b060d492de21b385acc887b5237a448bf7ffc367
[gnulib.git] / ChangeLog
1 2007-07-12  Bruno Haible  <bruno@clisp.org>
2
3         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
4         in the modules files.
5
6 2007-07-11  Karl Berry  <karl@gnu.org>
7
8         * MODULES.html.sh (func_module): use
9          sed -e '\|^'"${includefile}"'$|d' 
10          instead of /.../d, to avoid errors on $includefile's containing /.
11
12 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
13
14         * gnulib-tool (func_import): Avoid duplication of --avoid
15         statements
16         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
17         names to `_' in variable names.
18
19 2007-07-10  Eric Blake  <ebb9@byu.net>
20
21         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
22         * NEWS: Document this change.
23
24 2007-07-08  Bruno Haible  <bruno@clisp.org>
25
26         Update to Unicode 5.0.
27         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
28         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
29         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
30         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
31         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
32         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
33         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
34         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
35         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
36         U+10A3F, U+1D242..U+1D244.
37         (nonspacing_table_ind): Update.
38         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
39         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
40
41 2007-07-08  Bruno Haible  <bruno@clisp.org>
42
43         Update to Unicode 5.0.
44         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
45         code transform. Extend the name index field of unicode_name_to_code and
46         unicode_code_to_name from 16 to 24 bits.
47         * lib/uniname/uniname.c (unicode_character_name,
48         unicode_name_character): Add the range 0x12xxx to the code transform.
49         * lib/uniname/uninames.h: Regenerated.
50         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
51
52 2007-07-07  Bruno Haible  <bruno@clisp.org>
53
54         * modules/wcwidth-tests: New file.
55         * tests/test-wcwidth.c: New file.
56
57         Work around MacOS X wcwidth() bug.
58         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
59         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
60         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
61         original wcwidth in non-UTF-8 locales.
62         * modules/wcwidth (Depends-on): Add localcharset, streq,
63         uniwidth/width.
64         * doc/functions/wcwidth.texi: Update.
65
66 2007-07-07  Bruno Haible  <bruno@clisp.org>
67
68         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
69         (wcwidth): New declaration.
70         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
71         macros.
72         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
73         here. Prepare for creating <wchar.h> unconditionally.
74         * modules/wchar (Depends-on): Add link-warning.
75         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
76         REPLACE_WCWIDTH, and GL_LINK_WARNING.
77         * lib/wcwidth.h: Remove file.
78         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
79         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
80         * modules/wcwidth (Files): Remove lib/wcwidth.h.
81         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
82         (Include): Replace wcwidth.h with <wchar.h>.
83         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
84         * lib/mbchar.h: Don't include wcwidth.h.
85         * lib/mbswidth.c: Likewise.
86         * NEWS: Mention the change.
87
88 2007-07-07  Bruno Haible  <bruno@clisp.org>
89
90         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
91         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
92         definition with an external declaration.
93         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
94         defined as a function. Remove AC_C_INLINE requirement.
95         * modules/wcwidth (Files): Add lib/wcwidth.c.
96         (Makefile.am): Remove redundant statement.
97
98 2007-07-07  Bruno Haible  <bruno@clisp.org>
99
100         * MODULES.html.sh (Unicode string functions): Add the new modules.
101
102         * tests/uniwidth/test-u32-strwidth.c: New file.
103         * modules/uniwidth/u32-strwidth-tests: New file.
104
105         * lib/uniwidth/u32-strwidth.c: New file.
106         * modules/uniwidth/u32-strwidth: New file.
107
108         * tests/uniwidth/test-u16-strwidth.c: New file.
109         * modules/uniwidth/u16-strwidth-tests: New file.
110
111         * lib/uniwidth/u16-strwidth.c: New file.
112         * modules/uniwidth/u16-strwidth: New file.
113
114         * tests/uniwidth/test-u8-strwidth.c: New file.
115         * modules/uniwidth/u8-strwidth-tests: New file.
116
117         * lib/uniwidth/u8-strwidth.c: New file.
118         * modules/uniwidth/u8-strwidth: New file.
119
120         * tests/uniwidth/test-u32-width.c: New file.
121         * modules/uniwidth/u32-width-tests: New file.
122
123         * lib/uniwidth/u32-width.c: New file.
124         * modules/uniwidth/u32-width: New file.
125
126         * tests/uniwidth/test-u16-width.c: New file.
127         * modules/uniwidth/u16-width-tests: New file.
128
129         * lib/uniwidth/u16-width.c: New file.
130         * modules/uniwidth/u16-width: New file.
131
132         * tests/uniwidth/test-u8-width.c: New file.
133         * modules/uniwidth/u8-width-tests: New file.
134
135         * lib/uniwidth/u8-width.c: New file.
136         * modules/uniwidth/u8-width: New file.
137
138         * tests/uniwidth/test-uc_width.c: New file.
139         * modules/uniwidth/width-tests: New file.
140
141         * lib/uniwidth/width.c: New file, from GNU libiconv.
142         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
143         * modules/uniwidth/width: New file.
144
145         * lib/uniwidth.h: New file, from GNU libiconv.
146         * modules/uniwidth/base: New file.
147
148 2007-07-07  Bruno Haible  <bruno@clisp.org>
149
150         * lib/uniname.h: New file, from GNU gettext.
151         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
152         * lib/uniname/uninames.h: New file, from GNU gettext.
153         * lib/uniname/uniname.c: New file, from GNU gettext.
154         * tests/uniname/test-uninames.sh: New file.
155         * tests/uniname/test-uninames.c: New file, from GNU gettext.
156         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
157         * modules/uniname/base: New file.
158         * modules/uniname/uniname: New file.
159         * modules/uniname/uniname-tests: New file.
160         * MODULES.html.sh (Unicode string functions): Add the new modules.
161
162 2007-07-06  Bruno Haible  <bruno@clisp.org>
163
164         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
165
166 2007-07-06  Bruno Haible  <bruno@clisp.org>
167
168         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
169         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
170         includes <cygwin/sys_time.h> which includes <sys/select.h> which
171         include <sys/time.h>.
172         Reported by Eric Blake.
173
174 2007-07-06  Eric Blake  <ebb9@byu.net>
175
176         Fix testing canonicalize on cygwin.
177         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
178         Revert patch from 2007-06-19.
179         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
180         canonicalize module is also in use.
181         * tests/test-canonicalize.c: New file.
182         * tests/test-canonicalize.sh: Likewise.
183         * modules/canonicalize-tests: Likewise.
184
185 2007-07-06  Jim Meyering  <jim@meyering.net>
186
187         * lib/getugroups.c (getugroups): Detect getgrent failure.
188         Adjust comment to reflect reality: this function may return -1.
189
190 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
191
192         * build-aux/bootstrap (TP_URL,get_translations): Update to use
193         the new TP address.
194         (usage): Fix typo
195         (gnulib_mk): New variable.
196
197 2007-07-05  Jim Meyering  <jim@meyering.net>
198
199         Don't let endgrent clobber errno, no matter how improbable.
200         * lib/getugroups.c (getugroups): Save and restore errno around
201         endgrent call.
202
203         Close the group DB even when failing with 2^31 or more members.
204         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
205
206 2007-07-04  Jim Meyering  <jim@meyering.net>
207
208         * lib/getugroups.h: New file.
209         * lib/getugroups.c: Include "getugroups.h".
210         Remove uses of "register" keyword.
211         Move local variable, "cp", down into scope where used.
212         Give "username" parameter the "const" attribute.
213         * modules/getugroups (Files): Add lib/getugroups.h
214
215 2007-07-04  Karl Berry  <karl@gnu.org>
216
217         * MODULES.html.sh (func_all_modules): Complete rename of
218         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
219
220 2007-07-02  Bruno Haible  <bruno@clisp.org>
221
222         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
223         mode, when inttypes.h comes from gnulib.
224         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
225
226 2007-07-02  Simon Josefsson  <simon@josefsson.org>
227
228         * NEWS: Mention lgpl module name change.
229
230         * modules/lgpl-2.1: Renamed from lgpl.
231
232         * NEWS: Mention gpl module name change.
233
234         * modules/gpl-3.0: New file, based on gpl-2.0.
235
236         * modules/gpl-2.0: Renamed from gpl.
237
238         * modules/gpl: Fix filename, doc/gpl.texi is now found at
239         doc/gpl-2.0.texi.
240
241 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
242
243         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
244         #define __STDC_LIMIT_MACROS temporarily while including
245         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
246         Problem reported by Joel E. Denny in
247         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
248
249 2007-07-01  Bruno Haible  <bruno@clisp.org>
250
251         * lib/unistdio.h: New file.
252         * lib/unistdio/u-asnprintf.h: New file.
253         * lib/unistdio/u-asprintf.h: New file.
254         * lib/unistdio/u-printf-args.c: New file.
255         * lib/unistdio/u-printf-args.h: New file.
256         * lib/unistdio/u-printf-parse.h: New file.
257         * lib/unistdio/u-snprintf.h: New file.
258         * lib/unistdio/u-sprintf.h: New file.
259         * lib/unistdio/u-vasprintf.h: New file.
260         * lib/unistdio/u-vsnprintf.h: New file.
261         * lib/unistdio/u-vsprintf.h: New file.
262         * lib/unistdio/ulc-asnprintf.c: New file.
263         * lib/unistdio/ulc-asprintf.c: New file.
264         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
265         * lib/unistdio/ulc-printf-parse.c: New file.
266         * lib/unistdio/ulc-snprintf.c: New file.
267         * lib/unistdio/ulc-sprintf.c: New file.
268         * lib/unistdio/ulc-vasnprintf.c: New file.
269         * lib/unistdio/ulc-vasprintf.c: New file.
270         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
271         * lib/unistdio/ulc-vsnprintf.c: New file.
272         * lib/unistdio/ulc-vsprintf.c: New file.
273         * lib/unistdio/u8-asnprintf.c: New file.
274         * lib/unistdio/u8-asprintf.c: New file.
275         * lib/unistdio/u8-printf-parse.c: New file.
276         * lib/unistdio/u8-snprintf.c: New file.
277         * lib/unistdio/u8-sprintf.c: New file.
278         * lib/unistdio/u8-vasnprintf.c: New file.
279         * lib/unistdio/u8-vasprintf.c: New file.
280         * lib/unistdio/u8-vsnprintf.c: New file.
281         * lib/unistdio/u8-vsprintf.c: New file.
282         * lib/unistdio/u8-u8-asnprintf.c: New file.
283         * lib/unistdio/u8-u8-asprintf.c: New file.
284         * lib/unistdio/u8-u8-snprintf.c: New file.
285         * lib/unistdio/u8-u8-sprintf.c: New file.
286         * lib/unistdio/u8-u8-vasnprintf.c: New file.
287         * lib/unistdio/u8-u8-vasprintf.c: New file.
288         * lib/unistdio/u8-u8-vsnprintf.c: New file.
289         * lib/unistdio/u8-u8-vsprintf.c: New file.
290         * lib/unistdio/u16-asnprintf.c: New file.
291         * lib/unistdio/u16-asprintf.c: New file.
292         * lib/unistdio/u16-printf-parse.c: New file.
293         * lib/unistdio/u16-snprintf.c: New file.
294         * lib/unistdio/u16-sprintf.c: New file.
295         * lib/unistdio/u16-vasnprintf.c: New file.
296         * lib/unistdio/u16-vasprintf.c: New file.
297         * lib/unistdio/u16-vsnprintf.c: New file.
298         * lib/unistdio/u16-vsprintf.c: New file.
299         * lib/unistdio/u16-u16-asnprintf.c: New file.
300         * lib/unistdio/u16-u16-asprintf.c: New file.
301         * lib/unistdio/u16-u16-snprintf.c: New file.
302         * lib/unistdio/u16-u16-sprintf.c: New file.
303         * lib/unistdio/u16-u16-vasnprintf.c: New file.
304         * lib/unistdio/u16-u16-vasprintf.c: New file.
305         * lib/unistdio/u16-u16-vsnprintf.c: New file.
306         * lib/unistdio/u16-u16-vsprintf.c: New file.
307         * lib/unistdio/u32-asnprintf.c: New file.
308         * lib/unistdio/u32-asprintf.c: New file.
309         * lib/unistdio/u32-printf-parse.c: New file.
310         * lib/unistdio/u32-snprintf.c: New file.
311         * lib/unistdio/u32-sprintf.c: New file.
312         * lib/unistdio/u32-vasnprintf.c: New file.
313         * lib/unistdio/u32-vasprintf.c: New file.
314         * lib/unistdio/u32-vsnprintf.c: New file.
315         * lib/unistdio/u32-vsprintf.c: New file.
316         * lib/unistdio/u32-u32-asnprintf.c: New file.
317         * lib/unistdio/u32-u32-asprintf.c: New file.
318         * lib/unistdio/u32-u32-snprintf.c: New file.
319         * lib/unistdio/u32-u32-sprintf.c: New file.
320         * lib/unistdio/u32-u32-vasnprintf.c: New file.
321         * lib/unistdio/u32-u32-vasprintf.c: New file.
322         * lib/unistdio/u32-u32-vsnprintf.c: New file.
323         * lib/unistdio/u32-u32-vsprintf.c: New file.
324         * tests/unistdio/test-ulc-asnprintf1.c: New file.
325         * tests/unistdio/test-ulc-asnprintf1.h: New file.
326         * tests/unistdio/test-ulc-printf1.h: New file.
327         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
328         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
329         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
330         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
331         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
332         * tests/unistdio/test-ulc-vasprintf1.c: New file.
333         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
334         * tests/unistdio/test-ulc-vsprintf1.c: New file.
335         * tests/unistdio/test-u8-asnprintf1.c: New file.
336         * tests/unistdio/test-u8-asnprintf1.h: New file.
337         * tests/unistdio/test-u8-printf1.h: New file.
338         * tests/unistdio/test-u8-vasnprintf1.c: New file.
339         * tests/unistdio/test-u8-vasnprintf2.c: New file.
340         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
341         * tests/unistdio/test-u8-vasnprintf3.c: New file.
342         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
343         * tests/unistdio/test-u8-vasprintf1.c: New file.
344         * tests/unistdio/test-u8-vsnprintf1.c: New file.
345         * tests/unistdio/test-u8-vsprintf1.c: New file.
346         * tests/unistdio/test-u16-asnprintf1.c: New file.
347         * tests/unistdio/test-u16-asnprintf1.h: New file.
348         * tests/unistdio/test-u16-printf1.h: New file.
349         * tests/unistdio/test-u16-vasnprintf1.c: New file.
350         * tests/unistdio/test-u16-vasnprintf2.c: New file.
351         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
352         * tests/unistdio/test-u16-vasnprintf3.c: New file.
353         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
354         * tests/unistdio/test-u16-vasprintf1.c: New file.
355         * tests/unistdio/test-u16-vsnprintf1.c: New file.
356         * tests/unistdio/test-u16-vsprintf1.c: New file.
357         * tests/unistdio/test-u32-asnprintf1.c: New file.
358         * tests/unistdio/test-u32-asnprintf1.h: New file.
359         * tests/unistdio/test-u32-printf1.h: New file.
360         * tests/unistdio/test-u32-vasnprintf1.c: New file.
361         * tests/unistdio/test-u32-vasnprintf2.c: New file.
362         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
363         * tests/unistdio/test-u32-vasnprintf3.c: New file.
364         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
365         * tests/unistdio/test-u32-vasprintf1.c: New file.
366         * tests/unistdio/test-u32-vsnprintf1.c: New file.
367         * tests/unistdio/test-u32-vsprintf1.c: New file.
368         * modules/unistdio/base: New file.
369         * modules/unistdio/u-printf-args: New file.
370         * modules/unistdio/ulc-asnprintf: New file.
371         * modules/unistdio/ulc-asprintf: New file.
372         * modules/unistdio/ulc-fprintf: New file.
373         * modules/unistdio/ulc-printf-parse: New file.
374         * modules/unistdio/ulc-snprintf: New file.
375         * modules/unistdio/ulc-sprintf: New file.
376         * modules/unistdio/ulc-vasnprintf: New file.
377         * modules/unistdio/ulc-vasprintf: New file.
378         * modules/unistdio/ulc-vfprintf: New file.
379         * modules/unistdio/ulc-vsnprintf: New file.
380         * modules/unistdio/ulc-vsprintf: New file.
381         * modules/unistdio/u8-asnprintf: New file.
382         * modules/unistdio/u8-asprintf: New file.
383         * modules/unistdio/u8-printf-parse: New file.
384         * modules/unistdio/u8-snprintf: New file.
385         * modules/unistdio/u8-sprintf: New file.
386         * modules/unistdio/u8-vasnprintf: New file.
387         * modules/unistdio/u8-vasprintf: New file.
388         * modules/unistdio/u8-vsnprintf: New file.
389         * modules/unistdio/u8-vsprintf: New file.
390         * modules/unistdio/u8-u8-asnprintf: New file.
391         * modules/unistdio/u8-u8-asprintf: New file.
392         * modules/unistdio/u8-u8-snprintf: New file.
393         * modules/unistdio/u8-u8-sprintf: New file.
394         * modules/unistdio/u8-u8-vasnprintf: New file.
395         * modules/unistdio/u8-u8-vasprintf: New file.
396         * modules/unistdio/u8-u8-vsnprintf: New file.
397         * modules/unistdio/u8-u8-vsprintf: New file.
398         * modules/unistdio/u16-asnprintf: New file.
399         * modules/unistdio/u16-asprintf: New file.
400         * modules/unistdio/u16-printf-parse: New file.
401         * modules/unistdio/u16-snprintf: New file.
402         * modules/unistdio/u16-sprintf: New file.
403         * modules/unistdio/u16-vasnprintf: New file.
404         * modules/unistdio/u16-vasprintf: New file.
405         * modules/unistdio/u16-vsnprintf: New file.
406         * modules/unistdio/u16-vsprintf: New file.
407         * modules/unistdio/u16-u16-asnprintf: New file.
408         * modules/unistdio/u16-u16-asprintf: New file.
409         * modules/unistdio/u16-u16-snprintf: New file.
410         * modules/unistdio/u16-u16-sprintf: New file.
411         * modules/unistdio/u16-u16-vasnprintf: New file.
412         * modules/unistdio/u16-u16-vasprintf: New file.
413         * modules/unistdio/u16-u16-vsnprintf: New file.
414         * modules/unistdio/u16-u16-vsprintf: New file.
415         * modules/unistdio/u32-asnprintf: New file.
416         * modules/unistdio/u32-asprintf: New file.
417         * modules/unistdio/u32-printf-parse: New file.
418         * modules/unistdio/u32-snprintf: New file.
419         * modules/unistdio/u32-sprintf: New file.
420         * modules/unistdio/u32-vasnprintf: New file.
421         * modules/unistdio/u32-vasprintf: New file.
422         * modules/unistdio/u32-vsnprintf: New file.
423         * modules/unistdio/u32-vsprintf: New file.
424         * modules/unistdio/u32-u32-asnprintf: New file.
425         * modules/unistdio/u32-u32-asprintf: New file.
426         * modules/unistdio/u32-u32-snprintf: New file.
427         * modules/unistdio/u32-u32-sprintf: New file.
428         * modules/unistdio/u32-u32-vasnprintf: New file.
429         * modules/unistdio/u32-u32-vasprintf: New file.
430         * modules/unistdio/u32-u32-vsnprintf: New file.
431         * modules/unistdio/u32-u32-vsprintf: New file.
432         * modules/unistdio/ulc-asnprintf-tests: New file.
433         * modules/unistdio/ulc-vasnprintf-tests: New file.
434         * modules/unistdio/ulc-vasprintf-tests: New file.
435         * modules/unistdio/ulc-vsnprintf-tests: New file.
436         * modules/unistdio/ulc-vsprintf-tests: New file.
437         * modules/unistdio/u8-asnprintf-tests: New file.
438         * modules/unistdio/u8-vasnprintf-tests: New file.
439         * modules/unistdio/u8-vasprintf-tests: New file.
440         * modules/unistdio/u8-vsnprintf-tests: New file.
441         * modules/unistdio/u8-vsprintf-tests: New file.
442         * modules/unistdio/u16-asnprintf-tests: New file.
443         * modules/unistdio/u16-vasnprintf-tests: New file.
444         * modules/unistdio/u16-vasprintf-tests: New file.
445         * modules/unistdio/u16-vsnprintf-tests: New file.
446         * modules/unistdio/u16-vsprintf-tests: New file.
447         * modules/unistdio/u32-asnprintf-tests: New file.
448         * modules/unistdio/u32-vasnprintf-tests: New file.
449         * modules/unistdio/u32-vasprintf-tests: New file.
450         * modules/unistdio/u32-vsnprintf-tests: New file.
451         * modules/unistdio/u32-vsprintf-tests: New file.
452         * MODULES.html.sh (Unicode string functions): Add the new modules.
453
454 2007-07-01  Bruno Haible  <bruno@clisp.org>
455
456         * lib/sprintf.c (sprintf): Limit the available length estimation,
457         to avoid address wraparound.
458         * lib/vsprintf.c (vsprintf): Likewise.
459         * modules/sprintf-posix (Dependencies): Add stdint.
460         * modules/vsprintf-posix (Dependencies): Likewise.
461
462 2007-07-01  Bruno Haible <bruno@clisp.org>
463
464         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
465         Windows PATH as well. Conservative double-quoting. Comments.
466
467 2007-07-01  Bruno Haible <bruno@clisp.org>
468             Eric Blake  <ebb9@byu.net>
469             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
470
471         * gnulib-tool (self_abspathname): Fix algorithm to cope with
472         empty components in $PATH, denoting '.'.
473
474 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
475
476         * gnulib-tool: Fix indentation.
477         (func_create_megatestdir): Likewise.
478         Report by Bruno Haible.
479
480 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
481
482         Sync from Automake.
483         * build-aux/gnupload: Fix shell portability issues with for loops.
484         Report by Karl Berry.
485
486 2007-06-29  Simon Josefsson  <simon@josefsson.org>
487
488         * build-aux/maint.mk (POURL): Use translationproject.org.
489
490 2007-06-27  Simon Josefsson  <simon@josefsson.org>
491             Bruno Haible  <bruno@clisp.org>
492
493         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
494         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
495         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
496         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
497         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
498
499 2007-06-27  Bruno Haible  <bruno@clisp.org>
500
501         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
502         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
503
504 2007-06-26  Karl Berry  <karl@gnu.org>
505
506         * MODULES.html.sh: remove xreadlink-with-size.
507
508 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
509
510         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
511         method that I hope also handles the double-include problem noted
512         by Bruno Haible in
513         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
514
515 2007-06-23  Bruno Haible  <bruno@clisp.org>
516
517         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
518         Don't let the 'mostlyclean' target fail if the last subdirectory could
519         not be removed.
520         Reported by Karl Berry.
521
522 2007-06-23  Bruno Haible  <bruno@clisp.org>
523
524         * gnulib-tool (echo): Add a speedier workaround for ksh.
525         * tests/test-echo.sh: Likewise.
526
527 2007-06-23  Bruno Haible  <bruno@clisp.org>
528
529         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
530         * tests/test-echo.sh: Likewise.
531
532 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
533
534         * gnulib-tool (IFS): Initialize early, so we don't set it to
535         empty later.
536         (self_abspathname): Rewrite algorithm to set it, reindent.
537         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
538         (func_create_megatestdir): Merge some sed scripts.
539
540 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
541
542         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
543         exposed by Sun Studio 11 cc on Solaris 8.
544
545 2007-06-22  Bruno Haible  <bruno@clisp.org>
546
547         * gnulib-tool (echo): Ensure the echo primitive does not interpret
548         backslashes.
549         * tests/test-echo.sh: New file.
550
551 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
552
553         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
554         simplify `sed_replace_build_aux' scripts, they are portable but
555         echoing them with `echo' is not.
556         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
557
558 2007-06-21  Karl Berry  <karl@gnu.org>
559
560         * config/srclist.txt: guess we can't handle the licenses via
561         srclist at the moment.
562
563 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
564
565         * MODULES.html.sh: Add include_next.
566         * modules/include_next: New file.
567
568 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
569
570         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
571         INCLUDE_NEXT.
572         (gl_CHECK_NEXT_HEADERS): New macro.
573         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
574         the obsolescent gl_ABSOLUTE_HEADER.
575         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
576         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
577         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
578         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
579         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
580         * m4/math_h.m4 (gl_MATH_H): Likewise.
581         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
582         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
583         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
584         * m4/stdint.m4 (gl_STDINT_H): Likewise.
585         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
586         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
587         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
588         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
589         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
590         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
591         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
592         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
593         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
594         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
595         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
596         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
597         * m4/inttypes.m4 (gl_INTTYPES_H): Define
598         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
599         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
600         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
601         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
602         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
603         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
604         * lib/float_.h: Likewise.
605         * lib/inttypes_.h: Likewise.
606         * lib/math_.h: Likewise.
607         * lib/search_.h: Likewise.
608         * lib/signal_.h: Likewise.
609         * lib/stdint_.h: Likewise.
610         * lib/stdio_.h: Likewise.
611         * lib/stdlib_.h: Likewise.
612         * lib/string_.h: Likewise.
613         * lib/sys_stat_.h: Likewise.
614         * lib/sys_time_.h: Likewise.
615         * lib/time_.h: Likewise.
616         * lib/unistd_.h: Likewise.
617         * lib/wchar_.h: Likewise.
618         * lib/wctype_.h: Likewise.
619         * lib/dirent_.h: Likewise.
620         * lib/iconv_.h: Likewise.
621         * lib/locale_.h: Likewise.
622         * lib/netinet_in_.h: Likewise.
623         * lib/sys_select_.h: Likewise.
624         * lib/sys_socket_.h: Likewise.
625         * lib/sysexits_.h: Likewise.
626         * modules/fcntl (Depends-on): Depend on include_next, not
627         absolute_header.
628         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
629         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
630         * modules/fchdir: Likewise.
631         * modules/float: Likewise.
632         * modules/iconv_open: Likewise.
633         * modules/inttypes: Likewise.
634         * modules/locale: Likewise.
635         * modules/math: Likewise.
636         * modules/netinet_in: Likewise.
637         * modules/search: Likewise.
638         * modules/signal: Likewise.
639         * modules/stdint: Likewise.
640         * modules/stdio: Likewise.
641         * modules/stdlib: Likewise.
642         * modules/string: Likewise.
643         * modules/sys_select: Likewise.
644         * modules/sys_socket: Likewise.
645         * modules/sys_stat: Likewise.
646         * modules/sys_time: Likewise.
647         * modules/sysexits: Likewise.
648         * modules/time: Likewise.
649         * modules/unistd: Likewise.
650         * modules/wchar: Likewise.
651         * modules/wctype: Likewise.
652         * modules/sys_stat: Change maintainer to "all".
653         * modules/unistd: Likewise.
654
655 2007-06-20  Karl Berry  <karl@gnu.org>
656
657         * config/srclist.txt: track www changes in license files.
658
659 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
660
661         * build-aux/bootstrap: Remove stray dot.
662         Make sure build_aux settings are honored when linking
663         gnulib_extra_files.
664
665 2007-06-19  Eric Blake  <ebb9@byu.net>
666
667         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
668         Allow compilation on cygwin.
669
670 2007-06-19  Jim Meyering  <jim@meyering.net>
671
672         xreadlink-with-size: Remove module.  No longer used.
673         Ex-callers now use xreadlink or mreadlink-with-size.
674         * modules/xreadlink-with-size: Remove module.
675         * lib/xreadlink-with-size.c: Remove file.
676         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
677         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
678         just before the function definition *is* accurate.
679
680         Eliminate one way canonicalize_filename_mode could exit.
681         * lib/canonicalize.c (canonicalize_filename_mode):
682         Use mreadlink_with_size, not xreadlink_with_size.
683
684 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
685
686         Detect porting problems to FreeBSD/arm, which has time_t wider than
687         long int.  Original problem reported for GNU diff by Xin Li in
688         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
689         * modules/getdate (Depends-on): Add intprops, verify.
690         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
691         is an integer type no wider than long int.
692
693 2007-06-18  Jim Meyering  <jim@meyering.net>
694
695         New module: mreadlink-with-size.
696         * MODULES.html.sh: Add mreadlink-with-size.
697         * modules/mreadlink-with-size: New module
698         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
699         not xreadlink-with-size.
700         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
701
702 2007-06-16  Bruno Haible  <bruno@clisp.org>
703
704         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
705         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
706         Reported by Gary V. Vaughan <gary@gnu.org>.
707
708 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
709
710         Revamp lchown so that it lives in unistd.h where it belongs.
711         * lib/lchown.h: Remove.
712         * lib/dirchownmod.c: Don't include lib/lchown.h.
713         * lib/fchownat.c: Likewise.
714         * lib/openat.c: Likewise.
715         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
716         does not follow symlinks.
717         (EOPNOTSUPP): Define if not defined.
718         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
719         is defined to 0.
720         (lchown): New decl.
721         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
722         Do not check for lchown decl.
723         Set REPLACE_LCHOWN.
724         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
725         REPLACE_LCHOWN.
726         * modules/chown: Make it clear it follows symlinks.
727         * modules/lchown: Make it clear it doesn't follow symlinks.
728         (Files): Remove lib/lchown.h
729         (Depends-on): Add unistd.
730         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
731         (Include): Include <unistd.h>, not "lchown.h".
732         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
733         REPLACE_LCHOWN.
734
735 2007-06-15  Jim Meyering  <jim@meyering.net>
736
737         Change license (GPL to LGPL) of fsusage and dependents.
738         * modules/fsusage (License): Change to LGPL.
739         * modules/full-read (License): Likewise.
740         * modules/full-write (License): Likewise.
741         * modules/safe-read (License): Likewise.
742         * modules/safe-write (License): Likewise.
743
744 2007-06-14  Ben Pfaff  <blp@gnu.org>
745
746         Missing part of allocsa -> malloca transition.
747         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
748         gl_MALLOCA.
749
750 2007-06-12  Bruno Haible  <bruno@clisp.org>
751
752         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
753         to ia64, x86_64, i386.
754         Reported by Eric Blake.
755
756 2007-06-12  Bruno Haible  <bruno@clisp.org>
757
758         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
759         cross-compiling to x86_64.
760
761 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
762
763         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
764         glitch reported by Ralf Wildenhues in
765         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
766
767         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
768         Vin Shelton.
769
770 2007-06-11  Bruno Haible  <bruno@clisp.org>
771
772         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
773         replacement string.
774         Reported by Eric Blake.
775
776 2007-06-10  Bruno Haible  <bruno@clisp.org>
777
778         Prepare vasnprintf code for use with Unicode strings.
779         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
780         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
781         TYPE_U32_STRING.
782         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
783         a_u32_string variants.
784         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
785         * lib/printf-args.c: Don't include config.h and the specification
786         header if PRINTF_FETCHARGS is already defined.
787         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
788         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
789         TYPE_U16_STRING, TYPE_U32_STRING.
790         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
791         u16_directive, u16_directives, u32_directive, u32_directives): New
792         types.
793         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
794         New declarations.
795         * lib/printf-parse.c: Don't include config.h and the specification
796         header if PRINTF_PARSE is already defined. Eliminate the set of
797         parameters for WIDE_CHAR_VERSION; the user of this file must provide
798         them now. Include c-ctype.h.
799         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
800         directive and CHAR_T_ONLY_ASCII.
801         * lib/vasnprintf.c: Don't include config.h and the specification header
802         if VASNPRINTF is already defined.
803         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
804         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
805         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
806         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
807         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
808         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
809         code accordingly.
810         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
811         pad_ourselves also in this case, with the 'c' and 's' directives, and
812         with a different notion of "width".
813         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
814
815 2007-06-10  Bruno Haible  <bruno@clisp.org>
816
817         * modules/unistr/u32-mbsnlen: New file.
818         * lib/unistr/u32-mbsnlen.c: New file.
819
820         * modules/unistr/u16-mbsnlen: New file.
821         * lib/unistr/u16-mbsnlen.c: New file.
822
823         * modules/unistr/u8-mbsnlen: New file.
824         * lib/unistr/u8-mbsnlen.c: New file.
825
826         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
827         declarations.
828
829 2007-06-10  Bruno Haible  <bruno@clisp.org>
830
831         * lib/string_.h (mbsnlen): New declaration.
832         * lib/mbsnlen.c: New file.
833         * m4/mbsnlen.m4: New file.
834         * modules/mbsnlen: New file.
835         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
836         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
837         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
838
839 2007-06-10  Bruno Haible  <bruno@clisp.org>
840
841         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
842
843 2007-06-10  Bruno Haible  <bruno@clisp.org>
844
845         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
846         * lib/mbuiter.h: Likewise.
847
848 2007-06-10  Bruno Haible  <bruno@clisp.org>
849
850         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
851         declaration.
852
853 2007-06-10  Karl Berry  <karl@gnu.org>
854
855         * config/srclist.txt: remove gettext entries, Bruno prefers
856         to update individually.
857
858 2007-06-10  Bruno Haible  <bruno@clisp.org>
859
860         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
861         'maxlen'. Ensure only length + width bytes are allocated, not
862         length + 1 + width.
863
864 2007-06-09  Bruno Haible  <bruno@clisp.org>
865
866         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
867         (CHAR_T): Remove macro.
868         (VASNPRINTF): Update.
869
870 2007-06-09  Bruno Haible  <bruno@clisp.org>
871
872         * MODULES.html.sh (Unicode string functions): Add the new modules.
873
874         * modules/uniconv/u32-conv-to-enc: New file.
875         * lib/uniconv/u32-conv-to-enc.c: New file.
876         * modules/uniconv/u32-conv-to-enc-tests: New file.
877         * tests/uniconv/test-u32-conv-to-enc.c: New file.
878
879         * modules/uniconv/u16-conv-to-enc: New file.
880         * lib/uniconv/u16-conv-to-enc.c: New file.
881         * lib/uniconv/u-conv-to-enc.h: New file.
882         * modules/uniconv/u16-conv-to-enc-tests: New file.
883         * tests/uniconv/test-u16-conv-to-enc.c: New file.
884
885         * modules/uniconv/u8-conv-to-enc: New file.
886         * lib/uniconv/u8-conv-to-enc.c: New file.
887         * modules/uniconv/u8-conv-to-enc-tests: New file.
888         * tests/uniconv/test-u8-conv-to-enc.c: New file.
889
890         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
891         u32_conv_to_encoding): New declarations.
892
893 2007-06-09  Bruno Haible  <bruno@clisp.org>
894
895         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
896
897 2007-06-09  Bruno Haible  <bruno@clisp.org>
898
899         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
900         * modules/malloca: Renamed from modules/allocsa, updated.
901         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
902         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
903         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
904         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
905         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
906         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
907         * modules/xmalloca: Renamed from modules/xallocsa, updated.
908         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
909         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
910         * modules/c-strcasestr (Depends-on): Update.
911         * lib/c-strcasestr.c: Update.
912         * modules/c-strstr (Depends-on): Update.
913         * lib/c-strstr.c: Update.
914         * modules/canonicalize-lgpl (Depends-on): Update.
915         * lib/canonicalize-lgpl.c: Update.
916         * modules/clean-temp (Depends-on): Update.
917         * lib/clean-temp.c: Update.
918         * modules/csharpcomp (Depends-on): Update.
919         * lib/csharpcomp.c: Update.
920         * modules/csharpexec (Depends-on): Update.
921         * lib/csharpexec.c: Update.
922         * modules/javacomp (Depends-on): Update.
923         * lib/javacomp.c: Update.
924         * modules/javaexec (Depends-on): Update.
925         * lib/javaexec.c: Update.
926         * modules/mbscasestr (Depends-on): Update.
927         * lib/mbscasestr.c: Update.
928         * modules/mbsstr (Depends-on): Update.
929         * lib/mbsstr.c: Update.
930         * modules/setenv (Depends-on): Update.
931         * lib/setenv.c: Update.
932         * modules/strcasestr (Depends-on): Update.
933         * lib/strcasestr.c: Update.
934         * modules/striconveha (Depends-on): Update.
935         * lib/striconveha.c: Update.
936         * modules/relocatable-prog-wrapper (Files): Update.
937         * lib/relocwrapper.c: Update.
938         * build-aux/install-reloc: Update.
939         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
940
941 2007-06-08  Bruno Haible  <bruno@clisp.org>
942
943         Port to uClibc.
944         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
945         * lib/fpurge.c (fpurge): Likewise.
946         * lib/freading.c (freading): Likewise.
947         * lib/fseeko.c (rpl_fseeko): Likewise.
948         * lib/fseterr.c (fseterr): Likewise.
949         * lib/fwriting.c (fwriting): Likewise.
950         * tests/test-fflush.c (main): Avoid a failure on uClibc.
951
952 2007-06-08  Bruno Haible  <bruno@clisp.org>
953
954         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
955         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
956         * modules/gettext (Files): Add m4/intlmacosx.m4.
957
958 2007-06-07  Bruno Haible  <bruno@clisp.org>
959
960         * modules/localename-tests: New file.
961         * tests/test-localename.c: New file.
962
963         New module 'localename'.
964         * lib/localename.h: New file.
965         * lib/localename.c: New file, from GNU gettext.
966         * m4/localename.m4: New file.
967         * modules/localename: New file.
968
969 2007-06-07  Bruno Haible  <bruno@clisp.org>
970
971         Work around the lack of <wchar.h> on some builds of uClibc.
972         * doc/headers/wchar.texi: Update.
973         * lib/wchar_.h: Include <wchar.h> only if it exists.
974         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
975         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
976         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
977         doesn't exist.
978         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
979         * modules/mbfile (Depends-on): Add wchar.
980         * modules/mbiter (Depends-on): Likewise.
981         * modules/mbuiter (Depends-on): Likewise.
982         Reported by Simon Josefsson.
983
984 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
985
986         Work around problem reported by Steven M. Schweda in
987         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
988         Tru64 5.1B with the Compaq compiler environment installed declares
989         an 'isblank' function but does not define it in the C library.
990         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
991         * lib/regex_internal.h (isblank): Likewise.
992         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
993         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
994
995 2007-06-05  Bruno Haible  <bruno@clisp.org>
996
997         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
998         ia64.
999         * modules/printf-safe: New file.
1000         * modules/fprintf-posix (Depends-on): Add printf-safe.
1001         * modules/printf-posix (Depends-on): Likewise.
1002         * modules/snprintf-posix (Depends-on): Likewise.
1003         * modules/sprintf-posix (Depends-on): Likewise.
1004         * modules/vasnprintf-posix (Depends-on): Likewise.
1005         * modules/vasprintf-posix (Depends-on): Likewise.
1006         * modules/vfprintf-posix (Depends-on): Likewise.
1007         * modules/vprintf-posix (Depends-on): Likewise.
1008         * modules/vsnprintf-posix (Depends-on): Likewise.
1009         * modules/vsprintf-posix (Depends-on): Likewise.
1010         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
1011         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
1012         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
1013         "no" on i386, x86_64, ia64.
1014         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
1015         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1016         on i386, x86_64, ia64.
1017         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
1018         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1019         on i386, x86_64, ia64.
1020         * tests/test-vasnprintf-posix.c: Include float.h.
1021         (LDBL80_WORDS): New macro.
1022         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1023         on i386, x86_64, ia64.
1024         * tests/test-vasprintf-posix.c: Include float.h.
1025         (LDBL80_WORDS): New macro.
1026         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1027         on i386, x86_64, ia64.
1028         * tests/test-snprintf-posix.c: Include float.h.
1029         * tests/test-sprintf-posix.c: Likewise.
1030         * tests/test-vsnprintf-posix.c: Likewise.
1031         * tests/test-vsprintf-posix.c: Likewise.
1032
1033 2007-06-05  Bruno Haible  <bruno@clisp.org>
1034
1035         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
1036         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
1037         non-IEEE numbers on i386, x86_64, ia64.
1038         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
1039         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
1040         * tests/test-isnanl.h: Include float.h.
1041         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
1042
1043 2007-06-05  Bruno Haible  <bruno@clisp.org>
1044
1045         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
1046         also the %a / %A. Handle the %a / %A code before this extra handling.
1047
1048 2007-06-05  Bruno Haible  <bruno@clisp.org>
1049
1050         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
1051         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
1052
1053 2007-06-05  Bruno Haible  <bruno@clisp.org>
1054
1055         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
1056         typo in variable name.
1057
1058 2007-06-05  Eric Blake  <ebb9@byu.net>
1059
1060         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
1061         Reported by Simon Josefsson.
1062
1063 2007-06-04  Bruno Haible  <bruno@clisp.org>
1064
1065         Avoid test failures on some PowerPC platforms.
1066         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
1067         Define differently for PowerPC.
1068         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
1069         Reported by Gary V. Vaughan <gary@gnu.org>.
1070
1071 2007-06-02  Bruno Haible  <bruno@clisp.org>
1072
1073         Fix test-stdint failure on FreeBSD/ia64.
1074         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
1075         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
1076         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
1077         * doc/headers/stdint.texi: Update.
1078
1079 2007-06-01  Bruno Haible  <bruno@clisp.org>
1080
1081         * tests/test-binary-io.c (main): Pass a third argument to open().
1082         Reported by Gary V. Vaughan <gary@gnu.org>.
1083
1084 2007-06-01  Bruno Haible  <bruno@clisp.org>
1085
1086         * doc/functions/frexpl.texi: Update for mingw.
1087
1088 2007-06-01  Bruno Haible  <bruno@clisp.org>
1089
1090         * tests/test-lseek.c (main): Disable test of errno for invalid third
1091         argument.
1092         * doc/functions/lseek.texi: Update.
1093         Reported by Gary V. Vaughan <gary@gnu.org>.
1094
1095 2007-05-28  Bruno Haible  <bruno@clisp.org>
1096
1097         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
1098
1099 2007-05-31  Eric Blake  <ebb9@byu.net>
1100
1101         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
1102         cross compiling.
1103
1104 2007-05-30  Eric Blake  <ebb9@byu.net>
1105         and Bruno Haible  <bruno@clisp.org>
1106
1107         Work around mingw test failures exposed by m4-1.4.9b.
1108         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
1109         * tests/test-unistd.c: Disable uid_t and git_t tests for the
1110         moment.
1111
1112 2007-05-30  Bruno Haible  <bruno@clisp.org>
1113
1114         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
1115         assuming that they are closed. Needed on HP-UX 11.
1116
1117 2007-05-29  Bruno Haible  <bruno@clisp.org>
1118
1119         Fix a problem with #include_next.
1120         * lib/dirent_.h: Split the double-inclusion guard.
1121         * lib/fcntl_.h: Likewise.
1122         * lib/float_.h: Likewise.
1123         * lib/iconv_.h: Likewise.
1124         * lib/inttypes_.h: Likewise.
1125         * lib/locale_.h: Likewise.
1126         * lib/math_.h: Likewise.
1127         * lib/netinet_in_.h: Likewise.
1128         * lib/search_.h: Likewise.
1129         * lib/signal_.h: Likewise.
1130         * lib/stdint_.h: Likewise.
1131         * lib/stdio_.h: Likewise.
1132         * lib/stdlib_.h: Likewise.
1133         * lib/string_.h: Likewise.
1134         * lib/sys_select_.h: Likewise.
1135         * lib/sys_socket_.h: Likewise.
1136         * lib/sys_stat_.h: Likewise.
1137         * lib/sys_time_.h: Likewise.
1138         * lib/sysexits_.h: Likewise.
1139         * lib/time_.h: Likewise.
1140         * lib/unistd_.h: Likewise.
1141         * lib/wchar_.h: Likewise.
1142         * lib/wctype_.h: Likewise.
1143
1144 2007-05-29  Bruno Haible  <bruno@clisp.org>
1145
1146         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
1147         for the moment.
1148
1149 2007-05-29  Bruno Haible  <bruno@clisp.org>
1150
1151         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
1152         invocation.
1153         Reported by Eric Blake.
1154
1155 2007-05-29  Bruno Haible  <bruno@clisp.org>
1156
1157         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
1158         compiling case.
1159
1160 2007-05-29  Eric Blake  <ebb9@byu.net>
1161             Bruno Haible  <bruno@clisp.org>
1162
1163         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
1164         cross compiles.
1165
1166 2007-05-28  Eric Blake  <ebb9@byu.net>
1167
1168         * modules/closein-tests (test_closein_LDADD): Support test on
1169         cygwin with libtool.
1170
1171 2007-05-28  Bruno Haible  <bruno@clisp.org>
1172
1173         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
1174         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
1175         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
1176         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
1177         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
1178         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
1179         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
1180         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
1181         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
1182
1183 2007-05-28  Eric Blake  <ebb9@byu.net>
1184
1185         Unconditionally include <config.h> in unit tests.
1186         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
1187         * tests/test-allocsa.c, tests/test-arcfour.c,
1188         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
1189         tests/test-array_list.c, tests/test-array_oset.c,
1190         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
1191         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
1192         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
1193         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
1194         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
1195         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
1196         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
1197         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
1198         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
1199         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
1200         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
1201         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
1202         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
1203         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
1204         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
1205         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
1206         test-md5.c, test-memmem.c, test-printf-posix.c,
1207         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
1208         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
1209         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
1210         test-strcasestr.c, test-striconv.c, test-striconveh.c,
1211         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
1212         test-vasnprintf-posix2.c, test-vasnprintf.c,
1213         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
1214         test-vfprintf-posix.c, test-vprintf-posix.c,
1215         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
1216         test-xvasprintf.c: Likewise.
1217
1218 2007-05-28  Bruno Haible  <bruno@clisp.org>
1219
1220         * gnulib-tool (func_import): Remember the --with-tests command-line
1221         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
1222         Reported by Eric Blake.
1223
1224 2007-05-28  Bruno Haible  <bruno@clisp.org>
1225
1226         * modules/ftell-tests: New file.
1227         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
1228         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
1229
1230         * lib/ftell.c: New file.
1231         * modules/ftell: New file.
1232         * m4/ftell.m4: New file.
1233         * doc/functions/ftell.texi: Update.
1234         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
1235         REPLACE_FTELL.
1236         * lib/stdio_.h (rpl_ftell): New declaration.
1237         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
1238         REPLACE_FTELL.
1239
1240 2007-05-28  Eric Blake  <ebb9@byu.net>
1241
1242         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
1243
1244 2007-05-28  Bruno Haible  <bruno@clisp.org>
1245
1246         * modules/fseek-tests: New file.
1247         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
1248         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
1249
1250         * lib/fseek.c: New file.
1251         * modules/fseek: New file.
1252         * m4/fseek.m4: New file.
1253         * doc/functions/fseek.texi: Update.
1254         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
1255         REPLACE_FSEEK.
1256         * lib/stdio_.h (rpl_fseek): New declaration.
1257         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
1258         REPLACE_FSEEK.
1259
1260 2007-05-28  Bruno Haible  <bruno@clisp.org>
1261
1262         * lib/stdio_.h (fflush): More comments.
1263
1264 2007-05-28  Bruno Haible  <bruno@clisp.org>
1265
1266         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
1267         runtime test.
1268
1269 2007-05-28  Eric Blake  <ebb9@byu.net>
1270
1271         Improve lseek module.
1272         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
1273         * lib/unistd_.h (lseek): Scale back link warning message.
1274         * tests/test-lseek.c: Beef up test.
1275         * tests/test-lseek.sh: Exercise more facets of lseek.
1276         Reported by Bruno Haible.
1277
1278 2007-05-28  Bruno Haible  <bruno@clisp.org>
1279
1280         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
1281         to define.
1282
1283 2007-05-27  Bruno Haible  <bruno@clisp.org>
1284
1285         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
1286
1287 2007-05-27  Bruno Haible  <bruno@clisp.org>
1288
1289         * modules/openmp: New file.
1290         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
1291         Noah Misch.
1292
1293 2007-05-26  Bruno Haible  <bruno@clisp.org>
1294
1295         * modules/chdir-long (Depends-on): Add fchdir.
1296         * modules/chdir-safer (Depends-on): Likewise.
1297         * modules/fts (Depends-on): Likewise.
1298         * modules/fts-lgpl (Depends-on): Likewise.
1299         * modules/openat (Depends-on): Likewise.
1300         * modules/savewd (Depends-on): Likewise.
1301
1302 2007-05-24  Eric Blake  <ebb9@byu.net>
1303
1304         Fix lseek on mingw.
1305         * modules/lseek: New module.
1306         * m4/lseek.m4: New file.
1307         * lib/lseek.c: New file.
1308         * modules/lseek-tests: New file.
1309         * tests/test-lseek.c: New file.
1310         * tests/test-lseek.sh: New file.
1311         * MODULES.html.sh: Document lseek module.
1312         * modules/fflush (Depends-on): Add lseek, fseeko.
1313         * modules/fseeko (Depends-on): Likewise.
1314         * modules/ftello (Depends-on): Likewise.
1315         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
1316         broken.
1317         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
1318         broken.
1319         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
1320         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
1321         * lib/ftello.c (rpl_ftello): Likewise.
1322         * tests/test-fseeko.c (main): Test this.
1323         * tests/test-fseeko.sh: Likewise.
1324         * tests/test-ftello.c (main): Likewise.
1325         * tests/test-ftello.sh: Likewise.
1326         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
1327         implies replacing fseek.
1328         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
1329         HAVE_FTELLO.
1330         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
1331         * modules/unistd (Makefile.am): Likewise.
1332         * lib/unistd_.h (lseek): Declare a replacement.
1333         * doc/functions/lseek.texi (lseek): Document this fix.
1334         * doc/functions/fseek.texi (fseek): Likewise.
1335         * doc/functions/ftell.texi (ftell): Likewise.
1336
1337 2007-05-24  Bruno Haible  <bruno@clisp.org>
1338
1339         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
1340         in the printed representation of a NaN.
1341         * tests/test-vasprintf-posix.c (test_function): Likewise.
1342         * tests/test-snprintf-posix.h (test_function): Likewise.
1343         * tests/test-sprintf-posix.h (test_function): Likewise.
1344         Reported by Eric Blake.
1345
1346 2007-05-23  Eric Blake  <ebb9@byu.net>
1347
1348         Fix fseeko/ftello on cygwin 1.5.24.
1349         * doc/functions/fseeko.texi (fseeko): Document the fix.
1350         * doc/functions/ftello.texi (ftello): Document the fix.
1351         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
1352         * doc/functions/stdout.text (stdout): New file.
1353         * doc/functions/stderr.text (stderr): New file.
1354         * doc/gnulib.texi (Function Substitutes): Use new files.
1355         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
1356         prior to 1.7.0.
1357         * tests/test-ftello.c (main): Likewise for ftello.
1358         * tests/test-fseeko.sh: New file.
1359         * tests/test-ftello.sh: New file.
1360         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
1361         with seekable stdin.
1362         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
1363         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
1364         (gl_REPLACE_FSEEKO): New macro.
1365         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
1366         * modules/fseeko (Files): Distribute fseeko.c.
1367         * modules/ftello (Files): Distribute ftello.c.
1368         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
1369         mode.
1370         * lib/ftello.c (rpl_ftello): New file.
1371         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
1372         fseeko, ftello.
1373         (gl_STDIN_LARGE_OFFSET): New macro.
1374         * modules/stdio (Makefile.am): Perform the replacement.
1375         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
1376
1377 2007-05-23  Bruno Haible  <bruno@clisp.org>
1378
1379         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
1380         GNULIB_POSIXCHECK is defined.
1381
1382 2007-05-21  Bruno Haible  <bruno@clisp.org>
1383
1384         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
1385         Check also the output for NaN arguments. When cross-compiling, guess
1386         no on IRIX.
1387         * lib/vasnprintf.c: Update comments.
1388         * tests/test-vasnprintf-posix.c (strisnan): New function.
1389         (test_function): Use it.
1390         * tests/test-vasprintf-posix.c (strisnan): New function.
1391         (test_function): Use it.
1392         * tests/test-snprintf-posix.h (strisnan): New function.
1393         (test_function): Use it.
1394         * tests/test-sprintf-posix.h (strisnan): New function.
1395         (test_function): Use it.
1396         Reported by Eric Blake.
1397
1398 2007-05-20  Bruno Haible  <bruno@clisp.org>
1399
1400         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
1401         numbers that fails on BeOS.
1402         * doc/functions/frexpl.texi: Update.
1403
1404 2007-05-20  Jim Meyering  <jim@meyering.net>
1405
1406         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
1407         forced upon us by glibc-2.6.
1408
1409 2007-05-20  Bruno Haible  <bruno@clisp.org>
1410
1411         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
1412         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
1413         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
1414         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
1415         NEED_PRINTF_INFINITE.
1416         (is_infinitel): New function.
1417         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
1418         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
1419         gl_PREREQ_VASNPRINTF_INFINITE.
1420         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
1421         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1422         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
1423         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
1424         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
1425         gl_PREREQ_VASNPRINTF_INFINITE.
1426         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1427         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1428         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1429         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1430         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1431         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1432         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1433         * doc/functions/fprintf.texi: Update.
1434         * doc/functions/printf.texi: Update.
1435         * doc/functions/snprintf.texi: Update.
1436         * doc/functions/sprintf.texi: Update.
1437         * doc/functions/vfprintf.texi: Update.
1438         * doc/functions/vprintf.texi: Update.
1439         * doc/functions/vsnprintf.texi: Update.
1440         * doc/functions/vsprintf.texi: Update.
1441
1442 2007-05-20  Bruno Haible  <bruno@clisp.org>
1443
1444         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
1445         was not found in libc.
1446         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
1447
1448 2007-05-20  Bruno Haible  <bruno@clisp.org>
1449
1450         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1451         printed as "-nan" instead of "nan".
1452         * tests/test-vasprintf-posix.c (test_function): Likewise.
1453         * tests/test-snprintf-posix.h (test_function): Likewise.
1454         * tests/test-sprintf-posix.h (test_function): Likewise.
1455         Needed for HP-UX 11.
1456
1457 2007-05-20  Jim Meyering  <jim@meyering.net>
1458
1459         Fix buggy test for the fchownat-deref bug.
1460         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
1461         symlink required for the run-test.  Without it, this test would
1462         always declare that fchownat doesn't work, and client code would
1463         unnecessarily use the replacement function with fixed libc.
1464         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
1465         Reported by Greg Schafer.
1466
1467 2007-05-19  Bruno Haible  <bruno@clisp.org>
1468
1469         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
1470         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
1471         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
1472         Needed for IRIX 6.5 and Solaris 2.5.1.
1473
1474 2007-05-19  Bruno Haible  <bruno@clisp.org>
1475
1476         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
1477         (test_function): Skip tests involving -0.0 on platforms where
1478         -0.0 = 0.0.
1479         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
1480         (test_function): Skip tests involving -0.0 on platforms where
1481         -0.0 = 0.0.
1482         * tests/test-snprintf-posix.h (have_minus_zero): New function.
1483         (test_function): Skip tests involving -0.0 on platforms where
1484         -0.0 = 0.0.
1485         * tests/test-sprintf-posix.h (have_minus_zero): New function.
1486         (test_function): Skip tests involving -0.0 on platforms where
1487         -0.0 = 0.0.
1488         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
1489         tests.
1490         * tests/test-printf-posix.h (test_function): Likewise.
1491         * tests/test-printf-posix.output: Remove all -0.0 related results.
1492         Needed for IRIX 6.5.
1493
1494 2007-05-19  Bruno Haible  <bruno@clisp.org>
1495
1496         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1497         printed as "nan0x7fffffff" instead of "nan".
1498         * tests/test-vasprintf-posix.c (test_function): Likewise.
1499         * tests/test-snprintf-posix.h (test_function): Likewise.
1500         * tests/test-sprintf-posix.h (test_function): Likewise.
1501         * tests/test-fprintf-posix.h (NaN): Remove macro.
1502         (test_function): Remove all NaN related tests.
1503         * tests/test-printf-posix.h (NaN): Remove macro.
1504         (test_function): Remove all NaN related tests.
1505         * tests/test-printf-posix.output: Remove all NaN related results.
1506         Needed for IRIX 6.5.
1507
1508 2007-05-19  Bruno Haible  <bruno@clisp.org>
1509
1510         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
1511         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
1512
1513 2007-05-19  Bruno Haible  <bruno@clisp.org>
1514
1515         * lib/float_.h: New file.
1516         * m4/float_h.m4: New file.
1517         * modules/float: New file.
1518         * modules/isnanl (Dependencies): Add float.
1519         * modules/isnanl-nolibm (Dependencies): Likewise.
1520         * modules/mathl (Dependencies): Likewise.
1521         * modules/printf-frexpl (Dependencies): Likewise.
1522         * modules/signbit (Dependencies): Likewise.
1523         * modules/vasnprintf (Dependencies): Likewise.
1524         * doc/headers/float.texi: Update.
1525
1526 2007-05-19  Jim Meyering  <jim@meyering.net>
1527
1528         * lib/utimens.c (gl_futimens): Rename from futimens,
1529         now that glibc-2.6 declares futimens.
1530         * lib/utimens.h: Likewise.
1531
1532 2007-05-19  Bruno Haible  <bruno@clisp.org>
1533
1534         Avoid test failures on mingw.
1535         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
1536         * tests/test-printf-posix.sh: Likewise.
1537         * tests/test-vfprintf-posix.sh: Likewise.
1538         * tests/test-vprintf-posix.sh: Likewise.
1539
1540 2007-05-19  Bruno Haible  <bruno@clisp.org>
1541
1542         Fix *printf result for NaN, Inf, -0.0 on mingw.
1543         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
1544         * lib/vasnprintf.c: Include math.h and isnan.h.
1545         (is_infinite_or_zero): New function.
1546         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
1547         values in the %f, %F, %e, %E, %g, %G directives.
1548         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
1549         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1550         gl_PRINTF_INFINITE and test its result. Invoke
1551         gl_PREREQ_VASNPRINTF_INFINITE.
1552         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1553         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1554         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1555         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1556         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1557         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1558         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1559         * doc/functions/fprintf.texi: Update.
1560         * doc/functions/printf.texi: Update.
1561         * doc/functions/snprintf.texi: Update.
1562         * doc/functions/sprintf.texi: Update.
1563         * doc/functions/vfprintf.texi: Update.
1564         * doc/functions/vprintf.texi: Update.
1565         * doc/functions/vsnprintf.texi: Update.
1566         * doc/functions/vsprintf.texi: Update.
1567
1568 2007-05-19  Bruno Haible  <bruno@clisp.org>
1569
1570         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
1571         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
1572         Instead of multiplying with 10^k, set extra_zeroes to k.
1573         (scale10_round_long_double): Remove function.
1574
1575 2007-05-18  Bruno Haible  <bruno@clisp.org>
1576
1577         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
1578         introduced on 2007-05-06.
1579
1580 2007-05-18  Bruno Haible  <bruno@clisp.org>
1581
1582         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
1583         %g directives.
1584         * tests/test-vasprintf-posix.c (test_function): Likewise.
1585         * tests/test-snprintf-posix.h (test_function): Likewise.
1586         * tests/test-sprintf-posix.h (test_function): Likewise.
1587
1588 2007-05-18  Bruno Haible  <bruno@clisp.org>
1589
1590         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
1591         (strmatch): New function.
1592         (test_function): Test the %f directive on numbers of various exponents.
1593         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
1594         (strmatch): New function.
1595         (test_function): Test the %f directive on numbers of various exponents.
1596         * tests/test-snprintf-posix.h (strmatch): New function.
1597         (test_function): Test the %f directive on numbers of various exponents.
1598         * tests/test-sprintf-posix.h (strmatch): New function.
1599         (test_function): Test the %f directive on numbers of various exponents.
1600         * tests/test-snprintf-posix.c (SIZEOF): New macro.
1601         * tests/test-sprintf-posix.c (SIZEOF): New macro.
1602         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
1603         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
1604
1605 2007-05-18  Bruno Haible  <bruno@clisp.org>
1606
1607         Add support for 'long double' number output.
1608         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
1609         * lib/vasnprintf.c: Include math.h and float+.h.
1610         (mp_limb_t): New type.
1611         (GMP_LIMB_BITS): New macro.
1612         (mp_twolimb_t): New type.
1613         (GMP_TWOLIMB_BITS): New macro.
1614         (mpn_t): New type.
1615         (multiply, divide, convert_to_decimal, decode_long_double,
1616         scale10_round_long_double, scale10_round_decimal_long_double,
1617         floorlog10l): New functions.
1618         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
1619         for the %f, %F, %e, %E, %g, %G directives.
1620         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
1621         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1622         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
1623         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
1624         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1625         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1626         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1627         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1628         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1629         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1630         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1631         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
1632         * modules/snprintf-posix (Depends-on): Likewise.
1633         * modules/sprintf-posix (Depends-on): Likewise.
1634         * modules/vasnprintf-posix (Depends-on): Likewise.
1635         * modules/vasprintf-posix (Depends-on): Likewise.
1636         * modules/vfprintf-posix (Depends-on): Likewise.
1637         * modules/vsnprintf-posix (Depends-on): Likewise.
1638         * modules/vsprintf-posix (Depends-on): Likewise.
1639         * modules/vasnprintf (Files): Add lib/float+.h.
1640         * doc/functions/fprintf.texi: Update.
1641         * doc/functions/printf.texi: Update.
1642         * doc/functions/snprintf.texi: Update.
1643         * doc/functions/sprintf.texi: Update.
1644         * doc/functions/vfprintf.texi: Update.
1645         * doc/functions/vprintf.texi: Update.
1646         * doc/functions/vsnprintf.texi: Update.
1647         * doc/functions/vsprintf.texi: Update.
1648
1649 2007-05-18  Bruno Haible  <bruno@clisp.org>
1650
1651         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
1652
1653 2007-05-18  Bruno Haible  <bruno@clisp.org>
1654
1655         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
1656         for printing 64-bit integers. Needed for mingw.
1657
1658 2007-05-18  Bruno Haible  <bruno@clisp.org>
1659
1660         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
1661         gl_FUNC_FREXPL_WORKS.
1662         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
1663
1664 2007-05-18  Bruno Haible  <bruno@clisp.org>
1665
1666         * modules/frexpl-nolibm-tests: New file.
1667
1668         * modules/frexpl-nolibm: New file.
1669         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
1670
1671 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
1672
1673         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
1674         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
1675         GCC 4.2, which otherwise issues a lot of warnings.
1676         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
1677         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
1678         Likewise.
1679         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
1680         * modules/iconv_open (iconv.h): Likewise.
1681         * modules/locale (locale.h): Likewise.
1682         * modules/netinet_in (netinet/in.h): Likewise.
1683         * modules/sys_select (sys_select.h): Likewise.
1684         * modules/sys_socket (sys/socket.h): Likewise.
1685         * modules/sys_stat (sys/stat.h): Likewise.
1686         * modules/sysexits (sysexits.h): Likewise.
1687         * modules/unistd (unistd.h): Likewise.
1688
1689 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1690
1691         * modules/closein-tests (Makefile.am): Distribute
1692         `test-closein.sh'.
1693
1694 2007-05-17  Bruno Haible  <bruno@clisp.org>
1695
1696         * tests/test-printf-posix.output: Renamed from
1697         tests/test-fprintf-posix.out.
1698         * modules/fprintf-posix-tests: Update.
1699         * modules/printf-posix-tests: Update.
1700         * modules/vfprintf-posix-tests: Update.
1701         * modules/vprintf-posix-tests: Update.
1702         * tests/test-fprintf-posix.sh: Update.
1703         * tests/test-printf-posix.sh: Update.
1704         * tests/test-vfprintf-posix.sh: Update.
1705         * tests/test-vprintf-posix.sh: Update.
1706         Reported by Ralf Wildenhues.
1707
1708 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
1709
1710         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
1711         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
1712         GCC 4.2, which otherwise issues a lot of warnings.
1713         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
1714         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
1715         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
1716         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
1717         it should no longer be needed.
1718         * lib/string_.h: Likewise.
1719         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
1720         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
1721         * modules/inttypes (inttypes.h): Likewise.
1722         * modules/math (math.h): Likewise.
1723         * modules/search (search.h): Likewise.
1724         * modules/signal (signal.h): Likewise.
1725         * modules/stdint (stdint.h): Likewise.
1726         * modules/stdio (stdio.h): Likewise.
1727         * modules/stdlib (stdlib.h): Likewise.
1728         * modules/string (string.h): Likewise.
1729         * modules/sys_time (sys/time.h): Likewise.
1730         * modules/time (time.h): Likewise.
1731         * modules/wchar (wchar.h): Likewise.
1732         * modules/wctype (wtype.h): Likewise.
1733
1734 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
1735
1736         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
1737
1738 2007-05-13  Bruno Haible  <bruno@clisp.org>
1739
1740         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
1741         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
1742         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
1743         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
1744         (gl_PREREQ_STRTOK_R): Don't require it here.
1745
1746 2007-05-13  Bruno Haible  <bruno@clisp.org>
1747
1748         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
1749         when used in C++ mode.
1750
1751 2007-05-12  Bruno Haible  <bruno@clisp.org>
1752
1753         * lib/linebuffer.h: Tweak doc.
1754         * lib/linebuffer.c: Likewise.
1755
1756 2007-05-12  James Youngman  <jay@gnu.org>
1757
1758         * lib/linebuffer.c (readlinebuffer_delim): New function,
1759         like readlinebuffer, but use a caller-specified delimiter.
1760         (readlinebuffer): Just call readlinebuffer_delim with '\n'
1761         as the delimiter.
1762         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
1763
1764 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
1765
1766         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
1767         * modules/openat (Files): Remove openat-die.c.
1768         (Depends-on): Add openat-die.
1769         * modules/openat-die: New module.
1770
1771 2007-05-06  Bruno Haible  <bruno@clisp.org>
1772
1773         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
1774         Update with info about Cygwin.
1775         * doc/functions/fprintf.texi: Update.
1776         * doc/functions/printf.texi: Update.
1777         * doc/functions/snprintf.texi: Update.
1778         * doc/functions/sprintf.texi: Update.
1779         * doc/functions/vfprintf.texi: Update.
1780         * doc/functions/vprintf.texi: Update.
1781         * doc/functions/vsnprintf.texi: Update.
1782         * doc/functions/vsprintf.texi: Update.
1783         Reported by Eric Blake.
1784
1785 2007-05-06  Bruno Haible  <bruno@clisp.org>
1786
1787         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
1788         padding ourselves for the floating-point directives.
1789         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
1790         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
1791         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
1792         gl_PRINTF_FLAG_ZERO and test its result. Invoke
1793         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
1794         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1795         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
1796         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1797         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1798         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1799         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1800         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1801         * tests/test-snprintf-posix.h (test_function): Also check the width
1802         and some flags in the %f directive.
1803         * tests/test-sprintf-posix.h (test_function): Likewise.
1804         * tests/test-vasnprintf-posix.c (test_function): Likewise.
1805         * tests/test-vasprintf-posix.c (test_function): Likewise.
1806         * doc/functions/fprintf.texi: Update.
1807         * doc/functions/printf.texi: Update.
1808         * doc/functions/snprintf.texi: Update.
1809         * doc/functions/sprintf.texi: Update.
1810         * doc/functions/vfprintf.texi: Update.
1811         * doc/functions/vprintf.texi: Update.
1812         * doc/functions/vsnprintf.texi: Update.
1813         * doc/functions/vsprintf.texi: Update.
1814
1815 2007-05-06  Bruno Haible  <bruno@clisp.org>
1816
1817         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
1818         pass the ' flag character to sprintf or snprintf.
1819         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
1820         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
1821         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
1822         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
1823         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
1824         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1825         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
1826         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1827         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1828         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1829         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1830         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1831         * tests/test-snprintf-posix.h (test_function): Also check the grouping
1832         flag.
1833         * tests/test-sprintf-posix.h (test_function): Likewise.
1834         * tests/test-vasnprintf-posix.c (test_function): Likewise.
1835         * tests/test-vasprintf-posix.c (test_function): Likewise.
1836         * doc/functions/fprintf.texi: Update.
1837         * doc/functions/printf.texi: Update.
1838         * doc/functions/snprintf.texi: Update.
1839         * doc/functions/sprintf.texi: Update.
1840         * doc/functions/vfprintf.texi: Update.
1841         * doc/functions/vprintf.texi: Update.
1842         * doc/functions/vsnprintf.texi: Update.
1843         * doc/functions/vsprintf.texi: Update.
1844
1845 2007-05-01  Bruno Haible  <bruno@clisp.org>
1846
1847         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
1848
1849 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
1850
1851         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
1852         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
1853
1854 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
1855
1856         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
1857         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
1858         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
1859
1860 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
1861
1862         * lib/argp-help.c (struct hol_entry): New member `ord'.
1863         (HOL_ENTRY_PTRCMP): Use ord for comparison
1864         (hol_sort): Initialize ord.
1865
1866 2007-05-01  Bruno Haible  <bruno@clisp.org>
1867
1868         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
1869         Reported by Eric Blake.
1870         * doc/gnulib.texi (Function Substitutes): Update.
1871
1872 2007-05-01  Bruno Haible  <bruno@clisp.org>
1873
1874         * doc/functions.texi: Remove file, now redundant through
1875         doc/functions/*.texi.
1876
1877 2007-05-01  Bruno Haible  <bruno@clisp.org>
1878
1879         * modules/argp (Depends-on): Add sleep.
1880
1881 2007-05-01  Bruno Haible  <bruno@clisp.org>
1882
1883         * modules/sleep-tests: New file.
1884         * tests/test-sleep.c: New file.
1885
1886         * modules/sleep: New file.
1887         * lib/sleep.c: New file.
1888         * m4/sleep.m4: New file.
1889         * lib/unistd_.h (sleep): New declaration.
1890         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
1891         HAVE_SLEEP.
1892         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
1893         * doc/functions/sleep.texi: Document the sleep module.
1894
1895 2007-05-01  Bruno Haible  <bruno@clisp.org>
1896
1897         * lib/sigprocmask.h: Remove file.
1898         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
1899         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
1900         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
1901         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
1902         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
1903         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
1904         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
1905         HAVE_SIGSET_T as a shell variable.
1906         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
1907         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
1908         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
1909         (Depends-on): Add signal. Remove verify.
1910         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
1911         (Include): Mention <signal.h> instead of sigprocmask.h.
1912         * NEWS: Mention the change.
1913         * lib/fatal-signal.c: Don't include sigprocmask.h.
1914
1915 2007-05-01  Bruno Haible  <bruno@clisp.org>
1916
1917         * modules/signal: New file.
1918         * lib/signal_.h: New file.
1919         * m4/signal_h.m4: New file.
1920
1921 2007-05-01  Bruno Haible  <bruno@clisp.org>
1922
1923         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
1924         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
1925         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
1926         HAVE_WCTYPE_CTMP_BUG into wctype.h.
1927
1928 2007-05-01  Bruno Haible  <bruno@clisp.org>
1929
1930         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
1931         configure time.
1932         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
1933         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
1934         * modules/sys_stat (Makefile.am): Substitute their values into
1935         sys/stat.h.
1936
1937 2007-05-01  Bruno Haible  <bruno@clisp.org>
1938
1939         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
1940         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
1941         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
1942
1943 2007-05-01  Bruno Haible  <bruno@clisp.org>
1944
1945         * doc/header/assert.texi: Undo last change: don't mention the gnulib
1946         'assert' module here.
1947
1948 2007-05-01  Bruno Haible  <bruno@clisp.org>
1949
1950         * doc/functions/*.texi: New files.
1951         * doc/functions/google-ranking.txt: New file.
1952         * doc/gnulib.texi (Function Substitutes): New chapter.
1953         (ctime, inet_ntoa): Remove sections.
1954         * doc/ctime.texi: Remove file.
1955         * doc/inet_ntoa.texi: Remove file.
1956         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
1957         dependencies.
1958         (%.info): New rule, specifying a --reference-limit.
1959
1960 2007-05-01  Bruno Haible  <bruno@clisp.org>
1961
1962         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
1963
1964 2007-05-01  Bruno Haible  <bruno@clisp.org>
1965
1966         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
1967         the portability of 'mkdir' to mingw systems.
1968
1969 2007-05-01  Bruno Haible  <bruno@clisp.org>
1970
1971         * doc/headers/google-ranking.txt: New file.
1972
1973 2007-04-30  Eric Blake  <ebb9@byu.net>
1974
1975         Prefer fseeko to fseek.
1976         * modules/getpass (Depends-on): Add fseeko.
1977         * lib/getpass.c (getpass): Use fseeko, not fseek.
1978
1979 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
1980
1981         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
1982         assumes the sorting is stable, while most qsort implementations
1983         are not.  Use argument addresses to ensure they never compare as
1984         equal.
1985
1986         * tests/test-argp-2.sh (usage-indent test): Fix output
1987         (func_compare): Restore diff options
1988         * tests/test-argp.c: Restore #include "progname.h"
1989
1990 2007-04-29  Bruno Haible  <bruno@clisp.org>
1991
1992         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
1993         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
1994         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
1995         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1996         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
1997         (configure.ac): Define CHECK_SNPRINTF_POSIX.
1998         (TESTS, check_PROGRAMS): Add test-snprintf.
1999         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
2000         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
2001         (TESTS, check_PROGRAMS): Add test-vsnprintf.
2002         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
2003         assertions that fail on HP-UX, OSF/1, or IRIX.
2004         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
2005
2006 2007-04-29  Bruno Haible  <bruno@clisp.org>
2007
2008         * MODULES.html.sh (posix_functions): Remove 'contents'.
2009
2010 2007-04-29  Karl Berry  <karl@gnu.org>
2011
2012         * config/srclist.txt (gendocs_template_min): new entry.
2013
2014 2007-04-29  Bruno Haible  <bruno@clisp.org>
2015
2016         Work around fpurge bug on BSD systems.
2017         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
2018         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
2019         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
2020         fpurge to rpl_fpurge if the system already has this function.
2021         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
2022         the case where the system already has this function. Correct invariants
2023         on BSD systems.
2024         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
2025         BSD systems.
2026
2027 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
2028
2029         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
2030         proposed by Sven Verdoolaege.
2031
2032         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
2033         options.
2034         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
2035         (usage and help tests): Update
2036
2037 2007-04-29  Bruno Haible  <bruno@clisp.org>
2038
2039         * tests/test-fflush.c (main): Use a file of size 17, not 10.
2040         Print more information in case of failure. Disable a test on BeOS.
2041
2042 2007-04-29  Bruno Haible  <bruno@clisp.org>
2043
2044         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
2045         This helps debugging on systems on which no gdb is available.
2046
2047 2007-04-29  Bruno Haible  <bruno@clisp.org>
2048
2049         * lib/freading.h: Improve comments.
2050         * lib/fwriting.h: Likewise.
2051         * tests/test-freading.c (main): Don't check freading immediately after
2052         repositioning. Needed for glibc.
2053
2054 2007-04-29  Bruno Haible  <bruno@clisp.org>
2055
2056         * lib/freading.c (freading): Trivial simplification.
2057
2058 2007-04-28  Bruno Haible  <bruno@clisp.org>
2059
2060         * tests/test-fwriting.c (main): Also test the interaction between
2061         fflush and fwriting.
2062         * modules/fwriting-tests (Depends-on): Add fflush.
2063
2064         * tests/test-freading.c (main): Also test the interaction between
2065         fflush and freading.
2066         * modules/freading-tests (Depends-on): Add fflush.
2067
2068 2007-04-28  Bruno Haible  <bruno@clisp.org>
2069
2070         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
2071         fseeko and ftello.
2072         Suggested by Eric Blake.
2073
2074 2007-04-28  Jim Meyering  <jim@meyering.net>
2075
2076         Avoid false-negative in gl_STDINT_H's C99 conformance test.
2077         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
2078         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
2079
2080 2007-04-27  Eric Blake  <ebb9@byu.net>
2081
2082         * doc/headers/assert.texi (assert.h): Document assert module use.
2083
2084 2007-04-27  Bruno Haible  <bruno@clisp.org>
2085
2086         * doc/headers/*.texi: New files.
2087         * doc/gnulib.texi (Header File Substitutes): New chapter.
2088         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
2089         dependencies.
2090         (standards.info ,standards.html, standards.dvi): Update dependencies.
2091         (mostlyclean, clean): New targets.
2092
2093 2007-04-27  Bruno Haible  <bruno@clisp.org>
2094
2095         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
2096         * modules/sysexits (Files, Makefile.am): Update.
2097
2098         * lib/sys_socket_.h: Renamed from lib/socket_.h.
2099         * modules/sys_socket (Files, Makefile.am): Update.
2100
2101         * lib/sys_stat_.h: Renamed from lib/stat_.h.
2102         * modules/sys_stat (Files, Makefile.am): Update.
2103
2104 2007-04-27  Eric Blake  <ebb9@byu.net>
2105
2106         * lib/freading.h: Improve comments.
2107         * lib/fwriting.h: Likewise.
2108         * lib/fflush.c: Likewise.
2109
2110         Fix closein for mingw.
2111         * modules/closein-tests: Add tests for closein.
2112         * tests/test-closein.c: New file.
2113         * tests/test-closein.sh: Likewise.
2114         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
2115         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
2116
2117 2007-04-27  Bruno Haible  <bruno@clisp.org>
2118
2119         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
2120         version is < 6.
2121         * lib/math_.h [__DECC]: Likewise.
2122         * lib/stdio_.h [__DECC]: Likewise.
2123         * lib/stdlib_.h [__DECC]: Likewise.
2124         * lib/string_.h [__DECC]: Likewise.
2125         * lib/time_.h [__DECC]: Likewise.
2126         * lib/wchar_.h [__DECC]: Likewise.
2127         * lib/wctype_.h [__DECC]: Likewise.
2128
2129 2007-04-27  Bruno Haible  <bruno@clisp.org>
2130
2131         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
2132
2133 2007-04-27  Bruno Haible  <bruno@clisp.org>
2134
2135         * lib/fflush.c: Add comments.
2136         * modules/fpurge-tests (Depends-on): Add fflush.
2137         * modules/freadable-tests (Depends-on): Likewise.
2138         * modules/fwritable-tests (Depends-on): Likewise.
2139
2140 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
2141
2142         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
2143         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
2144         Report by Bruno Haible <bruno@clisp.org>.
2145
2146 2007-04-26  Eric Blake  <ebb9@byu.net>
2147
2148         Fix fflush on mingw.
2149         * modules/fflush (Depends-on): Add freading.
2150         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
2151         but unread data.
2152
2153 2007-04-26  Eric Blake  <ebb9@byu.net>
2154         and Bruno Haible  <bruno@clisp.org>
2155
2156         Implement freading and fwriting.
2157         * lib/freading.c: New file.
2158         * lib/freading.h: Likewise.
2159         * m4/freading.m4: Likewise.
2160         * modules/freading: Likewise.
2161         * modules/freading-tests: Likewise.
2162         * tests/test-freading.c: Likewise.
2163         * lib/fwriting.c: New file.
2164         * lib/fwriting.h: Likewise.
2165         * m4/fwriting.m4: Likewise.
2166         * modules/fwriting: Likewise.
2167         * modules/fwriting-tests: Likewise.
2168         * tests/test-fwriting.c: Likewise.
2169         * MODULES.html.sh (File stream based Input/Output): Mention them.
2170
2171 2007-04-26  Bruno Haible  <bruno@clisp.org>
2172
2173         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
2174         'long' when we assume it.
2175         Suggested by Eric Blake.
2176
2177 2007-04-26  Bruno Haible  <bruno@clisp.org>
2178
2179         Ensure fseeko, ftello are declared on glibc systems.
2180         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
2181         * modules/fseeko (configure.ac-early): Likewise.
2182         * modules/ftello (configure.ac-early): Likewise.
2183         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
2184         AC_FUNC_FSEEKO for this.
2185         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
2186         (gl_CHECK_FSEEKO): Remove macro.
2187
2188 2007-04-26  Bruno Haible  <bruno@clisp.org>
2189
2190         * tests/test-fflush.c (main): Also check the ftell result after
2191         fflush and fseek/fseeko.
2192         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
2193         file descriptor position cache in the stream.
2194         * lib/fseeko.c (rpl_fseeko): Likewise.
2195
2196 2007-04-26  Bruno Haible  <bruno@clisp.org>
2197
2198         * modules/fflush-tests (Depends-on): Add fseeko.
2199
2200 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
2201             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2202
2203         * lib/argz_.h: ensure error_t definition is obtained in same
2204         mechanism system argz.h would have.
2205         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
2206         argz facilities are known bad.  Err on the side of caution if
2207         cross-compiling.
2208
2209 2007-04-25  Eric Blake  <ebb9@byu.net>
2210
2211         * lib/fpurge.c (includes): Use stdlib.h for free.
2212         * tests/test-fflush.c (main): Also test fflush-fseeko.
2213
2214 2007-04-25  Bruno Haible  <bruno@clisp.org>
2215
2216         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
2217         * lib/fseeko.c: New file.
2218         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
2219         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
2220         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
2221         gl_FUNC_FSEEKO.
2222         (gl_FUNC_FSEEKO): Invoke it.
2223         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
2224         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
2225         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
2226
2227 2007-04-25  Bruno Haible  <bruno@clisp.org>
2228
2229         * modules/fflush (Depends-on): Add ftello.
2230
2231 2007-04-25  Bruno Haible  <bruno@clisp.org>
2232
2233         * modules/ftello-tests: New file.
2234         * tests/test-ftello.c: New file.
2235
2236         * modules/ftello: New file.
2237         * m4/ftello.m4: New file.
2238         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
2239         HAVE_FTELLO.
2240         * lib/stdio_.h (ftello): New declaration.
2241         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
2242         HAVE_FTELLO.
2243
2244 2007-04-25  Bruno Haible  <bruno@clisp.org>
2245
2246         * modules/fseeko-tests: New file.
2247         * tests/test-fseeko.c: New file.
2248
2249         * modules/fseeko: New file.
2250         * m4/fseeko.m4: New file.
2251         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
2252         HAVE_FSEEKO.
2253         * lib/stdio_.h (fseeko): New declaration.
2254         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
2255         HAVE_FSEEKO.
2256
2257 2007-04-25  Bruno Haible  <bruno@clisp.org>
2258
2259         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
2260
2261 2007-04-25  Bruno Haible  <bruno@clisp.org>
2262
2263         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
2264         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
2265         * tests/test-unistd.c: Likewise.
2266         * tests/test-fcntl.c: Likewise.
2267
2268 2007-04-23  Eric Blake  <ebb9@byu.net>
2269
2270         * lib/fflush.c: Fix missing include.
2271         Reported by Bruno Haible.
2272
2273 2007-04-23  Bruno Haible  <bruno@clisp.org>
2274
2275         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
2276         Reported by Eric Blake.
2277
2278 2007-04-23  Bruno Haible  <bruno@clisp.org>
2279
2280         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
2281
2282 2007-04-23  Bruno Haible  <bruno@clisp.org>
2283
2284         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
2285
2286 2007-04-23  Bruno Haible  <bruno@clisp.org>
2287
2288         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
2289         Needed on HP-UX 11.
2290
2291 2007-04-16  Eric Blake  <ebb9@byu.net>
2292
2293         Make fflush rely on fpurge.
2294         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
2295         open coding all variants.
2296         * modules/fflush (Depends-on): Add fpurge and unistd.
2297         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
2298         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
2299
2300         Fix --with-tests compilation on cygwin.
2301         * modules/argmatch-tests (Makefile.am): List gnulib library first
2302         in LDADD.
2303         * modules/argp-tests (Makefile.am): Likewise.
2304         * modules/array-list-tests (Makefile.am): Likewise.
2305         * modules/array-oset-tests (Makefile.am): Likewise.
2306         * modules/avltree-list-tests (Makefile.am): Likewise.
2307         * modules/avltree-oset-tests (Makefile.am): Likewise.
2308         * modules/avltreehash-list-tests (Makefile.am): Likewise.
2309         * modules/carray-list-tests (Makefile.am): Likewise.
2310         * modules/dirname-tests (Makefile.am): Likewise.
2311         * modules/frexp-tests (Makefile.am): Likewise.
2312         * modules/isnanl-tests (Makefile.am): Likewise.
2313         * modules/linked-list-tests (Makefile.am): Likewise.
2314         * modules/linkedhash-list-tests (Makefile.am): Likewise.
2315         * modules/lock-tests (Makefile.am): Likewise.
2316         * modules/rbtree-list-tests (Makefile.am): Likewise.
2317         * modules/rbtree-oset-tests (Makefile.am): Likewise.
2318         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
2319         * modules/tls-tests (Makefile.am): Likewise.
2320         * modules/tsearch-tests (Makefile.am): Likewise.
2321         * modules/xvasprintf-tests (Makefile.am): Likewise.
2322
2323         Fix fpurge for cygwin.
2324         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
2325         value.
2326         * modules/fpurge-tests (Depends-on): Clean up trash.
2327
2328 2007-04-16  Simon Josefsson  <simon@josefsson.org>
2329
2330         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
2331
2332         * m4/autobuild.m4: Re-indent.
2333
2334 2007-04-13  Bruno Haible  <bruno@clisp.org>
2335
2336         * modules/fpurge-tests: New file.
2337         * tests/test-fpurge.c: New file.
2338
2339         * modules/fpurge: New file.
2340         * lib/fpurge.h: New file.
2341         * lib/fpurge.c: New file.
2342         * m4/fpurge.m4: New file.
2343
2344 2007-04-13  Bruno Haible  <bruno@clisp.org>
2345
2346         * modules/fbufmode-tests: New file.
2347         * tests/test-fbufmode.c: New file.
2348
2349         * modules/fbufmode: New file.
2350         * lib/fbufmode.h: New file.
2351         * lib/fbufmode.c: New file.
2352         * m4/fbufmode.m4: New file.
2353
2354 2007-04-13  Bruno Haible  <bruno@clisp.org>
2355
2356         * modules/fwritable-tests: New file.
2357         * tests/test-fwritable.c: New file.
2358
2359         * modules/fwritable: New file.
2360         * lib/fwritable.h: New file.
2361         * lib/fwritable.c: New file.
2362         * m4/fwritable.m4: New file.
2363
2364 2007-04-13  Bruno Haible  <bruno@clisp.org>
2365
2366         * modules/freadable-tests: New file.
2367         * tests/test-freadable.c: New file.
2368
2369         * modules/freadable: New file.
2370         * lib/freadable.h: New file.
2371         * lib/freadable.c: New file.
2372         * m4/freadable.m4: New file.
2373
2374 2007-04-13  Bruno Haible  <bruno@clisp.org>
2375
2376         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
2377         MOSTLYCLEANFILES.
2378
2379 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
2380
2381         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
2382         gzip bootstrap.conf to avoid dragging in i18n machinery.
2383         (gnulib_tool_option): Use it.
2384
2385 2007-04-13  Bruno Haible  <bruno@clisp.org>
2386
2387         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
2388         %F directives.
2389         * tests/test-vasprintf-posix.c (test_function): Likewise.
2390         * tests/test-snprintf-posix.h (test_function): Likewise.
2391         * tests/test-sprintf-posix.h (test_function): Likewise.
2392         * tests/test-fprintf-posix.h (test_function): Likewise.
2393         * tests/test-printf-posix.h (test_function): Likewise.
2394         * tests/test-fprintf-posix.out: Likewise.
2395
2396 2007-04-13  Bruno Haible  <bruno@clisp.org>
2397
2398         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
2399         * modules/tls-tests (configure.ac): Likewise.
2400         Reported by Arto C. Nirkko <anirkko@insel.ch>.
2401
2402 2007-04-13  Bruno Haible  <bruno@clisp.org>
2403
2404         * lib/tls.c (glthread_tls_get): Fix return type.
2405         Patch by Arto C. Nirkko <anirkko@insel.ch>.
2406
2407 2007-04-12  Eric Blake  <ebb9@byu.net>
2408
2409         * modules/gettime (Depends-on): Remove gettime.
2410         Reported by Dmitry V. Levin.
2411
2412 2007-04-12  Bruno Haible  <bruno@clisp.org>
2413
2414         * modules/fflush (Include): Mention <stdio.h>.
2415         * modules/strtoimax (Include): Mention <inttypes.h>.
2416         * modules/strtoumax (Include): Likewise.
2417
2418 2007-04-12  Eric Blake  <ebb9@byu.net>
2419
2420         * .cvsignore: New file.
2421         * .gitignore: Likewise.
2422
2423 2007-04-12  Bruno Haible  <bruno@clisp.org>
2424
2425         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
2426         not before, since $(LDADD) often contains libgnu.a.
2427         * modules/striconv-tests (test_striconv_LDADD): Likewise.
2428         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
2429         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
2430         Needed on Cygwin.
2431
2432 2007-04-12  Eric Blake  <ebb9@byu.net>
2433
2434         Work around glibc's failure to flush stdin on fclose.
2435         * lib/closein.c (close_stdin): Flush stdin before closing.
2436
2437         Work around glibc's failure to reset seekable stdin on exit.
2438         * modules/closein: New module.
2439         * lib/closein.c: New file.
2440         * lib/closein.h: Likewise.
2441         * m4/closein.m4: Likewise.
2442         * MODULES.html.sh (File stream based Input/Output): Document it.
2443
2444 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2445
2446         * gnulib-tool: Rename generated 'autobuild' script to
2447         'do-autobuild' in --create-megatestdir output.
2448
2449         * doc/gnulib.texi (Build robot for gnulib): Fix.
2450
2451 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2452
2453         * modules/sysexits (Depends-on): Add absolute-header.
2454
2455 2007-04-12  Eric Blake  <ebb9@byu.net>
2456
2457         No need to preserve errno on success.
2458         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
2459         Reported by Bruno Haible.
2460
2461 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2462
2463         * MODULES.html.sh (Support for maintaining and releasing
2464         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
2465
2466 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2467
2468         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
2469
2470 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2471
2472         * modules/autobuild: New module.
2473
2474         * m4/autobuild.m4: New file.
2475
2476 2007-04-11  Bruno Haible  <bruno@clisp.org>
2477
2478         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
2479         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
2480         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
2481         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
2482         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2483         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2484         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2485         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2486         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2487         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2488         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
2489         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2490         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2491         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
2492         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2493         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2494         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
2495         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2496         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2497         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
2498         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2499         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2500         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
2501         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2502         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2503         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
2504         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2505         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2506         Reported by Eric Blake.
2507
2508 2007-04-11  Bruno Haible  <bruno@clisp.org>
2509
2510         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
2511
2512 2007-04-10  Bruno Haible  <bruno@clisp.org>
2513
2514         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
2515         for NaN and Infinity. Needed on FreeBSD 6.1.
2516         * tests/test-vasnprintf-posix.c (test_function): Undo last change
2517         regarding results for "%010a" of Infinity and NaN.
2518         * tests/test-vasprintf-posix.c (test_function): Likewise.
2519         * tests/test-snprintf-posix.h (test_function): Likewise.
2520         * tests/test-sprintf-posix.h (test_function): Likewise.
2521         * tests/test-fprintf-posix.h (test_function): Likewise.
2522         * tests/test-printf-posix.h (test_function): Likewise.
2523         * tests/test-fprintf-posix.out: Likewise.
2524
2525 2007-04-10  Bruno Haible  <bruno@clisp.org>
2526
2527         * modules/locale-tests: New file.
2528         * tests/test-locale.c: New file.
2529
2530         * modules/locale: New file.
2531         * lib/locale_.h: New file.
2532         * m4/locale_h.m4: New file.
2533
2534 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
2535             Bruno Haible  <bruno@clisp.org>
2536
2537         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
2538         be determined, test for availability of the copysignf, copysign,
2539         copysignl functions.
2540         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
2541         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
2542         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
2543
2544 2007-04-09  Eric Blake  <ebb9@byu.net>
2545
2546         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
2547         * modules/stdio (Makefile.am): Support fflush.
2548         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
2549         * modules/fflush: New file.
2550         * lib/fflush.c: Likewise.
2551         * m4/fflush.m4: Likewise.
2552         * modules/fflush-tests: New test.
2553         * tests/test-fflush.c: Likewise.
2554         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
2555
2556 2007-04-06  Bruno Haible  <bruno@clisp.org>
2557
2558         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
2559         (VASNPRINTF): Use signbit for faster determination whether to print a
2560         minus sign.
2561         * modules/vasnprintf (Files): Remove lib/float+.h.
2562         * modules/fprintf-posix (Depends-on): Add signbit.
2563         * modules/snprintf-posix (Depends-on): Likewise.
2564         * modules/sprintf-posix (Depends-on): Likewise.
2565         * modules/vasnprintf-posix (Depends-on): Likewise.
2566         * modules/vasprintf-posix (Depends-on): Likewise.
2567         * modules/vfprintf-posix (Depends-on): Likewise.
2568         * modules/vsnprintf-posix (Depends-on): Likewise.
2569         * modules/vsprintf-posix (Depends-on): Likewise.
2570
2571 2007-04-06  Bruno Haible  <bruno@clisp.org>
2572
2573         * tests/test-frexp.c (main): Test also the sign bit of zero results.
2574         * tests/test-frexpl.c (main): Likewise.
2575         * tests/test-ldexpl.c (main): Likewise.
2576         * modules/frexp-tests (Depends-on): Add signbit.
2577         * modules/frexpl-tests (Depdends-on): Likewise.
2578         * modules/ldexpl-tests (Depdends-on): Likewise.
2579
2580 2007-04-06  Bruno Haible  <bruno@clisp.org>
2581
2582         * modules/signbit-tests: New file.
2583         * tests/test-signbit.c: New file.
2584
2585         * modules/signbit: New file.
2586         * lib/signbitf.c: New file.
2587         * lib/signbitd.c: New file.
2588         * lib/signbitl.c: New file.
2589         * m4/signbit.m4: New file.
2590         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
2591         (signbit): New macro.
2592         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
2593         REPLACE_SIGNBIT.
2594         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
2595         REPLACE_FREXPL into math.h.
2596
2597 2007-04-06  Bruno Haible  <bruno@clisp.org>
2598
2599         * modules/isnanf-nolibm-tests: New file.
2600         * tests/test-isnanf.c: New file.
2601
2602         * modules/isnanf-nolibm: New file.
2603         * lib/isnanf.h: New file.
2604         * lib/isnanf.c: New file.
2605         * lib/isnan.c: Consider the USE_FLOAT macro.
2606         * m4/isnanf.m4: New file.
2607
2608 2007-04-06  Bruno Haible  <bruno@clisp.org>
2609
2610         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
2611         (Link): New section.
2612
2613         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
2614
2615 2007-04-06  Bruno Haible  <bruno@clisp.org>
2616
2617         Assume the 'long double' type.
2618         * m4/longdouble.m4: Remove file.
2619         * config/srclist.txt: Don't mention longdouble.m4.
2620         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
2621         * lib/float+.h: Likewise.
2622         * lib/frexp.c: Likewise.
2623         * lib/printf-args.h: Likewise.
2624         * lib/printf-args.c: Likewise.
2625         * lib/printf-frexp.c: Likewise.
2626         * lib/printf-parse.c: Likewise.
2627         * lib/vasnprintf.c: Likewise.
2628         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
2629         * m4/intl.m4: Likewise.
2630         * m4/isnanl.m4: Likewise.
2631         * m4/printf.m4: Likewise.
2632         * m4/printf-frexpl.m4: Likewise.
2633         * m4/vasnprintf.m4: Likewise.
2634         * modules/allocsa (Files): Remove m4/longdouble.m4.
2635         * modules/gettext (Files): Likewise.
2636         * modules/relocatable-prog-wrapper (Files): Likewise.
2637         * modules/vasnprintf (Files): Likewise.
2638         * modules/isnanl (Files): Likewise.
2639         (Include): Simplify.
2640         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
2641         (Include): Simplify.
2642         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
2643         (Include): Simplify.
2644         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
2645         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2646         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
2647         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2648         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
2649         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2650         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
2651         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2652         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
2653         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2654         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
2655         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2656         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
2657         * tests/test-isnanl.c: Likewise.
2658         * tests/test-snprintf-posix.h: Likewise.
2659         * tests/test-sprintf-posix.h: Likewise.
2660         * tests/test-vasnprintf-posix.c: Likewise.
2661         * tests/test-vasnprintf-posix2.c: Likewise.
2662         * tests/test-vasprintf-posix.c: Likewise.
2663
2664 2007-04-06  Bruno Haible  <bruno@clisp.org>
2665
2666         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
2667         * lib/math_.h [__DECC]: Include the overridden include file through
2668         #include_next, outside the double-inclusion guard.
2669         * lib/stdio_.h [__DECC]: Likewise.
2670         * lib/stdlib_.h [__DECC]: Likewise.
2671         * lib/string_.h [__DECC]: Likewise.
2672         * lib/time_.h [__DECC]: Likewise.
2673         * lib/wchar_.h [__DECC]: Likewise.
2674         * lib/wctype_.h [__DECC]: Likewise.
2675         * lib/inttypes_.h [__DECC]: Likewise.
2676         Reported by Albert Chin <china@thewrittenword.com> in
2677         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
2678
2679 2007-04-04  Eric Blake  <ebb9@byu.net>
2680
2681         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
2682         1.5.x.
2683
2684 2007-04-04  Bruno Haible  <bruno@clisp.org>
2685
2686         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
2687         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
2688
2689 2007-04-04  Bruno Haible  <bruno@clisp.org>
2690
2691         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
2692         results for "%010a" of Infinity and NaN.
2693         * tests/test-vasprintf-posix.c (test_function): Likewise.
2694         * tests/test-snprintf-posix.h (test_function): Likewise.
2695         * tests/test-sprintf-posix.h (test_function): Likewise.
2696         * tests/test-fprintf-posix.h (test_function): Remove these tests.
2697         * tests/test-printf-posix.h (test_function): Likewise.
2698         * tests/test-fprintf-posix.out: Update.
2699         Needed for FreeBSD 6.1.
2700
2701 2007-04-04  Bruno Haible  <bruno@clisp.org>
2702
2703         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
2704         directly used by the gnulib modules nor by gnulib-tool.
2705
2706 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
2707
2708         * DEPENDENCIES: Give overall description of version dependency
2709         desirability.  Use more-typical names for apps.
2710         Add shell, coreutils, diffutils, grep, tar, gzip.
2711
2712 2007-04-04  Simon Josefsson  <simon@josefsson.org>
2713
2714         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
2715
2716 2007-04-04  Karl Berry  <karl@gnu.org>
2717
2718         * MODULES.html.sh (func_module): missing '.
2719
2720 2007-04-03  Bruno Haible  <bruno@clisp.org>
2721
2722         * modules/argmatch-tests (Makefile.am): New variable
2723         test_argmatch_LDADD.
2724         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
2725         * modules/array-list-tests (Makefile.am): New variable
2726         test_array_list_LDADD.
2727         * modules/array-oset-tests (Makefile.am): New variable
2728         test_array_oset_LDADD.
2729         * modules/avltree-list-tests (Makefile.am): New variable
2730         test_avltree_list_LDADD.
2731         * modules/avltree-oset-tests (Makefile.am): New variable
2732         test_avltree_oset_LDADD.
2733         * modules/avltreehash-list-tests (Makefile.am): New variable
2734         test_avltreehash_list_LDADD.
2735         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
2736         test_canonicalize_lgpl_LDADD.
2737         * modules/carray-list-tests (Makefile.am): New variable
2738         test_carray_list_LDADD.
2739         * modules/dirname-tests (Makefile.am): New variable
2740         test_dirname_LDADD.
2741         * modules/linked-list-tests (Makefile.am): New variable
2742         test_linked_list_LDADD.
2743         * modules/linkedhash-list-tests (Makefile.am): New variable
2744         test_linkedhash_list_LDADD.
2745         * modules/rbtree-list-tests (Makefile.am): New variable
2746         test_rbtree_list_LDADD.
2747         * modules/rbtree-oset-tests (Makefile.am): New variable
2748         test_rbtree_oset_LDADD.
2749         * modules/rbtreehash-list-tests (Makefile.am): New variable
2750         test_rbtreehash_list_LDADD.
2751         * modules/xvasprintf-tests (Makefile.am): New variable
2752         test_xvasprintf_LDADD.
2753         Reported by Eric Blake.
2754
2755 2007-04-03  Eric Blake  <ebb9@byu.net>
2756
2757         * DEPENDENCIES: Weaken m4 requirements.
2758
2759 2007-04-03  Bruno Haible  <bruno@clisp.org>
2760
2761         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
2762         * modules/isnanl-tests (configure.ac): Likewise.
2763
2764 2007-04-03  Ben Pfaff  <blp@gnu.org>
2765
2766         * modules/iconv_open: Add $(srcdir)/ to source directory
2767         references in Makefile fragments that call gperf, to fix VPATH
2768         builds.
2769
2770 2007-04-03  Bruno Haible  <bruno@clisp.org>
2771
2772         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
2773         * lib/ldexpl.c: Undo last change.
2774
2775 2007-04-03  Bruno Haible  <bruno@clisp.org>
2776
2777         * modules/printf-frexpl (Depends-on): Undo last change.
2778         (Files): Add m4/ldexpl.m4.
2779
2780 2007-04-03  Bruno Haible  <bruno@clisp.org>
2781
2782         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
2783         * modules/isnanl (Link): New section.
2784
2785         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
2786         * modules/frexp (Link): New section.
2787
2788         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
2789         * modules/frexpl (Link): New section.
2790
2791         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
2792         * modules/ldexpl (Link): New section.
2793
2794 2007-04-03  Bruno Haible  <bruno@clisp.org>
2795
2796         * modules/TEMPLATE-EXTENDED: New file.
2797         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
2798
2799 2007-04-03  Bruno Haible  <bruno@clisp.org>
2800
2801         * DEPENDENCIES: New file.
2802         Suggested by Simon Josefsson.
2803
2804 2007-04-03  Bruno Haible  <bruno@clisp.org>
2805
2806         * doc/gnulib.texi: Escape @.
2807
2808 2007-04-03  James Youngman  <jay@gnu.org>
2809         and Paul Eggert  <eggert@cs.ucla.edu>
2810
2811         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
2812         birthtime on all systems that have birthtime, not just those which
2813         use st_birthtimensec rather than st_birthtim.  Putting zero in
2814         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
2815         that the birth time is not available for files on an NFS mount.
2816
2817 2007-04-03  Simon Josefsson  <simon@josefsson.org>
2818
2819         * modules/memxor: Move back from crypto/, suggested by Bruno.
2820         * modules/crypto/hmac-sha1: Fix memxor dependency.
2821
2822         * modules/crypto/gc: Moved from ../.
2823
2824 2007-04-02  Eric Blake  <ebb9@byu.net>
2825
2826         * lib/ldexpl.c (includes): Avoid libm.
2827
2828         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
2829
2830 2007-04-02  Bruno Haible  <bruno@clisp.org>
2831
2832         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
2833         on IRIX.
2834
2835 2007-04-02  Bruno Haible  <bruno@clisp.org>
2836
2837         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
2838         x86 or x86_64 platforms running MacOS X.
2839         Reported by Ryan Schmidt <@ryandesign.com>.
2840
2841 2007-04-02  Bruno Haible  <bruno@clisp.org>
2842
2843         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
2844         i386.
2845
2846 2007-04-01  Simon Josefsson  <simon@josefsson.org>
2847
2848         * modules/crypto/arcfour: Moved from ../.
2849         * modules/crypto/arcfour-tests: Moved from ../.
2850         * modules/crypto/arctwo: Moved from ../.
2851         * modules/crypto/arctwo-tests: Moved from ../.
2852         * modules/crypto/des: Moved from ../.
2853         * modules/crypto/des-tests: Moved from ../.
2854         * modules/crypto/gc-arcfour: Moved from ../.
2855         * modules/crypto/gc-arcfour-tests: Moved from ../.
2856         * modules/crypto/gc-arctwo: Moved from ../.
2857         * modules/crypto/gc-arctwo-tests: Moved from ../.
2858         * modules/crypto/gc-des: Moved from ../.
2859         * modules/crypto/gc-des-tests: Moved from ../.
2860         * modules/crypto/gc-hmac-md5: Moved from ../.
2861         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
2862         * modules/crypto/gc-hmac-sha1: Moved from ../.
2863         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
2864         * modules/crypto/gc-md2: Moved from ../.
2865         * modules/crypto/gc-md2-tests: Moved from ../.
2866         * modules/crypto/gc-md4: Moved from ../.
2867         * modules/crypto/gc-md4-tests: Moved from ../.
2868         * modules/crypto/gc-md5: Moved from ../.
2869         * modules/crypto/gc-md5-tests: Moved from ../.
2870         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
2871         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
2872         * modules/crypto/gc-random: Moved from ../.
2873         * modules/crypto/gc-rijndael: Moved from ../.
2874         * modules/crypto/gc-rijndael-tests: Moved from ../.
2875         * modules/crypto/gc-sha1: Moved from ../.
2876         * modules/crypto/gc-sha1-tests: Moved from ../.
2877         * modules/crypto/gc-tests: Moved from ../.
2878         * modules/crypto/hmac-md5: Moved from ../.
2879         * modules/crypto/hmac-md5-tests: Moved from ../.
2880         * modules/crypto/hmac-sha1: Moved from ../.
2881         * modules/crypto/hmac-sha1-tests: Moved from ../.
2882         * modules/crypto/md2: Moved from ../.
2883         * modules/crypto/md2-tests: Moved from ../.
2884         * modules/crypto/md4: Moved from ../.
2885         * modules/crypto/md4-tests: Moved from ../.
2886         * modules/crypto/md5: Moved from ../.
2887         * modules/crypto/md5-tests: Moved from ../.
2888         * modules/crypto/memxor: Moved from ../.
2889         * modules/crypto/rijndael: Moved from ../.
2890         * modules/crypto/rijndael-tests: Moved from ../.
2891         * modules/crypto/sha1: Moved from ../.
2892
2893 2007-03-30  James Youngman  <jay@gnu.org>
2894
2895         * tests/test-stat-time.c (prepare_test): use chmod() rather than
2896         rename() to change the ctime of a file (because ctime is unaffected
2897         by rename on jfs2 on AIX 5.1).
2898         (main): Start by doing cleanup, in case a previous run failed leaving
2899         test files behind.
2900
2901 2007-03-31  Bruno Haible  <bruno@clisp.org>
2902
2903         Support old proprietary implementations of iconv.
2904         * modules/iconv_open: New file.
2905         * lib/iconv_.h: New file.
2906         * m4/iconv_h.m4: New file.
2907         * lib/iconv_open.c: New file.
2908         * lib/iconv_open-aix.gperf: New file.
2909         * lib/iconv_open-hpux.gperf: New file.
2910         * lib/iconv_open-irix.gperf: New file.
2911         * lib/iconv_open-osf.gperf: New file.
2912         * m4/iconv_open.m4: New file.
2913         * modules/linebreak (Depends-on): Add iconv_open.
2914         * modules/striconv (Depends-on): Likewise.
2915         * modules/striconveh (Depends-on): Likewise.
2916         * modules/unicodeio (Depends-on): Likewise.
2917         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
2918         (iconv_t)(-1).
2919         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
2920         conversion if cd is (iconv_t)(-1).
2921         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
2922         is not possible.
2923
2924 2007-03-31  Bruno Haible  <bruno@clisp.org>
2925
2926         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
2927         work on Solaris either. Protect also second use of "autodetect_jp".
2928
2929 2007-03-31  Bruno Haible  <bruno@clisp.org>
2930
2931         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
2932         the function is not present.
2933
2934 2007-03-31  Bruno Haible  <bruno@clisp.org>
2935
2936         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
2937         the function is not present.
2938
2939 2007-03-31  Bruno Haible  <bruno@clisp.org>
2940
2941         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
2942         a bug in HP-UX iconv_open().
2943
2944 2007-03-31  Bruno Haible  <bruno@clisp.org>
2945
2946         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
2947         (Mathematics <math.h>): New section, add fpieee.
2948         (Input/output <stdio.h>): Add fseterr.
2949         (Mathematics <math.h>): New section, add printf-frexp.
2950         (Container data structures): Add sublist.
2951         (Core language properties): Add fpucw, inline.
2952         (Functions for greatest-width integer types <inttypes.h>): Add
2953         imaxabs, imaxdiv, inttypes.
2954         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
2955         isnanl-nolibm, ldexp.
2956         (Mathematics <math.h>): New section, add printf-frexpl.
2957         (Support for systems lacking POSIX:2001): Add fprintf-posix,
2958         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
2959         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
2960         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
2961         (Unicode string functions): Add unistr/u*-mbtoucr.
2962         (Java): Add javacomp-script, javaexec-script.
2963         (C#): Add csharpcomp-script, csharpexec-script.
2964         (Support for building libraries and executables): Add havelib,
2965         relocatable-*.
2966         (Support for maintaining and releasing projects): Renamed from
2967         'Support for maintaining and release projects'. Add announce-gen.
2968
2969 2007-03-31  Bruno Haible  <bruno@clisp.org>
2970
2971         * README: Talk primarily about git.
2972         (git and CVS): Renamed from CVS.
2973         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
2974         gnulib is available through git.
2975         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
2976
2977 2007-03-30  Bruno Haible  <bruno@clisp.org>
2978
2979         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
2980         * lib/poll_.h: Likewise.
2981         * lib/stat_.h: Likewise.
2982         * lib/sys_time_.h: Likewise.
2983         * lib/sysexit_.h: Likewise.
2984         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
2985         * lib/stdbool_.h: Likewise.
2986         * lib/byteswap_.h: Add double-inclusion guard.
2987
2988 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
2989
2990         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
2991
2992 2007-03-30  Karl Berry  <karl@gnu.org>
2993
2994         * config/srclist-update: double space after USA in the license
2995         substitution, since that's how it's usually (?) written.
2996
2997 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
2998
2999         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
3000         reported by Bruno Haible.
3001
3002 2007-03-29  Bruno Haible  <bruno@clisp.org>
3003
3004         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
3005         a bug in AIX iconv().
3006
3007 2007-03-29  Bruno Haible  <bruno@clisp.org>
3008
3009         * modules/ldexpl-tests: New file.
3010         * tests/test-ldexpl.c: New file.
3011
3012 2007-03-29  Bruno Haible  <bruno@clisp.org>
3013
3014         * lib/ldexpl.c: Include fpucw.h.
3015         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
3016         multiplication.
3017         * modules/ldexpl (Depends-on): Add fpucw.
3018
3019 2007-03-29  Bruno Haible  <bruno@clisp.org>
3020
3021         * modules/ldexpl: New file.
3022         * m4/ldexpl.m4: New file.
3023         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
3024         set.
3025         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
3026         REPLACE_LDEXPL.
3027         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
3028         REPLACE_LDEXPL.
3029         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
3030         gl_FUNC_LDEXPL_WORKS.
3031         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
3032         * modules/mathl (Files): Remove lib/ldexpl.c.
3033         (Depends-on): Add ldexpl.
3034
3035 2007-03-29  Bruno Haible  <bruno@clisp.org>
3036
3037         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
3038
3039 2007-03-29  Bruno Haible  <bruno@clisp.org>
3040
3041         * tests/test-striconveh.c (main): Don't assume that a direct conversion
3042         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
3043         and possibly also HP-UX.
3044         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3045         work on AIX, IRIX, HP-UX, OSF/1.
3046         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
3047         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
3048         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
3049         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
3050         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
3051         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
3052
3053 2007-03-29  Bruno Haible  <bruno@clisp.org>
3054
3055         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
3056
3057 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3058
3059         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
3060         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
3061
3062 2007-03-29  Eric Blake  <ebb9@byu.net>
3063
3064         * lib/acl-internal.h: Remove redundant include.
3065         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
3066         Cygwin when a file is locked.
3067
3068 2007-03-29  Bruno Haible  <bruno@clisp.org>
3069
3070         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
3071         file.
3072         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
3073
3074 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3075
3076         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
3077         try to remove a parent directory if the child couldn't be removed
3078         (except for the first rmdir, which could fail because the child
3079         doesn't exist).  Problem reported by Jeff Blaine in
3080         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
3081
3082 2007-03-28  Bruno Haible  <bruno@clisp.org>
3083
3084         * lib/striconveh.c (utf8conv_carefully): New function.
3085         (mem_cd_iconveh_internal): Invoke it.
3086
3087 2007-03-28  Bruno Haible  <bruno@clisp.org>
3088
3089         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
3090         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
3091         input.
3092         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
3093         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
3094         unistr/u8-uctomb.
3095
3096 2007-03-28  Bruno Haible  <bruno@clisp.org>
3097
3098         * modules/unistr/u8-mbtoucr: New file.
3099         * lib/unistr/u8-mbtoucr.c: New file.
3100         * modules/unistr/u16-mbtoucr: New file.
3101         * lib/unistr/u16-mbtoucr.c: New file.
3102         * modules/unistr/u16-mbtoucr: New file.
3103         * lib/unistr/u16-mbtoucr.c: New file.
3104         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
3105
3106 2007-03-27  Simon Josefsson  <simon@josefsson.org>
3107             Bruno Haible  <bruno@clisp.org>
3108
3109         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
3110         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
3111         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
3112
3113         * m4/stdio_h.m4: Add stubs for vasprintf too.
3114
3115         * modules/stdio: Support vasprintf in sed command.
3116
3117         * modules/vasprintf: Depend on stdio for prototypes.  Remove
3118         vasprintf.h.  Add stdio module indicator.
3119
3120         * lib/stdio_.h: Declare asprintf and vasprintf, based on
3121         vasprintf.h.
3122
3123         * lib/vasprintf.h: File removed.
3124
3125         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
3126         * lib/vasprintf.c: Ditto.
3127         * lib/xvasprintf.c: Ditto.
3128         * tests/test-vasprintf-posix.c: Ditto.
3129         * tests/test-vasprintf.c: Ditto.
3130
3131 2007-03-27  Bruno Haible  <bruno@clisp.org>
3132
3133         Make vasnprintf multithread-safe.
3134         * lib/vasnprintf.c (decimal_point_char): New function.
3135         (VASNPRINTF): Use it.
3136         Suggested by Simon Josefsson.
3137
3138 2007-03-27  Eric Blake  <ebb9@byu.net>
3139
3140         Support sub-second birthtime on cygwin.
3141         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
3142         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
3143         (get_stat_birthtime): Also work with st_birthtim.
3144
3145 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
3146
3147         * lib/stat-time.h (USE_BIRTHTIME): Remove.
3148         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
3149         (get_stat_birthtime_ns): Do not try to use "spare" fields.
3150         (get_stat_birthtime_ns): Simplify compile-time tests.
3151         (get_stat_birthtime): Change the API to look like
3152         get_stat_mtime etc., except return a negative tv_nsec on error.
3153         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
3154         Don't check for "spare" fields.
3155         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
3156         or for struct stat.st_birthtime, as these tests aren't used.
3157         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
3158
3159 2007-03-27  Bruno Haible  <bruno@clisp.org>
3160
3161         * lib/stat-time.h: Include <sys/stat.h>.
3162
3163 2007-03-27  James Youngman  <jay@gnu.org>
3164
3165         * lib/stat-time.h (get_stat_birthtime): New function for
3166           retrieving st_birthtime as provided by UFS2 (hence *BSD).
3167         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
3168           and its variants.
3169         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
3170         * modules/stat-time-test: New file.
3171         * tests/test-stat-time.c: New test, devised by Bruno Haible.
3172
3173 2007-03-26  Bruno Haible  <bruno@clisp.org>
3174
3175         Better support of signalling NaNs.
3176         * lib/atanl.c: Include isnanl.h.
3177         (atanl): Perform test for NaN at the beginning of the function and
3178         through a call to isnanl.
3179         * lib/cosl.c: Include isnanl.h.
3180         (cosl): Perform test for NaN at the beginning of the function and
3181         through a call to isnanl.
3182         * lib/ldexpl.c: Include isnanl.h.
3183         (ldexpl): Perform test for NaN through a call to isnanl.
3184         * lib/logl.c: Include isnanl.h.
3185         (logl): Perform test for NaN at the beginning of the function and
3186         through a call to isnanl.
3187         * lib/sinl.c: Include isnanl.h.
3188         (sinl): Perform test for NaN at the beginning of the function and
3189         through a call to isnanl.
3190         * lib/sqrtl.c: Include isnanl.h.
3191         (sqrtl): Perform test for NaN at the beginning of the function and
3192         through a call to isnanl.
3193         * lib/tanl.c: Include isnanl.h.
3194         (tanl): Perform test for NaN at the beginning of the function and
3195         through a call to isnanl.
3196         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
3197         * modules/mathl (Depends-on): Add isnanl.
3198
3199 2007-03-26  Eric Blake  <ebb9@byu.net>
3200
3201         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
3202         regression in logic sense of previous patch.
3203
3204 2007-03-26  Bruno Haible  <bruno@clisp.org>
3205
3206         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
3207         unportable shell command "if ! ...".
3208         Reported by Ralf Wildenhues.
3209
3210 2007-03-25  Bruno Haible  <bruno@clisp.org>
3211
3212         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
3213         <sysexits.h> file, and only add EX_CONFIG.
3214         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
3215         absolute file name and whether it is sufficient. Substitute also
3216         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
3217         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
3218         ABSOLUTE_SYSEXITS_H into sysexits.h.
3219
3220 2007-03-25  Bruno Haible  <bruno@clisp.org>
3221
3222         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
3223         hints is NULL.
3224
3225 2007-03-25  Bruno Haible  <bruno@clisp.org>
3226
3227         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
3228         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
3229
3230 2007-03-25  Bruno Haible  <bruno@clisp.org>
3231
3232         * lib/vasnprintf.c: Include langinfo.h.
3233         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
3234         multithread-safe.
3235         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
3236         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
3237         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
3238         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
3239         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
3240         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
3241         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
3242         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
3243         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
3244         Reported by Simon Josefsson.
3245
3246 2007-03-25  Bruno Haible  <bruno@clisp.org>
3247
3248         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
3249         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
3250         * modules/vasnprintf (Depends-on): Add stdint.
3251
3252 2007-03-25  Bruno Haible  <bruno@clisp.org>
3253
3254         * modules/fpieee: New file.
3255         * m4/fpieee.m4: New file.
3256         * modules/isnan-nolibm (Depends-on): Add fpieee.
3257         * modules/isnanl-nolibm (Depends-on): Add fpieee.
3258         * modules/isnanl (Depends-on): Add fpieee.
3259
3260 2007-03-25  Bruno Haible  <bruno@clisp.org>
3261
3262         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
3263
3264 2007-03-25  Bruno Haible  <bruno@clisp.org>
3265
3266         Avoid test failures on IRIX 6.5.
3267         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
3268         (main): Use it.
3269         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
3270         macros.
3271         (main): Use them.
3272
3273 2007-03-25  Bruno Haible  <bruno@clisp.org>
3274
3275         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
3276         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
3277         exists but doesn't work.
3278         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
3279         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
3280         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
3281         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
3282
3283 2007-03-25  Bruno Haible  <bruno@clisp.org>
3284
3285         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
3286         returns inf. Needed on IRIX 6.5.
3287
3288 2007-03-25  Bruno Haible  <bruno@clisp.org>
3289
3290         * tests/test-frexpl.c: Include isnanl-nolibm.h.
3291         (main): Use isnanl instead of x != x idiom.
3292         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
3293
3294         * tests/test-frexp.c: Include isnan.h.
3295         (main): Use isnan instead of x != x idiom.
3296         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
3297
3298 2007-03-25  Bruno Haible  <bruno@clisp.org>
3299
3300         * tests/test-frexp.c (NaN): New function/macro.
3301         (main): Use it instead of 0.0 / 0.0.
3302         * tests/test-isnan.c (NaN): New function/macro.
3303         (main): Use it instead of 0.0 / 0.0.
3304         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
3305         (test_function): Use it instead of 0.0 / 0.0.
3306         * tests/test-vasprintf-posix.c (NaN): New function/macro.
3307         (test_function): Use it instead of 0.0 / 0.0.
3308         * tests/test-snprintf-posix.h (NaN): New function/macro.
3309         (test_function): Use it instead of 0.0 / 0.0.
3310         * tests/test-sprintf-posix.h (NaN): New function/macro.
3311         (test_function): Use it instead of 0.0 / 0.0.
3312         * tests/test-fprintf-posix.h (NaN): New function/macro.
3313         (test_function): Use it instead of 0.0 / 0.0.
3314         * tests/test-printf-posix.h (NaN): New function/macro.
3315         (test_function): Use it instead of 0.0 / 0.0.
3316
3317         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
3318
3319 2007-03-25  Bruno Haible  <bruno@clisp.org>
3320
3321         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
3322
3323 2007-03-25  Bruno Haible  <bruno@clisp.org>
3324
3325         * lib/regexec.c (merge_state_with_log): Make static.
3326
3327 2007-03-25  Bruno Haible  <bruno@clisp.org>
3328
3329         * lib/trigl.c (kernel_rem_pio2): Make static.
3330
3331 2007-03-25  Bruno Haible  <bruno@clisp.org>
3332
3333         * lib/sincosl.c (sincosl_table): Make static.
3334
3335 2007-03-25  Bruno Haible  <bruno@clisp.org>
3336
3337         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
3338         if the compiler does not support C99.
3339
3340 2007-03-25  Bruno Haible  <bruno@clisp.org>
3341
3342         * modules/time (Makefile.am): Ensure all rule action lines start with a
3343         tab.
3344
3345 2007-03-24  Bruno Haible  <bruno@clisp.org>
3346
3347         * modules/tsearch-tests: New file.
3348         * tests/test-tsearch.sh: New file.
3349         * tests/test-tsearch.c: New file, mostly copied from glibc.
3350
3351         * modules/search-tests: New file.
3352         * tests/test-search.c: New file.
3353
3354         * modules/search: New file.
3355         * lib/search_.h: New file, incorporating lib/tsearch.h.
3356         * m4/search_h.m4: New file.
3357         * lib/tsearch.h: Remove file.
3358         * lib/tsearch.c: Include search.h instead of tsearch.h.
3359         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
3360         HAVE_TSEARCH.
3361         * modules/tsearch (Files): Remove lib/tsearch.h.
3362         (Depends-on): Add search.
3363         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
3364         (Include): Change tsearch.h into search.h.
3365
3366 2007-03-24  Bruno Haible  <bruno@clisp.org>
3367
3368         * modules/fpucw: New file.
3369         * lib/fpucw.h: New file.
3370         * lib/frexp.c: Include fpucw.h.
3371         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3372         (FUNC): Use them.
3373         * lib/printf-frexp.c: Include fpucw.h.
3374         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3375         (FUNC): Use them.
3376         * lib/vasnprintf.c: Include fpucw.h.
3377         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
3378         'long double' calculations.
3379         * tests/test-frexpl.c: Include fpucw.h.
3380         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3381         * tests/test-printf-frexpl.c: Include fpucw.h.
3382         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3383         * modules/frexpl (Depends-on): Add fpucw.
3384         * modules/printf-frexpl (Depends-on): Likewise.
3385         * modules/fprintf-posix (Depends-on): Likewise.
3386         * modules/snprintf-posix (Depends-on): Likewise.
3387         * modules/sprintf-posix (Depends-on): Likewise.
3388         * modules/vasnprintf-posix (Depends-on): Likewise.
3389         * modules/vasprintf-posix (Depends-on): Likewise.
3390         * modules/vfprintf-posix (Depends-on): Likewise.
3391         * modules/vsnprintf-posix (Depends-on): Likewise.
3392         * modules/vsprintf-posix (Depends-on): Likewise.
3393         * modules/frexpl-tests (Depends-on): Likewise.
3394         * modules/printf-frexpl-tests (Depends-on): Likewise.
3395
3396 2007-03-24  Bruno Haible  <bruno@clisp.org>
3397
3398         * lib/float+.h: New file.
3399         * lib/isnan.c: Include float+.h.
3400         (SIZE): New macro.
3401         (FUNC): Compare only SIZE bytes of the value.
3402         * lib/vasnprintf.c: Include float+.h.
3403         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
3404         SIZEOF_LDBL or SIZEOF_DBL bytes.
3405         * modules/isnan-nolibm (Files): Add lib/float+.h.
3406         * modules/isnanl-nolibm (Files): Add lib/float+.h.
3407         * modules/isnanl (Files): Add lib/float+.h.
3408         * modules/vasnprintf (Files): Add lib/float+.h.
3409
3410 2007-03-24  Bruno Haible  <bruno@clisp.org>
3411
3412         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
3413         include isnanl-nolibm.h.
3414
3415 2007-03-24  Bruno Haible  <bruno@clisp.org>
3416
3417         * tests/test-read-file.c (main): Don't produce spurious output for
3418         expected situations. Make the test fail if it encountered unexpected
3419         results.
3420
3421 2007-03-24  Bruno Haible  <bruno@clisp.org>
3422
3423         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
3424         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
3425
3426 2007-03-24  Bruno Haible  <bruno@clisp.org>
3427
3428         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
3429
3430 2007-03-24  Bruno Haible  <bruno@clisp.org>
3431
3432         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
3433         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
3434
3435         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
3436         * modules/utf8-ucs4: Turn into a symbolic link to module
3437         unistr/u8-mbtouc.
3438
3439         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
3440         utf8-ucs4-unsafe.
3441         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
3442         unistr/u8-mbtouc-unsafe.
3443
3444         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
3445         * modules/utf16-ucs4: Turn into a symbolic link to module
3446         unistr/u16-mbtouc.
3447
3448         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
3449         utf16-ucs4-unsafe.
3450         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
3451         unistr/u16-mbtouc-unsafe.
3452
3453         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
3454         * modules/ucs4-utf8: Turn into a symbolic link to module
3455         unistr/u8-ubtomb.
3456
3457         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
3458         * modules/ucs4-utf16: Turn into a symbolic link to module
3459         unistr/u16-ubtomb.
3460
3461 2007-03-24  Bruno Haible  <bruno@clisp.org>
3462
3463         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
3464         Enable the function only if HAVE_INLINE.
3465         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
3466         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3467         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
3468         Enable the function only if HAVE_INLINE.
3469         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
3470         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3471         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
3472         Enable the function only if HAVE_INLINE.
3473         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
3474         Enable the function only if HAVE_INLINE.
3475         * modules/utf8-ucs4: Update.
3476         * modules/utf8-ucs4-unsafe: Update.
3477         * modules/utf16-ucs4: Update.
3478         * modules/utf16-ucs4-unsafe: Update.
3479         * modules/ucs4-utf8: Update.
3480         * modules/ucs4-utf16: Update.
3481
3482 2007-03-24  Bruno Haible  <bruno@clisp.org>
3483
3484         * lib/utf8-ucs4.h: Remove file.
3485         * lib/utf8-ucs4-unsafe.h: Remove file.
3486         * lib/utf16-ucs4.h: Remove file.
3487         * lib/utf16-ucs4-unsafe.h: Remove file.
3488         * lib/ucs4-utf8.h: Remove file.
3489         * lib/ucs4-utf16.h: Remove file.
3490         * lib/unistr.h: Include their previous contents.
3491         * m4/utf-ucs4.m4: Remove file.
3492         * m4/ucs4-utf.m4: Remove file.
3493         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
3494         (Depends-on): Add unistr/base.
3495         (configure.ac): Remove gl_UTF_UCS4.
3496         (Makefile.am): Update.
3497         (Include): Change to unistr.h.
3498         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
3499         (Depends-on): Add unistr/base.
3500         (configure.ac): Remove gl_UTF_UCS4.
3501         (Makefile.am): Update.
3502         (Include): Change to unistr.h.
3503         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
3504         (Depends-on): Add unistr/base.
3505         (configure.ac): Remove gl_UTF_UCS4.
3506         (Makefile.am): Update.
3507         (Include): Change to unistr.h.
3508         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
3509         (Depends-on): Add unistr/base.
3510         (configure.ac): Remove gl_UTF_UCS4.
3511         (Makefile.am): Update.
3512         (Include): Change to unistr.h.
3513         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
3514         (Depends-on): Add unistr/base.
3515         (configure.ac): Remove gl_UCS4_UTF.
3516         (Makefile.am): Update.
3517         (Include): Change to unistr.h.
3518         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
3519         (Depends-on): Add unistr/base.
3520         (configure.ac): Remove gl_UCS4_UTF.
3521         (Makefile.am): Update.
3522         (Include): Change to unistr.h.
3523         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
3524         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
3525         utf8-ucs4-unsafe.h.
3526         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
3527         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
3528         utf16-ucs4-unsafe.h.
3529         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
3530         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
3531         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
3532         * lib/unistr/u8-strchr.c: Likewise.
3533         * lib/unistr/u8-strrchr.c: Likewise.
3534         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
3535         * lib/unistr/u16-strchr.c: Likewise.
3536         * lib/unistr/u16-strrchr.c: Likewise.
3537         * lib/striconveh.c: Update.
3538         * lib/linebreak.c: Update.
3539
3540 2007-03-24  Bruno Haible  <bruno@clisp.org>
3541
3542         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
3543         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
3544
3545 2007-03-22  Bruno Haible  <bruno@clisp.org>
3546
3547         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
3548
3549 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
3550
3551         * MODULES.html.sh (File system functions): New module write-any-file.
3552         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
3553         * m4/write-any-file.m4: New files.
3554
3555 2007-03-23  Eric Blake  <ebb9@byu.net>
3556
3557         * gnulib-tool: Rearrange space-tab sequences, since some editors
3558         like to eat them.
3559
3560 2007-03-23  Eric Blake  <ebb9@byu.net>
3561
3562         * lib/version-etc.c (version_etc_va): Update license wording to
3563         be more concise.  Recommended by Richard Stallman.
3564
3565 2007-03-22  Bruno Haible  <bruno@clisp.org>
3566
3567         * lib/poll.c (MSG_PEEK): New fallback definition.
3568
3569 2007-03-22  Bruno Haible  <bruno@clisp.org>
3570
3571         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
3572         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
3573         (main): Update.
3574         Fixes a compilation error on BeOS.
3575
3576 2007-03-22  Bruno Haible  <bruno@clisp.org>
3577
3578         * modules/frexpl-tests: New file.
3579         * tests/test-frexpl.c: New file.
3580
3581         * modules/frexpl: New file.
3582         * m4/frexpl.m4: New file.
3583         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
3584         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
3585         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
3586         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
3587         (Depends-on): Add frexpl. Remove isnanl-nolibm.
3588         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
3589
3590 2007-03-22  Bruno Haible  <bruno@clisp.org>
3591
3592         * lib/frexpl.c: Share code with lib/frexp.c.
3593         * modules/mathl (Files): Add lib/frexp.c.
3594         (Depends-on): Add isnanl-nolibm.
3595
3596 2007-03-22  Bruno Haible  <bruno@clisp.org>
3597
3598         * modules/printf-frexp (Files): Add m4/frexp.m4.
3599         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
3600         only if the found frexp function actually works.
3601
3602 2007-03-22  Bruno Haible  <bruno@clisp.org>
3603
3604         * lib/frexp.c: Remove older implementation that uses divisions.
3605
3606 2007-03-21  Bruno Haible  <bruno@clisp.org>
3607
3608         * modules/frexp-tests: New file.
3609         * tests/test-frexp.c: New file.
3610
3611         * modules/frexp: New file.
3612         * lib/frexp.c: New file.
3613         * m4/frexp.m4: New file.
3614         * lib/math_.h (frexp): New declaration.
3615         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
3616         REPLACE_FREXP.
3617         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
3618
3619 2007-03-21  Bruno Haible  <bruno@clisp.org>
3620
3621         * modules/isnanl-tests: New file.
3622         * tests/test-isnanl.c: New file.
3623
3624         * modules/isnanl: New file.
3625         * lib/isnanl.h: New file.
3626         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
3627         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
3628         gl_FUNC_ISNANL_WORKS.
3629         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
3630         New macros.
3631
3632 2007-03-21  Bruno Haible  <bruno@clisp.org>
3633
3634         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
3635         lib/isnanl.h.
3636         (Include): Update.
3637         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
3638         * lib/vasnprintf.c: Update.
3639         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
3640         tests/test-isnanl.h, remove tests/test-isnanl.c.
3641         (Makefile.am): Update.
3642         * tests/test-isnanl-nolibm.c: New file.
3643         * tests/test-isnanl.h: New file.
3644         * tests/test-isnanl.c: Remove file.
3645
3646 2007-03-21  Jim Meyering  <jim@meyering.net>
3647
3648         When trying to open ".", treat ESTALE like EACCES.
3649         * lib/savewd.c (savewd_save): Resort to forking not just upon
3650         failure with EACCES, but also when errno is ESTALE.
3651
3652 2007-03-20  Bruno Haible  <bruno@clisp.org>
3653
3654         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
3655         Needed on AIX 5.1. Reported by Matthew Woehlke.
3656
3657 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
3658
3659         Suggestions by Bruno Haible:
3660         * lib/acl-internal.h: Include "gettext.h" rather than rolling
3661         our own.
3662         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
3663         * modules/acl (Depends-on): Add gettext.
3664
3665 2007-03-19  Bruno Haible  <bruno@clisp.org>
3666
3667         * modules/iconvme: Remove file.
3668         * lib/iconvme.h: Remove file.
3669         * lib/iconvme.c: Remove file.
3670         * m4/iconvme.m4: Remove file.
3671
3672 2007-03-19  Bruno Haible  <bruno@clisp.org>
3673
3674         * doc/relocatable-maint.texi: Break long shell script line.
3675         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
3676
3677 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
3678
3679         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
3680         handle file_has_acl.
3681         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
3682         * lib/acl.c: Move header inclusions and related macro defns into
3683         lib/acl-internal.h.
3684         (S_ISLNK): Remove defn, since that's now done for us.
3685         (file_has_acl): Move to lib/file-has-acl.c.
3686         Call acl_trivial if available.  This is the crucial part of the fix.
3687         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
3688         shared within the library.  Rewrite a bit, partly to make it compatible
3689         with the GNU coding style.
3690         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
3691         Remove unnecessary double-quotes.
3692         Don't test for acl_to_text; the build will catch that.
3693         Replace acl_entries if it doesn't exist and it is needed.
3694         Check for -lsec and acl_trivial (as used on Solaris 10).
3695         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
3696         lib/file-has-acl.c.
3697         (Depends-on): Add sys_stat, for S_ISLNK.
3698
3699 2007-03-19  Ben Pfaff  <blp@gnu.org>
3700
3701         * doc/gnulib.texi: Fix typos.
3702         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
3703
3704 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
3705
3706         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
3707         If size is zero here, buf must be zero.
3708
3709 2007-03-19  Simon Josefsson  <simon@josefsson.org>
3710
3711         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
3712         <bruno@clisp.org>.
3713
3714 2007-03-18  Bruno Haible  <bruno@clisp.org>
3715
3716         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
3717         Suggested by Eric Blake.
3718
3719 2007-03-18  Ben Pfaff  <blp@gnu.org>
3720
3721         * doc/relocatable.texi: Recommend using as prefix a directory
3722         that does not exist and will never be created.  Based on
3723         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
3724         and others.
3725
3726 2007-03-17  Bruno Haible  <bruno@clisp.org>
3727
3728         * lib/fchownat.c: Include lchown.h.
3729
3730 2007-03-17  Bruno Haible  <bruno@clisp.org>
3731
3732         Fix endless loop when the given allocated size was > INT_MAX.
3733         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
3734         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
3735         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
3736         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
3737         * lib/sprintf.c (sprintf): Likewise.
3738
3739 2007-03-17  Bruno Haible  <bruno@clisp.org>
3740
3741         * tests/test-argp-2.sh (func_compare): Output a context diff.
3742
3743 2007-03-17  Bruno Haible  <bruno@clisp.org>
3744
3745         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
3746         locale's decimal-point character.
3747
3748 2007-03-17  Bruno Haible  <bruno@clisp.org>
3749
3750         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
3751         before comparing it. Needed because on some platforms (e.g. x86) a
3752         'long double' occupies less bytes than sizeof (long double).
3753
3754 2007-03-17  Bruno Haible  <bruno@clisp.org>
3755
3756         * tests/test-crc.c (main): Make printf statements 64-bit clean.
3757         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
3758         * tests/test-getaddrinfo.c (simple): Likewise.
3759         * tests/test-read-file.c (main): Likewise.
3760
3761 2007-03-17  Bruno Haible  <bruno@clisp.org>
3762
3763         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
3764
3765 2007-03-17  Bruno Haible  <bruno@clisp.org>
3766
3767         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
3768         unused variable.
3769
3770 2007-03-17  Bruno Haible  <bruno@clisp.org>
3771
3772         * tests/test-c-strcasecmp.c: Include c-strcase.h.
3773         * tests/test-c-strncasecmp.c: Likewise.
3774
3775 2007-03-17  Bruno Haible  <bruno@clisp.org>
3776
3777         * modules/stdlib (Depends-on): Add unistd.
3778         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
3779         Needed for MacOS X 10.3.
3780
3781 2007-03-17  Bruno Haible  <bruno@clisp.org>
3782
3783         * lib/unistr/u-strdup.h: Include <stdlib.h>.
3784
3785 2007-03-17  Bruno Haible  <bruno@clisp.org>
3786
3787         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
3788
3789 2007-03-17  Bruno Haible  <bruno@clisp.org>
3790
3791         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
3792         to reflect files copied from gnulib (with or without modifications).
3793         Suggested by Jim Meyering.
3794
3795 2007-03-17  Eric Blake  <ebb9@byu.net>
3796
3797         * NEWS: Document stdlib change from 2007-02-18.
3798
3799 2007-03-17  Jim Meyering  <jim@meyering.net>
3800
3801         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
3802         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
3803         someone uses a name containing shell meta-characters.
3804         Reported by Alfred M. Szmidt.
3805
3806         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
3807
3808 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
3809
3810         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
3811         and copy gettext configuration files only if configure.ac contains
3812         a use of AM_GNU_GETTEXT_VERSION.
3813
3814 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
3815
3816         * build-aux/bootstrap (gnulib_name): New variable.
3817         (gnulib_tool_options): Use it.
3818
3819 2007-03-13  Simon Josefsson  <simon@josefsson.org>
3820
3821         * tests/test-des.c: Use new namespace.
3822
3823 2007-03-15  Bruno Haible  <bruno@clisp.org>
3824
3825         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
3826         Reported by James Youngman <jay@gnu.org>.
3827
3828 2007-03-15  Bruno Haible  <bruno@clisp.org>
3829
3830         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
3831         declared prototype. Needed with cc on OSF/1 5.1.
3832
3833 2007-03-15  Bruno Haible  <bruno@clisp.org>
3834
3835         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
3836         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
3837         (struct gl_list_implementation): Add dispose_fn argument to the
3838         'create_empty', 'create' methods.
3839         (struct gl_list_impl_base): Add field 'dispose_fn'.
3840         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
3841         argument.
3842         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
3843         dispose_fn argument.
3844         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
3845         dispose_fn on the dropped values.
3846         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
3847         dispose_fn argument.
3848         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
3849         dropped values.
3850         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
3851         (gl_tree_remove_node): Call dispose_fn on the dropped value.
3852         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
3853         (gl_tree_remove_node): Call dispose_fn on the dropped value.
3854         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
3855         argument.
3856         (gl_tree_list_free): Call dispose_fn on the dropped values.
3857         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
3858         the dropped values.
3859         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
3860         Add dispose_fn argument.
3861         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
3862         Call dispose_fn on the dropped values.
3863         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
3864         Add dispose_fn argument.
3865         (gl_sublist_create): Initialize the 'dispose_fn' field.
3866         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
3867         * tests/test-array_list.c (main): Update.
3868         * tests/test-carray_list.c (main): Update.
3869         * tests/test-avltree_list.c (main): Update.
3870         * tests/test-rbtree_list.c (main): Update.
3871         * tests/test-avltreehash_list.c (main): Update.
3872         * tests/test-rbtreehash_list.c (main): Update.
3873         * tests/test-linked_list.c (main): Update.
3874         * tests/test-linkedhash_list.c (main): Update.
3875         * tests/test-array_oset.c (main): Update.
3876
3877 2007-03-15  Bruno Haible  <bruno@clisp.org>
3878
3879         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
3880         (gl_oset_create_empty): Add dispose_fn argument.
3881         (struct gl_oset_implementation): Add dispose_fn argument to
3882         'create_empty' method.
3883         (struct gl_oset_impl_base): Add dispose_fn field.
3884         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
3885         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
3886         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
3887         values.
3888         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
3889         (gl_tree_oset_free): Call dispose_fn on the dropped values.
3890         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
3891         dropped value.
3892         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
3893         dropped value.
3894         * tests/test-array_oset.c (main): Update.
3895         * tests/test-avltree_oset.c (main): Update.
3896         * tests/test-rbtree_oset.c (main): Update.
3897         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
3898
3899 2007-03-13  Bruno Haible  <bruno@clisp.org>
3900
3901         * tests/test-stdbool.c (i): Update after last patch.
3902
3903 2007-03-12  Bruno Haible  <bruno@clisp.org>
3904
3905         * lib/quotearg.c: Include <wctype.h> early, before the definition of
3906         the iswprint macro. Needed on Solaris 2.5.1.
3907
3908 2007-03-12  Bruno Haible  <bruno@clisp.org>
3909
3910         * tests/test-printf-frexp.c (main): Declare x as volatile.
3911
3912 2007-03-12  Simon Josefsson  <simon@josefsson.org>
3913
3914         * doc/gnulib.texi (Build robot for gnulib): New section.
3915
3916 2007-03-12  Jim Meyering  <jim@meyering.net>
3917
3918         * build-aux/bootstrap: New file.
3919         * build-aux/bootstrap.conf: New file, from coreutils.
3920
3921 2007-03-11  Bruno Haible  <bruno@clisp.org>
3922
3923         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
3924
3925 2007-03-12  Simon Josefsson  <simon@josefsson.org>
3926
3927         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
3928         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
3929         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
3930
3931 2007-03-11  Bruno Haible  <bruno@clisp.org>
3932
3933         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
3934         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
3935
3936 2007-03-11  Bruno Haible  <bruno@clisp.org>
3937
3938         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
3939         formula. Needed for SunPRO C 5.0.
3940
3941 2007-03-11  Bruno Haible  <bruno@clisp.org>
3942
3943         * modules/long-options (Depends-on): Add getopt.
3944
3945 2007-03-11  Bruno Haible  <bruno@clisp.org>
3946
3947         * modules/modechange (Depends-on): Add stdbool.
3948
3949 2007-03-11  Bruno Haible  <bruno@clisp.org>
3950
3951         * modules/i-ring (Depends-on): Add stdbool.
3952
3953 2007-03-11  Bruno Haible  <bruno@clisp.org>
3954
3955         * modules/gc-des (Depends-on): Add stdbool.
3956
3957 2007-03-11  Bruno Haible  <bruno@clisp.org>
3958
3959         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
3960
3961 2007-03-11  Bruno Haible  <bruno@clisp.org>
3962
3963         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
3964
3965 2007-03-11  Bruno Haible  <bruno@clisp.org>
3966
3967         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
3968
3969 2007-03-11  Bruno Haible  <bruno@clisp.org>
3970
3971         * lib/vasnprintf.c (sprintf): Undefine.
3972
3973 2007-03-11  Bruno Haible  <bruno@clisp.org>
3974
3975         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
3976         initializers in SunPRO C and Compaq C compilers.
3977
3978 2007-03-11  Bruno Haible  <bruno@clisp.org>
3979
3980         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
3981         decrementing code ANSI C compliant.
3982
3983 2007-03-11  Bruno Haible  <bruno@clisp.org>
3984
3985         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
3986         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
3987
3988 2007-03-11  Bruno Haible  <bruno@clisp.org>
3989
3990         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
3991         <stdbool.h> substitute doesn't pass.
3992
3993 2007-03-11  Bruno Haible  <bruno@clisp.org>
3994
3995         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
3996
3997 2007-03-11  Bruno Haible  <bruno@clisp.org>
3998
3999         * gnulib-tool (func_create_megatestdir): Create also an autobuild
4000         script, for submission to autobuild.josefsson.org.
4001
4002 2007-03-10  Bruno Haible  <bruno@clisp.org>
4003
4004         * modules/canonicalize-lgpl-tests: New file.
4005         * tests/test-canonicalize-lgpl.sh: New file.
4006         * tests/test-canonicalize-lgpl.c: New file.
4007
4008         * modules/c-strcase-tests: New file.
4009         * tests/test-c-strcase.sh: New file.
4010         * tests/test-c-strcasecmp.c: New file.
4011         * tests/test-c-strncasecmp.c: New file.
4012
4013         * modules/atexit-tests: New file.
4014         * tests/test-atexit.sh: New file.
4015         * tests/test-atexit.c: New file.
4016
4017 2007-03-10  Bruno Haible  <bruno@clisp.org>
4018
4019         * tests/test-binary-io.sh: Use temporary filenames that are not so
4020         likely to clash with those of other tests (in a parallel make).
4021         * tests/test-binary-io.c: Likewise.
4022
4023 2007-03-10  Bruno Haible  <bruno@clisp.org>
4024
4025         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
4026         fallback; use #error instead.
4027         Suggested by Simon Josefsson.
4028
4029 2007-03-10  Bruno Haible  <bruno@clisp.org>
4030
4031         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
4032         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
4033         first and the last.
4034
4035 2007-03-10  Bruno Haible  <bruno@clisp.org>
4036
4037         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
4038
4039 2007-03-10  Bruno Haible  <bruno@clisp.org>
4040
4041         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
4042         "make distcheck".
4043         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
4044         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
4045         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
4046
4047 2007-03-10  Bruno Haible  <bruno@clisp.org>
4048
4049         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
4050         variable.
4051         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
4052         variable.
4053
4054 2007-03-09  Eric Blake  <ebb9@byu.net>
4055         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
4056
4057         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
4058         types are not being provided by gnulib.
4059         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
4060         types are supported.
4061
4062 2007-03-10  Bruno Haible  <bruno@clisp.org>
4063
4064         * lib/stdio_.h (__attribute__): New macro.
4065         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
4066         vsprintf): Specify __attribute__ __format__ for GCC.
4067         Suggested by Eric Blake.
4068
4069 2007-03-09  Bruno Haible  <bruno@clisp.org>
4070
4071         * modules/printf-posix-tests: New file.
4072         * tests/test-printf-posix.sh: New file.
4073         * tests/test-printf-posix.c: New file.
4074
4075         * modules/printf-posix: New file.
4076         * lib/printf.c: New file.
4077         * m4/printf-posix-rpl.m4: New file.
4078         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
4079         REPLACE_PRINTF.
4080         * lib/stdio_.h (printf): New declaration.
4081         (format, __format__, ____printf____, ____scanf____, ____strftime____,
4082         ____strfmon____): New macros.
4083         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
4084         REPLACE_PRINTF.
4085
4086 2007-03-09  Bruno Haible  <bruno@clisp.org>
4087
4088         * tests/test-vasnprintf-posix2.sh: New file.
4089         * tests/test-vasnprintf-posix2.c: New file.
4090         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
4091         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
4092         (Makefile.am): Activate test-vasnprintf-posix2.sh.
4093
4094         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
4095         a locale dependent decimal point, rather than always '.'.
4096
4097 2007-03-09  Eric Blake  <ebb9@byu.net>
4098
4099         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
4100         spite of platforms like Tandem/NSK that define it to -1.
4101
4102 2007-03-08  Bruno Haible  <bruno@clisp.org>
4103
4104         * modules/vprintf-posix-tests: New file.
4105         * tests/test-vprintf-posix.sh: New file.
4106         * tests/test-vprintf-posix.c: New file.
4107         * tests/test-printf-posix.h: New file.
4108
4109         * modules/vprintf-posix: New file.
4110         * lib/vprintf.c: New file.
4111         * m4/vprintf-posix.m4: New file.
4112         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
4113         REPLACE_VPRINTF.
4114         * lib/stdio_.h (vprintf): New declaration.
4115         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
4116         REPLACE_VPRINTF.
4117
4118 2007-03-08  Bruno Haible  <bruno@clisp.org>
4119
4120         * modules/fprintf-posix-tests: New file.
4121         * tests/test-fprintf-posix.sh: New file.
4122         * tests/test-fprintf-posix.c: New file.
4123
4124         * modules/fprintf-posix: New file.
4125         * lib/fprintf.c: New file.
4126         * m4/fprintf-posix.m4: New file.
4127         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
4128         REPLACE_FPRINTF.
4129         * lib/stdio_.h (fprintf): New declaration.
4130         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
4131         REPLACE_FPRINTF.
4132
4133 2007-03-08  Bruno Haible  <bruno@clisp.org>
4134
4135         * modules/vfprintf-posix-tests: New file.
4136         * tests/test-vfprintf-posix.sh: New file.
4137         * tests/test-vfprintf-posix.c: New file.
4138         * tests/test-fprintf-posix.h: New file.
4139         * tests/test-fprintf-posix.out: New file.
4140
4141         * modules/vfprintf-posix: New file.
4142         * lib/vfprintf.c: New file.
4143         * m4/vfprintf-posix.m4: New file.
4144         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
4145         REPLACE_VFPRINTF.
4146         * lib/stdio_.h (vfprintf): New declaration.
4147         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
4148         REPLACE_VFPRINTF.
4149
4150 2007-03-08  Bruno Haible  <bruno@clisp.org>
4151
4152         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
4153
4154 2007-03-08  Bruno Haible  <bruno@clisp.org>
4155
4156         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
4157         instead of 'expr' invocations.
4158         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
4159         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
4160         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
4161         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
4162         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
4163         Suggested by Paul Eggert.
4164
4165 2007-03-08  Bruno Haible  <bruno@clisp.org>
4166
4167         * modules/fseterr-tests: New file.
4168         * tests/test-fseterr.c: New file.
4169
4170         * modules/fseterr: New file.
4171         * lib/fseterr.h: New file.
4172         * lib/fseterr.c: New file.
4173
4174 2007-03-08  Bruno Haible  <bruno@clisp.org>
4175
4176         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
4177         * lib/getopt_.h: Likewise.
4178         * lib/mbswidth.h: Likewise.
4179         * lib/setenv.h: Likewise.
4180         * lib/vasnprintf.h: Likewise.
4181         * lib/vasprintf.h: Likewise.
4182         * lib/verror.h: Likewise.
4183         * lib/xsetenv.h: Likewise.
4184         * lib/xvasprintf.h: Likewise.
4185
4186 2007-03-08  Jim Meyering  <jim@meyering.net>
4187
4188         * users.txt: Add parted.
4189
4190         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
4191
4192 2007-03-07  Bruno Haible  <bruno@clisp.org>
4193
4194         * m4/printf.m4: Make the shell script snippets copy&pastable.
4195
4196 2007-03-02  Bruno Haible  <bruno@clisp.org>
4197
4198         * lib/netinet_in_.h: New file.
4199         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
4200         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
4201         * modules/netinet_in (Files): Add lib/netinet_in_.h.
4202         (Depends-on): Add absolute-header.
4203         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
4204         into netinet/in.h.
4205
4206 2007-03-03  Bruno Haible  <bruno@clisp.org>
4207
4208         * lib/sys_select_.h: New file.
4209         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
4210         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
4211         * modules/sys_select (Files): Add lib/sys_select_.h.
4212         (Depends-on): Add absolute-header.
4213         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
4214         into sys/select.h.
4215
4216 2007-03-02  Bruno Haible  <bruno@clisp.org>
4217
4218         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
4219         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
4220         values.
4221         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
4222         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
4223         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
4224         * modules/sys_socket (Depends-on): Add absolute-header.
4225         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
4226         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
4227         (Include): Remove requirement of inclusion of <sys/types.h>.
4228
4229 2007-03-02  Bruno Haible  <bruno@clisp.org>
4230
4231         * lib/byteswap_.h (bswap_32): Fix formula.
4232
4233 2007-03-06  Bruno Haible  <bruno@clisp.org>
4234
4235         * modules/sprintf-posix-tests: New file.
4236         * tests/test-sprintf-posix.c: New file.
4237
4238         * modules/sprintf-posix: New file.
4239         * lib/sprintf.c: New file.
4240         * m4/sprintf-posix.m4: New file.
4241         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
4242         REPLACE_SPRINTF.
4243         * lib/stdio_.h (sprintf): New declaration.
4244         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
4245         REPLACE_SPRINTF.
4246
4247 2007-03-06  Bruno Haible  <bruno@clisp.org>
4248
4249         * modules/vsprintf-posix-tests: New file.
4250         * tests/test-vsprintf-posix.c: New file.
4251         * tests/test-sprintf-posix.h: New file.
4252
4253         * modules/vsprintf-posix: New file.
4254         * lib/vsprintf.c: New file.
4255         * m4/vsprintf-posix.m4: New file.
4256         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
4257         REPLACE_VSPRINTF.
4258         * lib/stdio_.h (vsprintf): New declaration.
4259         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
4260         REPLACE_VSPRINTF.
4261
4262 2007-03-06  Bruno Haible  <bruno@clisp.org>
4263
4264         * modules/vsnprintf (Depend-on): Remove minmax.
4265
4266 2007-03-06  Bruno Haible  <bruno@clisp.org>
4267
4268         * modules/snprintf-posix-tests: New file.
4269         * tests/test-snprintf-posix.c: New file.
4270
4271         * modules/snprintf-posix: New file.
4272         * m4/snprintf-posix.m4: New file.
4273         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
4274         gl_FUNC_SNPRINTF.
4275         (gl_FUNC_SNPRINTF): Invoke it.
4276         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
4277         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
4278         is set.
4279         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
4280
4281 2007-03-06  Bruno Haible  <bruno@clisp.org>
4282
4283         * modules/vsnprintf-posix-tests: New file.
4284         * tests/test-vsnprintf-posix.c: New file.
4285         * tests/test-snprintf-posix.h: New file.
4286
4287         * modules/vsnprintf-posix: New file.
4288         * m4/vsnprintf-posix.m4: New file.
4289         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
4290         gl_FUNC_VSNPRINTF.
4291         (gl_FUNC_VSNPRINTF): Invoke it.
4292         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
4293         * lib/stdio_.h (vsnprintf): Define as a replacement if
4294         REPLACE_VSNPRINTF is set.
4295         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
4296
4297 2007-03-06  Bruno Haible  <bruno@clisp.org>
4298
4299         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
4300         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
4301
4302 2007-03-06  Bruno Haible  <bruno@clisp.org>
4303
4304         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
4305         (asinl): Declare also if HAVE_DECL_ASINL is set.
4306         (atanl): Declare also if HAVE_DECL_ATANL is set.
4307         (ceill): Declare also if HAVE_DECL_CEILL is set.
4308         (cosl): Declare also if HAVE_DECL_COSL is set.
4309         (expl): Declare also if HAVE_DECL_EXPL is set.
4310         (floorl): Declare also if HAVE_DECL_FLOORL is set.
4311         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
4312         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
4313         (logl): Declare also if HAVE_DECL_LOGL is set.
4314         (sinl): Declare also if HAVE_DECL_SINL is set.
4315         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
4316         (tanl): Declare also if HAVE_DECL_TANL is set.
4317         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
4318         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
4319         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
4320         declaration of frexpl, ldexpl.
4321         * modules/printf-frexpl (Depends-on): Add math.
4322         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
4323
4324 2007-03-05  Bruno Haible  <bruno@clisp.org>
4325
4326         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
4327         frexpl and ldexpl are declared.
4328         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
4329
4330 2007-03-05  Bruno Haible  <bruno@clisp.org>
4331
4332         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
4333         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
4334
4335 2007-03-05  Bruno Haible  <bruno@clisp.org>
4336
4337         * lib/stdio_.h: Include <stddef.h>.
4338
4339 2007-03-05  Bruno Haible  <bruno@clisp.org>
4340
4341         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
4342
4343 2007-03-05  Bruno Haible  <bruno@clisp.org>
4344
4345         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
4346         NetBSD 4, from Ralf Wildenhues.
4347
4348 2007-03-04  Bruno Haible  <bruno@clisp.org>
4349
4350         * lib/vasprintf.h: Update #if logic for the case when the functions
4351         exist but are overridden.
4352
4353 2007-03-04  Bruno Haible  <bruno@clisp.org>
4354
4355         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
4356         implementations: glibc-2.4 and MacOS X 10.3.
4357         * tests/test-vasnprintf-posix.c (test_function): Test also the case
4358         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
4359         * tests/test-vasprintf-posix.c (test_function): Likewise.
4360
4361 2007-03-04  Bruno Haible  <bruno@clisp.org>
4362
4363         * modules/vasprintf-posix-tests: New file.
4364         * tests/test-vasprintf-posix.c: New file.
4365
4366         * modules/vasprintf-posix: New file.
4367         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
4368         defined.
4369         * m4/vasprintf-posix.m4: New file.
4370         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
4371         gl_FUNC_VASPRINTF.
4372         (gl_FUNC_VASPRINTF): Invoke it.
4373         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
4374         here.
4375         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
4376
4377 2007-03-04  Bruno Haible  <bruno@clisp.org>
4378
4379         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
4380         REPLACE_GETTIMEOFDAY.
4381         * modules/sys_time (Makefile.am): Likewise.
4382         * m4/sys_time_h.m4: Likewise.
4383         * m4/gettimeofday.m4: Likewise.
4384
4385 2007-03-04  Bruno Haible  <bruno@clisp.org>
4386
4387         * modules/vasnprintf-posix-tests: New file.
4388         * tests/test-vasnprintf-posix.c: New file.
4389
4390         * modules/vasnprintf-posix: New file.
4391         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
4392         printf-frexpl.h.
4393         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
4394         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
4395         REPLACE_VASNPRINTF is defined.
4396         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
4397         gl_FUNC_VASNPRINTF.
4398         (gl_FUNC_VASNPRINTF): Invoke it.
4399         * m4/vasnprintf-posix.m4: New file.
4400         * m4/printf.m4: New file.
4401
4402 2007-03-04  Bruno Haible  <bruno@clisp.org>
4403
4404         Compile progreloc.c only if --enable-relocatable is specified.
4405         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
4406         if --enable-relocatable was specified.
4407         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
4408         lib_SOURCES.
4409
4410 2007-03-04  Jim Meyering  <jim@meyering.net>
4411
4412         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
4413         Use it consistently, rather than enumerating errno constants.
4414
4415 2007-03-04  Bruno Haible  <bruno@clisp.org>
4416
4417         * modules/xvasprintf-tests: New file.
4418         * tests/test-xvasprintf.c: New file.
4419
4420         * modules/vasprintf-tests: New file.
4421         * tests/test-vasprintf.c: New file.
4422
4423         * modules/vasnprintf-tests: New file.
4424         * tests/test-vasnprintf.c: New file.
4425
4426         * modules/vsnprintf-tests: New file.
4427         * tests/test-vsnprintf.c: New file.
4428
4429         * modules/snprintf-tests: New file.
4430         * tests/test-snprintf.c: New file.
4431
4432 2007-03-04  Bruno Haible  <bruno@clisp.org>
4433
4434         Compile relocatable.c only if --enable-relocatable is specified.
4435         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
4436         gl_RELOCATABLE_LIBRARY.
4437         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
4438         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
4439         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
4440         gl_RELOCATABLE_LIBRARY.
4441         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
4442         (Makefile.am): Remove lib_SOURCES.
4443         * modules/relocatable-lib-lgpl (configure.ac): Invoke
4444         gl_RELOCATABLE_LIBRARY.
4445         (Makefile.am): Remove lib_SOURCES.
4446         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
4447         always.
4448         * modules/relocatable-prog-wrapper (configure.ac): Invoke
4449         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
4450
4451 2007-03-04  Bruno Haible  <bruno@clisp.org>
4452
4453         * modules/argmatch-tests: New file.
4454         * tests/test-argmatch.c: New file.
4455
4456         * tests/test-allocsa.c (main): Halve the number of loop runs.
4457
4458         * modules/alloca-opt-tests: New file.
4459         * tests/test-alloca-opt.c: New file.
4460
4461 2007-03-04  Jim Meyering  <jim@meyering.net>
4462
4463         Work around difference between Linux ACLs and Solaris 10 ZFS.
4464         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
4465         for EINVAL.
4466
4467 2007-03-03  Bruno Haible  <bruno@clisp.org>
4468
4469         * modules/relocatable-prog (Depends-on): Add back progreloc's
4470         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
4471
4472 2007-03-03  Bruno Haible  <bruno@clisp.org>
4473
4474         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
4475         * modules/relocatable-lib: New file.
4476
4477 2007-03-03  Bruno Haible  <bruno@clisp.org>
4478
4479         * modules/relocatable-prog: Renamed from modules/relocatable.
4480         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
4481
4482 2007-03-03  Bruno Haible  <bruno@clisp.org>
4483
4484         * modules/relocatable-script (Files): Add doc/relocatable.texi,
4485         m4/relocatable-lib.m4.
4486         (Depends-on): Remove 'relocatable'.
4487         (configure.ac): Add gl_RELOCATABLE_NOP.
4488
4489 2007-03-03  Bruno Haible  <bruno@clisp.org>
4490
4491         * modules/relocatable-prog-wrapper: New file.
4492         * modules/relocatable (Depends-on): Add it. Remove all other
4493         dependencies except progname.
4494         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
4495
4496         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
4497         (gl_FUNC_STRERROR): Nop.
4498         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
4499
4500         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
4501         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
4502
4503         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
4504         (gl_FUNC_READLINK): Update.
4505
4506         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
4507
4508 2007-03-03  Bruno Haible  <bruno@clisp.org>
4509
4510         * lib/xreadlink.c: Include <unistd.h> unconditionally.
4511         * modules/xreadlink (Depends-on): Add unistd.
4512         * modules/xreadlink-with-size (Depends-on): Likewise.
4513
4514 2007-03-03  Bruno Haible  <bruno@clisp.org>
4515
4516         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
4517         extracted from gt_FUNC_SETENV.
4518         (gt_FUNC_SETENV): Remove macro.
4519         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
4520         remove gt_FUNC_SETENV.
4521
4522 2007-03-03  Bruno Haible  <bruno@clisp.org>
4523
4524         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
4525         ENABLE_RELOCATABLE here.
4526         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
4527
4528 2007-03-03  Bruno Haible  <bruno@clisp.org>
4529
4530         * modules/rbtreehash-list-tests (Depends-on): Add progname.
4531         * tests/test-rbtreehash_list.c: Include progname.h.
4532         (main): Call set_program_name.
4533
4534         * modules/rbtree-oset-tests (Depends-on): Add progname.
4535         * tests/test-rbtree_oset.c: Include progname.h.
4536         (main): Call set_program_name.
4537
4538         * modules/rbtree-list-tests (Depends-on): Add progname.
4539         * tests/test-rbtree_list.c: Include progname.h.
4540         (main): Call set_program_name.
4541
4542         * modules/linked-list-tests (Depends-on): Add progname.
4543         * tests/test-linked_list.c: Include progname.h.
4544         (main): Call set_program_name.
4545
4546 2007-03-03  Bruno Haible  <bruno@clisp.org>
4547
4548         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
4549         All uses of __restrict changed to _Restrict_.
4550         * lib/glob_.h (__restrict): Remove macro.
4551
4552 2007-03-02  Bruno Haible  <bruno@clisp.org>
4553
4554         * modules/gettext (configure.ac): Require gettext infrastructure
4555         from version 0.16.1.
4556
4557 2007-03-02  Bruno Haible  <bruno@clisp.org>
4558
4559         * modules/linkedhash-list-tests (Depends-on): Add progname.
4560         * tests/test-linkedhash_list.c: Include progname.h.
4561         (main): Call set_program_name.
4562
4563         * modules/carray-list-tests (Depends-on): Add progname.
4564         * tests/test-carray_list.c: Include progname.h.
4565         (main): Call set_program_name.
4566
4567         * modules/avltreehash-list-tests (Depends-on): Add progname.
4568         * tests/test-avltreehash_list.c: Include progname.h.
4569         (main): Call set_program_name.
4570
4571         * modules/avltree-oset-tests (Depends-on): Add progname.
4572         * tests/test-avltree_oset.c: Include progname.h.
4573         (main): Call set_program_name.
4574
4575         * modules/avltree-list-tests (Depends-on): Add progname.
4576         * tests/test-avltree_list.c: Include progname.h.
4577         (main): Call set_program_name.
4578
4579         * modules/array-oset-tests (Depends-on): Add progname.
4580         * tests/test-array_oset.c: Include progname.h.
4581         (main): Call set_program_name.
4582
4583         * modules/array-list-tests (Depends-on): Add progname.
4584         * tests/test-array_list.c: Include progname.h.
4585         (main): Call set_program_name.
4586
4587         * modules/argp-tests (Depends-on): Add progname.
4588         * tests/test-argp.c: Include argp.h first. Include progname.h.
4589         (main): Call set_program_name.
4590
4591 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
4592
4593         * doc/gnulib-tool.texi (Initial import): Reword description of
4594         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
4595         limited effect even if defined after the first system include.
4596
4597 2007-03-01  Bruno Haible  <bruno@clisp.org>
4598
4599         * build-aux/config.libpath: Update to libtool-1.5.22.
4600         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
4601
4602 2007-03-01  Bruno Haible  <bruno@clisp.org>
4603
4604         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
4605         foo_CFLAGS.
4606         Reported by Ralf Wildenhues.
4607
4608 2007-03-01  Bruno Haible  <bruno@clisp.org>
4609
4610         * build-aux/install-reloc: Remove object files left over by some
4611         compilers.
4612         Reported by Ralf Wildenhues.
4613
4614 2007-03-01  Bruno Haible  <bruno@clisp.org>
4615
4616         * build-aux/install-reloc: Break long lines.
4617
4618 2007-03-01  Bruno Haible  <bruno@clisp.org>
4619
4620         * doc/relocatable.texi: Document that it may not work on OpenBSD.
4621         Reported by Ralf Wildenhues.
4622
4623 2007-03-01  Bruno Haible  <bruno@clisp.org>
4624
4625         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
4626         include ordering constraints.
4627
4628 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
4629
4630         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
4631         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
4632         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
4633         as another example.
4634         * lib/time_.h: Fix misspelling.
4635         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4636         Require gl_HEADER_TIME_H_DEFAULTS.
4637         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
4638         * m4/time_r.m4 (gl_TIME_R): Likewise.
4639         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
4640
4641 2007-03-01  Bruno Haible  <bruno@clisp.org>
4642
4643         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
4644         * m4/utimens.m4 (gl_UTIMENS): Likewise.
4645
4646 2007-03-01  Jim Meyering  <jim@meyering.net>
4647
4648         * modules/xreadlink (Maintainer): Add my name.
4649         * modules/xreadlink-with-size (Depends-on): Alphabetize.
4650
4651 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
4652             Bruno Haible  <bruno@clisp.org>
4653
4654         * build-aux/install-reloc: Compile also c-ctype.c.
4655         * build-aux/relocatable.sh.in: New file.
4656         * doc/relocatable.texi: New file.
4657         * doc/relocatable-maint.texi: New file.
4658         * doc/gnulib.texi: Include relocatable-maint.texi.
4659         * lib/progreloc.c: Include unistd.h unconditionally.
4660         * lib/relocwrapper.c: Include unistd.h unconditionally.
4661         Include c-ctype.h.
4662         (add_dotbin): Use c_tolower.
4663         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
4664         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
4665         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
4666         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
4667         to m4/relocatable-lib.m4.
4668         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
4669         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
4670         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
4671         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
4672         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
4673         * modules/relocatable: New file.
4674         * modules/relocatable-lib: New file.
4675         * modules/relocatable-script: New file.
4676
4677 2007-02-28  Bruno Haible  <bruno@clisp.org>
4678
4679         Import --enable-relocatable infrastructure.
4680         * build-aux/config.libpath: New file, from GNU gettext.
4681         * build-aux/install-reloc: New file, from GNU gettext.
4682         * build-aux/reloc-ldflags: New file, from GNU gettext.
4683         * lib/relocatable.h: New file, from GNU gettext.
4684         * lib/relocatable.c: New file, from GNU gettext.
4685         * lib/relocwrapper.c: New file, from GNU gettext.
4686         * m4/relocatable.m4: New file, from GNU gettext.
4687
4688 2007-02-28  Bruno Haible  <bruno@clisp.org>
4689
4690         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
4691
4692         * modules/xreadlink: New file, from GNU gettext with modifications.
4693         * lib/xreadlink.c: New file, from GNU gettext.
4694         * lib/xreadlink.h: Add comments.
4695         (xreadlink): New declaration.
4696
4697         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
4698         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
4699         lib/xreadlink-with-size.c.
4700         (configure.ac): Remove gl_XREADLINK invocation.
4701         (Makefile.am): Augment lib_SOURCES.
4702         * m4/xreadlink.m4: Remove file.
4703         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
4704         (xreadlink_with_size): Renamed from xreadink.
4705         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
4706         * modules/canonicalize (Depends-on): Replace xreadlink with
4707         xreadlink-with-size.
4708         * lib/canonicalize.c (canonicalize_filename_mode): Update.
4709
4710 2007-02-25  Jim Meyering  <jim@meyering.net>
4711
4712         * build-aux/announce-gen: When complaining about excess arguments,
4713         list them.
4714
4715 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
4716
4717         * README: Document signed integer overflow situation more
4718         accurately.
4719
4720 2007-02-25  Bruno Haible  <bruno@clisp.org>
4721
4722         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
4723         'a' or 'A' conversion.
4724
4725 2007-02-25  Bruno Haible  <bruno@clisp.org>
4726
4727         * modules/filename: Renamed from modules/pathname.
4728         (Files): Replace lib/pathname.h with lib/filename.h. Replace
4729         lib/concatpath.c with lib/concat-filename.c.
4730         (Makefile.am): Update.
4731         (Include): Replace pathname.h with filename.h.
4732         * lib/filename.h: Renamed from lib/pathname.h.
4733         (concatenated_filename): Renamed from concatenated_pathname.
4734         * lib/concat-filename.c: Renamed from lib/concatpath.c.
4735         (concatenated_filename): Renamed from concatenated_pathname.
4736         * lib/findprog.c: Include filename.h instead of pathname.h.
4737         (find_in_path): Update.
4738         * lib/javacomp.c: Include filename.h instead of pathname.h.
4739         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
4740         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
4741         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
4742         is_oldgcj_14_13_usable, is_javac_usable): Update.
4743         * lib/javaexec.c: Include filename.h instead of pathname.h.
4744         (execute_java_class): Update.
4745         * modules/findprog: Update.
4746         * modules/javacomp: Update.
4747         * modules/javaexec: Update.
4748         * MODULES.html.sh (File system functions): Add 'filename', remove
4749         'pathname'.
4750
4751 2007-02-25  Bruno Haible  <bruno@clisp.org>
4752
4753         * modules/printf-frexpl-tests: New file.
4754         * tests/test-printf-frexpl.c: New file.
4755
4756         * modules/printf-frexpl: New file.
4757         * lib/printf-frexpl.h: New file.
4758         * lib/printf-frexpl.c: New file.
4759         * m4/printf-frexpl.m4: New file.
4760
4761 2007-02-25  Bruno Haible  <bruno@clisp.org>
4762
4763         * modules/printf-frexp-tests: New file.
4764         * tests/test-printf-frexp.c: New file.
4765
4766         * modules/printf-frexp: New file.
4767         * lib/printf-frexp.h: New file.
4768         * lib/printf-frexp.c: New file.
4769         * m4/printf-frexp.m4: New file.
4770
4771 2007-02-25  Bruno Haible  <bruno@clisp.org>
4772
4773         Assume automake >= 1.10 for the tests.
4774         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
4775         * modules/arctwo-tests: Likewise.
4776         * modules/argp-tests: Likewise.
4777         * modules/avltree-list-tests: Likewise.
4778         * modules/avltree-oset-tests: Likewise.
4779         * modules/avltreehash-list-tests: Likewise.
4780         * modules/carray-list-tests: Likewise.
4781         * modules/crc-tests: Likewise.
4782         * modules/des-tests: Likewise.
4783         * modules/gc-arcfour-tests: Likewise.
4784         * modules/gc-arctwo-tests: Likewise.
4785         * modules/gc-des-tests: Likewise.
4786         * modules/gc-hmac-md5-tests: Likewise.
4787         * modules/gc-hmac-sha1-tests: Likewise.
4788         * modules/gc-md2-tests: Likewise.
4789         * modules/gc-md4-tests: Likewise.
4790         * modules/gc-md5-tests: Likewise.
4791         * modules/gc-pbkdf2-sha1-tests: Likewise.
4792         * modules/gc-rijndael-tests: Likewise.
4793         * modules/gc-sha1-tests: Likewise.
4794         * modules/gc-tests: Likewise.
4795         * modules/getaddrinfo-tests: Likewise.
4796         * modules/hmac-md5-tests: Likewise.
4797         * modules/hmac-sha1-tests: Likewise.
4798         * modules/linked-list-tests: Likewise.
4799         * modules/linkedhash-list-tests: Likewise.
4800         * modules/lock-tests: Likewise.
4801         * modules/md2-tests: Likewise.
4802         * modules/md4-tests: Likewise.
4803         * modules/md5-tests: Likewise.
4804         * modules/rbtree-list-tests: Likewise.
4805         * modules/rbtree-oset-tests: Likewise.
4806         * modules/rbtreehash-list-tests: Likewise.
4807         * modules/read-file-tests: Likewise.
4808         * modules/rijndael-tests: Likewise.
4809         * modules/stdint-tests: Likewise.
4810         * modules/tls-tests: Likewise.
4811
4812 2007-02-24  Bruno Haible  <bruno@clisp.org>
4813
4814         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
4815         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
4816         function; instead check whether isnan with a double argument links.
4817         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
4818         function; instead check whether isnan with a 'long double' argument
4819         links.
4820         Reported by Eric Blake <ebb9@byu.net>.
4821
4822 2007-02-24  Bruno Haible  <bruno@clisp.org>
4823
4824         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
4825         defined.
4826         * lib/isnanl.c: Remove all code. Just include isnan.c.
4827         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
4828
4829 2007-02-25  Jim Meyering  <jim@meyering.net>
4830
4831         Avoid conflicting types for 'unsetenv' on FreeBSD.
4832         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
4833         conflicting with FreeBSD's (5.0 and 6.1) function declaration
4834         in stdlib.h.
4835
4836 2007-02-24  Bruno Haible  <bruno@clisp.org>
4837
4838         * modules/isnanl-nolibm-tests: New file.
4839         * tests/test-isnanl.c: New file.
4840
4841         * modules/isnanl-nolibm: New file.
4842         * lib/isnanl.h: New file.
4843         * lib/isnanl.c: New file.
4844         * m4/isnanl.m4: New file.
4845
4846 2007-02-24  Bruno Haible  <bruno@clisp.org>
4847
4848         * modules/isnan-nolibm-tests: New file.
4849         * tests/test-isnan.c: New file.
4850
4851         * modules/isnan-nolibm: New file.
4852         * lib/isnan.h: New file.
4853         * lib/isnan.c: New file.
4854         * m4/isnan.m4: New file.
4855
4856 2007-02-24  Bruno Haible  <bruno@clisp.org>
4857
4858         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
4859         assume that an exponent fits in 20 bits.
4860
4861 2007-02-24  Jim Meyering  <jim@meyering.net>
4862
4863         * m4/regex.m4: Update the description of the configure-time option,
4864         --without-included-regex, to state accurately what the defaults are,
4865         and perhaps to give people an idea why using this option is risky.
4866
4867 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
4868
4869         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
4870         loops on small arguments.  This attempts to avoid the problem
4871         Bruno Haible reported for AIX 4.3.2 in
4872         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
4873
4874 2007-02-23  Bruno Haible  <bruno@clisp.org>
4875
4876         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
4877         Needed for help2man.
4878
4879 2007-02-23  Karl Berry  <karl@gnu.org>
4880
4881         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
4882         exists, foo.h should be cvs-ignored, not committed.
4883
4884 2007-02-23  Eric Blake  <ebb9@byu.net>
4885
4886         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
4887         * lib/stat-time.h (includes): Likewise.
4888         * lib/utimecmp.c (includes): Likewise.
4889         * lib/utimens.h (includes): Likewise.
4890         * lib/getdate.y (includes): Also include "timespec.h" for use
4891         internal to the module.
4892         * modules/utimens (Depends-on): Revert yesterday's patch.
4893         * modules/nanosleep (Depends-on): Add missing dependency.
4894
4895 2007-02-22  Bruno Haible  <bruno@clisp.org>
4896
4897         * lib/glob.c: Don't include getlogin_r.h.
4898
4899 2007-02-22  Jim Meyering  <jim@meyering.net>
4900
4901         * modules/utimens (Depends-on): Add timespec, required for
4902         utimens.h's inclusion of timespec.h.
4903
4904 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
4905
4906         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
4907         long unreadable paths in GNU/Linux.  Problem reported by Andreas
4908         Schwab in
4909         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
4910         I'll try to think of a better way to fix the Solaris problem.
4911
4912         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
4913         like glibc; on Solaris 10, it fails with errno == EINVAL.
4914         POSIX says the behavior is unspecified if the first argument is NULL,
4915         so play it safe and never pass NULL to the system getcwd.
4916
4917 2007-02-21  Jim Meyering  <jim@meyering.net>
4918
4919         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
4920         of gettimeofday.  It would conflict with the one now always
4921         provided via sys_time_.h.  Reported by Matthew Woehlke, as
4922         an IRIX 6.5 build failure.
4923
4924 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
4925
4926         Minor fixups to port to Solaris 10 with Sun C 5.8.
4927         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
4928         * modules/getcwd (Depends-on): Add dirfd.
4929         * lib/putenv.c (putenv): #undef it.
4930         (rpl_putenv): New decl.
4931         (malloc, free): Include <stdlib.h> rather than prototyping separately.
4932
4933 2007-02-20  Bruno Haible  <bruno@clisp.org>
4934
4935         * modules/stdio-tests: New file.
4936         * tests/test-stdio.c: New file.
4937
4938         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
4939         (Depends-on): Add stdio.
4940         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
4941         (Include): Use <stdio.h> instead of vsnprintf.h.
4942         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
4943         HAVE_DECL_VSNPRINTF.
4944         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
4945
4946         * modules/snprintf (Files): Remove lib/snprintf.h.
4947         (Depends-on): Add stdio.
4948         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
4949         (Include): Use <stdio.h> instead of snprintf.h.
4950         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
4951         HAVE_DECL_SNPRINTF.
4952         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
4953         * lib/getaddrinfo.c: Likewise.
4954
4955         * modules/stdio: New file.
4956         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
4957         * lib/snprintf.h: Remove file.
4958         * lib/vsnprintf.h: Remove file.
4959         * lib/.cppi-disable: Remove snprintf.h.
4960         * m4/stdio_h.m4: New file.
4961         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
4962
4963 2007-02-20  Jim Meyering  <jim@meyering.net>
4964
4965         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
4966         used by e.g., mingw.  From Bruno Haible.
4967
4968 2007-02-19  Bruno Haible  <bruno@clisp.org>
4969
4970         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
4971         warnings.
4972         Reported by Ben Pfaff <blp@cs.stanford.edu>.
4973
4974 2007-02-19  Bruno Haible  <bruno@clisp.org>
4975
4976         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
4977         from mingw users.
4978
4979 2007-02-19  Bruno Haible  <bruno@clisp.org>
4980
4981         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
4982         warnings.
4983         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
4984
4985 2007-02-19  Jim Meyering  <jim@meyering.net>
4986
4987         Don't use FD after a successful "fdopendir (fd)".
4988         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
4989         Reset it by calling dirfd on the just-obtained DIR*.
4990
4991         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
4992         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
4993
4994 2007-02-18  Bruno Haible  <bruno@clisp.org>
4995
4996         * lib/readlink.c: Include <unistd.h>.
4997         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
4998         HAVE_READLINK.
4999         * modules/readlink (Depends-on): Add unistd.
5000         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5001         (Include): Add <unistd.h>.
5002
5003         * lib/getlogin_r.h: Remove file.
5004         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
5005         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
5006         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
5007         HAVE_DECL_GETLOGIN_R.
5008         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
5009         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5010         (Include): Use <unistd.h> instead of getlogin_r.h.
5011
5012         * lib/getcwd.h: Remove file.
5013         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
5014         * lib/xgetcwd.c: Likewise.
5015         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
5016         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
5017         * modules/getcwd (Files): Remove lib/getcwd.h.
5018         (Depends-on): Add unistd.
5019         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5020         (Include): Use <unistd.h> instad of getcwd.h.
5021
5022         * lib/ftruncate.c: Include <unistd.h> first.
5023         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
5024         Set HAVE_FTRUNCATE.
5025         * modules/ftruncate (Depends-on): Add unistd.
5026         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5027
5028         * lib/fchdir.c: Include <unistd.h> first.
5029         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
5030         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
5031         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
5032         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5033         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
5034
5035         * lib/dup2.c: Include <unistd.h> first.
5036         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
5037         HAVE_DUP2.
5038         * modules/dup2 (Depends-on): Add unistd.
5039         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5040
5041         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
5042         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
5043         REPLACE_CHOWN. Don't define chown as a macro here.
5044         * modules/chown (Depends-on): Add unistd.
5045         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5046
5047         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
5048         Add definition for GL_LINK_WARNING.
5049         (chown, dup2): New declarations.
5050         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
5051         link warning.
5052         (ftruncate): New declaration.
5053         (getcwd): New declaration, taken from old getcwd.h.
5054         (getlogin_r): New declaration, taken from old getlogin_r.h.
5055         (readlink): New declaration.
5056         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
5057         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
5058         (gl_PREREQ_UNISTD): Remove macro.
5059         (gl_UNISTD_MODULE_INDICATOR): New macro.
5060         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
5061         many new variables. Don't set UNISTD_H.
5062         * modules/unistd (Description): Change.
5063         (Depends-on): Add link-warning.
5064         (configure.ac): Update.
5065         (Makefile.am): Create unistd.h always. Substitute many new variables
5066         into it.
5067
5068 2007-02-18  Bruno Haible  <bruno@clisp.org>
5069
5070         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
5071         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
5072         HAVE_GETSUBOPT.
5073         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
5074         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
5075         * lib/getsubopt.h: Remove file.
5076         * modules/getsubopt (Files): Remove lib/getsubopt.h.
5077         (Depends-on): Add stdlib.
5078         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5079         (Includes): Use <stdlib.h> instead of getsubopt.h.
5080         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
5081         Set HAVE_GETSUBOPT.
5082         * lib/getsubopt.c: Don't include getsubopt.h.
5083
5084 2007-02-18  Bruno Haible  <bruno@clisp.org>
5085
5086         * modules/fchdir (Depends-on): Add dup2.
5087
5088 2007-02-18  Bruno Haible  <bruno@clisp.org>
5089
5090         * lib/stdlib_.h: Handle glibc's special invocation convention
5091         specially.
5092
5093 2007-02-18  Bruno Haible  <bruno@clisp.org>
5094
5095         * modules/stdlib-tests: New file.
5096         * tests/test-stdlib.c: New file.
5097
5098         * modules/mkstemp (Files): Remove lib/mkstemp.h.
5099         (Depends-on): Add stdlib.
5100         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5101         (Includes): Use <stdlib.h> instead of mkstemp.h.
5102         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5103         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
5104         * lib/mkstemp.c: Don't include mkstemp.h.
5105         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
5106         * lib/stdlib--.h: Don't include mkstemp.h.
5107
5108         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
5109         (Depends-on): Add stdlib.
5110         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5111         (Includes): Use <stdlib.h> instead of mkdtemp.h.
5112         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5113         HAVE_MKDTEMP.
5114         * lib/mkdtemp.c: Don't include mkdtemp.h.
5115         * lib/clean-temp.c: Don't include mkdtemp.h.
5116
5117         * modules/exit (Files): Remove lib/exit.h.
5118         (Depends-on): Add stdlib.
5119         (Makefile.am): Remove lib_SOURCES.
5120         (Include): Use <stdlib.h> instead of exit.h.
5121         * lib/argmatch.c: Don't include exit.h.
5122         * lib/execute.c: Likewise.
5123         * lib/pagealign_alloc.c: Likewise.
5124         * lib/pipe.c: Likewise.
5125         * lib/wait-process.c: Likewise.
5126         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
5127         * lib/exitfail.c: Likewise.
5128         * lib/savewd.c: Likewise.
5129         * lib/xsetenv.c: Likewise.
5130
5131         * modules/stdlib: New file.
5132         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
5133         and extra comments about mkstemp().
5134         * lib/exit.h: Remove file.
5135         * lib/mkdtemp.h: Remove file.
5136         * lib/mkstemp.h: Remove file.
5137         * m4/stdlib_h.m4: New file.
5138         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
5139
5140 2007-02-18  Bruno Haible  <bruno@clisp.org>
5141
5142         * modules/math-tests: New file.
5143         * tests/test-math.c: New file.
5144
5145         * modules/math: New file.
5146         * modules/mathl (Files): Remove lib/mathl.h.
5147         (Depends-on): Add math.
5148         (Makefile.am): Don't mention mathl.h.
5149         (Include): Use <math.h> instead of mathl.h.
5150         * lib/math_.h: New file.
5151         * lib/mathl.h: Remove file.
5152         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
5153         mathl.h.
5154         * lib/asinl.c: Likewise.
5155         * lib/atanl.c: Likewise.
5156         * lib/ceill.c: Likewise.
5157         * lib/cosl.c: Likewise.
5158         * lib/expl.c: Likewise.
5159         * lib/floorl.c: Likewise.
5160         * lib/frexpl.c: Likewise.
5161         * lib/ldexpl.c: Likewise.
5162         * lib/logl.c: Likewise.
5163         * lib/sincosl.c: Likewise.
5164         * lib/sinl.c: Likewise.
5165         * lib/sqrtl.c: Likewise.
5166         * lib/tanl.c: Likewise.
5167         * lib/trigl.c: Likewise.
5168         * m4/math_h.m4: New file.
5169         * MODULES.html.sh (Mathematics): Add math.
5170
5171 2007-02-17  Bruno Haible  <bruno@clisp.org>
5172
5173         * modules/wctype-tests: New file.
5174         * tests/test-wctype.c: New file.
5175
5176         * modules/wchar-tests: New file.
5177         * tests/test-wchar.c: New file.
5178
5179         * modules/unistd-tests: New file.
5180         * tests/test-unistd.c: New file.
5181
5182         * modules/time-tests: New file.
5183         * tests/test-time.c: New file.
5184
5185         * modules/sysexits-tests: New file.
5186         * tests/test-sysexits.c: New file.
5187
5188         * modules/sys_time-tests: New file.
5189         * tests/test-sys_time.c: New file.
5190
5191         * modules/sys_stat-tests: New file.
5192         * tests/test-sys_stat.c: New file.
5193
5194         * modules/sys_socket-tests: New file.
5195         * tests/test-sys_socket.c: New file.
5196
5197         * modules/sys_select-tests: New file.
5198         * tests/test-sys_select.c: New file.
5199
5200         * modules/string-tests: New file.
5201         * tests/test-string.c: New file.
5202
5203         * modules/stdbool-tests: New file.
5204         * tests/test-stdbool.c: New file.
5205
5206         * modules/netinet_in-tests: New file.
5207         * tests/test-netinet_in.c: New file.
5208
5209         * modules/inttypes-tests: New file.
5210         * tests/test-inttypes.c: New file.
5211
5212         * modules/fcntl-tests: New file.
5213         * tests/test-fcntl.c: New file.
5214
5215         * modules/byteswap-tests: New file.
5216         * tests/test-byteswap.c: New file.
5217
5218         * modules/arpa_inet-tests: New file.
5219         * tests/test-arpa_inet.c: New file.
5220
5221 2007-02-17  Bruno Haible  <bruno@clisp.org>
5222
5223         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
5224         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
5225         if the corresponding module is not enabled. Emit link warnings if
5226         the function is used nevertheless.
5227         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
5228         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
5229         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
5230         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
5231         * modules/inttypes (Depends-on): Add link-warning.
5232         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5233         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
5234         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
5235         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
5236         * modules/imaxdiv (configure.ac): Likewise.
5237         * modules/strtoimax (configure.ac): Likewise.
5238         * modules/strtoumax (configure.ac): Likewise.
5239
5240 2007-02-17  Bruno Haible  <bruno@clisp.org>
5241
5242         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
5243         gl_STRING_MODULE_INDICATOR_DEFAULTS.
5244         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
5245         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
5246
5247 2007-02-17  Bruno Haible  <bruno@clisp.org>
5248
5249         * modules/link-warning: New file.
5250         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
5251         * lib/string_.h (GL_LINK_WARNING): Remove definition.
5252         * modules/string (Depends-on): Add link-warning.
5253         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5254         string.h.
5255         * MODULES.html.sh (Support for building libraries and executables): Add
5256         link-warning.
5257
5258 2007-02-17  Bruno Haible  <bruno@clisp.org>
5259
5260         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
5261         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
5262         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
5263         long lines.
5264
5265 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
5266             Bruno Haible  <bruno@clisp.org>
5267
5268         * modules/tmpfile: New file.
5269         * lib/tmpfile.c: New file.
5270         * m4/tmpfile.m4: New file.
5271         * MODULES.html.sh (func_all_modules): New section "Input/output".
5272
5273 2007-02-15  Bruno Haible  <bruno@clisp.org>
5274
5275         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
5276         (supports_delete_on_close): New function.
5277         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
5278
5279 2007-02-14  Bruno Haible  <bruno@clisp.org>
5280
5281         * modules/mbspcasecmp-tests: New file.
5282         * tests/test-mbspcasecmp.sh: New file.
5283         * tests/test-mbspcasecmp.c: New file.
5284
5285         New module mbspcasecmp.
5286         * modules/mbspcasecmp: New file.
5287         * lib/mbspcasecmp.c: New file.
5288         * lib/string_.h (strncasecmp): Change warning message.
5289         (mbspcasecmp): New declaration.
5290         * m4/mbspcasecmp.m4: New file.
5291         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5292         GNULIB_MBSPCASECMP.
5293         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
5294         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
5295
5296 2007-02-14  Bruno Haible  <bruno@clisp.org>
5297
5298         * modules/mbsncasecmp-tests: New file.
5299         * tests/test-mbsncasecmp.sh: New file.
5300         * tests/test-mbsncasecmp.c: New file.
5301
5302         New module mbsncasecmp.
5303         * modules/mbsncasecmp: New file.
5304         * lib/mbsncasecmp.c: New file.
5305         * lib/string_.h (mbsncasecmp): New declaration.
5306         * m4/mbsncasecmp.m4: New file.
5307         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5308         GNULIB_MBSNCASECMP.
5309         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
5310         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
5311
5312 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
5313
5314         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
5315         Verify that it doesn't overlap with our flags.
5316         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
5317         do not have the desired effect in multibyte locales; instead, use
5318         mbscasecmp.
5319         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
5320         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
5321         we don't require GNU fnmatch ourselves (if our users require it, they
5322         should do so explicitly).
5323
5324         Fix regex code so it doesn't rely on strcasecmp.
5325         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
5326         Otherwise, include gnulib's langinfo.h.
5327         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
5328         undesirable behavior in non-C locales.  Instead, rely on localecharset.
5329         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
5330         * modules/regex (FILES): Remove m4/codeset.m4.
5331         (Depends-on): Add localcharset.  Remove strcase.
5332
5333 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5334
5335         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
5336         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
5337
5338 2007-02-13  Bruno Haible  <bruno@clisp.org>
5339
5340         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
5341         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5342
5343 2007-02-12  Bruno Haible  <bruno@clisp.org>
5344
5345         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
5346         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
5347         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
5348         time warning rather than a link error.
5349
5350 2007-02-12  Bruno Haible  <bruno@clisp.org>
5351
5352         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
5353         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
5354         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5355
5356 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5357
5358         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
5359         args, not 2.
5360
5361 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5362
5363         New module 'time', so that apps can include <time.h> as per
5364         POSIX and GNU instead of separate include files like time_r.h
5365         and timegm.h.  This implementation tries out a simpler approach
5366         for replacing decls in standard include files (as compared to
5367         the string module), somewhat as an experiment.
5368
5369         * config/srclist.txt: Comment out mktime.c for now.
5370         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
5371         since it doesn't apply any more.  Use generic wording instead.
5372         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
5373         'time'.
5374         * lib/time_.h, m4/time_h.m4, modules/time: New files.
5375         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
5376         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
5377         Don't include <sys/types.h>; no longer needed since we assume C89.
5378         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
5379         * lib/strftime.c: Likewise.
5380         * lib/time_r.c: Likewise.
5381         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
5382         * lib/nanosleep.c: Include <time.h> first, to check interface.
5383         * lib/strptime.c: Likewise.
5384         * lib/time_r.c: Likewise.
5385         * lib/timegm.c: Likewise.
5386         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
5387         needed.
5388         * lib/timegm.c: Don't include timegm.h; no longer needed.
5389         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
5390         time.h now handles any problems in that area.
5391         (struct timespec, nanosleep): Remove; time.h now arranges for these.
5392         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
5393         that time.h defines struct timespec.
5394         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
5395         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
5396         handles that.
5397         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
5398         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
5399         needed.  Set REPLACE_LOCALTIME.
5400         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
5401         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
5402         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
5403         nanosleep; time_h.m4 now does that.  Don't require
5404         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
5405         module handles this now.
5406         * modules/getdate (Depends-on): Remove timespec.  Add time.
5407         * modules/nanosleep (Depends-on): Likewise.
5408         * modules/stat-time (Depends-on): Likewise.
5409         * modules/nanosleep (Include): Include time.h, not timespec.h.
5410         * modules/strptime (Files): Remove lib/strptime.h.
5411         (Depends-on): Add extensions, time.
5412         (Include): Include time.h, not strptime.h.
5413         * modules/time_r (Files): Remove lib/time_r.h.
5414         (Depends-on): Add time.
5415         (Include): Include time.h, not time_r.h.
5416         * modules/timegm: Likewise.
5417         * modules/timespec (Description): Now does timespec-related decls
5418         of our own, instead of struct timespec itself.
5419         (Depends-on): Add time; remove extensions.
5420         (Maintainer): Add self.
5421         * modules/utimecmp (Depends-on): Add time; remove timespec.
5422         * modules/utimens (Depends-on): Likewise.
5423         * modules/xnanosleep (Depends-on): Likewise.
5424
5425 2007-02-11  Bruno Haible  <bruno@clisp.org>
5426
5427         * lib/c-strstr.c: Include allocsa.h.
5428         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5429         * lib/c-strcasestr.c: Include allocsa.h.
5430         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5431         * lib/strcasestr.c: Include allocsa.h.
5432         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5433         * lib/mbsstr.c: Include allocsa.h.
5434         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5435         allocsa/freesa instead of malloc/free.
5436         * lib/mbscasestr.c: Include allocsa.h.
5437         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5438         allocsa/freesa instead of malloc/free.
5439         * modules/c-strstr (Depends-on): Add allocsa.
5440         * modules/c-strcasestr (Depends-on): Likewise.
5441         * modules/strcasestr (Depends-on): Likewise.
5442         * modules/mbsstr (Depends-on): Likewise.
5443         * modules/mbscasestr (Depends-on): Likewise.
5444
5445 2007-02-11  Bruno Haible  <bruno@clisp.org>
5446
5447         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
5448
5449         * modules/mbsspn-tests: New file.
5450         * tests/test-mbsspn.sh: New file.
5451         * tests/test-mbsspn.c: New file.
5452
5453 2007-02-11  Bruno Haible  <bruno@clisp.org>
5454
5455         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
5456
5457         * modules/mbspbrk-tests: New file.
5458         * tests/test-mbspbrk.sh: New file.
5459         * tests/test-mbspbrk.c: New file.
5460
5461 2007-02-11  Bruno Haible  <bruno@clisp.org>
5462
5463         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
5464         unneeded cast.
5465
5466         * modules/mbscspn-tests: New file.
5467         * tests/test-mbscspn.sh: New file.
5468         * tests/test-mbscspn.c: New file.
5469
5470 2007-02-11  Bruno Haible  <bruno@clisp.org>
5471
5472         * modules/mbscasecmp-tests: New file.
5473         * tests/test-mbscasecmp.sh: New file.
5474         * tests/test-mbscasecmp.c: New file.
5475
5476 2007-02-11  Bruno Haible  <bruno@clisp.org>
5477
5478         Ensure O(n) worst-case complexity of mbscasestr.
5479         * lib/mbscasestr.c: Include stdbool.h.
5480         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5481         functions.
5482         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
5483         the bookkeeping indicates that it's worth it.
5484         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
5485
5486         * modules/mbscasestr-tests: New file.
5487         * tests/test-mbscasestr1.c: New file.
5488         * tests/test-mbscasestr2.sh: New file.
5489         * tests/test-mbscasestr2.c: New file.
5490         * tests/test-mbscasestr3.sh: New file.
5491         * tests/test-mbscasestr3.c: New file.
5492         * tests/test-mbscasestr4.sh: New file.
5493         * tests/test-mbscasestr4.c: New file.
5494         * m4/locale-tr.m4: New file.
5495
5496 2007-02-11  Bruno Haible  <bruno@clisp.org>
5497
5498         Ensure O(n) worst-case complexity of mbsstr.
5499         * lib/mbsstr.c: Include stdbool.h.
5500         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5501         functions.
5502         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
5503         bookkeeping indicates that it's worth it.
5504         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
5505
5506         * modules/mbsstr-tests: New file.
5507         * tests/test-mbsstr1.c: New file.
5508         * tests/test-mbsstr2.sh: New file.
5509         * tests/test-mbsstr2.c: New file.
5510         * tests/test-mbsstr3.sh: New file.
5511         * tests/test-mbsstr3.c: New file.
5512         * m4/locale-fr.m4: New file.
5513
5514 2007-02-11  Bruno Haible  <bruno@clisp.org>
5515
5516         * lib/mbsrchr.c (mbsrchr): Fix bug.
5517
5518         * modules/mbsrchr-tests: New file.
5519         * tests/test-mbsrchr.sh: New file.
5520         * tests/test-mbsrchr.c: New file.
5521
5522 2007-02-11  Bruno Haible  <bruno@clisp.org>
5523
5524         * lib/mbschr.c (mbschr): Fix bug.
5525
5526         * modules/mbschr-tests: New file.
5527         * tests/test-mbschr.sh: New file.
5528         * tests/test-mbschr.c: New file.
5529         * m4/locale-zh.m4: New file.
5530
5531 2007-02-11  Bruno Haible  <bruno@clisp.org>
5532
5533         Support for copying multibyte string iterators.
5534         * lib/mbiter.h: Include <string.h>.
5535         (mbiter_multi_copy): New function.
5536         (mbi_copy): New macro.
5537         * lib/mbuiter.h: Include <string.h>.
5538         (mbuiter_multi_copy): New function.
5539         (mbui_copy): New macro.
5540
5541 2007-02-11  Bruno Haible  <bruno@clisp.org>
5542
5543         New module mbslen.
5544         * modules/mbslen: New file.
5545         * lib/mbslen.c: New file.
5546         * lib/string_.h (mbslen): New declaration.
5547         * m4/mbslen.m4: New file.
5548         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5549         GNULIB_MBSLEN.
5550         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
5551         * MODULES.html.sh (Internationalization functions): Add mbslen.
5552
5553 2007-02-11  Bruno Haible  <bruno@clisp.org>
5554
5555         Ensure O(n) worst-case complexity of strcasestr substitute.
5556         * lib/strcasestr.c: Include stdbool.h.
5557         (knuth_morris_pratt): New function.
5558         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
5559         bookkeeping indicates that it's worth it.
5560         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
5561
5562         * modules/strcasestr-tests: New file.
5563         * tests/test-strcasestr.c: New file.
5564
5565 2007-02-11  Bruno Haible  <bruno@clisp.org>
5566
5567         Ensure O(n) worst-case complexity of c_strcasestr.
5568         * lib/c-strcasestr.c: Include stdbool.h, string.h.
5569         (knuth_morris_pratt): New function.
5570         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
5571         the bookkeeping indicates that it's worth it.
5572         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
5573
5574         * modules/c-strcasestr-tests: New file.
5575         * tests/test-c-strcasestr.c: New file.
5576
5577 2007-02-11  Bruno Haible  <bruno@clisp.org>
5578
5579         Ensure O(n) worst-case complexity of c_strstr.
5580         * lib/c-strstr.c: Include stdbool.h, string.h.
5581         (knuth_morris_pratt): New function.
5582         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
5583         bookkeeping indicates that it's worth it.
5584         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
5585
5586         * lib/c-strstr.c: Complete rewrite for maintainability.
5587
5588         * modules/c-strstr-tests: New file.
5589         * tests/test-c-strstr.c: New file.
5590
5591 2007-02-11  Bruno Haible  <bruno@clisp.org>
5592
5593         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
5594         5.2.1 and earlier, whereby \055 was treated just like the range
5595         delimiter '-'.
5596         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
5597
5598 2007-02-08  Bruno Haible  <bruno@clisp.org>
5599
5600         * modules/regex (Depends-on): Add stdbool.
5601         Reported by Dalibor Topic <robilad@kaffe.org>.
5602
5603 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
5604
5605         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
5606         Prefer returning from main to exiting from it.
5607         Remove unnecessary parens after sizeof.
5608
5609 2007-02-05  Bruno Haible  <bruno@clisp.org>
5610
5611         New module mbssep.
5612         * modules/mbssep: New file.
5613         * lib/mbssep.c: New file.
5614         * lib/string_.h (strsep): Add a conditional link warning.
5615         (mbssep): New declaration.
5616         * m4/mbssep.m4: New file.
5617         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5618         GNULIB_MBSSEP.
5619         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
5620         * MODULES.html.sh (Internationalization functions): Add mbssep.
5621
5622 2007-02-05  Bruno Haible  <bruno@clisp.org>
5623
5624         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
5625         Optimize search in case of 1 delimiter.
5626
5627 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
5628
5629         * lib/acl.h: Include sys/types.h before sys/acl.h.
5630
5631 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
5632
5633         Merge upstream fix for glibc bugzilla #3957:
5634
5635         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
5636
5637         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
5638         bit for RE_HAT_LISTS_NOT_NEWLINE.
5639         (build_charclass_op): Remove bogus comment.
5640
5641 2007-02-05  Simon Josefsson  <simon@josefsson.org>
5642
5643         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
5644
5645 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
5646
5647         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
5648         * lib/memmem.c [!defined _LIBC]: Include config.h.
5649
5650 2007-02-04  Bruno Haible  <bruno@clisp.org>
5651
5652         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
5653         warning message.
5654
5655 2007-02-04  Bruno Haible  <bruno@clisp.org>
5656
5657         New module mbstok_r.
5658         * modules/mbstok_r: New file.
5659         * lib/mbstok_r.c: New file.
5660         * lib/string_.h (strtok_r): Change argument names to match the
5661         comments. Add a conditional link warning.
5662         (mbstok_r): New declaration.
5663         * m4/mbstok_r.m4: New file.
5664         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5665         GNULIB_MBSTOK_R.
5666         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
5667         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
5668
5669 2007-02-04  Bruno Haible  <bruno@clisp.org>
5670
5671         New module mbsspn.
5672         * modules/mbsspn: New file.
5673         * lib/mbsspn.c: New file.
5674         * lib/string_.h (strspn): Add a conditional link warning.
5675         (mbsspn): New declaration.
5676         * m4/mbsspn.m4: New file.
5677         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5678         GNULIB_MBSSPN.
5679         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
5680         * MODULES.html.sh (Internationalization functions): Add mbsspn.
5681
5682 2007-02-04  Bruno Haible  <bruno@clisp.org>
5683
5684         New module mbspbrk.
5685         * modules/mbspbrk: New file.
5686         * lib/mbspbrk.c: New file.
5687         * lib/string_.h (strpbrk): Add a conditional link warning.
5688         (mbspbrk): New declaration.
5689         * m4/mbspbrk.m4: New file.
5690         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5691         GNULIB_MBSPBRK.
5692         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
5693         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
5694
5695 2007-02-04  Bruno Haible  <bruno@clisp.org>
5696
5697         New module mbscspn.
5698         * modules/mbscspn: New file.
5699         * lib/mbscspn.c: New file.
5700         * lib/string_.h (strcspn): Add a conditional link warning.
5701         (mbscspn): New declaration.
5702         * m4/mbscspn.m4: New file.
5703         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5704         GNULIB_MBSCSPN.
5705         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
5706         * MODULES.html.sh (Internationalization functions): Add mbscspn.
5707
5708 2007-02-04  Bruno Haible  <bruno@clisp.org>
5709
5710         New module mbscasestr, reduced goal of strcasestr.
5711         * modules/mbscasestr: New file.
5712         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
5713         (mbscasestr): Renamed from strcasestr.
5714         * lib/strcasestr.c: Don't include mbuiter.h.
5715         (strcasestr): Remove support for multibyte locales.
5716         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
5717         Change the conditional link warning.
5718         (mbscasestr): New declaration.
5719         * m4/mbscasestr.m4: New file.
5720         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
5721         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
5722         REPLACE_STRCASESTR.
5723         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
5724         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
5725         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
5726         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
5727         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
5728         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
5729         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
5730         (Depends-on): Remove mbuiter.
5731         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
5732
5733 2007-02-04  Bruno Haible  <bruno@clisp.org>
5734
5735         Simplify handling of strncasecmp.
5736         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
5737         the conditional link warning.
5738         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
5739         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
5740         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
5741         * modules/strcase (configure.ac): Don't invoke
5742         gl_STRING_MODULE_INDICATOR.
5743         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
5744
5745 2007-02-04  Bruno Haible  <bruno@clisp.org>
5746
5747         New module mbscasecmp, reduced goal of strcasecmp.
5748         * modules/mbscasecmp: New file.
5749         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
5750         (mbscasecmp): Renamed from strcasecmp.
5751         * lib/strcasecmp.c: Don't include mbuiter.h.
5752         (strcasecmp): Remove support for multibyte locales.
5753         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
5754         Change the conditional link warning.
5755         (mbscasecmp): New declaration.
5756         * m4/mbscasecmp.m4: New file.
5757         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
5758         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
5759         REPLACE_STRCASECMP.
5760         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
5761         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5762         GNULIB_MBSCASECMP.
5763         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
5764         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
5765         * modules/strcase (Files): Remove m4/mbrtowc.m4.
5766         (Depends-on): Remove mbuiter.
5767         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
5768
5769 2007-02-04  Bruno Haible  <bruno@clisp.org>
5770
5771         New module mbsstr. Remove module strstr.
5772         * modules/mbsstr: New file.
5773         * modules/strstr: Remove file.
5774         * lib/mbsstr.c: Renamed from lib/strstr.c.
5775         (mbsstr): Renamed from strstr.
5776         * lib/string_.h (strstr): Remove declaration. Change the conditional
5777         link warning.
5778         (mbsstr): New declaration.
5779         * m4/mbsstr.m4: New file.
5780         * m4/strstr.m4: Remove file.
5781         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
5782         REPLACE_STRSTR.
5783         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
5784         Don't initialize GNULIB_STRSTR.
5785         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
5786         substitute GNULIB_STRSTR and REPLACE_STRSTR.
5787         * MODULES.html.sh (Internationalization functions): Add mbsstr.
5788         (Support for systems lacking ANSI C 89): Remove strstr.
5789
5790 2007-02-04  Bruno Haible  <bruno@clisp.org>
5791
5792         New module mbsrchr.
5793         * modules/mbsrchr: New file.
5794         * lib/mbsrchr.c: New file.
5795         * lib/string_.h (strrchr): Add a conditional link warning.
5796         (mbsrchr): New declaration.
5797         * m4/mbsrchr.m4: New file.
5798         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5799         GNULIB_MBSRCHR.
5800         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
5801         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
5802
5803 2007-02-04  Bruno Haible  <bruno@clisp.org>
5804
5805         New module mbschr.
5806         * modules/mbschr: New file.
5807         * lib/mbschr.c: New file.
5808         * lib/string_.h (strchr): Add a conditional link warning.
5809         (mbschr): New declaration.
5810         * m4/mbschr.m4: New file.
5811         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5812         GNULIB_MBSCHR.
5813         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
5814         * MODULES.html.sh (Internationalization functions): Add mbschr.
5815
5816 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
5817
5818         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
5819
5820         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
5821
5822 2007-02-04  Bruno Haible  <bruno@clisp.org>
5823
5824         New module description section 'configure.ac-early'.
5825         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
5826         (func_get_autoconf_early_snippet): New function.
5827         (func_import, func_create_testdir): Use it. Remove special cases for
5828         modules 'extensions' and 'lock'.
5829         * modules/extensions (configure.ac-early): Require
5830         gl_USE_SYSTEM_EXTENSIONS.
5831         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
5832
5833 2007-02-04  Bruno Haible  <bruno@clisp.org>
5834
5835         Make use of gcj-4.3's -fsource and -ftarget option.
5836         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
5837         and if so try the options -fsource and -ftarget.
5838         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
5839         source_version, ftarget_option, target_version arguments.
5840         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
5841         (is_envjavac_oldgcj_14_14_usable): Renamed from
5842         is_envjavac_gcj_14_14_usable.
5843         (is_envjavac_oldgcj_14_13_usable): Renamed from
5844         is_envjavac_gcj_14_13_usable.
5845         (is_gcj_present): Update.
5846         (is_gcj_43, is_gcj43_usable): New functions.
5847         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
5848         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
5849         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
5850         try the options -fsource and -ftarget.
5851
5852 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
5853
5854         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
5855         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
5856         larger value.
5857
5858 2007-02-03  Jim Meyering  <jim@meyering.net>
5859
5860         Give tools a better chance to allocate space for very large buffers.
5861         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
5862
5863         Make pwd and readlink work also when run with an unreadable parent dir
5864         on systems with openat support.
5865         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
5866         provided getcwd function, even when we have openat support.
5867         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
5868
5869 2007-02-02  Bruno Haible  <bruno@clisp.org>
5870
5871         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
5872         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
5873         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
5874         portability problems if one of these functions is only used on specific
5875         platforms.
5876         Reported by Paul Eggert.
5877
5878 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
5879
5880         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
5881         is causing more trouble than it's curing.
5882         * lib/regex_internal.h (__mempcpy): Remove.
5883         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
5884         (and make the code a tad smaller to boot).
5885         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
5886
5887 2007-02-02  Jim Meyering  <jim@meyering.net>
5888
5889         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
5890         section, not in the Makefile.am: one.
5891
5892 2007-02-02  Eric Blake  <ebb9@byu.net>
5893
5894         * lib/strchrnul.c: Always include config.h first.
5895
5896         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
5897         gnulib strstr is not necessary here.
5898
5899 2007-02-02  Simon Josefsson  <simon@josefsson.org>
5900
5901         * m4/socklen.m4: Fix typo.
5902
5903 2007-02-02  Eric Blake  <ebb9@byu.net>
5904
5905         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
5906         * modules/netinet_in (Makefile.am): Likewise.
5907
5908 2007-02-01  Bruno Haible  <bruno@clisp.org>
5909
5910         * lib/string_.h (GL_LINK_WARNING): New macro.
5911         (strcasecmp, strstr, strcasestr): If provided by the system,
5912         conditionally define as a macro that leads to a warning instead of to
5913         an error.
5914         (strncasecmp): Conditionally define as a macro that leads to a warning.
5915
5916 2007-02-01  Karl Berry  <karl@gnu.org>
5917
5918         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
5919
5920 2007-02-01  Bruno Haible  <bruno@clisp.org>
5921
5922         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
5923         renamings.
5924
5925 2007-02-01  Eric Blake  <ebb9@byu.net>
5926
5927         * modules/regex (Depends-on): Revert dependence on mempcpy.
5928         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
5929         module's definition of mempcpy.
5930         Reported by Paul Eggert.
5931
5932 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
5933
5934         * lib/string_.h: If the gnulib module XYZ is not present, undefine
5935         the symbol XYZ before redefining it.  This fixes a problem with
5936         programs that don't use XYZ, when compiled on systems that define
5937         XYZ to something else.
5938
5939 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
5940
5941         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
5942         occurs when "mkdir -m foo" creates a setgid directory that is (1)
5943         writeable to group or other and (2) is intended to have a special
5944         mode bit that is set or cleared.  In such a case, the directory
5945         should be neither group- nor other-writeable until the special
5946         mode bits are right.
5947
5948 2007-01-31  Eric Blake  <ebb9@byu.net>
5949
5950         * modules/mountlist (Depends-on): Add strstr.
5951
5952         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
5953         bug.
5954         * modules/string (Makefile.am): Remove redundant replacement.
5955         * modules/regex (Depends-on): Add mempcpy.
5956
5957 2007-01-31  Bruno Haible  <bruno@clisp.org>
5958
5959         New module description field 'Link'.
5960         * gnulib-tool (func_usage): Document --extract-link-directive.
5961         (sed_extract_prog): Recognize 'Link' directive.
5962         (func_get_link_directive): New function.
5963         (func_import): Show summary of link directives.
5964         Handle --extract-link-directive option.
5965         * modules/acl (Link): New section.
5966         * modules/clock-time (Link): New section.
5967         * modules/euidaccess (Link): New section.
5968         * modules/gettext (Link): New section.
5969         * modules/iconv (Link): New section.
5970         * modules/lock (Link): New section.
5971         * modules/nanosleep (Link): New section.
5972         * modules/readline (Link): New section.
5973
5974 2007-01-27  Bruno Haible  <bruno@clisp.org>
5975
5976         Enforce the use of gnulib modules for unportable <string.h> functions.
5977         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
5978         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
5979         (gl_HEADER_STRING_H_BODY): Require it.
5980         * lib/string_.h: If the gnulib module XYZ is not present, redefine
5981         the symbol XYZ to one that gives a link error.
5982         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
5983         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
5984         * modules/mempcpy (configure.ac): Likewise.
5985         * modules/memrchr (configure.ac): Likewise.
5986         * modules/stpcpy (configure.ac): Likewise.
5987         * modules/stpncpy (configure.ac): Likewise.
5988         * modules/strcase (configure.ac): Likewise.
5989         * modules/strcasestr (configure.ac): Likewise.
5990         * modules/strchrnul (configure.ac): Likewise.
5991         * modules/strdup (configure.ac): Likewise.
5992         * modules/strndup (configure.ac): Likewise.
5993         * modules/strnlen (configure.ac): Likewise.
5994         * modules/strpbrk (configure.ac): Likewise.
5995         * modules/strsep (configure.ac): Likewise.
5996         * modules/strstr (configure.ac): Likewise.
5997         * modules/strtok_r (configure.ac): Likewise.
5998
5999 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
6000
6001         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
6002
6003 2007-01-30  Jim Meyering  <jim@meyering.net>
6004
6005         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
6006
6007 2007-01-29  Bruno Haible  <bruno@clisp.org>
6008
6009         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
6010         * lib/execute.c: Likewise.
6011         * lib/pipe.c: Likewise.
6012         * lib/printf-args.h: Likewise.
6013         * lib/printf-args.c: Likewise.
6014         * lib/printf-parse.c: Likewise.
6015         * lib/vasnprintf.c: Likewise.
6016
6017 2007-01-29  Eric Blake  <ebb9@byu.net>
6018
6019         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
6020         declaration.
6021
6022 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
6023
6024         * lib/strptime.h (strptime): Use 'restrict' for args where
6025         POSIX requires this.
6026         * lib/strptime.c (strptime): Likewise.
6027         Change license notice from LGPL to GPL, since gnulib-tool will
6028         change this as needed.
6029         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
6030         defined.
6031         Include "strptime.h" first, to check interface.
6032         Do not #undef _LIBC and _NL_CURRENT.
6033         Do not include <stdlib.h>; no longer needed.
6034         Include "time_r.h" and declare ptime_locale_status
6035         only if _LIBC is not defined.
6036         (__P): Remove unused macro.
6037         (match_string): Bring back glibc version, but use it only if _LIBC
6038         is defined.
6039         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
6040         Remove unnecessary assertion and abort() call.
6041         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
6042         * m4/strptime.m4: Fix serial number comment.
6043         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
6044         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
6045         (Depends-on): Add time_r.
6046
6047 2007-01-29  Bruno Haible  <bruno@clisp.org>
6048
6049         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6050         strptime.
6051         * modules/strptime (Depends-on): Add stdbool.
6052         * lib/strptime.h: Include <time.h> always. Add comments.
6053
6054 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
6055
6056         * modules/strptime: New file.
6057         * lib/strptime.h: New file.
6058         * lib/strptime.c: New file.
6059         * m4/strptime.m4: New file.
6060
6061 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
6062
6063         * MODULES.html.sh: New module mpsort.
6064         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
6065
6066         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
6067         a circularity problem with HP-UX ia64 reported by Bob Proulx in
6068         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
6069         All uses changed.
6070         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
6071         All uses changed.
6072         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
6073         to _Restrict_.
6074         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
6075         the parameter matches the prototype.
6076
6077 2007-01-28  Jim Meyering  <jim@meyering.net>
6078
6079         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
6080         sys/time.h here, reverting that part of the previous patch:
6081         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
6082
6083 2007-01-28  Bruno Haible  <bruno@clisp.org>
6084
6085         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
6086         value of $(SYS_TIME_H).
6087         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
6088         remove it conditionally, too. [added by Jim Meyering]
6089         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
6090         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6091         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
6092         GETTIMEOFDAY_REPLACEMENT to 1.
6093
6094 2007-01-28  Bruno Haible  <bruno@clisp.org>
6095
6096         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
6097         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
6098         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
6099         Set UNISTD_H instead of UNISTD_H2.
6100         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
6101
6102 2007-01-28  Bruno Haible  <bruno@clisp.org>
6103
6104         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
6105         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
6106
6107 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6108
6109         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
6110         (func_create_testdir): Ensure C locale for `grep' and `tr'
6111         character ranges.
6112         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
6113         ACLOCAL_AMFLAGS parsing state machine.
6114
6115 2007-01-27  Bruno Haible  <bruno@clisp.org>
6116
6117         * modules/unistr/base: Update.
6118
6119 2007-01-27  Bruno Haible  <bruno@clisp.org>
6120
6121         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
6122         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
6123         * modules/unistr/u32-mbtouc-unsafe: Renamed from
6124         modules/unistr/u32-mbtouc.
6125         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
6126         * lib/unistr.h: Update.
6127         * lib/linebreak.c: Update.
6128         * modules/unistr/u32-mbtouc: Renamed from
6129         modules/unistr/u32-mbtouc-safe.
6130         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
6131         * lib/unistr.h: Update.
6132         * lib/unistr/u32-to-u8.c: Update.
6133         * lib/unistr/u32-to-u16.c: Update.
6134
6135 2007-01-27  Bruno Haible  <bruno@clisp.org>
6136
6137         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
6138         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
6139         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
6140         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
6141         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
6142         * modules/unistr/u16-mbtouc-unsafe: Renamed from
6143         modules/unistr/u16-mbtouc.
6144         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
6145         * lib/unistr.h: Update.
6146         * lib/linebreak.c: Update.
6147         * modules/linebreak: Update.
6148         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
6149         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
6150         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
6151         * modules/unistr/u16-mbtouc: Renamed from
6152         modules/unistr/u16-mbtouc-safe.
6153         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
6154         * lib/unistr.h: Update.
6155         * lib/unistr/u16-to-u8.c: Update.
6156         * modules/unistr/u16-to-u8: Update.
6157         * lib/unistr/u16-to-u32.c: Update.
6158         * modules/unistr/u16-to-u32: Update.
6159
6160 2007-01-27  Bruno Haible  <bruno@clisp.org>
6161
6162         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
6163         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
6164         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
6165         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
6166         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
6167         * modules/unistr/u8-mbtouc-unsafe: Renamed from
6168         modules/unistr/u8-mbtouc.
6169         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
6170         * lib/unistr.h: Update.
6171         * lib/striconveh.c: Update.
6172         * modules/striconveh: Update.
6173         * lib/linebreak.c: Update.
6174         * modules/linebreak: Update.
6175         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
6176         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
6177         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
6178         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
6179         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
6180         * lib/unistr.h: Update.
6181         * lib/striconveh.c: Update.
6182         * modules/striconveh: Update.
6183         * lib/unistr/u8-to-u16.c: Update.
6184         * modules/unistr/u8-to-u16: Update.
6185         * lib/unistr/u8-to-u32.c: Update.
6186         * modules/unistr/u8-to-u32: Update.
6187
6188 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6189
6190         Sync from Libtool.
6191         * lib/argz.c: Do not include strings.h nor memory.h, include
6192         string.h unconditionally.  Patch by Simon Josefsson.
6193
6194 2007-01-27  Bruno Haible  <bruno@clisp.org>
6195
6196         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
6197         from gl_HEADER_STRING_H_BODY.
6198         (gl_HEADER_STRING_H_BODY): Require it.
6199         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
6200         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
6201         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
6202         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
6203         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
6204         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
6205         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
6206         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
6207         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
6208         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
6209         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
6210         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
6211         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
6212         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
6213         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
6214
6215 2007-01-27  Bruno Haible  <bruno@clisp.org>
6216
6217         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
6218         check_PROGRAMS into noinst_PROGRAMS.
6219         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
6220         check_PROGRAMS in this case.
6221         (func_import): Set for_test to false.
6222         (func_create_testdir): Set for_test to true.
6223
6224 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
6225             Bruno Haible  <bruno@clisp.org>
6226
6227         * modules/strcasestr (Files): Remove lib/strcasestr.h.
6228         (Depends-on): Add string.
6229         (Includes): Use <string.h> instead of strcasestr.h.
6230         * modules/string (Makefile.am): Also substitute the value of
6231         REPLACE_STRCASESTR.
6232         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
6233         assume strcasestr is declared in <string.h> not <strings.h>. Also
6234         set REPLACE_STRCASESTR.
6235         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
6236         REPLACE_STRCASESTR.
6237         * lib/strcasestr.h: Remove file.
6238         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
6239         * lib/string_.h (strcasestr): New declaration.
6240
6241 2007-01-27  Bruno Haible  <bruno@clisp.org>
6242
6243         * lib/string_.h: Use 'extern'.
6244
6245 2007-01-27  Jim Meyering  <jim@meyering.net>
6246
6247         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
6248         of set-but-not-used local, "q".
6249
6250         * lib/mempcpy.c: Include <config.h> before <string.h>.
6251         This fixes a compilation error on HP-UX, due to the system's
6252         "restrict"-using mempcpy prototype.
6253
6254 2007-01-26  Bruno Haible  <bruno@clisp.org>
6255
6256         Small optimization.
6257         * lib/javacomp.c: Include c-strstr.h.
6258          (is_envjavac_gcj): Use c_strstr instead of strstr.
6259         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
6260
6261 2007-01-26  Bruno Haible  <bruno@clisp.org>
6262
6263         * MODULES.html.sh (Unicode string functions): Add the new modules.
6264
6265         * modules/uniconv/u32-strconv-to-locale: New file.
6266         * lib/uniconv/u32-strconv-to-locale.c: New file.
6267
6268         * modules/uniconv/u16-strconv-to-locale: New file.
6269         * lib/uniconv/u16-strconv-to-locale.c: New file.
6270
6271         * modules/uniconv/u8-strconv-to-locale: New file.
6272         * lib/uniconv/u8-strconv-to-locale.c: New file.
6273
6274         * modules/uniconv/u32-strconv-from-locale: New file.
6275         * lib/uniconv/u32-strconv-from-locale.c: New file.
6276
6277         * modules/uniconv/u16-strconv-from-locale: New file.
6278         * lib/uniconv/u16-strconv-from-locale.c: New file.
6279
6280         * modules/uniconv/u8-strconv-from-locale: New file.
6281         * lib/uniconv/u8-strconv-from-locale.c: New file.
6282
6283         * modules/uniconv/u32-strconv-to-enc: New file.
6284         * lib/uniconv/u32-strconv-to-enc.c: New file.
6285         * modules/uniconv/u32-strconv-to-enc-tests: New file.
6286         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
6287
6288         * modules/uniconv/u16-strconv-to-enc: New file.
6289         * lib/uniconv/u16-strconv-to-enc.c: New file.
6290         * lib/uniconv/u-strconv-to-enc.h: New file.
6291         * modules/uniconv/u16-strconv-to-enc-tests: New file.
6292         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
6293
6294         * modules/uniconv/u8-strconv-to-enc: New file.
6295         * lib/uniconv/u8-strconv-to-enc.c: New file.
6296         * modules/uniconv/u8-strconv-to-enc-tests: New file.
6297         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
6298
6299         * modules/uniconv/u32-strconv-from-enc: New file.
6300         * lib/uniconv/u32-strconv-from-enc.c: New file.
6301         * modules/uniconv/u32-strconv-from-enc-tests: New file.
6302         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
6303
6304         * modules/uniconv/u16-strconv-from-enc: New file.
6305         * lib/uniconv/u16-strconv-from-enc.c: New file.
6306         * modules/uniconv/u16-strconv-from-enc-tests: New file.
6307         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
6308
6309         * modules/uniconv/u8-strconv-from-enc: New file.
6310         * lib/uniconv/u8-strconv-from-enc.c: New file.
6311         * lib/uniconv/u-strconv-from-enc.h: New file.
6312         * modules/uniconv/u8-strconv-from-enc-tests: New file.
6313         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
6314
6315         * modules/uniconv/u32-conv-from-enc: New file.
6316         * lib/uniconv/u32-conv-from-enc.c: New file.
6317         * modules/uniconv/u32-conv-from-enc-tests: New file.
6318         * tests/uniconv/test-u32-conv-from-enc.c: New file.
6319
6320         * modules/uniconv/u16-conv-from-enc: New file.
6321         * lib/uniconv/u16-conv-from-enc.c: New file.
6322         * lib/uniconv/u-conv-from-enc.h: New file.
6323         * modules/uniconv/u16-conv-from-enc-tests: New file.
6324         * tests/uniconv/test-u16-conv-from-enc.c: New file.
6325
6326         * modules/uniconv/u8-conv-from-enc: New file.
6327         * lib/uniconv/u8-conv-from-enc.c: New file.
6328         * modules/uniconv/u8-conv-from-enc-tests: New file.
6329         * tests/uniconv/test-u8-conv-from-enc.c: New file.
6330
6331         * modules/uniconv/base: New file.
6332         * lib/uniconv.h: New file.
6333
6334 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
6335
6336         * doc/gnulib-tool.texi (Initial import): Update to match current
6337         behavior with strdup module.
6338         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
6339         * lib/memmem.h: Remove; all uses removed.  This is now done
6340         by <string.h>.
6341         * lib/mempcpy.h: Likewise.
6342         * lib/memrchr.h: Likewise.
6343         * lib/stpcpy.h: Likewise.
6344         * lib/stpncpy.h: Likewise.
6345         * lib/strcase.h: Likewise.
6346         * lib/strchrnul.h: Likewise.
6347         * lib/strdup.h: Likewise.
6348         * lib/strndup.h: Likewise.
6349         * lib/strnlen.h: Likewise.
6350         * lib/strpbrk.h: Likewise.
6351         * lib/strsep.h: Likewise.
6352         * lib/strstr.h: Likewise.
6353         * lib/strtok_r.h: Likewise.
6354         * lib/string_.h: New file.
6355         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
6356         Rely on <string.h> instead.
6357         * lib/canon-host.c: Likewise.
6358         * lib/chdir-long.c: Likewise.
6359         * lib/concatpath.c: Likewise.
6360         * lib/exclude.c: Likewise.
6361         * lib/fchdir.c: Likewise.
6362         * lib/getaddrinfo.c: Likewise.
6363         * lib/getcwd.c: Likewise.
6364         * lib/getsubopt.c: Likewise.
6365         * lib/glob.c: Likewise.
6366         * lib/hard-locale.c: Likewise.
6367         * lib/iconvme.c: Likewise.
6368         * lib/javacomp.c: Likewise.
6369         * lib/mempcpy.c: Likewise.
6370         * lib/memrchr.c: Likewise.
6371         * lib/regex_internal.h: Likewise.
6372         * lib/stpncpy.c: Likewise.
6373         * lib/strcasecmp.c: Likewise.
6374         * lib/strchrnul.c: Likewise.
6375         * lib/strdup.c: Likewise.
6376         * lib/striconv.c: Likewise.
6377         * lib/striconveh.c: Likewise.
6378         * lib/striconveha.c: Likewise.
6379         * lib/strncasecmp.c: Likewise.
6380         * lib/strndup.c: Likewise.
6381         * lib/strnlen.c: Likewise.
6382         * lib/strsep.c: Likewise.
6383         * lib/strstr.c: Likewise.
6384         * lib/strtok_r.c: Likewise.
6385         * lib/userspec.c: Likewise.
6386         * lib/w32spawn.h: Likewise.
6387         * lib/xstrndup.c: Likewise.
6388         * lib/mountlist.c (strstr): Remove decl.
6389         * m4/string_h.m4: New file.
6390         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
6391         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
6392         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
6393         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
6394         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
6395         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
6396         Set REPLACE_STRCASECMP if necessary.
6397         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
6398         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
6399         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
6400         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
6401         HAVE_DECL_STRDUP if necessary.
6402         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
6403         since gl_FUNC_STRNDUP does that now.
6404         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
6405         Check for decl here...
6406         (gl_PREREQ_STRNLEN): ... not here.
6407         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
6408         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
6409         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
6410         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
6411         necessary.
6412         * modules/string: New file.
6413         * modules/memmem (Files): Remove special-purpose include file.
6414         (Depends-on): Add string.
6415         (Include): Include <string.h>, not the removed file.
6416         * modules/mempcpy: Likewise.
6417         * modules/memrchr: Likewise.
6418         * modules/stpcpy: Likewise.
6419         * modules/stpncpy: Likewise.
6420         * modules/strcase: Likewise.
6421         * modules/strchrnul: Likewise.
6422         * modules/strdup: Likewise.
6423         * modules/strndup: Likewise.
6424         * modules/strnlen: Likewise.
6425         * modules/strpbrk: Likewise.
6426         * modules/strsep: Likewise.
6427         * modules/strstr: Likewise.
6428         * modules/strtok_r: Likewise.
6429         * tests/test-dirname.c: Don't include "strdup.h", since
6430         <string.h> now suffices.
6431         * tests/test-memmem.c: Don't include "memmem.h", since
6432         <string.h> now suffices.
6433
6434 2007-01-25  Bruno Haible  <bruno@clisp.org>
6435
6436         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
6437         *resultp is 0.
6438
6439         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
6440         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
6441         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
6442         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
6443
6444         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
6445         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
6446         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
6447         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
6448         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
6449         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
6450
6451 2007-01-24  Bruno Haible  <bruno@clisp.org>
6452
6453         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
6454         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
6455         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
6456         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
6457         gl_FUNC_FTS_CORE.
6458         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
6459         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
6460         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
6461         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
6462         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
6463         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
6464         gl_FUNC_FCHOWNAT.
6465         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
6466         gl_FUNC_STRFTIME.
6467         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
6468         Reported by Ralf Wildenhues.
6469
6470 2007-01-24  Bruno Haible  <bruno@clisp.org>
6471
6472         Drop AC_REQUIRE calls that are redundant with the module dependencies.
6473         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
6474         gl_GETADDRINFO.
6475         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
6476         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
6477         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
6478
6479 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
6480
6481         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
6482         Don't use 'exit'; just return from 'main'.
6483         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
6484
6485         * lib/fnmatch_.h: Readjust white space and comments to match
6486         glibc, to avoid spurious diffs.
6487
6488 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
6489
6490         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
6491         2004-12-01 change by Jakub Jelinek, since this code won't compile
6492         if !LIBC.  Problem reported by Bob Proulx.
6493
6494 2007-01-23  Bruno Haible  <bruno@clisp.org>
6495
6496         * lib/striconveh.c: Include c-strcaseeq.h.
6497         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
6498         * modules/striconveh (Depends-on): Add c-strcaseeq.
6499
6500 2007-01-23  Bruno Haible  <bruno@clisp.org>
6501
6502         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
6503
6504         * modules/c-strcaseeq: New file.
6505         * lib/c-strcaseeq.h: New file.
6506
6507         * modules/streq: New file.
6508         * lib/streq.h: New file.
6509
6510 2007-01-23  Bruno Haible  <bruno@clisp.org>
6511
6512         * modules/striconveha-tests: New file.
6513         * tests/test-striconveha.c: New file.
6514
6515         * lib/striconveha.h: Include <stdbool.h>.
6516         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
6517         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
6518         (mem_iconveha_notranslit): Renamed from mem_iconveha.
6519         (mem_iconveha): New function.
6520         (str_iconveha_notranslit): Renamed from str_iconveha.
6521         (str_iconveha): New function.
6522         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
6523         c-strcase.
6524
6525 2007-01-23  Bruno Haible  <bruno@clisp.org>
6526
6527         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
6528         encodings without forgiving before trying any encoding with handler.
6529         (str_iconveha): Try all encodings without forgiving before trying any
6530         encoding with handler.
6531
6532 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
6533
6534         Import the following changes from libc.
6535
6536         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
6537
6538         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
6539
6540         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
6541
6542         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
6543         normal_bracket label.
6544
6545         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
6546
6547         [BZ #361]
6548         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
6549         to normal_bracket after fetching the next character.
6550
6551 2007-01-22  Bruno Haible  <bruno@clisp.org>
6552
6553         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
6554         argument.
6555         * lib/striconveh.c (iconv_carefully_1): New function.
6556         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
6557         argument.
6558         (str_cd_iconveh): Update.
6559         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
6560         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
6561         * tests/test-striconveh.c (MAGIC): New macro.
6562         (new_offsets): New function.
6563         (main): Test call with and without offsets.
6564
6565 2007-01-22  Bruno Haible  <bruno@clisp.org>
6566
6567         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
6568         * modules/sys_select (Makefile.am): Likewise.
6569         * modules/sys_socket (Makefile.am): Likewise.
6570         * modules/sys_time (Makefile.am): Likewise.
6571
6572 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
6573
6574         * modules/gettimeofday (License): Change from GPL to LGPL, since
6575         gettimeofday is a library function.
6576
6577 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6578
6579         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
6580
6581 2007-01-21  Bruno Haible  <bruno@clisp.org>
6582
6583         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
6584
6585 2007-01-21  Bruno Haible  <bruno@clisp.org>
6586
6587         * modules/striconveha: New file.
6588         * lib/striconveha.h: New file.
6589         * lib/striconveha.c: New file.
6590         * MODULES.html.sh (Internationalization functions): Add striconveha.
6591         * lib/striconv.c (str_iconv): Optimize the case of an empty input
6592         string.
6593         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
6594
6595 2007-01-21  Bruno Haible  <bruno@clisp.org>
6596
6597         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
6598         * lib/striconveh.c (str_iconveh): Likewise.
6599
6600 2007-01-21  Bruno Haible  <bruno@clisp.org>
6601
6602         * lib/striconveh.h (mem_iconveh): New declaration.
6603         * lib/striconveh.c (mem_iconveh): New function.
6604         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
6605
6606 2007-01-21  Bruno Haible  <bruno@clisp.org>
6607
6608         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
6609
6610         * lib/striconveh.h (mem_cd_iconveh): Change specification.
6611         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
6612         original result buffer.
6613         (str_cd_iconveh): Update.
6614         * tests/test-striconveh.c (main): Update.
6615
6616         * lib/striconv.h (mem_cd_iconv): Change specification.
6617         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
6618         result buffer.
6619         (str_cd_iconv): Update.
6620         * tests/test-striconv.c (main): Update.
6621
6622 2007-01-21  Bruno Haible  <bruno@clisp.org>
6623
6624         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
6625
6626 2007-01-20  Jim Meyering  <jim@meyering.net>
6627
6628         * lib/userspec.c (parse_with_separator): If a user or group string
6629         starts with "+", skip the corresponding name-to-ID look-up, since
6630         such a look-up must fail: user and group names may not include "+".
6631
6632 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
6633
6634         * lib/poll.c: Include sys/time.h and time.h unconditionally,
6635         since we now assume the sys_time module.
6636         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
6637         check for sys/time.h; no longer needed.
6638         * modules/poll (Depends-on): Depend on sys_time.
6639
6640 2007-01-18  Bruno Haible  <bruno@clisp.org>
6641
6642         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
6643         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
6644
6645         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
6646         gettimeofday.
6647
6648         * tests/test-gettimeofday.c: Include <time.h>.
6649         (dummy): Remove variable.
6650
6651         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
6652         gl_HEADER_SYS_TIME_H.
6653         (gl_HEADER_SYS_TIME_H): New macro.
6654
6655         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
6656         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6657         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
6658         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
6659         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6660         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
6661         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
6662         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6663         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
6664         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
6665         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6666
6667         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
6668         last change; it caused a compilation error when cross-compiling to
6669         Cygwin.
6670
6671 2007-01-18  Jim Meyering  <jim@meyering.net>
6672
6673         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
6674         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
6675         than the race-prone "test -d sys || mkdir sys".
6676         (configure.ac): Use AC_PROG_MKDIR_P.
6677         * modules/sys_select: Likewise.
6678         * modules/sys_socket: Likewise.
6679         * modules/sys_time: Likewise.
6680
6681 2007-01-18  Eric Blake  <ebb9@byu.net>
6682
6683         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
6684         replace gettimeofday.
6685         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
6686         name, to avoid infinite recursion.
6687
6688 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
6689
6690         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
6691         module sys_time.
6692         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
6693         assume timespec.h defines struct timeval.
6694         * lib/settime.c: Likewise.
6695         * lib/utimens.c: Likewise.
6696         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
6697         since we now assume the gettimeofday module.
6698         * lib/tempname.c (__gen_tempname): Likewise.
6699         * lib/gettimeofday.h: Remove.
6700         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
6701         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
6702         Include <time.h>, for 'time()'.
6703         (localtime_buffer_addr): Also use this workaround if
6704         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
6705         to simplify the uses.  All uses changed.
6706         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
6707         that #undef is inside {}, and 'const' follows type name consistently.
6708         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
6709         (gettimeofday): Do not use the maximum possible value for
6710         tv->tv_usec, since that might break usages other than ls.c.
6711         Instead, we'll leave ls.c alone.  This undoes today's patch
6712         by Bruno.  Add a compile-time warning for 1s-clock resolution;
6713         we've never observed the problem but might as well keep the
6714         canary.
6715         * lib/nanosleep.c: Include timespec.h first, for interface check.
6716         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
6717         now assume the sys_time module.
6718         * lib/tempname.c: Likewise.
6719         * lib/timespec.h: Likewise.
6720         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
6721         needed.
6722         * lib/strftime.c: Likewise.
6723         * lib/timespec.h: Likewise.
6724         * lib/posixtm.c: Include posixtm.h first, for interface check.
6725         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
6726         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
6727         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
6728         * lib/sys_time_.h: New file.
6729         * lib/timespec.h (struct timespec): Use long int, not long.
6730         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6731         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
6732         Remove obsolescent call to AC_HEADER_TIME.
6733         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
6734         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
6735         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
6736         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
6737         Likewise.
6738         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
6739         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
6740         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
6741         into the sys_time module.  Check for gettimeofday just once.
6742         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
6743         for gettimeofday signature to just check the signature.  Merely
6744         compile it, since linking doesn't test signature.  Improve test for
6745         whether gettimeofday.o is actually needed.
6746         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
6747         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
6748         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
6749         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6750         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
6751         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
6752         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
6753         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
6754         than worrying about sys/time.h.
6755         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
6756         Don't bother worrying about TIME_WITH_SYS_TIME.
6757         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
6758         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
6759         * m4/sys_time_h.m4: New file.
6760         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
6761         Don't include sys/time.h.  Return from main rather than exiting.
6762         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
6763         all uses changed.
6764         * modules/gethrxtime (Depends-on): Add sys_time.
6765         * modules/gettime (Depends-on): Likewise.
6766         * modules/gettimeofday (Depends-on): Likewise.
6767         * modules/nanosleep (Depends-on): Likewise.
6768         * modules/settime (Depends-on): Likewise.
6769         * modules/tempname (Depends-on): Likewise.
6770         * modules/utimens (Depends-on): Likewise.
6771         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
6772         (Include:) Change back to <sys/time.h>.
6773         (Maintainer:) Add self.
6774         * modules/sys_time: New file.
6775         * modules/tempname (Depends-on): Add gettimeofday.
6776         * tests/test-gettimeofday.c: Include <sys/time.h>
6777         rather than gettimeofday.h.
6778
6779 2007-01-17  Bruno Haible  <bruno@clisp.org>
6780
6781         * gnulib-tool (func_get_license): Revert last patch. Instead, let
6782         the license default to GPL.
6783         (func_create_testdir): Don't complain if a module is LGPL and its
6784         tests module depends on GPLed modules.
6785
6786 2007-01-17  Bruno Haible  <bruno@clisp.org>
6787
6788         * lib/gettimeofday.c (gettimeofday): Add code for the case
6789         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
6790         maximum possible value for tv->tv_usec, rather than the minimum one.
6791
6792 2005-10-08  Martin Lambers  <marlam@marlam.de>
6793 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
6794 2007-01-16  Bruno Haible  <bruno@clisp.org>
6795
6796         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
6797         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
6798         gl_FUNC_GETTIMEOFDAY.
6799         (Include): Add gettimeofday.h.
6800         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
6801         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
6802         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
6803         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
6804         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
6805         * lib/gettimeofday.h: New file.
6806         * lib/gettimeofday.c: Include <sys/timeb.h>.
6807         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
6808         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6809         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
6810         fall back on time().
6811
6812         * tests/test-gettimeofday.c: New file.
6813         * modules/gettimeofday-tests: New file.
6814
6815 2007-01-16  Eric Blake  <ebb9@byu.net>
6816
6817         * modules/fnmatch (Depends-on): Depend on wchar.
6818         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
6819         * m4/fnmatch.m4: Likewise.
6820         * modules/mbchar (Makefile.am): Assume <wchar.h>.
6821         * m4/mbchar.m4: Likewise.
6822         * modules/mbswidth (Depends-on): Depend on wchar.
6823         * lib/mbswidth.c: Assume <wchar.h>.
6824         * m4/mbswidth.m4: Likewise.
6825         * modules/quotearg (Depends-on): Depend on wchar.
6826         * lib/quotearg.c: Assume <wchar.h>.
6827         * m4/quotearg.m4: Likewise.
6828         * modules/regex (Depends-on): Depend on wchar.
6829         * lib/regex_internal.h: Assume <wchar.h>.
6830         * m4/regex.m4: Likewise.
6831         * modules/stdint (Depends-on): Depend on wchar.
6832         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
6833         * m4/stdint.m4: Likewise.
6834         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
6835         * modules/strftime (Depends-on): Depend on wchar.
6836         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
6837         * modules/strtol (Depends-on): Depend on wchar.
6838         * lib/strtol.c: Assume <wchar.h>.
6839         * modules/wcwidth (Depends-on): Depend on wchar.
6840         * lib/wcwidth.h: Assume <wchar.h>.
6841         * m4/wcwidth.m4: Likewise.
6842
6843 2007-01-16  Bruno Haible  <bruno@clisp.org>
6844
6845         * modules/csharpexec-script: New, created from...
6846         * modules/csharpexec: ... this.
6847
6848 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
6849
6850         * modules/javaexec-script: New, created from...
6851         * modules/javaexec: ... this.
6852
6853 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6854
6855         * modules/poll (Dependencies): Add sys_select.
6856
6857 2007-01-15  Jim Meyering  <jim@meyering.net>
6858
6859         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
6860         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
6861         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
6862         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
6863
6864 2007-01-15  Bruno Haible  <bruno@clisp.org>
6865
6866         * modules/striconveh: New file.
6867         * lib/striconveh.h: New file.
6868         * lib/striconveh.c: New file.
6869         * MODULES.html.sh (Internationalization functions): Add striconveh.
6870
6871         * modules/striconveh-tests: New file.
6872         * tests/test-striconveh.c: New file.
6873
6874 2007-01-15  Bruno Haible  <bruno@clisp.org>
6875
6876         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
6877         not from GNU libiconv or GNU libc.
6878
6879 2007-01-15  Bruno Haible  <bruno@clisp.org>
6880
6881         * doc/gnulib-intro.texi (Copyright): Explain the different license
6882         terms for module descriptions, autoconf macros, tests, documentation.
6883
6884 2007-01-14  Bruno Haible  <bruno@clisp.org>
6885
6886         * modules/striconv-tests: New file.
6887         * tests/test-striconv.c: New file.
6888
6889 2007-01-14  Bruno Haible  <bruno@clisp.org>
6890
6891         * modules/iconv-tests: New file.
6892         * tests/test-iconv.c: New file.
6893
6894 2007-01-14  Bruno Haible  <bruno@clisp.org>
6895
6896         * gnulib-tool (func_get_license): For test modules, use the license of
6897         the main module.
6898
6899 2007-01-14  Bruno Haible  <bruno@clisp.org>
6900
6901         * modules/iconv (Include): Clarify that <iconv.h> can only be included
6902         if iconv is found to exist.
6903
6904 2007-01-14  Bruno Haible  <bruno@clisp.org>
6905
6906         * modules/c-ctype-tests: New file.
6907         * tests/test-c-ctype.c: New file.
6908
6909 2007-01-14  Bruno Haible  <bruno@clisp.org>
6910
6911         * modules/binary-io-tests: New file.
6912         * tests/test-binary-io.sh: New file.
6913         * tests/test-binary-io.c: New file.
6914
6915 2007-01-14  Bruno Haible  <bruno@clisp.org>
6916
6917         * modules/array-oset-tests: New file.
6918         * tests/test-array_oset.c: New file.
6919
6920 2007-01-14  Bruno Haible  <bruno@clisp.org>
6921
6922         * modules/array-list-tests: New file.
6923         * tests/test-array_list.c: New file.
6924
6925 2007-01-14  Bruno Haible  <bruno@clisp.org>
6926
6927         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
6928         and make.
6929         Reported by Simon Josefsson in
6930         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
6931
6932 2007-01-14  Bruno Haible  <bruno@clisp.org>
6933
6934         * modules/allocsa-tests: New file.
6935         * tests/test-allocsa.c: New file.
6936
6937 2007-01-14  Bruno Haible  <bruno@clisp.org>
6938
6939         * modules/fchdir (Depends-on): Add absolute-header.
6940         * modules/unistd (Depends-on): Likewise.
6941
6942 2006-12-30  Bruno Haible  <bruno@clisp.org>
6943
6944         * modules/fchdir: New file.
6945         * modules/unistd (Files): Add lib/unistd_.h.
6946         (Makefile.am): Generate unistd.h from unistd_.h.
6947         * lib/fchdir.c: New file.
6948         * lib/dirent_.h: New file.
6949         * lib/unistd_.h: New file.
6950         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
6951         * m4/fchdir.m4: New file.
6952         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
6953         (gl_HEADER_UNISTD): Invoke it.
6954         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
6955         function.
6956         * lib/backupfile.c (opendir, closedir): Undefine.
6957         * lib/chown.c (open, close): Undefine.
6958         * lib/clean-temp.c (open, close): Undefine.
6959         * lib/copy-file.c (open, close): Undefine.
6960         * lib/execute.c (open, close): Undefine.
6961         * lib/fsusage.c (open, close): Undefine.
6962         * lib/gc-gnulib.c (open, close): Undefine.
6963         * lib/getcwd.c (opendir, closedir): Undefine.
6964         * lib/glob.c (opendir, closedir): Undefine.
6965         * lib/javacomp.c (open, close): Undefine.
6966         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
6967         * lib/openat-proc.c (open, close): Undefine.
6968         * lib/pagealign_alloc.c (open, close): Undefine.
6969         * lib/pipe.c (open, close): Undefine.
6970         * lib/progreloc.c (open, close): Undefine.
6971         * lib/savedir.c (opendir, closedir): Undefine.
6972         * lib/utime.c (open, close): Undefine.
6973         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
6974
6975 2007-01-10  Bruno Haible  <bruno@clisp.org>
6976
6977         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
6978
6979 2007-01-12  Eric Blake  <ebb9@byu.net>
6980
6981         Provide a robust <wchar.h>.  Further simplifications are now
6982         possible in other modules, but not included here.
6983         * modules/wchar: New module.
6984         * m4/wchar.m4: New file.
6985         * lib/wchar_.h: Likewise.
6986         * modules/mbchar (Depends-on): Depend on wchar, as the first use
6987         of the new module.
6988         * MODULES.html.sh (Extended multibyte and wide character utilities):
6989         New section.
6990
6991 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
6992
6993         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
6994         to a reasonable default for memory allocation.
6995         (xreadlink): Don't allocate a huge buffer, to work around a buggy
6996         file system that reports garbage st_size values for symlinks.
6997         Problem reported by Liyang Hu.
6998
6999 2007-01-11  Simon Josefsson  <simon@josefsson.org>
7000
7001         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
7002         Emacs .#* auto-save files).
7003
7004 2007-01-11  Bruno Haible  <bruno@clisp.org>
7005
7006         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
7007         directory.
7008
7009 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
7010
7011         Use @...@ consistently in lib/wctype_.h.
7012         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
7013         on it being set to 1 or 0.
7014         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
7015         go back to AC_SUBSTing it.
7016         * modules/wctype (Makefile.am): Undo previous change.
7017
7018 2007-01-10  Eric Blake  <ebb9@byu.net>
7019
7020         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
7021         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
7022         * modules/wctype (Makefile.am): Likewise.
7023         Reported by Chris McGuire.
7024
7025 2007-01-10  Jim Meyering  <jim@meyering.net>
7026
7027         fts.c: a small readability/maintainability improvement
7028         * lib/fts.c (fts_read): Make this code slightly more readable and
7029         maintainable by hoisting the "sp->fts_cur = p" assignments to
7030         immediately follow the statements that set P.  Derived from
7031         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
7032
7033 2007-01-10  Eric Blake  <ebb9@byu.net>
7034
7035         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
7036         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
7037         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7038         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
7039         Reported by Chris McGuire.
7040
7041 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7042
7043         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
7044         in sed script.
7045
7046 2007-01-09  Bruno Haible  <bruno@clisp.org>
7047
7048         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
7049         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
7050         variables.
7051         (func_module): Use them.
7052
7053 2007-01-09  Bruno Haible  <bruno@clisp.org>
7054
7055         * modules/unistr/base: New file.
7056         * lib/unistr.h: New file.
7057
7058         * modules/unistr/u8-to-u16: New file.
7059         * lib/unistr/u8-to-u16.c: New file.
7060
7061         * modules/unistr/u8-to-u32: New file.
7062         * lib/unistr/u8-to-u32.c: New file.
7063
7064         * modules/unistr/u16-to-u8: New file.
7065         * lib/unistr/u16-to-u8.c: New file.
7066
7067         * modules/unistr/u16-to-u32: New file.
7068         * lib/unistr/u16-to-u32.c: New file.
7069
7070         * modules/unistr/u32-to-u8: New file.
7071         * lib/unistr/u32-to-u8.c: New file.
7072
7073         * modules/unistr/u32-to-u16: New file.
7074         * lib/unistr/u32-to-u16.c: New file.
7075
7076         * modules/unistr/u8-check: New file.
7077         * modules/unistr/u16-check: New file.
7078         * modules/unistr/u32-check: New file.
7079         * lib/unistr/u8-check.c: New file.
7080         * lib/unistr/u16-check.c: New file.
7081         * lib/unistr/u32-check.c: New file.
7082
7083         * modules/unistr/u8-chr: New file.
7084         * modules/unistr/u16-chr: New file.
7085         * modules/unistr/u32-chr: New file.
7086         * lib/unistr/u8-chr.c: New file.
7087         * lib/unistr/u16-chr.c: New file.
7088         * lib/unistr/u32-chr.c: New file.
7089
7090         * modules/unistr/u8-cmp: New file.
7091         * modules/unistr/u16-cmp: New file.
7092         * modules/unistr/u32-cmp: New file.
7093         * lib/unistr/u8-cmp.c: New file.
7094         * lib/unistr/u16-cmp.c: New file.
7095         * lib/unistr/u32-cmp.c: New file.
7096
7097         * modules/unistr/u8-cpy: New file.
7098         * modules/unistr/u16-cpy: New file.
7099         * modules/unistr/u32-cpy: New file.
7100         * lib/unistr/u8-cpy.c: New file.
7101         * lib/unistr/u16-cpy.c: New file.
7102         * lib/unistr/u32-cpy.c: New file.
7103         * lib/unistr/u-cpy.h: New file.
7104
7105         * modules/unistr/u8-cpy-alloc: New file.
7106         * modules/unistr/u16-cpy-alloc: New file.
7107         * modules/unistr/u32-cpy-alloc: New file.
7108         * lib/unistr/u8-cpy-alloc.c: New file.
7109         * lib/unistr/u16-cpy-alloc.c: New file.
7110         * lib/unistr/u32-cpy-alloc.c: New file.
7111         * lib/unistr/u-cpy-alloc.h: New file.
7112
7113         * modules/unistr/u8-endswith: New file.
7114         * modules/unistr/u16-endswith: New file.
7115         * modules/unistr/u32-endswith: New file.
7116         * lib/unistr/u8-endswith.c: New file.
7117         * lib/unistr/u16-endswith.c: New file.
7118         * lib/unistr/u32-endswith.c: New file.
7119         * lib/unistr/u-endswith.h: New file.
7120
7121         * modules/unistr/u8-mblen: New file.
7122         * modules/unistr/u16-mblen: New file.
7123         * modules/unistr/u32-mblen: New file.
7124         * lib/unistr/u8-mblen.c: New file.
7125         * lib/unistr/u16-mblen.c: New file.
7126         * lib/unistr/u32-mblen.c: New file.
7127
7128         * modules/unistr/u8-mbtouc: New file.
7129         * modules/unistr/u16-mbtouc: New file.
7130         * modules/unistr/u32-mbtouc: New file.
7131         * lib/unistr/u8-mbtouc.c: New file.
7132         * lib/unistr/u16-mbtouc.c: New file.
7133         * lib/unistr/u32-mbtouc.c: New file.
7134
7135         * modules/unistr/u8-mbtouc-safe: New file.
7136         * modules/unistr/u16-mbtouc-safe: New file.
7137         * modules/unistr/u32-mbtouc-safe: New file.
7138         * lib/unistr/u8-mbtouc-safe.c: New file.
7139         * lib/unistr/u16-mbtouc-safe.c: New file.
7140         * lib/unistr/u32-mbtouc-safe.c: New file.
7141
7142         * modules/unistr/u8-move: New file.
7143         * modules/unistr/u16-move: New file.
7144         * modules/unistr/u32-move: New file.
7145         * lib/unistr/u8-move.c: New file.
7146         * lib/unistr/u16-move.c: New file.
7147         * lib/unistr/u32-move.c: New file.
7148         * lib/unistr/u-move.h: New file.
7149
7150         * modules/unistr/u8-next: New file.
7151         * modules/unistr/u16-next: New file.
7152         * modules/unistr/u32-next: New file.
7153         * lib/unistr/u8-next.c: New file.
7154         * lib/unistr/u16-next.c: New file.
7155         * lib/unistr/u32-next.c: New file.
7156
7157         * modules/unistr/u8-prev: New file.
7158         * modules/unistr/u16-prev: New file.
7159         * modules/unistr/u32-prev: New file.
7160         * lib/unistr/u8-prev.c: New file.
7161         * lib/unistr/u16-prev.c: New file.
7162         * lib/unistr/u32-prev.c: New file.
7163
7164         * modules/unistr/u8-set: New file.
7165         * modules/unistr/u16-set: New file.
7166         * modules/unistr/u32-set: New file.
7167         * lib/unistr/u8-set.c: New file.
7168         * lib/unistr/u16-set.c: New file.
7169         * lib/unistr/u32-set.c: New file.
7170         * lib/unistr/u-set.h: New file.
7171
7172         * modules/unistr/u8-startswith: New file.
7173         * modules/unistr/u16-startswith: New file.
7174         * modules/unistr/u32-startswith: New file.
7175         * lib/unistr/u8-startswith.c: New file.
7176         * lib/unistr/u16-startswith.c: New file.
7177         * lib/unistr/u32-startswith.c: New file.
7178         * lib/unistr/u-startswith.h: New file.
7179
7180         * modules/unistr/u8-stpcpy: New file.
7181         * modules/unistr/u16-stpcpy: New file.
7182         * modules/unistr/u32-stpcpy: New file.
7183         * lib/unistr/u8-stpcpy.c: New file.
7184         * lib/unistr/u16-stpcpy.c: New file.
7185         * lib/unistr/u32-stpcpy.c: New file.
7186         * lib/unistr/u-stpcpy.h: New file.
7187
7188         * modules/unistr/u8-stpncpy: New file.
7189         * modules/unistr/u16-stpncpy: New file.
7190         * modules/unistr/u32-stpncpy: New file.
7191         * lib/unistr/u8-stpncpy.c: New file.
7192         * lib/unistr/u16-stpncpy.c: New file.
7193         * lib/unistr/u32-stpncpy.c: New file.
7194         * lib/unistr/u-stpncpy.h: New file.
7195
7196         * modules/unistr/u8-strcat: New file.
7197         * modules/unistr/u16-strcat: New file.
7198         * modules/unistr/u32-strcat: New file.
7199         * lib/unistr/u8-strcat.c: New file.
7200         * lib/unistr/u16-strcat.c: New file.
7201         * lib/unistr/u32-strcat.c: New file.
7202         * lib/unistr/u-strcat.h: New file.
7203
7204         * modules/unistr/u8-strchr: New file.
7205         * modules/unistr/u16-strchr: New file.
7206         * modules/unistr/u32-strchr: New file.
7207         * lib/unistr/u8-strchr.c: New file.
7208         * lib/unistr/u16-strchr.c: New file.
7209         * lib/unistr/u32-strchr.c: New file.
7210
7211         * modules/unistr/u8-strcmp: New file.
7212         * modules/unistr/u16-strcmp: New file.
7213         * modules/unistr/u32-strcmp: New file.
7214         * lib/unistr/u8-strcmp.c: New file.
7215         * lib/unistr/u16-strcmp.c: New file.
7216         * lib/unistr/u32-strcmp.c: New file.
7217
7218         * modules/unistr/u8-strcpy: New file.
7219         * modules/unistr/u16-strcpy: New file.
7220         * modules/unistr/u32-strcpy: New file.
7221         * lib/unistr/u8-strcpy.c: New file.
7222         * lib/unistr/u16-strcpy.c: New file.
7223         * lib/unistr/u32-strcpy.c: New file.
7224         * lib/unistr/u-strcpy.h: New file.
7225
7226         * modules/unistr/u8-strcspn: New file.
7227         * modules/unistr/u16-strcspn: New file.
7228         * modules/unistr/u32-strcspn: New file.
7229         * lib/unistr/u8-strcspn.c: New file.
7230         * lib/unistr/u16-strcspn.c: New file.
7231         * lib/unistr/u32-strcspn.c: New file.
7232         * lib/unistr/u-strcspn.h: New file.
7233
7234         * modules/unistr/u8-strdup: New file.
7235         * modules/unistr/u16-strdup: New file.
7236         * modules/unistr/u32-strdup: New file.
7237         * lib/unistr/u8-strdup.c: New file.
7238         * lib/unistr/u16-strdup.c: New file.
7239         * lib/unistr/u32-strdup.c: New file.
7240         * lib/unistr/u-strdup.h: New file.
7241
7242         * modules/unistr/u8-strlen: New file.
7243         * modules/unistr/u16-strlen: New file.
7244         * modules/unistr/u32-strlen: New file.
7245         * lib/unistr/u8-strlen.c: New file.
7246         * lib/unistr/u16-strlen.c: New file.
7247         * lib/unistr/u32-strlen.c: New file.
7248         * lib/unistr/u-strlen.h: New file.
7249
7250         * modules/unistr/u8-strmblen: New file.
7251         * modules/unistr/u16-strmblen: New file.
7252         * modules/unistr/u32-strmblen: New file.
7253         * lib/unistr/u8-strmblen.c: New file.
7254         * lib/unistr/u16-strmblen.c: New file.
7255         * lib/unistr/u32-strmblen.c: New file.
7256
7257         * modules/unistr/u8-strmbtouc: New file.
7258         * modules/unistr/u16-strmbtouc: New file.
7259         * modules/unistr/u32-strmbtouc: New file.
7260         * lib/unistr/u8-strmbtouc.c: New file.
7261         * lib/unistr/u16-strmbtouc.c: New file.
7262         * lib/unistr/u32-strmbtouc.c: New file.
7263
7264         * modules/unistr/u8-strncat: New file.
7265         * modules/unistr/u16-strncat: New file.
7266         * modules/unistr/u32-strncat: New file.
7267         * lib/unistr/u8-strncat.c: New file.
7268         * lib/unistr/u16-strncat.c: New file.
7269         * lib/unistr/u32-strncat.c: New file.
7270         * lib/unistr/u-strncat.h: New file.
7271
7272         * modules/unistr/u8-strncmp: New file.
7273         * modules/unistr/u16-strncmp: New file.
7274         * modules/unistr/u32-strncmp: New file.
7275         * lib/unistr/u8-strncmp.c: New file.
7276         * lib/unistr/u16-strncmp.c: New file.
7277         * lib/unistr/u32-strncmp.c: New file.
7278
7279         * modules/unistr/u8-strncpy: New file.
7280         * modules/unistr/u16-strncpy: New file.
7281         * modules/unistr/u32-strncpy: New file.
7282         * lib/unistr/u8-strncpy.c: New file.
7283         * lib/unistr/u16-strncpy.c: New file.
7284         * lib/unistr/u32-strncpy.c: New file.
7285         * lib/unistr/u-strncpy.h: New file.
7286
7287         * modules/unistr/u8-strnlen: New file.
7288         * modules/unistr/u16-strnlen: New file.
7289         * modules/unistr/u32-strnlen: New file.
7290         * lib/unistr/u8-strnlen.c: New file.
7291         * lib/unistr/u16-strnlen.c: New file.
7292         * lib/unistr/u32-strnlen.c: New file.
7293         * lib/unistr/u-strnlen.h: New file.
7294
7295         * modules/unistr/u8-strpbrk: New file.
7296         * modules/unistr/u16-strpbrk: New file.
7297         * modules/unistr/u32-strpbrk: New file.
7298         * lib/unistr/u8-strpbrk.c: New file.
7299         * lib/unistr/u16-strpbrk.c: New file.
7300         * lib/unistr/u32-strpbrk.c: New file.
7301         * lib/unistr/u-strpbrk.h: New file.
7302
7303         * modules/unistr/u8-strrchr: New file.
7304         * modules/unistr/u16-strrchr: New file.
7305         * modules/unistr/u32-strrchr: New file.
7306         * lib/unistr/u8-strrchr.c: New file.
7307         * lib/unistr/u16-strrchr.c: New file.
7308         * lib/unistr/u32-strrchr.c: New file.
7309
7310         * modules/unistr/u8-strspn: New file.
7311         * modules/unistr/u16-strspn: New file.
7312         * modules/unistr/u32-strspn: New file.
7313         * lib/unistr/u8-strspn.c: New file.
7314         * lib/unistr/u16-strspn.c: New file.
7315         * lib/unistr/u32-strspn.c: New file.
7316         * lib/unistr/u-strspn.h: New file.
7317
7318         * modules/unistr/u8-strstr: New file.
7319         * modules/unistr/u16-strstr: New file.
7320         * modules/unistr/u32-strstr: New file.
7321         * lib/unistr/u8-strstr.c: New file.
7322         * lib/unistr/u16-strstr.c: New file.
7323         * lib/unistr/u32-strstr.c: New file.
7324         * lib/unistr/u-strstr.h: New file.
7325
7326         * modules/unistr/u8-strtok: New file.
7327         * modules/unistr/u16-strtok: New file.
7328         * modules/unistr/u32-strtok: New file.
7329         * lib/unistr/u8-strtok.c: New file.
7330         * lib/unistr/u16-strtok.c: New file.
7331         * lib/unistr/u32-strtok.c: New file.
7332         * lib/unistr/u-strtok.h: New file.
7333
7334         * modules/unistr/u8-uctomb: New file.
7335         * modules/unistr/u16-uctomb: New file.
7336         * modules/unistr/u32-uctomb: New file.
7337         * lib/unistr/u8-uctomb.c: New file.
7338         * lib/unistr/u16-uctomb.c: New file.
7339         * lib/unistr/u32-uctomb.c: New file.
7340
7341         * MODULES.html.sh (Unicode string functions): Add the new modules.
7342
7343 2007-01-08  Bruno Haible  <bruno@clisp.org>
7344
7345         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
7346         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
7347         subdirectories.
7348
7349 2007-01-08  Karl Berry  <karl@gnu.org>
7350
7351         * doc/error.texi: mention that main() fns must set program_name
7352         when progname is used.
7353
7354 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
7355
7356         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
7357         WCTYPE_H is empty, for the benefit of builds from non-distclean
7358         directories.  Problem reported by Eric Blake in
7359         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
7360
7361 2007-01-08  Bruno Haible  <bruno@clisp.org>
7362
7363         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
7364         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
7365         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
7366         PROVIDE_CANONICALIZE_FILENAME_MODE.
7367         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
7368
7369 2007-01-08  Bruno Haible  <bruno@clisp.org>
7370
7371         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
7372         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
7373         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
7374         * lib/fts.c: Likewise.
7375         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
7376
7377 2006-12-25  Bruno Haible  <bruno@clisp.org>
7378
7379         * modules/utf8-ucs4-safe: New file.
7380         * lib/utf8-ucs4-safe.h: New file.
7381         * lib/unistr/utf8-ucs4-safe.c: New file.
7382
7383         * modules/utf16-ucs4-safe: New file.
7384         * lib/utf16-ucs4-safe.h: New file.
7385         * lib/unistr/utf16-ucs4-safe.c: New file.
7386
7387         * MODULES.html.sh (Unicode string functions): Add the new modules.
7388
7389 2007-01-08  Bruno Haible  <bruno@clisp.org>
7390
7391         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
7392         (Depends-on): Add unitypes.
7393         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7394         (u8_mbtouc_aux): Move out to separate file.
7395         (u8_mbtouc): Use ucs4_t, uint8_t types.
7396         * lib/unistr/utf8-ucs4.c: New file.
7397
7398         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
7399         (Depends-on): Add unitypes.
7400         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7401         (u16_mbtouc_aux): Move out to separate file.
7402         (u16_mbtouc): Use ucs4_t, uint16_t types.
7403         * lib/unistr/utf16-ucs4.c: New file.
7404
7405         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
7406         (Depends-on): Add unitypes.
7407         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
7408         (u8_uctomb_aux): Move out to separate file.
7409         (u8_uctomb): Use ucs4_t, uint8_t types.
7410         * lib/unistr/ucs4-utf8.c: New file.
7411
7412         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
7413         (Depends-on): Add unitypes.
7414         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
7415         (u16_uctomb_aux): Move out to separate file.
7416         (u16_uctomb): Use ucs4_t, uint16_t types.
7417         * lib/unistr/ucs4-utf16.c: New file.
7418
7419 2006-12-25  Bruno Haible  <bruno@clisp.org>
7420
7421         * modules/unitypes: New file.
7422         * lib/unitypes.h: New file.
7423         * MODULES.html.sh (func_all_modules): New section "Unicode string
7424         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
7425         this section. Add unitypes.
7426
7427 2007-01-08  Bruno Haible  <bruno@clisp.org>
7428
7429         Avoid variable names that conflict with those from libtool.
7430         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
7431         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
7432         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
7433         library_names_spec to acl_library_names_spec, hardcode_* to
7434         acl_hardcode_*.
7435         Reported by Ralf Wildenhues.
7436
7437 2007-01-08  Bruno Haible  <bruno@clisp.org>
7438
7439         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
7440         definition.
7441         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
7442         definition.
7443         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
7444         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
7445         definition.
7446         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
7447         definition.
7448         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
7449         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
7450         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
7451         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
7452         definition.
7453         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
7454         definition.
7455         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
7456         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
7457         GC_USE_<algorithm>.
7458         * lib/gc-libgcrypt.c: Likewise.
7459         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
7460         * modules/gc-arctwo (configure.ac): Likewise.
7461         * modules/gc-des (configure.ac): Likewise.
7462         * modules/gc-hmac-md5 (configure.ac): Likewise.
7463         * modules/gc-hmac-sha1 (configure.ac): Likewise.
7464         * modules/gc-md2 (configure.ac): Likewise.
7465         * modules/gc-md4 (configure.ac): Likewise.
7466         * modules/gc-md5 (configure.ac): Likewise.
7467         * modules/gc-random (configure.ac): Likewise.
7468         * modules/gc-rijndael (configure.ac): Likewise.
7469         * modules/gc-sha1 (configure.ac): Likewise.
7470
7471 2007-01-08  Bruno Haible  <bruno@clisp.org>
7472
7473         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
7474         macro definition.
7475         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
7476         definition.
7477         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
7478         definition.
7479         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
7480         * modules/fcntl-safer (configure.ac): Likewise.
7481         * modules/fopen-safer (configure.ac): Likewise.
7482         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
7483         GNULIB_FWRITEERROR macro definition.
7484
7485 2007-01-08  Bruno Haible  <bruno@clisp.org>
7486
7487         * m4/gnulib-common.m4: New file.
7488         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
7489         (func_get_filelist): Add m4/gnulib-common.m4.
7490
7491 2007-01-08  Bruno Haible  <bruno@clisp.org>
7492
7493         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
7494         command.
7495
7496 2007-01-08  Jim Meyering  <jim@meyering.net>
7497
7498         Use a more robust test for a "can't happen" condition.
7499         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
7500         narrowed the st_size value.  Presuming the "can't happen" condition
7501         is true, that narrowing could conceivably convert an invalid st_size
7502         value into a valid one.  Instead, use a change based on Matthew
7503         Woehlke's original patch.
7504
7505         Slight readability improvement: use an assert-like macro
7506         in place of literal "abort ()" uses.
7507         * lib/fts.c (fts_assert): Define.
7508         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
7509         Use this macro instead of a bare 'abort'.
7510
7511 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
7512
7513         Don't worry about using IRIX 5.3's wctype.h broken definitions;
7514         simply work around them.
7515         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
7516         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
7517         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
7518         declaring.
7519         Don't bother to define as macros, since the standard doesn't require it.
7520         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
7521         longer worry about IRIX 5.3.
7522         (HAVE_WCTYPE_CTMP_BUG): Remove.
7523
7524 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
7525
7526         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
7527         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
7528         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
7529         Problems reported by Georg Schwarz for IRIX 5.3.
7530
7531         * gnulib-tool (autoconf_minversion): Take the maximum version number
7532         found, not the minimum.  Problem reported by James Youngman.
7533
7534 2007-01-03  Karl Berry  <karl@gnu.org>
7535
7536         * doc/error.texi: new file, explaining interaction with progname.
7537         * doc/gnulib.texi: include it.  Update copyright.
7538
7539 2007-01-03  Simon Josefsson  <simon@josefsson.org>
7540
7541         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
7542         AC_CANONICAL_HOST, to improve autobuild outputs.
7543
7544 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
7545             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
7546
7547         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
7548         sockets, server sockets, and other file descriptors.  Count errors
7549         to compute the return value.  Reorder the code a bit to be easier
7550         to follow.  Don't set event bits that were not requested (except
7551         POLLERR and POLLHUP).
7552
7553 2007-01-01  Bruno Haible  <bruno@clisp.org>
7554
7555         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
7556
7557 2007-01-03  Jim Meyering  <jim@meyering.net>
7558
7559         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
7560
7561 2007-01-02  Bruno Haible  <bruno@clisp.org>
7562
7563         * modules/settime (Include): Require timespec.h.
7564         * modules/nanosleep (Include): Likewise.
7565
7566 2007-01-01  Bruno Haible  <bruno@clisp.org>
7567
7568         * gnulib-tool (func_emit_copyright_notice): Bump year.
7569         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
7570
7571 2007-01-01  Bruno Haible  <bruno@clisp.org>
7572
7573         Improve support for OpenBSD.
7574         * build-aux/config.rpath (libname_spec): Export.
7575         (library_names_spec): New variable. Export.
7576         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
7577         library_names_spec from the config.rpath output. Locate shared library
7578         through the name pattern in library_names_spec.
7579
7580 2007-01-01  Eric Blake  <ebb9@byu.net>
7581
7582         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
7583
7584 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
7585
7586         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
7587         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
7588         assume the C locale, and avoid an "eval" that could cause trouble.
7589         Problem with SORT reported by Bob Proulx.
7590
7591         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
7592         Define.  Trivial patch from Henning Nielsen Lund, originally
7593         sent to bug-grep@gnu.org today.
7594
7595 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
7596
7597         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
7598         struct stat.  Problem reported by Henning Nielsen Lund.
7599         * lib/acl.c: Include acl.h first, to check interface.  Don't
7600         bother to include sys/types.h and sys/stat.h again.
7601
7602 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
7603
7604         Import the following change from libc; problem reported by
7605         Sven Verdoolaege.
7606
7607         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
7608
7609         [BZ #1373]
7610         * lib/argp.h: Remove __NTH for __argp_usage inline function.
7611
7612 2006-12-28  Jim Meyering  <jim@meyering.net>
7613
7614         * build-aux/announce-gen: Do not assume that the package
7615         builds any of tar.gz, tar.bz2, and .xdelta files.
7616         Suggestion from Simon Josefsson.
7617
7618 2006-12-28  Simon Josefsson  <simon@josefsson.org>
7619
7620         * modules/announce-gen: New file.
7621
7622 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
7623
7624         * lib/mbchar.h: Just include <wctype.h>; the wctype module
7625         handles its gotchas now.
7626         * lib/mbswidth.c: Likewise.
7627         * lib/wcwidth.h: Likewise.
7628         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
7629         and iswcntrl; the wctype module does this stuff now.
7630         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
7631         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7632         * modules/mbchar (Depends-on): Add wctype.
7633         * modules/mbswidth (Depends-on): Likewise.
7634         * modules/wcwidth (Depends-on): Likewise.
7635
7636 2006-12-27  Eric Blake  <ebb9@byu.net>
7637
7638         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
7639         module uses more than what <wctype.h> is required to provide.
7640
7641 2006-12-26  Eric Blake  <ebb9@byu.net>
7642
7643         * gnulib-tool (sed_extract_prog): Avoid space-tab.
7644
7645 2006-12-26  Eric Blake  <ebb9@byu.net>
7646
7647         * modules/absolute-header: New module.
7648         * modules/fcntl (Depends-on): Depend on it.
7649         * modules/inttypes (Depends-on): Likewise.
7650         * modules/stdint (Depends-on): Likewise.
7651         * modules/sys_stat (Depends-on): Likewise.
7652         * modules/wctype (Depends-on): Likewise.
7653         * MODULES.html.sh (Support for building libraries and
7654         executables): Document it.
7655
7656 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
7657
7658         * gnulib-tool (SED): Remove, undoing previous change.
7659         The problem was that it broke coreutils on Solaris, because
7660         "sed --posix" leaked into a makefile.
7661         (sed): New alias, if 'alias' and GNU sed.
7662
7663 2006-12-24  Jim Meyering  <jim@meyering.net>
7664
7665         Work around an fchownat bug in glibc-2.4:
7666         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
7667         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
7668         in spite of the -P option.
7669         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
7670         New macros.
7671         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
7672         * modules/openat (Files): Add lib/fchownat.c.
7673         * lib/openat.c (fchownat): Don't define here.  Move to...
7674         * lib/fchownat.c: ...this new file.
7675
7676 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
7677
7678         Fix bug reported by Bruno Haible in
7679         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
7680         where quotearg.c didn't compile on Mac OS X 10.2 because it
7681         lacks <wchar.h> and wint_t.
7682         * lib/wctype_.h (__wctype_wint_t): New type.
7683         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
7684         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
7685         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
7686         Arg is now of type __wctype_wint_t, not wint_t.
7687         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
7688         substitute HAVE_WINT_T.
7689         * modules/wctype (Files): Add m4/wint_t.m4.
7690         (wctype.h): Substitute HAVE_WINT_T.
7691
7692 2006-12-23  Bruno Haible  <bruno@clisp.org>
7693
7694         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
7695
7696 2006-12-23  Bruno Haible  <bruno@clisp.org>
7697
7698         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
7699         S_ISLNK.
7700         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
7701         mingw.
7702
7703 2006-12-22  Bruno Haible  <bruno@clisp.org>
7704
7705         * lib/copy-file.c: Include acl.h.
7706         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
7707         Close the file descriptors only after being done with copy_acl.
7708         * modules/copy-file (Depends-on): Add acl.
7709
7710 2006-12-22  Bruno Haible  <bruno@clisp.org>
7711
7712         * gnulib-tool (SED): New variable.
7713         Use $SED instead of sed everywhere.
7714
7715 2006-12-22  Bruno Haible  <bruno@clisp.org>
7716
7717         * modules/no-c++: New file.
7718         * m4/no-c++.m4: New file.
7719         * MODULES.html.sh (Support for building libraries and executables):
7720         Add no-c++.
7721
7722 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
7723
7724         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
7725         Include <limits.h>, and use its INT_MAX to rewrite the
7726         j loop so that it does not overflow 'int'.  Problem reported by
7727         Ralf Wildenhues in
7728         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
7729         Play it safe by shifting left by 1 rather than multiplying by 2,
7730         as GCC is less likely to optimize this away when the value
7731         is signed (when it assumes overflow leads to undefined behavior).
7732         Also, don't assume time_t uses two's complement.
7733
7734 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
7735
7736         * MODULES.html.sh: New module wctype.
7737         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
7738         * lib/fnmatch.c: Don't bother to include <wchar.h> before
7739         <wctype.h>, since the new wctype module should fix this.
7740         * lib/quotearg.c: Include <wctype.h> unconditionally, since
7741         the wctype module should arrange for it.
7742         * lib/regex_internal.h: Likewise.
7743         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
7744         since the wctype module should handle this now.
7745         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
7746         * modules/fnmatch (Depends-on): Add wctype.
7747         * modules/quotearg (Depends-on): Likewise.
7748         * modules/regex (Depends-on): Likewise.
7749
7750 2006-12-19  Bruno Haible  <bruno@clisp.org>
7751
7752         * lib/strdup.h [C++]: Wrap definitions in extern "C".
7753         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
7754
7755 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7756
7757         * modules/savewd (Depends-on): Fix dependency on fcntl.
7758
7759 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
7760
7761         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
7762         conforms to C99, rather than relying on the user's environment
7763         setting of STDINT_H.
7764
7765 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
7766         and Eric Blake  <ebb9@byu.net>
7767
7768         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
7769         This is more consistent with the other defines here.
7770         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
7771         Port to z/OS.  Problem reported by Paul Gilmartin.
7772         Change local vars to use gl_ prefix rather than ac_.
7773         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
7774         with other defines.
7775         * modules/double-slash-root: New module.
7776         * modules/dirname (Files): Remove m4/double-slash-root.m4.
7777         (Depends-on): Add double-slash-root.
7778         * MODULES.html.sh (File system functions): Mention new module.
7779
7780 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
7781
7782         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
7783         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
7784         This is for the benefit of gzip, which doesn't do i18n.
7785
7786 2006-12-12  Jim Meyering  <jim@meyering.net>
7787
7788         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
7789         Reported by Andreas Schwab <schwab@suse.de>.
7790
7791 2006-12-12  Bruno Haible  <bruno@clisp.org>
7792
7793         Merge these changes.
7794         2006-09-05  Bruno Haible  <bruno@clisp.org>
7795         * lib/iconvme.c (iconv_string): No need to save and restore errno when
7796         iconv_alloc succeeded.
7797         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
7798         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
7799         test for " && dest " at the end - dest is always != NULL there. Call
7800         iconv with 4xNULL arguments initially, to reset the state. Call iconv
7801         with 2xNULL arguments, also to flush the state storage. Handle the
7802         IRIX iconv behaviour. Realloc the final result, to throw away unused
7803         memory.
7804
7805 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
7806
7807         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
7808         and fchmodat unconditionally, since glibc 2.4 has them.
7809         Problem reported by Arkadiusz Miskiewicz.
7810
7811 2006-12-10  Bruno Haible  <bruno@clisp.org>
7812
7813         * gnulib-tool (func_import): Show the include files only for those
7814         modules that are copied and specified.
7815         Reported by Karl Berry.
7816
7817 2006-12-08  Jim Meyering  <jim@meyering.net>
7818
7819         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
7820         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
7821
7822         * build-aux/announce-gen: Add two new options, both optional:
7823         --bootstrap-tools=TOOL_LIST
7824               a comma-separated list of tools, e.g.,
7825               autoconf,automake,bison,gnulib
7826         --gnulib-snapshot-date=DATE
7827               if gnulib is in the bootstrap tool list,
7828               then report this as the snapshot date.
7829               If not specified, use the current date/time.
7830               If you specify a date here, be sure it's UTC.
7831
7832 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7833
7834         * tests/test-argp-2.sh: Fix test to match actual output.
7835         (func_compare): Fix sed script to be portable.
7836
7837 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
7838
7839         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
7840         workaround for this case.  It is not autoconfigured now; offhand
7841         it's hard to see how to autoconfigure it.
7842
7843 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
7844
7845         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
7846         a directory that is about to be chowned.  Such a directory's
7847         initial file permissions should permit the owner only and this
7848         should not be changed until after the chown, since the group and
7849         other bits would be incorrect if they granted permission before
7850         the chown.
7851
7852         Fix porting problem for iswctype reported by Georg Schwarz in:
7853         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
7854         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
7855         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
7856         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
7857         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
7858
7859 2006-12-03  Jim Meyering  <jim@meyering.net>
7860
7861         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
7862         p->fts_statp may not yet be defined.
7863         (fts_read): Instead, set it in the caller, once p->fts_statp is
7864         sure to be defined, and corresponds to a top-level directory.
7865         This bug made du -x fail.  Here's the coreutils test case:
7866         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
7867         Reported by Mike Frysinger.
7868
7869 2006-12-01  Jim Meyering  <jim@meyering.net>
7870
7871         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
7872         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
7873         Reported by Simon Josefsson.
7874
7875 2006-11-30  Jim Meyering  <jim@meyering.net>
7876
7877         * m4/warning.m4: Use the all-permissive copyright notice
7878         recommended by RMS (rather than LGPL).
7879         * m4/vararrays.m4: Likewise.
7880         * m4/flexmember.m4: Likewise.
7881
7882 2006-11-29  Bruno Haible  <bruno@clisp.org>
7883
7884         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
7885         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
7886         using +=.
7887         Reported by Simon Josefsson <simon@josefsson.org>.
7888
7889 2006-11-28  James Youngman <jay@gnu.org>
7890
7891         * README: Advise users that they might find the bug-gnulib@gnu.org
7892         and autotools-announce@gnu.org mailing lists useful.
7893
7894 2006-11-28  Bruno Haible  <bruno@clisp.org>
7895
7896         * m4/ptrdiff_max.m4: Remove file.
7897
7898 2006-11-21  Bruno Haible  <bruno@clisp.org>
7899
7900         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
7901         _AC_COMPUTE_INT.
7902         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7903         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
7904         _AC_COMPUTE_INT.
7905         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7906         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
7907         _AC_COMPUTE_INT.
7908         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7909
7910 2006-11-28  Jim Meyering  <jim@meyering.net>
7911
7912         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
7913         warning from "gcc -Wshadow" about shadowing the builtin.
7914
7915 2006-11-27  Bruno Haible  <bruno@clisp.org>
7916
7917         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
7918         _AC_COMPUTE_INT.
7919         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7920
7921 2006-11-27  Bruno Haible  <bruno@clisp.org>
7922             Paul Eggert  <eggert@cs.ucla.edu>
7923
7924         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
7925
7926 2006-11-26  Bruno Haible  <bruno@clisp.org>
7927
7928         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
7929         noinst_LTLIBRARIES.
7930
7931 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
7932             Bruno Haible  <bruno@clisp.org>
7933
7934         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
7935         if compiling with "gcc -ansi".
7936
7937 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
7938
7939         Fix some incompatibilities with gcc -ansi -pedantic.
7940         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
7941         if compiling pedantically with GCC, unless it's C99 or later.
7942         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
7943         it mishandles gcc -ansi -pedantic as well.
7944         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
7945         if gcc -pedantic.
7946         * lib/regexec.c (check_node_accept_bytes): Don't use auto
7947         initializers for struct if -pedantic, unless it's C99 or later.
7948
7949 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
7950
7951         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
7952         Don't close an fd more than once. Identical atimes indicate
7953         success, not failure.
7954
7955 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
7956
7957         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
7958
7959 2006-11-23  Jim Meyering  <jim@meyering.net>
7960
7961         * build-aux/announce-gen: New file.  From coreutils.
7962
7963 2006-11-22  Jim Meyering  <jim@meyering.net>
7964
7965         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
7966         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
7967         (fts_read): Use a temporary to narrow the overused st_size member
7968         before using it in a switch statement.  Reported by Matthew Woehlke.
7969
7970         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
7971         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
7972
7973 2006-11-20  Bruno Haible  <bruno@clisp.org>
7974
7975         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
7976         changequote instead of pairs of brackets.
7977         Reported by Andreas Schwab <schwab@suse.de>.
7978
7979 2006-11-21  Jim Meyering  <jim@meyering.net>
7980
7981         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
7982         so as to remain compatible with older compilers.
7983         Patch from Michael Deutschmann.
7984
7985 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
7986
7987         * MODULES.html.sh (File system functions): Add openat.
7988
7989         * lib/openat.h (rpl_fstatat): New macro, if
7990         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
7991         (fstatat): Define to rpl_fstatat under the same conditions,
7992         unless COMPILING_FSTATAT.
7993         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
7994         seems to have the bug.
7995         * lib/fstatat.c: New file.
7996         * modules/openat (Files): Add it.
7997
7998 2006-11-20  Bruno Haible  <bruno@clisp.org>
7999
8000         * Makefile: New file.
8001
8002 2006-11-20  Jim Meyering  <jim@meyering.net>
8003
8004         The beginnings of syntax-related checks for gnulib.
8005         * lib/Makefile: New file.
8006         * lib/t-idcache: New script.  Ensure that the two halves of
8007         idcache.c stay in sync.
8008
8009         * lib/idcache.c: Adjust comments in user- and group- portions to
8010         be more accurate, and to be consistent with one another.
8011
8012 2006-11-20  Jim Meyering  <jim@meyering.net>
8013
8014         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
8015         continue using the flexible array member (thus, this module performs
8016         half as many malloc calls), with the addition that...
8017         (getgroup, getuser): Consistently record a non-match via an empty
8018         "name" string, and map an empty string match to a NULL return value.
8019         * modules/idcache (Depends-on): Re-add flexmember.
8020
8021         * lib/idcache.c (getuser): Remove all uses of the register keyword.
8022         (getuidbyname, getgroup, getgidbyname): Likewise.
8023
8024         Use cleaner syntax: NULL rather than 0.
8025         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
8026
8027 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8028
8029         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
8030         It mishandled the case where the group was missing.
8031         Problem reported by Greg Schafer.
8032         * modules/idcache: Likewise.
8033
8034 2006-11-18  Jim Meyering  <jim@meyering.net>
8035
8036         * check-module (%exempt_header): Add exception for some
8037         conditionally-included headers.
8038
8039         * modules/i-ring (Depends-on): Add verify.
8040         (License): Change to LGPL.
8041
8042 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
8043
8044         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
8045         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
8046         and inttostr.h.  Use snprintf rather than uinttostr, so that
8047         LGPLed code doesn't depend on GPLed.
8048
8049 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
8050
8051         * modules/inline (License): Change from GPL to LGPL.
8052
8053 2006-11-17  Jim Meyering  <jim@meyering.net>
8054
8055         * modules/d-type (License): Switch to LGPL.
8056
8057 2006-11-15  Bruno Haible  <bruno@clisp.org>
8058
8059         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
8060
8061 2006-11-15  Eric Blake  <ebb9@byu.net>
8062
8063         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
8064         the module dependency.
8065
8066 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8067             Bruno Haible  <bruno@clisp.org>
8068
8069         * gnulib-tool (func_create_testdir): Add license consistency check.
8070
8071 2006-11-15  Eric Blake  <ebb9@byu.net>
8072
8073         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
8074         random "(cached)" in configure output.
8075
8076 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8077
8078         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
8079         test for conforming inttypes.h is both announced and cached.
8080
8081         * MODULES.html.sh (seen_modules, seen_files): New variables.
8082         (func_module): Rewrite to use a few less gnulib-tool and sed
8083         invocations.  Avoid a couple of quadratic algorithms for ...
8084         (missed_modules, missed_files): ... these, with ...
8085         (func_append, func_tmpdir): ... these new functions, from
8086         gnulib-tool.  Analogously, install traps for cleanup.
8087
8088         * tests/test-gc.c (main): Remove unused variables.
8089         * tests/test-read-file.c: Include stdlib.h, for 'free'.
8090
8091 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
8092
8093         * modules/inttostr (License): Change to LGPL.
8094
8095 2006-11-14  Eric Blake  <ebb9@byu.net>
8096
8097         * modules/tempname (License): Change to LGPL.
8098
8099 2006-11-14  Eric Blake  <ebb9@byu.net>
8100
8101         * doc/functions.texi (Function Portability): *printf functions on
8102         Cygwin now understand all POSIX size specifiers.
8103
8104 2006-11-14  Bruno Haible  <bruno@clisp.org>
8105
8106         * modules/c-ctype (License): Change to LGPL.
8107
8108 2006-11-12  Bruno Haible  <bruno@clisp.org>
8109
8110         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
8111         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
8112         for GNOME libraries, for which the include files are installed in
8113         subdirectories of $prefix/include.
8114
8115 2006-11-12  Bruno Haible  <bruno@clisp.org>
8116
8117         * m4/lib-link.m4: Require at least autoconf-2.54.
8118         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
8119         name to underscores for the --with option.
8120
8121 2006-11-13  Bruno Haible  <bruno@clisp.org>
8122
8123         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
8124         the tests directory.
8125         Reported by Ralf Wildenhues.
8126
8127 2006-11-13  Bruno Haible  <bruno@clisp.org>
8128
8129         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
8130         (func_emit_initmacro_end): Undo the override here.
8131         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
8132         Works around the famous automake error in coreutils.
8133
8134 2006-11-13  Eric Blake  <ebb9@byu.net>
8135
8136         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
8137         element, not its node.
8138
8139 2006-11-12  Bruno Haible  <bruno@clisp.org>
8140
8141         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
8142         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
8143
8144 2006-11-12  Bruno Haible  <bruno@clisp.org>
8145
8146         * gnulib-tool: New option --local-symlink.
8147         (func_usage): Document it.
8148         (lsymbolic): New variable.
8149         (func_import, func_create_testdir): If --symlink was not specified,
8150         test whether --local-symlink was specified and the file comes from
8151         the local_gnulib_dir.
8152
8153 2006-11-12  Bruno Haible  <bruno@clisp.org>
8154
8155         * gnulib-tool (func_ln): New function.
8156         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
8157
8158 2006-11-12  Bruno Haible  <bruno@clisp.org>
8159
8160         Finish support for source files in subdirectories.
8161         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
8162         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
8163         AUTOMAKE_OPTIONS.
8164         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
8165
8166 2006-11-12  Bruno Haible  <bruno@clisp.org>
8167
8168         * gnulib-tool (func_get_automake_snippet): Synthesize also an
8169         EXTRA_lib_SOURCES augmentation.
8170         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
8171
8172 2006-11-12  Jim Meyering  <jim@meyering.net>
8173
8174         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
8175         file descriptors.  This also averts a failure on systems with
8176         native openat support when a traversed directory lacks "x" access.
8177         * lib/fts_.h: Include "i-ring.h"
8178         (struct FTS) [fts_fd_ring]: New member.
8179         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
8180         (FCHDIR): Add parentheses.
8181         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
8182         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
8183         When descending, rather than simply closing the previous
8184         fts_cwd_fd value, push that file descriptor onto the ring.
8185         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
8186         (fts_open): Initialize the new fd_ring member.
8187         (fts_close): Clear the ring.
8188         (fts_safe_changedir): When possible, use our new fd_ring to skip
8189         the diropen and fstat and dev/ino comparison that would normally
8190         accompany a virtual `chdir ("..")'.
8191
8192         * modules/fts (Depends-on): Add i-ring.
8193         * modules/i-ring: New module.
8194         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
8195         * m4/i-ring.m4: New file.
8196
8197 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8198
8199         * gnulib-tool (func_create_testdir): Fix replacement of
8200         `build-aux' in configure.ac.  Run autotools in gltests
8201         subdirectory.
8202         (func_create_testdir, func_create_megatestdir, test): There is
8203         no need for '--force' in most autotool invocations in a new
8204         tree.  Actually fail the whole test if any of the tools, or the
8205         configure or make stages fail.
8206
8207         Sync from Automake.
8208         * build-aux/gnupload: Revert last change.  Add pointer to upload
8209         instructions of the GNU Maintenance Instructions.
8210         Suggestion by Karl Berry.
8211
8212 2006-11-10  Jim Meyering  <jim@meyering.net>
8213
8214         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
8215
8216 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8217
8218         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
8219         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
8220         (bind_textdomain_codeset) [! ENABLE_NLS]:
8221         Evaluate all the arguments.  That way, callers get compatible behavior
8222         if the arguments have side effects.  Also, it avoids some GCC
8223         diagnostics in some cases; Joel E. Denny reported problems when Bison
8224         was configured with --enable-gcc-warnigs.
8225
8226 2006-11-10  Jim Meyering  <jim@meyering.net>
8227
8228         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
8229         relevant options in CFLAGS (like -O, -fno-inline) are taken into
8230         account.
8231
8232 2006-11-10  Jim Meyering  <jim@meyering.net>
8233
8234         * modules/inline: New file/module.
8235         * modules/xalloc (Files): Remove m4/inline.m4.
8236         (Depends-on): Add inline, instead.
8237         * modules/oset: Likewise.
8238         * modules/list: Likewise.
8239
8240 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8241
8242         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
8243         Problem reported by Matthew Woehlke.
8244
8245 2006-11-09  Bruno Haible  <bruno@clisp.org>
8246
8247         * lib/tempname.c (gen_tempname): Remove variant that invokes
8248         __gen_tempname.
8249         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
8250         __gen_tempname.
8251
8252 2006-11-08  Bruno Haible  <bruno@clisp.org>
8253
8254         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
8255         to 'yes' instead of 'cross-compiling'.
8256
8257 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
8258
8259         * lib/quotearg.h (quotearg_free): New decl.
8260         * lib/quotearg.c (quotearg_free): New function.
8261         (slot0, nslots, slotvec0, slotvec):
8262         Now file-scope so that quotearg_free can get at them.
8263
8264 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8265
8266         Sync from Automake.
8267         * build-aux/gnupload: Add missing 'gnu' to example URL.
8268         Report by Karl Berry.
8269
8270 2006-11-08  Bruno Haible  <bruno@clisp.org>
8271
8272         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
8273         Suggested by Paul Eggert.
8274
8275 2006-11-08  Jim Meyering  <jim@meyering.net>
8276
8277         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
8278         It's already included if !_LIBC.
8279         (fts_safe_changedir): Add a comment.
8280
8281 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8282
8283         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
8284         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
8285         Matthew Woehlke.
8286
8287         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
8288         definitions up, to avoid colliding with change below.
8289         (static_inline) [HAVE_INLINE]: New macro.
8290         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
8291         Provide extern decls when !HAVE_INLINE.  Do not define unless
8292         static_inline is defined, either by us or by xmalloc.c.  Use
8293         static_inline rather than static inline.
8294         (XCALLOC): Optimize sizeof(T) = 1 case.
8295         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
8296
8297 2006-11-07  Bruno Haible  <bruno@clisp.org>
8298
8299         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
8300         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
8301         AC_C_INLINE.
8302         * modules/xalloc (Files): Add m4/inline.m4.
8303
8304 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8305
8306         * README: Fix typo.
8307         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
8308         (Miscellanous Notes): ...from this.
8309
8310 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8311
8312         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
8313         Mention that offsetof should be used instead of sizeof.
8314         From Bruno Haible.
8315
8316 2006-11-07  Bruno Haible  <bruno@clisp.org>
8317
8318         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
8319
8320 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8321
8322         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8323         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
8324         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8325         (gl_tree_add_before, gl_tree_add_after):
8326         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
8327         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
8328         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
8329         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
8330         (gl_linked_add_after, gl_linked_add_at): Likewise.
8331         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
8332         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8333         (gl_tree_add_before, gl_tree_add_after): Likewise.
8334         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
8335         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
8336         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
8337
8338 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8339
8340         * lib/gl_oset.h: Use C comment style, not C++ comment style.
8341
8342 2006-11-06  Bruno Haible  <bruno@clisp.org>
8343
8344         * m4/inline.m4: New file.
8345         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
8346         * modules/list (Files): Add m4/inline.m4.
8347         * modules/oset (Files): Likewise.
8348
8349 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8350
8351         * lib/idcache.c: Include <stddef.h>, for offsetof.
8352         (struct userid.name): Change from char * to a flexible array member.
8353         All uses changed.
8354         * modules/idcache (Depends-on): Add flexmember.
8355
8356         * MODULES.html.sh (Core language properties): New module flexmember.
8357         * modules/flexmember, m4/flexmember.m4: New files.
8358
8359         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
8360         inline functions that are identical with the old xnmalloc_inline,
8361         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
8362         that we can avoid some unnecessary integer multiplications and
8363         divisions in the common case where the element size is known at
8364         compile time.
8365         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
8366         needed.
8367         (xnboundedmalloc): Remove.
8368         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
8369         arguments, for consistency with rest of this header.
8370         (xcharalloc): Rewrite using XNMALLOC.
8371         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
8372         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
8373         versions have been moved to lib/xalloc.h and renamed to be the
8374         non-*_inline versions.
8375         (xmalloc, xrealloc): Implement without reference to the xnmalloc
8376         and xnrealloc functions, since those functions are now inline and
8377         now call us.
8378         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
8379         renaming described above.
8380         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
8381         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
8382         captures the dependency in AC_C_INLINE.
8383
8384         New module canonicalize-lgpl, proposed by Charles Wilson in
8385         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
8386         with a few small changes afterwards.
8387         * MODULES.html.sh (File system functions): New module
8388         canonicalize-lgpl.
8389         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
8390         and canonicalize_file_name.
8391         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
8392         * modules/canonicalize-lgpl: New files.
8393
8394 2006-11-05  Bruno Haible  <bruno@clisp.org>
8395
8396         * gnulib-tool (func_import, func_create_testdir): Create directories
8397         also for files in subdirectories of lib/.
8398
8399 2006-11-05  Bruno Haible  <bruno@clisp.org>
8400
8401         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
8402         ANSI C compliant.
8403
8404 2006-11-03  Bruno Haible  <bruno@clisp.org>
8405
8406         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8407         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
8408         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
8409         (xnboundedmalloc): New inline function.
8410         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
8411         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
8412         xmalloc.
8413         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
8414         xmalloc.
8415         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
8416         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
8417         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
8418         xmalloc.
8419         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8420         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
8421         xmalloc.
8422         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
8423         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8424         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
8425         xmalloc.
8426         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8427         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
8428         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8429         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
8430         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
8431         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
8432         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
8433
8434 2006-11-03  Bruno Haible  <bruno@clisp.org>
8435
8436         * lib/c-ctype.h [C++]: Define functions without name mangling.
8437         * lib/fwriteerror.h [C++]: Likewise.
8438         * lib/gcd.h [C++]: Likewise.
8439         * lib/linebreak.h [C++]: Likewise.
8440
8441 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
8442
8443         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
8444         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
8445         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
8446         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
8447         Check for functions and headers just once.
8448         Check for declaration of canonicalize_file_name.
8449         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
8450
8451 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
8452
8453         * gnulib-tool (func_import): Fix typo in actioncmd.
8454
8455 2006-11-02  Bruno Haible  <bruno@clisp.org>
8456
8457         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
8458         newline sequence in the Makefile.am snippet as a space, like "make"
8459         does.
8460         Reported by Roger Persson <perrog@gmail.com>.
8461
8462 2006-11-01  Bruno Haible  <bruno@clisp.org>
8463
8464         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
8465         already declared in <string.h>.
8466         * lib/strcase.h (strncasecmp): Don't declare it if yes.
8467
8468 2006-11-01  Bruno Haible  <bruno@clisp.org>
8469
8470         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
8471         * lib/strcase.h: Include <string.h>.
8472         (strcasecmp): Define to rpl_strcasecmp here.
8473
8474 2006-11-01  Bruno Haible  <bruno@clisp.org>
8475
8476         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
8477
8478 2006-11-01  Eric Blake  <ebb9@byu.net>
8479
8480         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
8481
8482         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
8483
8484 2006-10-29  Bruno Haible  <bruno@clisp.org>
8485
8486         Make it compile in C++ mode.
8487         * lib/full-write.c (full_rw): Add a cast.
8488
8489 2006-11-01  Bruno Haible  <bruno@clisp.org>
8490
8491         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
8492         be POSIX compliant.
8493         Reported by Roger Persson <perrog@gmail.com>.
8494
8495 2006-11-01  Eric Blake  <ebb9@byu.net>
8496
8497         * lib/getopt_.h: Fix comments.
8498
8499 2006-10-31  Eric Blake  <ebb9@byu.net>
8500
8501         * modules/tmpdir (Depends-on): Add sys_stat.
8502         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
8503         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
8504         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
8505         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
8506         tempname.
8507
8508 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
8509
8510         Avoid some C++ diagnostics reported by Bruno Haible.
8511         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
8512         xmalloc.
8513         (quotearg_alloc): Use xcharalloc rather than xmalloc.
8514         (struct slotvec): Move to top level.
8515         (quotearg_n_options): Rewrite to avoid xmalloc.
8516         * lib/xalloc.h (xcharalloc): New function.
8517         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
8518         [defined __cplusplus]: Add function template that provides result
8519         type propagation.  This part of the change is from Bruno Haible.
8520
8521 2006-10-29  Bruno Haible  <bruno@clisp.org>
8522
8523         Make it compile in C++ mode.
8524         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
8525         * lib/strnlen1.c (strnlen1): Cast memchr result.
8526         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
8527         * lib/clean-temp.c (string_equals, string_hash): Add casts.
8528         (create_temp_dir): Rename local variable 'template'.
8529         (compile_csharp_using_sscli): Add cast.
8530         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
8531         * lib/findprog.c (find_in_path): Likewise.
8532         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
8533         * lib/wait-process.c (register_slave_subprocess): Likewise.
8534
8535 2006-10-22  Bruno Haible  <bruno@clisp.org>
8536
8537         * modules/tsearch: New file.
8538         * lib/tsearch.h: New file.
8539         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
8540         * m4/tsearch.m4: New file.
8541         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
8542
8543 2006-10-29  Eric Blake  <ebb9@byu.net>
8544
8545         * lib/arcfour.c: Assume config.h.
8546         * lib/arctwo.c: Likewise.
8547         * lib/base64.c: Likewise.
8548         * lib/check-version.c: Likewise.
8549         * lib/crc.c: Likewise.
8550         * lib/des.c: Likewise.
8551         * lib/gc-gnulib.c: Likewise.
8552         * lib/gc-libgcrypt.c: Likewise.
8553         * lib/gc-pbkdf2-sha1.c: Likewise.
8554         * lib/getaddrinfo.c: Likewise.
8555         * lib/getdelim.c: Likewise.
8556         * lib/getline.c: Likewise.
8557         * lib/hmac-md5.c: Likewise.
8558         * lib/hmac-sha1.c: Likewise.
8559         * lib/iconvme.c: Likewise.
8560         * lib/md2.c: Likewise.
8561         * lib/md4.c: Likewise.
8562         * lib/memxor.c: Likewise.
8563         * lib/read-file.c: Likewise.
8564         * lib/readline.c: Likewise.
8565         * lib/rijndael-alg-fst.c: Likewise.
8566         * lib/rijndael-api-fst.c: Likewise.
8567         * lib/xgetdomainname.c: Likewise.
8568
8569 2006-10-28  Eric Blake  <ebb9@byu.net>
8570
8571         * lib/xstrndup.c: Assume config.h.
8572
8573 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8574
8575         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
8576         stat-macros.h is now for our own macros, whereas stat_h is for
8577         macros in the <sys/stat.h> name space.
8578         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
8579         (STAT_MACROS_H): Remove.
8580         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
8581         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
8582         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
8583         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
8584         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
8585         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
8586         Move these macros to ...
8587         * lib/stat_.h: here.  Don't include stat-macros.h.
8588         * lib/canonicalize.c: Don't include stat-macros.h.
8589         * lib/chown.c: Likewise.
8590         * lib/euidaccess.c: Likewise.
8591         * lib/file-type.c: Likewise.
8592         * lib/filemode.c: Likewise.
8593         * lib/glob.c: Likewise.
8594         * lib/isapipe.c: Likewise.
8595         * lib/lchown.c: Likewise.
8596         * lib/lstat.c: Likewise.
8597         * lib/mkdir-p.c: Likewise.
8598         * lib/rmdir.c: Likewise.
8599         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
8600         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
8601         unless mkdir isn't declared, to speed up 'configure'.
8602         Always create sys/stat.h, since it's unlikely any real sys/stat.h
8603         would define all the S_* symbols.
8604         * modules/canonicalize (Depends-on):
8605         Depend on sys_stat, not stat-macros.
8606         * modules/chown: Likewise.
8607         * modules/euidaccess: Likewise.
8608         * modules/filemode: Likewise.
8609         * modules/file-type: Likewise.
8610         * modules/glob: Likewise.
8611         * modules/isapipe: Likewise.
8612         * modules/lchown: Likewise.
8613         * modules/lstat: Likewise.
8614         * modules/mkancesdirs: Likewise.
8615         * modules/rmdir: Likewise.
8616         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
8617         * modules/modechange: Likewise.
8618         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
8619         (configure.ac): Remove gl_STAT_MACROS.
8620         * modules/sys_stat (Depends-on): Remove stat-macros.
8621
8622 2006-10-27  Bruno Haible  <bruno@clisp.org>
8623
8624         * m4/signed.m4: Remove file.
8625         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
8626         invocation.
8627         * modules/vasnprintf (Files): Remove m4/signed.m4.
8628
8629 2006-10-27  Bruno Haible  <bruno@clisp.org>
8630
8631         Update to GNU gettext 0.16.
8632         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
8633         m4/inttypes-h.m4, m4/signed.m4.
8634         * m4/gettext.m4: Update to GNU gettext 0.16.
8635         * m4/intl.m4: New file, from GNU gettext.
8636         * m4/intldir.m4: New file, from GNU gettext.
8637         * config/srclist.txt: Update
8638
8639 2006-10-27  Eric Blake  <ebb9@byu.net>
8640
8641         * MODULES.html.sh: Document tempname.
8642         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
8643         dependencies.
8644         (Files): Move lib/tempname.c...
8645         * modules/tempname: ...to this new module.
8646         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
8647         (gl_PREREQ_TEMPNAME): Move...
8648         * m4/tempname.m4: ...to this new file.
8649         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
8650         * modules/sys_stat (Depends-on): Add stat-macros.
8651         * lib/stat_.h (includes): Pick up stat macros.
8652         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
8653         if stat macros are broken.
8654         * lib/tempname.c (includes): No need to include "stat-macros.h".
8655         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
8656         (direxists, __path_search) [!_LIBC]: Don't compile these in
8657         gnulib; the tmpdir module covers that.
8658         * lib/tempname.h: New file.
8659
8660 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
8661
8662         * COPYING: Explain how gnulib-tool converts licence headers.
8663         Almost all wording by Eric Blake.
8664
8665 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
8666
8667         * lib/mbchar.h (is_basic_table): Make read-only.
8668         * lib/mbchar.c (is_basic_table): Likewise.
8669         Reported by John Darrington.
8670
8671 2006-10-25  Bruno Haible  <bruno@clisp.org>
8672
8673         * lib/progname.h (set_program_name): Undefine before defining.
8674
8675 2006-10-25  Bruno Haible  <bruno@clisp.org>
8676
8677         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
8678         false for non-gcc C++ compilers.
8679         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
8680
8681 2006-10-24  Bruno Haible  <bruno@clisp.org>
8682
8683         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
8684         iconv implementations like Irix iconv.
8685
8686 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
8687
8688         * modules/vararrays: New file.
8689         * m4/vararrays.m4: New file, taken from diffutils.
8690         * MODULES.html.sh: New module vararrays.
8691
8692 2006-10-24  Karl Berry  <karl@gnu.org>
8693
8694         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
8695         Don't call GNU Unix.
8696
8697 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8698
8699         * users.txt: Add Libtool.
8700
8701         Sync from Libtool:
8702
8703         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
8704
8705         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
8706         to gnulib's policy of including config.h unconditionally.
8707
8708 2006-10-24  Bruno Haible  <bruno@clisp.org>
8709
8710         * modules/wcwidth (Files): Add m4/wint_t.m4.
8711         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
8712         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
8713
8714 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
8715
8716         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
8717         to pacify GCC with some -W flags enabled.  Problem reported by
8718         Bruno Haible.
8719
8720 2006-10-24  Jim Meyering  <jim@meyering.net>
8721
8722         * MODULES.html.sh: Remove uinttostr.  It's not a module.
8723         Reported by Karl Berry.
8724
8725 2006-10-23  Bruno Haible  <bruno@clisp.org>
8726
8727         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
8728
8729 2006-10-24  Bruno Haible  <bruno@clisp.org>
8730
8731         * lib/gl_list.h: Use C comment style, not C++ comment style.
8732
8733 2006-10-23  Eric Blake  <ebb9@byu.net>
8734
8735         * lib/getaddrinfo.c (includes): Add missing include.
8736
8737 2006-10-23  Bruno Haible  <bruno@clisp.org>
8738             Paul Eggert  <eggert@cs.ucla.edu>
8739
8740         Ability to rename obstack_free.
8741         * lib/obstack.h (__obstack_free): New macro. Declare instead of
8742         obstack_free.
8743         (obstack_free): Invoke the __obstack_free macro.
8744         * lib/obstack.c (obstack_free): Use __obstack_free macro.
8745
8746 2006-10-23  Bruno Haible  <bruno@clisp.org>
8747             Paul Eggert  <eggert@cs.ucla.edu>
8748
8749         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
8750         __argc, __argv from the declaration. (They are defined as macros on
8751         mingw.)
8752
8753 2006-10-22  Bruno Haible  <bruno@clisp.org>
8754
8755         * doc/gnulib-intro.texi: New file.
8756         * doc/gnulib.texi: Include it.
8757
8758 2006-10-21  Bruno Haible  <bruno@clisp.org>
8759
8760         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
8761         "Introduction", "Miscellanous Notes", "Particular Modules".
8762
8763 2006-10-21  Bruno Haible  <bruno@clisp.org>
8764
8765         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8766         Change mostlyclean-local rule to avoid sh syntax error from bash
8767         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
8768
8769 2006-10-23  Jim Meyering  <jim@meyering.net>
8770
8771         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
8772         in place of snprintf.
8773
8774         * modules/inttostr (Files): Add lib/uinttostr.c.
8775         * lib/uinttostr.c (inttostr): New file/function.
8776         * lib/inttostr.h (uinttostr): Declare.
8777         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
8778         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
8779         Add uinttostr.
8780         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
8781
8782 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
8783
8784         * lib/canonicalize.c (ELOOP): Define if not already defined.
8785         Problem reported by Bruno Haible in
8786         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
8787
8788 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
8789
8790         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
8791         Problem reported by Perry Smith and Ville Laurikari.
8792
8793         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
8794         uses.
8795
8796 2006-10-19  Bruno Haible  <bruno@clisp.org>
8797
8798         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
8799         for mingw.
8800
8801 2006-10-19  Bruno Haible  <bruno@clisp.org>
8802
8803         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
8804         Needed for mingw.
8805
8806 2006-10-19  Bruno Haible  <bruno@clisp.org>
8807
8808         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
8809
8810 2006-10-19  Bruno Haible  <bruno@clisp.org>
8811
8812         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
8813         it.
8814
8815 2006-10-19  Bruno Haible  <bruno@clisp.org>
8816
8817         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
8818         invocation.
8819
8820 2006-10-19  Bruno Haible  <bruno@clisp.org>
8821
8822         * gnulib-tool (func_create_testdir): Don't include ftruncate and
8823         mountlist by default.
8824
8825 2006-10-16  Bruno Haible  <bruno@clisp.org>
8826
8827         * lib/c-strstr.c: Include c-strstr.h.
8828
8829 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
8830
8831         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
8832         in a slash.
8833
8834 2006-10-18  Bruno Haible  <bruno@clisp.org>
8835
8836         * lib/lock.h [C++]: Wrap definitions in extern "C".
8837
8838 2006-10-18  Bruno Haible  <bruno@clisp.org>
8839
8840         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
8841         gl_LIBOBJS list.
8842
8843 2006-10-18  Bruno Haible  <bruno@clisp.org>
8844
8845         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
8846
8847 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
8848
8849         * lib/xstrtol.h: Include gettext.h.
8850         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
8851         Problem reported by Eric Blake.
8852         * modules/xstrtol (Depends-on): Add gettext-h.
8853
8854 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
8855
8856         * lib/strftime.c (advance): New macro.
8857         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
8858         incomplete type, so you can't add 0 to it.  Problem and patch
8859         reported by Eelco Dolstra for dietlibc.
8860
8861 2006-10-18  Jim Meyering  <jim@meyering.net>
8862
8863         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
8864         type for a local, and rename it: s/up/user_proc/.
8865
8866 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
8867
8868         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
8869         READ_UTMP_USER_PROCESS.
8870         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
8871
8872 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
8873
8874         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
8875         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
8876
8877 2006-10-17  Eric Blake  <ebb9@byu.net>
8878
8879         * lib/sigprocmask.c (sigprocmask): Fix typo.
8880
8881         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
8882
8883         * modules/clean-temp (Makefile.am): Don't add to make output...
8884         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
8885         config.h.
8886
8887 2006-10-17  Bruno Haible  <bruno@clisp.org>
8888
8889         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
8890         differently if DEFAULT_TEXT_DOMAIN is set.
8891
8892 2006-10-16  Bruno Haible  <bruno@clisp.org>
8893
8894         * lib/clean-temp.c: Include fwriteerror.h.
8895
8896 2006-10-16  Bruno Haible  <bruno@clisp.org>
8897
8898         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
8899
8900 2006-10-16  Bruno Haible  <bruno@clisp.org>
8901
8902         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
8903         * lib/sigprocmask.h: Include <sys/types.h>.
8904         (sigset_t): Use the system's definition if present.
8905
8906 2006-10-17  Eric Blake  <ebb9@byu.net>
8907
8908         * lib/xvasprintf.c (includes): Assume config.h.
8909         * lib/xasprintf.c (includes): Likewise.
8910
8911 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
8912
8913         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
8914         at least as wide as intmax_t.
8915
8916 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
8917
8918         (Imported from Automake.)
8919         * build-aux/gnupload: Update to version 1.1 of directive file.
8920
8921 2006-10-16  Eric Blake  <ebb9@byu.net>
8922
8923         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
8924         match Automake 1.10a.
8925
8926 2006-10-14  Bruno Haible  <bruno@clisp.org>
8927
8928         * modules/sigprocmask: New file.
8929         * lib/sigprocmask.h: New file.
8930         * lib/sigprocmask.c: New file.
8931         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
8932         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
8933         request sigprocmask.o.
8934         (gl_PREREQ_SIGPROCMASK): New macro.
8935         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
8936         (Depends-on): Add sigprocmask.
8937         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
8938         gt_SIGNALBLOCKING. Test for 'raise' only once.
8939         * lib/fatal-signal.c: Include sigprocmask.h.
8940         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
8941         unblock_fatal_signals): Define always.
8942         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
8943         sigprocmask.
8944
8945 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
8946
8947         Sync from Automake.
8948         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
8949         which incorrectly sets the mode of an existing destination
8950         directory.  In some cases the unpatched install-sh could do the
8951         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
8952         system.  We hope this is rare in practice, but it's clearly worth
8953         fixing.  Problem reported by Alex Unleashed in
8954         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
8955         Also, don't bother to check for -m bugs unless we're using -m;
8956         suggested by Stepan Kasal.
8957
8958 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8959
8960         Sync from Automake.
8961         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
8962         `-c' flag, so they appear at the same position as in %FASTDEP%
8963         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
8964         which ignores unknown options only after the first non-option.
8965         Bug report against M4 by Nelson H. F. Beebe.
8966
8967 2006-10-13  Jim Meyering  <jim@meyering.net>
8968
8969         Fix a bug in yesterday's change.
8970         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
8971         p->fts_statp->st_dev would be used uninitialized.
8972         Ensures that we always call fts_stat on the very first entry.
8973         Miklos Szeredi reported that find -xdev stopped working.
8974
8975 2006-10-12  Bruno Haible  <bruno@clisp.org>
8976
8977         * gnulib-tool (func_get_automake_snippet): Append an automatically
8978         computed EXTRA_DIST augmentation.
8979         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
8980         * modules/alloca-opt (Makefile.am): Likewise.
8981         * modules/allocsa (Makefile.am): Likewise.
8982         * modules/arcfour (Makefile.am): Likewise.
8983         * modules/arctwo (Makefile.am): Likewise.
8984         * modules/argmatch (Makefile.am): Likewise.
8985         * modules/argz (Makefile.am): Likewise.
8986         * modules/atexit (Makefile.am): Likewise.
8987         * modules/backupfile (Makefile.am): Likewise.
8988         * modules/byteswap (Makefile.am): Likewise.
8989         * modules/c-strtod (Makefile.am): Likewise.
8990         * modules/c-strtold (Makefile.am): Likewise.
8991         * modules/calloc (Makefile.am): Likewise.
8992         * modules/canon-host (Makefile.am): Likewise.
8993         * modules/canonicalize (Makefile.am): Likewise.
8994         * modules/chdir-long (Makefile.am): Likewise.
8995         * modules/chdir-safer (Makefile.am): Likewise.
8996         * modules/check-version (Makefile.am): Likewise.
8997         * modules/chown (Makefile.am): Likewise.
8998         * modules/cloexec (Makefile.am): Likewise.
8999         * modules/close-stream (Makefile.am): Likewise.
9000         * modules/closeout (Makefile.am): Likewise.
9001         * modules/crc (Makefile.am): Likewise.
9002         * modules/csharpexec (Makefile.am): Likewise.
9003         * modules/cycle-check (Makefile.am): Likewise.
9004         * modules/des (Makefile.am): Likewise.
9005         * modules/dev-ino (Makefile.am): Likewise.
9006         * modules/dirfd (Makefile.am): Likewise.
9007         * modules/dirname (Makefile.am): Likewise.
9008         * modules/dup2 (Makefile.am): Likewise.
9009         * modules/eealloc (Makefile.am): Likewise.
9010         * modules/error (Makefile.am): Likewise.
9011         * modules/euidaccess (Makefile.am): Likewise.
9012         * modules/exclude (Makefile.am): Likewise.
9013         * modules/exitfail (Makefile.am): Likewise.
9014         * modules/fcntl-safer (Makefile.am): Likewise.
9015         * modules/fcntl (Makefile.am): Likewise.
9016         * modules/file-type (Makefile.am): Likewise.
9017         * modules/fileblocks (Makefile.am): Likewise.
9018         * modules/filemode (Makefile.am): Likewise.
9019         * modules/filenamecat (Makefile.am): Likewise.
9020         * modules/fnmatch (Makefile.am): Likewise.
9021         * modules/fopen-safer (Makefile.am): Likewise.
9022         * modules/fpending (Makefile.am): Likewise.
9023         * modules/fprintftime (Makefile.am): Likewise.
9024         * modules/free (Makefile.am): Likewise.
9025         * modules/fsusage (Makefile.am): Likewise.
9026         * modules/ftruncate (Makefile.am): Likewise.
9027         * modules/fts (Makefile.am): Likewise.
9028         * modules/gc-arcfour (Makefile.am): Likewise.
9029         * modules/gc-des (Makefile.am): Likewise.
9030         * modules/gc-hmac-md5 (Makefile.am): Likewise.
9031         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
9032         * modules/gc-md4 (Makefile.am): Likewise.
9033         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9034         * modules/gc-sha1 (Makefile.am): Likewise.
9035         * modules/gc (Makefile.am): Likewise.
9036         * modules/getaddrinfo (Makefile.am): Likewise.
9037         * modules/getcwd (Makefile.am): Likewise.
9038         * modules/getdelim (Makefile.am): Likewise.
9039         * modules/getdomainname (Makefile.am): Likewise.
9040         * modules/getgroups (Makefile.am): Likewise.
9041         * modules/gethostname (Makefile.am): Likewise.
9042         * modules/gethrxtime (Makefile.am): Likewise.
9043         * modules/getline (Makefile.am): Likewise.
9044         * modules/getloadavg (Makefile.am): Likewise.
9045         * modules/getlogin_r (Makefile.am): Likewise.
9046         * modules/getndelim2 (Makefile.am): Likewise.
9047         * modules/getopt (Makefile.am): Likewise.
9048         * modules/getpagesize (Makefile.am): Likewise.
9049         * modules/getpass-gnu (Makefile.am): Likewise.
9050         * modules/getpass (Makefile.am): Likewise.
9051         * modules/getsubopt (Makefile.am): Likewise.
9052         * modules/gettime (Makefile.am): Likewise.
9053         * modules/gettimeofday (Makefile.am): Likewise.
9054         * modules/getugroups (Makefile.am): Likewise.
9055         * modules/getusershell (Makefile.am): Likewise.
9056         * modules/glob (Makefile.am): Likewise.
9057         * modules/group-member (Makefile.am): Likewise.
9058         * modules/hard-locale (Makefile.am): Likewise.
9059         * modules/hash (Makefile.am): Likewise.
9060         * modules/hmac-md5 (Makefile.am): Likewise.
9061         * modules/hmac-sha1 (Makefile.am): Likewise.
9062         * modules/human (Makefile.am): Likewise.
9063         * modules/idcache (Makefile.am): Likewise.
9064         * modules/imaxabs (Makefile.am): Likewise.
9065         * modules/imaxdiv (Makefile.am): Likewise.
9066         * modules/inet_ntop (Makefile.am): Likewise.
9067         * modules/inet_pton (Makefile.am): Likewise.
9068         * modules/intprops (Makefile.am): Likewise.
9069         * modules/inttostr (Makefile.am): Likewise.
9070         * modules/inttypes (Makefile.am): Likewise.
9071         * modules/isapipe (Makefile.am): Likewise.
9072         * modules/javaversion (Makefile.am): Likewise.
9073         * modules/lchmod (Makefile.am): Likewise.
9074         * modules/lchown (Makefile.am): Likewise.
9075         * modules/localcharset (Makefile.am): Likewise.
9076         * modules/long-options (Makefile.am): Likewise.
9077         * modules/lstat (Makefile.am): Likewise.
9078         * modules/malloc (Makefile.am): Likewise.
9079         * modules/mathl (Makefile.am): Likewise.
9080         * modules/mbchar (Makefile.am): Likewise.
9081         * modules/md2 (Makefile.am): Likewise.
9082         * modules/md4 (Makefile.am): Likewise.
9083         * modules/md5 (Makefile.am): Likewise.
9084         * modules/memcasecmp (Makefile.am): Likewise.
9085         * modules/memchr (Makefile.am): Likewise.
9086         * modules/memcmp (Makefile.am): Likewise.
9087         * modules/memcoll (Makefile.am): Likewise.
9088         * modules/memcpy (Makefile.am): Likewise.
9089         * modules/memmem (Makefile.am): Likewise.
9090         * modules/memmove (Makefile.am): Likewise.
9091         * modules/mempcpy (Makefile.am): Likewise.
9092         * modules/memrchr (Makefile.am): Likewise.
9093         * modules/memset (Makefile.am): Likewise.
9094         * modules/memxor (Makefile.am): Likewise.
9095         * modules/mkancesdirs (Makefile.am): Likewise.
9096         * modules/mkdir-p (Makefile.am): Likewise.
9097         * modules/mkdir (Makefile.am): Likewise.
9098         * modules/mkdtemp (Makefile.am): Likewise.
9099         * modules/mkstemp (Makefile.am): Likewise.
9100         * modules/mktime (Makefile.am): Likewise.
9101         * modules/modechange (Makefile.am): Likewise.
9102         * modules/mountlist (Makefile.am): Likewise.
9103         * modules/nanosleep (Makefile.am): Likewise.
9104         * modules/obstack (Makefile.am): Likewise.
9105         * modules/openat (Makefile.am): Likewise.
9106         * modules/pagealign_alloc (Makefile.am): Likewise.
9107         * modules/pathmax (Makefile.am): Likewise.
9108         * modules/physmem (Makefile.am): Likewise.
9109         * modules/poll (Makefile.am): Likewise.
9110         * modules/posixtm (Makefile.am): Likewise.
9111         * modules/posixver (Makefile.am): Likewise.
9112         * modules/putenv (Makefile.am): Likewise.
9113         * modules/quote (Makefile.am): Likewise.
9114         * modules/quotearg (Makefile.am): Likewise.
9115         * modules/raise (Makefile.am): Likewise.
9116         * modules/read-file (Makefile.am): Likewise.
9117         * modules/readline (Makefile.am): Likewise.
9118         * modules/readlink (Makefile.am): Likewise.
9119         * modules/readtokens (Makefile.am): Likewise.
9120         * modules/readutmp (Makefile.am): Likewise.
9121         * modules/realloc (Makefile.am): Likewise.
9122         * modules/regex (Makefile.am): Likewise.
9123         * modules/rename-dest-slash (Makefile.am): Likewise.
9124         * modules/rename (Makefile.am): Likewise.
9125         * modules/rijndael (Makefile.am): Likewise.
9126         * modules/rmdir (Makefile.am): Likewise.
9127         * modules/rpmatch (Makefile.am): Likewise.
9128         * modules/safe-read (Makefile.am): Likewise.
9129         * modules/safe-write (Makefile.am): Likewise.
9130         * modules/same-inode (Makefile.am): Likewise.
9131         * modules/same (Makefile.am): Likewise.
9132         * modules/save-cwd (Makefile.am): Likewise.
9133         * modules/savedir (Makefile.am): Likewise.
9134         * modules/setenv (Makefile.am): Likewise.
9135         * modules/settime (Makefile.am): Likewise.
9136         * modules/sha1 (Makefile.am): Likewise.
9137         * modules/sig2str (Makefile.am): Likewise.
9138         * modules/snprintf (Makefile.am): Likewise.
9139         * modules/stat-macros (Makefile.am): Likewise.
9140         * modules/stat-time (Makefile.am): Likewise.
9141         * modules/stdbool (Makefile.am): Likewise.
9142         * modules/stdint (Makefile.am): Likewise.
9143         * modules/stdlib-safer (Makefile.am): Likewise.
9144         * modules/stpcpy (Makefile.am): Likewise.
9145         * modules/stpncpy (Makefile.am): Likewise.
9146         * modules/strcase (Makefile.am): Likewise.
9147         * modules/strcasestr (Makefile.am): Likewise.
9148         * modules/strchrnul (Makefile.am): Likewise.
9149         * modules/strcspn (Makefile.am): Likewise.
9150         * modules/strdup (Makefile.am): Likewise.
9151         * modules/strerror (Makefile.am): Likewise.
9152         * modules/strftime (Makefile.am): Likewise.
9153         * modules/strndup (Makefile.am): Likewise.
9154         * modules/strnlen (Makefile.am): Likewise.
9155         * modules/strpbrk (Makefile.am): Likewise.
9156         * modules/strsep (Makefile.am): Likewise.
9157         * modules/strstr (Makefile.am): Likewise.
9158         * modules/strtod (Makefile.am): Likewise.
9159         * modules/strtoimax (Makefile.am): Likewise.
9160         * modules/strtok_r (Makefile.am): Likewise.
9161         * modules/strtol (Makefile.am): Likewise.
9162         * modules/strtoll (Makefile.am): Likewise.
9163         * modules/strtoul (Makefile.am): Likewise.
9164         * modules/strtoull (Makefile.am): Likewise.
9165         * modules/strtoumax (Makefile.am): Likewise.
9166         * modules/strverscmp (Makefile.am): Likewise.
9167         * modules/sys_socket (Makefile.am): Likewise.
9168         * modules/sys_stat (Makefile.am): Likewise.
9169         * modules/sysexits (Makefile.am): Likewise.
9170         * modules/time_r (Makefile.am): Likewise.
9171         * modules/timegm (Makefile.am): Likewise.
9172         * modules/timespec (Makefile.am): Likewise.
9173         * modules/tmpfile-safer (Makefile.am): Likewise.
9174         * modules/trim (Makefile.am): Likewise.
9175         * modules/unistd-safer (Makefile.am): Likewise.
9176         * modules/unlinkdir (Makefile.am): Likewise.
9177         * modules/unlocked-io (Makefile.am): Likewise.
9178         * modules/userspec (Makefile.am): Likewise.
9179         * modules/utime (Makefile.am): Likewise.
9180         * modules/utimecmp (Makefile.am): Likewise.
9181         * modules/utimens (Makefile.am): Likewise.
9182         * modules/vasnprintf (Makefile.am): Likewise.
9183         * modules/vasprintf (Makefile.am): Likewise.
9184         * modules/vsnprintf (Makefile.am): Likewise.
9185         * modules/xalloc (Makefile.am): Likewise.
9186         * modules/xgetcwd (Makefile.am): Likewise.
9187         * modules/xnanosleep (Makefile.am): Likewise.
9188         * modules/xreadlink (Makefile.am): Likewise.
9189         * modules/xstrtod (Makefile.am): Likewise.
9190         * modules/xstrtol (Makefile.am): Likewise.
9191         * modules/xstrtold (Makefile.am): Likewise.
9192         * modules/yesno (Makefile.am): Likewise.
9193         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
9194
9195 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9196
9197         * modules/error (Makefile.am): Distribute files through
9198         EXTRA_DIST, not lib_SOURCES.
9199
9200 2006-10-12  Eric Blake  <ebb9@byu.net>
9201
9202         * modules/error (Makefile.am): Distribute files in /lib.
9203         * modules/obstack (Makefile.am): Likewise.
9204
9205 2006-10-12  Bruno Haible  <bruno@clisp.org>
9206
9207         * modules/acl (Makefile.am): Distribute all files in lib/ through
9208         EXTRA_DIST.
9209         * modules/arcfour (Makefile.am): Likewise.
9210         * modules/arctwo (Makefile.am): Likewise.
9211         * modules/argmatch (Makefile.am): Likewise.
9212         * modules/argz (Makefile.am): Likewise.
9213         * modules/atexit (Makefile.am): Likewise.
9214         * modules/backupfile (Makefile.am): Likewise.
9215         * modules/c-strtod (Makefile.am): Likewise.
9216         * modules/c-strtold (Makefile.am): Likewise.
9217         * modules/calloc (Makefile.am): Likewise.
9218         * modules/canon-host (Makefile.am): Likewise.
9219         * modules/canonicalize (Makefile.am): Likewise.
9220         * modules/chdir-long (Makefile.am): Likewise.
9221         * modules/chdir-safer (Makefile.am): Likewise.
9222         * modules/check-version (Makefile.am): Likewise.
9223         * modules/chown (Makefile.am): Likewise.
9224         * modules/cloexec (Makefile.am): Likewise.
9225         * modules/close-stream (Makefile.am): Likewise.
9226         * modules/closeout (Makefile.am): Likewise.
9227         * modules/crc (Makefile.am): Likewise.
9228         * modules/cycle-check (Makefile.am): Likewise.
9229         * modules/des (Makefile.am): Likewise.
9230         * modules/dirfd (Makefile.am): Likewise.
9231         * modules/dirname (Makefile.am): Likewise.
9232         * modules/dup2 (Makefile.am): Likewise.
9233         * modules/euidaccess (Makefile.am): Likewise.
9234         * modules/exclude (Makefile.am): Likewise.
9235         * modules/exitfail (Makefile.am): Likewise.
9236         * modules/fcntl-safer (Makefile.am): Likewise.
9237         * modules/file-type (Makefile.am): Likewise.
9238         * modules/fileblocks (Makefile.am): Likewise.
9239         * modules/filemode (Makefile.am): Likewise.
9240         * modules/filenamecat (Makefile.am): Likewise.
9241         * modules/fnmatch (Makefile.am): Likewise.
9242         * modules/fopen-safer (Makefile.am): Likewise.
9243         * modules/fpending (Makefile.am): Likewise.
9244         * modules/fprintftime (Makefile.am): Likewise.
9245         * modules/free (Makefile.am): Likewise.
9246         * modules/fsusage (Makefile.am): Likewise.
9247         * modules/ftruncate (Makefile.am): Likewise.
9248         * modules/fts (Makefile.am): Likewise.
9249         * modules/gc (Makefile.am): Likewise.
9250         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9251         * modules/getaddrinfo (Makefile.am): Likewise.
9252         * modules/getcwd (Makefile.am): Likewise.
9253         * modules/getdelim (Makefile.am): Likewise.
9254         * modules/getdomainname (Makefile.am): Likewise.
9255         * modules/getgroups (Makefile.am): Likewise.
9256         * modules/gethostname (Makefile.am): Likewise.
9257         * modules/gethrxtime (Makefile.am): Likewise.
9258         * modules/getline (Makefile.am): Likewise.
9259         * modules/getloadavg (Makefile.am): Likewise.
9260         * modules/getlogin_r (Makefile.am): Likewise.
9261         * modules/getopt (Makefile.am): Likewise.
9262         * modules/getpass (Makefile.am): Likewise.
9263         * modules/getpass-gnu (Makefile.am): Likewise.
9264         * modules/getsubopt (Makefile.am): Likewise.
9265         * modules/gettime (Makefile.am): Likewise.
9266         * modules/gettimeofday (Makefile.am): Likewise.
9267         * modules/getugroups (Makefile.am): Likewise.
9268         * modules/getusershell (Makefile.am): Likewise.
9269         * modules/glob (Makefile.am): Likewise.
9270         * modules/group-member (Makefile.am): Likewise.
9271         * modules/hard-locale (Makefile.am): Likewise.
9272         * modules/hash (Makefile.am): Likewise.
9273         * modules/hmac-md5 (Makefile.am): Likewise.
9274         * modules/hmac-sha1 (Makefile.am): Likewise.
9275         * modules/human (Makefile.am): Likewise.
9276         * modules/idcache (Makefile.am): Likewise.
9277         * modules/imaxabs (Makefile.am): Likewise.
9278         * modules/imaxdiv (Makefile.am): Likewise.
9279         * modules/inet_ntop (Makefile.am): Likewise.
9280         * modules/inet_pton (Makefile.am): Likewise.
9281         * modules/inttostr (Makefile.am): Likewise.
9282         * modules/isapipe (Makefile.am): Likewise.
9283         * modules/lchown (Makefile.am): Likewise.
9284         * modules/long-options (Makefile.am): Likewise.
9285         * modules/lstat (Makefile.am): Likewise.
9286         * modules/malloc (Makefile.am): Likewise.
9287         * modules/mathl (Makefile.am): Likewise.
9288         * modules/mbchar (Makefile.am): Likewise.
9289         * modules/md2 (Makefile.am): Likewise.
9290         * modules/md4 (Makefile.am): Likewise.
9291         * modules/md5 (Makefile.am): Likewise.
9292         * modules/memcasecmp (Makefile.am): Likewise.
9293         * modules/memchr (Makefile.am): Likewise.
9294         * modules/memcmp (Makefile.am): Likewise.
9295         * modules/memcoll (Makefile.am): Likewise.
9296         * modules/memcpy (Makefile.am): Likewise.
9297         * modules/memmem (Makefile.am): Likewise.
9298         * modules/memmove (Makefile.am): Likewise.
9299         * modules/mempcpy (Makefile.am): Likewise.
9300         * modules/memrchr (Makefile.am): Likewise.
9301         * modules/memset (Makefile.am): Likewise.
9302         * modules/memxor (Makefile.am): Likewise.
9303         * modules/mkancesdirs (Makefile.am): Likewise.
9304         * modules/mkdir (Makefile.am): Likewise.
9305         * modules/mkdir-p (Makefile.am): Likewise.
9306         * modules/mkdtemp (Makefile.am): Likewise.
9307         * modules/mkstemp (Makefile.am): Likewise.
9308         * modules/mktime (Makefile.am): Likewise.
9309         * modules/modechange (Makefile.am): Likewise.
9310         * modules/mountlist (Makefile.am): Likewise.
9311         * modules/nanosleep (Makefile.am): Likewise.
9312         * modules/openat (Makefile.am): Likewise.
9313         * modules/pagealign_alloc (Makefile.am): Likewise.
9314         * modules/physmem (Makefile.am): Likewise.
9315         * modules/poll (Makefile.am): Likewise.
9316         * modules/posixtm (Makefile.am): Likewise.
9317         * modules/posixver (Makefile.am): Likewise.
9318         * modules/putenv (Makefile.am): Likewise.
9319         * modules/quote (Makefile.am): Likewise.
9320         * modules/quotearg (Makefile.am): Likewise.
9321         * modules/raise (Makefile.am): Likewise.
9322         * modules/read-file (Makefile.am): Likewise.
9323         * modules/readline (Makefile.am): Likewise.
9324         * modules/readlink (Makefile.am): Likewise.
9325         * modules/readtokens (Makefile.am): Likewise.
9326         * modules/readutmp (Makefile.am): Likewise.
9327         * modules/realloc (Makefile.am): Likewise.
9328         * modules/regex (Makefile.am): Likewise.
9329         * modules/rename (Makefile.am): Likewise.
9330         * modules/rename-dest-slash (Makefile.am): Likewise.
9331         * modules/rijndael (Makefile.am): Likewise.
9332         * modules/rmdir (Makefile.am): Likewise.
9333         * modules/rpmatch (Makefile.am): Likewise.
9334         * modules/safe-read (Makefile.am): Likewise.
9335         * modules/safe-write (Makefile.am): Likewise.
9336         * modules/same (Makefile.am): Likewise.
9337         * modules/save-cwd (Makefile.am): Likewise.
9338         * modules/savedir (Makefile.am): Likewise.
9339         * modules/setenv (Makefile.am): Likewise.
9340         * modules/settime (Makefile.am): Likewise.
9341         * modules/sha1 (Makefile.am): Likewise.
9342         * modules/sig2str (Makefile.am): Likewise.
9343         * modules/snprintf (Makefile.am): Likewise.
9344         * modules/stdlib-safer (Makefile.am): Likewise.
9345         * modules/stpcpy (Makefile.am): Likewise.
9346         * modules/stpncpy (Makefile.am): Likewise.
9347         * modules/strcase (Makefile.am): Likewise.
9348         * modules/strcasestr (Makefile.am): Likewise.
9349         * modules/strchrnul (Makefile.am): Likewise.
9350         * modules/strcspn (Makefile.am): Likewise.
9351         * modules/strdup (Makefile.am): Likewise.
9352         * modules/strerror (Makefile.am): Likewise.
9353         * modules/strftime (Makefile.am): Likewise.
9354         * modules/strndup (Makefile.am): Likewise.
9355         * modules/strnlen (Makefile.am): Likewise.
9356         * modules/strpbrk (Makefile.am): Likewise.
9357         * modules/strsep (Makefile.am): Likewise.
9358         * modules/strstr (Makefile.am): Likewise.
9359         * modules/strtod (Makefile.am): Likewise.
9360         * modules/strtoimax (Makefile.am): Likewise.
9361         * modules/strtok_r (Makefile.am): Likewise.
9362         * modules/strtol (Makefile.am): Likewise.
9363         * modules/strtoll (Makefile.am): Likewise.
9364         * modules/strtoul (Makefile.am): Likewise.
9365         * modules/strtoull (Makefile.am): Likewise.
9366         * modules/strtoumax (Makefile.am): Likewise.
9367         * modules/strverscmp (Makefile.am): Likewise.
9368         * modules/time_r (Makefile.am): Likewise.
9369         * modules/timegm (Makefile.am): Likewise.
9370         * modules/tmpfile-safer (Makefile.am): Likewise.
9371         * modules/unistd-safer (Makefile.am): Likewise.
9372         * modules/unlinkdir (Makefile.am): Likewise.
9373         * modules/userspec (Makefile.am): Likewise.
9374         * modules/utime (Makefile.am): Likewise.
9375         * modules/utimecmp (Makefile.am): Likewise.
9376         * modules/utimens (Makefile.am): Likewise.
9377         * modules/vasnprintf (Makefile.am): Likewise.
9378         * modules/vasprintf (Makefile.am): Likewise.
9379         * modules/vsnprintf (Makefile.am): Likewise.
9380         * modules/xalloc (Makefile.am): Likewise.
9381         * modules/xgetcwd (Makefile.am): Likewise.
9382         * modules/xnanosleep (Makefile.am): Likewise.
9383         * modules/xreadlink (Makefile.am): Likewise.
9384         * modules/xstrtod (Makefile.am): Likewise.
9385         * modules/xstrtol (Makefile.am): Likewise.
9386         * modules/xstrtold (Makefile.am): Likewise.
9387         * modules/yesno (Makefile.am): Likewise.
9388
9389 2006-10-12  Jim Meyering  <jim@meyering.net>
9390
9391         * m4/getloadavg.m4: Revert the change below.
9392
9393         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
9394         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
9395         fail with a symlink, which is what coreutils' ./bootstrap now
9396         creates by default.
9397
9398 2006-10-12  Bruno Haible  <bruno@clisp.org>
9399
9400         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
9401         mingw.
9402         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
9403         MSVC and mingw explicitly.
9404
9405 2006-10-11  Simon Josefsson  <jas@extundo.com>
9406             Bruno Haible  <bruno@clisp.org>
9407
9408         Add support for multiple gnulib-tool invocations in the scope of a
9409         single configure.ac file.
9410         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
9411         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
9412         with the same contents as the _LIBADD variable.
9413         (func_emit_initmacro_start, func_emit_initmacro_end,
9414         func_emit_initmacro_done): New functions.
9415         (func_import, func_create_testdir): Invoke them. Allow the identifiers
9416         gl_LIBOBJS and gl_LTLIBOBJS.
9417
9418 2006-10-11  Bruno Haible  <bruno@clisp.org>
9419
9420         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
9421         (func_create_testdir): Don't create po/Makefile.am, don't invoke
9422         autoreconf. Instead, invoke autopoint explicitly but move back the
9423         *.m4 files from gnulib.
9424
9425 2006-10-11  Bruno Haible  <bruno@clisp.org>
9426
9427         * gnulib-tool (func_usage): Make module names after --create-testdir
9428         optional.
9429         (func_create_testdir): If no module was specified, use nearly all
9430         modules.
9431
9432 2006-10-12  Jim Meyering  <jim@meyering.net>
9433
9434         Big performance improvement for fts-based tools that use FTS_NOSTAT.
9435         Avoid spurious inode-mismatch problems on non-POSIX file systems.
9436         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
9437         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
9438         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
9439         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
9440         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
9441         (fts_set_stat_required): New function.
9442         (fts_open): Defer the calls to fts_stat, if possible or requested.
9443         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
9444         into fts_stat itself.
9445         (fts_read): Perform any required (deferred) fts_stat call.
9446         (fts_build): Likewise, for the directory we're about to open and read.
9447         In the readdir loop, carefully decide whether each entry will require
9448         an eventual call to fts_stat, using dirent.d_type info if available.
9449         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
9450         a command line argument into this function.  Update all callers.
9451         Map a return value of FTS_DOT to FTS_D for a command line argument.
9452         * modules/fts (Depends-on): Add d-type.  Alphabetize.
9453         Thanks to Miklos Szeredi for his tenacity and for the initial
9454         bug report about "find" failing on a FUSE-based file system.
9455
9456         * lib/fts.c (fts_open): Use consistent indentation.
9457
9458 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9459
9460         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
9461         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
9462         reported by Jim Meyering.  All uses of cache variables renamed
9463         to match Autoconf's.
9464         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
9465         the other one.
9466
9467         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
9468         Fix misspelling in diagnostic.
9469
9470 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9471
9472         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
9473         defined.  Problem reported by Matthew Woehlke.
9474
9475         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
9476         Add support for Tandem NonStop R series.
9477         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
9478         Use new macro.
9479
9480         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
9481         (has_trailing_slash): Omit size arg; all callers changed.
9482         Omit 'inline', since it doesn't help performance and we'd
9483         need to configure it.
9484         Don't count //, ///, etc. as having a trailing slash.
9485         As a side effect, this removes a C99ism reported by Matthew Woehlke.
9486         (rpl_rename_dest_slash): On failure, use rename's errno rather
9487         than (in some cases) an incorrect or junk errno.
9488         Simplify code by removing need to compute length; this does
9489         cause it to make two passes instead of one over the file name,
9490         but it's worth it.
9491
9492         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
9493         change, since Autoconf's version may no longer be appropriate now
9494         that we are using CVS Autoconf's version.  Add support for Tandem.
9495
9496 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9497             Bruno Haible  <bruno@clisp.org>
9498
9499         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
9500         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
9501         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
9502         gl_AC_TYPE_LONG_LONG.
9503
9504         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
9505         instead of HAVE_LONG_LONG.
9506         * lib/printf-args.c (printf_fetchargs): Likewise.
9507         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
9508         * lib/vasnprintf.c (VASNPRINTF): Likewise.
9509         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
9510         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
9511         gl_AC_TYPE_LONG_LONG.
9512
9513 2006-10-11  Bruno Haible  <bruno@clisp.org>
9514
9515         * m4/longlong.m4: Add comments.
9516         * m4/ulonglong.m4: Likewise.
9517
9518 2006-10-10  Bruno Haible  <bruno@clisp.org>
9519
9520         Make it possible to #define stpcpy, strdup to aliases.
9521         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
9522         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
9523
9524 2006-10-10  Bruno Haible  <bruno@clisp.org>
9525
9526         Make it possible to #define gcd to an alias.
9527         * lib/gcd.c: Include config.h.
9528
9529 2006-10-10  Bruno Haible  <bruno@clisp.org>
9530
9531         Make it possible to #define c_isascii to an alias.
9532         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
9533         defined. Undefine the macros before defining them, to avoid gcc
9534         warnings.
9535         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
9536         define NO_C_CTYPE_MACROS early.
9537
9538 2006-10-10  Bruno Haible  <bruno@clisp.org>
9539
9540         Make it possible to #define set_program_name to an alias.
9541         * lib/progname.c: Don't undefine set_program_name; instead, undefine
9542         ENABLE_RELOCATABLE early.
9543
9544 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9545
9546         Port to Tandem NSK OSS, which has 64-bit signed int but at most
9547         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
9548         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
9549         More generally, don't assume that 64-bit signed int is available
9550         if unsigned int is, and vice versa.
9551         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
9552         unsigned symbols, not on their signed counterparts.
9553         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
9554         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
9555         (UINT64_C, UINTMAX_C):
9556         Likewise.
9557         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
9558         unsigned counterparts.
9559         (Have_long_long, Unsigned): New macros.
9560         (Int): Renamed from INT.
9561         (strtoimax): Use the new macros.
9562         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
9563         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
9564         * modules/inttypes (inttypes.h): Substitute
9565         HAVE_UNSIGNED_LONG_LONG_INT.
9566         * modules/stdint (stdint.h): Likewise.
9567         (Files): Add m4/ulonglong.m4.
9568
9569 2006-10-10  Bruno Haible  <bruno@clisp.org>
9570
9571         Fix a gcc -Wshadow warning.
9572         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
9573         to 'bucket'.
9574         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
9575         gl_linked_indexof_from_to): Likewise.
9576         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
9577         Likewise.
9578         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
9579         Likewise.
9580         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
9581         Reported by Eric Blake.
9582
9583 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
9584
9585         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
9586         for NetBSD.  Problem reported by Bruno Haible.
9587
9588 2006-10-09  Jim Meyering  <jim@meyering.net>
9589
9590         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
9591         Patch from Bruno Haible.
9592
9593 2006-10-09  Jim Meyering  <jim@meyering.net>
9594
9595         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
9596         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
9597         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
9598
9599 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
9600
9601         Don't include <config.h> twice; this doesn't work in some cases,
9602         e.g., when config.h has "#define intmax_t long long int" and
9603         we include <config.h>, <inttypes.h>, <config.h> in that order.
9604         Problem reported by Matthew Woehlke in:
9605         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
9606         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
9607         * lib/fts-cycle.c: Don't include config.h.
9608         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
9609         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
9610         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
9611         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
9612         inttypes.h.
9613         * lib/xstrtoumax.c: Likewise.
9614         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
9615         __strtol and the like, so that this module is more like its siblings.
9616         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
9617         Remove; no longer needed now that we assume gnulib inttypes.h.
9618
9619 2006-10-08  Bruno Haible  <bruno@clisp.org>
9620
9621         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
9622         option.
9623
9624 2006-10-07  Jim Meyering  <jim@meyering.net>
9625
9626         * modules/inttypes (inttypes.h): Revert what seems to have been
9627         an inadvertent part of today's change: use "|", not "/" in the
9628         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
9629
9630 2006-10-07  Bruno Haible  <bruno@clisp.org>
9631
9632         * modules/sublist: New file.
9633
9634 2006-10-07  Bruno Haible  <bruno@clisp.org>
9635
9636         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
9637         * modules/argz (argz.h): Likewise.
9638         * modules/arpa_inet (arpa/inet.h): Likewise.
9639         * modules/byteswap (byteswap.h): Likewise.
9640         * modules/configmake (configmake.h): Likewise.
9641         * modules/fcntl (fcntl.h): Likewise.
9642         * modules/fnmatch (fnmatch.h): Likewise.
9643         * modules/getopt (getopt.h): Likewise.
9644         * modules/glob (glob.h): Likewise.
9645         * modules/inttypes (inttypes.h): Likewise.
9646         * modules/netinet_in (netinet/in.h): Likewise.
9647         * modules/poll (poll.h): Likewise.
9648         * modules/stdbool (stdbool.h): Likewise.
9649         * modules/stdint (stdint.h): Likewise.
9650         * modules/sys_select (sys/select.h): Likewise.
9651         * modules/sys_socket (sys/socket.h): Likewise.
9652         * modules/sys_stat (sys/stat.h): Likewise.
9653         * modules/sysexits (sysexits.h): Likewise.
9654         * modules/unistd (unistd.h): Likewise.
9655         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9656         Add a "DO NOT EDIT" comment to the generated file.
9657         (func_import): Likewise for gnulib-comp.m4.
9658
9659 2006-10-07  Bruno Haible  <bruno@clisp.org>
9660
9661         * lib/gl_sublist.h: New file.
9662         * lib/gl_sublist.c: New file.
9663
9664 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9665
9666         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
9667         name (relative to the original working directory) and the file
9668         name component (relative to the temporary working directory).  All
9669         callers changed.
9670         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
9671         * lib/mkdir-p.c (make_dir_parents): Likewise.
9672         * lib/mkdir-p.h (make_dir_parents): Likewise.
9673
9674 2006-10-06  Eric Blake  <ebb9@byu.net>
9675
9676         Define several macros for use by the clean-temp module.
9677         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
9678         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
9679         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
9680
9681         * lib/clean-temp.h (close_stream_temp): New declaration.
9682         * lib/clean-temp.c (includes): Pull in headers according to what
9683         other modules are in use.
9684         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
9685
9686 2006-10-06  Bruno Haible  <bruno@clisp.org>
9687
9688         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
9689         instead of fopen, fwriteerror.
9690
9691 2006-10-06  Bruno Haible  <bruno@clisp.org>
9692
9693         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
9694         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
9695         int.
9696         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
9697         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
9698         Return an error indicator.
9699         Suggested by Eric Blake.
9700
9701 2006-10-06  Bruno Haible  <bruno@clisp.org>
9702
9703         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
9704         Reported by Eric Blake.
9705
9706 2006-10-06  Bruno Haible  <bruno@clisp.org>
9707
9708         * modules/closeout (Description): Mention stderr too.
9709
9710 2006-10-06  Bruno Haible  <bruno@clisp.org>
9711         and Paul Eggert  <eggert@cs.ucla.edu>
9712
9713         * lib/closeout.c (close_stdout): Also close stderr.
9714         * lib/closeout.h: Update comment.
9715
9716 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9717
9718         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
9719         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
9720         * lib/dirchownmod.c: Include lchown.h.
9721         * lib/lchown.c: Don't include files that lchown.h now includes.
9722         Don't declare chown, since lchown.h now does that.
9723         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
9724         (lchown): Define to rpl_chown if lchown is declared but
9725         does not exist.  Declare using a prototype if lchown is not
9726         declared.  Add a copyright notice.
9727         * lib/mkstemp.h: Include <unistd.h>.
9728         * lib/openat.c: Include lchown.h.
9729
9730         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
9731         we now test for that separately.
9732         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
9733         rather than O_NOFOLLOW, when testing whether it's possible to
9734         avoid a race condition reliably.
9735         * lib/savewd.c (savewd_chdir): Likewise.
9736
9737         Remove macros that are no longer needed now that stdint.h is
9738         reliable.
9739         * lib/fsusage.c (UINTMAX_MAX): Remove.
9740         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
9741         * lib/utimecmp.c (SIZE_MAX): Remove.
9742
9743         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
9744
9745         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
9746         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
9747         O_NOATIME works.
9748
9749 2006-10-05  Bruno Haible  <bruno@clisp.org>
9750
9751         * lib/gl_list.h (gl_sortedlist_search_from_to,
9752         gl_sortedlist_indexof_from_to): New declarations.
9753         (gl_list_implementation): New fields sortedlist_search_from_to,
9754         sortedlist_indexof_from_to.
9755         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
9756         inline functions.
9757         * lib/gl_list.c (gl_sortedlist_search_from_to,
9758         gl_sortedlist_indexof_from_to): New functions.
9759         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
9760         function.
9761         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
9762         (gl_array_sortedlist_search_from_to): New function.
9763         (gl_array_list_implementation): Update.
9764         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
9765         function.
9766         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
9767         (gl_carray_sortedlist_search_from_to): New function.
9768         (gl_carray_list_implementation): Update.
9769         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
9770         gl_linked_sortedlist_indexof_from_to): New functions.
9771         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
9772         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
9773         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
9774         gl_tree_sortedlist_indexof_from_to): New functions.
9775         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
9776         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
9777         Update.
9778         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
9779         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
9780         Update.
9781
9782 2006-10-05  Bruno Haible  <bruno@clisp.org>
9783
9784         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
9785         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
9786         (struct gl_list_implementation): Add fields search_from_to,
9787         indexof_from_to. Remove fields search, indexof.
9788         (gl_list_search): Use the search_from_to method.
9789         (gl_list_search_from, gl_list_search_from_to): New functions.
9790         (gl_list_indexof): Use the indexof_from_to method.
9791         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
9792         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
9793         (gl_list_search_from, gl_list_search_from_to): New functions.
9794         (gl_list_indexof): Use the indexof_from_to method.
9795         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
9796         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
9797         gl_array_indexof. Add start_index, end_index arguments.
9798         (gl_array_search_from_to): Renamed from gl_array_search. Add
9799         start_index, end_index arguments.
9800         (gl_array_remove, gl_array_list_implementation): Update.
9801         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
9802         gl_carray_indexof. Add start_index, end_index arguments.
9803         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
9804         start_index, end_index arguments.
9805         (gl_carray_remove, gl_carray_list_implementation): Update.
9806         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
9807         gl_linked_search. Add start_index, end_index arguments.
9808         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
9809         start_index, end_index arguments.
9810         (gl_linked_remove): Update.
9811         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
9812         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
9813         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
9814         field to 'size_t'.
9815         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
9816         gl_tree_search. Add start_index, end_index arguments.
9817         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
9818         start_index, end_index arguments.
9819         (gl_tree_remove): Update.
9820         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
9821         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
9822         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
9823         function.
9824         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
9825         gl_tree_search. Add start_index, end_index arguments.
9826         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
9827         start_index, end_index arguments.
9828         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
9829         Update.
9830         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
9831
9832 2006-10-05  Bruno Haible  <bruno@clisp.org>
9833
9834         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
9835
9836         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
9837         fwriteerror_temp): New declarations.
9838         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
9839         (descriptors): New variable.
9840         (cleanup): First, close the descriptors.
9841         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
9842         fclose_temp, fwriteerror_temp): New functions.
9843
9844 2006-10-04  Jim Meyering  <jim@meyering.net>
9845
9846         * lib/fts.c (fts_open): Tiny comment change.
9847
9848 2006-10-04  Bruno Haible  <bruno@clisp.org>
9849
9850         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
9851         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
9852         gl_LOCK_BODY.
9853         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
9854         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
9855         gl_LOCK_EARLY_BODY.
9856         (gl_LOCK): Require gl_LOCK_BODY.
9857
9858 2006-10-04  Bruno Haible  <bruno@clisp.org>
9859
9860         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
9861         (gl_oset_search_atleast): New declaration.
9862         (struct gl_oset_implementation): Add field 'search_atleast'.
9863         (gl_oset_search_atleast): New inline function.
9864         * lib/gl_oset.c (gl_oset_search_atleast): New function.
9865         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
9866         (gl_array_oset_implementation): Update.
9867         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
9868         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
9869         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
9870
9871 2006-10-04  Bruno Haible  <bruno@clisp.org>
9872
9873         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
9874
9875 2006-10-03  Bruno Haible  <bruno@clisp.org>
9876
9877         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
9878         from gl_avltreehash_list_implementation.
9879
9880 2006-10-03  Bruno Haible  <bruno@clisp.org>
9881
9882         * lib/gl_oset.c (gl_oset_add): Fix return type.
9883
9884 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
9885
9886         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
9887
9888 2006-10-02  Eric Blake  <ebb9@byu.net>
9889
9890         * modules/strnlen (Depends-on): Add extensions.
9891
9892 2006-10-02  Eric Blake  <ebb9@byu.net>
9893
9894         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
9895         definition in 2.60+.
9896
9897 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
9898
9899         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
9900         checks.
9901
9902 2006-10-02  Bruno Haible  <bruno@clisp.org>
9903
9904         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
9905         to the AUTOMAKE_OPTIONS.
9906         Reported by Jim Meyering.
9907
9908 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9909
9910         Work around bug in Solaris 10 /proc file system:
9911         /proc/self/fd/NNN/.. isn't the parent directory of
9912         the directory whose file descriptor is NNN.  This needs to
9913         be worked around at run time, not compile time, since a
9914         program might be built on Solaris 8, where things work, and
9915         run on Solaris 10.
9916         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
9917         to use the following interface instead:
9918         (OPENAT_BUFFER_SIZE): New macro.
9919         (openat_proc_name): New function.
9920         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
9921         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
9922         Likewise.
9923         * lib/openat-proc.c: New file.
9924         * modules/openat (Files): Add lib/openat-proc.c.
9925         (Depends-on): Add same-inode, stdbool.
9926         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
9927
9928 2006-09-29  Bruno Haible  <bruno@clisp.org>
9929
9930         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
9931         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
9932         argument. Set stdout_closed before testing for ferror, not after.
9933         (fwriteerror, fwriteerror_no_ebadf): New functions.
9934
9935 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9936
9937         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
9938
9939 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
9940
9941         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
9942         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
9943
9944 2006-09-28  Jim Meyering  <jim@meyering.net>
9945
9946         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
9947         Include <unistd.h>.
9948
9949 2006-09-28  Bruno Haible  <bruno@clisp.org>
9950
9951         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
9952         * modules/linkedhash-list (Depends-on): Likewise.
9953         * modules/rbtreehash-list (Depends-on): Likewise.
9954
9955 2006-09-28  Bruno Haible  <bruno@clisp.org>
9956
9957         * lib/strndup.h: Simplify the redefinition of strndup.
9958         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
9959         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
9960
9961 2006-09-28  Bruno Haible  <bruno@clisp.org>
9962
9963         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
9964         * lib/gl_linkedhash_list.c: Likewise.
9965         * lib/gl_rbtreehash_list.c: Likewise.
9966
9967 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9968
9969         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
9970         getaddrinfo.
9971
9972         * lib/__fpending.h: Don't include <stdio_ext.h> unless
9973         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
9974         it causes <stdio_ext.h> to cause a compile-time error.
9975         Problem reported by Nelson H. F. Beebe.
9976         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
9977         of HAVE_DECL___PENDING.
9978
9979         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
9980         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
9981         declaration.
9982
9983 2006-09-27  Jim Meyering  <jim@meyering.net>
9984
9985         This file could end up with a definition for a function
9986         named __strndup, rather than rpl_strndup on a system with
9987         incomplete weak_alias support.
9988         * lib/strndup.c (strndup): Rename from __strndup.
9989         Remove #defines that used to map __strndup to strndup.
9990         Don't use K&R prototypes.
9991         Remove LIBC-related code, since this file is not sync'd with glibc.
9992         * lib/strndup.h: Revamp, accordingly.
9993         * m4/strndup.m4: Modernize.
9994
9995 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
9996
9997         * modules/savewd (Depends-on): Add 'raise'.
9998         * lib/savewd.c: Include <signal.h>, for 'raise'.
9999
10000 2006-09-26  Jim Meyering  <jim@meyering.net>
10001
10002         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
10003         when we detect Darwin 8.7.0's acl_get_file bug.
10004         Rearrange to perform the new (below) run-test while $LIBS
10005         contains any acl-related library.  Set USE_ACL at the end.
10006         (gl_ACL_GET_FILE): New function.
10007
10008 2006-09-26  Eric Blake  <ebb9@byu.net>
10009
10010         * lib/verror.c: Include <config.h> unconditionally.
10011
10012 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
10013
10014         * modules/clock-time (Maintainer): Add self.
10015         * modules/getlogin_r (Depends-on): Add extensions.
10016
10017 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10018
10019         * modules/clock-time: New module.
10020         * modules/nanosleep (Depends-on): Add clock-time.
10021         * modules/gethrxtime (Depends-on): Likewise.
10022         * modules/gettime (Depends-on): Likewise.
10023         * modules/settime (Depends-on): Likewise.
10024
10025         * modules/fts-lgpl: Depend on openat.
10026         * modules/mkancesdirs: Depend on savewd.
10027         * modules/mkdir-p: Likewise.
10028
10029 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10030
10031         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
10032
10033         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
10034         `gl_have_arbitrary_file_name_length_limit' to
10035         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
10036         actually works between configure runs.
10037
10038 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10039             Bruno Haible  <bruno@clisp.org>
10040
10041         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
10042
10043 2006-09-25  Jim Meyering  <jim@meyering.net>
10044
10045         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
10046         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
10047
10048 2006-09-25  Eric Blake  <ebb9@byu.net>
10049
10050         * gnulib-tool (func_import, func_create_testdir): Fix typos in
10051         exec's in 2006-09-18 patch when shuffling fds.
10052
10053 2006-09-25  Bruno Haible  <bruno@clisp.org>
10054
10055         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
10056         Reported by Jim Meyering.
10057
10058 2006-09-24  Jim Meyering  <jim@meyering.net>
10059
10060         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
10061         compare a pointer against a literal "0".  That caused failures with
10062         at least HP-UX's hpcc.
10063
10064 2006-09-22  Simon Josefsson  <jas@extundo.com>
10065
10066         * modules/gc-sha1:
10067         * modules/gc-md4:
10068         * modules/gc-hmac-sha1:
10069         * modules/gc-hmac-md5:
10070         * modules/gc-des:
10071         * modules/gc-arcfour: Distribute more files.
10072
10073 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10074
10075         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
10076         (gl_linked_iterator_from_to): Initialize struct completely.
10077         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
10078         (gl_tree_iterator_from_to): Likewise
10079         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
10080         * lib/gl_array_list.c [lint] (gl_array_iterator)
10081         (gl_array_iterator_from_to): Likewise.
10082         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
10083         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
10084         (gl_carray_iterator_from_to): Likewise.
10085
10086         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
10087         * lib/md4.c (md4_process_block): Remove unused variable.
10088         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
10089         parentheses for clarity.
10090
10091 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10092
10093         * modules/bison-i18n (Depends-on): Add gettext.
10094
10095 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10096
10097         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
10098         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
10099         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
10100         also add missing comma that caused broken test.
10101         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
10102         stdlib.h, for `abort'.
10103         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
10104         variables.
10105         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
10106         include unistd.h if present, for `rmdir'.
10107         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
10108         variables.
10109         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
10110         in the process include standard headers for prototypes.
10111         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
10112         gets declared on GNU/Linux.
10113         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
10114         unistd.h, for `rmdir'.
10115         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
10116
10117         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
10118         always true.
10119         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
10120
10121         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
10122
10123 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10124
10125         * gnulib-tool (func_version): Create output all at once.  This
10126         may help avoid triggering unnecessary SIGPIPEs, and at any
10127         rate it doesn't hurt.
10128
10129 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10130             Bruno Haible  <bruno@clisp.org>
10131
10132         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
10133         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
10134         * m4/signed.m4 (bh_C_SIGNED): Likewise.
10135
10136         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
10137         (gl_FUNC_VASPRINTF): Invoke it.
10138
10139 2006-09-22  Bruno Haible  <bruno@clisp.org>
10140
10141         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
10142         getloadavg.c as first argument.
10143
10144 2006-09-22  Bruno Haible  <bruno@clisp.org>
10145
10146         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
10147         at the beginning of the gl_INIT macro.
10148         * modules/getloadavg (configure.ac): Pass $gl_source_base to
10149         gl_GETLOADAVG.
10150
10151 2006-09-22  Bruno Haible  <bruno@clisp.org>
10152
10153         * gnulib-tool (func_create_megatestdir): Don't include the config-h
10154         module.
10155         Suggested by Ralf Wildenhues.
10156
10157 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
10158
10159         Import this patch from libc:
10160
10161         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
10162
10163         * lib/regex_internal.c (re_string_reconstruct): Handle
10164         offset < pstr->valid_raw_len && pstr->offsets_needed case.
10165         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
10166         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
10167         re_string_context_at.
10168
10169         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
10170         now requires it.
10171         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
10172         gl_REGEX now does it for us.
10173         (gl_REGEX): Add test taken from
10174         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
10175
10176         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
10177         Check that large offsets work.  Modernize Autoconf usages.
10178         Prefer "yes" to mean a good thing rather than a bad.
10179         Don't put "#define mkstemp" in config.h, as this might interfere
10180         with standard system headers that "#define mkstemp mkstemp64".
10181
10182         * modules/mkstemp (Depends-on): Add extensions, so that
10183         mkstemp is visible on some platforms.
10184         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
10185         (Include): Change to "mkstemp.h" from <stdlib.h>.
10186         (Files): Add mkstemp.h.
10187
10188         * lib/mkstemp.h: New file, since some standard headers
10189         #define mkstemp.
10190         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
10191         Include "mkstemp.h".
10192         Make the _LIBC code resemble glibc original more,
10193         e.g., use K&R style.
10194         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
10195         (mkstemp): Remove, since mkstemp.h does this for us.
10196         * lib/stdlib--.h: Include mkstemp.h.
10197
10198         Import this patch from libc:
10199
10200         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10201
10202         * lib/tempname.c (__gen_tempname): Change attempts_min
10203         into a macro.  Use preprocessor to decide how to initialize
10204         attempts [Coverity CID 67].
10205
10206 2006-09-20  Bruno Haible  <bruno@clisp.org>
10207
10208         * lib/mkdtemp.c: Import from libc.
10209         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10210                 * sysdeps/posix/tempname.c (__gen_tempname): Change
10211                 attempts_min into a macro.  Use preprocessor to decide how to
10212                 initialize attempts [Coverity CID 67].
10213         2001-11-27  Paul Eggert  <eggert@twinsun.com>
10214                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
10215                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
10216
10217 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10218
10219         * gnulib-tool (func_exit): New function, to allow to pass the
10220         exit status portably through the trap.  Use everywhere.
10221         (--help, --version): Signal a write error.
10222         (trap): catch SIGPIPE, for write errors.
10223         Exit at the end of the trap, with the correct exit status.
10224
10225 2006-09-19  Karl Berry  <karl@gnu.org>
10226
10227         * doc/gnulib.texi: note about the license texinfo files.
10228
10229 2006-09-19  Eric Blake  <ebb9@byu.net>
10230
10231         * gnulib-tool: Avoid space-tab.
10232
10233 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10234
10235         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
10236         that prevented coreutils 6.1 from building.  Problem reported
10237         by Petter Reinholdtsen.
10238
10239 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10240
10241         * gnulib-tool (avoidlist): Fix typo that broke options like
10242         --avoid=lock that are used by coreutils bootstrap.
10243
10244 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
10245
10246         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
10247         more systematically.
10248
10249 2006-09-18  Jim Meyering  <jim@meyering.net>
10250
10251         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
10252
10253 2006-09-18  Bruno Haible  <bruno@clisp.org>
10254
10255         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
10256
10257 2006-09-18  Bruno Haible  <bruno@clisp.org>
10258
10259         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
10260         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
10261         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
10262         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
10263         * m4/gettext.m4: Require autoconf >= 2.52.
10264         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
10265         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
10266         of gl_cv_header_inttypes_h.
10267
10268 2006-09-18  Bruno Haible  <bruno@clisp.org>
10269
10270         * lib/javaversion.c: Include configmake.h.
10271
10272 2006-09-18  Bruno Haible  <bruno@clisp.org>
10273
10274         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
10275         avoid that the while loops be executed in a subshell.
10276
10277 2006-09-18  Bruno Haible  <bruno@clisp.org>
10278
10279         * MODULES.html.sh (func_module): Break long lines.
10280         Suggested by Bruce Korb <bkorb@gnu.org>.
10281
10282 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10283
10284         Speed up by a factor of 1.12.
10285         * gnulib-tool (nl): New variable.
10286         (func_import): Rewrite include directive extraction to only read each
10287         directive once.
10288
10289 2006-09-17  Bruno Haible  <bruno@clisp.org>
10290
10291         * modules/javaversion (Makefile.am): Remove DEFS setting.
10292         (Depends-on): Add configmake, for PKGDATADIR definition.
10293
10294 2006-09-17  Bruno Haible  <bruno@clisp.org>
10295
10296         * gnulib-tool (func_create_testdir): Rewrite all files at once.
10297
10298 2006-09-17  Bruno Haible  <bruno@clisp.org>
10299
10300         * gnulib-tool (func_append): New function, stolen from libtool.m4.
10301         (func_modules_transitive_closure, func_modules_add_dummy,
10302         func_modules_to_filelist, func_import, func_create_testdir,
10303         func_create_megatestdir, ...): Use it wherever possible.
10304         Suggested by Ralf Wildenhues.
10305
10306 2006-09-16  Karl Berry  <karl@gnu.org>
10307
10308         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
10309         to avoid sectioning errors.
10310         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
10311         [ifinfo]: blank line after @center-ed titles.
10312         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
10313         Spell FSF address consistently with others.
10314         (These changes approved by rms.)
10315
10316 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10317
10318         Speed up by a factor of 1.61.
10319         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
10320         already checked module names again.
10321
10322 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10323
10324         Speed up by a factor of 1.13.
10325         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
10326         for new_files, and the input to func_add_or_update.
10327
10328 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10329
10330         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
10331         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
10332
10333 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10334
10335         * modules/mkancesdirs (Depends-on): Add fcntl.
10336         * modules/savewd: New file.
10337         * MODULES.html.sh (File system functions): Add savewd.
10338
10339         * modules/configmake (Makefile.am): Add support for the
10340         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
10341
10342 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10343
10344         * m4/savewd.m4: New file.
10345
10346 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10347
10348         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
10349         (dirchownmod): New arg FD.  All callers changed.
10350         Use FD rather than opening the directory ourself, as opening is
10351         now the caller's responsibility.
10352         * lib/dirchownmod.h: Likewise.
10353         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
10354         hosts that require <sys/types.h> before <sys/stat.h>.  Include
10355         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
10356         (test_dir): Remove.
10357         (mkancesdirs): Return length of prefix of FILE that has already
10358         been made, or -2 if there is a child doing the work.  Redo
10359         algorithm so that it is O(N) rather than O(N**2).  Optimize away
10360         ".", and treat ".." specially since it might stray back into
10361         already-created areas.  Use a subprocess if necessary.  New arg
10362         WD; all users changed.  MAKE_DIR function should now return 1
10363         if it creates a directory that is not readable.  Return -2 if
10364         a child process is spun off.
10365         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
10366         Adjust signature to match code.
10367         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
10368         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
10369         all users changed.
10370         * lib/savewd.c, lib/savewd.h: New files.
10371
10372 2006-09-15  Jim Meyering  <jim@meyering.net>
10373
10374         * modules/rename-dest-slash: New module.
10375         * MODULES.html.sh (posix_compat): Add it here.
10376
10377         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
10378
10379 2006-09-15  Jim Meyering  <jim@meyering.net>
10380
10381         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
10382         file.
10383
10384         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
10385
10386 2006-09-15  Jim Meyering  <jim@meyering.net>
10387
10388         * lib/rename-dest-slash.c (has_trailing_slash): Use
10389         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
10390         (rpl_rename_dest_slash): Perform the cheaper trailing slash
10391         test before testing whether SRC is a directory.
10392         Suggestions from Bruno Haible.
10393
10394         Avoid a warning about an unused variable.
10395         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
10396         into the #ifdef block where it's used.
10397
10398         * lib/rename-dest-slash.c: New file.
10399
10400 2006-09-14  Bruno Haible  <bruno@clisp.org>
10401
10402         * lib/allocsa.c: Include <config.h> unconditionally.
10403         * lib/asnprintf.c: Likewise.
10404         * lib/asprintf.c: Likewise.
10405         * lib/c-strcasecmp.c: Likewise.
10406         * lib/c-strcasestr.c: Likewise.
10407         * lib/c-strncasecmp.c: Likewise.
10408         * lib/c-strstr.c: Likewise.
10409         * lib/classpath.c: Likewise.
10410         * lib/clean-temp.c: Likewise.
10411         * lib/concatpath.c: Likewise.
10412         * lib/copy-file.c: Likewise.
10413         * lib/csharpcomp.c: Likewise.
10414         * lib/csharpexec.c: Likewise.
10415         * lib/execute.c: Likewise.
10416         * lib/fatal-signal.c: Likewise.
10417         * lib/findprog.c: Likewise.
10418         * lib/fwriteerror.c: Likewise.
10419         * lib/gl_array_list.c: Likewise.
10420         * lib/gl_array_oset.c: Likewise.
10421         * lib/gl_avltree_list.c: Likewise.
10422         * lib/gl_avltree_oset.c: Likewise.
10423         * lib/gl_avltreehash_list.c: Likewise.
10424         * lib/gl_carray_list.c: Likewise.
10425         * lib/gl_linked_list.c: Likewise.
10426         * lib/gl_linkedhash_list.c: Likewise.
10427         * lib/gl_list.c: Likewise.
10428         * lib/gl_oset.c: Likewise.
10429         * lib/gl_rbtree_list.c: Likewise.
10430         * lib/gl_rbtree_oset.c: Likewise.
10431         * lib/gl_rbtreehash_list.c: Likewise.
10432         * lib/imaxabs.c: Likewise.
10433         * lib/imaxdiv.c: Likewise.
10434         * lib/javacomp.c: Likewise.
10435         * lib/javaexec.c: Likewise.
10436         * lib/javaversion.c: Likewise.
10437         * lib/linebreak.c: Likewise.
10438         * lib/localcharset.c: Likewise.
10439         * lib/lock.c: Likewise.
10440         * lib/mbchar.c: Likewise.
10441         * lib/mbswidth.c: Likewise.
10442         * lib/mkdtemp.c: Likewise.
10443         * lib/pipe.c: Likewise.
10444         * lib/printf-args.c: Likewise.
10445         * lib/printf-parse.c: Likewise.
10446         * lib/progname.c: Likewise.
10447         * lib/progreloc.c: Likewise.
10448         * lib/readlink.c: Likewise.
10449         * lib/sh-quote.c: Likewise.
10450         * lib/stpcpy.c: Likewise.
10451         * lib/stpncpy.c: Likewise.
10452         * lib/strcasecmp.c: Likewise.
10453         * lib/strcasestr.c: Likewise.
10454         * lib/strcspn.c: Likewise.
10455         * lib/striconv.c: Likewise.
10456         * lib/strncasecmp.c: Likewise.
10457         * lib/strnlen1.c: Likewise.
10458         * lib/strstr.c: Likewise.
10459         * lib/strtok_r.c: Likewise.
10460         * lib/tls.c: Likewise.
10461         * lib/tmpdir.c: Likewise.
10462         * lib/unicodeio.c: Likewise.
10463         * lib/unsetenv.c: Likewise.
10464         * lib/vasnprintf.c: Likewise.
10465         * lib/vasprintf.c: Likewise.
10466         * lib/wait-process.c: Likewise.
10467         * lib/xallocsa.c: Likewise.
10468         * lib/xsetenv.c: Likewise.
10469         * lib/xstriconv.c: Likewise.
10470
10471 2006-09-13  Simon Josefsson  <jas@extundo.com>
10472
10473         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
10474         that internally, suggested by Ralf Wildenhues
10475         <Ralf.Wildenhues@gmx.de>.
10476
10477 2006-09-13  Simon Josefsson  <jas@extundo.com>
10478
10479         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
10480         @LIBOBJS@.
10481         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10482
10483 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
10484
10485         * lib/_fpending.c: Include <config.h> unconditionally, since we no
10486         longer worry about uses that don't define HAVE_CONFIG_H.
10487         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
10488         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
10489         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
10490         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
10491         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
10492         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
10493         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
10494         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
10495         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
10496         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
10497         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
10498         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
10499         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
10500         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
10501         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
10502         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
10503         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
10504         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
10505         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
10506         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
10507         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
10508         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
10509         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
10510         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
10511         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
10512         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
10513         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
10514         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
10515         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
10516         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
10517         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
10518         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
10519         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
10520         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
10521         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
10522         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
10523         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
10524         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
10525         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
10526         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
10527         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
10528         Likewise.
10529
10530 2006-09-13  Eric Blake  <ebb9@byu.net>
10531
10532         * lib/getopt.c: Fix typo in last commit.
10533
10534 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
10535
10536         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
10537         dgettext.
10538
10539 2006-09-12  Jim Meyering  <jim@meyering.net>
10540
10541         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
10542         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
10543         Reported by Nelson H. F. Beebe.
10544
10545 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
10546
10547         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
10548         program_invocation_name and program_invocation_short_name are
10549         initialized.
10550         * lib/argp-namefrob.h: Move declarations of program_invocation_name
10551         and program_invocation_short_name to argp.h, so they are visible
10552         to user programs.
10553         * lib/argp.h: Likewise
10554
10555 2006-09-10  Bruno Haible  <bruno@clisp.org>
10556
10557         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
10558         m4/inttypes_h.m4, m4/uintmax_t.m4.
10559
10560 2006-09-10  Bruno Haible  <bruno@clisp.org>
10561
10562         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
10563         gl_AC_TYPE_UINTMAX_T.
10564
10565 2006-09-10  Bruno Haible  <bruno@clisp.org>
10566
10567         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
10568
10569 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
10570
10571         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
10572         convention.  Text proposed by Bruno Haible.
10573         (struct argp_option): Document the use of N_() wrappers.
10574
10575         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
10576         '\v', and translate the two parts separately, instead of feeding
10577         the whole string to gettext.  This allows to exclude
10578         '\v' from the strings visible to the translator by writing doc
10579         strings as N_("..") "\v" N_("..").
10580
10581 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
10582
10583         * config/srclist.txt: Undo latest change; the bug was fixed.
10584
10585 2006-09-09  Bruno Haible  <bruno@clisp.org>
10586
10587         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
10588         assignments if building a library without libtool.
10589         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
10590         in func_emit_lib_Makefile_am.
10591         (func_import): When building a static library libfoo.a, arrange to
10592         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
10593         (func_create_testdir): Likewise.
10594         * modules/gc (configure.ac, Makefile.am): If building statically,
10595         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
10596         * modules/iconvme (configure.ac, Makefile.am): Likewise.
10597         * modules/striconv (configure.ac, Makefile.am): Likewise.
10598         Based on a suggestion by Ralf Wildenhues.
10599
10600 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10601
10602         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
10603         Check for unistd.h too, since Autoconf doesn't assume POSIX.
10604         Also:
10605
10606         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10607         Add year_2050_test to catch glibc bug 2821
10608         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
10609
10610         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10611         Prefer #ifdef to #if.
10612
10613         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
10614         Return from 'main' instead of calling 'exit'.
10615
10616 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10617
10618         * lib/mktime.c (guess_time_tm): Fix bug where mktime
10619         returned the maximum time_t value rather than (time_t) -1.
10620         Problem originally reported by William Bardwell
10621         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
10622
10623         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
10624         Moved to here ...
10625         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
10626         ... from here.
10627
10628 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10629
10630         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
10631         2821 is fixed.
10632
10633 2006-09-08  Jim Meyering  <jim@meyering.net>
10634
10635         Don't make generated files read-only.  That would bother too many
10636         people.  However, do retain the ability to work when targets are
10637         read-only: remove the destination and temporary files before writing
10638         them (when generated via sed or echo), or by using the -f option for
10639         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
10640         * modules/alloca-opt, modules/argz, modules/arpa_inet:
10641         * modules/byteswap, modules/configmake, modules/fcntl:
10642         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
10643         * modules/localcharset, modules/netinet_in, modules/poll:
10644         * modules/stdbool, modules/stdint, modules/sys_select:
10645         * modules/sys_socket, modules/sys_stat, modules/sysexits:
10646
10647 2006-09-08  Jim Meyering  <jim@meyering.net>
10648
10649         Avoid new build failure on FreeBSD 6.0.
10650         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
10651         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
10652         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
10653
10654 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10655
10656         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
10657
10658 2006-09-07  Jim Meyering  <jim@meyering.net>
10659
10660         Fix global typo in last change: use chmod u-w, not chmod u-x.
10661         Spotted by Paul Eggert and Bruce Korb.
10662         * modules/alloca-opt, modules/argz, modules/arpa_inet:
10663         * modules/byteswap, modules/configmake, modules/fcntl:
10664         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
10665         * modules/localcharset, modules/netinet_in, modules/poll:
10666         * modules/stdbool, modules/stdint, modules/sys_select:
10667         * modules/sys_socket, modules/sys_stat, modules/sysexits:
10668
10669 2006-09-06  Jim Meyering  <jim@meyering.net>
10670
10671         Make generated files be read-only.
10672         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
10673         Ensure that each generated file is now read-only.
10674         * modules/argz: Likewise.
10675         * modules/arpa_inet: Likewise.
10676         * modules/byteswap: Likewise.
10677         * modules/configmake: Likewise.
10678         * modules/fcntl: Likewise.
10679         * modules/fnmatch: Likewise.
10680         * modules/getopt: Likewise.
10681         * modules/glob: Likewise.
10682         * modules/inttypes: Likewise.
10683         * modules/netinet_in: Likewise.
10684         * modules/poll: Likewise.
10685         * modules/stdbool: Likewise.
10686         * modules/stdint: Likewise.
10687         * modules/sys_select: Likewise.
10688         * modules/sys_socket: Likewise.
10689         * modules/sys_stat: Likewise.
10690         * modules/sysexits: Likewise.
10691         * modules/localcharset: Same as above, but continue using temporary
10692         file named "t-$@" (why different?) rather than the "$@-t" used
10693         everywhere else.
10694
10695         * modules/sysexits (Makefile.am): Replace literal occurrences
10696         of "sysexit.h" more readable, and more consistent, "$@".
10697
10698 2006-09-06  Bruno Haible  <bruno@clisp.org>
10699
10700         * modules/striconv: New file.
10701         * modules/xstriconv: New file.
10702         * MODULES.html.sh (Internationalization functions): Add striconv,
10703         xstriconv.
10704
10705 2006-09-06  Bruno Haible  <bruno@clisp.org>
10706
10707         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
10708         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
10709         not using libtool correctly.
10710
10711 2006-09-06  Bruno Haible  <bruno@clisp.org>
10712
10713         * lib/striconv.h: New file.
10714         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
10715         iconvstring.c.
10716         * lib/xstriconv.h: New file.
10717         * lib/xstriconv.c: New file.
10718
10719 2006-09-06  Bruno Haible  <bruno@clisp.org>
10720
10721         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
10722         lib_..._LDFLAGS.
10723
10724 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10725
10726         * lib/argz_.h: Sync from Libtool.
10727
10728         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
10729                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
10730
10731         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
10732
10733 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
10734
10735         * modules/trim: New file.
10736
10737 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
10738
10739         * lib/trim.h: New file.
10740         * lib/trim.c: New file.
10741
10742 2006-09-05  Bruno Haible  <bruno@clisp.org>
10743
10744         * MODULES.html.sh (String handling): Add trim.
10745
10746 2006-09-04  Karl Berry  <karl@gnu.org>
10747
10748         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
10749         until next release.
10750
10751 2006-09-03  Bruno Haible  <bruno@clisp.org>
10752
10753         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
10754         correctly.
10755
10756 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10757
10758         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
10759         not gl_GETLOADAVG.  Omit unneeded semicolons.
10760         Problems reported by Ralf Wildenhues in
10761         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
10762         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
10763         at the end, which is the usual gnulib style.
10764
10765         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
10766         of doing all the work ourselves.
10767         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
10768         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
10769
10770 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10771
10772         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
10773         Problem reported by Ralf Wildenhues in
10774         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
10775
10776         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
10777         HAVE_STRUCT_STATFS_F_FSTYPENAME.
10778
10779 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10780
10781         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
10782         yesterday's patch by changing test -n to test -z.
10783
10784 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10785
10786         * modules/getloadavg (Files): Add m4/getloadavg.m4.
10787         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
10788         the former is now obsolescent.
10789
10790         * modules/chdir-long (Depends-on): Add fcntl.
10791
10792 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10793
10794         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
10795         obsolescent, and programs should use gnulib instead.
10796         * m4/getloadavg.m4: New file, with contents taken from Autoconf
10797         but with prefixes changed.
10798
10799 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10800
10801         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
10802         or stdbool.h, because they might not exist while configuring.
10803
10804         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
10805         Don't include unistd.h or limits.h; not needed, since chdir-long.h
10806         does that for us.
10807         (O_DIRECTORY): Remove.
10808
10809 2006-08-31  Eric Blake  <ebb9@byu.net>
10810
10811         * gnulib-tool: Don't let emacs change spaces to TAB.
10812
10813 2006-08-31  Bruno Haible  <bruno@clisp.org>
10814
10815         * gnulib-tool: When calling func_import more than once, do it in a
10816         subshell.
10817         Reported by Eric Blake <ebb9@byu.net>.
10818
10819 2006-08-31  Bruno Haible  <bruno@clisp.org>
10820
10821         * gnulib-tool (nl): Remove variable.
10822         (sed_transform_lib_file): Use more robust test for config-h module.
10823         (func_import): Fix typo in 2006-08-25 patch.
10824
10825 2006-08-31  Bruno Haible  <bruno@clisp.org>
10826
10827         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
10828         specified, augment Makefile.am variables instead of assigning them.
10829
10830 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10831
10832         Work around a bug in both the Linux and SunOS 64-bit kernels:
10833         nanosleep mishandles sleeps for longer than 2**31 seconds.
10834         Problem reported by Frank v Waveren in
10835         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
10836         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
10837         Check for nanosleep bug.
10838         (LIB_NANOSLEEP): Append clock_gettime library if needed.
10839
10840 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10841
10842         Work around a bug in both the Linux and SunOS 64-bit kernels:
10843         nanosleep mishandles sleeps for longer than 2**31 seconds.
10844         Problem reported by Frank v Waveren in
10845         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
10846         * lib/nanosleep.c (BILLION): New constant.
10847         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
10848         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
10849         implementation.
10850
10851 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10852
10853         * modules/nanosleep (Depends-on): Add gettime.
10854
10855 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10856         and Simon Josefsson  <jas@extundo.com>
10857         and Oskar Liljeblad  <oskar@osk.mine.nu>
10858
10859         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
10860         * gnulib-tool (func_import): New license type 'unmodifiable license
10861         text'.
10862         * modules/fdl: Use it.  Longer description.
10863         * module/gpl, module/lgpl: New files.
10864
10865 2006-08-30  Jim Meyering  <jim@meyering.net>
10866
10867         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
10868         shadowing the parameter.
10869
10870 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10871
10872         Sync from Libtool:
10873
10874         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10875
10876         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
10877         sharing with gnulib.  Report by Eric Blake.
10878
10879 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10880
10881         * modules/isapipe: New file.
10882         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
10883
10884 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10885
10886         * modules/configmake (Makefile.am): Add a comment, and omit
10887         the CONFIGMAKE_ prefix from generated macro names.  Suggested
10888         by Bruno Haible.
10889
10890 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10891
10892         * m4/isapipe.m4: New file.
10893
10894 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10895
10896         * lib/isapipe.c, lib/isapipe.h: New files.
10897
10898 2006-08-29  Jim Meyering  <jim@meyering.net>
10899
10900         * modules/configmake (Makefile.am): Make configmake.h depend on
10901         Makefile.  Otherwise, a stale configmake.h could hang around.
10902
10903 2006-08-29  Eric Blake  <ebb9@byu.net>
10904
10905         * lib/error.c (error_at_line, print_errno_message): Match libc, after
10906         resolution of upstream bug 3044.
10907
10908 2006-08-29  Bruno Haible  <bruno@clisp.org>
10909
10910         * modules/localcharset (Depends-on): Add configmake.
10911         (Makefile.am): Remove setting of LIBDIR through DEFS.
10912
10913 2006-08-29  Bruno Haible  <bruno@clisp.org>
10914
10915         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
10916         defined.
10917
10918 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10919
10920         * modules/fcntl: New file.
10921         * modules/chdir-safer (Depends-on): Add fcntl.
10922         * modules/fts: Likewise.
10923         * modules/mkdir-p: Likewise.
10924
10925         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
10926         This undoes the most recent change, since we're now addressing the
10927         problem in a different way.
10928
10929         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
10930         into output, since the output might be called Makefile.am even
10931         if $makefile_name is something different.
10932         (func_import): Use $makefile_am rather than
10933         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
10934         empty.
10935
10936         * modules/inttypes (Files): Add m4/inttypes-h.m4.
10937
10938 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10939
10940         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
10941         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
10942         recent change to stdint.m4, since we're now addressing the problem in a
10943         different way.
10944
10945 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10946
10947         * m4/fcntl_h.m4: New file.
10948
10949 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10950
10951         * lib/fcntl_.h: New file.
10952         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
10953         the fcntl module.
10954         * lib/dirchownmod.c: Likewise.
10955         * lib/fts.c: Likewise.
10956
10957         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
10958         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
10959         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
10960         just before including <inttypes.h>, to avoid circular inclusion.
10961
10962 2006-08-28  Jim Meyering  <jim@meyering.net>
10963
10964         * doc/visibility.texi: Actually read and correct the grammar of the
10965         sentence affected by yesterday's change.
10966
10967 2006-08-28  Eric Blake  <ebb9@byu.net>
10968
10969         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
10970         needs wrapper.
10971
10972 2006-08-28  Eric Blake  <ebb9@byu.net>
10973
10974         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
10975
10976 2006-08-28  Eric Blake  <ebb9@byu.net>
10977
10978         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
10979
10980 2006-08-28  Bruno Haible  <bruno@clisp.org>
10981
10982         * modules/c-strstr: New file, from GNU gettext.
10983         * MODULES.html.sh (String handling): Add c-strstr.
10984
10985 2006-08-28  Bruno Haible  <bruno@clisp.org>
10986
10987         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
10988         macros.
10989         Reported by Eric Blake.
10990
10991 2006-08-28  Bruno Haible  <bruno@clisp.org>
10992
10993         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
10994         (VASNPRINTF): Return a string of length > INT_MAX without failing.
10995         * lib/vasprintf.c: Include errno.h, limits.h.
10996         (EOVERFLOW): New fallback definition.
10997         (vasprintf): Test here whether the string length is > INT_MAX.
10998         * lib/vsnprintf.c: Include errno.h, limits.h.
10999         (EOVERFLOW): New fallback definition.
11000         (vsnprintf): Fix bug when generated string was too long for the buffer.
11001         Test here whether the string length is > INT_MAX.
11002
11003 2006-08-28  Bruno Haible  <bruno@clisp.org>
11004
11005         * lib/inttypes_.h (SCNX*): Remove definitions.
11006         Reported by Eric Blake.
11007
11008 2006-08-28  Bruno Haible  <bruno@clisp.org>
11009
11010         * lib/c-strstr.h: New file, from GNU gettext.
11011         * lib/c-strstr.c: New file, from GNU gettext.
11012
11013 2006-08-28  Bruno Haible  <bruno@clisp.org>
11014
11015         * gnulib-tool: Reorder some statements.
11016
11017 2006-08-28  Bruno Haible  <bruno@clisp.org>
11018
11019         * gnulib-tool: New option --makefile-name.
11020         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
11021         $makefile_name.
11022         (func_import): Write $makefile_name to the cache file, and read it from
11023         there unless explicitly specified. Use $makefile_name as file name
11024         instead of Makefile.am. Adjust the recommendations accordingly.
11025
11026 2006-08-28  Bruno Haible  <bruno@clisp.org>
11027
11028         * gnulib-tool (func_verify_module): Check against misapplying patch.
11029
11030 2006-08-28  Bruno Haible  <bruno@clisp.org>
11031
11032         * gnulib-tool (func_relativize, func_relconcat): New functions.
11033         Give an error if --local-dir is given with --update.
11034         Remove trailing slashes from $local_gnulib_dir.
11035         (func_import): Store the relativized $local_gnulib_dir in
11036         gnulib-cache.m4, and read it from there if not specified explicitly.
11037
11038 2006-08-28  Bruno Haible  <bruno@clisp.org>
11039
11040         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
11041         is the current directory. Respect also $local_gnulib_dir.
11042
11043 2006-08-28  Bruno Haible  <bruno@clisp.org>
11044             Simon Josefsson  <jas@extundo.com>
11045
11046         BeOS portability.
11047         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
11048
11049 2006-08-27  Jim Meyering  <jim@meyering.net>
11050
11051         * doc/visibility.texi: Remove duplicate word: "pointer".
11052
11053 2006-08-26  Bruno Haible  <bruno@clisp.org>
11054
11055         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
11056         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
11057         (Makefile.am): Create inttypes.h from inttypes_.h.
11058         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
11059
11060         * modules/imaxabs: New file.
11061
11062         * modules/imaxdiv: New file.
11063
11064 2006-08-26  Bruno Haible  <bruno@clisp.org>
11065
11066         * m4/inttypes.m4: New file.
11067         * m4/_inttypes_h.m4: Remove file.
11068         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
11069         PRI_MACROS_BROKEN.
11070         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
11071
11072         * m4/imaxabs.m4: New file.
11073
11074         * m4/imaxdiv.m4: New file.
11075
11076 2006-08-26  Bruno Haible  <bruno@clisp.org>
11077
11078         * lib/inttypes_.h: New file.
11079         * lib/inttypes.h: Remove file.
11080         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
11081
11082         * lib/imaxabs.c: New file.
11083
11084         * lib/imaxdiv.c: New file.
11085
11086 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11087
11088         New config-h module, so that "make" output needn't be cluttered
11089         by -DHAVE_CONFIG_H.
11090         * MODULES.html.sh (Support for building libraries and executables):
11091         Add config-h.
11092         * modules/config-h: New file.
11093         * gnulib-tool (nl, sed_transform_lib_file): New vars.
11094         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
11095         the config-h module is used.
11096
11097         New configmake module, so that "make" output needn't be cluttered
11098         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
11099         * MODULES.html.sh (Support for building libraries and executables):
11100         Add configmake.
11101         * modules/configmake: New file.
11102
11103 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11104
11105         * m4/config-h.m4: New file.
11106
11107 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11108
11109         * config/srclist.txt: Add elisp-comp.
11110
11111 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11112
11113         * MODULES.html.sh (Support for building libraries and executables):
11114         Add elisp-comp.
11115         * build-aux/elisp-comp: New file.
11116         * modules/elisp-comp: New file.
11117
11118 2006-08-24  Bruno Haible  <bruno@clisp.org>
11119
11120         * gnulib-tool (func_create_testdir): Use non-default values of
11121         sourcebase and m4base.
11122
11123 2006-08-24  Bruno Haible  <bruno@clisp.org>
11124
11125         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
11126         HTML structure.
11127
11128 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11129
11130         * modules/openat (Depends-on): Add lchown.
11131
11132 2006-08-23  Bruno Haible  <bruno@clisp.org>
11133
11134         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
11135         of gl_LOCK_EARLY instead of gl_LOCK.
11136
11137 2006-08-23  Bruno Haible  <bruno@clisp.org>
11138
11139         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
11140         on OSF/1 to no.
11141         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
11142
11143 2006-08-23  Bruno Haible  <bruno@clisp.org>
11144
11145         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
11146         as unusable.
11147
11148         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
11149         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
11150         (gl_LOCK): New macro.
11151
11152 2006-08-22  Simon Josefsson  <jas@extundo.com>
11153
11154         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
11155         to md5 module.
11156
11157 2006-08-22  Simon Josefsson  <jas@extundo.com>
11158
11159         * MODULES.html.sh: Add "Support for maintaining and release
11160         projects".
11161
11162         * build-aux/gnupload: New file, from coreutils.
11163
11164 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11165
11166         Avoid the need for AC_LIBSOURCES in m4 macros.
11167         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
11168         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
11169         * modules/check-version (EXTRA_DIST): Add check-version.h.
11170         * modules/crc (EXTRA_DIST): Add crc.h.
11171         * modules/des (EXTRA_DIST): Add des.h.
11172         * modules/gc (EXTRA_DIST): Add gc.h.
11173         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
11174         * modules/getline (EXTRA_DIST): Add getline.h.
11175         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
11176         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
11177         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
11178         * modules/md2 (EXTRA_DIST): Add md2.h.
11179         * modules/md4 (EXTRA_DIST): Add md4.h.
11180         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
11181         * modules/read-file (EXTRA_DIST): Add read-file.h.
11182         * modules/readline (EXTRA_DIST): Add readline.h.
11183         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
11184         rijndael-api-fst.h.
11185
11186 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11187
11188         * m4/rijndael.m4 (gl_ARCFOUR):
11189         * m4/arctwo.m4 (gl_ARCTWO):
11190         * m4/check-version.m4 (gl_CHECK_VERSION):
11191         * m4/crc.m4 (gl_CRC):
11192         * m4/des.m4 (gl_DES):
11193         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
11194         * m4/gc.m4 (gl_GC):
11195         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
11196         * m4/getline.m4 (gl_FUNC_GETLINE):
11197         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
11198         * m4/hmac-md5.m4 (gl_HMAC_MD5):
11199         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
11200         * m4/md2.m4 (gl_MD2):
11201         * m4/md4.m4 (gl_MD4):
11202         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
11203         * m4/read-file.m4 (gl_FUNC_READ_FILE):
11204         * m4/readline.m4 (gl_FUNC_READLINE):
11205         * m4/rijndael.m4 (gl_RIJNDAEL):
11206         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11207         to get the necessary .h files and whatnot.
11208
11209 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11210
11211         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
11212         gnulib rather than the other way around.
11213         * config/srclistvars.sh (COREUTILS): Remove.
11214
11215 2006-08-22  Jim Meyering  <jim@meyering.net>
11216
11217         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
11218
11219         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
11220
11221 2006-08-22  Eric Blake  <ebb9@byu.net>
11222
11223         * modules/regexprops-generic: New file.
11224         * MODULES.html.sh (Support for building documentation): List it.
11225
11226 2006-08-22  Eric Blake  <ebb9@byu.net>
11227
11228         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
11229         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
11230         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
11231         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
11232
11233 2006-08-22  Bruno Haible  <bruno@clisp.org>
11234
11235         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
11236         and lib_LTLIBRARIES like the other lib_* variables.
11237
11238 2006-08-22  Bruno Haible  <bruno@clisp.org>
11239
11240         * build-aux/x-to-1.in: New file, from GNU gettext.
11241
11242 2006-08-22  Bruno Haible  <bruno@clisp.org>
11243
11244         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
11245         <utmpx.h> exists.
11246
11247 2006-08-22  Bruno Haible  <bruno@clisp.org>
11248
11249         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
11250         <utmpx.h> exists.
11251
11252 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11253
11254         BeOS portability.
11255         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
11256         exist.
11257         Problem reported by Bruno Haible.
11258
11259 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11260
11261         Avoid the need for AC_LIBSOURCES in m4 macros.
11262         * modules/acl (EXTRA_DIST): Add acl.h.
11263         * modules/argmatch (Files): Add m4/argmatch.m4.
11264         (configure.ac): Add gl_ARGMATCH.
11265         (EXTRA_DIST): Renamed from lib_SOURCES, for
11266         consistency with the other modules.  Remove argmatch.c.
11267         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
11268         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
11269         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
11270         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
11271         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
11272         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
11273         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
11274         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
11275         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
11276         * modules/closeout (EXTRA_DIST): Add closeout.h.
11277         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
11278         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
11279         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
11280         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
11281         dirname.h; remove basename.c and stripslash.c.
11282         * modules/exclude (EXTRA_DIST): Add exclude.h.
11283         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
11284         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
11285         * modules/file-type (EXTRA_DIST): Add file-type.h.
11286         * modules/filemode (EXTRA_DIST): Add filemode.h.
11287         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
11288         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11289         * modules/fpending (EXTRA_DIST): Add __fpending.h.
11290         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
11291         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
11292         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
11293         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
11294         * modules/getdate (EXTRA_DIST): Add getdate.c.
11295         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
11296         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
11297         * modules/getpass (EXTRA_DIST): Add getpass.h.
11298         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
11299         * modules/group-member (EXTRA_DIST): Add group-member.h.
11300         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
11301         * modules/hash (EXTRA_DIST): Add hash.h.
11302         * modules/human (EXTRA_DIST): Add human.h.
11303         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
11304         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
11305         * modules/lchown (EXTRA_DIST): Add lchown.h.
11306         * modules/long-options (EXTRA_DIST): Add long-options.h.
11307         * modules/lstat (EXTRA_DIST): Add lstat.h.
11308         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
11309         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
11310         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
11311         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
11312         * modules/memxor (EXTRA_DIST): Add memxor.h.
11313         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
11314         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
11315         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
11316         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
11317         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
11318         * modules/physmem (EXTRA_DIST): Add physmem.h.
11319         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
11320         * modules/posixver (EXTRA_DIST): Add posixver.h.
11321         * modules/quote (EXTRA_DIST): Add quote.h.
11322         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
11323         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
11324         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
11325         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
11326         regex_internal.h regexec.c.
11327         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
11328         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
11329         * modules/same (EXTRA_DIST): Add same.h.
11330         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
11331         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
11332         * modules/savedir (EXTRA_DIST): Add savedir.h.
11333         * modules/sha1 (EXTRA_DIST): Add sha1.h.
11334         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
11335         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
11336         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
11337         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
11338         * modules/strdup (EXTRA_DIST): Add strdup.h.
11339         * modules/strftime (EXTRA_DIST): Add strftime.h.
11340         * modules/strndup (EXTRA_DIST): Add strndup.h.
11341         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
11342         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
11343         * modules/time_r (EXTRA_DIST): Add time_r.h.
11344         * modules/timespec (EXTRA_DIST): Add timespec.h.
11345         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11346         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
11347         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
11348         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
11349         * modules/userspec (EXTRA_DIST): Add userspec.h.
11350         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
11351         * modules/utimens (EXTRA_DIST): Add utimens.h.
11352         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
11353         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
11354         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
11355         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
11356         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
11357         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
11358         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
11359         * modules/yesno (EXTRA_DIST): Add yesno.h.
11360
11361 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11362
11363         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
11364
11365         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
11366         * m4/dev-ino.m4, same-inode.m4: Remove.
11367
11368         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
11369         * m4/acl.m4 (AC_FUNC_ACL):
11370         * m4/backupfile.m4 (gl_BACKUPFILE):
11371         * m4/c-strtod.m4 (gl_C99_STRTOLD):
11372         * m4/canon-host.m4 (gl_CANON_HOST):
11373         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
11374         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
11375         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
11376         * m4/cloexec.m4 (gl_CLOEXEC):
11377         * m4/close-stream.m4 (gl_CLOSE_STREAM):
11378         * m4/closeout.m4 (gl_CLOSEOUT):
11379         * m4/dirfd.m4 (gl_FUNC_DIRFD):
11380         * m4/dirname.m4 (gl_DIRNAME):
11381         * m4/exclude.m4 (gl_EXCLUDE):
11382         * m4/exitfail.m4 (gl_EXITFAIL):
11383         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
11384         * m4/file-type.m4 (gl_FILE_TYPE):
11385         * m4/filemode.m4 (gl_FILEMODE):
11386         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
11387         * m4/fpending.m4 (gl_FUNC_FPENDING):
11388         * m4/fprintftime.m4 (gl_FPRINTFTIME):
11389         * m4/fts.m4 (gl_FUNC_FTS):
11390         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
11391         * m4/getdate.m4 (gl_GETDATE):
11392         * m4/gethrxtime.m4 (gl_GETHRXTIME):
11393         * m4/getpagesize.m4 (gl_GETPAGESIZE):
11394         * m4/getpass.m4 (gl_FUNC_GETPASS):
11395         * m4/gettime.m4 (gl_GETTIME):
11396         * m4/getugroups.m4 (gl_GETUGROUPS):
11397         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
11398         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
11399         * m4/hard-locale.m4 (gl_HARD_LOCALE):
11400         * m4/hash.m4 (gl_HASH):
11401         * m4/idcache.m4 (gl_IDCACHE):
11402         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
11403         * m4/lchown.m4 (gl_FUNC_LCHOWN):
11404         * m4/long-options.m4 (gl_LONG_OPTIONS):
11405         * m4/lstat.m4 (gl_FUNC_LSTAT):
11406         * m4/md5.m4 (gl_MD5):
11407         * m4/memcasecmp.m4 (gl_MEMCASECMP):
11408         * m4/memcoll.m4 (gl_MEMCOLL):
11409         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
11410         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
11411         * m4/memxor.m4 (gl_MEMXOR):
11412         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
11413         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
11414         * m4/modechange.m4 (gl_MODECHANGE):
11415         * m4/mountlist.m4 (gl_MOUNTLIST):
11416         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
11417         * m4/openat.m4 (gl_FUNC_OPENAT):
11418         * m4/pathmax.m4 (gl_PATHMAX):
11419         * m4/physmem.m4 (gl_PHYSMEM):
11420         * m4/posixtm.m4 (gl_POSIXTM):
11421         * m4/posixver.m4 (gl_POSIXVER):
11422         * m4/quote.m4 (gl_QUOTE):
11423         * m4/quotearg.m4 (gl_QUOTEARG):
11424         * m4/readtokens.m4 (gl_READTOKENS):
11425         * m4/readutmp.m4 (gl_READUTMP):
11426         * m4/regex.m4 (gl_REGEX):
11427         * m4/safe-read.m4 (gl_SAFE_READ):
11428         * m4/safe-write.m4 (gl_SAFE_WRITE):
11429         * m4/same.m4 (gl_SAME):
11430         * m4/save-cwd.m4 (gl_SAVE_CWD):
11431         * m4/savedir.m4 (gl_SAVEDIR):
11432         * m4/settime.m4 (gl_SETTIME):
11433         * m4/sha1.m4 (gl_SHA1):
11434         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
11435         * m4/stat-macros.m4 (gl_STAT_MACROS):
11436         * m4/stat-time.m4 (gl_STAT_TIME):
11437         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
11438         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
11439         * m4/strdup.m4 (gl_FUNC_STRDUP):
11440         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
11441         * m4/strndup.m4 (gl_FUNC_STRNDUP):
11442         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
11443         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
11444         * m4/time_r.m4 (gl_TIME_R):
11445         * m4/timespec.m4 (gl_TIMESPEC):
11446         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
11447         * m4/unlinkdir.m4 (gl_UNLINKDIR):
11448         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
11449         * m4/userspec.m4 (gl_USERSPEC):
11450         * m4/utimecmp.m4 (gl_UTIMECMP):
11451         * m4/utimens.m4 (gl_UTIMENS):
11452         * m4/xalloc.m4 (gl_XALLOC):
11453         * m4/xgetcwd.m4 (gl_XGETCWD):
11454         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
11455         * m4/xreadlink.m4 (gl_XREADLINK):
11456         * m4/xstrtod.m4 (gl_XSTRTOD):
11457         * m4/yesno.m4 (gl_YESNO):
11458         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11459         to get the necessary .h files and whatnot.
11460
11461 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
11462             Bruno Haible  <bruno@clisp.org>
11463
11464         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
11465         /bin/sh understanding of '!' conditional negation.
11466
11467 2006-08-21  Jim Meyering  <jim@meyering.net>
11468
11469         * modules/openat (Depends-on): Really alphabetize.
11470
11471         * modules/acl (Depends-on): Add error and quote.
11472
11473         * check-module (find_included_lib_files): Add at-func.c to the
11474         ok-to-include-more-than-once white list.
11475
11476         * modules/openat (Depends-on): Add lstat.  Alphabetize.
11477
11478 2006-08-21  Bruno Haible  <bruno@clisp.org>
11479
11480         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
11481         Emit a pkgdata_DATA variable only if some snippets add contents to it.
11482         Reported by Martin Lambers <marlam@marlam.de>.
11483
11484 2006-08-21  Bruno Haible  <bruno@clisp.org>
11485
11486         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
11487         specify an installation location, don't emit a noinst_LIBRARIES or
11488         noinst_LTLIBRARIES assignment.
11489
11490 2006-08-21  Bruno Haible  <bruno@clisp.org>
11491
11492         BeOS portability.
11493         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
11494         BeOS has mbrtowc() but no <wctype.h>.
11495
11496 2006-08-21  Bruno Haible  <bruno@clisp.org>
11497
11498         BeOS portability.
11499         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
11500         exist.
11501
11502 2006-08-21  Bruno Haible  <bruno@clisp.org>
11503
11504         BeOS portability.
11505         * lib/mbchar.h: Include <wctype.h> only if it exists.
11506
11507 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11508
11509         Remove files that are no longer needed by their respective modules.
11510         * m4/obstack.m4: Remove.
11511         * m4/strerror_r.m4: Remove.
11512         * m4/uint32_t.m4: Remove.
11513         * m4/uintptr_t.m4: Remove.
11514         * m4/ullong_max.m4: Remove.
11515         * m4/xstrtoimax.m4: Remove.
11516         * m4/xstrtoumax.m4: Remove.
11517
11518         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
11519         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
11520         dependencies now capture this.
11521
11522         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
11523         Do not use AC_LIBSOURCES, since gnulib modules now do this.
11524         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
11525         * m4/human.m4 (gl_HUMAN): Likewise.
11526         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
11527         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
11528
11529         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
11530
11531         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
11532         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
11533         stdint.
11534         * m4/human.m4 (gl_HUMAN): Likewise.
11535         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
11536         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
11537         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
11538         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
11539         * m4/xstrtol (gl_XSTRTOL): Likewise.
11540
11541         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
11542         AC_TYPE_LONG_LONG_INT.
11543         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
11544         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
11545         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
11546         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
11547
11548         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
11549         on stdbool.
11550
11551         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
11552         (gl_PREREQ_XSTRTOUL): Remove.
11553
11554         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
11555
11556         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
11557         mode.
11558
11559 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11560
11561         Add and change modules to make it easier for coreutils to use
11562         gnulib-tool.
11563         * modules/backupfile (Files): Remove m4/d-ino.m4.
11564         (Depends-on): Add d-ino.
11565         * modules/cycle-check (Depends-on): Add stdint.
11566         (lib_SOURCES): Add cycle-check.h.
11567         * modules/d-ino: New module.
11568         * modules/d-type: New module.
11569         * modules/error (Files): Remove m4/strerror_r.m4.
11570         * modules/filemode (Files): Add m4/st_dm_mode.m4.
11571         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
11572         m4/inttypes_h.m4, m4/uintmax_t.m4.
11573         (Depends-on): Add stdint.
11574         (lib_SOURCES): Add fsusage.h.
11575         * modules/getcwd (Files): Remove d-ino.m4.
11576         (Depends-on): Add d-ino.
11577         * modules/getndelim2 (Depends-on): Add stdint.
11578         * modules/glob (Files): Remove m4/d-type.m4.
11579         (Depends-on): Add d-type.
11580         * modules/host-os: New module.
11581         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
11582         m4/inttypes_h.m4, m4/uintmax_t.m4.
11583         * Depends-on: Add stdint.
11584         (lib_SOURCES): Add human.h.
11585         * modules/inttostr (Files): Remove m4/intmax_t.m4,
11586         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
11587         m4/uintmax_t.m4, m4/ulonglong.m4.
11588         (Depends-on): Add stdint.
11589         (EXTRA_DIST): Add inttostr.h.
11590         * modules/lchmod: New module.
11591         * modules/link-follow: New module.
11592         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
11593         (Depends-on): Add lchmod.
11594         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
11595         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
11596         (Depends-on): Add stdint.
11597         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
11598         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
11599         (Depends-on): Add stdint.
11600         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
11601         * modules/perl: New module.
11602         * modules/regex (Depends-on): Add stdint.
11603         * modules/rmdir-errno: New module.
11604         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
11605         m4/intmax_t.m4.
11606         (Depends-on): Add stdint.
11607         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
11608         m4/uintmax_t.m4.
11609         (Depends-on): Add stdint.
11610         * modules/unlink-busy: New module.
11611         * modules/utimecmp (Depends-on): Add stdint.
11612         * modules/uptime: New module.
11613         * modules/winsz-ioctl: New module.
11614         * modules/winsz-termios: New module.
11615         * modules/xnanosleep (Depends-on): Add nanosleep.
11616         * modules/ullong_max: Remove.
11617         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
11618         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
11619         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
11620         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
11621         (Depends-on): Add inttypes.
11622         (lib_SOURCES): Add xstrtol.h.
11623         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
11624         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
11625         * MODULES.html.sh: Move 'assert' into the assert section.
11626         Move 'dummy' into the linking section.
11627         Remove ullong_max.
11628         Add section for compatibility checks for POSIX:2001 functions,
11629         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
11630         winsz-ioctl, and winsz-termios into it.
11631         Add lchmod.
11632         Add top-level Misc section and put host-os, perl, and uptime
11633         into it.
11634
11635 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11636
11637         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
11638         now assume the stdint module.  Do not include inttypes.h.
11639         * lib/fsusage.h: Likewise.
11640         * lib/getndelim2.c: Likewise.
11641         * lib/human.h: Likewise.
11642         * lib/inttostr.h: Likewise.
11643         * lib/obstack.c: Likewise.
11644         * lib/regex_internal.h: Likewise.
11645         * lib/tempname.c: Likewise.
11646         * lib/utimecmp.c: Likewise.
11647         * lib/xstrtol.h: Likewise.
11648
11649         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
11650
11651         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
11652         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
11653         * lib/xtime.h: Likewise.
11654
11655 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11656
11657         * modules/openat (Files): Add lib/fchmodat.c.
11658         Fixes problem reported by Jay Youngman.
11659
11660 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11661
11662         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
11663         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
11664
11665 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
11666             Bruno Haible  <bruno@clisp.org>
11667
11668         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
11669         and is a script that invokes bison. Tighten the code. Add comments.
11670
11671 2006-08-18  Jim Meyering  <jim@meyering.net>
11672
11673         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
11674         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
11675         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
11676         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
11677
11678 2006-08-18  Bruno Haible  <bruno@clisp.org>
11679
11680         * modules/bison-i18n: New file.
11681         * MODULES.html.sh (Internationalization functions): Add it.
11682
11683 2006-08-18  Bruno Haible  <bruno@clisp.org>
11684
11685         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
11686         sys/statvfs.h. When getmntinfo was found, check its declaration and
11687         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
11688
11689 2006-08-18  Bruno Haible  <bruno@clisp.org>
11690
11691         * m4/bison-i18n.m4: New file, from bison.
11692
11693 2006-08-18  Bruno Haible  <bruno@clisp.org>
11694
11695         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
11696         (ME_DUMMY): Treat "kernfs" as a dummy.
11697         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
11698
11699 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11700
11701         Update from coreutils.
11702
11703         2006-08-15  Jim Meyering  <jim@meyering.net>
11704
11705         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
11706
11707         2006-01-17  Jim Meyering  <jim@meyering.net>
11708
11709         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
11710
11711         2006-01-11  Jim Meyering  <jim@meyering.net>
11712
11713         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
11714         Check for the lchmod function.
11715
11716 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11717
11718         Update from coreutils.
11719
11720         * lib/__fpending.h: Add copyright notice.
11721         * lib/fprintftime.h: Likewise.
11722         * lib/savedir.c: Use (C) in copyright notice.
11723         * lib/savedir.h: Likewise.
11724
11725         2006-08-15  Jim Meyering  <jim@meyering.net>
11726
11727         * lib/at-func.c: New file, with the logic of all emulated at-functions.
11728         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
11729         in support of the EXPECTED_ERRNO macro.
11730         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
11731         definitions.  Instead, define the appropriate symbols and include
11732         "at-func.c".
11733         * lib/mkdirat.c (mkdirat): Likewise.
11734         * lib/fchmodat.c (fchmodat): Likewise.
11735         (ENOSYS): Remove definition.
11736         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
11737         it.  Don't include "unistd--.h" -- it wasn't ever used.
11738
11739         2006-01-17  Jim Meyering  <jim@meyering.net>
11740
11741         Rewrite fts.c not to change the current working directory,
11742         by using openat, fstatat, fdopendir, etc..
11743
11744         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
11745         (HAVE_OPENAT_SUPPORT): Define.
11746         [_LIBC] (fchdir): Don't undef or define; no longer used.
11747         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
11748         Now, this `function' always succeeds, and consumes its file descriptor
11749         parameter -- so callers must not close such FDs.  Update callers.
11750         (diropen_fd, opendirat, cwd_advance_fd): New functions.
11751         (diropen): Add parameter, SP.  Adjust all callers.
11752         Implement using diropen_fd, rather than open.
11753         (fts_open): Initialize new member, fts_cwd_fd.
11754         Remove fts_rft-setting code.
11755         (fts_close): Close fts_cwd_fd, if necessary.
11756         (__opendir2): Define in terms of opendir or opendirat,
11757         depending on whether the FST_NOCHDIR flag is set.
11758         (fts_build): Since fts_safe_changedir consumes its FD, and since
11759         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
11760         and close the dup'd file descriptor upon failure.
11761         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
11762         (fts_safe_changedir): Tweak semantics to reflect that this function
11763         now calls cwd_advance_fd and hence consumes its FD argument.
11764         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
11765         [struct FTS] (fts_rft): Remove now-unused member.
11766         [struct FTS] (fts_cycle.state): Improve comment.
11767
11768         * lib/openat.c (openat_needs_fchdir): New function.
11769         * lib/openat.h (openat_needs_fchdir): Declare it.
11770
11771 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11772
11773         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
11774         Problem and fix reported by Pádraig Brady in
11775         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
11776
11777 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11778
11779         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
11780
11781 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11782
11783         * lib/memcoll.c (memcoll): Optimize for the common case where the
11784         arguments are bytewise equal.
11785
11786 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11787
11788         * doc/regexprops-generic.texi: Add a copyright notice.
11789
11790 2006-08-15  Bruno Haible  <bruno@clisp.org>
11791
11792         * modules/tmpdir (License): Change to LGPL.
11793
11794 2006-08-15  Bruno Haible  <bruno@clisp.org>
11795
11796         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
11797         module.
11798
11799 2006-08-14  Simon Josefsson  <jas@extundo.com>
11800
11801         * config/srclist.txt: Add gnupload.
11802
11803 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11804
11805         Change copyright notice from LGPL 2 to GPL 2, since that's the
11806         standard form used in the gnulib repository.
11807         * tests/test-lock.c: Likewise.
11808         * tests/test-stdint.c: Likewise.
11809         * tests/test-tls.c: Likewise.
11810
11811         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
11812         prelude-manager.  User shorter URLs for GNU projects, without '?'.
11813         Add copyright notice.
11814
11815         * check-module: Add copyright notice.  Output a copyright
11816         notice if "--version" is specified.
11817         * modules/COPYING: New file.
11818         * tests/test-getaddrinfo.c: Add copyright notice.
11819         * tests/test-verify.c: Likewise.
11820
11821 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11822
11823         Change copyright notice from LGPL 2 to GPL 2, since that's the
11824         standard form used in the gnulib repository.
11825         * lib/lock.c: LGPL -> GPL.
11826         * lib/lock.h: Likewise.
11827         * lib/strnlen1.c: Likewise.
11828         * lib/strnlen1.h: Likewise.
11829         * lib/tls.c: Likewise.
11830         * lib/tls.h: Likewise.
11831         * lib/tmpdir.c: Likewise.
11832
11833         * lib/TODO: Remove; this belongs only in coreutils.
11834
11835 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11836
11837         Add copyright notices to long-enough files that lack them, since
11838         otherwise the files aren't clearly free.  Use the same notice that
11839         getdate.texi already uses.
11840         * doc/alloca-opt.texi: Add copyright notice.
11841         * doc/alloca.texi: Likewise.
11842         * doc/ctime.texi: Likewise.
11843         * doc/functions.texi: Likewise.
11844         * doc/gcd.texi: Likewise.
11845         * doc/gnulib-tool.texi: Likewise.
11846         * doc/inet_ntoa.texi: Likewise.
11847         * doc/visibility.texi: Likewise.
11848
11849         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
11850         * doc/quote.texi: Add copyright notice.
11851
11852         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
11853         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
11854         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
11855         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
11856         is now obsolete, and give a pointer to the Sun list.
11857         Add copyright notice.
11858
11859 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11860
11861         * config/srclistvars.sh: Add copyright notice.
11862
11863 2006-08-14  Eric Blake  <ebb9@byu.net>
11864
11865         Import the following change from libc:
11866
11867         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
11868
11869         Upstream bug 2997.
11870         * lib/misc/error.c: Add space between program name and message if file
11871         name is missing.
11872
11873 2006-08-12  Karl Berry  <karl@gnu.org>
11874
11875         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
11876         remove, these originate in gnulib now.
11877
11878 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11879
11880         * doc/Makefile (standards.info standards.html standards.dvi):
11881         Also depend on make-stds.texi.
11882
11883 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
11884
11885         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
11886         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
11887
11888         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
11889         in wchar_t.  Problem reported by Eric Blake.
11890
11891         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
11892         LEN is smaller than SIZE.  Suggested by Bruno Haible.
11893         Also, help the compiler to keep LEN in a register.
11894
11895 2006-08-11  Eric Blake  <ebb9@byu.net>
11896
11897         * users.txt: Sort.  Add tar.
11898
11899 2006-08-11  Bruno Haible  <bruno@clisp.org>
11900
11901         * users.txt: New file.
11902
11903 2006-08-11  Bruno Haible  <bruno@clisp.org>
11904
11905         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
11906         before <wchar.h>. Needed for OSF/1 and BSD/OS.
11907
11908 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
11909
11910         * modules/snprintf (Depends-on): Remove minmax.
11911         (Maintainer): Add self and Bruno.
11912
11913 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
11914
11915         * lib/.cppi-disable: Add snprintf.h, socket_.h.
11916         * lib/snprintf.c: Include <errno.h> and <limits.h>.
11917         (EOVERFLOW): Define if the system does not.
11918         Do not include "minmax.h"; it wasn't used.
11919         (snprintf): Don't assume size_t promotes to an unsigned type.
11920         Fix bug when generated string was too long for the buffer: the
11921         buffer's contents are supposed to be the initial prefix of the
11922         output.  Don't assume vasnprintf returns EOVERFLOW if the size
11923         exceeds INT_MAX; do the check ourselves.
11924
11925         Import the following changes from libc:
11926
11927         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
11928
11929         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
11930         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
11931         set wc to the byte which couldn't be converted.
11932         (re_string_reconstruct): Don't clear valid_raw_len before calling
11933         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
11934         tip_context using re_string_context_at.
11935
11936         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
11937
11938         * lib/posix/regex.h: g++ still cannot handled [restrict].
11939
11940         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
11941
11942         * lib/posix/regex.h: Remove special handling for VMS.
11943
11944 2006-08-10  Jim Meyering  <jim@meyering.net>
11945
11946         * modules/same-inode: New module.
11947         * modules/dev-ino: New module.
11948         * modules/cycle-check: Depend on these modules, rather than simply
11949         including their .h files.
11950         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
11951         required via m4/cycle-check.m4.
11952         * modules/same: Depend on new same-inode module, rather than
11953         including same-inode.h.
11954         * modules/chdir-safer: New file.
11955
11956         * modules/chown (Depends-on): Add stat-macros.
11957
11958 2006-08-10  Jim Meyering  <jim@meyering.net>
11959
11960         * m4/cycle-check.m4: New file.
11961         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
11962         * m4/dev-ino.m4, m4/same-inode.m4: New files.
11963
11964 2006-08-10  Eric Blake  <ebb9@byu.net>
11965
11966         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
11967         in from original proposal.
11968
11969 2006-08-10  Eric Blake  <ebb9@byu.net>
11970         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11971
11972         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
11973         namespace.
11974
11975 2006-08-10  Bruno Haible  <bruno@clisp.org>
11976
11977         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
11978         as well.
11979
11980 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
11981
11982         Sync from coreutils.
11983
11984         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
11985
11986         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
11987         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
11988
11989 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
11990
11991         * modules/restrict: Remove; no longer needed now that we assume
11992         Autoconf 2.59 or later.
11993         * MODULES.html.sh: Remove 'restrict'.
11994         * modules/argp (Depends-on): Remove 'restrict'.
11995         * modules/base64 (Depends-on): Likewise.
11996         * modules/gc (Depends-on): Likewise.
11997         * modules/getaddrinfo (Depends-on): Likewise.
11998         * modules/glob (Depends-on): Likewise.
11999         * modules/inet_ntop (Depends-on): Likewise.
12000         * modules/inet_pton (Depends-on): Likewise.
12001         * modules/memxor (Depends-on): Likewise.
12002         * modules/regex (Depends-on): Likewise.
12003         * modules/strtok_r (Depends-on): Likewise.
12004         * modules/time_r (Depends-on): Likewise.
12005
12006 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12007
12008         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
12009         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
12010         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12011         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
12012         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
12013         * m4/memxor.m4 (gl_MEMXOR): Likewise.
12014         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
12015         gl_C_RESTRICT replaced by AC_C_RESTRICT.
12016
12017         Merge from coreutils.
12018         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
12019         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
12020         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
12021         * m4/time_r.m4 (gl_TIME_R): Likewise.
12022
12023 2006-08-09  Karl Berry  <karl@gnu.org>
12024
12025         * config/srclist.txt: no more gettext-tools, per Bruno.
12026
12027 2006-08-08  Eric Blake  <ebb9@byu.net>
12028
12029         * modules/verror: New module.
12030         * MODULES.html.sh: Document it.
12031
12032 2006-08-08  Eric Blake  <ebb9@byu.net>
12033
12034         * lib/verror.h, lib/verror.c: New files.
12035
12036 2006-08-08  Eric Blake  <ebb9@byu.net>
12037
12038         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
12039         verror_at_line output complies with GNU Coding Standards even when
12040         file is NULL.
12041
12042 2006-08-07  Bruno Haible  <bruno@clisp.org>
12043
12044         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
12045         versions of AIX.
12046         Reported by Ralf Wildenhues.
12047
12048 2006-08-07  Bruno Haible  <bruno@clisp.org>
12049
12050         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
12051         in an AC_DEFUN. Needed so that the autoconf snippets can use
12052         AC_REQUIRE.
12053
12054 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12055
12056         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12057         Initialize pkgdata_DATA.
12058         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
12059         overriding it.
12060
12061 2006-08-06  Eric Blake  <ebb9@byu.net>
12062
12063         * lib/error.h: Fold in some upstream changes from glibc.
12064         * lib/error.c: Likewise.
12065
12066 2006-08-04  Bruno Haible  <bruno@clisp.org>
12067
12068         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12069         Make the mostlyclean-local rule depend on mostlyclean-generic.
12070         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
12071
12072 2006-07-31  Bruno Haible  <bruno@clisp.org>
12073
12074         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
12075         <stdlib.h>, <string.h>.
12076
12077 2006-07-30  Bruno Haible  <bruno@clisp.org>
12078
12079         * modules/readlink (License): Change to LGPL.
12080
12081 2006-07-30  Bruno Haible  <bruno@clisp.org>
12082
12083         * modules/javaversion (Makefile.am): Distribute javaversion.java and
12084         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
12085         set PKGDATADIR to point to it.
12086
12087 2006-07-30  Bruno Haible  <bruno@clisp.org>
12088
12089         * modules/csharpexec (configure.ac): Comment out macro invocation.
12090         * modules/javaexec (configure.ac): Likewise.
12091         * modules/javacomp-script (configure.ac): Likewise.
12092
12093         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
12094
12095 2006-07-30  Bruno Haible  <bruno@clisp.org>
12096
12097         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
12098         linked-list.
12099
12100 2006-07-30  Bruno Haible  <bruno@clisp.org>
12101
12102         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
12103
12104 2006-07-30  Bruno Haible  <bruno@clisp.org>
12105
12106         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12107         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
12108         get removed.
12109
12110 2006-07-29  Bruno Haible  <bruno@clisp.org>
12111
12112         Make it possible for gnulib-tool to work with locally modified or
12113         augmented gnulib repositories.
12114         * gnulib-tool (func_usage): Document --local-dir option.
12115         (local_gnulib_dir): New variable.
12116         Handle --local-dir option.
12117         (func_lookup_file): New function.
12118         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
12119         (func_get_description, func_get_filelist, func_get_description,
12120         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
12121         func_get_automake_snippet, func_get_include_directive,
12122         func_get_license, func_get_maintainer): Use func_lookup_file.
12123         (func_import, func_create_testdir): Use func_lookup_file.
12124
12125 2006-07-29  Bruno Haible  <bruno@clisp.org>
12126
12127         * modules/setenv (Depends-on): Add unistd.
12128
12129 2006-07-29  Bruno Haible  <bruno@clisp.org>
12130
12131         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
12132
12133 2006-07-29  Bruno Haible  <bruno@clisp.org>
12134
12135         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
12136
12137 2006-07-29  Bruno Haible  <bruno@clisp.org>
12138
12139         * gnulib-tool (import, update): If there is no Makefile.am, look at
12140         aclocal.m4, instead of bailing out.
12141
12142 2006-07-29  Bruno Haible  <bruno@clisp.org>
12143
12144         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
12145         Categorize the options by when they are useful.
12146
12147 2006-07-29  Bruno Haible  <bruno@clisp.org>
12148
12149         * gnulib-tool (func_usage): Document option --no-libtool.
12150         Handle option --no-libtool.
12151         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
12152         for changed semantics of $libtool variable.
12153         (func_import): Likewise. If libtool is not used, show this through
12154         an option --no-libtool.
12155         (func_create_testdir): Update.
12156
12157 2006-07-29  Bruno Haible  <bruno@clisp.org>
12158
12159         * gnulib-tool (func_import): Extend error message about missing
12160         --doc-base.
12161
12162 2006-07-29  Bruno Haible  <bruno@clisp.org>
12163
12164         * gnulib-tool (func_import): Don't create the $docbase directory if
12165         there is no file to store there.
12166
12167 2006-07-29  Bruno Haible  <bruno@clisp.org>
12168
12169         * gnulib-tool (autoconf_minversion): If a --dir option is given and
12170         relevant, look for configure.ac there, not in the current directory.
12171         Also use a simple search for AC_PREREQ, not "autoconf --trace".
12172
12173 2006-07-29  Bruno Haible  <bruno@clisp.org>
12174
12175         * gnulib-tool (SORT): New variable.
12176         (func_usage): Undocument --assume-autoconf option.
12177         Remove --assume-autoconf option handling.
12178         (autoconf_minversion): Determine from the contents of configure.ac.
12179         (func_import): Remove autoconf_minversion handling.
12180         Suggested by Eric Blake.
12181
12182 2006-07-29  Bruno Haible  <bruno@clisp.org>
12183
12184         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
12185
12186 2006-07-29  Bruno Haible  <bruno@clisp.org>
12187
12188         * config/srclist.txt (*setenv.[ch]): Remove rules.
12189
12190 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12191
12192         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
12193
12194 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12195
12196         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
12197         arpa/inet.h.
12198
12199 2006-07-28  Simon Josefsson  <jas@extundo.com>
12200
12201         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
12202         * modules/inet_pton (Depends-on): Likewise.
12203
12204 2006-07-28  Simon Josefsson  <jas@extundo.com>
12205
12206         * m4/netinet_in_h.m4: New file.
12207
12208 2006-07-28  Simon Josefsson  <jas@extundo.com>
12209
12210         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
12211         #include's.
12212
12213 2006-07-28  Simon Josefsson  <jas@extundo.com>
12214
12215         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
12216         #include's.
12217
12218 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
12219
12220         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
12221         setgid on directories only if they set these bits.
12222         * lib/modechange.h: Remove obsolete comment about masks.
12223
12224 2006-07-28  Eric Blake  <ebb9@byu.net>
12225
12226         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
12227         macro expansion.
12228
12229 2006-07-28  Bruno Haible  <bruno@clisp.org>
12230
12231         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
12232
12233 2006-07-28  Bruno Haible  <bruno@clisp.org>
12234
12235         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
12236
12237 2006-07-28  Bruno Haible  <bruno@clisp.org>
12238
12239         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
12240         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
12241         Define fallbacks.
12242         Avoids link error on FreeBSD 4.x.
12243         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12244
12245         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
12246         encoding.
12247         * lib/mbswidth.c (iswcntrl): Likewise.
12248
12249 2006-07-27  Bruno Haible  <bruno@clisp.org>
12250
12251         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
12252         test.
12253
12254 2006-07-27  Bruno Haible  <bruno@clisp.org>
12255
12256         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
12257         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
12258         defined.
12259
12260 2006-07-26  Eric Blake  <ebb9@byu.net>
12261
12262         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
12263
12264 2006-07-26  Eric Blake  <ebb9@byu.net>
12265
12266         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
12267         like mingw that lack mkstemp.
12268         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
12269         avoid compilation warning on mingw.
12270
12271 2006-07-26  Bruno Haible  <bruno@clisp.org>
12272
12273         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
12274         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
12275         INT_FAST*_MIN, INTPTR_MIN.
12276
12277 2006-07-25  Bruno Haible  <bruno@clisp.org>
12278
12279         * modules/version-etc (Depends-on): Add stdarg.
12280
12281 2006-07-25  Bruno Haible  <bruno@clisp.org>
12282
12283         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
12284         complex commands.
12285
12286 2006-07-25  Bruno Haible  <bruno@clisp.org>
12287
12288         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
12289         defined in <stdarg.h> or config.h.
12290
12291 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12292
12293         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
12294         (gl_STDIO_SAFER): Remove.
12295
12296 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12297
12298         * MODULES.html.sh (File stream based Input/Output):
12299         Add fopen-safer, tmpfile-safer; remove stdio-safer.
12300         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
12301         * modules/fopen-safer, modules/tmpfile-safer: New files.
12302         * modules/stdio-safer: Remove.
12303
12304 2006-07-24  Bruno Haible  <bruno@clisp.org>
12305
12306         * modules/tmpdir: New file.
12307         * MODULES.html.sh (File system functions): Add it.
12308
12309 2006-07-24  Bruno Haible  <bruno@clisp.org>
12310
12311         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
12312         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
12313
12314 2006-07-24  Bruno Haible  <bruno@clisp.org>
12315
12316         * modules/clean-temp: New file.
12317
12318 2006-07-24  Bruno Haible  <bruno@clisp.org>
12319
12320         * m4/tmpdir.m4: New file, from GNU gettext.
12321
12322 2006-07-24  Bruno Haible  <bruno@clisp.org>
12323
12324         * lib/tmpdir.h: New file, from GNU gettext.
12325         * lib/tmpdir.c: New file, from GNU gettext.
12326
12327 2006-07-24  Bruno Haible  <bruno@clisp.org>
12328
12329         * lib/clean-temp.h: New file, from GNU gettext.
12330         * lib/clean-temp.c: New file, from GNU gettext.
12331
12332 2006-07-23  Eric Blake  <ebb9@byu.net>
12333
12334         * modules/stdio-safer (Files): Add tmpfile-safer.c.
12335         (Depends-on): Add binary-io.
12336
12337 2006-07-23  Eric Blake  <ebb9@byu.net>
12338
12339         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
12340
12341 2006-07-23  Eric Blake  <ebb9@byu.net>
12342
12343         * lib/tmpfile-safer.c: New file.
12344         * lib/stdio-safer.h (fopen_safer): Add prototype.
12345         * lib/stdio--.h (tmpfile): Make safer.
12346
12347 2006-07-23  Bruno Haible  <bruno@clisp.org>
12348
12349         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
12350         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
12351         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
12352         gl_linked_remove_at): Use it.
12353
12354 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12355         and Simon Josefsson <jas@extundo.com>
12356
12357         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
12358
12359         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
12360
12361 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12362
12363         * modules/close-stream: New file.
12364         * modules/closeout (Description): Make it clear that it exits
12365         with a diagnostic on error.
12366         (Depends-on): Add close-stream.  Remove fpending, stdbool.
12367         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
12368
12369 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12370
12371         * m4/close-stream.m4: New file.
12372
12373 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12374
12375         * lib/close-stream.c, lib/close-stream.h: New files.
12376
12377 2006-07-22  Bruno Haible  <bruno@clisp.org>
12378
12379         Merge from GNU gettext 0.15.
12380
12381         2006-05-01  Bruno Haible  <bruno@clisp.org>
12382
12383                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
12384
12385         2006-07-22  Bruno Haible  <bruno@clisp.org>
12386
12387                 * modules/javaversion: New file.
12388                 * MODULES.html.sh (Java): Add javaversion.
12389
12390         2006-03-12  Bruno Haible  <bruno@clisp.org>
12391
12392                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
12393
12394         2005-12-04  Bruno Haible  <bruno@clisp.org>
12395
12396                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
12397                 (untested).
12398
12399         2006-06-21  Bruno Haible  <bruno@clisp.org>
12400
12401                 Avoid warnings from recent versions of mcs.
12402                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
12403                 -o, -L, -r any more. Use options documented since mcs-1.0
12404                 instead. Similarly for -g.
12405
12406         2005-12-04  Bruno Haible  <bruno@clisp.org>
12407
12408                 * build-aux/csharpcomp.sh.in: Suffix for resources is
12409                 .resources, not .resource.
12410
12411         2005-07-09  Bruno Haible  <bruno@clisp.org>
12412
12413                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
12414                 add a .dll suffix.
12415                 Reported by Mark Junker <mjscod@gmx.de>.
12416
12417         2006-07-22  Bruno Haible  <bruno@clisp.org>
12418
12419                 * modules/gettext: Upgrade to gettext-0.15.
12420                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
12421                 m4/visibility.m4.
12422                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
12423
12424 2006-07-22  Bruno Haible  <bruno@clisp.org>
12425
12426         Merge from GNU gettext 0.15.
12427
12428         2006-03-25  Bruno Haible  <bruno@clisp.org>
12429
12430                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
12431
12432         2006-07-21  Bruno Haible  <bruno@clisp.org>
12433
12434                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
12435                 "1.1".
12436
12437         2006-05-09  Bruno Haible  <bruno@clisp.org>
12438
12439                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
12440                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
12441                 for the conftestver execution.
12442
12443         2006-05-01  Bruno Haible  <bruno@clisp.org>
12444
12445                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
12446                 optional target-version argument. Verify that the compiler
12447                 groks source of the specified source-version, or add -source
12448                 option as necessary. Verify that the compiler produces
12449                 bytecode in the specified target-version, or add -target and
12450                 -source options as necessary. Make the result of the test
12451                 available as variable CONF_JAVAC. Also log error output in
12452                 config.log.
12453
12454         2006-03-11  Bruno Haible  <bruno@clisp.org>
12455
12456                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
12457
12458         2006-05-09  Bruno Haible  <bruno@clisp.org>
12459
12460                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
12461                 CLASSPATH_SEPARATOR to a semicolon.
12462
12463         2006-03-12  Bruno Haible  <bruno@clisp.org>
12464
12465                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
12466                 available as variable CONF_JAVA, for subsequent autoconf
12467                 tests. Also log error output in config.log.
12468
12469         2006-07-19  Bruno Haible  <bruno@clisp.org>
12470
12471                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
12472                 that getline works on glibc2 systems. Needed to avoid trouble
12473                 in relocatable.c.
12474                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
12475
12476         2005-12-04  Bruno Haible  <bruno@clisp.org>
12477
12478                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
12479                 launcher (untested).
12480
12481         2005-12-04  Bruno Haible  <bruno@clisp.org>
12482
12483                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
12484
12485         2006-07-22  Bruno Haible  <bruno@clisp.org>
12486
12487                 * gettext.m4: Update from GNU gettext-0.15.
12488                 * nls.m4: Likewise.
12489                 * po.m4: Likewise.
12490                 * inttypes-pri.m4: Likewise.
12491                 * inttypes-h.m4: Renamed from inttypes.m4.
12492                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
12493
12494 2006-07-22  Bruno Haible  <bruno@clisp.org>
12495
12496         Merge from GNU gettext 0.15.
12497
12498         2005-07-05  Bruno Haible  <bruno@clisp.org>
12499
12500                 * printf-args.c (printf_fetchargs): Work around broken
12501                 definition of wint_t on mingw.
12502
12503         2005-02-12  Bruno Haible  <bruno@clisp.org>
12504
12505                 * xallocsa.h: Add extern "C" for C++.
12506
12507         2006-05-17  Bruno Haible  <bruno@clisp.org>
12508
12509                 Cygwin portability.
12510                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
12511
12512         2006-04-30  Bruno Haible  <bruno@clisp.org>
12513
12514                 * progreloc.c: Include <mach-o/dyld.h> if available.
12515                 (find_executable): Use _NSGetExecutablePath when possible.
12516
12517         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
12518
12519                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
12520                 function.
12521
12522         2005-12-29  Bruno Haible  <bruno@clisp.org>
12523
12524                 * progreloc.c (set_program_name_and_installdir): Fix
12525                 compilation error.
12526
12527         2005-12-04  Bruno Haible  <bruno@clisp.org>
12528
12529                 Cygwin portability.
12530                 * progreloc.c: Include <windows.h> also on Cygwin.
12531                 (find_executable): Add support for Cygwin.
12532                 (set_program_name_and_installdir): Handle also platforms with
12533                 nonempty EXEEXT.
12534
12535         2006-07-11  Bruno Haible  <bruno@clisp.org>
12536
12537                 * javacomp.c: Fix a comment.
12538                 Reported by Jim Meyering.
12539
12540         2006-04-30  Bruno Haible  <bruno@clisp.org>
12541
12542                 * javacomp.h (compile_java_class): Add source_version,
12543                 target_version arguments.
12544                 * javacomp.c: Rewritten to choose only a compiler that
12545                 respects the specified source_version and target_version.
12546
12547         2006-06-27  Bruno Haible  <bruno@clisp.org>
12548
12549                 Assume correct S_ISDIR macro.
12550                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
12551
12552         2006-07-22  Bruno Haible  <bruno@clisp.org>
12553
12554                 * javaversion.h: New file, from GNU gettext.
12555                 * javaversion.c: New file, from GNU gettext.
12556                 * javaversion.java: New file, from GNU gettext.
12557                 * javaversion.class: New file, from GNU gettext.
12558
12559         2006-05-17  Bruno Haible  <bruno@clisp.org>
12560
12561                 Cygwin portability.
12562                 * javaexec.c (execute_java_class): Test for jview program
12563                 also on Cygwin.
12564
12565         2006-04-09  Bruno Haible  <bruno@clisp.org>
12566
12567                 * fatal-signal.c: Don't include string.h.
12568                 (at_fatal_signal): Use a copying loop instead of memcpy.
12569
12570         2005-12-04  Bruno Haible  <bruno@clisp.org>
12571
12572                 * csharpexec.c: Add support for 'clix' launcher (untested).
12573                 (execute_csharp_using_sscli): New function.
12574                 (execute_csharp_program): Call it.
12575
12576         2006-06-21  Bruno Haible  <bruno@clisp.org>
12577
12578                 Avoid warnings from recent versions of mcs.
12579                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
12580                 -o, -L, -r any more. Use options documented since mcs-1.0
12581                 instead. Similarly for -g.
12582
12583         2005-07-09  Bruno Haible  <bruno@clisp.org>
12584
12585                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
12586                 add a .dll suffix.
12587                 Reported by Mark Junker <mjscod@gmx.de>.
12588
12589         2006-06-17  Bruno Haible  <bruno@clisp.org>
12590
12591                 * config.charset: Update for NetBSD 3.0.
12592
12593         2006-05-17  Bruno Haible  <bruno@clisp.org>
12594
12595                 Cygwin portability.
12596                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
12597
12598         2006-05-16  Bruno Haible  <bruno@clisp.org>
12599
12600                 * localcharset.c [CYGWIN]: Include <windows.h>.
12601                 (get_charset_aliases): For Cygwin, return the same CPxxx
12602                 aliases list as under WIN32.
12603                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
12604                 the environment variables. Fall back to GetACP().
12605
12606         2006-04-05  Bruno Haible  <bruno@clisp.org>
12607
12608                 * config.charset: Update Juan Manuel Guerrero's address.
12609
12610         2005-02-12  Bruno Haible  <bruno@clisp.org>
12611
12612                 * allocsa.h: Add extern "C" for C++.
12613
12614         2005-02-10  Bruno Haible  <bruno@clisp.org>
12615
12616                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
12617                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
12618
12619         2006-07-22  Bruno Haible  <bruno@clisp.org>
12620
12621                 * gettext.h: Update to GNU gettext-0.15.
12622
12623 2006-07-22  Bruno Haible  <bruno@clisp.org>
12624
12625         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
12626         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
12627         lib-prefix.m4, longdouble.m4, ssize_t.m4.
12628
12629 2006-07-21  Eric Blake  <ebb9@byu.net>
12630
12631         * modules/stdlib-safer: New file.
12632         * MODULES.html.sh (File stream based Input/Output): Add
12633         stdlib-safer.
12634
12635 2006-07-21  Eric Blake  <ebb9@byu.net>
12636
12637         * lib/stdlib-safer.h: New file from coreutils, required by
12638         stdlib--.h.
12639
12640 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
12641
12642         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
12643
12644 2006-07-20  Bruno Haible  <bruno@clisp.org>
12645
12646         * gnulib-tool: Recognize new option --assume-autoconf.
12647         (autoconf_minversion): New variable.
12648         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
12649
12650 2006-07-20  Bruno Haible  <bruno@clisp.org>
12651
12652         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
12653
12654 2006-07-19  Derek R. Price  <derek@ximbiot.com>
12655
12656         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
12657         Reindent and repaginate.
12658
12659 2006-07-19  Derek Price  <derek@ximbiot.com>
12660
12661         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
12662         Correct grammar.
12663
12664 2006-07-17  Bruno Haible  <bruno@clisp.org>
12665
12666         * modules/list: New file.
12667         * modules/array-list: New file.
12668         * modules/carray-list, modules/carray-list-tests: New files.
12669         * modules/linked-list, modules/linked-list-tests: New files.
12670         * modules/avltree-list, modules/avltree-list-tests: New files.
12671         * modules/rbtree-list, modules/rbtree-list-tests: New files.
12672         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
12673         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
12674         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
12675         * modules/oset: New file.
12676         * modules/array-oset: New file.
12677         * modules/avltree-oset, modules/avltree-oset-tests: New files.
12678         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
12679         * tests/test-carray_list.c: New file.
12680         * tests/test-linked_list.c: New file.
12681         * tests/test-avltree_list.c: New file.
12682         * tests/test-rbtree_list.c: New file.
12683         * tests/test-linkedhash_list.c: New file.
12684         * tests/test-avltreehash_list.c: New file.
12685         * tests/test-rbtreehash_list.c: New file.
12686         * tests/test-avltree_oset.c: New file.
12687         * tests/test-rbtree_oset.c: New file.
12688         * MODULES.html.sh (Container data structures): New section.
12689
12690 2006-07-17  Bruno Haible  <bruno@clisp.org>
12691
12692         * m4/gl_list.m4: New file.
12693
12694 2006-07-17  Bruno Haible  <bruno@clisp.org>
12695
12696         * lib/gl_list.h: New file.
12697         * lib/gl_list.c: New file.
12698         * lib/gl_array_list.h: New file.
12699         * lib/gl_array_list.c: New file.
12700         * lib/gl_carray_list.h: New file.
12701         * lib/gl_carray_list.c: New file.
12702         * lib/gl_linked_list.h: New file.
12703         * lib/gl_linked_list.c: New file.
12704         * lib/gl_anylinked_list1.h: New file.
12705         * lib/gl_anylinked_list2.h: New file.
12706         * lib/gl_avltree_list.h: New file.
12707         * lib/gl_avltree_list.c: New file.
12708         * lib/gl_anyavltree_list1.h: New file.
12709         * lib/gl_anyavltree_list2.h: New file.
12710         * lib/gl_rbtree_list.h: New file.
12711         * lib/gl_rbtree_list.c: New file.
12712         * lib/gl_anyrbtree_list1.h: New file.
12713         * lib/gl_anyrbtree_list2.h: New file.
12714         * lib/gl_anytree_list1.h: New file.
12715         * lib/gl_anytree_list2.h: New file.
12716         * lib/gl_linkedhash_list.h: New file.
12717         * lib/gl_linkedhash_list.c: New file.
12718         * lib/gl_anyhash_list1.h: New file.
12719         * lib/gl_anyhash_list2.h: New file.
12720         * lib/gl_avltreehash_list.h: New file.
12721         * lib/gl_avltreehash_list.c: New file.
12722         * lib/gl_rbtreehash_list.h: New file.
12723         * lib/gl_rbtreehash_list.c: New file.
12724         * lib/gl_anytreehash_list1.h: New file.
12725         * lib/gl_anytreehash_list2.h: New file.
12726
12727         * lib/gl_oset.h: New file.
12728         * lib/gl_oset.c: New file.
12729         * lib/gl_array_oset.h: New file.
12730         * lib/gl_array_oset.c: New file.
12731         * lib/gl_avltree_oset.h: New file.
12732         * lib/gl_avltree_oset.c: New file.
12733         * lib/gl_rbtree_oset.h: New file.
12734         * lib/gl_rbtree_oset.c: New file.
12735         * lib/gl_anytree_oset.h: New file.
12736
12737 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
12738
12739         * m4/mkancesdirs.m4: New file.
12740         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
12741         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
12742         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
12743         it.
12744
12745 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
12746
12747         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
12748         * lib/mkancesdirs.h: New files.
12749         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
12750         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
12751         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
12752         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
12753         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
12754         callers changed.  Revamp internals significantly, by not
12755         attempting to create directories that are temporarily more
12756         permissive than the final results.  Do not attempt to use
12757         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
12758         This removes some race conditions, fixes some bugs, and simplifies
12759         things.  Use new dirchownmod function to do owner and mode changes.
12760         * lib/mkdir-p.h: Likewise.
12761         * lib/modechange.c (octal_to_mode): New function.
12762         (struct mode_change): New member mentioned.
12763         (make_node_op_equals): New arg mentioned.  All callers changed.
12764         (mode_compile): Keep track of which mode bits the user has explicitly
12765         mentioned.
12766         (mode_adjust): New arg DIR, so that we implement the X op correctly.
12767         New arg PMODE_BITS, to keep track of which mode bits the user
12768         mentioned; it treats S_ISUID and S_ISGID speciall.
12769         All callers changed.
12770         * lib/modechange.h: Likewise.
12771
12772 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
12773
12774         * MODULES.html.sh: Add mkancestors.
12775         * modules/mkancesdirs: New module.
12776         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
12777         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
12778         The chdir-safer and afs files are now orphans; I'll remove them
12779         unless someone speaks up.
12780         Add lib/dirchownmod.c, lib/dirchownmod.h.
12781         (Depends-on): Remove alloca, chown, save-cwd, dirname.
12782         Add lchown, mkancesdirs.
12783         (Maintainer): Add self.
12784
12785 2006-07-15  Karl Berry  <karl@gnu.org>
12786
12787         * gnulib-tool: help message wording/arrangement.
12788
12789 2006-07-14  Simon Josefsson  <jas@extundo.com>
12790
12791         * doc/gnulib.texi (Libtool and Windows): New section.
12792
12793 2006-07-12  Simon Josefsson  <jas@extundo.com>
12794
12795         * modules/gendocs (License): Fix license, approved by Karl.
12796
12797 2006-07-12  Eric Blake  <ebb9@byu.net>
12798
12799         * MODULES.html.sh: Add gendocs.
12800
12801 2006-07-11  Eric Blake  <ebb9@byu.net>
12802
12803         * modules/fdl: New module, to install doc/fdl.texi.
12804         * MODULES.html.sh: Add new section for documentation modules.
12805         * gnulib-tool: Avoid space-tab.
12806         (--doc-base): New option, to manage files from doc.
12807
12808 2006-07-11  Eric Blake  <ebb9@byu.net>
12809
12810         * m4/absolute-header.m4: Fix comments to match recent change.
12811
12812 2006-07-11  Eric Blake  <ebb9@byu.net>
12813
12814         * gnulib-tool: List --doc-base before --tests-base.
12815
12816 2006-07-11  Derek R. Price  <derek@ximbiot.com>
12817
12818         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
12819
12820 2006-07-11  Bruno Haible  <bruno@clisp.org>
12821
12822         * README: Mention where to put documentation.
12823
12824 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12825
12826         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
12827
12828 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
12829
12830         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
12831         to stdint.m4.
12832
12833 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
12834
12835         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
12836         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
12837         "no/such/file/stdint.h" when there is no such file, so that
12838         the resulting C code can be parsed by dodgy compilers.
12839         Problems reported by Bob Proulx.
12840
12841 2006-07-10  Derek R. Price  <derek@ximbiot.com>
12842
12843         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
12844         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
12845         macros into the GNU _D_EXACT_NAMLEN.
12846         * lib/savedir.c:  Likewise.
12847         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
12848
12849 2006-07-10  Derek R. Price  <derek@ximbiot.com>
12850         and Paul Eggert  <eggert@cs.ucla.edu>
12851
12852         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
12853         * m4/savedir.m4:
12854         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
12855         macros into the GNU _D_EXACT_NAMLEN.
12856
12857 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12858
12859         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
12860         around the absolute name, to work around a problem with the HP-UX
12861         11.23 native C compiler, reported by Bob Proulx.
12862
12863 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12864
12865         * doc/maintain.texi, make-stds.texi: Sync from
12866         <http://savannah.gnu.org/projects/gnustandards>.
12867
12868 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12869
12870         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
12871
12872 2006-07-09  Jim Meyering  <jim@meyering.net>
12873
12874         * m4/glob.m4: Remove a doubled word in a comment.
12875
12876 2006-07-09  Jim Meyering  <jim@meyering.net>
12877
12878         * lib/argp-pv.c: Remove a doubled word in a comment.
12879         * lib/check-version.c (check_version): Likewise.
12880         * lib/javacomp.c (compile_java_class): Likewise.
12881
12882 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
12883
12884         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
12885         for the benefit of people using Autoconf 2.60.  If you want to
12886         support older Autoconf versions you can copy m4/onceonly_2_57.m4
12887         (or m4/onceonly.m4, if pre-2.57) manually.
12888
12889 2006-07-08  Jim Meyering  <jim@meyering.net>
12890
12891         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
12892         comment.
12893         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
12894         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
12895         comment.
12896
12897 2006-07-08  Jim Meyering  <jim@meyering.net>
12898
12899         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
12900
12901 2006-07-07  Simon Josefsson  <jas@extundo.com>
12902
12903         * tests/test-crc.c: Change expected crc value, the test vector
12904         were probably computed using the old broken crc.c?
12905
12906 2006-07-06  Simon Josefsson  <jas@extundo.com>
12907
12908         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
12909         now the canonical place for the M4 file).
12910
12911         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
12912         from the sys_socket dependency now.
12913
12914         * modules/inet_pton (Files): Ditto.
12915
12916         * modules/inet_ntop (Files): Ditto.
12917
12918 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
12919
12920         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
12921         not gl_PREREQ_GETUSERSHELL.
12922
12923 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12924
12925         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
12926         with only one argument, for Autoconf 2.60.
12927         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
12928         expand to nothing, so add a shell command to avoid syntax error.
12929         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
12930
12931 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12932
12933         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
12934
12935 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12936
12937         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
12938         no longer needed.  Check for isblank decl.
12939         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
12940         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
12941         of existence.
12942
12943 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12944
12945         * lib/getloadavg.c: Use __VMS, not VMS.
12946         * lib/getopt.c: Likewise.
12947         * lib/getpagesize.h: Likewise.
12948         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
12949         and probably does not work.
12950
12951 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12952
12953         * lib/.cppi-disable: Add wcwidth.
12954         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
12955         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
12956         (ISGRAPH): Remove.  All uses changed to isgraph.
12957         (FOLD) [!defined _LIBC]: Remove special case.
12958         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
12959         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
12960         HAVE_ISBLANK.
12961         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
12962         case.
12963
12964 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
12965
12966         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
12967         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
12968         brackets.  Other minor changes to suppress some compiler
12969         warnings.
12970
12971 2006-07-06  Derek R. Price  <derek@ximbiot.com>
12972         and Paul Eggert  <eggert@cs.ucla.edu>
12973
12974         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
12975         of invoking obsolescent AC_HEADER_DIRENT macro.
12976         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
12977         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
12978         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
12979         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
12980         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
12981         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12982         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
12983         * m4/readdir.m4: Remove; no longer needed.
12984
12985 2006-07-06  Derek R. Price  <derek@ximbiot.com>
12986         and Paul Eggert  <eggert@cs.ucla.edu>
12987
12988         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
12989         Don't worry about this obsolete case any more.
12990         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
12991         directories.
12992         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
12993         worry about this obsolete case any more.
12994         * lib/fts.c: Likewise.
12995         * lib/getcwd.c: Likewise.
12996         * lib/glob.h: Likewise.
12997         * lib/savedir.c: Likewise.
12998
12999 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13000
13001         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
13002         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
13003         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
13004         needed.
13005         All uses removed.
13006         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13007         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13008         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
13009         needed.
13010         * m4/getdate.m4 (gl_GETDATE): Likewise.
13011         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13012         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13013         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13014         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13015         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13016         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13017         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
13018         needed.
13019
13020 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13021
13022         * lib/memcasecmp.c: Include <limits.h>.
13023         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
13024         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
13025         Don't assume isdigit succeeds only on '0' through '9'.
13026
13027 2006-07-05  Eric Blake  <ebb9@byu.net>
13028
13029         * modules/getaddrinfo (Depends-on): Add snprintf.
13030
13031 2006-07-05  Eric Blake  <ebb9@byu.net>
13032
13033         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
13034         to avoid 'header present but could not be compiled' on cygwin.
13035
13036 2006-07-05  Eric Blake  <ebb9@byu.net>
13037
13038         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
13039         missing from netdb.h.
13040         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
13041
13042 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13043
13044         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
13045         no longer needed.
13046         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
13047         * m4/getdate.m4 (gl_GETDATE): Likewise.
13048         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13049         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13050         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13051         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13052         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13053
13054 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13055
13056         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
13057         All uses of is_space replaced by isspace.
13058         * lib/exit.h: Don't talk about STDC_HEADERS.
13059         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
13060         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
13061         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
13062         replaced by isprint etc.
13063         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
13064         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13065         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
13066         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
13067         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
13068         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13069
13070 2006-07-05  Bruno Haible  <bruno@clisp.org>
13071
13072         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
13073         the function exists, before testing against AIX.
13074         Reported by Martin Lambers <marlam@marlam.de>.
13075
13076 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13077
13078         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
13079         From Mark D. Baushke.
13080
13081 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13082
13083         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
13084         to the absolute name, not just one, to bypass Sun C 5.8's
13085         "warning: #include of /usr/include/... may be non-portable".
13086
13087 2006-07-04  Eric Blake  <ebb9@byu.net>
13088
13089         * modules/dirname-tests: New test module.
13090         * tests/test-dirname.c: New file, replacing dirname.c
13091         TEST_DIRNAME section that was recently deleted.
13092
13093 2006-07-04  Bruno Haible  <bruno@clisp.org>
13094
13095         Assume ANSI C header files and <ctype.h> functions.
13096         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
13097         (mbsnwidth): Use isprint, iscntrl instead.
13098
13099 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13100
13101         Merge from coreutils.
13102         * MODULES.html.sh: Add xstrtold.
13103         * modules/xstrtold: New file.
13104         * modules/cycle-check (Files): Add lib/same-inode.h.
13105         * modules/dirname (Files): Add m4/double-slash-root.m4.
13106         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
13107         * modules/mkdir-p (Files): Add lib/same-inode.h.
13108         * modules/same (Files): Add lib/same-inode.h.
13109
13110 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13111
13112         * m4/absolute-header.m4: Renamed from full-header-path.m4.
13113         This is to keep the terminology clean; POSIX talks about
13114         "absolute pathnames", not "full pathnames", but the GNU
13115         Coding Standards say to use "path" for something else;
13116         so use "absolute" to keep both sides happy.
13117         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
13118         Set gl_absolute_header, not gl_full_header_path.
13119         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
13120         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
13121         All uses changed.
13122
13123         Merge from coreutils.
13124
13125         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13126
13127         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
13128         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
13129         want to require the building of c-strtod.o.
13130         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
13131         needs -lm directly.
13132         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
13133
13134         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13135
13136         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
13137         --as-needed option if available.  Problem reported by Albert Chin in
13138         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
13139         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
13140         cc merely issues a bunch of annoying warnings for --as-needed
13141         (this problem was reported by Bob Proulx).  Also, try linking with
13142         -lm to detect a bug in binutils 2.16 (this problem was reported
13143         by Ralf Wildenhues).
13144
13145         2006-06-18  Jim Meyering  <jim@meyering.net>
13146
13147         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
13148         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
13149         macro.
13150         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
13151         also check for glibc-2.4's abort-inducing bug.
13152
13153         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
13154         Low-probability clean-up should be to use rmdir to get rid of
13155         the just-created directory, not unlink.
13156
13157         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
13158         configure fail, and request a bug report to inform us about it.
13159         Add a comment that, barring reports to the contrary, in 2007 we'll
13160         assume ftruncate is universally available.
13161
13162         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13163
13164         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
13165
13166         2006-03-12  Jim Meyering  <jim@meyering.net>
13167
13168         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
13169         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
13170         * m4/same.m4 (gl_SAME): Likewise.
13171         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
13172
13173         2006-03-11  Eric Blake  <ebb9@byu.net>
13174
13175         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
13176         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
13177         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
13178         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
13179
13180 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13181
13182         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
13183         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
13184         reported by Mark D. Baushke, one in
13185         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
13186
13187         Merge from coreutils.
13188
13189         * lib/.cppi-disable: Add stdint_.h.
13190         * lib/.cvsignore: Add stdint.h.
13191
13192         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13193
13194         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
13195         both double and long double versions.
13196         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
13197         * lib/xstrtold.c: New file.
13198         * lib/xstrtod.h (xstrtold): New decl.
13199
13200         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
13201
13202         * lib/filemode.c (setst): Remove.
13203         (strmode): Rewrite to avoid setst.  This makes the code shorter,
13204         (arguably) clearer, and the generated code is a bit smaller on my
13205         Debian GNU/Linux stable x86 host.
13206
13207         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13208
13209         * lib/filemode.c: Include "filemode.h" first, to test the interface.
13210         Assume that filemode.h includes sys/types.h and sys/stat.h.
13211         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
13212         (ftypelet): Reorder to put common cases first, for efficiency.
13213         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
13214         to do 'M'.
13215         (strmode): Renamed from mode_string, and now stores 12 bytes instead
13216         of 10, for compatibility with FreeBSD.  All callers changed.
13217         (filemodestring): Now stores 12 bytes instead of 10, and sets file
13218         types that can't be deduced solely from st_mode.  First arg is now a
13219         const pointer.
13220         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
13221         (strmode): Renamed from mode_string.
13222         (filemodestring): New decl.
13223         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
13224         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
13225         needed.
13226         (S_ISPORT, S_ISWHT): New macros, if not already defined.
13227
13228         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
13229
13230         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
13231         fsusage.h now does that.  Include fsusage.h first, to test interface.
13232         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
13233         at most one method (the old code could have generated decls that
13234         didn't conform to C89, not that this was ever exercised).
13235         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
13236
13237         2006-03-19  Jim Meyering  <jim@meyering.net>
13238
13239         Work even in a chroot where d_ino values for entries in "/"
13240         don't match the stat.st_ino values for the same names.
13241         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
13242         number, iterate through all entries again, using lstat instead.
13243         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
13244         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
13245
13246         * lib/getcwd.c (__getcwd): Clarify a comment.
13247         Use memcpy in place of a call to strcpy.
13248
13249         2006-03-12  Jim Meyering  <jim@meyering.net>
13250
13251         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
13252         matches that of the current directory (which we're about to chdir ".."
13253         out of), then save the dev-ino of the parent, instead.
13254
13255         * lib/same-inode.h (SAME_INODE): New file/macro.
13256         * lib/chdir-safer.c (SAME_INODE): Remove definition.
13257         Include "same-inode.h", instead.
13258         * lib/same.c: Likewise.
13259         * lib/cycle-check.h: Include "same-inode.h".
13260         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
13261         * lib/cycle-check.c (SAME_INODE): Remove definition.
13262         * lib/root-dev-ino.h: Include "same-inode.h".
13263
13264         2006-03-11  Eric Blake  <ebb9@byu.net>
13265
13266         * lib/same.c (same_name): s/base_name/last_component/
13267         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
13268         * lib/filenamecat.c (file_name_concat): Likewise.
13269
13270         2006-03-11  Eric Blake  <ebb9@byu.net>,
13271                     Paul Eggert  <eggert@cs.ucla.edu>
13272
13273         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
13274         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
13275         drive prefix.
13276         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
13277         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
13278         (last_component): New method.
13279         * lib/dirname.c (dir_len): Determine when drive letters need a
13280         subsequent slash.  Preserve // when it is special.
13281         (dir_name): Don't append dot when drive letter is absolute.
13282         [TEST_DIRNAME]: Move into a full-blown gnulib test.
13283         * lib/basename.c (base_name): New semantics - malloc the result.
13284         Preserve // when it is special.  Preserve relative files that look
13285         like drive letters.
13286         (base_len): Preserve // when it is special.
13287         (last_component): New method, similar to old base_name semantics.
13288         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
13289         base_name.  Strip redundant slashes from ///.
13290
13291 2006-07-03  Jim Meyering  <jim@meyering.net>
13292
13293         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
13294         macro is used before the first cycle_check call.
13295
13296 2006-07-03  Eric Blake  <ebb9@byu.net>
13297
13298         * modules/dirname (Depends-on): Add xstrndup.
13299
13300 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13301
13302         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
13303         test cases, so that config.log is a bit easier to follow.
13304
13305 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13306
13307         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
13308         both are 64 bits, since this seems to be the tradition, and this
13309         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
13310         we ever run into a host that prefers long long to long in this
13311         case, we'll need another configure-time test.  Problem reported by
13312         Jim Meyering.
13313
13314 2006-07-02  Eric Blake  <ebb9@byu.net>
13315
13316         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
13317
13318 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13319
13320         * modules/inttypes (Depends-on): No longer depends on stdint.
13321         * modules/stdint (Description): Say more about assumptions.
13322         Say that the fast types might differ.  Say macros are used.
13323         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
13324         (Makefile.am): Revise list of substituted symbols to match
13325         new stdint.m4.
13326         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
13327         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
13328         * tests/test-stdint.c (verify_same_types)
13329         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
13330         the code conforms to C99/C89.
13331         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
13332         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
13333
13334 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13335
13336         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
13337         but fix a bug, by requiring at least 64 bits.
13338         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
13339         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
13340         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
13341         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
13342
13343         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
13344         changes.  Make 2.59 a prerequisite.  Check and substitute for
13345         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
13346         inttypes.h.  Do not use special include files; just use the
13347         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
13348         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
13349         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
13350         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
13351         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
13352         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
13353         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
13354         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
13355         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
13356         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
13357         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
13358         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
13359         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
13360         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
13361         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
13362         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
13363         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
13364         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
13365         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
13366         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
13367         WINT_MAX.  Check for C99 conformance more strictly, by detecting
13368         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
13369         not check for things that C99 does not require, e.g., int8_t.  If
13370         a test isn't needed unless <stdint.h> isn't working, and is
13371         unlikely to be needed for any other reason, then don't do it
13372         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
13373         size_t, since we assume C89 freestanding at least.  Do not check
13374         for sig_atomic_t, wchar_t, or wint_t, since the code now does
13375         the right thing even if the types are not defined.  Instead use:
13376         (gl_STDINT_TYPE_PROPERTIES): New macro.
13377         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
13378         testing whether <sys/types.h> clashes, as Autoconf does this for
13379         us now.  All uses removed.
13380         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
13381         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
13382         (gl_CHECK_TYPE_SAME):
13383         Remove; no longer needed.
13384         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
13385         exists, since we'll return 0 anyway in that case.
13386         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
13387
13388 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13389
13390         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
13391         possible collision with system files.
13392         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
13393         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
13394         WCHAR_MIN and WCHAR_MAX in this case.
13395         (<stddef.h>): Do not include; no longer needed.
13396         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
13397         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
13398         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
13399         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
13400         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
13401         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
13402         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
13403         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
13404         !defined(__c99))]: Include in this case too, since it's harmless
13405         now.
13406         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
13407         dangerous to do so.
13408         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
13409         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
13410         (_STDINT_MIN, _STDINT_MAX): New macros.
13411         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
13412         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
13413         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
13414         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
13415         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
13416         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
13417         macros, not typedefs; this simplifies things quite a bit.
13418         Use long int for all types narrower than int64_t.
13419         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
13420         Define in terms of long long int or int64_t or long int,
13421         not int64_t or int32_t.  This saves some compile-time testing.
13422         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
13423         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
13424         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
13425         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
13426         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
13427         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
13428         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
13429         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
13430         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
13431         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
13432         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13433         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13434         undef any previous version and define our own version, for
13435         simplicity and consistency with the new macros for types.
13436         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13437         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13438         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
13439         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
13440         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
13441         @WINT_T_SUFFIX@ to keep things simple here.
13442         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
13443         Simplify by assuming typical 8/16/32/64 host, since we're
13444         already doing that elsewhere anyway.
13445         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
13446         and assume long long int is 64 bits if available.  This
13447         speeds up 'configure'.
13448
13449 2006-07-01  Eric Blake  <ebb9@byu.net>
13450
13451         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
13452         Reported by Andreas Buening.
13453
13454 2006-07-01  Eric Blake  <ebb9@byu.net>
13455
13456         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
13457
13458 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13459
13460         * lib/getaddrinfo.c: fixed typo
13461
13462 2006-06-29  Jim Meyering  <jim@meyering.net>
13463
13464         * modules/strftime (Maintainer): Add my name, since with the
13465         FPRINTFTIME changes strftime.c has forked from glibc.
13466
13467 2006-06-29  Eric Blake  <ebb9@byu.net>
13468
13469         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
13470
13471 2006-06-29  Eric Blake  <ebb9@byu.net>
13472
13473         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
13474
13475 2006-06-29  Eric Blake  <ebb9@byu.net>
13476
13477         * lib/stat_.h: New file.
13478
13479 2006-06-29  Eric Blake  <ebb9@byu.net>
13480
13481         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
13482         unused static function.
13483
13484 2006-06-29  Eric Blake  <ebb9@byu.net>
13485
13486         * doc/functions.texi (Function Portability): Document missing lstat
13487         on mingw.
13488
13489 2006-06-29  Eric Blake  <ebb9@byu.net>
13490
13491         * MODULES.html.sh: Add sys_stat.
13492         * modules/sys_stat: New module.
13493         * modules/mkstemp (Depends-on): Add sys_stat.
13494
13495 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13496
13497         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
13498
13499 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13500
13501         * m4/c-bs-a.m4: Removed.
13502
13503 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13504
13505         * lib/strftime.c: Assume strftime() exists.
13506
13507 2006-06-29  Derek Price  <derek@ximbiot.com>
13508
13509         * modules/c-bs-a: Removed - \a is C89.
13510         * MODULES.html.sh: Remove c-bs-a.
13511
13512 2006-06-29  Bruno Haible  <bruno@clisp.org>
13513
13514         * modules/wcwidth (License): Change to LGPL.
13515
13516 2006-06-28  Simon Josefsson  <jas@extundo.com>
13517
13518         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
13519         on _WIN32.
13520
13521         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
13522         getnameinfo.
13523
13524 2006-06-28  Simon Josefsson  <jas@extundo.com>
13525
13526         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
13527
13528 2006-06-28  Simon Josefsson  <jas@extundo.com>
13529
13530         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
13531         functions there.  It will succeed on Windows XP, but on Windows
13532         2000 and (presumably) earlier, it will fail, and use the internal
13533         re-implementation.
13534         (use_win32_p): New function.
13535         (getaddrinfo): Use strtoul on servname, to support numeric ports.
13536         Support AI_NUMERICSERV to disable getservbyname.
13537         (getnameinfo): New function, only supports
13538         NI_NUMERICHOST|NI_NUMERICSERV for now.
13539
13540         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
13541         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
13542         getnameinfo.
13543
13544 2006-06-28  Eric Blake  <ebb9@byu.net>
13545
13546         * modules/wcwidth: New file.
13547         * modules/mbchar (Depends-on): Add wcwidth.
13548         * modules/mbswidth (Depends-on): Add wcwidth.
13549         * MODULES.html.sh: Add wcwidth.
13550
13551 2006-06-28  Eric Blake  <ebb9@byu.net>
13552
13553         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
13554         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
13555
13556 2006-06-28  Eric Blake  <ebb9@byu.net>
13557
13558         * lib/xvasprintf.h: Fix comments.
13559
13560 2006-06-28  Eric Blake  <ebb9@byu.net>
13561
13562         * lib/mbchar.h (wcwidth): Include wcwidth.h.
13563         * lib/mbswidth.c (wcwidth): Move from here...
13564         * lib/wcwidth.h: ...to this new file.
13565
13566 2006-06-28  Derek R. Price  <derek@ximbiot.com>
13567
13568         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
13569
13570         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
13571         it's obsolete.
13572         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
13573
13574 2006-06-28  Derek R. Price  <derek@ximbiot.com>
13575
13576         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
13577         Autoconf 2.60 says this stuff was obsolete.
13578
13579 2006-06-28  Bruno Haible  <bruno@clisp.org>
13580
13581         * modules/wcwidth (Files): Add m4/wchar_t.m4.
13582
13583 2006-06-28  Bruno Haible  <bruno@clisp.org>
13584
13585         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
13586         gt_TYPE_WCHAR_T.
13587
13588 2006-06-28  Bruno Haible  <bruno@clisp.org>
13589
13590         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
13591         declaration for wcwidth.
13592         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
13593
13594 2006-06-28  Bruno Haible  <bruno@clisp.org>
13595
13596         * lib/mkdtemp.c [MINGW]: Include <io.h>.
13597         (mkdir): Define using _mkdir.
13598
13599 2006-06-28  Bruno Haible  <bruno@clisp.org>
13600
13601         * lib/getaddrinfo.h: Fix POSIX URL.
13602         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
13603         _WIN32.
13604         (use_win32_p): Make static.
13605         (getaddrinfo): Reject service name if it is empty or does not consist
13606         solely of decimal digits, or if its value is > 65535.
13607         (getnameinfo): Remove useless casts.
13608
13609 2006-06-27  Simon Josefsson  <jas@extundo.com>
13610
13611         * modules/sys_select: New file, suggested by Bruno Haible, Paul
13612         Eggert and Martin Lambers.
13613
13614 2006-06-27  Simon Josefsson  <jas@extundo.com>
13615
13616         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
13617         Eggert and Martin Lambers.
13618
13619 2006-06-27  Bruno Haible  <bruno@clisp.org>
13620
13621         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
13622         result to 0, not to empty.
13623         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
13624
13625 2006-06-27  Bruno Haible  <bruno@clisp.org>
13626
13627         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
13628
13629 2006-06-26  Simon Josefsson  <jas@extundo.com>
13630
13631         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
13632         present.
13633
13634 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
13635
13636         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
13637         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
13638         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
13639
13640 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
13641
13642         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
13643
13644 2006-06-26  Bruno Haible  <bruno@clisp.org>
13645
13646         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
13647
13648 2006-06-26  Bruno Haible  <bruno@clisp.org>
13649
13650         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
13651
13652 2006-06-26  Bruno Haible  <bruno@clisp.org>
13653
13654         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
13655         SGI C compiler in pre-C99 mode.
13656         Suggested by Mark D. Baushke and Larry Jones.
13657
13658 2006-06-26  Bruno Haible  <bruno@clisp.org>
13659
13660         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
13661         WCHAR_MAX.
13662         Reported by Mark D. Baushke and Larry Jones.
13663
13664 2006-06-26  Bruno Haible  <bruno@clisp.org>
13665
13666         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
13667         in pre-C99 mode.
13668         Suggested by Mark D. Baushke and Larry Jones.
13669
13670 2006-06-23  Simon Josefsson  <jas@extundo.com>
13671             Bruno Haible  <bruno@clisp.org>
13672
13673         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
13674         Emit mostlyclean-local rule.
13675         (func_emit_tests_Makefile_am): Likewise.
13676         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
13677
13678 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
13679
13680         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
13681
13682 2006-06-23  Bruno Haible  <bruno@clisp.org>
13683
13684         * tests/test-stdint.c: Update to match ISO C 99 Technical
13685         Corrigendum 1.
13686
13687 2006-06-23  Bruno Haible  <bruno@clisp.org>
13688
13689         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
13690
13691 2006-06-23  Bruno Haible  <bruno@clisp.org>
13692
13693         * lib/stdint_.h: Treat IRIX like OpenBSD.
13694
13695 2006-06-23  Bruno Haible  <bruno@clisp.org>
13696
13697         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
13698         ISO C 99 Technical Corrigendum 1.
13699
13700 2006-06-22  Simon Josefsson  <jas@extundo.com>
13701
13702         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
13703         MinGW.
13704
13705 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
13706
13707         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
13708         needed.  Some compiler complained about some of them.  Problem reported
13709         by Larry Jones in
13710         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
13711
13712 2006-06-21  Simon Josefsson  <jas@extundo.com>
13713
13714         * tests/test-getaddrinfo.c: New file.
13715
13716         * modules/getaddrinfo-tests: New file.
13717
13718         * MODULES.html.sh: Add inet_pton.
13719
13720         * modules/inet_pton: New file.
13721
13722 2006-06-21  Simon Josefsson  <jas@extundo.com>
13723
13724         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
13725         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
13726         of using the (limited) gnulib implementation on Windows XP.
13727
13728         * m4/inet_pton.m4: New file.
13729
13730 2006-06-21  Simon Josefsson  <jas@extundo.com>
13731
13732         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
13733         variable.
13734
13735         * lib/socket_.h: Don't define WINVER.
13736
13737         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
13738         slightly modified to work in gnulib.
13739
13740 2006-06-21  Simon Josefsson  <jas@extundo.com>
13741
13742         * doc/gnulib.texi (Windows sockets): Add.
13743
13744 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
13745
13746         * lib/read-file.c (fread_file): Start with buffer allocation of
13747         0 bytes rather than 1 byte; this simplifies the code.
13748         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
13749         code to free buffer and save/restore errno.
13750         (internal_read_file): Remove unused local.
13751
13752 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
13753
13754         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
13755         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
13756         Problem reported by Denis Excoffier in
13757         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
13758
13759 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13760
13761         * modules/sys_socket, modules/socklen: Include sys/types since
13762         FreeBSD 4.x's sys/socket.h needs it.
13763
13764 2006-06-19  Simon Josefsson  <jas@extundo.com>
13765
13766         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
13767
13768 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13769
13770         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
13771
13772 2006-06-19  Bruno Haible  <bruno@clisp.org>
13773
13774         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
13775         and FULL_PATH_INTTYPES_H in angle brackets.
13776         Reported by Mark D. Baushke <mdb@gnu.org>.
13777
13778 2006-06-17  Eric Blake  <ebb9@byu.net>
13779
13780         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
13781         errno.
13782
13783 2006-06-17  Bruno Haible  <bruno@clisp.org>
13784
13785         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
13786         <sys/inttypes.h>.
13787
13788 2006-06-17  Bruno Haible  <bruno@clisp.org>
13789
13790         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
13791         whether errno is declared. Assume <errno.h> declares errno.
13792
13793 2006-06-17  Bruno Haible  <bruno@clisp.org>
13794
13795         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
13796
13797 2006-06-17  Bruno Haible  <bruno@clisp.org>
13798
13799         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
13800         problem on Solaris 2.5.1.
13801
13802 2006-06-16  Eric Blake  <ebb9@byu.net>
13803
13804         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
13805         * lib/unicodeio.c [!defined errno]: Likewise.
13806         * lib/strtol.c [!defined errno]: Likewise.
13807         * lib/strtod.c [!defined errno]: Likewise.
13808
13809 2006-06-15  Eric Blake  <ebb9@byu.net>
13810
13811         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
13812
13813 2006-06-15  Eric Blake  <ebb9@byu.net>
13814
13815         * config/srclist.txt (ssize_t.m4): Lose sync.
13816
13817 2006-06-15  Bruno Haible  <bruno@clisp.org>
13818
13819         * modules/stdint (Files): Include m4/full-header-path.m4,
13820         m4/size_max.m4, m4/wchar_t.m4.
13821         (Makefile.am): Many more substitutions.
13822         * modules/stdint-tests: New file.
13823         * tests/test-stdint.c: New file.
13824
13825 2006-06-15  Bruno Haible  <bruno@clisp.org>
13826
13827         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
13828         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
13829         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
13830         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
13831         gl_CHECK_TYPE_SAME): New macros.
13832
13833 2006-06-15  Bruno Haible  <bruno@clisp.org>
13834
13835         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
13836
13837 2006-06-15  Bruno Haible  <bruno@clisp.org>
13838
13839         * lib/stdint_.h: Rewritten to be fully auto-configured.
13840         Fixes bug on HP-UX/IA64.
13841
13842 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
13843
13844         * lib/getdate.y (__attribute__): Don't define if already defined.
13845         Problem reported by Larry Jones.
13846         * lib/utimens.c (__attribute__): Likewise.
13847
13848 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
13849
13850         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
13851         reported by Andreas Schwab.
13852
13853 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13854             Bruno Haible  <bruno@clisp.org>
13855
13856         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
13857         check for the declaration of strnlen and a run test that exposes the
13858         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
13859         rpl_strndup.
13860
13861 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13862             Bruno Haible  <bruno@clisp.org>
13863
13864         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
13865
13866 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13867
13868         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
13869         compile test, for Tru64 4.0D.
13870
13871 2006-05-28  Karl Berry  <karl@gnu.org>
13872
13873         * config/srclist.txt (printf-args.c): lose sync.
13874
13875 2006-05-26  Martin Lambers  <marlam@marlam.de>
13876
13877         * lib/getpass.c: Updates the test for the native W32 API, and adds
13878         missing includes, thus fixing compilation warnings.
13879
13880 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
13881
13882         * lib/exclude.c (exclude_fnmatch): New function.
13883         (excluded_file_name): Call exclude_fnmatch.
13884         * lib/exclude.h (excluded_file_name): New prototype
13885
13886 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
13887
13888         * lib/tempname.c (small_open, large_open): New macros.
13889         (__open, __open64) [!_LIBC]: Remove.
13890         (__gen_tempname): Use small_open and large_open instead of __open
13891         and __open64.  This fixes a portability bug on HP-UX 11.11i
13892         reported by Simon Wing-Tang in
13893         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
13894
13895 2006-05-24  Bruno Haible  <bruno@clisp.org>
13896
13897         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
13898         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
13899         Reported by Thorsten Maerz <torte@netztorte.de> via
13900         Aaron Stone <aaron@serendipity.cx>.
13901
13902 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
13903
13904         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
13905         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
13906         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
13907         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
13908         not really conditional on the cache.
13909         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
13910
13911 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
13912
13913         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
13914         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
13915         (my_usleep): Don't mishandle maximum value.
13916
13917 2006-05-19  Jim Meyering  <jim@meyering.net>
13918
13919         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
13920
13921 2006-05-17  Bruno Haible  <bruno@clisp.org>
13922
13923         Cygwin portability.
13924         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
13925
13926 2006-05-17  Bruno Haible  <bruno@clisp.org>
13927
13928         * lib/stdint_.h: Fix recognition of Cygwin.
13929
13930 2006-05-15  Bruno Haible  <bruno@clisp.org>
13931
13932         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
13933         on libtool patch by Ralf Wildenhues.
13934
13935 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13936
13937         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
13938         test for C99 conformance; (bool) 0.5 is an integer constant
13939         expression, but (bool) -0.5 is not.  Problem reported by Fedor
13940         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
13941
13942 2006-05-11  Simon Josefsson  <jas@extundo.com>
13943
13944         * m4/xvasprintf.m4: Fix obvious typo.
13945
13946 2006-05-11  Jim Meyering  <jim@meyering.net>
13947
13948         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
13949         James Lemley.
13950
13951 2006-05-10  Simon Josefsson  <jas@extundo.com>
13952
13953         * lib/md4.c: Typo fix, update copyright years.
13954         (K1, K2): Don't use L because it turn computations into 64-bit on
13955         64-bit platforms.
13956
13957 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
13958
13959         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
13960         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
13961         unwanted sign propagation, e.g., on hosts with 64-bit int.
13962         There still are some problems with reeelly weird theoretical hosts
13963         (e.g., 33-bit int) but it's not worth worrying about now.
13964         * lib/sha1.c (rol): Likewise.
13965         (K1, K2, K3, K4): Remove unnecessary L suffix.
13966
13967 2006-05-10  Bruno Haible  <bruno@clisp.org>
13968
13969         * lib/des.c: Cast to avoid warnings.
13970
13971 2006-05-09  Bruno Haible  <bruno@clisp.org>
13972
13973         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
13974         (Depends-on): Depend also on xsize, stdarg.
13975         (configure.ac): Add gl_XVASPRINTF.
13976
13977 2006-05-09  Bruno Haible  <bruno@clisp.org>
13978
13979         * m4/xvasprintf.m4: New file.
13980
13981 2006-05-09  Bruno Haible  <bruno@clisp.org>
13982
13983         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
13984         (EOVERFLOW): Define fallback value.
13985         (xstrcat): New function.
13986         (xvasprintf): Recognize the special case of a string concatenation.
13987
13988 2006-05-08  Eric Blake  <ebb9@byu.net>
13989
13990         * gnulib-tool (func_version): Base copyright year on CVS date.
13991         (func_emit_copyright_notice): New function.
13992         (func_emit_lib_Makefile_am): Use it.
13993         (func_emit_tests_Makefile_am): Likewise.
13994         (func_import): Likewise.
13995
13996 2006-05-08  Bruno Haible  <bruno@clisp.org>
13997
13998         * modules/stdarg: New file.
13999         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
14000
14001 2006-05-08  Bruno Haible  <bruno@clisp.org>
14002
14003         * m4/stdarg.m4: New file, from GNU gettext.
14004
14005 2006-05-08  Bruno Haible  <bruno@clisp.org>
14006
14007         * config/srclist.txt (build-aux/config.rpath): different from latest
14008         release.
14009
14010 2006-05-08  Bruno Haible  <bruno@clisp.org>
14011
14012         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
14013
14014 2006-05-05  Jim Meyering  <jim@meyering.net>
14015
14016         * m4/warning.m4: New file, derived from bison's file by the same name.
14017
14018 2006-05-03  Bruno Haible  <bruno@clisp.org>
14019
14020         * lib/stdint_.h: Shorter URL.
14021         * lib/inttypes.h: Likewise.
14022
14023 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14024
14025         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
14026
14027 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14028
14029         * lib/verify.h: Document the internals better.  Most of this change
14030         was written by Bruno Haible.
14031
14032 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14033
14034         * doc/verify.texi: New file, partly based on a proposal by
14035         Bruno Haible.
14036
14037 2006-05-02  Bruno Haible  <bruno@clisp.org>
14038
14039         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
14040         test from here...
14041         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
14042
14043 2006-04-29  Bruno Haible  <bruno@clisp.org>
14044
14045         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
14046         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
14047
14048 2006-04-29  Bruno Haible  <bruno@clisp.org>
14049
14050         * gnulib-tool: Make --update option actually work.
14051
14052 2006-04-29  Bruno Haible  <bruno@clisp.org>
14053
14054         * doc/gcd.texi: New file.
14055         * doc/gnulib.texi: Include it.
14056
14057 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
14058
14059         * lib/getdate.y (get_date): When adding relative date, start with the
14060         initial time, not with the result of the first mktime call.
14061
14062 2006-04-25  Bruno Haible  <bruno@clisp.org>
14063
14064         * gnulib-tool (func_import): Output the include directives in three
14065         blocks, sorted separately.
14066         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14067
14068 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14069
14070         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
14071         to define main with arguments, for C++.  Reported by Eric Blake.
14072         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
14073         Prefer 'int main ()' to 'int main (void)', for C++.
14074         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
14075         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
14076         for 'main', for C99 and C++.
14077
14078 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14079
14080         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
14081         Don't assume that exit status -1 is valid.
14082         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14083         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
14084         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
14085         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
14086         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
14087         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
14088         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
14089         functions can be used without declaring them, or that you can
14090         exit with status -1.
14091         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
14092
14093 2006-04-24  Karl Berry  <karl@gnu.org>
14094
14095         * config/srclist.txt (longdouble.m4): sync lost.
14096
14097 2006-04-24  Eric Blake  <ebb9@byu.net>
14098
14099         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
14100
14101 2006-04-24  Bruno Haible  <bruno@clisp.org>
14102
14103         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
14104         poll() implementation in AIX.
14105         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14106
14107 2006-04-24  Bruno Haible  <bruno@clisp.org>
14108
14109         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
14110         assigned exactly once.
14111
14112 2006-04-23  Claudio Fontana  <claudio@gnu.org>
14113             Bruno Haible  <bruno@clisp.org>
14114
14115         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
14116         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
14117         for AM_CPPFLAGS.
14118
14119 2006-04-23  Bruno Haible  <bruno@clisp.org>
14120
14121         * modules/copy-file: Depend on unistd.
14122         * modules/execute: Likewise.
14123         * modules/fatal-signal: Likewise.
14124         * modules/findprog: Likewise.
14125         * modules/mkdtemp : Likewise.
14126         * modules/pipe: Likewise.
14127         * modules/wait-process: Likewise.
14128
14129 2006-04-23  Bruno Haible  <bruno@clisp.org>
14130
14131         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
14132         condition was already detected.
14133         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14134
14135 2006-04-23  Bruno Haible  <bruno@clisp.org>
14136
14137         * lib/copy-file.c: Include <unistd.h> unconditionally.
14138         * lib/execute.c: Likewise.
14139         * lib/fatal-signal.c: Likewise.
14140         * lib/findprog.c: Likewise.
14141         * lib/mkdtemp.c: Likewise.
14142         * lib/pipe.h: Likewise.
14143         * lib/pipe.c: Likewise.
14144         * lib/wait-process.h: Likewise.
14145
14146 2006-04-23  Bruno Haible  <bruno@clisp.org>
14147
14148         * gnulib-tool (func_usage): Fix --import description. Document
14149         --update.
14150         (func_import): Create temporary file in a temporary directory, if
14151         --dry-run is specified. Silence errors from 'grep' when there are no
14152         m4 files in $m4dir.
14153         (func_create_testdir): Silence errors from 'grep' when there are no
14154         m4 files in $m4dir.
14155         Reported by Karl Berry <karl@freefriends.org>.
14156
14157 2006-04-20  Bruno Haible  <bruno@clisp.org>
14158
14159         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
14160         one argument, so that the code will be portable to Autoconf 2.60.
14161         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
14162         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
14163         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
14164
14165 2006-04-19  Derek Price  <derek@ximbiot.com>
14166             Eric Blake  <ebb9@byu.net>
14167
14168         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
14169         rather than "/full/path.h".  Update comment to match.  Shorten &
14170         generalize m4_translit call via AS_TR_CPP.
14171
14172 2006-04-19  Derek Price  <derek@ximbiot.com>
14173             Eric Blake  <ebb9@byu.net>
14174
14175         * lib/inttypes.h: Correct grammar in comment.
14176
14177 2006-04-18  Derek Price  <derek@ximbiot.com>
14178             Paul Eggert  <eggert@cs.ucla.edu>
14179
14180         * modules/inttypes: New file.
14181         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
14182
14183 2006-04-18  Derek Price  <derek@ximbiot.com>
14184             Paul Eggert  <eggert@cs.ucla.edu>
14185
14186         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
14187         New files.
14188
14189 2006-04-18  Derek Price  <derek@ximbiot.com>
14190             Paul Eggert  <eggert@cs.ucla.edu>
14191
14192         * lib/inttypes.h: New file.
14193         * lib/strtoimax.c: Assume <inttypes.h>.
14194
14195 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
14196
14197         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
14198         isn't mounted.  Problem reported by Kir Kolyshkin.
14199
14200 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
14201
14202         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
14203         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
14204         Derek R. Price.
14205         * lib/regex.h (RE_DUP_MAX): Update comment to match current
14206         implementation.
14207
14208 2006-04-12  Eric Blake  <ebb9@byu.net>
14209
14210         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
14211         is now done automatically by the corresponding Autoconf macro.
14212
14213 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
14214
14215         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
14216         time_r.h.
14217
14218 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14219
14220         Merge regex changes from libc, removing some of our
14221         POSIX-conformance changes that were rejected and redoing them in a
14222         less-intrusive way.
14223
14224         * lib/regcomp.c (re_compile_internal, init_dfa):
14225         Length arg is now size_t, not Idx.  All uses changed.
14226         (peek_token): Forward decl now says internal_function.
14227         (__re_error_msgid, __re_error_msgid_idx):
14228         Now static rather than extern with attribute_hidden.
14229         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
14230         For some reason libc prefers K&R style defns for external functions.
14231         (regerror) [!defined _LIBC]: Likewise.
14232         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
14233         (seek_collating_symbol_entry, lookup_collation_sequence_value):
14234         (build_range_exp, build_collating_symbol):
14235         Use K&R-style defn.
14236         (re_compile_fastmap): Use '\0' to memset, not 0.
14237         (utf8_sb_map): Make the calculations more obvious.
14238         (init_dfa, parse_bracket_exp, build_charclass_op):
14239         Call calloc and cast result, as glibc does.
14240         (init_word_char, fetch_token, peek_token, peek_token_bracket):
14241         (build_range_exp, build_collating_symbol):
14242         Now internal functions.
14243
14244         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
14245
14246         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
14247         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
14248         Don't depend on VMS; depend on __VMS instead, for POSIX
14249         namespace cleanness.
14250         (regoff_t): Define to ssize_t, not long int.
14251
14252         Remove the REG_ macros named below.  Instead, make the old names
14253         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
14254         __USE_GNU_REGEX.
14255         (REG_BACKSLASH_ESCAPE_IN_LISTS):
14256         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
14257         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
14258         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
14259         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
14260         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
14261         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
14262         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
14263         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
14264         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
14265         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
14266         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
14267         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
14268         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
14269         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
14270         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
14271         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
14272         (REG_NREGS):
14273         Remove.  All uses replaced by the old RE_* names.
14274         (RE_BACKSLASH_ESCAPE_IN_LISTS):
14275         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
14276         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
14277         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
14278         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
14279         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
14280         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
14281         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
14282         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
14283         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
14284         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
14285         Don't bother having these macros be independent of each others'
14286         values, since they no longer exist in the POSIX name space.
14287
14288         Rename the following member names back to their old names,
14289         unless !__USE_GNU_REGEX.  All uses changed back.
14290         (buffer): Renamed from re_buffer.
14291         (allocated): Renamed from re_allocated.
14292         (used): Renamed from re_used.
14293         (syntax): Renamed from re_syntax.
14294         (fastmap): Renamed from re_fastmap.
14295         (translate): Renamed from re_translate.
14296         (can_be_null): Renamed from re_can_be_null.
14297         (regs_allocated): Renamed from re_regs_allocated.
14298         (fastmap_accurate): Renamed from re_fastmap_accurate.
14299         (no_sub): Renamed from re_no_sub.
14300         (not_bol): Renamed from re_not_bol.
14301         (not_eol): Renamed from re_not_eol.
14302         (newline_anchor): Renamed from re_newline_anchor.
14303         (num_regs): Renamed from rm_num_regs.
14304         (start): Renamed from rm_start.
14305         (end): Renamed from rm_end.
14306
14307         (free_state): Move up a bit.
14308
14309         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
14310         #define to be empty.
14311         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
14312         when that is what is intended.
14313         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
14314         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
14315         (MAX): New macro.
14316         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
14317         All uses changed back to re_malloc, etc.  It's now the caller's
14318         responsibility to check for overflow; all callers changed.
14319         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
14320         (re_x2nrealloc): Remove.
14321         (free_state): Remove decl.
14322
14323         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
14324         (re_set_registers, re_exec):
14325         Use K&R-style defn.
14326
14327         2006-01-31  Roland McGrath  <roland@redhat.com>
14328
14329         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
14330         Reported by Mike Frysinger <vapier@gentoo.org>.
14331
14332         2006-01-15  Andreas Jaeger  <aj@suse.de>
14333
14334         [BZ #1950]
14335         * lib/regex_internal.c (re_string_reconstruct): Adjust for
14336         build_wcs_upper_buffer change.
14337         (build_wcs_upper_buffer): Change return type.
14338
14339         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
14340
14341         * lib/regex_internal.h: Include <stdint.h> if available.
14342
14343         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
14344
14345         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
14346
14347         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
14348
14349         * lib/regcomp.c: Adjust for changed secondary hash function.
14350
14351         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
14352
14353         * lib/regex.h: Pretty printing.
14354         Clean up namespace a bit.
14355
14356         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
14357
14358         * lib/regexec.c (update_cur_sifted_state, check_arrival,
14359         check_arrival_add_next_nodes): Avoid using uninitialized variable.
14360
14361         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14362                     Ulrich Drepper  <drepper@redhat.com>
14363
14364         [BZ #1302]
14365         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
14366         changed.
14367         (bitset_word_t): Renamed from bitset_word.  All uses changed.
14368
14369         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
14370
14371         [BZ #281]
14372         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
14373         * lib/regcomp.c: Remove unnecessary uses of
14374         unsigned RE_TRANSLATE_TYPE.
14375         * lib/regex_internal.h: Likewise.
14376         * lib/regex_internal.c: Likewise.
14377         * lib/regexec.c: Likewise.
14378         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
14379
14380         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
14381
14382         * lib/regexec.c (find_recover_state): Remove unnecessary
14383         initialization.
14384         (transit_state_bkref): Make DFA a const pointer.
14385         (get_subexp): Likewise.
14386         (check_arrival): Likewise.
14387         (update_cur_sifted_state): Likewise.
14388         (re_search_internal): Likewise.
14389         (prune_impossible_nodes): Likewise.
14390         (acquire_init_state_context): Likewise.
14391         (proceed_next_node): Likewise.
14392         (set_regs): Likewise.
14393         (free_fail_stack_return): Likewise.
14394         (check_arrival_expand_ecl): Mark DFA parameter as const.
14395         (check_arrival_expand_ecl_sub): Likewise.
14396         (check_subexp_limits): Likewise.
14397         (sub_epsilon_src_nodes):  Likewise.
14398         (add_epsilon_src_nodes):  Likewise.
14399         (merge_state_array): Likewise.
14400         (update_regs): Likewise.
14401         (build_trtable): Likewise.
14402         (sift_states_backward): Mark MCTX parameter as const.
14403         (build_sifted_states): Likewise.
14404         (update_cur_sifted_state): Likewise.
14405         (sift_states_mkref): Likewise.
14406         (check_arrival_expand_ecl): Mark eclosure as const.
14407         (check_dst_limits_calc_pos_1): Likewise.
14408         * lib/regex_internal.h (re_match_context_t): Make dfa a const
14409         pointer.
14410
14411         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
14412
14413         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
14414         (transit_state_sb): Likewise.
14415         (transit_state_mb): Likewise.
14416         (sift_states_iter_mb): Likewise.
14417         (check_arrival_add_next_nodes): Likewise.
14418         (check_node_accept_bytes): Change first parameter to pointer-to-const.
14419         [_LIBC] (re_search_2_stub): Use mempcpy.
14420
14421         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
14422         mbrtowc for very simple UTF-8 case.
14423
14424         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
14425         a pointer-to-const.
14426         (re_acquire_state_context): Likewise.
14427         * lib/regex_internal.h: Adjust prototypes.
14428
14429         * lib/regex.c: Prevent using C++ compilers.
14430
14431         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
14432         (re_acquire_state_context): Likewise.
14433
14434 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14435
14436         * modules/regex (Depends-on): Add ssize_t.
14437
14438 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14439
14440         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
14441         translation table.
14442
14443 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14444
14445         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
14446
14447 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
14448             Bruno Haible  <bruno@clisp.org>
14449
14450         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
14451         <sys/types.h> and <inttypes.h>.
14452
14453 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14454
14455         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
14456         `__error_t_defined', so argp.h will not typedef the former.
14457
14458 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
14459
14460         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
14461         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
14462         glibc names.  Even if glibc is changed to conform to POSIX, the
14463         traditional names will be available anyway, since regex depends on
14464         the extensions module.  Also, fix a longstanding typo in the
14465         implementation of Spencer ERE test #75 from grep 2.3.  Problems
14466         reported by Emanuele Giaquinta.  Also, change sense of cached
14467         variable, so that the message makes sense.
14468
14469 2006-03-24  Simon Josefsson  <jas@extundo.com>
14470
14471         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
14472         including some doc fixes.
14473         (base64_encode_alloc): Fix +1 bug on allocation failures.
14474
14475 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14476
14477         * lib/base64.c (base64_encode): Do not read past end of array with
14478         unsanitized input on systems with CHAR_BIT > 8.
14479
14480 2006-03-24  Eric Blake  <ebb9@byu.net>
14481
14482         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
14483
14484 2006-03-22  Karl Berry  <karl@gnu.org>
14485
14486         * config/srclist.txt (*setenv.[ch]): get from coreutils.
14487         * config/srclistvars.sh (COREUTILS): new var.
14488
14489 2006-03-17  Jim Meyering  <jim@meyering.net>
14490
14491         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
14492         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
14493
14494 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
14495
14496         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
14497         no longer needs it.  Instead, check that regoff_t is as least
14498         as wide as ptrdiff_t.
14499
14500         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
14501         so that our regex.h stays compatible with the installed regex.
14502         This is helpful for installers who configure --without-included-regex.
14503         Problem reported by Emanuele Giaquinta.
14504
14505 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
14506
14507         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
14508         Typedef to long int, not to off_, as POSIX will likely change
14509         in that direction.
14510
14511 2006-03-15  Eric Blake  <ebb9@byu.net>
14512
14513         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
14514
14515 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
14516
14517         * lib/argp-help.c (validate_uparams): Fix typo
14518         * lib/argp-parse.c (argp_default_options): Consistently begin help
14519         messages with a lowercase letter.
14520
14521 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
14522
14523         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
14524         overrun buffers and shouldn't be used (much as gets shouldn't be
14525         used).
14526         * lib/time_r.c (asctime_r, ctime_r): Likewise.
14527
14528 2006-03-08  Simon Josefsson  <jas@extundo.com>
14529
14530         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
14531         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14532
14533 2006-03-08  Simon Josefsson  <jas@extundo.com>
14534
14535         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
14536         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14537
14538 2006-03-08  Simon Josefsson  <jas@extundo.com>
14539
14540         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
14541         signal that configure disabled the device.
14542
14543 2006-03-08  Simon Josefsson  <jas@extundo.com>
14544
14545         * build-aux/maint.mk: Fix refresh-po, to handle no translated
14546         languages.
14547
14548 2006-03-07  Simon Josefsson  <jas@extundo.com>
14549
14550         * modules/getopt (Depends-on): Add unistd.
14551
14552         * modules/unistd: New file.
14553
14554 2006-03-07  Simon Josefsson  <jas@extundo.com>
14555
14556         * modules/gc-random: New file.
14557
14558 2006-03-07  Simon Josefsson  <jas@extundo.com>
14559
14560         * m4/unistd_h.m4: New file.
14561
14562 2006-03-07  Simon Josefsson  <jas@extundo.com>
14563
14564         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
14565         test to be side-effect free by storing the result in the cache
14566         variable gl_cv_lib_readline, and moving the assignment of
14567         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
14568         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14569
14570 2006-03-07  Simon Josefsson  <jas@extundo.com>
14571
14572         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
14573         error on missing devices (the functions will return an error).
14574
14575         * m4/gc.m4: Move random stuff to gc-random.m4
14576
14577 2006-03-07  Simon Josefsson  <jas@extundo.com>
14578
14579         * lib/unistd_.h: New file.
14580
14581 2006-03-07  Simon Josefsson  <jas@extundo.com>
14582
14583         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
14584
14585 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14586
14587         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
14588         Problem reported by Juan Manuel Guerrero.
14589
14590 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14591
14592         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
14593         the unistd module.
14594         * lib/getlogin_r.c: Likewise.
14595         * lib/getlogin_r.h: Likewise.
14596         * lib/glob.c: Likewise.
14597         * lib/pagealign_alloc.c: Likewise.
14598         * lib/unistd_.h: Remove; no longer needed.
14599
14600 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14601
14602         * MODULES.html.sh (Support for systems lacking POSIX:2001):
14603         Add unistd.
14604         * modules/c-stack (Depends-on): Add unistd.
14605         * modules/getlogin_r: Likewise.
14606         * modules/glob: Likewise.
14607         * modules/pagealign_alloc: Likewise.
14608         * modules/unistd (Files): Remove lib/unistd_.h.
14609         (EXTRA_DIST): Remove.
14610         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
14611         need unistd_.h.
14612         (MOSTLYCLEANFILES): Remove unistd.h-t.
14613
14614 2006-03-03  Simon Josefsson  <jas@extundo.com>
14615
14616         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
14617
14618 2006-03-03  Simon Josefsson  <jas@extundo.com>
14619
14620         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
14621         libidn and bison.
14622
14623 2006-03-03  Simon Josefsson  <jas@extundo.com>
14624
14625         * build-aux/maint.mk: Add indent target.
14626
14627 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
14628
14629         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
14630         our replacement poll.h in any case, to avoid a differing
14631         declaration from a system header.  Seen on AIX.
14632
14633 2006-03-01  Simon Josefsson  <jas@extundo.com>
14634
14635         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
14636         <kasal@ucw.cz>.
14637
14638 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14639
14640         * modules/gettime (Depends-on): Add extensions module.
14641         * modules/nanosleep (Depends-on): Likewise.
14642         * modules/settime (Depends-on): Likewise.
14643
14644 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14645
14646         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
14647         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
14648         pedantically.
14649         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14650         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
14651
14652         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
14653         not "==".  Reported by Ralf Wildenhues.
14654
14655 2006-03-01  Karl Berry  <karl@gnu.org>
14656
14657         * doc/Copyright/request-*: new files, synced from gnuorg.
14658
14659 2006-03-01  Karl Berry  <karl@gnu.org>
14660
14661         * config/srclist.txt (Copyright/*): new entries.
14662
14663 2006-02-28  Simon Josefsson  <jas@extundo.com>
14664
14665         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
14666
14667 2006-02-27  Simon Josefsson  <jas@extundo.com>
14668
14669         * lib/base64.h: Indent #define's.  From Jim Meyering
14670         <jim@meyering.net>.
14671
14672 2006-02-27  Jim Meyering  <jim@meyering.net>
14673
14674         Revert the change of 2006-02-24, so these files can continue
14675         to be sync'd from gettext.
14676         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
14677         of `config.h'.
14678
14679 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
14680
14681         * modules/intprops: New file.
14682         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
14683         Add intprops.
14684         * modules/getloadavg (Files): Remove lib/intprops.h.
14685         (Depends-on): Add intprops.
14686         * modules/human: Likewise.
14687         * modules/inttostr: Likewise.
14688         * modules/openat: Likewise.
14689         * modules/sig2str: Likewise.
14690         * modules/userspec: Likewise.
14691         * modules/utimecmp: Likewise.
14692         * modules/xnanosleep: Likewise.
14693         * modules/xstrtol: Likewise.
14694
14695 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
14696
14697         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
14698         * modules/lock-tests (TESTS): Use $(EXEEXT).
14699         * modules/tls-tests: Likewise.
14700         * modules/argp-tests: Likewise.
14701         (check_PROGRAMS): New var, replacing...
14702         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
14703
14704 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14705
14706         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
14707         `config.h'.
14708
14709 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
14710
14711         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
14712
14713 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14714
14715         Sync from coreutils.
14716         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
14717         gl_CHDIR_SAFER.
14718
14719 2006-02-22  Jim Meyering  <jim@meyering.net>
14720
14721         Sync from coreutils.
14722         * m4/chdir-safer.m4: New file.
14723
14724 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
14725
14726         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
14727         AT_FDCWD exceeds INT_MAX.
14728         * lib/openat.h (AT_FDCWD): Likewise.
14729
14730 2006-02-17  Eric Blake  <address@hidden>
14731
14732         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
14733
14734 2006-02-16  Simon Josefsson  <jas@extundo.com>
14735
14736         * modules/getaddrinfo (Depends-on): Add sys_socket.
14737
14738 2006-02-15  Simon Josefsson  <jas@extundo.com>
14739
14740         * build-aux/maint.mk: Add dsyntax-check rule.
14741
14742 2006-02-15  Eric Blake  <ebb9@byu.net>
14743
14744         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
14745         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
14746         'present but cannot compile' warnings on cygwin.
14747         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
14748         use ws2tcpip.h if sys/socket.h works.
14749         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
14750         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
14751
14752 2006-02-14  Simon Josefsson  <jas@extundo.com>
14753
14754         * modules/maintainer-makefile (Files): Rename.
14755
14756         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
14757         and (the local) Makefile.cfg to maint-cfg.mk.
14758
14759         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
14760         to the latter.
14761
14762         * modules/maintainer-makefile: New module.
14763
14764         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
14765         severaly stripped to make it possible to build it up from scratch
14766         with reliable tests.
14767
14768         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
14769         fixes to permit overriding the default actions when configure and
14770         makefile are not available.
14771
14772 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
14773
14774         Sync from coreutils.
14775         * modules/lstat (Depends-on): Don't depend on xalloc.
14776         (License): Change from GPL to LGPL, since this is now simply a
14777         replacement for a libc function.
14778
14779 2006-02-14  Jim Meyering  <jim@meyering.net>
14780
14781         Sync from coreutils.
14782
14783         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
14784         failure on deficient systems, and simplify gnulib lgpl dependencies.
14785         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
14786         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
14787
14788         * lib/xalloc-die.c: Remove unused definition of N_.
14789
14790 2006-02-14  Jim Meyering  <jim@meyering.net>
14791
14792         Sync from coreutils.
14793         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
14794         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
14795         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
14796         double-quote uses of that variable, to accommodate the rare case in
14797         which getmntent is available in none of the libraries checked.  This
14798         happens at least on FreeBSD 5.0.
14799
14800 2006-02-13  Simon Josefsson  <jas@extundo.com>
14801
14802         * gnulib-tool (Usage): Fix --import, from
14803         karl@freefriends.org (Karl Berry).
14804
14805 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
14806
14807         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
14808
14809 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
14810
14811         * lib/argp-namefrob.h: Restore changes accidentally lost during the
14812         "autoupdate" on 2005-12-12.
14813
14814 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
14815
14816         * modules/closeout (Depends-on): Remove atexit.
14817
14818 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
14819
14820         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
14821         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
14822
14823 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
14824
14825         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
14826         __EXTENSIONS__ if this causes compilation to fail.  Problem
14827         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
14828         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
14829
14830 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
14831
14832         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
14833         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
14834         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
14835         All uses changed.
14836
14837 2006-01-26  Simon Josefsson  <jas@extundo.com>
14838
14839         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
14840         prototype is visible on mingw32.
14841
14842         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
14843         for mingw32.
14844
14845         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
14846         mingw32).
14847
14848 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
14849
14850         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
14851         attempt to open for write; this always fails, at least on POSIX
14852         hosts.  This reinstates the 2006-01-09 change, which was
14853         inadvertently removed.
14854
14855 2006-01-26  Bruno Haible  <bruno@clisp.org>
14856
14857         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
14858         Reported by Paul Eggert.
14859
14860 2006-01-26  Bruno Haible  <bruno@clisp.org>
14861             Paul Eggert  <eggert@cs.ucla.edu>
14862
14863         * lib/stdbool_.h (_Bool)
14864         [(! (defined __cplusplus || defined __BEOS__)
14865           && !defined __GNUC__
14866           && !(defined __HP_cc || defined __xlc__
14867                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
14868                || defined __sgi))]:
14869         #define to signed char in these cases too; this simplifies
14870         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
14871         etc., separately) and makes it more conservative.
14872
14873 2006-01-25  Simon Josefsson  <jas@extundo.com>
14874
14875         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
14876         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
14877         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
14878
14879 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14880
14881         * lib/argp-namefrob.h: Bugfix. Remove stray #
14882
14883 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
14884
14885         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
14886         so that we test the test.
14887         Check for yet another HP-UX cc bug involving *bool |= bool.
14888
14889 2006-01-25  Karl Berry  <karl@gnu.org>
14890
14891         * config/srclist.txt (vasnprintf.c): sync lost.
14892
14893 2006-01-25  Jim Meyering  <jim@meyering.net>
14894
14895         Sync from the stable (b5) branch of coreutils:
14896
14897         * lib/fts.c (fts_children): Don't let close() clobber errno from
14898         failed fchdir().
14899
14900         * lib/fts.c (fts_stat): When following a symlink-to-directory,
14901         don't necessarily interpret stat-fails+lstat-succeeds as indicating
14902         a dangling symlink.  That can also happen at least for ELOOP.
14903         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
14904         FYI, this bug predates the inclusion of fts.c in coreutils.
14905
14906         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
14907         in their own block, so pre-c99 compilers don't object.
14908
14909         Avoid the double-free (first in fts_read, second in fts_close) that
14910         would occur when an `active' directory is made inaccessible (e.g.,
14911         via chmod a-x) during a traversal.
14912         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
14913         before returning.  Reproduce this failure by
14914         mkdir -p a/b; cd a; chmod a-x . b
14915         Reported by Stavros Passas.
14916
14917 2006-01-25  Jim Meyering  <jim@meyering.net>
14918
14919         * lib/fileblocks.c: Remove more useless parentheses.
14920         * lib/readutmp.h: Likewise.
14921
14922 2006-01-25  Bruno Haible  <bruno@clisp.org>
14923
14924         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
14925         warnings.
14926         Reported by Paul Eggert.
14927
14928 2006-01-25  Bruno Haible  <bruno@clisp.org>
14929
14930         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
14931         rid of a trap command. For Solaris sh.
14932         Reported by Mark D. Baushke <mdb@gnu.org>.
14933
14934 2006-01-24  Simon Josefsson  <jas@extundo.com>
14935
14936         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
14937         Bruno.
14938
14939 2006-01-24  Karl Berry  <karl@gnu.org>
14940
14941         * config/srclist.txt (argp-namefrob.h): sync lost.
14942
14943 2006-01-24  Jim Meyering  <jim@meyering.net>
14944
14945         * modules/openat (Files): Add lib/intprops.h.
14946         From Mark D. Baushke.
14947
14948 2006-01-24  Jim Meyering  <jim@meyering.net>
14949
14950         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
14951         Reported by Mark D. Baushke.
14952
14953 2006-01-24  Jim Meyering  <jim@meyering.net>
14954
14955         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
14956
14957 2006-01-24  Bruno Haible  <bruno@clisp.org>
14958
14959         * modules/strnlen (Maintainer): Change from glibc to all.
14960
14961 2006-01-24  Bruno Haible  <bruno@clisp.org>
14962
14963         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
14964         Patch by Paul Eggert.
14965
14966 2006-01-24  Bruno Haible  <bruno@clisp.org>
14967
14968         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
14969         already has it.
14970         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
14971         2005-11-26.
14972
14973         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
14974         'signed char' to avoid problems with the built-in _Bool type.
14975         Reported by Paul Eggert on 2005-11-26.
14976
14977 2006-01-24  Bruno Haible  <bruno@clisp.org>
14978
14979         * gnulib-tool (func_import): Avoid constructing complicated sed
14980         expressions inside backquote.
14981         Report and solution by Mark D. Baushke <mdb@gnu.org>.
14982
14983 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
14984
14985         These changes imported from libc.
14986         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
14987         test and two separate function calls.
14988         * lib/strndup.c (__strndup): Add libc_hidden_def.
14989
14990 2006-01-23  Simon Josefsson  <jas@extundo.com>
14991
14992         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
14993         Remove the test_*_SOURCES variable: automake infers it by default.
14994         * modules/tls-tests: Likewise.
14995
14996 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
14997
14998         Work around porting bugs reported by Dieter in
14999         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
15000         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
15001         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
15002         Include "getopt.h" first, to check interface.
15003         (getenv): Declare only if defined HAVE_DECL_GETENV &&
15004         !HAVE_DECL_GETENV.
15005         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
15006         (__strndup): Revert to K&R-style function dfns, the glibc style.
15007         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
15008         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
15009         Include strnlen.h first, to get prototype properly.
15010         (strnlen): Renamed from __strnlen.
15011         Remove weak alias.
15012
15013 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15014
15015         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
15016
15017 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15018
15019         * config/srclist.txt: Adjust to reflect glibc reorganization.
15020         This affects only comments.
15021
15022 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15023
15024          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
15025          Reported by Bruce Korb <bkorb@gnu.org>.
15026
15027 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
15028
15029         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
15030         to pacify gcc -Wswitch-default.
15031
15032 2006-01-22  Bruno Haible  <bruno@clisp.org>
15033
15034         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
15035         temporary buffer for sprintf, take into account the precision also
15036         for 'd', 'i', 'u', 'o', 'x', 'X'.
15037
15038 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15039
15040         * modules/argp-tests: New module
15041         * tests/test-argp.c: New file
15042         * tests/test-argp-2.sh: New file
15043
15044 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15045
15046         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
15047         (__argp_base_name): Removed
15048         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
15049         typo.
15050         (__argp_base_name): Provide macro definition or extern declaration
15051         depending on the configuration
15052
15053 2006-01-20  Simon Josefsson  <jas@extundo.com>
15054
15055         * modules/inet_ntop (Depends-on): Depend on sys_socket.
15056
15057 2006-01-20  Simon Josefsson  <jas@extundo.com>
15058
15059         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
15060
15061 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
15062
15063         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
15064         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
15065         Suggested by Bruno Haible.
15066
15067 2006-01-20  Karl Berry  <karl@gnu.org>
15068
15069         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
15070         until changes propagate, I guess.
15071
15072 2006-01-19  Simon Josefsson  <jas@extundo.com>
15073
15074         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
15075
15076 2006-01-19  Simon Josefsson  <jas@extundo.com>
15077
15078         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
15079
15080 2006-01-19  Simon Josefsson  <jas@extundo.com>
15081
15082         * gnulib-tool: Set check_PROGRAMS.
15083
15084         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15085         modules/des-tests, modules/gc-arcfour-tests,
15086         modules/gc-arctwo-tests, modules/gc-des-tests,
15087         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15088         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15089         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15090         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15091         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15092         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
15093         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
15094         test_*_SOURCES.
15095
15096 2006-01-18  Simon Josefsson  <jas@extundo.com>
15097
15098         * modules/socklen (Depends-on): Depend on sys_socket.
15099
15100 2006-01-18  Simon Josefsson  <jas@extundo.com>
15101
15102         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15103         modules/des-tests, modules/gc-arcfour-tests,
15104         modules/gc-arctwo-tests, modules/gc-des-tests,
15105         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15106         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15107         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15108         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15109         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15110         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
15111         $(EXEEXT) to automake TESTS variable, for mingw32.
15112
15113 2006-01-17  Simon Josefsson  <jas@extundo.com>
15114
15115         * modules/socklen (Include): Need sys/socket.h.
15116
15117 2006-01-17  Bruno Haible  <bruno@clisp.org>
15118
15119         * modules/ssize_t (Include): Add <sys/types.h>.
15120
15121 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
15122
15123         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
15124         it's not portable and it doesn't work with cross-compiles.
15125         Problem reported by Bruno Haible.  Fix missing-$ typo in
15126         'test "gl_cv_ignore_unused_libraries" ...' that prevented
15127         -zignore from being used with Sun's C compiler.
15128
15129 2006-01-12  Simon Josefsson  <jas@extundo.com>
15130
15131         * lib/base64.c: Fix warning, reported by Bruno Haible
15132         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
15133
15134 2006-01-12  Bruno Haible  <bruno@clisp.org>
15135
15136         * modules/ldd: New file.
15137         * build-aux/ldd.sh.in: New file.
15138         * MODULES.html.sh (Support for building libraries and executables): Add
15139         ldd.
15140
15141 2006-01-12  Bruno Haible  <bruno@clisp.org>
15142
15143         * m4/ldd.m4: New file.
15144
15145 2006-01-12  Bruno Haible  <bruno@clisp.org>
15146
15147         * gnulib-tool (func_import, func_create_testdir): Don't go into an
15148         endless loop while replacing $auxdir with build-aux.
15149
15150 2006-01-11  Simon Josefsson  <jas@extundo.com>
15151
15152         * lib/stdint_.h (SIZE_MAX): Add missing (.
15153
15154 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
15155
15156         Sync from coreutils.
15157         * lib/md5.c: Fix commentary typos.
15158         (alignof, UNALIGNED_P): No need for a GCC-specific version.
15159         * lib/md5.h (__attribute__): Remove; unused.
15160         * lib/sha1.c: Fix commentary to match md5 better.
15161         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
15162         so that we don't need to worry about alignment.  All uses changed.
15163         This merges the 2005-10-28 md5 change into sha1.
15164
15165 2006-01-11  Jim Meyering  <jim@meyering.net>
15166
15167         Sync from coreutils.
15168         * lib/md5.c (OP): Fix spacing.
15169
15170 2006-01-11  Bruno Haible  <bruno@clisp.org>
15171
15172         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15173         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
15174         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
15175
15176 2006-01-11  Bruno Haible  <bruno@clisp.org>
15177
15178         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15179         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
15180         the "early" section as well.
15181
15182 2006-01-11  Bruno Haible  <bruno@clisp.org>
15183
15184         Avoid "ar: no archive members specified" error on MacOS X.
15185         * gnulib-tool (func_modules_add_dummy): New function.
15186         (func_import, func_create_testdir): Invoke it.
15187
15188 2006-01-11  Bruno Haible  <bruno@clisp.org>
15189
15190         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
15191         with $auxdir in AC_CONFIG_FILES statements.
15192
15193 2006-01-11  Bruno Haible  <bruno@clisp.org>
15194
15195         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
15196         Initialize also noinst_HEADERS to empty.
15197
15198 2006-01-11  Bruno Haible  <bruno@clisp.org>
15199
15200         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
15201         variables.
15202         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
15203         autoreconf.
15204
15205 2006-01-11  Bruno Haible  <bruno@clisp.org>
15206
15207         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
15208         overridable by the user.
15209         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15210
15211 2006-01-10  Simon Josefsson  <jas@extundo.com>
15212
15213         * modules/sys_socket: New file.
15214
15215 2006-01-10  Simon Josefsson  <jas@extundo.com>
15216
15217         * m4/sys_socket_h.m4: New file.
15218
15219 2006-01-10  Simon Josefsson  <jas@extundo.com>
15220
15221         * lib/socket_.h: New file.
15222
15223 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15224
15225         * modules/readutmp (Maintainer): Add myself.
15226
15227 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15228
15229         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
15230         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
15231         People who are still concerned with buggy memcmp implementations
15232         can invoke gl_FUNC_MEMCMP themselves.
15233
15234 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15235
15236         * lib/regex_internal.h (BITSET_WORD_BITS):
15237         Work around a bug in 64-bit PGC (before version 6.1-2), where the
15238         preprocessor mishandles large unsigned values as if they were signed.
15239         Problem reported by Claudio Fontana in
15240         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
15241
15242 2006-01-10  Jim Meyering  <jim@meyering.net>
15243
15244         Avoid the double-free (first in fts_read, second in fts_close) that
15245         would occur when an `active' directory is made inaccessible (e.g.,
15246         via chmod a-x) during a traversal.
15247         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15248         before returning.  Reproduce this failure by
15249         mkdir -p a/b; cd a; chmod a-x . b
15250         Reported by Stavros Passas.
15251
15252         Sync from coreutils.
15253         * lib/sha1.c: Tweak grammar in a comment.
15254
15255 2006-01-10  Jim Meyering  <jim@meyering.net>
15256
15257         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
15258         Patch by Joerg Sonnenberger.
15259
15260 2006-01-10  Bruno Haible  <bruno@clisp.org>
15261
15262         * modules/readutmp: Depend on module free.
15263         * modules/strtok_r: Depend on module restrict.
15264
15265 2006-01-10  Bruno Haible  <bruno@clisp.org>
15266
15267         * modules/gettext (configure.ac): Add an invocation of
15268         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
15269
15270 2006-01-10  Bruno Haible  <bruno@clisp.org>
15271
15272         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
15273         Reported by Werner Lemberg <wl@gnu.org>.
15274
15275 2006-01-10  Bruno Haible  <bruno@clisp.org>
15276
15277         * lib/localcharset.c: Update from GNU gettext.
15278
15279 2006-01-10  Bruno Haible  <bruno@clisp.org>
15280
15281         * lib/argp.h (__const): Remove macro. Use const instead.
15282         * lib/argp-fmtstream.h (__const): Likewise.
15283         * lib/glob_.h (__const): Remove macro.
15284         * lib/glob-libc.h: Use const instead of __const.
15285
15286 2006-01-10  Bruno Haible  <bruno@clisp.org>
15287
15288         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
15289         variable.
15290         Needed to avoid an automake error regarding the 'gettext' module.
15291
15292 2006-01-09  Simon Josefsson  <jas@extundo.com>
15293
15294         * modules/inet_ntop (Depends-on): Add restrict.
15295
15296 2006-01-09  Simon Josefsson  <jas@extundo.com>
15297
15298         * modules/gc-rijndael-tests (License): Put under LGPL.
15299
15300         * modules/gc-des-tests (License): Likewise.
15301
15302         * modules/gc-arcfour-tests (License): Likewise.
15303
15304         * modules/gc-arctwo-tests (License): Likewise.
15305
15306         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
15307
15308         * modules/gc-hmac-sha1-tests (Files): Likewise.
15309
15310         * modules/gc-hmac-md5-tests (License): Likewise.
15311
15312         * modules/gc-sha1-tests (License): Likewise.
15313
15314         * modules/gc-md5-tests (License): Likewise.
15315
15316         * modules/gc-md4-tests (License): Likewise.
15317
15318         * modules/gc-md2-tests (License): Likewise.
15319
15320         * modules/gc-tests (License): Likewise.
15321
15322         * modules/des-tests (License): Likewise.
15323
15324         * modules/md4-tests (License): Likewise.
15325
15326         * modules/md2-tests (License): Likewise.
15327
15328 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15329
15330         Sync from coreutils:
15331
15332         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
15333         * modules/lib-ignore: New file.
15334         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
15335         chdir-safer.m4, lchmod.m4.
15336         * modules/openat: Add mkdirat.c, openat-priv.h.
15337
15338 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15339
15340         Sync from coreutils.
15341         * m4/lib-ignore.m4: New file.
15342         * m4/lchmod.m4: New file.
15343
15344 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15345
15346         Sync from coreutils.
15347         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
15348         for write access: POSIX says that must fail.
15349         * lib/fts.c (diropen): Likewise.
15350         * lib/save-cwd.c (save_cwd): Likewise.
15351         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
15352         well, for minor improvements on hosts that lack O_DIRECTORY.
15353         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
15354         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
15355         Fall back on chown if open failed with EACCES.
15356
15357         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
15358         Report an error at compile-time if only a 1-second nominal clock
15359         resolution is found.
15360
15361         * lib/lchmod.h: New file.
15362         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
15363         (make_dir_parents): Use lchown rather than chown, and
15364         lchmod rather than chmod.
15365
15366         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
15367         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
15368         "proc" reported by n0dalus.
15369
15370         * lib/mountlist.c: Include <limits.h>.
15371         (dev_from_mount_options)
15372         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
15373         New function.  It no longer assumes "dev=" has the System V meaning
15374         on Linux (since it doesn't).  It also parses "dev=" more carefully.
15375         (read_file_system_list)
15376         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
15377         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
15378         dev= in that case.
15379
15380         * lib/posixtm.h (PDS_PRE_2000): New macro.
15381         * lib/posixtm.c (year): Arg is now syntax_bits rather than
15382         allow_century.  All usages changed.  Reject dates outside the range
15383         1969-1999 if PDS_PRE_2000 is used.
15384
15385 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15386
15387         Sync from coreutils.
15388         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
15389         (Time of day items): Mention the possibility of leap seconds.
15390         Problem reported by Dr. David Alan Gilbert.
15391
15392 2006-01-09  Jim Meyering  <jim@meyering.net>
15393
15394         Sync from coreutils.
15395
15396         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
15397
15398         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
15399
15400         * lib/modechange.c (mode_compile): Reject an invalid mode string
15401         that starts with an octal digit.  From Andreas Gruenbacher.
15402
15403         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
15404         and dup to open_safer and dup_safer, respectively.
15405         (openat_permissive): Fix typo in comment.
15406
15407         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
15408         "gettext.h"; either no longer needed or are guaranteed by openat.h.
15409         (_): Remove; no longer needed.
15410         (openat): Renamed from rpl_openat; no need for rpl_openat
15411         since openat.h renames openat for us.
15412         Replace most of the body with a call to openat_permissive,
15413         to avoid duplicate code.
15414         Port to (probably hypothetical) environments were mode_t is
15415         wider than int.
15416         (openat_permissive): Require mode arg, so that we can check
15417         types better.  Put it just after flags.  Change cwd failure
15418         indicator from pointer-to-bool to pointer-to-errno-value.
15419         All callers changed.
15420         Invoke openat_save_fail and/or openat_restore_fail if
15421         cwd_errno is null, so that openat can call us.
15422         (openat_permissive, fdopendir, fstatat, unlinkat):
15423         Simplify errno handling to avoid some duplicate code,
15424         as it's OK to set errno on success.
15425         * lib/openat.h: Revamp code so that function macros depend on
15426         __OPENAT_PREFIX only, not also on AT_FDCWD.
15427         (openat_ro): Remove.  Caller changed to use openat_permissive.
15428         (openat_permissive): Now a macro, if not a function.
15429         (openat_restore_fail, openat_save_fail): Now always functions,
15430         since mkdirat needs them even if __OPENAT_PREFIX is defined.
15431
15432         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
15433         and openat.c.
15434         * lib/mkdirat.c: Include openat-priv.h.
15435         Remove definitions of macros defined therein.
15436         * lib/openat.c: Likewise.
15437
15438         * lib/mkdirat.c (mkdirat): New file and function.
15439         * lib/openat.h (mkdirat): Declare.
15440
15441         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
15442
15443         * lib/openat.h (openat_permissive): Declare.
15444         (openat_ro): Define.
15445
15446         * lib/openat.c (EXPECTED_ERRNO): New macro.
15447         (openat_permissive): New function -- used in remove.c rewrite.
15448         (all functions): Set errno just before returning, only if there
15449         was an actual failure.
15450         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
15451
15452         Emulate openat-family functions using Linux's procfs, if possible.
15453         Idea and some code based on Ulrich Drepper's glibc changes.
15454
15455         * lib/openat.c: (BUILD_PROC_NAME): New macro.
15456         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
15457         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
15458         before falling back on save_cwd and restore_cwd.
15459         (fdopendir, fstatat, unlinkat): Likewise.
15460
15461         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
15462         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
15463
15464         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
15465         as second argument to va_arg.  Otherwise, some versions of gcc
15466         warn that `if this code is reached, the program will abort'.
15467
15468 2006-01-09  Jim Meyering  <jim@meyering.net>
15469
15470         Sync from coreutils.
15471         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
15472         Require openat-priv.h.
15473
15474 2006-01-09  Bruno Haible  <bruno@clisp.org>
15475
15476         * modules/strnlen (Include): Use strnlen.h.
15477
15478 2006-01-09  Bruno Haible  <bruno@clisp.org>
15479
15480         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
15481
15482 2006-01-09  Bruno Haible  <bruno@clisp.org>
15483
15484         * lib/sysexit_.h (EX_OK): New macro.
15485         Suggested by Martin Lambers <marlam@marlam.de>.
15486
15487 2006-01-09  Bruno Haible  <bruno@clisp.org>
15488
15489         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
15490         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
15491
15492 2006-01-09  Bruno Haible  <bruno@clisp.org>
15493
15494         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
15495         numbers.
15496
15497 2006-01-09  Bruno Haible  <bruno@clisp.org>
15498
15499         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
15500         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
15501         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
15502         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
15503
15504 2006-01-09  Bruno Haible  <bruno@clisp.org>
15505
15506         * build-aux/javacomp.sh.in: New file, moved from lib/.
15507         * modules/javacomp-script (Files): Update.
15508         (configure.ac): Add AC_CONFIG_FILES invocation.
15509         (EXTRA_DIST): Remove variable.
15510
15511         * build-aux/javaexec.sh.in: New file, moved from lib/.
15512         * modules/javaexec (Files): Update.
15513         (configure.ac): Add AC_CONFIG_FILES invocation.
15514         (EXTRA_DIST): Remove javaexec.sh.in.
15515
15516         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
15517         * modules/csharpcomp-script (Files): Update.
15518         (configure.ac): Add AC_CONFIG_FILES invocation.
15519         (EXTRA_DIST): Remove variable.
15520
15521         * build-aux/csharpexec.sh.in: New file, moved from lib/.
15522         * modules/csharpexec (Files): Update.
15523         (configure.ac): Add AC_CONFIG_FILES invocation.
15524         (EXTRA_DIST): Remove csharpexec.sh.in.
15525
15526 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
15527
15528         Sync from coreutils.
15529
15530         Add POSIX ACL support
15531         * lib/acl.h (copy_acl, set_acl): Add declarations.
15532         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
15533         systems other than Linux.
15534         (chmod_or_fchmod): New function: use fchmod when possible,
15535         and chmod otherwise.
15536         (file_has_acl): Add a POSIX ACL implementation, with a
15537         Linux-specific subcase.
15538         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
15539         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
15540         acls are unsupported.
15541         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
15542         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
15543         are unsupported.
15544
15545 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
15546
15547         Sync from coreutils.
15548         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
15549
15550 2006-01-07  Bruno Haible  <bruno@clisp.org>
15551
15552         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
15553         gl_EARLY.
15554
15555 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
15556
15557         * lib/strftime.c (tzname): Don't declare if it is already #defined.
15558         Problem reported for Mingw by Mark Junker.
15559
15560 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
15561
15562         * README: Gnulib normally doesn't generate a tarball.
15563
15564 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
15565
15566         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
15567         long int, not int, for nanosecond counts, so that people who are
15568         used to POSIX struct timespec won't be surprised.  Reported by Jim
15569         Meyering.
15570
15571 2005-12-28  Bruno Haible  <bruno@clisp.org>
15572
15573         * build-aux/config.rpath: Update from GNU gettext.
15574
15575 2005-12-16  Jim Meyering  <jim@meyering.net>
15576
15577         * modules/fprintftime: New module.
15578         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
15579
15580 2005-12-16  Jim Meyering  <jim@meyering.net>
15581
15582         * m4/fprintftime.m4: New file.
15583
15584 2005-12-16  Jim Meyering  <jim@meyering.net>
15585
15586         * lib/fprintftime.c, lib/fprintftime.h: New files.
15587
15588 2005-12-15  Simon Josefsson  <jas@extundo.com>
15589
15590         * modules/socklen (configure.ac): Fix M4 macro name, to align with
15591         new m4/socklen.m4.
15592
15593 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
15594
15595         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
15596         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
15597
15598 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
15599
15600         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
15601         * lib/argp-help.c (fill_in_uparams): Check if the constructed
15602         struct uparams is valid. Fall back to the default values if it is
15603         not.
15604
15605 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15606
15607         * modules/argp (Files): Add argp-pin.c
15608         (Depends-on): dirname
15609         (lib_SOURCES): Add argp-pin.c
15610
15611 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15612
15613         * m4/argp.m4:  Check if program_invocation_name and
15614         program_invocation_short_name are declared and define appropriate
15615         macros if they are not.
15616
15617 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15618
15619         * lib/argp-help.c (__argp_base_name): New function
15620         (__argp_short_program_name): Rewrite using __argp_base_name
15621         * lib/argp-namefrob.h: Define program_invocation_name and
15622         program_invocation_short_name if requested
15623         (__argp_base_name): Add prototype
15624         * lib/argp-parse.c (argp_def): Use gettext wrappers
15625         (argp_default_parser): Use __argp_base_name
15626         * lib/argp-pin.c: New file. Defines program_invocation_name and
15627         program_invocation_short_name on systems that lack them.
15628
15629 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
15630
15631         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
15632         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
15633         porting problem reported by Georg Schwarz in
15634         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
15635
15636 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
15637
15638         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
15639         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
15640         porting problem reported by Georg Schwarz in
15641         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
15642
15643 2005-12-05  Bruno Haible  <bruno@clisp.org>
15644
15645         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
15646         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
15647         Reported by Mark Junker <mjscod@gmx.de>.
15648
15649 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
15650
15651         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
15652         Use implementation from Albert Chin, with some
15653         comments/corrections by Stepan Kasal and myself.
15654
15655 2005-12-02  Bruno Haible  <bruno@clisp.org>
15656
15657         * gnulib-tool (func_import): Accept GPLed build tool modules when
15658         --lgpl is given.
15659         * modules/csharpcomp-script: New file.
15660         * modules/csharpcomp: Depend on it.
15661         * modules/javacomp-script: New file.
15662         * modules/javacomp: Depend on it.
15663         Suggested by Simon Josefsson.
15664
15665 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
15666
15667         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
15668         statement, to work around an HP-UX 10.20 compiler bug reported by
15669         Peter O'Gorman.
15670
15671 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
15672
15673         * modules/savedir (Depends-on): Add openat.
15674
15675 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
15676
15677         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
15678         (uintmax_t) [defined uintmax_t]: Do not declare.
15679         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
15680         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
15681         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
15682         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
15683         sake of portability to weird hosts that C allows (though we don't
15684         know of any practical examples).
15685
15686         * lib/savedir.h (fdsavedir): New decl.
15687         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
15688         contains most of the former guts of savedir.
15689         (savedir): Use savedirstream.
15690         Include "openat.h".
15691
15692 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
15693
15694         * modules/obstack (Files): Add m4/ulonglong.m4.
15695         Problem reported by Davide Angelocola.
15696
15697 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
15698
15699         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
15700         coreutils no longer futzes with rounding modes.
15701
15702 2005-11-14  Jim Meyering  <jim@meyering.net>
15703
15704         * lib/mkstemp-safer.c: Include <config.h>, required for possible
15705         replacement of mkstemp.
15706
15707 2005-11-10  Simon Josefsson  <jas@extundo.com>
15708
15709         * lib/readline.c: Remove EOL.
15710
15711 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15712
15713         * modules/gethrxtime (Depends-on): Add gettime.
15714
15715 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15716
15717         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
15718         or gettimeofday; no longer needed.
15719
15720 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15721
15722         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
15723         time business.
15724         (gethrxtime) [! (HAVE_NANOUPTIME
15725         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
15726         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
15727         our own approximation.
15728
15729 2005-11-08  Eric Blake  <ebb9@byu.net>
15730
15731         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
15732
15733 2005-11-08  Eric Blake  <ebb9@byu.net>
15734
15735         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
15736
15737 2005-11-04  Bruno Haible  <bruno@clisp.org>
15738
15739         * gnulib-tool: Implement --update mode.
15740
15741 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
15742
15743         Fix porting problem reported by Theodoros V. Kalamatianos.
15744         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
15745         Don't assume that futimes failing means we must fail.
15746
15747 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
15748
15749         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
15750         variables to suggest the intended function of the PATH_MAX check.
15751
15752 2005-10-30  Kean Johnston  <jkj@sco.com>
15753
15754         Trivial changes to support SCO systems.
15755         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
15756         as PATH_MAX.
15757         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
15758         where __ptr is null when no I/O is pending.
15759
15760 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15761
15762         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
15763         leave errno alone.  Problem reported by Dmitry V. Levin.
15764
15765 2005-10-28  Simon Josefsson  <jas@extundo.com>
15766
15767         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
15768         Test more.
15769
15770         * tests/test-gc-md2.c, tests/test-md2.c: New files.
15771
15772         * modules/md2, modules/md2-tests: New files.
15773
15774 2005-10-28  Simon Josefsson  <jas@extundo.com>
15775
15776         * m4/inet_ntop.m4: More tests.
15777
15778         * m4/gc-md2.m4, md2.m4: New file.
15779
15780 2005-10-28  Simon Josefsson  <jas@extundo.com>
15781
15782         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
15783         "restrict" keywords, as per POSIX.  Protect the function
15784         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
15785         Don't use K&R prototypes.  Check the sprintf return values.
15786         Re-define EAFNOSUPPORT if not present.  Indent.
15787
15788         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
15789         suggested by Bruno Haible <bruno@clisp.org>.
15790
15791         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
15792
15793         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
15794
15795         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
15796         libgcrypt).
15797
15798         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
15799
15800         * lib/md2.h, lib/md2.c: New files.
15801
15802 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
15803
15804         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
15805         errno alone.  Problem reported by Frederic Jolliton.
15806
15807 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
15808
15809         * modules/verify (License): Change from GPL to LGPL.  This is a
15810         tiny module and there are apparently near-equivalents that are
15811         under the BSD license.
15812
15813 2005-10-24  Simon Josefsson  <jas@extundo.com>
15814
15815         * modules/sha1: Relicense to LGPL.
15816
15817 2005-10-24  Simon Josefsson  <jas@extundo.com>
15818
15819         * lib/md4.h: Shrink buffer size, now that we changed the type.
15820
15821 2005-10-23  Simon Josefsson  <jas@extundo.com>
15822
15823         * gnulib-tool (func_import): Fix --tests-base.
15824
15825 2005-10-22  Simon Josefsson  <jas@extundo.com>
15826
15827         * modules/arcfour (Depends-on): Need stdint.
15828
15829 2005-10-22  Simon Josefsson  <jas@extundo.com>
15830
15831         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
15832         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
15833
15834 2005-10-22  Simon Josefsson  <jas@extundo.com>
15835
15836         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
15837         suggested by Bruno Haible <bruno@clisp.org>.
15838
15839 2005-10-22  Simon Josefsson  <jas@extundo.com>
15840
15841         * lib/crc.h: Include stddef.h, for size_t.
15842
15843 2005-10-22  Simon Josefsson  <jas@extundo.com>
15844
15845         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
15846         arcfour_context struct (simplify test vector testing in GNU
15847         Shishi).
15848
15849 2005-10-21  Simon Josefsson  <jas@extundo.com>
15850
15851         * modules/des, modules/des-tests: New files.
15852
15853         * modules/gc-des, modules/gc-des-tests: New files.
15854
15855         * tests/test-des.c, tests/test-gc-des.c: New file.
15856
15857 2005-10-21  Simon Josefsson  <jas@extundo.com>
15858
15859         * modules/arctwo, modules/arctwo-tests: New files.
15860
15861         * tests/test-arctwo.c: New file.
15862
15863         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
15864
15865         * tests/test-gc-arctwo.c: New file.
15866
15867 2005-10-21  Simon Josefsson  <jas@extundo.com>
15868
15869         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
15870         Bruno Haible <bruno@clisp.org>.
15871
15872         * m4/gc-des.m4: New file.
15873
15874 2005-10-21  Simon Josefsson  <jas@extundo.com>
15875
15876         * m4/arctwo.m4: New file.
15877
15878         * m4/gc-arctwo.m4: New file.
15879
15880 2005-10-21  Simon Josefsson  <jas@extundo.com>
15881
15882         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
15883         block.
15884
15885 2005-10-21  Simon Josefsson  <jas@extundo.com>
15886
15887         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
15888         <bruno@clisp.org>.
15889
15890         * lib/hmac-sha1.c (hmac_sha1): Likewise.
15891
15892         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
15893         Bruno Haible <bruno@clisp.org>.
15894
15895         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
15896         <bruno@clisp.org>.
15897
15898 2005-10-21  Simon Josefsson  <jas@extundo.com>
15899
15900         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
15901
15902 2005-10-21  Simon Josefsson  <jas@extundo.com>
15903
15904         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
15905
15906 2005-10-21  Simon Josefsson  <jas@extundo.com>
15907
15908         * lib/des.h, lib/des.c: New files.
15909
15910         * lib/gc-gnulib.c: Support DES.c
15911
15912 2005-10-21  Simon Josefsson  <jas@extundo.com>
15913
15914         * lib/arctwo.h, lib/arctwo.c: New files.
15915
15916         * lib/gc-gnulib.c: Support ARCTWO.
15917
15918 2005-10-21  Simon Josefsson  <jas@extundo.com>
15919
15920         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
15921         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15922
15923 2005-10-21  Simon Josefsson  <jas@extundo.com>
15924
15925         * gnulib-tool (func_import, func_create_testdir): Define automake
15926         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
15927         Makefile.am snippet),
15928         suggested by Bruno Haible <bruno@clisp.org>.
15929
15930         * modules/gc (Makefile.am): Use it.
15931
15932 2005-10-21  Bruno Haible  <bruno@clisp.org>
15933
15934         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
15935         patch.
15936
15937 2005-10-19  Simon Josefsson  <jas@extundo.com>
15938
15939         * tests/test-gc-rijndael.c: New file.
15940
15941         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
15942
15943 2005-10-19  Simon Josefsson  <jas@extundo.com>
15944
15945         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
15946         interface too.
15947
15948 2005-10-19  Simon Josefsson  <jas@extundo.com>
15949
15950         * tests/test-gc-arcfour.c: New file.
15951
15952         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
15953
15954 2005-10-19  Simon Josefsson  <jas@extundo.com>
15955
15956         * modules/gc-md4, modules/gc-md4-tests: New file.
15957
15958         * tests/test-gc-md4.c: New file.
15959
15960 2005-10-19  Simon Josefsson  <jas@extundo.com>
15961
15962         * m4/gc-md4.m4: New file.
15963
15964 2005-10-19  Simon Josefsson  <jas@extundo.com>
15965
15966         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
15967         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
15968         <kasal@ucw.cz>.
15969
15970 2005-10-19  Simon Josefsson  <jas@extundo.com>
15971
15972         * m4/gc-arcfour.m4: New file.
15973
15974         * m4/gc-rijndael.m4: New file.
15975
15976 2005-10-19  Simon Josefsson  <jas@extundo.com>
15977
15978         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
15979
15980 2005-10-19  Simon Josefsson  <jas@extundo.com>
15981
15982         * lib/gc-gnulib.c: Support ARCFOUR.
15983
15984 2005-10-19  Simon Josefsson  <jas@extundo.com>
15985
15986         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
15987         support.
15988
15989         * lib/gc.h: Add ECB enum type.
15990
15991         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
15992
15993 2005-10-18  Simon Josefsson  <jas@extundo.com>
15994
15995         * tests/test-md5.c: New file.
15996
15997         * modules/md5-tests: New file.
15998
15999 2005-10-18  Simon Josefsson  <jas@extundo.com>
16000
16001         * tests/test-md4.c: New file.
16002
16003         * modules/md4, modules/md4-tests: New files.
16004
16005 2005-10-18  Simon Josefsson  <jas@extundo.com>
16006
16007         * m4/md4.m4: New file.
16008
16009 2005-10-18  Simon Josefsson  <jas@extundo.com>
16010
16011         * lib/md4.h, lib/md4.c: New files, based on md5.?.
16012
16013 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
16014
16015         * gnulib-tool (func_create_testdir): Omit the second check whether
16016         BUILT_SOURCES in nonempty.
16017
16018 2005-10-17  Simon Josefsson  <jas@extundo.com>
16019
16020         * tests/test-rijndael.c: New file.
16021
16022 2005-10-17  Simon Josefsson  <jas@extundo.com>
16023
16024         * modules/sha1: Depend on stdint instead of md5.
16025
16026         * modules/md5: Depend on stdint, remove uint32_t.
16027
16028 2005-10-17  Simon Josefsson  <jas@extundo.com>
16029
16030         * modules/gc-sha1-tests: New file.
16031
16032         * tests/test-gc-sha1.c: New file.
16033
16034 2005-10-17  Simon Josefsson  <jas@extundo.com>
16035
16036         * m4/md5.m4: Remove call to uint32_t.m4.
16037
16038 2005-10-17  Simon Josefsson  <jas@extundo.com>
16039
16040         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
16041
16042         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
16043         md5.h.
16044
16045         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
16046
16047         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
16048
16049 2005-10-17  Simon Josefsson  <jas@extundo.com>
16050
16051         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
16052
16053 2005-10-17  Simon Josefsson  <jas@extundo.com>
16054
16055         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
16056
16057 2005-10-17  Simon Josefsson  <jas@extundo.com>
16058
16059         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
16060
16061         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
16062
16063 2005-10-17  Bruno Haible  <bruno@clisp.org>
16064
16065         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
16066         that it can also be used in a test.
16067
16068 2005-10-16  Bruno Haible  <bruno@clisp.org>
16069
16070         * gnulib-tool (func_emit_tests_Makefile_am): Also define
16071         TESTS_ENVIRONMENT, so that individual tests can augment it.
16072
16073         * gnulib-tool (func_create_testdir): Use an intermediate target for
16074         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
16075         macros, like $(ALLOCA_H), which cannot be passed through the command
16076         line.
16077
16078 2005-10-15  Simon Josefsson  <jas@extundo.com>
16079
16080         * modules/rijndael-tests: New file.
16081
16082         * modules/rijndael: New file.
16083
16084 2005-10-15  Simon Josefsson  <jas@extundo.com>
16085
16086         * m4/rijndael.m4: New file.
16087
16088 2005-10-15  Simon Josefsson  <jas@extundo.com>
16089
16090         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
16091
16092         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
16093
16094 2005-10-14  Simon Josefsson  <jas@extundo.com>
16095
16096         * tests/test-arcfour.c: New file.
16097
16098         * modules/arcfour, modules/arcfour-tests: New files.
16099
16100 2005-10-14  Simon Josefsson  <jas@extundo.com>
16101
16102         * m4/arcfour.m4: New file.
16103
16104 2005-10-14  Simon Josefsson  <jas@extundo.com>
16105
16106         * lib/arcfour.h, lib/arcfour.c: New files.
16107
16108 2005-10-14  Roland McGrath  <roland@redhat.com>
16109
16110         Import from libc.  [BZ #1331]
16111         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
16112         macro argument.
16113         Reported by Matej Vela <vela@debian.org>.
16114
16115 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16116
16117         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
16118         include <wchar.h>; no longer needed.
16119
16120 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16121
16122         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
16123
16124 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
16125         and  Ulrich Drepper  <drepper@redhat.com>
16126
16127         Import from libc.
16128         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
16129         instead of inline stream orientation test and two separate
16130         function calls.  Pay no attention to USE_IN_LIBIO.
16131
16132 2005-10-13  Simon Josefsson  <jas@extundo.com>
16133
16134         * modules/gc-hmac-md5-tests: New file.
16135
16136         * tests/test-gc-hmac-sha1.c: New file.
16137
16138         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
16139
16140         * modules/gc-hmac-md5-tests: New file.
16141
16142         * tests/test-gc-md5.c: New file.
16143
16144         * modules/gc-md5-tests: New file.
16145
16146 2005-10-13  Simon Josefsson  <jas@extundo.com>
16147
16148         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
16149         Move memory allocation outside of loop.
16150
16151 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
16152
16153         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
16154         intermediate directory is in a read-only file system.  Problem
16155         reported by Eric Blake.
16156
16157 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
16158
16159         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
16160
16161 2005-10-12  Simon Josefsson  <jas@extundo.com>
16162
16163         * tests/test-hmac-sha1.c: New file.
16164
16165         * modules/hmac-sha1-tests: New file.
16166
16167         * modules/hmac-sha1: New file.
16168
16169 2005-10-12  Simon Josefsson  <jas@extundo.com>
16170
16171         * modules/gc-sha1: New file.
16172
16173 2005-10-12  Simon Josefsson  <jas@extundo.com>
16174
16175         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
16176
16177         * tests/test-gc-pbkdf2-sha1.c: New file.
16178
16179 2005-10-12  Simon Josefsson  <jas@extundo.com>
16180
16181         * modules/gc-md5, modules/gc-hmac-md5: New files.
16182
16183         * modules/gc (Files): Remove md5, memxor and hmac files.
16184
16185 2005-10-12  Simon Josefsson  <jas@extundo.com>
16186
16187         * m4/gc-pbkdf2-sha1.m4: New file.
16188
16189         * m4/gc-hmac-sha1.m4: New file.
16190
16191         * m4/gc-sha1: New file.
16192
16193         * m4/hmac-sha1.m4: New file.
16194
16195 2005-10-12  Simon Josefsson  <jas@extundo.com>
16196
16197         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
16198
16199         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
16200
16201 2005-10-12  Simon Josefsson  <jas@extundo.com>
16202
16203         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
16204         suggested by Bruno Haible <bruno@clisp.org>.
16205
16206 2005-10-12  Simon Josefsson  <jas@extundo.com>
16207
16208         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
16209
16210 2005-10-12  Simon Josefsson  <jas@extundo.com>
16211
16212         * lib/gc-pbkdf2-sha1.c: New file.
16213
16214         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
16215
16216 2005-10-12  Simon Josefsson  <jas@extundo.com>
16217
16218         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
16219
16220         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
16221
16222 2005-10-12  Simon Josefsson  <jas@extundo.com>
16223
16224         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
16225         GC_USE_HMAC_MD5, respectively.
16226
16227         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
16228         (gc_md5): Fix typo.
16229
16230         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
16231
16232         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
16233
16234         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
16235
16236 2005-10-12  Bruno Haible  <bruno@clisp.org>
16237
16238         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
16239         Reported by Stepan Kasal <kasal@ucw.cz>.
16240
16241 2005-10-11  Simon Josefsson  <jas@extundo.com>
16242
16243         * tests/test-crc.c: New file.
16244
16245         * modules/crc, modules/crc-tests: New files.
16246
16247 2005-10-11  Simon Josefsson  <jas@extundo.com>
16248
16249         * m4/crc.m4: New file.
16250
16251 2005-10-11  Simon Josefsson  <jas@extundo.com>
16252
16253         * lib/gc.h: Add gc_hash and gc_hash_buffer.
16254
16255         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
16256
16257         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
16258
16259 2005-10-11  Simon Josefsson  <jas@extundo.com>
16260
16261         * lib/crc.h, lib/crc.c: New files.
16262
16263         * lib/gc.h (gc_hash_buffer): Add doc.
16264
16265 2005-10-11  Bruno Haible  <bruno@clisp.org>
16266
16267         * modules/c-strcasestr: New file.
16268         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
16269
16270 2005-10-11  Bruno Haible  <bruno@clisp.org>
16271
16272         * modules/c-strcase: New file.
16273         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
16274
16275 2005-10-11  Bruno Haible  <bruno@clisp.org>
16276
16277         * lib/strcasecmp.c: Include limits.h.
16278         (strcasecmp): Avoid integer overflow on exotic platforms.
16279         * lib/strncasecmp.c: Include limits.h.
16280         (strncasecmp): Avoid integer overflow on exotic platforms.
16281         Reported by Paul Eggert.
16282
16283 2005-10-11  Bruno Haible  <bruno@clisp.org>
16284
16285         * lib/c-strcasestr.h: New file, from GNU gettext.
16286         * lib/c-strcasestr.c: New file, from GNU gettext.
16287
16288 2005-10-11  Bruno Haible  <bruno@clisp.org>
16289
16290         * lib/c-strcase.h: New file, from GNU gettext.
16291         * lib/c-strcasecmp.c: New file, from GNU gettext.
16292         * lib/c-strncasecmp.c: New file, from GNU gettext.
16293
16294 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
16295
16296         * modules/mempcpy (License): GPL -> LGPL.
16297         * modules/strchrnul (License): Likewise.
16298         * modules/sysexits (License): Likewise.
16299
16300 2005-10-08  Simon Josefsson  <jas@extundo.com>
16301
16302         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
16303
16304 2005-10-07  Simon Josefsson  <jas@extundo.com>
16305
16306         * m4/memxor.m4: Remove gl_C_RESTRICT call.
16307
16308 2005-10-06  Simon Josefsson  <jas@extundo.com>
16309
16310         * tests/test-hmac-md5.c: New file.
16311
16312         * modules/hmac-md5-tests: New file.
16313
16314         * modules/hmac-md5: New file.
16315
16316 2005-10-06  Simon Josefsson  <jas@extundo.com>
16317
16318         * m4/hmac-md5.m4: New file.
16319
16320         * m4/memxor.m4: Require gl_C_RESTRICT.
16321
16322 2005-10-06  Simon Josefsson  <jas@extundo.com>
16323
16324         * lib/memxor.c (memxor): Avoid casts and warnings.
16325
16326 2005-10-06  Simon Josefsson  <jas@extundo.com>
16327
16328         * lib/hmac-md5.c: New file.
16329
16330         * lib/hmac.h: New file.
16331
16332 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
16333
16334         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
16335         promotes to int, not unsigned int, to catch the AIX 5.3
16336         compiler bug.
16337
16338 2005-10-05  Simon Josefsson  <jas@extundo.com>
16339
16340         * modules/memxor: New file.
16341
16342         * modules/iconv (Files): Move config.rpath to havelib, it is used
16343         there.
16344
16345         * modules/havelib (Files): Add config.rpath.
16346
16347 2005-10-05  Simon Josefsson  <jas@extundo.com>
16348
16349         * m4/memxor.m4: New file.
16350
16351 2005-10-05  Simon Josefsson  <jas@extundo.com>
16352
16353         * lib/memxor.c (memxor): Fix compiler error.
16354
16355         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
16356         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
16357
16358         * lib/memxor.h, lib/memxor.c: New files.
16359
16360         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
16361         we assume all systems have it, suggested by Jim Meyering
16362         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
16363         any systems lack sys/socket.h; mingw32 is known to lack it, but we
16364         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
16365         same reasons.
16366
16367 2005-10-05  Simon Josefsson  <jas@extundo.com>
16368
16369         * config/srclist.txt: Add glibc bug 1423 for md5.h.
16370
16371 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
16372
16373         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
16374         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
16375         needed, since the source code now assumes these .h files.
16376
16377 2005-10-05  Derek Price  <derek@ximbiot.com>
16378
16379         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
16380
16381 2005-10-05  Bruno Haible  <bruno@clisp.org>
16382
16383         * modules/stdint (License): Change to LGPL.
16384
16385 2005-10-04  Simon Josefsson  <jas@extundo.com>
16386
16387         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
16388         D. Baushke" <mdb@gnu.org>.
16389
16390 2005-10-04  Bruno Haible  <bruno@clisp.org>
16391
16392         * lib/verify.h (verify_true): Provide alternative definition for C++.
16393
16394 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
16395
16396         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
16397         (SSIZE_MAX): New macro, if not already defined.
16398         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
16399         than 2 GiB.
16400
16401 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16402
16403         Sync from coreutils.
16404         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
16405         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
16406         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
16407         ULLONG_MAX doesn't work with 2.7.2.1.
16408
16409 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16410
16411         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
16412         From Ben Pfaff.
16413
16414         * modules/exclude (Depends-on): Depend on verify.
16415         * modules/strtoimax (Depends-on): Likewise.
16416         * modules/utimecmp (Depends-on): Likewise.
16417
16418 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16419
16420         * lib/exclude.c: Include verify.h.
16421         (verify): Remove.  All callers changed to use verify.h's version.
16422         * lib/strtoimax.c: Likewise.
16423         * lib/utimecmp.c: Likewis.e
16424
16425         Sync from coreutils.
16426         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
16427         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
16428         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
16429         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
16430         bother returning ENOSYS if settimeofday or stime fails; just let
16431         them return whatever errno they want to return.
16432         * lib/utimens.c: Include unistd.h, for dup2.
16433         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
16434         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
16435
16436 2005-10-02  Jim Meyering  <jim@meyering.net>
16437
16438         Sync from coreutils.
16439         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
16440         from glibc-2.2.5 that fails for read-only files.
16441
16442 2005-10-02  Jim Meyering  <jim@meyering.net>
16443
16444         Sync from coreutils.
16445         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
16446         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
16447         `#if HAVE_CONFIG_H'.
16448         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
16449         Remove AT_FDCWD test.
16450         Do not consume the fd unless successful.
16451         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
16452         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
16453         block, so that we don't even try to compile it if settimeofday is
16454         available.  This works around a compilation failure on OSF1 V5.1,
16455         due to stime requiring a `long int*' while tv_sec is `int'.
16456
16457 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
16458
16459         Sync from coreutils.
16460         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
16461         against `yes', rather than just testing for nonempty.
16462
16463 2005-10-01  Simon Josefsson  <jas@extundo.com>
16464
16465         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
16466         and Darwin.
16467
16468         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
16469         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
16470         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
16471         freeaddrinfo and gai_strerror are declared by the POSIX headers.
16472         Check if struct addrinfo is declared.
16473
16474 2005-10-01  Simon Josefsson  <jas@extundo.com>
16475
16476         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
16477         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
16478         AI_* and EAI_* definitions.  Protect function declarations.
16479
16480 2005-10-01  Jim Meyering  <jim@meyering.net>
16481
16482         Sync from coreutils.
16483
16484         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
16485         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
16486         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
16487         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16488         in the inet and nsl libraries.  Required on Solaris 5.7.
16489
16490 2005-10-01  Jim Meyering  <jim@meyering.net>
16491
16492         Sync from coreutils.
16493         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16494         in the inet and nsl libraries.  Required on Solaris 5.7.
16495
16496 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
16497
16498         * lib/getdelim.c (getdelim): Remove unused variables.
16499
16500 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
16501
16502         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
16503         so that the code works even with ancient cpp.  Portability problem
16504         with GCC 2.7.2.1 reported by Thomas M.Ott.
16505
16506 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
16507
16508         * modules/regex (Depends-on): Add strcase.
16509
16510         * modules/gethostname (Licence): Change from GPL to LGPL, since
16511         gethostname.c is a trivial implementation of a standard library
16512         function.
16513         * modules/poll (License): Change from GPL to LGPL, since it's
16514         derived from LGPL code.
16515
16516 2005-09-27  Jim Meyering  <jim@meyering.net>
16517
16518         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
16519         HAVE_CONFIG_H.
16520
16521         * lib/intprops.h (signed_type_or_expr__): Define.
16522         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
16523         for unsigned types.
16524
16525 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
16526
16527         * lib/verify.h (verify_expr): Remove, replacing with:
16528         (verify_true): New macro that returns true instead of void.
16529         (verify_type__): Remove.
16530         (verify): Use verify_true rather than verify_type__.
16531
16532 2005-09-26  Bruno Haible  <bruno@clisp.org>
16533
16534         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
16535         is necessary.
16536         (lib_SOURCES): Remove mbchar.c.
16537         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
16538         (Files): Add m4/mbrtowc.m4.
16539         * modules/mbiter: Likewise.
16540         * modules/mbuiter: Likewise.
16541
16542 2005-09-26  Bruno Haible  <bruno@clisp.org>
16543
16544         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
16545         compile mbchar.c if they are not both present.
16546         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
16547         * m4/mbiter.m4 (gl_MBITER): Likewise.
16548         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
16549         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
16550         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
16551
16552 2005-09-25  Jim Meyering  <jim@meyering.net>
16553
16554         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
16555         also uses socklen_t.
16556
16557 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
16558
16559         * lib/utimens.c (ENOSYS): Define if not already defined.
16560         (futimens): Support having a null PATH if the file descriptor
16561         is nonnegative.
16562
16563         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
16564         Remove.
16565         (__attribute): Define to empty unless GCC 3.1 or later.
16566         This works around a core dump on OpenBSD 3.4, which has GCC
16567         2.95.3, which dumps core when given __attribute__(()).  It also
16568         simplifies other tests, since we really don't want to bother with
16569         worrying about which ancient version of GCC supported what.
16570         Original problem reported by Yoann Vandoorselaere, with part of
16571         the fix suggested by Derek Price.
16572
16573 2005-09-24  Jim Meyering  <jim@meyering.net>
16574
16575         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
16576         so we can once again use a positive bitfield width of 1 -- now we
16577         don't have to explain why we were using a bitfield width of 2.
16578
16579 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
16580
16581         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
16582         and similarly for the other external symbols.  Problem reported
16583         by James Gallager.
16584
16585         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
16586         bug reported by Jim Meyering.
16587
16588         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
16589         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
16590         not needed, since socklen is a prerequisite module.
16591
16592 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
16593
16594         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
16595         Problem reported by Eric Blake.
16596         (getaddrinfo): Initialize se so that it's not garbage.
16597         Redo internal storage allocation so that it doesn't make unportable
16598         assumptions about alignment.
16599         Fix a memory leak.
16600
16601         * lib/utimens.c (futimens): Use futimesat if available.
16602         Prefer it to futimes since it doesn't have the futimes bug.
16603
16604         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
16605         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
16606         Instead, declare a function that returns a pointer to an array,
16607         and use verify_type__ to declare the size of the array.
16608         Problem and germ of a solution reported by Bruno Haible.
16609         (verify_type__): Use 2, not 1, for bitfield size, to avoid
16610         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
16611
16612 2005-09-23  Jim Meyering  <jim@meyering.net>
16613
16614         Sync from coreutils.
16615         Correct build failure (socklen_t not defined) on at least
16616         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
16617         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
16618
16619 2005-09-23  Jim Meyering  <jim@meyering.net>
16620
16621         * modules/getaddrinfo (Depends-on): Add socklen.
16622
16623 2005-09-23  Bruno Haible  <bruno@clisp.org>
16624
16625         * tests/test-verify.c: New file.
16626
16627 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16628
16629         Sync from coreutils.
16630
16631         * modules/argmatch (Depends-on): Add verify.
16632         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
16633         unistd-safer.
16634         * modules/save-cwd (Depends-on): Likewise.
16635
16636         * modules/openat (Files): Add lib/openat-die.c.
16637         (Depends-on): Remove error, exitfail.
16638         Add dirname.
16639
16640         * modules/verify: New file.
16641         * MODULES.html.sh (Diagnostics <assert.h>): New section,
16642         with "verify" module.
16643
16644 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16645
16646         Sync from coreutils.
16647
16648         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
16649         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
16650         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
16651         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
16652         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
16653         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
16654         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
16655         Don't bother checking for string.h, stdlib.h, unistd.h.
16656         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
16657         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
16658         module's job.
16659         * m4/jm-macros.m4 (gl_MACROS): Likewise.
16660         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
16661
16662         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
16663         (gl_GETDATE): Use it.
16664
16665         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
16666
16667 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16668
16669         Sync from coreutils.
16670
16671         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
16672         stat-time.h.
16673         * lib/argmatch.h: Include verify.h
16674         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
16675         (ARGMATCH_ASSERT): Remove; unused.
16676         * lib/canonicalize.c: Assume STDC_HEADERS.
16677         * lib/exclude.c: Include "strcase.h".
16678         * lib/regex_internal.h [!defined _LIBC]: Likewise.
16679         * lib/getusershell.c: Include stdio--.h rather than stdio.h
16680         and stdio-safer.h.
16681         (getusershell): Call fopen, not fopen_safer.
16682         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
16683         Do not include unistd-safer.h.
16684         (save_cwd): Don't call fd_safer; no longer needed
16685         now that we include fcntl--.h.
16686
16687         * lib/getdate.y (relative_time): New type.
16688         (RELATIVE_TIME_0): New constant.
16689         (parser_control): Use relative_time instead of doing it ourselves.
16690         (%union): Add new relative_time rel member.
16691         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
16692         Now typeless.
16693         (relunit, relunit_snumber): Now of type rel.
16694         (zone, rel, relunit, get_date): Adjust to above changes.
16695
16696         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
16697         Do not include unistd-safer.h.
16698         (getloadavg): Don't call fd_safer; no longer needed
16699         now that we include fcntl--.h.
16700
16701         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
16702         (make_dir_parents): Treat ENOSYS like EEXIST.
16703
16704         Improve quality of diagnostics on restore_cwd failure.
16705         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
16706         (make_dir_parents): Last arg is now int * (for errno), not bool *.
16707         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
16708         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
16709         each time through the loop.  Do not diagnose restore_cwd failure;
16710         that is the caller's job (and perhaps the caller does not care).
16711
16712         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
16713         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
16714         If the file already exists but is not a directory, don't bother
16715         to try to make its parents.
16716         Close potential file descriptor leak if we can't chdir("/") (!).
16717         Don't always return true if chdir($PWD) fails; return true only
16718         if the requested action was done successfully (except for the
16719         chdir($PWD)).
16720         Don't log final directory unless we actually made it.
16721         Refactor to avoid duplicate code to fix up permissions.
16722         Don't attempt to fix up parent permissions if chdir($PWD) fails.
16723
16724         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
16725         to make it a bit faster and (I hope) clearer.
16726         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
16727         Fix bug in formats like %2N.
16728
16729         * lib/verify.h: New file.
16730
16731 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16732
16733         Sync from coreutils.
16734         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
16735
16736 2005-09-22  Jim Meyering  <jim@meyering.net>
16737
16738         Sync from coreutils.
16739
16740         * m4/lstat.m4 (gl_FUNC_LSTAT):
16741         Use AC_LIBSOURCES to require lstat.c and lstat.h.
16742         Remove obsolete comment.
16743         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
16744         * m4/xstrtod.m4: Likewise.
16745
16746         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
16747
16748 2005-09-22  Jim Meyering  <jim@meyering.net>
16749
16750         Sync from coreutils.
16751
16752         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
16753
16754         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
16755         the .tm_year member, since otherwise gcc-4.0 would now warn about
16756         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
16757
16758         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
16759         order to avoid an unsuppressible warning from gcc on 64-bit systems.
16760
16761         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
16762         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
16763         when run in a time zone for which daylight savings time is in effect
16764         for the starting date.
16765
16766         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
16767         stop us from restricting permissions of just-created absolute-named
16768         directories.
16769         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
16770         to restore initial working directory.
16771         * lib/mkdir-p.c (make_dir_parents): New parameter:
16772         different_working_dir, to tell caller if/when we change the working
16773         directory and are unable to return to the initial one.
16774         * lib/mkdir-p.h (make_dir_parents): Update prototype.
16775         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
16776         `return false'.  This fixes a bug introduced on 2004-07-30.
16777
16778         * lib/openat.c (fdopendir): Be sure to close the supplied
16779         file descriptor before returning.  This makes our replacement
16780         implementation a little closer to Solaris's, where fdopendir
16781         ties the file descriptor to the returned DIR* pointer.
16782         * lib/openat.c (unlinkat): New function.
16783         * lib/openat.h (unlinkat): Add prototype.
16784         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
16785         (openat_restore_fail): Rename from openat_restore_die.
16786         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
16787
16788         Provide an alternative to exiting immediately upon save_cwd or
16789         restore_cwd failure.  Now, an application can arrange e.g.,
16790         to perform a longjump in that case.
16791         * lib/openat.c: Include dirname.h.
16792         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
16793         (rpl_openat, fdopendir, fstatat): Call openat_save_die
16794         and openat_restore_die rather than calling error directly.
16795         Don't include "error.h" or "exitfail.h"; they're no longer needed.
16796
16797         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
16798         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
16799         define.
16800
16801         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
16802         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
16803                             int utc, int nanoseconds);
16804         Background:
16805         date should not have to allocate a megabyte of virtual memory to
16806         handle a format argument like +%1048575T.  When implemented with
16807         strftime, it must allocate such a buffer, use strftime to fill it
16808         in, print it, then free it.
16809         With fprintftime, it simply prints everything and exits.
16810         With no need for memory allocation, that's one fewer way to fail.
16811         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
16812         optional field width, not before, so we accept %9:z, not %:9z.
16813         (my_strftime): Be sure to use L_('x') for literals.
16814
16815         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
16816         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
16817         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
16818         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
16819         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
16820         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
16821         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
16822         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
16823         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
16824         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
16825         * lib/xgethostname.c, lib/xreadlink.c:
16826         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
16827
16828         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
16829         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
16830         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
16831         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
16832         and don't include <sys/file.h>).
16833
16834 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
16835
16836         Sync from coreutils.
16837
16838         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
16839         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
16840         [!LDAV_DONE]: Avoid unused variable warning.
16841
16842 2005-09-21  Bruno Haible  <bruno@clisp.org>
16843
16844         * lib/unicodeio.h (unicode_to_mb): New declaration.
16845
16846 2005-09-20  Derek Price  <derek@ximbiot.com>
16847
16848         * lib/getaddrinfo.c: Don't include <netdb.h> included from
16849         getaddrinfo.h.
16850
16851 2005-09-20  Bruno Haible  <bruno@clisp.org>
16852
16853         * gnulib-tool: Remove trailing slashes from the values specified for
16854         --source-base, --m4-base, --tests-base, --aux-dir.
16855         Suggested by Simon Josefsson <jas@extundo.com>.
16856
16857 2005-09-20  Bruno Haible  <bruno@clisp.org>
16858
16859         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
16860         func_modules_to_filelist, func_import, func_create_testdir): Make all
16861         sorting results locale-independent, so that gnulib-cache.m4 doesn't
16862         change when gnulib-tool is invoked in a different locale.
16863
16864 2005-09-19  Simon Josefsson  <jas@extundo.com>
16865
16866         * m4/socklen.m4: Fix typo.
16867
16868 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
16869
16870         Use a consistent style for including <config.h>.
16871         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
16872         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
16873         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
16874         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
16875         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
16876         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
16877         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
16878         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
16879         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
16880         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
16881         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
16882         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
16883         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
16884         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
16885         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
16886         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
16887         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
16888         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
16889         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
16890         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
16891         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
16892         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
16893         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
16894         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
16895         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
16896         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
16897         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
16898         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
16899         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
16900         lib/xstrtoumax.c, lib/yesno.c:
16901         Standardize inclusion of config.h.
16902         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
16903         lib/inttostr.h:  Removed inclusion of config.h from header files.
16904         * lib/inttostr.c:  Adjusted in-tree users.
16905         * lib/timespec.h: Remove superfluous warning to include config.h.
16906         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
16907         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
16908         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
16909         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
16910         config.h with HAVE_CONFIG_H.
16911
16912 2005-09-19  Jim Meyering  <jim@meyering.net>
16913
16914         * modules/pathmax (License): Change to LGPL.
16915
16916 2005-09-19  Derek Price  <derek@ximbiot.com>
16917
16918         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
16919
16920 2005-09-19  Bruno Haible  <bruno@clisp.org>
16921
16922         * gnulib-tool (import): Provide default for --tests-base.
16923
16924 2005-09-19  Bruno Haible  <bruno@clisp.org>
16925
16926         * doc/quote.texi: New file, extracted from gnulib.texi.
16927         * doc/ctime.texi: New file, extracted from gnulib.texi.
16928         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
16929         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
16930         * doc/gnulib.texi: Include them.
16931
16932 2005-09-18  Bruno Haible  <bruno@clisp.org>
16933
16934         Portability fix.
16935         * gnulib-tool (func_readlink): New function.
16936         (func_ln_if_changed): Use it.
16937
16938 2005-09-18  Bruno Haible  <bruno@clisp.org>
16939
16940         * gnulib-tool: Support --with-tests also with --import.
16941         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
16942         (func_import): Use variables $testsbase and $inctests. Emit a
16943         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
16944         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
16945         SUBDIRS += $testsdir.
16946         (func_create_testdir): Update.
16947
16948 2005-09-18  Bruno Haible  <bruno@clisp.org>
16949
16950         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
16951         instead of $dry_run.
16952         (func_cp_if_changed, func_mv_if_changed): Remove functions.
16953         (func_ln_if_changed): Don't handle dry-run here.
16954         (func_import): In dry-run mode, detect more precisely which actions
16955         would be performed, and don't use "...ing" verbs.
16956
16957 2005-09-18  Bruno Haible  <bruno@clisp.org>
16958
16959         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
16960         (func_import): Use join on two temporary files instead of three nested
16961         loops, in order to determine which files are new or old.
16962
16963 2005-09-18  Bruno Haible  <bruno@clisp.org>
16964
16965         * gnulib-tool (func_import): Comment out code that spits out the
16966         new files with --dry-run.
16967
16968 2005-09-18  Bruno Haible  <bruno@clisp.org>
16969
16970         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
16971
16972 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
16973
16974         * lib/stat-time.h: New file.
16975         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
16976         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
16977         in a different way.
16978         (timespec_cmp): New function.
16979         * lib/utimecmp.c: Include stat-time.h.
16980         (SYSCALL_RESOLUTION): Depend on whether various struct stat
16981         members exist, not on the obsolescent ST_MTIM_NSEC.
16982         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
16983
16984 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
16985
16986         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
16987
16988 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
16989
16990         * MODULES.html.sh (File system functions): Add stat-time.
16991         * modules/stat-time: New file.
16992         * modules/timespec (Files): Remove m4/st_mtim.m4; this
16993         is now done in a different way, by the stat-time module.
16994         * modules/utimecmp (Depends-on): Add stat-time.
16995
16996 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
16997
16998         * m4/st_mtim.m4: Remove.  Superseded by...
16999         * m4/stat-time.m4: New file.
17000         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
17001         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
17002
17003 2005-09-15  Derek Price  <derek@ximbiot.com>
17004
17005         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
17006
17007 2005-09-15  Derek Price  <derek@ximbiot.com>
17008
17009         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
17010         * lib/regex_internal.c: Ditto, using this...
17011         (__GNUC_PREREQ): ...new macro.
17012         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
17013         using...
17014         (__GNUC_PREREQ): ...this new macro.
17015
17016         * lib/strstr.h: Include string.h. Define strstr as a macro here.
17017
17018 2005-09-15  Derek Price  <derek@ximbiot.com>
17019             Paul Eggert  <eggert@cs.ucla.edu>
17020
17021         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
17022         changes, consolidating in...
17023         * lib/regex_internal.h: ...this file.
17024
17025 2005-09-13  Jim Meyering  <jim@meyering.net>
17026
17027         * lib/canon-host.c: Filter through gnu indent and reword comments
17028         slightly.
17029         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
17030
17031 2005-09-13  Derek Price  <derek@ximbiot.com>
17032
17033         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
17034         failure.
17035         Reported by Jim Meyering  <jim@meyering.net>.
17036
17037 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
17038
17039         * lib/base64.c: Typo.
17040         (base64_encode): Put b64str in initialized data section.
17041
17042 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
17043
17044         Merge glibc and coreutils changes into gnulib, plus a few
17045         extra fixes.
17046         * lib/md5.c: Use #error rather than a string.
17047         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
17048         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
17049         (__attribute__): Define to empty for non recent-GCC.
17050         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
17051         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
17052         Renamed from their non-__ counterparts, with new macros replacing
17053         them if not _LIBC.  Add __THROW attribute.
17054         (rol): Remove.
17055         (struct md5_ctx): Align buffer if using GCC.
17056         * lib/sha1.h (struct sha1_ctx): Likewise.
17057         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
17058         The old name was backwards.
17059         (NOTSWAP): Remove; not used.
17060         (rol): New macro, moved here from md5.h.
17061         (sha1_process_block): Remove a FIXME that doesn't make sense.
17062
17063 2005-09-12  Derek Price  <derek@ximbiot.com>
17064
17065         Return usable errors from canon-host.
17066         * lib/canon-host.h: New file.
17067         * lib/canon-host.c (canon_host): Wrap...
17068         (canon_host_r): ...this new function, which now relies exclusively on
17069         getaddrinfo.
17070         (ch_strerror): New function.
17071         (last_cherror): New global.
17072         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
17073         interface.
17074         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
17075         void *.
17076         (freeaddrinfo): Free ai->ai_canonname when set.
17077
17078 2005-09-12  Derek Price  <derek@ximbiot.com>
17079
17080         Make canon-host require getaddrinfo.
17081         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
17082         AC_LIBSOURCE canon-host.h.  Call...
17083         (gl_PREREQ_CANON_HOST): ...this new function, which requires
17084         gl_GETADDRINFO.
17085         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
17086
17087 2005-09-12  Derek Price  <derek@ximbiot.com>
17088
17089         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
17090         LGPL.
17091         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
17092
17093 2005-09-12  Derek Price  <derek@ximbiot.com>
17094
17095         * lib/gai_strerror.c: Include config.h when available.  Include
17096         getaddrinfo.h before other headers to test interface.
17097         Reported by Larry Jones <lawrence.jones@ugs.com>.
17098
17099 2005-09-12  Derek Price  <derek@ximbiot.com>
17100             Paul Eggert  <eggert@cs.ucla.edu>
17101
17102         * modules/glob (Files): Add glob-libc.h.
17103
17104 2005-09-12  Derek Price  <derek@ximbiot.com>
17105             Paul Eggert  <eggert@cs.ucla.edu>
17106
17107         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
17108         glob_.h, glob-libc.h.
17109         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
17110
17111 2005-09-12  Derek Price  <derek@ximbiot.com>
17112             Paul Eggert  <eggert@cs.ucla.edu>
17113
17114         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
17115         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
17116         protecting things that should be done only in gnulib contexts.
17117         * lib/glob_.h: New file, containing only the glob things needed for
17118         gnulib.
17119         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
17120         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
17121         (glob, globfree, glob_pattern_p): Now defined simply in terms of
17122         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
17123         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
17124         and to respect the namespace rules better.
17125
17126 2005-09-08  Simon Josefsson  <jas@extundo.com>
17127
17128         * modules/socklen: New file.
17129
17130 2005-09-08  Simon Josefsson  <jas@extundo.com>
17131
17132         * m4/socklen.m4: New file.
17133
17134 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17135
17136         * modules/utimens (Files): Add m4/utimbuf.m4, since
17137         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
17138         Reported by Sergey Poznyakoff.
17139
17140 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17141
17142         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
17143         definitions, since that's the preferred style in glibc.
17144         Fix a minor spacing issue, and update copyright notice to match
17145         glibc's.
17146
17147 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17148
17149         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
17150
17151 2005-09-06  Simon Josefsson  <jas@extundo.com>
17152
17153         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
17154         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
17155
17156 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17157
17158         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
17159         warning.
17160
17161 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17162
17163         * config/srclist.txt: Add glibc bug 1302.
17164
17165 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
17166
17167         Change bitset word type from unsigned int to unsigned long int,
17168         as this has better performance on typical 64-bit hosts.
17169         Port bitset code to hosts with unusual word sizes.
17170         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
17171         (build_collating_symbol):
17172         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
17173         argument is a bitset.  This is merely a style issue, but it makes
17174         it clearer that an entire array is expected.
17175         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
17176         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
17177         Port to the case where bitset_word is not the same as unsigned int.
17178         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17179         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
17180         Likewise.
17181         * lib/regexec.c (check_dst_limits_calc_pos_1,
17182         check_subexp_matching_top):
17183         (build_trtable, group_nodes_into_DFAstates):
17184         Likewise.
17185         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
17186         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
17187         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
17188         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
17189         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
17190         * lib/regcomp.c (optimize_subexps, lower_subexp):
17191         Work even if bitset_word has holes in its bitwise representation.
17192         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
17193         * lib/regexec.c (check_dst_limits_calc_pos_1,
17194         check_subexp_matching_top):
17195         Likewise.
17196         * lib/regex_internal.c (re_string_reconstruct):
17197         Don't assume UCHAR_MAX == 255.
17198         * lib/regex_internal.h (bitset_set_all): Likewise.
17199         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
17200         All uses changed.
17201         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
17202         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
17203         All uses changed.
17204         (BITSET_WORD_MAX): New macro.
17205         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
17206         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
17207         (bitset_empty, bitset_copy):
17208         Prefer sizeof (bitset) to multiplying it out ourselves.
17209         (bitset_not_merge): Remove; unused.
17210         (bitset_contain): Return bool, not unsigned int with one bit on.
17211         All callers changed.
17212         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
17213         alignment than re_node_set; do this by defining a new internal
17214         type struct dests_alloc and using it to allocate memory.
17215
17216 2005-09-05  Bruno Haible  <bruno@clisp.org>
17217
17218         * gnulib-tool (func_import): Fix comparison in handling of symbolic
17219         links.
17220
17221 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
17222
17223         * modules/size_max (Makefile.am): Add size_max.h
17224
17225 2005-09-04  Derek Price  <derek@ximbiot.com>
17226
17227         * gnulib-tool (func_import): Fix reversed $symbolic logic.
17228
17229 2005-09-03  Simon Josefsson  <jas@extundo.com>
17230
17231         * gnulib-tool: Fix typo.
17232
17233 2005-09-03  Simon Josefsson  <jas@extundo.com>
17234
17235         * config/srclist.txt: Add glibc bug 1293.
17236
17237 2005-09-03  Derek Price  <derek@ximbiot.com>
17238
17239         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
17240         From Larry Jones <lawrence.jones@ugs.com>.
17241
17242 2005-09-02  Simon Josefsson  <jas@extundo.com>
17243
17244         * modules/socklen: New file.
17245
17246 2005-09-02  Simon Josefsson  <jas@extundo.com>
17247
17248         * modules/havelib: New module.
17249
17250         * modules/gettext, modules/iconv, modules/lock, modules/readline:
17251         Use havelib.
17252
17253 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17254
17255         Check for arithmetic overflow when calculating sizes, to prevent
17256         some buffer-overflow issues.  These patches are conservative, in the
17257         sense that when I couldn't determine whether an overflow was possible,
17258         I inserted a run-time check.
17259         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
17260         macros.
17261         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
17262         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
17263         (re_xnrealloc, re_x2nrealloc): New inline functions.
17264         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
17265         parse_bracket_exp):
17266         (build_equiv_class, build_charclass): Check for arithmetic overflow
17267         in size expression calculations.
17268         * lib/regex_internal.c (re_string_realloc_buffers):
17269         (build_wcs_upper_buffer, re_node_set_add_intersect):
17270         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
17271         (re_dfa_add_node, register_state): Likewise.
17272         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
17273         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
17274         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
17275         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
17276
17277 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17278
17279         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
17280         m4/ulonglong.m4.  Problem reported by Martin Lambers.
17281
17282 2005-09-02  Bruno Haible  <bruno@clisp.org>
17283
17284         Support for lib vs. lib64 distinction on biarch platforms.
17285         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
17286         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
17287         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
17288
17289 2005-09-02  Bruno Haible  <bruno@clisp.org>
17290
17291         * gnulib-tool (import): In the other first-use case, provide defaults
17292         as well.
17293
17294 2005-09-02  Bruno Haible  <bruno@clisp.org>
17295
17296         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
17297         patches not yet found in the latest gettext release.
17298
17299 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17300
17301         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
17302         to avoid a collision with bits/local_lim.h in glibc.
17303         All uses changed.  Problem reported by Dmitry V. Levin in
17304         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
17305
17306         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
17307         bugs in int versus size_t comparisons.
17308         (re_string_context_at): Fix bug where the code assumed that
17309         Idx is signed.
17310
17311         Use bool where appropriate.
17312         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
17313         All callers changed.
17314         (calc_eclosure_iter): Likewise, for ROOT arg.
17315         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
17316         (build_charclass_op): Likewise, for NON_MATCH arg.
17317         * lib/regex_internal.c (re_string_allocate, re_string_construct):
17318         (re_string_construct_common): Likewise, for ICASE arg.
17319         * lib/regexec.c (re_search_2_stub, re_search_stub):
17320         Likewise, for RET_LEN arg.
17321         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
17322         (set_regs): Likewise, for FL_BACKTRACK arg.
17323         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
17324         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
17325         (calc_eclosure_iter, parse_bracket_exp):
17326         Use bool for internal variables that are booleans.
17327         * lib/regexec.c (re_search_internal, check_matching,
17328         proceed_next_node):
17329         (set_regs, build_sifted_states, sift_states_bkref):
17330         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
17331         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
17332         (find_collation_sequence_value):
17333         Likewise.
17334         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
17335         (re_node_set_compare):
17336         Return bool, not int. All callers changed.
17337         * lib/regexec.c (check_halt_node_context, check_dst_limits):
17338         (build_trtable, check_node_accept): Likewise.
17339         * lib/regex_internal.h: Include stdbool.h.
17340
17341         Fix bugs uncovered when converting to bool.
17342         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
17343         failure instead of charging ahead blindly.
17344         * lib/regex_internal.c (register_state): Likewise.
17345         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
17346         for freeing internal storage.
17347         (group_nodes_into_DFA_states): Use unsigned int, not int, for
17348         bitset pieces used as boolean, to avoid undefined behavior
17349         on hosts that do int overflow checking.
17350
17351 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17352
17353         * config/srclist.txt: Add glibc bugs 1285-1287.
17354
17355 2005-09-01  Jim Meyering  <jim@meyering.net>
17356
17357         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
17358         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
17359         Require gl_STAT_MACROS, too.
17360
17361 2005-09-01  Bruno Haible  <bruno@clisp.org>
17362
17363         * gnulib-tool (import): In the first-use case, provide defaults.
17364
17365 2005-09-01  Bruno Haible  <bruno@clisp.org>
17366
17367         * gnulib-tool (func_import): Remove the .tmp files.
17368
17369 2005-09-01  Bruno Haible  <bruno@clisp.org>
17370
17371         * gnulib-tool (func_import): Fix handling of symbolic links.
17372
17373 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17374
17375         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
17376         old glibc regex code mishandles strings longer than 2**31 bytes.
17377         This patch fixes this when the regex code is used in gnulib
17378         (i.e., outside glibc).
17379
17380         This patch should not affect the use of the regex code inside
17381         glibc.  No doubt this problem also needs to be handled for glibc
17382         as well, but the result will be an incompatible change to the
17383         glibc ABI, and the old ABI will have to be supported too.  That
17384         can be the the subject for another patch.
17385
17386         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
17387         governing whether the rest of this patch is active.  By default,
17388         the macro is disabled and the patch has no effect.
17389         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
17390         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
17391         (struct re_pattern_buffer, re_search, re_search_2, re_match):
17392         (re_match_2, re_set_registers): Use the new types.
17393         * lib/regex_internal.h (Idx, re_hashval_t): New types.
17394         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
17395         New macros.
17396         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
17397         (re_string_context_at, bin_tree_t, re_dfastate_t):
17398         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
17399         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
17400         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
17401         (re_string_char_size_at, re_string_wchar_at):
17402         (re_string_elem_size_at):
17403         Use the new types and macros to port to 64-bit hosts.
17404         Use unsigned types for internal values, so that the code
17405         mostly works even for arrays larger than SSIZE_MAX.
17406         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
17407         (search_duplicated_node, calc_eclosure_iter, fetch_number):
17408         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
17409         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
17410         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
17411         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
17412         (calc_inveclosure, parse_dup_op, build_range_exp):
17413         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
17414         (fetch_number, create_token_tree, mark_opt_subexp):
17415         Likewise.
17416         * lib/regex_internal.c (re_string_construct_common,
17417         create_ci_newstate):
17418         (create_cd_newstate, re_string_allocate, re_string_construct):
17419         (re_string_realloc_buffers, build_wcs_upper_buffer):
17420         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
17421         (re_string_reconstruct, re_string_peek_byte_case):
17422         (re_string_fetch_byte_case, re_string_context_at):
17423         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
17424         (re_node_set_init_copy, re_node_set_add_intersect):
17425         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
17426         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
17427         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
17428         (re_acquire_state, re_acquire_state_context, register_state):
17429         Likewise.
17430         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
17431         search_cur_bkref_entry):
17432         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
17433         (re_search_internal, re_search_2_stub, re_search_stub)
17434         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
17435         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
17436         (update_cur_sifted_state, check_dst_limits):
17437         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
17438         (check_subexp_limits, sift_states_bkref, merge_state_array):
17439         (check_subexp_matching_top, get_subexp, get_subexp_sub):
17440         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
17441         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
17442         (expand_bkref_cache, check_node_accept_bytes):
17443         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
17444         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
17445         (acquire_init_state_context, check_halt_node_context):
17446         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
17447         (sift_states_backward, clean_state_log_if_needed):
17448         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
17449         (find_recover_state, transit_state_sb, transit_state_mb):
17450         (transit_state_bkref, build_trtable, match_ctx_clean):
17451         Likewise.
17452         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
17453         to work around an assumption that REG_MISSING is negative.
17454
17455         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
17456         (seek_collating_symbol_entry) [defined _LIBC]:
17457         (lookup_collation_sequence_value) [defined _LIBC]:
17458         (build_range_exp, build_collating_symbol) [defined _LIBC]:
17459         Use prototypes rather than old-style function definitions.
17460         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
17461         (transit_state_sb) [0]:
17462         (find_collation_sequence_value) [defined _LIBC]: Likewise.
17463
17464         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
17465         rm_eo.
17466
17467         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
17468         (optimize_subexps, lower_subexp):
17469         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
17470         since the signed shift might overflow.  Use 1u<<31 instead.
17471         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17472         Likewise.
17473         * lib/regexec.c (check_dst_limits_calc_pos_1,
17474         check_subexp_matching_top): Likewise.
17475
17476         * lib/regcomp.c (optimize_subexps, lower_subexp):
17477         Use CHAR_BIT rather than 8, for clarity.
17478         * lib/regexec.c (check_dst_limits_calc_pos_1):
17479         (check_subexp_matching_top): Likewise.
17480         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
17481         have to worry about portability issues when shifting it left.
17482         Remove no-longer-needed test for table_size > 0.
17483         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
17484         in a word, as the resulting behavior is undefined.
17485         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
17486         in one case, a <= should have been an <, and in another case the
17487         whole test was missing.
17488         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
17489         the standard name CHAR_BIT.
17490         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
17491         this is not true on one's complement and signed-magnitude hosts.
17492
17493         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
17494         next_last_offset.
17495         (struct re_dfa_t): Remove unused member states_alloc.
17496         * lib/regcomp.c (init_dfa): Don't initialize unused members.
17497
17498 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17499
17500         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
17501         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
17502         and large-file glibc and in 32-bit large-file Solaris.
17503
17504 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17505
17506         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
17507         lengths fit in regoff_t; this isn't true if regoff_t is the same
17508         width as size_t.
17509         * lib/regex.c (re_search_internal): 5th arg is LAST_START
17510         (= START + RANGE) instead of RANGE.  This avoids overflow
17511         problems when regoff_t is the same width as size_t.
17512         All callers changed.
17513         (re_search_2_stub): Check for overflow when adding the
17514         sizes of the two strings.
17515         (re_search_stub): Check for overflow when adding START
17516         to RANGE; if it occurs, substitute the extreme value.
17517
17518 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17519
17520         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
17521
17522 2005-08-31  Jim Meyering  <jim@meyering.net>
17523
17524         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
17525         a pointer-to-const.
17526         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
17527         (register_state): Likewise.
17528         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
17529         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
17530         (group_nodes_into_DFAstates): Likewise.
17531
17532 2005-08-31  Jim Meyering  <jim@meyering.net>
17533
17534         * check-module: Add a FIXME comment.
17535
17536 2005-08-31  Eric Blake  <ebb9@byu.net>
17537
17538         * modules/unistd-safer (Files): Add unistd--.h.
17539         * modules/stdio-safer (Files): Add stdio--.h.
17540
17541 2005-08-31  Derek Price  <derek@ximbiot.com>
17542
17543         * lib/getdelim.c (getdelim): Return EOF on EOF.
17544         Reported by Larry Jones <lawrence.jones@ugs.com>.
17545
17546 2005-08-31  Bruno Haible  <bruno@clisp.org>
17547
17548         Avoid unnecessary diffs in the generated lib/Makefile.am.
17549         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
17550         the generated files.
17551         (func_import): Don't set cmd.
17552
17553 2005-08-31  Bruno Haible  <bruno@clisp.org>
17554
17555         * lib/strstr.c: Include <stddef.h>, for NULL.
17556         * lib/strcasestr.c: Likewise.
17557         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
17558
17559 2005-08-31  Bruno Haible  <bruno@clisp.org>
17560
17561         * gnulib-tool: New option --macro-prefix.
17562         (func_import): Use macro_prefix.
17563         (import): Handle option --macro-prefix.
17564
17565 2005-08-31  Bruno Haible  <bruno@clisp.org>
17566
17567         * gnulib-tool (import): Rename most ac_* variables to cached_*.
17568         Also use new variables cached_lgpl, cached_libtool.
17569
17570 2005-08-31  Bruno Haible  <bruno@clisp.org>
17571
17572         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
17573         always instantiating them.
17574
17575 2005-08-31  Bruno Haible  <bruno@clisp.org>
17576
17577         * gnulib-tool (func_import): Read the previous cached settings
17578         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
17579         earlier added by gnulib but are now dropped. Warn when a gnulib file
17580         overwrites a non-gnulib file.
17581
17582 2005-08-31  Bruno Haible  <bruno@clisp.org>
17583
17584         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
17585         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
17586         projects that don't keep autogenerated files in CVS. Put into
17587         actioncmd only the specified modules, not the transitive closure.
17588
17589 2005-08-31  Bruno Haible  <bruno@clisp.org>
17590
17591         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
17592         Create directories that shall be filled.
17593         (import): Don't look for gl_* macros in configure.ac. Recurse across
17594         all directories containing a gnulib-cache.m4 files, if meaningful.
17595
17596 2005-08-31  Bruno Haible  <bruno@clisp.org>
17597
17598         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
17599         (import): Set seen_libtool when we see gl_LIBTOOL.
17600
17601 2005-08-31  Bruno Haible  <bruno@clisp.org>
17602
17603         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
17604         declaration macro definitions from generated gnulib.m4.
17605
17606 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
17607
17608         * lib/iconvme.h: Add prototype for iconv_alloc.
17609
17610 2005-08-29  Simon Josefsson  <jas@extundo.com>
17611
17612         * lib/iconvme.c: Fix errno.
17613
17614 2005-08-29  Bruno Haible  <bruno@clisp.org>
17615
17616         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
17617         that it works when the directory contains spaces.
17618
17619 2005-08-29  Bruno Haible  <bruno@clisp.org>
17620
17621         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
17622
17623 2005-08-29  Bruno Haible  <bruno@clisp.org>
17624
17625         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
17626         Emit more advice.
17627
17628 2005-08-29  Bruno Haible  <bruno@clisp.org>
17629         and Stepan Kasal  <kasal@ucw.cz>
17630
17631         * check-module: If more parameters are given, check each of them
17632         separately; add more exceptions, as noted by Jim Meyering.
17633         (check_module): New procedure.
17634         (%exempt_header): Now contains all exceptions.
17635
17636 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
17637
17638         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
17639
17640 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
17641
17642         * lib/iconvme.c: Split iconv_string into iconv_alloc.
17643
17644 2005-08-28  Bruno Haible  <bruno@clisp.org>
17645
17646         * m4/gnulib-tool.m4: New file.
17647
17648 2005-08-27  Jim Meyering  <jim@meyering.net>
17649
17650         * modules/unistd-safer (Files): Add pipe-safer.c.
17651         * modules/fcntl-safer (Files): Add creat-safer.c.
17652
17653 2005-08-27  Jim Meyering  <jim@meyering.net>
17654
17655         * m4/stdlib-safer.m4: New file.  From coreutils.
17656         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
17657         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
17658         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
17659         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
17660         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
17661
17662 2005-08-27  Jim Meyering  <jim@meyering.net>
17663
17664         * lib/fopen-safer.c: Merge minor changes from coreutils.
17665         * lib/dup-safer.c: Likewise.
17666         * lib/fd-safer.c: Likewise.
17667
17668         Merge from coreutils.
17669         * lib/stdio--.h: New file.
17670         * lib/stdlib--.h: New file.
17671         * lib/mkstemp-safer.c: New file.
17672
17673         GNU tar needs these.
17674         * lib/pipe-safer.c: New file.
17675         * lib/creat-safer.c: New file.
17676         * lib/fcntl--.h (creat): Define to creat_safer.
17677         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
17678         * lib/unistd--.h (pipe): Define to pipe_safer.
17679         * lib/unistd-safer.h: Declare pipe_safer.
17680
17681 2005-08-26  Simon Josefsson  <jas@extundo.com>
17682
17683         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
17684         Haible <bruno@clisp.org>.
17685
17686 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
17687
17688         * lib/regex_internal.h: Remove all references to
17689         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
17690         or better.
17691         (bitset_not, bitset_merge, bitset_not_merge):
17692         (bitset_mask, re_string_allocate, re_string_construct):
17693         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
17694         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
17695         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
17696         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
17697         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
17698         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
17699         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
17700         (re_acquire_state_context):
17701         Remove unnecessary forward decls.
17702         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
17703         Put __attribute at function definition,
17704         now that the function decl has been removed.
17705         * lib/regex_internal.c (re_string_peek_byte_case):
17706         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
17707         Likewise.
17708
17709 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
17710
17711         * m4/regex.m4: Add AC_PREREQ(2.50).
17712         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
17713
17714 2005-08-25  Simon Josefsson  <jas@extundo.com>
17715
17716         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
17717         __fsetlocking.
17718
17719 2005-08-25  Simon Josefsson  <jas@extundo.com>
17720
17721         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
17722         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
17723         GLIBC specific code.
17724
17725 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17726
17727         Make regex safe for g++.  This fixes one real bug (an "err"
17728         that should have been "*err").  g++ problem reported by
17729         Sam Steingold.
17730         * lib/regex_internal.h (re_calloc): New macro, consistent with
17731         re_malloc etc.  All callers of calloc changed to use re_calloc.
17732         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
17733         not int.  All callers changed.
17734         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
17735         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
17736         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
17737         (find_recover_state): Change "err" to "*err"; this fixes what
17738         appears to be a real bug.
17739         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
17740         versus int.
17741
17742 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17743
17744         * modules/regex (Depends-on): Add malloc, since the code
17745         assumes that !malloc(0) means failure.
17746
17747 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17748
17749         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
17750
17751         alloca modernization/simplification for regex.
17752         * lib/regex.c: Remove portability cruft for alloca.  This no longer
17753         needs to be at the start of the file, and can be moved into
17754         regex_internal.h and simplified.
17755         * lib/regex_internal.h: Include <alloca.h>.
17756         (__libc_use_alloca) [!defined _LIBC]: New macro.
17757         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
17758         now works outside glibc.
17759
17760 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17761
17762         * config/srclist.txt: Add glibc bugs 1241, 1245.
17763
17764 2005-08-25  Jim Meyering  <jim@meyering.net>
17765
17766         * lib/open-safer.c: Include <config.h>.
17767         Otherwise, we'd lose LARGEFILE support in any file using
17768         e.g. "fcntl--.h"
17769
17770 2005-08-25  Bruno Haible  <bruno@clisp.org>
17771
17772         * m4/minmax.m4: Require autoconf 2.52.
17773         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
17774         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
17775         alternatives of translit over the alphabet.
17776         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
17777
17778 2005-08-24  Simon Josefsson  <jas@extundo.com>
17779
17780         * tests/test-getpass.c: New file.
17781
17782 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
17783
17784         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
17785         for GNU regex features.
17786
17787 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
17788
17789         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
17790         * lib/regex.h (regerror): Likewise.
17791
17792         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
17793         requires this.  (The code never needed it.)
17794
17795         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
17796         All uses of recently-renamed identifiers changed to use the new,
17797         POSIX-compliant names.  The code will build and run just fine
17798         without these changes, but it's better to eat our own dog food
17799         and use the standard-conforming names.
17800
17801         * lib/regex.h: Fix a multitude of POSIX name space violations.
17802         These changes have an effect only for programs that define
17803         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
17804         do not change anything for programs compiled in the normal way.
17805         Also, there is no effect on the ABI.
17806
17807         (_REGEX_SOURCE): New macro.
17808         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
17809         defined and _GNU_SOURCE is not; this fixes a name space violation.
17810
17811         Rename the following macros to obey POSIX requirements.
17812         The old names are still visible as macros if _REGEX_SOURCE is defined.
17813         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
17814         RE_BACKSLASH_ESCAPE_IN_LISTS.
17815         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
17816         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
17817         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
17818         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
17819         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
17820         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
17821         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
17822         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
17823         (REG_INTERVALS): renamed from RE_INTERVALS.
17824         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
17825         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
17826         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
17827         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
17828         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
17829         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
17830         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
17831         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
17832         RE_UNMATCHED_RIGHT_PAREN_ORD.
17833         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
17834         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
17835         (REG_DEBUG): renamed from RE_DEBUG.
17836         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
17837         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
17838         unusual, since we can't clash with the POSIX REG_ICASE.
17839         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
17840         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
17841         (REG_NO_SUB): renamed from RE_NO_SUB.
17842         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
17843         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
17844         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
17845         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
17846         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
17847         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
17848         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
17849         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
17850         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
17851         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
17852         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
17853         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
17854         RE_SYNTAX_POSIX_MINIMAL_BASIC.
17855         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
17856         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
17857         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
17858         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
17859         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
17860         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
17861         (REG_FIXED): Renamed from REGS_FIXED.
17862         (REG_NREGS): Renamed from RE_NREGS.
17863
17864         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
17865         of other REG_* macros, since POSIX says the user is allowed to
17866         #undef these macros selectively.
17867
17868         (reg_errcode_t): Update comment stating what other tables need
17869         to be consistent.
17870
17871         Rename the following enum values to obey POSIX requirements.
17872         The old names are still visible as macros.
17873         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
17874         is not defined, since GNU is supposed to be a superset of POSIX as
17875         much as possible, and since we want reg_errcode_t to be a signed
17876         type for implementation consistency.
17877         (_REG_NOERROR): Renamed from REG_NOERROR.
17878         (_REG_NOMATCH): Renamed from REG_NOMATCH.
17879         (_REG_BADPAT): Renamed from REG_BADPAT.
17880         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
17881         (_REG_ECTYPE): Renamed from REG_ECTYPE.
17882         (_REG_EESCAPE): Renamed from REG_EESCAPE.
17883         (_REG_ESUBREG): Renamed from REG_ESUBREG.
17884         (_REG_EBRACK): Renamed from REG_EBRACK.
17885         (_REG_EPAREN): Renamed from REG_EPAREN.
17886         (_REG_EBRACE): Renamed from REG_EBRACE.
17887         (_REG_BADBR): Renamed from REG_BADBR.
17888         (_REG_ERANGE): Renamed from REG_ERANGE.
17889         (_REG_ESPACE): Renamed from REG_ESPACE.
17890         (_REG_BADRPT): Renamed from REG_BADRPT.
17891         (_REG_EEND): Renamed from REG_EEND.
17892         (_REG_ESIZE): Renamed from REG_ESIZE.
17893         (_REG_ERPAREN): Renamed from REG_ERPAREN.
17894         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
17895         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
17896         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
17897         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
17898
17899         (_REG_RE_NAME, _REG_RM_NAME): New macros.
17900         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
17901         changed.  But support the old name if the new one is not defined
17902         and if _REGEX_SOURCE.
17903
17904         Change the following member names in struct re_pattern_buffer.
17905         The old names are still supported if !_REGEX_SOURCE.
17906         The new names are always supported, regardless of _REGEX_SOURCE.
17907         (re_buffer): Renamed from buffer.
17908         (re_allocated): Renamed from allocated.
17909         (re_used): Renamed from used.
17910         (re_syntax): Renamed from syntax.
17911         (re_fastmap): Renamed from fastmap.
17912         (re_translate): Renamed from translate.
17913         (re_can_be_null): Renamed from can_be_null.
17914         (re_regs_allocated): Renamed from regs_allocated.
17915         (re_fastmap_accurate): Renamed from fastmap_accurate.
17916         (re_no_sub): Renamed from no_sub.
17917         (re_not_bol): Renamed from not_bol.
17918         (re_not_eol): Renamed from not_eol.
17919         (re_newline_anchor): Renamed from newline_anchor.
17920
17921         Change the following member names in struct re_registers.
17922         The old names are still supported if !_REGEX_SOURCE.
17923         The new names are always supported, regardless of _REGEX_SOURCE.
17924         (rm_num_regs): Renamed from num_regs.
17925         (rm_start): Renamed from start.
17926         (rm_end): Renamed from end.
17927
17928         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
17929         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
17930         Prepend __ to parameter names.
17931
17932         Undo yesterday's changes.
17933
17934 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
17935
17936         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
17937         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
17938         lib/regex.c.
17939
17940 2005-08-24  Jim Meyering  <jim@meyering.net>
17941
17942         Sync from coreutils.
17943         * m4/fcntl-safer.m4: New file.
17944
17945         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
17946         and object files for this module.
17947
17948 2005-08-24  Jim Meyering  <jim@meyering.net>
17949
17950         Sync from coreutils.
17951         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
17952
17953 2005-08-24  Jim Meyering  <jim@meyering.net>
17954
17955         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
17956         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
17957
17958 2005-08-24  Jim Meyering  <jim@meyering.net>
17959
17960         * modules/fcntl-safer: New module.
17961         * modules/fts (Depends-on): Add fcntl-safer.
17962         * MODULES.html.sh (File descriptor based Input/Output):
17963         Add fcntl-safer.
17964
17965 2005-08-24  Bruno Haible  <bruno@clisp.org>
17966
17967         Support for unit test modules.
17968         * modules/README: Mention tests modules.
17969         * modules/TEMPLATE-TESTS: New file.
17970         * gnulib-tool: New options --extract-tests-module, --with-tests and
17971         --tests-base (unused for the moment).
17972         (testsbase, inctests): New variables.
17973         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
17974         (func_verify_module): Exclude TEMPLATE-TESTS.
17975         (func_verify_nontests_module, func_verify_tests_module): New functions.
17976         (func_get_dependencies): Add implicit dependency for tests modules.
17977         (func_get_tests_module): New function.
17978         (func_modules_transitive_closure): When --with-tests was specified,
17979         include the unit tests as well, unless explicitly avoided.
17980         (func_emit_lib_Makefile_am): Ignore the tests modules here.
17981         (func_emit_tests_Makefile_am): New function.
17982         (func_create_testdir): When --with-tests was specified, emit a
17983         tests/ directory.
17984         * MODULES.html.sh (Future developments): Update.
17985
17986 2005-08-24  Bruno Haible  <bruno@clisp.org>
17987
17988         * modules/tls-tests: New file.
17989         * tests/test-tls.c: New file, from GNU gettext.
17990
17991 2005-08-24  Bruno Haible  <bruno@clisp.org>
17992
17993         * modules/lock-tests: New file.
17994         * tests/test-lock.c: New file, from GNU gettext.
17995
17996 2005-08-24  Bruno Haible  <bruno@clisp.org>
17997
17998         * lib/lock.h: Add multiple inclusion guard.
17999         * lib/tls.h: Add multiple inclusion guard.
18000
18001 2005-08-24  Bruno Haible  <bruno@clisp.org>
18002
18003         * gnulib-tool: Add support for the --aux-dir option to
18004         --create-testdir, --create-megatestdir, --test, --megatest.
18005         (func_create_testdir, func_create_megatestdir): Optionally emit a
18006         AC_CONFIG_AUX_DIR directive.
18007         (create-testdir, create-megatestdir, test, megatest): Provide a
18008         default value for $auxdir.
18009
18010 2005-08-24  Bruno Haible  <bruno@clisp.org>
18011
18012         * gnulib-tool (import): Use compound statement instead of subshell
18013         where possible.
18014
18015 2005-08-24  Bruno Haible  <bruno@clisp.org>
18016
18017         * gnulib-tool (import): Change --aux-dir default to "build-aux".
18018
18019 2005-08-24  Bruno Haible  <bruno@clisp.org>
18020
18021         * gnulib-tool (func_version): Update.
18022
18023 2005-08-24  Bruno Haible  <bruno@clisp.org>
18024
18025         * gnulib-tool (func_import, func_create_testdir,
18026         func_create_megatestdir): Quote all autoconf macro arguments.
18027
18028 2005-08-24  Bruno Haible  <bruno@clisp.org>
18029
18030         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
18031         option --force, because --force causes the aclocal.m4 of each
18032         subdirectory to be newer than the corresponding config.h.in.
18033
18034 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18035
18036         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
18037         All contents moved to gl_REGEX.
18038         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
18039         assume that it does.
18040
18041 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18042
18043         * lib/regex.h (REG_NOSYS)
18044         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
18045         Define, since POSIX requires it as of 2001.
18046         (_REG_ENOSYS)
18047         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
18048         New private symbol, used to keep the enum signed in all cases.
18049         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
18050         Youngman in
18051         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
18052
18053         * lib/regex_internal.c (re_string_skip_chars, register_state):
18054         (calc_state_hash):
18055         Remove forward decls; no longer needed now that we use prototypes.
18056         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
18057         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
18058         (clean_state_log_if_needed): Likewise.
18059
18060 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18061
18062         * config/srclist.txt: Add glibc bugs 1231-1233.
18063
18064 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18065
18066         Fix problems reported by Sam Steingold in
18067         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
18068         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
18069         assumed that reg_errcode_t is a signed type, which is not
18070         necessarily true if _XOPEN_SOURCE is not defined.
18071         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
18072         since some compilers warn about it otherwise.
18073
18074 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18075
18076         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
18077         (init_word_char, create_initial_state, duplicate_node_closure):
18078         (fetch_token, peek_token_bracket, build_range_exp):
18079         (build_collating_symbol): Remove forward decls; no longer needed
18080         now that we use prototypes.
18081
18082         * lib/regcomp.c:
18083         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
18084         (re_compile_fastmap_iter, regcomp, regerror, regfree):
18085         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
18086         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
18087         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
18088         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
18089         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
18090         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
18091         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
18092         (build_range_exp, build_collating_symbol, parse_bracket_exp):
18093         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
18094         (build_charclass, build_charclass_op, fetch_number, create_tree):
18095         (create_token_tree, mark_opt_subexp, duplicate_tree):
18096         Use prototypes rather than old-style definitions.
18097
18098         * lib/regex_internal.c:
18099         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
18100         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
18101         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18102         (re_string_reconstruct, re_string_peek_byte_case):
18103         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
18104         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18105         (re_node_set_init_copy, re_node_set_add_intersect):
18106         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18107         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18108         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18109         (re_acquire_state, re_acquire_state_context, register_state):
18110         (create_ci_newstate, create_cd_newstate, free_state):
18111         Likewise.
18112         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
18113         re_search_2):
18114         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
18115         (re_search_internal, prune_impossible_nodes):
18116         (acquire_init_state_context, check_matching, static):
18117         (check_halt_node_context, check_halt_state_context, proceed_next_node):
18118         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
18119         (update_regs, sift_states_backward, build_sifted_states):
18120         (clean_state_log_if_needed, merge_state_array):
18121         (update_cur_sifted_state, add_epsilon_src_nodes):
18122         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
18123         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
18124         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
18125         (find_recover_state, check_subexp_matching_top, transit_state_mb):
18126         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
18127         (check_arrival, check_arrival_add_next_nodes):
18128         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18129         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18130         (check_node_accept_bytes, check_node_accept, extend_buffers):
18131         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
18132         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
18133         (sift_ctx_init):
18134         Likewise.
18135
18136         * lib/regex_internal.h:
18137         (re_string_allocate, re_string_construct, re_string_reconstruct):
18138         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
18139         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
18140         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
18141         (re_string_context_at, re_string_peek_byte_case):
18142         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
18143         is defined, since we now use prototypes always.
18144
18145         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
18146         C89 or better.  All uses removed.
18147
18148 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18149
18150         * config/srclist.txt: Add glibc bugs 1220-1227.
18151
18152 2005-08-20  Jim Meyering  <jim@meyering.net>
18153
18154         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
18155         of unused local, dfa.
18156
18157 2005-08-20  Bruno Haible  <bruno@clisp.org>
18158
18159         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
18160
18161 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18162
18163         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
18164         (re_node_set_insert_last, re_dfa_add_node):
18165         Rename local variables to avoid GCC shadowing warnings.
18166
18167 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18168
18169         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
18170         [defined lint]: Suppress bogus uninitialized-variable warnings.
18171
18172         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
18173         and let the caller return REG_ESPACE if out of space.  This
18174         removes an uninitialied-variable warning with GCC 4.0.1, and also
18175         avoids taking the address of a local variable.  All callers
18176         changed.
18177
18178 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18179
18180         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
18181         $LIBCSRC/posix/regexec.c.
18182         Add glibc bug 1217 for regcomp.c.
18183
18184 2005-08-19  Jim Meyering  <jim@meyering.net>
18185
18186         * lib/regexec.c (proceed_next_node): Redo local variables to
18187         avoid GCC shadowing warnings.
18188
18189 2005-08-18  Bruno Haible  <bruno@clisp.org>
18190
18191         * lib/strstr.c (strstr): Fix return value in multibyte case.
18192         * lib/strcasestr.c (strcasestr): Likewise.
18193
18194 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18195
18196         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
18197
18198 2005-08-17  Jim Meyering  <jim@meyering.net>
18199
18200         Make the %s format (seconds since the epoch) work for a negative
18201         number and when used with a zero-padded field width, e.g. %015s.
18202
18203         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
18204         label so that it precedes the code to set `digits'.  Otherwise,
18205         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
18206         print `00-22'.  Now, it prints `-0022', as it should.
18207
18208 2005-08-17  Bruno Haible  <bruno@clisp.org>
18209
18210         * modules/strstr (Files): Add m4/mbrtowc.m4.
18211         (Depends-on): Add mbuiter.
18212
18213 2005-08-17  Bruno Haible  <bruno@clisp.org>
18214
18215         * modules/strcasestr: New file.
18216         * MODULES.html.sh (String handling, based on ANSI C 89): Add
18217         strcasestr.
18218
18219 2005-08-17  Bruno Haible  <bruno@clisp.org>
18220
18221         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
18222
18223 2005-08-17  Bruno Haible  <bruno@clisp.org>
18224
18225         * modules/mbuiter: New file.
18226         * MODULES.html.sh (Extended multibyte and wide character utilities):
18227         Add mbuiter.
18228
18229 2005-08-17  Bruno Haible  <bruno@clisp.org>
18230
18231         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
18232         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
18233
18234 2005-08-17  Bruno Haible  <bruno@clisp.org>
18235
18236         * m4/strcasestr.m4: New file.
18237
18238 2005-08-17  Bruno Haible  <bruno@clisp.org>
18239
18240         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
18241         * lib/strstr.c: Completely rewritten, with multibyte locale support.
18242
18243 2005-08-17  Bruno Haible  <bruno@clisp.org>
18244
18245         * lib/strcasestr.h: New file.
18246         * lib/strcasestr.c: New file.
18247
18248 2005-08-17  Bruno Haible  <bruno@clisp.org>
18249
18250         * lib/strcasecmp.c: Use mbuiter.h.
18251
18252 2005-08-17  Bruno Haible  <bruno@clisp.org>
18253
18254         * lib/mbuiter.h: New file.
18255
18256 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
18257
18258         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
18259         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
18260         and gl_GETOPT are both invoked via different paths (as happens
18261         with GNU tar CVS because it uses both argp and getopt), the former
18262         wins.
18263
18264 2005-08-16  Bruno Haible  <bruno@clisp.org>
18265
18266         * modules/tls: New file.
18267         * MODULES.html.sh (Multithreading): Add tls.
18268
18269 2005-08-16  Bruno Haible  <bruno@clisp.org>
18270
18271         * modules/strnlen1: New file.
18272         * MODULES.html.sh (String handling): Add strnlen1.
18273
18274 2005-08-16  Bruno Haible  <bruno@clisp.org>
18275
18276         * modules/strcase (Files): Add m4/mbrtowc.m4.
18277         (Depends-on): Add strnlen1, mbchar.
18278
18279 2005-08-16  Bruno Haible  <bruno@clisp.org>
18280
18281         * modules/mbiter: New file.
18282         * MODULES.html.sh (Extended multibyte and wide character utilities):
18283         Add mbiter.
18284
18285 2005-08-16  Bruno Haible  <bruno@clisp.org>
18286
18287         * modules/mbfile: New file.
18288         * MODULES.html.sh (Extended multibyte and wide character utilities):
18289         Add mbfile.
18290
18291 2005-08-16  Bruno Haible  <bruno@clisp.org>
18292
18293         * modules/mbchar: New file.
18294         * MODULES.html.sh (Extended multibyte and wide character utilities):
18295         New section.
18296
18297 2005-08-16  Bruno Haible  <bruno@clisp.org>
18298
18299         * m4/tls.m4: New file, from GNU gettext.
18300
18301 2005-08-16  Bruno Haible  <bruno@clisp.org>
18302
18303         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
18304         always.
18305         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
18306
18307 2005-08-16  Bruno Haible  <bruno@clisp.org>
18308
18309         * m4/mbiter.m4: New file.
18310
18311 2005-08-16  Bruno Haible  <bruno@clisp.org>
18312
18313         * m4/mbfile.m4: New file.
18314
18315 2005-08-16  Bruno Haible  <bruno@clisp.org>
18316
18317         * m4/mbchar.m4: New file.
18318
18319 2005-08-16  Bruno Haible  <bruno@clisp.org>
18320
18321         * lib/tls.h: New file, from GNU gettext.
18322         * lib/tls.c: New file, from GNU gettext.
18323
18324 2005-08-16  Bruno Haible  <bruno@clisp.org>
18325
18326         * lib/strnlen1.h: New file.
18327         * lib/strnlen1.c: New file.
18328
18329 2005-08-16  Bruno Haible  <bruno@clisp.org>
18330
18331         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
18332         (mbi_init): Update.
18333         (mbi_avail, mbi_advance): Let the iteration end before the terminating
18334         NUL byte, not after it.
18335
18336 2005-08-16  Bruno Haible  <bruno@clisp.org>
18337
18338         * lib/strcase.h (strcasecmp): Add note in comments.
18339         * lib/strncasecmp.c: Use code from strcasecmp.c.
18340         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
18341         (strcasecmp): Work correctly in multibyte locales.
18342
18343 2005-08-16  Bruno Haible  <bruno@clisp.org>
18344
18345         * lib/mbiter.h: New file.
18346
18347 2005-08-16  Bruno Haible  <bruno@clisp.org>
18348
18349         * lib/mbfile.h: New file.
18350
18351 2005-08-16  Bruno Haible  <bruno@clisp.org>
18352
18353         * lib/mbchar.h: New file.
18354         * lib/mbchar.c: New file.
18355
18356 2005-08-16  Bruno Haible  <bruno@clisp.org>
18357
18358         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
18359         the valid ones. Makes the comparison operations transitive:
18360         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
18361         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
18362
18363 2005-08-15  Simon Josefsson  <jas@extundo.com>
18364
18365         * modules/ssize_t (License): Change to 'unlimited'.
18366
18367         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
18368
18369 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
18370
18371         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
18372         Add comments for each pending glibc patch.
18373
18374 2005-08-15  Bruno Haible  <bruno@clisp.org>
18375
18376         * lib/regex.h (__restrict_arr): Don't define to __restrict if
18377         __cplusplus is defined.
18378
18379 2005-08-14  Jim Meyering  <jim@meyering.net>
18380
18381         Sync from coreutils.
18382
18383         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
18384         Use the hash-table-based cycle-detection code not just when
18385         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
18386         Reported by James Youngman in
18387         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
18388         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
18389         FTS_TIGHT_CYCLE_CHECK.
18390         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
18391         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
18392         once again.
18393         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
18394         * lib/fts.c (fd_safer): Remove decl.
18395         Include fcntl--.h rather than unistd-safer.h
18396         (fts_safe_changedir): Don't call fd_safer; no longer needed
18397         now that we include fcntl--.h.
18398
18399 2005-08-12  Simon Josefsson  <jas@extundo.com>
18400
18401         * modules/getndelim2: Use ssize_t module.
18402         * modules/getnline: Likewise.
18403         * modules/safe-read: Likewise.
18404         * modules/xreadlink: Likewise.
18405
18406         * modules/ssize_t: New file.
18407
18408 2005-08-12  Simon Josefsson  <jas@extundo.com>
18409
18410         * m4/readline.m4: Look for termcap, curses or ncurses if required.
18411
18412 2005-08-12  Simon Josefsson  <jas@extundo.com>
18413
18414         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18415         ssize_t.
18416
18417 2005-08-12  Simon Josefsson  <jas@extundo.com>
18418
18419         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
18420         readline, getdelim and check_version.
18421         (Support for systems lacking ISO C 99: Sizes of integer types):
18422         Add size_max.
18423
18424 2005-08-12  Bruno Haible  <bruno@clisp.org>
18425
18426         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
18427
18428 2005-08-11  Simon Josefsson  <jas@extundo.com>
18429
18430         * modules/readline: New file.
18431
18432         * modules/strnlen (Files): Add strnlen.h.
18433
18434 2005-08-11  Simon Josefsson  <jas@extundo.com>
18435
18436         * m4/readline.m4: New file.
18437
18438 2005-08-11  Simon Josefsson  <jas@extundo.com>
18439
18440         * lib/readline.h, readline.c: New file.
18441
18442 2005-08-11  Simon Josefsson  <jas@extundo.com>
18443
18444         * doc/gnulib.texi (Initial import, Finishing touches): Mention
18445         gl_AVOID.
18446
18447 2005-08-11  Bruno Haible  <bruno@clisp.org>
18448
18449         * lib/strnlen.h (strnlen): Change parameter name to match comment.
18450
18451 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
18452
18453         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
18454
18455 2005-08-10  Simon Josefsson  <jas@extundo.com>
18456
18457         * tests/test-iconvme.c: New file.
18458
18459 2005-08-10  Simon Josefsson  <jas@extundo.com>
18460
18461         * m4/strnlen.m4: New file.
18462
18463         * m4/strndup.m4: Don't check for strnlen declaration, done in
18464         strnlen.m4.
18465
18466 2005-08-10  Simon Josefsson  <jas@extundo.com>
18467
18468         * lib/strndup.c: Use strnlen.h.
18469
18470         * lib/strnlen.h: New file.
18471
18472 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
18473
18474         * README: Typos.
18475
18476 2005-08-02  Simon Josefsson  <jas@extundo.com>
18477
18478         * modules/readline: New file.
18479
18480 2005-08-02  Simon Josefsson  <jas@extundo.com>
18481
18482         * modules/getdelim: New file.
18483
18484         * modules/getline: Rewrite, don't use getndelim2.
18485
18486 2005-08-02  Simon Josefsson  <jas@extundo.com>
18487
18488         * m4/getline.m4: Separate out getdelim stuff into separate module.
18489
18490         * m4/getdelim.m4: New file.
18491
18492 2005-08-02  Simon Josefsson  <jas@extundo.com>
18493
18494         * lib/getline.h, getline.c: Rewrite.
18495
18496         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
18497
18498 2005-07-31  Bruno Haible  <bruno@clisp.org>
18499
18500         * lib/lock.h (gl_lock_initializer): New macro.
18501         (gl_lock_define_initialized): Use it.
18502         (gl_rwlock_initializer): New macro.
18503         (gl_rwlock_define_initialized): Use it.
18504         (gl_recursive_lock_initializer): New macro.
18505         (gl_recursive_lock_define_initialized): Use it.
18506
18507 2005-07-30  Karl Berry  <karl@gnu.org>
18508
18509         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
18510         Report from Ben Pfaff, regarding getopt.
18511
18512 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
18513
18514         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
18515         normal way.
18516         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
18517         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
18518         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
18519         (gl_GETOPT): Use the new macros.  Most of the implementation
18520         is moved to the new macros.  This is for programs like Emacs
18521         that don't want all the functionality of gl_GETOPT.
18522
18523 2005-07-26  Bruno Haible  <bruno@clisp.org>
18524
18525         * m4/lock.m4: Update from GNU gettext.
18526
18527 2005-07-26  Bruno Haible  <bruno@clisp.org>
18528
18529         * lib/lock.h: Update from GNU gettext.
18530         * lib/lock.c: Update from GNU gettext.
18531
18532 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
18533
18534         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
18535         obsolescent AC_TRY_RUN.  Include the default includes files, for
18536         'exit'.
18537
18538 2005-07-24  Bruno Haible  <bruno@clisp.org>
18539
18540         * modules/visibility: New file.
18541         * MODULES.html.sh (Misc): Add visibility.
18542
18543 2005-07-24  Bruno Haible  <bruno@clisp.org>
18544
18545         * m4/visibility.m4: New file.
18546
18547 2005-07-24  Bruno Haible  <bruno@clisp.org>
18548
18549         * doc/visibility.texi: New file.
18550
18551 2005-07-22  Bruno Haible  <bruno@clisp.org>
18552
18553         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
18554         $(ALLOCA_H), redundant through BUILT_SOURCES.
18555         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
18556         redundant through BUILT_SOURCES.
18557         * modules/byteswap (Makefile.am): Remove explicit dependency on
18558         $(BYTESWAP_H), redundant through BUILT_SOURCES.
18559         * modules/fnmatch (Makefile.am): Remove explicit dependency on
18560         $(FNMATCH_H), redundant through BUILT_SOURCES.
18561         * modules/getopt (Makefile.am): Remove explicit dependency on
18562         $(GETOPT_H), redundant through BUILT_SOURCES.
18563         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
18564         redundant through BUILT_SOURCES.
18565         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
18566         redundant through BUILT_SOURCES.
18567         * modules/stdbool (Makefile.am): Remove explicit dependency on
18568         $(STDBOOL_H), redundant through BUILT_SOURCES.
18569         * modules/stdint (Makefile.am): Remove explicit dependency on
18570         $(STDINT_H), redundant through BUILT_SOURCES.
18571         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
18572         Remove explicit dependency on $(SYSEXITS_H).
18573         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
18574
18575 2005-07-18  Simon Josefsson  <jas@extundo.com>
18576
18577         * lib/check-version.c (check_version): Accept identical versions too.
18578
18579 2005-07-18  Bruno Haible  <bruno@clisp.org>
18580
18581         * modules/lock: New file.
18582         * MODULES.html.sh (Multithreading): New section.
18583
18584 2005-07-18  Bruno Haible  <bruno@clisp.org>
18585
18586         * m4/lock.m4: New file, from GNU gettext.
18587
18588 2005-07-18  Bruno Haible  <bruno@clisp.org>
18589
18590         * lib/lock.h: New file, from GNU gettext.
18591         * lib/lock.c: New file, from GNU gettext.
18592
18593 2005-07-18  Bruno Haible  <bruno@clisp.org>
18594
18595         * lib/lock.h (gl_once_t): New type.
18596         (gl_once_define, gl_once): New macros.
18597         * lib/lock.c (fresh_once): New variable.
18598         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
18599         functions.
18600
18601 2005-07-16  Simon Josefsson  <jas@extundo.com>
18602
18603         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
18604         workaround, suggested by Bruno.
18605
18606 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
18607
18608         * modules/xalloc (Depends-on): Add xalloc-die.
18609         * modules/xvasprintf (Depends-on): Add xalloc-die.
18610
18611 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
18612
18613         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
18614         with a minor change.
18615
18616 2005-07-15  Bruno Haible  <bruno@clisp.org>
18617
18618         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
18619         When using lib/poll.c, define poll as rpl_poll.
18620
18621 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
18622
18623         * modules/argp (Depends-on): Remove unlocked-io.
18624
18625 2005-07-14  Derek Price  <derek@ximbiot.com>
18626
18627         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
18628         for glob symlink bug.
18629
18630 2005-07-14  Bruno Haible  <bruno@clisp.org>
18631
18632         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
18633         Instead, test for *_unlocked function declarations directly.
18634
18635 2005-07-11  Simon Josefsson  <jas@extundo.com>
18636
18637         * modules/size_max: New file.
18638
18639         * modules/xsize: Depend on size_max module for size_max.m4.
18640
18641 2005-07-11  Simon Josefsson  <jas@extundo.com>
18642
18643         * lib/size_max.h: New file.
18644
18645 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
18646
18647         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
18648         copyright symbol and the year.
18649         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
18650         (version_etc_va): Use parameterized copyright notice.
18651         Reword to conform to the current GNU coding standards.
18652
18653 2005-07-11  Karl Berry  <karl@gnu.org>
18654
18655         * doc/gnulib.texi (Quoting): new node.
18656         (Initial import): more info, from Patrice.
18657
18658 2005-07-11  Bruno Haible  <bruno@clisp.org>
18659
18660         * gnulib-tool (func_usage): Document option --avoid.
18661         (Command line options): Handle --avoid.
18662         (func_acceptable): New function.
18663         (func_modules_transitive_closure): Use it.
18664
18665 2005-07-11  Bruno Haible  <bruno@clisp.org>
18666
18667         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
18668         Reported by Jim Meyering.
18669
18670 2005-07-10  Bruno Haible  <bruno@clisp.org>
18671
18672         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
18673         Needed when size_t is smaller than 'unsigned int'.
18674         Reported by Paul Eggert.
18675
18676 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
18677
18678         * modules/argp (Depends-on): Add unlocked-io
18679
18680 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
18681
18682         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
18683         block of defines.
18684
18685 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
18686
18687         * config/srclist.txt: Comment out regcomp.c, since we have a porting
18688         fix now.
18689
18690 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
18691         and Paul Eggert  <eggert@cs.ucla.edu>
18692
18693         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
18694         in wint_t, not wchar_t.  Remove now-unnecessary cast.
18695
18696 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18697
18698         * modules/regex (Files): Add lib/regex_internal.c,
18699         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
18700         (Depends-on): Add extensions.
18701         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
18702
18703 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18704
18705         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
18706         pathconf.
18707         * m4/same.m4 (gl_SAME): Likewise.
18708         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
18709
18710         * m4/regex.m4: Adjust to new libc regex implementation.
18711         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
18712         all the .c and .h parts of (the new) regex.
18713         Quote the m4 stuff better.
18714         Check for RE_ICASE bug of old gnulib.
18715         Check for REG_STARTEND of recent libc.
18716         Rename local variables from jm_* to gl_*.
18717         Quote operand of "test -f".
18718         Say "recent enough" version of libc, not "version 2".
18719         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
18720         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
18721         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
18722         Remove check for btowc, isascii.
18723         Require AM_LANGINFO_CODESET.
18724
18725 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18726
18727         * lib/regex.c, regex.h: Sync from libc.
18728         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
18729         * lib/regexec.c:
18730         New files, synced from libc, except that regex_internal.h
18731         currently has a small porting fix.
18732
18733 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18734
18735         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
18736         regex_internal.c, regexec.c.
18737         Add regex_internal.h too, but as a comment, since the libc version
18738         is currently broken in gnulib mode.
18739
18740 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
18741
18742         Support programs like Emacs that use gnulib but not gettext.
18743         * MODULES.html.sh (Internationalization functions): Add gettext-h.
18744         * modules/gettext-h: New file.
18745         * modules/gettext (Files): Remove lib/gettext.h.
18746         (Depends-on): Add gettext-h.
18747         (Makefile.am): Remove lib_SOURCES.
18748         * modules/argmatch, modules/c-stack, modules/closeout:
18749         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
18750         * modules/execute, modules/file-type, modules/getaddrinfo:
18751         * modules/getopt, modules/human, modules/javacomp:
18752         * modules/javaexec, modules/mkdir-p, modules/obstack:
18753         * modules/openat, modules/pagealign_alloc, modules/pipe:
18754         * modules/quotearg, modules/regex, modules/rpmatch:
18755         * modules/unicodeio, modules/userspec, modules/version-etc:
18756         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
18757         * modules/xsetenv:
18758         Depend on gettext-h, not gettext.
18759
18760 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
18761
18762         * gnulib-tool (func_import): Add support for 'public domain' license.
18763         * modules/alloca, modules/atexit, modules/memmove:
18764         Now public domain, not GPL.
18765         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
18766         * modules/realloc, modules/strerror, modules/strtod:
18767         Now LGPL, not GPL.
18768
18769 2005-07-05  Bruno Haible  <bruno@clisp.org>
18770
18771         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
18772         autoconf CVS. Needed for mingw.
18773
18774 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
18775
18776         Remove the dependency of the strftime module on the tzset module.
18777         * modules/strftime (Depends-on): Remove dependency on tzset.
18778
18779 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
18780
18781         Remove the dependency of the strftime module on the tzset module.
18782         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
18783         gl_FUNC_TZSET_CLOBBER.
18784
18785 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
18786
18787         Remove the dependency of the strftime module on the tzset module.
18788         * lib/strftime.c (my_strftime)
18789         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
18790         Copy the input structure, to work around some of the bug with
18791         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
18792         Solaris releases, you should also use the tzset module, but we won't
18793         require it as a dependency any more since we don't want LGPLed code
18794         to depend on GPLed code.
18795
18796 2005-07-02  Jim Meyering  <jim@meyering.net>
18797
18798         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
18799         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
18800         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
18801         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
18802
18803 2005-07-02  Jim Meyering  <jim@meyering.net>
18804
18805         * lib/backupfile.c (backup_args): Change a `0' to NULL.
18806
18807 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
18808
18809         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
18810         declares only 'struct timespec;' (!).
18811
18812 2005-07-01  Jim Meyering  <jim@meyering.net>
18813
18814         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
18815         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
18816         * lib/save-cwd.c, tempname.c:
18817         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
18818         and don't include <sys/file.h>).
18819
18820 2005-06-29  Jim Meyering  <jim@meyering.net>
18821
18822         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
18823         type name.  Use the variable name instead.
18824         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
18825         Likewise.
18826
18827 2005-06-28  Simon Josefsson  <jas@extundo.com>
18828
18829         * modules/check-version (Files): Add check-version.m4.
18830
18831 2005-06-28  Simon Josefsson  <jas@extundo.com>
18832
18833         * m4/check-version.m4: New file, suggested by Jim Meyering
18834         <jim@meyering.net>.
18835
18836 2005-06-28  Simon Josefsson  <jas@extundo.com>
18837
18838         * lib/check-version.h, lib/check-version.c: New files.
18839
18840 2005-06-28  Simon Josefsson  <jas@extundo.com>
18841
18842         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
18843         collision with global variable.  Better indentation.  Don't
18844         increment buffer pointer beyond buffer end.  Based on comments
18845         from Paul Eggert <eggert@cs.ucla.edu>.
18846
18847         * lib/base64.h: Indent.
18848
18849 2005-06-28  Simon Josefsson  <jas@extundo.com>
18850
18851         * doc/gnulib.texi (Library version handling): New section.
18852
18853 2005-06-28  Jim Meyering  <jim@meyering.net>
18854
18855         * check-module (find_included_lib_files): Hard-code another
18856         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
18857         but modules/fts-lgpl (correctly) does not list those files.
18858
18859         * modules/canonicalize (Files): Add lib/pathmax.h.
18860
18861 2005-06-25  Simon Josefsson  <jas@extundo.com>
18862
18863         * modules/check-version: New file.
18864
18865 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
18866
18867         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
18868         initializer of struct addrinfo, as an indication that we don't
18869         care how many members the structure has.
18870
18871 2005-06-24  Derek Price  <derek@ximbiot.com>
18872         and Bruno Haible  <bruno@clisp.org>
18873
18874         Remove stat module & update lstat.
18875         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
18876         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
18877         * m4/stat.m4: Remove this file.
18878
18879 2005-06-24  Derek Price  <derek@ximbiot.com>
18880         and Bruno Haible  <bruno@clisp.org>
18881
18882         Remove stat module & update lstat.
18883         * lib/stat.c: Remove this file...
18884         (slash_aware_lstat): ...moving this content and its support...
18885         * lib/lstat.c (rpl_lstat): ...into here.
18886         * lib/lstat.h: New file.
18887
18888 2005-06-24  Derek Price  <derek@ximbiot.com>
18889         and Bruno Haible  <bruno@clisp.org>
18890
18891         Remove stat module & update lstat.
18892         * config/srclist.txt (libc sources): Remove stat.
18893
18894 2005-06-24  Derek Price  <derek@ximbiot.com>
18895         and Bruno Haible  <bruno@clisp.org>
18896
18897         Remove stat module & update lstat.
18898         * MODULES.html.sh (stat): Remove.
18899         * MODULES.html: Regenerated.
18900         * modules/lstat (Description): Correct function name.
18901         (Files): Add "lstat.h".
18902         (Depends-on): Remove stat, add xalloc, stat-macros.
18903         * modules/stat: Remove this file.
18904         (Include): Add "lstat.h", remove <sys/stat.h>.
18905
18906 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
18907
18908         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
18909         (ranged_convert): Don't save conversion in a temporary struct.
18910         This causes a warning with GCC 4.0.0, and anyway in the typical
18911         case it's not worth the extra 100 bytes or so of code.
18912         (ranged_convert, __mktime_internal): When calling a function via a
18913         pointer P, use P () rather than (*P) (), as we now assume C89 or
18914         better.
18915
18916 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
18917
18918         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
18919         "who -r" failed to give output.  Problem reported by Tim Waugh.
18920
18921         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
18922         (xcalloc): Use it to avoid needless tests.
18923         Problem reported by Jim Meyering.
18924
18925 2005-06-20  Derek Price  <derek@ximbiot.com>
18926
18927         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
18928         unnecessary for Autoconfs > 2.59c.
18929
18930 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18931
18932         * lib/argp.h (__option_is_short): Check upper limit of
18933         __key. Isprint() requires its argument to have the value
18934         of an unsigned char or EOF.
18935
18936 2005-06-16  Jim Meyering  <jim@meyering.net>
18937
18938         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
18939         when either N or S is zero.
18940
18941 2005-06-16  Derek Price  <derek@ximbiot.com>
18942
18943         * m4/bison.m4: Declare YACC & YFLAGS precious.
18944
18945 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
18946
18947         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
18948         multibyte string or pattern, fall back on unibyte matching.
18949         Problem reported by James Youngman.
18950
18951 2005-06-08  Bruno Haible  <bruno@clisp.org>
18952
18953         * modules/csharpcomp: New file.
18954         * MODULES.html.sh (C#): Add csharpcomp.
18955
18956 2005-06-08  Bruno Haible  <bruno@clisp.org>
18957
18958         * m4/csharpcomp.m4: New file, from GNU gettext.
18959
18960 2005-06-08  Bruno Haible  <bruno@clisp.org>
18961
18962         * lib/csharpcomp.h: New file, from GNU gettext.
18963         * lib/csharpcomp.c: New file, from GNU gettext.
18964         * lib/csharpcomp.sh.in: New file, from GNU gettext.
18965
18966 2005-06-08  Bruno Haible  <bruno@clisp.org>
18967
18968         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
18969         warning on mingw.
18970
18971 2005-06-07  Derek Price  <derek@ximbiot.com>
18972
18973         Sync from CVS.
18974         * lib/glob_.h: Indent nested #ifdef.
18975
18976 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
18977
18978         Sync from coreutils.
18979         Use "file name" when talking about file names, instead of "filename"
18980         or "path", as per the GNU coding standards.
18981         * lib/mkdir-p.c: Renamed from makepath.c.
18982         (make_dir_parents): Renamed from make_path.  All callers changed.
18983         * lib/mkdir-p.h: Likewise.  All includers changed.
18984         * lib/filenamecat.c: Renamed from path-concat.c.
18985         (file_name_concat): Renamed from path_concat.  All callers changed.
18986         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
18987         * lib/filenamecat.h: Likewise.  All includers changed.
18988         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
18989         in comments or local variable names.
18990         * lib/basename.c: Likewise.
18991         * lib/canonicalize.c, canonicalize.h: Likewise.
18992         * lib/dirname.c, dirname.h: Likewise.
18993         * lib/euidaccess.c: Likewise.
18994         * lib/exclude.c: Likewise
18995         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
18996         * lib/fsusage.c, fsuage.h: Likewise.
18997         * lib/fts.c, fts_.h: Likewise.
18998         * lib/getcwd.c: Likewise.
18999         * lib/getloadavg.c: Likewise.
19000         * lib/mkstemp.c: Likewise.
19001         * lib/mountlist.c, mountlist.h: Likewise.
19002         * lib/openat.c, openat.h: Likewise.
19003         * lib/readlink-stub.c: Likewise.
19004         * lib/readutmp.c, readutmp.h: Likewise.
19005         * lib/rename.c: Likewise.
19006         * lib/rmdir.c: Likewise.
19007         * lib/same.c: Likewise.
19008         * lib/savedir.c: Likewise.
19009         * lib/stripslash.c: Likewise.
19010         * lib/tempname.c: Likewise.
19011         * lib/xreadlink.c: Likewise.
19012         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
19013         All uses changed.
19014         * lib/exclude.h: Likewise.
19015
19016         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
19017         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19018         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
19019         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19020         * lib/pathmax.h: Include <limits.h> unconditionally, since other
19021         files have been getting away with it for years (MORE/BSD 4.3
19022         is extinct now).
19023         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
19024         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19025
19026         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
19027         Define to 256, not 255, as per modern POSIX.
19028
19029 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19030
19031         Sync from coreutils.
19032         Use "file name" when talking about file names, instead of "filename"
19033         or "path", as per the GNU coding standards.
19034         * MODULES.html.sh: mkdir-p renamed from makepath.
19035         filenamecat renamed from path-concat.
19036         * modules/filenamecat: Renamed from modules/path-concat.
19037         (Files): filenamecat.h and filenamecat.c renamed from
19038         path-concat.h and path-concat.c.
19039         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
19040         (Include): filenamecat.h, not path-concat.h.
19041         * modules/mkdir-p: Renamed from modules/makepath.
19042         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
19043         makepath.c.
19044         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
19045         (Include): mkdir-p.h, not makepath.h.
19046
19047 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19048
19049         Sync from coreutils.
19050         * m4/mkdir-p.m4: Renamed from makepath.m4.
19051         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
19052         Rename files from makepath.c to mkdir-p.c, and from
19053         makepath.h to mkdir-p.h.
19054         * m4/filenamecat.m4: Renamed from path-concat.m4.
19055         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
19056         Rename files from path-concat.c to filenamecat.c,
19057         and from path-concat.h to filenamecat.h.
19058         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
19059         "file name" in local variables or comments.
19060         * m4/rename.m4: Likewise.
19061
19062 2005-06-01  Bruno Haible  <bruno@clisp.org>
19063
19064         * modules/csharpexec: New file.
19065         * MODULES.html.sh (C#): New section.
19066
19067 2005-06-01  Bruno Haible  <bruno@clisp.org>
19068
19069         * m4/csharp.m4: New file, from GNU gettext.
19070         * m4/csharpexec.m4: New file, from GNU gettext.
19071
19072 2005-06-01  Bruno Haible  <bruno@clisp.org>
19073
19074         * lib/csharpexec.h: New file, from GNU gettext.
19075         * lib/csharpexec.c: New file, from GNU gettext.
19076         * lib/csharpexec.sh.in: New file, from GNU gettext.
19077
19078 2005-05-31  Derek Price  <derek@ximbiot.com>
19079             Paul Eggert  <eggert@cs.ucla.edu>
19080
19081         Sync from cvs.
19082         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19083
19084 2005-05-31  Derek Price  <derek@ximbiot.com>
19085             Paul Eggert  <eggert@cs.ucla.edu>
19086
19087         Sync from cvs.
19088         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19089
19090 2005-05-29  Derek Price  <derek@ximbiot.com>
19091
19092         * config/srclist.txt (glob_.h, glob.c): Add these files.
19093
19094 2005-05-29  Derek Price  <derek@ximbiot.com>
19095
19096         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
19097         * modules/glob: New file.
19098         * modules/getlogin_r: Add link to POSIX spec in description.
19099
19100 2005-05-29  Derek Price  <derek@ximbiot.com>
19101             Paul Eggert  <eggert@cs.ucla.edu>
19102
19103         * m4/glob.m4: New file.
19104
19105 2005-05-29  Derek Price  <derek@ximbiot.com>
19106             Paul Eggert  <eggert@cs.ucla.edu>
19107
19108         * lib/glob_.h, lib/glob.c: New files.
19109
19110 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19111
19112         * modules/fts (Files): Remove m4/inttypes-pri.m4.
19113         * modules/fts-lgpl (Depends-on): Remove gettext.
19114
19115 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19116
19117         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
19118         and don't require gt_INTTYPES_PRI.
19119
19120 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19121
19122         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
19123
19124         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
19125         the configuration hassle isn't worth it.
19126         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
19127         (LONGEST_MODIFIER, PRIuMAX): Remove.
19128
19129 2005-05-27  Bruno Haible  <bruno@clisp.org>
19130
19131         * lib/getlogin_r.h: Remove second include of <stddef.h>.
19132
19133 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
19134
19135         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
19136         _POSIX_PTHREAD_SEMANTICS for Solaris.
19137
19138 2005-05-25  Derek Price  <derek@ximbiot.com>
19139
19140         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
19141
19142 2005-05-25  Derek Price  <derek@ximbiot.com>
19143             Paul Eggert  <eggert@cs.ucla.edu>
19144
19145         * modules/getlogin_r, m4/getlogin_r.m4: New files.
19146         * lib/getlogin_r.c, getlogin_r.h: New files.
19147
19148 2005-05-25  Bruno Haible  <bruno@clisp.org>
19149             Derek Price  <derek@ximbiot.com>
19150
19151         * lib/getlogin_r.h: Simplify API documentation.
19152
19153 2005-05-23  Derek Price  <derek@ximbiot.com>
19154
19155         * modules/minmax (Files): Add m4/minmax.m4.
19156         (configure.ac): Add gl_MINMAX.
19157
19158 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
19159
19160         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
19161         so that unistd-safer.h (GPL'ed code) need not be included.
19162
19163 2005-05-22  Bruno Haible  <bruno@clisp.org>
19164
19165         * m4/minmax.m4: New file.
19166         Based on a patch by Derek Price <derek@ximbiot.com>.
19167
19168 2005-05-22  Bruno Haible  <bruno@clisp.org>
19169
19170         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
19171         (INT64_MIN): Fix definition.
19172         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
19173
19174         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
19175         NEED_SIGNED_INT_TYPES.
19176
19177         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
19178         HAVE_SYSTEM_INTTYPES.
19179
19180 2005-05-22  Bruno Haible  <bruno@clisp.org>
19181
19182         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
19183         Also include <sys/param.h> if it defines MIN, MAX.
19184         Based on a patch by Derek Price <derek@ximbiot.com>.
19185
19186 2005-05-21  Jim Meyering  <jim@meyering.net>
19187
19188         * modules/fts (Files): Add m4/inttypes-pri.m4.
19189         (Depends-on): Add lstat and remove gettext.  Alphabetize.
19190
19191 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19192
19193         New fts module.
19194         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
19195         (setup_dir, free_dir): New functions.
19196         (enter_dir, leave_dir): Define trivial
19197         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
19198         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
19199         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
19200         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
19201         Move to fts-cycle.c.
19202         (fts_open): Use setup_dir.
19203         (fts_close): Use free_dir.
19204         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
19205         This adds a label and some gotos, but the alternatives were messier.
19206         Check for memory allocation failure when entering a dir.
19207         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
19208         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
19209         (FTS): New member fts_cycle, that is a union that contains the
19210         old active_dir_ht and cycle_state.  All uses changed to mention
19211         fts_cycle.ht and fts_cycle.state.
19212         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
19213         fts.c, with the following changes:
19214         (setup_dir, free_dir): New functions.
19215         (enter_dir): Now returns bool.  Return true if successful, false
19216         if memory exhausted.  All callers changed.
19217         Do not bother partly cleaning up on
19218         memory allocation failure; that is free_dir's job.
19219         However, free ad if hash_insert fails, to avoid memory leak.
19220         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
19221         fts->fts_options to see which union member to use.
19222
19223 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19224
19225         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
19226         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
19227
19228 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19229
19230         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
19231
19232 2005-05-20  Jim Meyering  <jim@meyering.net>
19233
19234         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
19235         Now a macro, to pacify GCC.
19236
19237 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19238
19239         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
19240         of -1.
19241
19242 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19243
19244         * lib/chown.c (rpl_chown): Return -1 on failure.
19245
19246 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19247
19248         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
19249         Don't check for stddef.h.
19250         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
19251         don't use its results.
19252         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
19253         since we include them unconditionally.  Don't require
19254         AM_STDBOOL_H, since stdbool is a prerequisite.
19255         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
19256         since we assume C89 or better.
19257         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
19258         as we don't use their results.
19259         Don't check for fchdir, memmove, memset, strrchr, as we use
19260         them unconditionally.
19261         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
19262         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
19263
19264 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19265
19266         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
19267         Include <stddef.h> unconditionally, since we assume C89 now.
19268         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
19269         * lib/fts.c: Include fts_.h first, to check interface.
19270         Do not include intprops.h; no longer needed.
19271         Include cycle-check.h and hash.h, since fts_.h no longer does.
19272         Remove unnecessary casts of closedir to void.
19273         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
19274         decide whether to decrement nlinks.
19275         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
19276         (FTS): Use struct hash_table * instead of Hash_table, so that
19277         we no longer need to include hash.h here.
19278
19279 2005-05-18  Jim Meyering  <jim@meyering.net>
19280
19281         * modules/dirfd (License): Change to LGPL.  Most of the code
19282         is already in the public domain.
19283
19284 2005-05-18  Jim Meyering  <jim@meyering.net>
19285
19286         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
19287         Reported by Yoann Vandoorselaere.
19288
19289 2005-05-17  Jim Meyering  <jim@meyering.net>
19290
19291         * m4/fts.m4: New file, from coreutils.
19292
19293 2005-05-17  Jim Meyering  <jim@meyering.net>
19294
19295         * lib/fts.c, lib/fts_.h: New files, from coreutils.
19296
19297 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19298
19299         Sync from coreutils.
19300         * m4/unlinkdir.m4: New file.
19301
19302 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19303
19304         Sync from coreutils.
19305         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
19306         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
19307         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
19308         White space changes only.
19309         * lib/makepath.c (make_path): Port to hosts where leading "//" is
19310         special.
19311         * lib/yesno.c: Include getline.h, not ctype.h.
19312         (yesno): Don't remove leading white space; POSIX doesn't allow it.
19313         Use getline to remove arbitrary restriction on response length.
19314
19315 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19316
19317         * config/srclist-update: Spell out "Street" in FSF postal
19318         mail address; this is the style the FSF seems to prefer.
19319
19320         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
19321         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
19322         this updates FSF postal mail address.
19323
19324         Sync from coreutils.
19325         * modules/unlinkdir: New file.
19326         * modules/yesno (Depends-on): Add getline.
19327         * MODULES.html.sh (File system functions): Add unlinkdir.
19328
19329 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19330
19331         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
19332         lib/strsep.h:
19333         Change the initial comment to refer to GPL, not LGPL.
19334         gnulib-tool will change it to LGPL as needed.
19335
19336         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
19337         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
19338         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
19339         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
19340         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
19341         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
19342         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
19343         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
19344         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
19345         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
19346         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
19347         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
19348         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
19349         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
19350         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
19351         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
19352         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
19353         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
19354         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
19355         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
19356         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
19357         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
19358         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
19359         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
19360         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
19361         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
19362         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
19363         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
19364         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
19365         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
19366         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
19367         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
19368         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
19369         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
19370         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
19371         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
19372         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
19373         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
19374         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
19375         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
19376         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
19377         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
19378         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
19379         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
19380         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
19381         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
19382         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
19383         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
19384         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
19385         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
19386         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
19387         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
19388         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
19389         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
19390         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
19391         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
19392         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
19393         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
19394         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
19395         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
19396         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
19397         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
19398         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
19399         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
19400         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
19401         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
19402         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
19403         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
19404         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
19405         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
19406         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
19407         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
19408         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
19409         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
19410         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
19411         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
19412         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
19413         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
19414         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
19415         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
19416         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
19417         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
19418         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
19419         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
19420         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
19421         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
19422         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
19423         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
19424         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
19425         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
19426         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
19427         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
19428         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
19429         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
19430         lib/yesno.c, lib/yesno.h:
19431         Update FSF postal mail address.
19432
19433 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19434
19435         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
19436         tests/test-memmem.c, tests/test-stpncpy.c:
19437         Update FSF postal mail address.
19438
19439 2005-05-13  Bruno Haible  <bruno@clisp.org>
19440
19441         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
19442         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
19443         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
19444         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
19445         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
19446         Add support for 64-bit integers in the MSVC compiler.
19447
19448 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19449
19450         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
19451
19452 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
19453
19454         * gnulib-tool (func_import): Sort and uniquify recommended includes.
19455
19456 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
19457
19458         * doc/getdate.texi (General date syntax): Don't say that date
19459         date --iso-8601=ns generates acceptable dates; it doesn't yet.
19460         Problem reported by Nic Ferrier.
19461
19462 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19463
19464         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
19465         specified in ai_socktype. Fix invalid ai_protocol
19466         check. ai_protocol is usually set to 0 or depending on
19467         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
19468         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
19469         ai_socktype / ai_protocol in the returned addrinfo structure.
19470
19471 2005-05-10  Simon Josefsson  <jas@extundo.com>
19472
19473         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
19474         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
19475
19476 2005-05-10  Karl Berry  <karl@gnu.org>
19477
19478         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
19479         (from http://www.gnu.org/licenses).
19480         * doc/COPYING.LIB: also rename to COPYING.LESSER.
19481         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
19482         fdl.texi suffices.
19483
19484 2005-05-10  Karl Berry  <karl@gnu.org>
19485
19486         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
19487         (COPYING.DOC): remove.
19488
19489         * config/srclist-update: new FSF address.
19490
19491 2005-05-10  Derek Price  <derek@ximbiot.com>
19492
19493         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
19494         possible.
19495
19496 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19497             Bruno Haible  <bruno@clisp.org>
19498
19499         * modules/inet_ntop: New file.
19500         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19501         inet_ntop.
19502
19503 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19504             Bruno Haible  <bruno@clisp.org>
19505
19506         * m4/inet_ntop.m4: New file.
19507
19508 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19509             Bruno Haible  <bruno@clisp.org>
19510
19511         * lib/inet_ntop.h: New file.
19512         * lib/inet_ntop.c: New file, from glibc with modifications.
19513
19514 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
19515
19516         * modules/time_r (License): Change to LGPL.
19517         * modules/extensions (License): Change to LGPL.  Actually,
19518         the license is more permissive than that, but currently gnulib-tool
19519         doesn't know how to handle more-permissive licenses.
19520
19521         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
19522         Problem reported by Dave Love.
19523
19524 2005-05-08  Jim Meyering  <jim@meyering.net>
19525
19526         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
19527         blank.
19528
19529 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
19530
19531         * modules/argmatch (Depends-on): Add stdbool.
19532         * modules/backupfile (Depends-on): Likewise.
19533         * modules/chdir-long (Depends-on): Likewise.
19534         * modules/closeout (Depends-on): Likewise.
19535         * modules/cycle-check (Depends-on): Likewise.
19536         * modules/dirname (Depends-on): Likewise.
19537         * modules/fnmatch (Depends-on): Likewise.
19538         * modules/fsusage (Depends-on): Likewise.
19539         * modules/fwriteerror (Depends-on): Likewise.
19540         * modules/getcwd (Depends-on): Likewise.
19541         * modules/getloadavg (Depends-on): Likewise.
19542         * modules/hard-locale (Depends-on): Likewise.
19543         * modules/makepath (Depends-on): Likewise.
19544         * modules/mountlist (Depends-on): Likewise.
19545         * modules/nanosleep (Depends-on): Likewise.
19546         * modules/posixtm (Depends-on): Likewise.
19547         * modules/quotearg (Depends-on): Likewise.
19548         * modules/readtokens (Depends-on): Likewise.
19549         * modules/readtokens0 (Depends-on): Likewise.
19550         * modules/readutmp (Depends-on): Likewise.
19551         * modules/save-cwd (Depends-on): Likewise.
19552         * modules/strftime (Depends-on): Likewise.
19553         * modules/userspec (Depends-on): Likewise.
19554         * modules/utimecmp (Depends-on): Likewise.
19555         * modules/xgetcwd (Depends-on): Likewise.
19556         * modules/xnanosleep (Depends-on): Likewise.
19557         * modules/xstrtod (Depends-on): Likewise.
19558         * modules/yesno (Depends-on): Likewise.
19559
19560 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
19561
19562         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
19563         needless checks.
19564
19565 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19566
19567         Merge from coreutils.  Among other things,
19568         add bulletproofing for cases where stdin, stdout, or stderr are closed.
19569         * lib/fd-safer.c: New file.
19570         * lib/fcntl-safer.h, open-safer.c: Remove.
19571         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
19572         * lib/dup-safer.c: Include unistd-safer.h first.
19573         Don't include errno.h.
19574         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
19575         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
19576         * lib/file-type.c: Rely on file-type.h change.
19577         * lib/getloadavg.c: Include unistd-safer.h.
19578         (getloadavg): Use safer open.
19579         * lib/getusershell.c: Include "stdio-safer.h".
19580         (getusershell): Use safer fopen.
19581         * lib/long-options.c (long_options): Use NULL rather than 0.
19582         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
19583         'free'.
19584         * lib/modechange.c: Likewise.
19585         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
19586         (MODE_DONE): New constant.
19587         (struct mode_change): Remove 'next' member.
19588         (make_node_op_equals): New function; like the old one of the
19589         same name, except it allocates an array.
19590         (mode_compile, mode_create_from_ref): Use it.
19591         (mode_compile): Allocate result as an array, not a linked list.
19592         Parse octal string ourself, so that we catch mistakes like "+0".
19593         (mode_adjust): Arg is an array, not a linked list.
19594         * lib/modechange.c: Include stat-macros.h, xalloc.h.
19595         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
19596         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
19597         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
19598         Remove.  This is now stat-macros.h's job.
19599         (talloc): Remove.  All callers replaced by xalloc, so that
19600         our invokers don't have to worry about reporting memory failures.
19601         (make_node_op_equals): Remove.
19602         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
19603         New constants.
19604         (struct mode_change): Moved here from modechange.h.
19605         (mode_append_entry): Remove.
19606         (mode_compile): Remove MASKED_OPS arg, since it encouraged
19607         apps to have incorrect behavior.  Use simpler algorithm for head
19608         and tail.  Don't futz with umask; that's now the job of mode_adjust.
19609         Detect more invalid usages rather than having somewhat-random behavior.
19610         Don't insert an "a=" action, as that leads to incorrect behavior.
19611         (mode_compile, mode_create_from_ref): Return NULL on error instead
19612         of an enum, since now there's only one way to have an error.  All
19613         callers changed.
19614         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
19615         at the correct time.  Simplify calculation of "+u" and its ilk.
19616         Don't mishandle "+X".
19617         (mode_free): Remove "register" and localize decls.
19618         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
19619         (struct mode_change): Move to modechange.c; callers don't
19620         need to see this stuff.
19621         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
19622         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
19623         (mode_change, mode_adjust): Reflect the new signatures noted above.
19624         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
19625         that might redefine system include files.
19626         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
19627         (my_usleep): Use NULL rather than (void *) 0.
19628         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
19629         Use siginterrupt to specify that system calls should be interrupted.
19630         (rpl_nanosleep): Move initialization of suspended closer to call of
19631         my_usleep.
19632         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
19633         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
19634         (desirable_utmp_entry): New function.
19635         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
19636         using x2nrealloc, to simplify logic.
19637         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
19638         size calculation.  Do not assume utmp file is a regular file.
19639         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
19640         (READ_UTMP_CHECK_PIDS): New constant.
19641         * lib/save-cwd.c: Include unistd-safer.h.
19642         (save_cwd): Use fd_safer.
19643         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
19644         [!_LIBC] Include "stat-macros.h" instead.
19645         * lib/unistd-safer.h (fd_safer): New decl.
19646
19647 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19648
19649         * modules/getloadavg (Depends-on): Add unistd-safer.
19650         * modules/getusershell (Depends-on): Add stdio-safer.
19651         * modules/lstat (Depends-on): Remove xalloc.
19652         * modules/mkstemp (Depends-on): Add stat-macros.
19653         * modules/modechange (Depends-on): Remove xstrtol.
19654         Add stat-macros, xalloc.
19655         * modules/save-cwd (Depends-on): Add unistd-safer.
19656         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
19657         * modules/unistd-safer (Files): Add lib/fd-safer.c
19658         (Makefile.am): Remove lib_SOURCES.
19659
19660         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
19661         Remove fcntl-safer; unistd-safer supersedes it.
19662
19663 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19664
19665         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
19666         AC_HEADER_STAT.
19667         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
19668         (gl_PREREQ_CHOWN): Remove.
19669         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
19670         it.  Don't require AC_HEADER_STAT.
19671         (gl_PREREQ_LSTAT): Remove.
19672         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
19673         Don't require AC_HEADER_STAT.
19674         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
19675         (gl_PREREQ_RMDIR): Remove.
19676         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
19677         mention stat-macros.h or AC_HEADER_STAT, since we'll make
19678         the stat-macros module a prerequisite.
19679         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
19680         * m4/filemode.m4 (gl_FILEMODE): Likewise.
19681         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
19682         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
19683         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
19684         variable names.
19685         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
19686         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
19687         variable prefixes.
19688         * m4/fcntl-safer.m4: Remove.
19689         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
19690         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
19691         Invoke gl_PREREQ_FD_SAFER.
19692         (gl_PREREQ_FD_SAFER): New macro.
19693         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
19694         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
19695         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
19696         Remove duplicate call to AC_LIBOBJ(readutmp).
19697         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
19698
19699         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
19700         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
19701
19702 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19703
19704         * MODULES.html.sh (Misc): Add byteswap.
19705
19706 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19707
19708         * modules/getcwd (Depends-on): Add extensions.
19709         * modules/openat (Depends-on): Likewise.
19710
19711 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19712
19713         * modules/byteswap: New file.
19714
19715 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19716
19717         * m4/byteswap.m4: New file.
19718
19719 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19720
19721         * lib/byteswap_.h: New file.
19722
19723 2005-04-25  Karl Berry  <karl@gnu.org>
19724
19725         * m4/gettext.m4: Update from GNU gettext 0.14.4.
19726
19727 2005-04-25  Albert Chin  <china@thewrittenword.com>
19728
19729         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
19730         Toolkit C bug.
19731
19732 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
19733
19734         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
19735         (func_ln_if_changed) Remove forcibly for no error message
19736         in case file does not exist.
19737
19738 2005-04-19  Simon Josefsson  <jas@extundo.com>
19739
19740         * gnulib-tool (Options): Make --symlink mean --symbolic.
19741
19742 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
19743
19744         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
19745
19746 2005-04-16  Simon Josefsson  <jas@extundo.com>
19747
19748         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
19749
19750 2005-04-15  Simon Josefsson  <jas@extundo.com>
19751
19752         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
19753
19754 2005-04-15  Simon Josefsson  <jas@extundo.com>
19755
19756         * gnulib-tool: Rename --symlink to --symbolic.
19757
19758 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
19759
19760         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
19761         symbolic links to files instead of copying/moving.  Add --aux-dir,
19762         specifying directory relative --dir where auxiliary build tools
19763         are placed.
19764
19765 2005-04-14  Bruno Haible  <bruno@clisp.org>
19766
19767         * modules/allocsa (License): Change to LGPL.
19768         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
19769
19770 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
19771
19772         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
19773         that "UTC +1 second" continues to work.  Problem reported
19774         by Dmitry V. Levin.
19775         (relunit_snumber): New rule.
19776         (relunit): Use it.
19777
19778 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
19779
19780         * lib/getdate.y (universal_time_zone_table): New constant.
19781         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
19782         universal_time_zone_table.
19783         (lookup_zone): Prefer universal_time_zone_table to
19784         local_time_zone_table, so that "GMT" time stamps are allowed in
19785         London during the summer.  Problem reported by Ian Abbott.
19786
19787 2005-04-12  Jim Meyering  <jim@meyering.net>
19788
19789         * lib/human.c (humblock): Set *options even when returning due to
19790         xstrtoumax conversion failure.  Thanks to a used-uninitialized
19791         warning from gcc-4.
19792
19793 2005-04-09  Jim Meyering  <jim@meyering.net>
19794
19795         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
19796         -Wuninitialized: initialize tm0.tm_year.
19797
19798 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
19799
19800         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
19801         count, since there's no maximum.  All uses changed.
19802         Add member dsts_seen.
19803         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
19804         not being INT_MAX.
19805         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
19806         Use pc_rels_seen to decide whther a date is absolute.
19807
19808         * lib/getdate.y (number): Don't overwrite year.
19809         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
19810         check.
19811
19812 2005-04-02  Simon Josefsson  <jas@extundo.com>
19813
19814         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
19815         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
19816
19817 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
19818
19819         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
19820         where no absolute path name can be longer than PATH_MAX.
19821
19822 2005-03-27  Jim Meyering  <jim@meyering.net>
19823
19824         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
19825
19826 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
19827
19828         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
19829         "one's complement" -> "ones' complement" in comment, as per Knuth.
19830         "value of type" -> "type or expression" in comment.
19831         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
19832
19833 2005-03-26  Jim Meyering  <jim@meyering.net>
19834
19835         Comment nits.
19836         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
19837         Correct typos: s/or/of/.
19838
19839 2005-03-26  Jim Meyering  <jim@meyering.net>
19840
19841         * modules/check-include-files: Move to ../ and rename to...
19842         * check-module: ...this.
19843
19844 2005-03-25  Jim Meyering  <jim@meyering.net>
19845
19846         * modules/xvasprintf (Files): Add xalloc.h.
19847
19848 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
19849
19850         * modules/gettext (Files): config/config.rpath ->
19851         build-aux/config.rpath
19852         * modules/iconv (Files): Likewise.
19853         Problem reported by Oskar Liljeblad.
19854
19855 2005-03-23  Jim Meyering  <jim@meyering.net>
19856
19857         * modules/check-include-files: New script to check for
19858         missing dependencies, multiple includes, etc.
19859
19860         * modules/c-strtold (Depends-on): Add xalloc.
19861         * modules/c-strtod (Depends-on): Add xalloc.
19862         * modules/hash (Depends-on): Add xalloc.
19863         (Files): Remove lib/xalloc.h.
19864
19865         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
19866         * modules/userspec (Files): Add lib/inttostr.h.
19867
19868 2005-03-23  Jim Meyering  <jim@meyering.net>
19869
19870         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
19871
19872 2005-03-22  Jim Meyering  <jim@meyering.net>
19873
19874         * modules/stat-macros: New module.
19875         * modules/canonicalize, modules/euidaccess, modules/file-type,
19876         * modules/filemode, modules/lchown, modules/makepath,
19877         * modules/rmdir, modules/stat: Depend on new stat-macros module
19878         rather than listing lib/stat-macros.h manually.
19879         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
19880
19881 2005-03-22  Jim Meyering  <jim@meyering.net>
19882
19883         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
19884
19885 2005-03-22  Bruno Haible  <bruno@clisp.org>
19886
19887         * config/srclist.txt: Replace target directory 'config' with
19888         'build-aux'.
19889         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
19890         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
19891         ../build-aux/.
19892
19893 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
19894
19895         * modules/chdir-long (Depends-on): Add mempcpy.
19896
19897         * modules/acl, modules/backupfile, modules/c-strtod,
19898         modules/c-strtold, modules/canon-host, modules/canonicalize,
19899         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
19900         modules/exclude, modules/exitfail, modules/file-type,
19901         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
19902         modules/getdate, modules/getline, modules/getpagesize,
19903         modules/getpass, modules/getugroups, modules/group-member,
19904         modules/hard-locale, modules/hash, modules/human, modules/idcache,
19905         modules/inttostr, modules/long-options, modules/makepath,
19906         modules/md5, modules/memcasecmp, modules/memcoll,
19907         modules/modechange, modules/mountlist, modules/path-concat,
19908         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
19909         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
19910         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
19911         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
19912         modules/strftime, modules/strndup, modules/strverscmp,
19913         modules/timespec, modules/unlocked-io, modules/userspec,
19914         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
19915         modules/yesno:
19916         Remove lib_SOURCES line from Makefile.am section, as this is now
19917         done automatically by the corresponding Autoconf macro.
19918
19919 2005-03-21  Jim Meyering  <jim@meyering.net>
19920
19921         Changes imported from coreutils.
19922
19923         * lib/cycle-check.c: Don't include xalloc.h.
19924
19925         * lib/path-concat.c: Don't include assert.h.
19926         (path_concat): Remove assertion that would have triggered
19927         for ABASE starting with more than one slash.
19928         Reported by Andreas Schwab.
19929
19930         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
19931         properly when ABASE is an absolute file name.
19932         Correct the description of this function.
19933         Include <assert.h>.
19934         Add an assertion and a test driver.
19935         This fixes a bug introduced on 2004-07-02.
19936         Andreas Schwab reported the resulting failure of cp --parents:
19937         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
19938
19939 2005-03-21  Jim Meyering  <jim@meyering.net>
19940
19941         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
19942         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
19943
19944 2005-03-21  Jim Meyering  <jim@meyering.net>
19945         and  Paul Eggert  <eggert@cs.ucla.edu>
19946
19947         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
19948         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
19949         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
19950         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
19951         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
19952         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
19953         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
19954         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
19955         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
19956         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
19957         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
19958         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
19959         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
19960         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
19961         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
19962         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
19963         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
19964         for these modules.
19965
19966 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
19967
19968         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
19969         (which shouldn't happen), generate nothing instead of returning 0
19970         immediately, so that nstrftime (NULL, ...) doesn't return 0.
19971
19972 2005-03-16  Bruno Haible  <bruno@clisp.org>
19973
19974         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
19975         HAVE_LONGLONG_64BIT.
19976
19977 2005-03-16  Bruno Haible  <bruno@clisp.org>
19978
19979         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
19980         HAVE_LONGLONG_64BIT.
19981
19982 2005-03-16  Bruno Haible  <bruno@clisp.org>
19983
19984         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
19985         HAVE_LONGLONG_64BIT.
19986
19987 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
19988
19989         * lib/strftime.c (my_strftime): Prepend space to format so that we can
19990         reliably distinguish strftime failure from empty output on POSIX
19991         hosts.
19992
19993 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
19994
19995         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
19996         (iconv_string): Don't guess a size-zero buffer, as that might cause
19997         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
19998         result would be 'too large', where 'too large' is (heuristically)
19999         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
20000         overflow concerns.  This will prevent some unwanted malloc failures
20001         when the inputs are very large.
20002
20003 2005-03-15  Karl Berry  <karl@gnu.org>
20004
20005         * config/srclist.txt (config.rpath): from gettext.
20006         * config/config.rpath: update.
20007
20008 2005-03-15  Bruno Haible  <bruno@clisp.org>
20009
20010         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
20011         to 'negate'.
20012
20013         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
20014         variable.
20015
20016         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
20017         results.
20018
20019 2005-03-14  Simon Josefsson  <jas@extundo.com>
20020
20021         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
20022         <fx@gnu.org>.
20023
20024 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
20025
20026         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
20027         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
20028         intprops.h.
20029         * lib/strtol.c: Likewise.
20030
20031 2005-03-14  Jim Meyering  <jim@meyering.net>
20032
20033         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
20034         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
20035         to be nonzero so that we (and caller) can detect the difference
20036         between a valid zero-length expansion and an error return, even
20037         when the underlying strftime fails before writing anything into
20038         that location.
20039
20040 2005-03-14  Bruno Haible  <bruno@clisp.org>
20041
20042         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
20043         Update from GNU gettext 0.14.3.
20044
20045 2005-03-10  Jim Meyering  <jim@meyering.net>
20046
20047         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
20048
20049 2005-03-10  Jim Meyering  <jim@meyering.net>
20050
20051         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
20052         so that this module works on systems without fchdir.
20053
20054 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
20055
20056         Factor int-properties macros into a single file, except for
20057         glibc-related files.
20058         * lib/intprops.h: New file.
20059         * lib/getloadavg.c: Include it instead of limits.h.
20060         (INT_STRLEN_BOUND): Remove.
20061         * lib/human.c: Include intprops.h.
20062         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
20063         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
20064         302/1000.
20065         * lib/inttostr.h: Include intprops.h instead of limits.h.
20066         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
20067         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
20068         for consistency with intprops.h.
20069         (time_t_is_integer, twos_complement_arithmetic): Use them.
20070         * lib/sig2str.h: Include <signal.h>, intprops.h.
20071         (INT_STRLEN_BOUND): Remove.
20072         * lib/strftime.c (TYPE_SIGNED): Remove.
20073         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
20074         * lib/strtol.c: Adjust comments to match intprops.h.
20075         * lib/userspec.c: Include intprops.h.
20076         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
20077         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
20078         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
20079         instead of rolling our own expressions.
20080         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
20081
20082         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
20083         instead of int.
20084         (my_strftime): Do not mishandle years close to INT_MAX, by doing
20085         the right thing even if adding 1900 would overflow.  Similarly
20086         for tm_mon + 1 and tm_yday + 1.
20087         Make %Y always equivalent to %C%y, and similarly for %G and %g.
20088         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
20089         (DO_SIGNED_NUMBER): New macro.
20090         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
20091
20092 2005-03-07  Bruno Haible  <bruno@clisp.org>
20093
20094         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
20095
20096 2005-03-07  Bruno Haible  <bruno@clisp.org>
20097
20098         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
20099
20100 2005-03-04  Derek R. Price  <derek@ximbiot.com>
20101
20102         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
20103         (func_import): Only replace files via --import when they have actually
20104         changed.
20105
20106 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20107
20108         * m4/mmap-anon.m4: New file.
20109         * m4/pagealign_alloc.m4: New file.
20110
20111 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20112             Bruno Haible  <bruno@clisp.org>
20113
20114         * modules/pagealign_alloc: New file.
20115         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
20116
20117 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20118             Bruno Haible  <bruno@clisp.org>
20119
20120         * lib/pagealign_alloc.h: New file.
20121         * lib/pagealign_alloc.c: New file.
20122
20123 2005-03-03  Bruno Haible  <bruno@clisp.org>
20124
20125         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
20126         Use an all-permissive copyright notice, recommended by RMS.
20127
20128 2005-03-02  Bruno Haible  <bruno@clisp.org>
20129
20130         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
20131         of AIX, the replacement has to be done only after <string.h> is
20132         included, therefore not in config.h. stpncpy.h does the replacement,
20133         and stpncpy.c uses it.
20134
20135 2005-03-02  Bruno Haible  <bruno@clisp.org>
20136
20137         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
20138         stpncpy.c uses it.
20139
20140 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20141
20142         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
20143         The workaround isn't strictly needed for POSIX conformance, and
20144         it's too much of a pain to configure and maintain.  We'll ask
20145         people to fix their kernels instead.
20146         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
20147         (NANOSLEEP_BUG_WORKAROUND): Remove.
20148         (xnanosleep): Remove the workaround.
20149
20150 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20151
20152         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
20153         Reported by Derek Price.
20154         (Include): Add "timespec.h".
20155
20156         * modules/xnanosleep (Depends-on): Remove gethrxtime.
20157
20158 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20159
20160         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
20161         to detect nanosleep bug.
20162
20163 2005-03-01  Bruno Haible  <bruno@clisp.org>
20164
20165         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
20166
20167 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
20168
20169         * modules/gethrxtime: New file.
20170         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
20171         (Depends-on): Add gethrxtime.
20172         (configure.ac): Add gl_XNANOSLEEP.
20173         (Makefile.am): Remove lib_SOURCES line.
20174
20175 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20176
20177         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
20178         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
20179
20180 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20181
20182         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
20183         * lib/timespec.h (gettime): Return void, since it always
20184         succeeds now.  All uses changed.
20185         * lib/gettime.c (gettime) Likewise.
20186         [HAVE_NANOTIME]: Prefer nanotime.
20187         Assume gettimeofday succeeds, as POSIX requires.
20188         Assime time () succeeds, since other code already does.
20189         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
20190         (timespec_subtract): Remove.
20191         (NANOSLEEP_BUG_WORKAROUND): New constant.
20192         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
20193         things considerably.  Use it only on GNU/Linux hosts, since the
20194         workaround shouldn't be needed elsewhere.
20195
20196 2005-02-24  Bruno Haible  <bruno@clisp.org>
20197
20198         * modules/gettext (Files): Add m4/glibc2.m4.
20199
20200 2005-02-24  Bruno Haible  <bruno@clisp.org>
20201
20202         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
20203         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
20204         * m4/progtest.m4:
20205         Update from GNU gettext 0.14.2.
20206         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
20207
20208 2005-02-24  Bruno Haible  <bruno@clisp.org>
20209
20210         * lib/localcharset.c: Update from GNU gettext 0.14.2.
20211         * lib/config.charset: Update from GNU gettext 0.14.2.
20212
20213 2005-02-24  Bruno Haible  <bruno@clisp.org>
20214
20215         * lib/gettext.h: Update from GNU gettext 0.14.2.
20216
20217 2005-02-23  Simon Josefsson  <jas@extundo.com>
20218
20219         * m4/iconvme.m4: New file.
20220
20221 2005-02-23  Jim Meyering  <jim@meyering.net>
20222
20223         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
20224         change.
20225         Thanks to Bruno Haible for catching it.
20226
20227 2005-02-22  Simon Josefsson  <jas@extundo.com>
20228
20229         * modules/iconvme: New file.
20230
20231         * MODULES.html.sh: Add iconvme.
20232
20233 2005-02-22  Simon Josefsson  <jas@extundo.com>
20234
20235         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
20236
20237 2005-02-22  Simon Josefsson  <jas@extundo.com>
20238
20239         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
20240
20241 2005-02-22  Jim Meyering  <jim@meyering.net>
20242
20243         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
20244         s/ifndef/ifdef/.
20245
20246 2005-02-20  Neil Conway  <neilc@samurai.com>
20247
20248         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
20249         returned by OSX/Darwin if the specified buffer is not large
20250         enough for the hostname.
20251
20252 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20253
20254         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
20255         pass it to _help, otherwise the latter coredumps trying to
20256         dereference state.root_argp.
20257
20258 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20259
20260         * modules/chdir-long (Depends-on): Add memrchr.
20261         * modules/memrchr (Files): Add lib/memrchr.h.
20262         (Include): "memrchr.h".
20263
20264 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20265
20266         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
20267
20268 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20269
20270         * lib/memrchr.h: New file.
20271         * lib/chdir-long.c: Include it.
20272         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
20273         Don't bother including stddef.h.
20274
20275 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
20276
20277         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
20278         inclusion.
20279         Include <sys/types.h>, for dev_t.
20280         (ME_DUMMY, ME_REMOTE): Move from here....
20281         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
20282         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
20283         Dmitry V. Levin.
20284         Include mountlist.h first, to test the interface.
20285
20286 2005-01-29  Bruno Haible  <bruno@clisp.org>
20287
20288         * lib/progname.c (program_name): Initialize.
20289         Needed when linking statically on MacOS X.
20290
20291 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20292
20293         Sync from coreutils.
20294         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
20295         (Depends-on): Add c-strtod.
20296         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
20297
20298 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20299
20300         Sync from coreutils.
20301         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
20302
20303         Remove files that are specific to coreutils.
20304         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
20305
20306 2005-01-28  Bruno Haible  <bruno@clisp.org>
20307
20308         * modules/javacomp: New file.
20309         * MODULES.html.sh (Java): Add javacomp.
20310
20311 2005-01-28  Bruno Haible  <bruno@clisp.org>
20312
20313         * m4/javacomp.m4: New file, from GNU gettext.
20314
20315 2005-01-28  Bruno Haible  <bruno@clisp.org>
20316
20317         * lib/javacomp.sh.in: New file, from GNU gettext.
20318         * lib/javacomp.h: New file, from GNU gettext.
20319         * lib/javacomp.c: New file, from GNU gettext.
20320
20321 2005-01-26  Simon Josefsson  <jas@extundo.com>
20322
20323         * lib/gai_strerror.c: Use GPL in header.
20324
20325 2005-01-26  Bruno Haible  <bruno@clisp.org>
20326
20327         * modules/javaexec: New file.
20328         * MODULES.html.sh (Java): Add javaexec.
20329
20330 2005-01-26  Bruno Haible  <bruno@clisp.org>
20331
20332         * m4/javaexec.m4: New file, from GNU gettext.
20333
20334 2005-01-26  Bruno Haible  <bruno@clisp.org>
20335
20336         * lib/javaexec.sh.in: New file, from GNU gettext.
20337         * lib/javaexec.h: New file, from GNU gettext.
20338         * lib/javaexec.c: New file, from GNU gettext.
20339
20340 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20341
20342         * modules/lchown (Depends-on): Remove lchown.h
20343
20344 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20345
20346         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
20347         must be defined if the header file was not found, in order
20348         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
20349
20350 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20351
20352         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
20353         initializers for struct pentry_state.
20354         (__argp_error): Check return value of __asprintf
20355         (__argp_failure): Translate error message
20356
20357         * lib/argp-parse.c: Removed braces around the expansion of N_()
20358
20359 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
20360
20361         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
20362         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
20363         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
20364         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
20365         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
20366         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
20367         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
20368         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
20369         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
20370         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
20371         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
20372         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
20373         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
20374         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
20375         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
20376         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
20377         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
20378         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
20379         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
20380         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
20381         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
20382         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
20383         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
20384         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
20385         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
20386         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
20387         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
20388         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
20389         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
20390         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
20391         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
20392         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
20393         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
20394         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
20395         xstrtol.m4, xstrtoumax.m4, yesno.m4:
20396         Use an all-permissive copyright notice, recommended by RMS.
20397
20398 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
20399
20400         * modules/chdir-long (Depends-on): Remove mempcpy.
20401
20402 2005-01-21  Jim Meyering  <jim@meyering.net>
20403
20404         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
20405         same value as for Solaris 9.
20406
20407         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
20408         component length.  This included changing the parameter to be
20409         of type `char *' rather than `char const *'.
20410         * lib/chdir-long.h (chdir_long): Update prototype.
20411
20412         * lib/openat.c (fdopendir, fstatat): New functions.
20413         * lib/openat.h: Include headers required for use of DIR and struct
20414         stat.
20415         [AT_SYMLINK_NOFOLLOW]: Define.
20416         (fdopendir, fstatat): Add prototypes.
20417
20418 2005-01-21  Bruno Haible  <bruno@clisp.org>
20419
20420         * modules/classpath: New file.
20421         * MODULES.html.sh (Java): Add classpath.
20422
20423 2005-01-21  Bruno Haible  <bruno@clisp.org>
20424
20425         * lib/classpath.h: New file, from GNU gettext.
20426         * lib/classpath.c: New file, from GNU gettext.
20427
20428 2005-01-20  Simon Josefsson  <jas@extundo.com>
20429
20430         * modules/version-etc-fsf: New file.
20431
20432 2005-01-20  Simon Josefsson  <jas@extundo.com>
20433
20434         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
20435         * lib/version-etc.c: Remove version_etc_copyright.
20436         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
20437         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
20438
20439 2005-01-20  Simon Josefsson  <jas@extundo.com>
20440
20441         * lib/base64.h (isbase64): Add.
20442
20443         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
20444         using a unsigned prototype, don't inline.
20445         (base64_decode): Use it.
20446
20447 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20448
20449         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
20450         it.
20451
20452 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20453
20454         * lib/save-cwd.c (save_cwd): Remove code to support the case
20455         where fchdir is missing or flaky.
20456
20457 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20458
20459         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
20460
20461 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
20462
20463         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
20464         AC_LIBSOURCES now does this.
20465         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
20466         with new ullong_max module.
20467
20468 2005-01-19  Bruno Haible  <bruno@clisp.org>
20469
20470         * modules/sh-quote: New file.
20471         * MODULES.html.sh (Executing programs): Add sh-quote.
20472
20473 2005-01-19  Bruno Haible  <bruno@clisp.org>
20474
20475         * lib/sh-quote.h: New file, from GNU gettext.
20476         * lib/sh-quote.c: New file, from GNU gettext.
20477
20478 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20479
20480         Merge from coreutils.
20481         * m4/ullong_max.m4: New file.
20482         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
20483         (gl_MACROS): Assume localeconv exists.
20484
20485 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20486
20487         Merge changes from coreutils, as described below in several
20488         changelogs dated today.
20489
20490         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
20491         (O_DIRECTORY): Remove; not needed here, since "." must be
20492         a directory.  All uses removed.
20493         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
20494         universal on Suns, and we also need to test for IRIX.
20495         Revamp code to use 'if' rather than '#if'.
20496         Avoid unnecessary comparison of cwd->desc to 0.
20497
20498         * lib/utimens.c (futimens): Robustify the previous patch, by checking
20499         for known valid error numbers rather than observed invalid ones.
20500
20501 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20502
20503         * modules/ullong_max: New file.
20504
20505         * modules/chdir-long, modules/openat: New files.
20506         * modules/save-cwd (Depends-on): Depend on chdir-long.
20507         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
20508
20509 2005-01-18  Jim Meyering  <jim@meyering.net>
20510
20511         Merge from coreutils.
20512         * m4/chdir-long.m4, m4/openat.m4: New files.
20513         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
20514         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
20515         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
20516         is sane and DOES follow symlinks.  Besides, testing 20 different
20517         systems found no broken chown implementations.
20518         Prompted by a change in rsync's copy of this macro.
20519         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
20520
20521         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
20522
20523         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
20524         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
20525         NULL-means-set-to-current-time semantics.
20526         Remove temporary file immediately, rather than waiting
20527         for configure's at-exit trap code to do it.
20528
20529 2005-01-18  Jim Meyering  <jim@meyering.net>
20530
20531         * lib/version-etc.c (version_etc_copyright): Update copyright date.
20532
20533         * lib/utimens.c (futimens): Account for the fact that futimes
20534         can also fail with errno == ENOSYS or errno == ENOENT.
20535         Patch from Dmitry V. Levin.
20536
20537         Change the name of the robust chdir function from chdir to chdir_long.
20538         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
20539         (restore_cwd): Use chdir_long, not chdir.
20540         * lib/chdir-long.c: Renamed from chdir.c.
20541         * lib/chdir-long.h: Renamed from chdir.h.
20542         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
20543         Hurd.
20544
20545 2005-01-18  Bruno Haible  <bruno@clisp.org>
20546
20547         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
20548         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
20549         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
20550         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
20551         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
20552         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
20553         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
20554         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
20555         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
20556         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
20557         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
20558         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
20559         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
20560         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
20561         Use an all-permissive copyright notice, recommended by RMS.
20562
20563 2005-01-18  Bob Proulx  <bob@proulx.com>
20564
20565         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
20566         simplify offsetof() macro construct to avoid compile failure with
20567         native HP-UX 11.0 ANSI C compiler.
20568
20569 2005-01-17  Bruno Haible  <bruno@clisp.org>
20570
20571         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
20572         redundant because stpncpy.m4 takes care of it.
20573
20574 2005-01-17  Bruno Haible  <bruno@clisp.org>
20575
20576         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
20577
20578 2005-01-17  Bruno Haible  <bruno@clisp.org>
20579
20580         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
20581         used.
20582
20583 2005-01-17  Bruno Haible  <bruno@clisp.org>
20584
20585         * lib/fwriteerror.h (fwriteerror): Change specification to include
20586         fclose.
20587         * lib/fwriteerror.c: Include <stdbool.h>.
20588         (fwriteerror): At the end, close the file stream. Record whether
20589         stdout was already closed.
20590
20591 2005-01-17  Bruno Haible  <bruno@clisp.org>
20592
20593         * lib/execute.c (environ): Declare if needed.
20594         * lib/pipe.c (environ): Likewise.
20595         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
20596
20597 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20598
20599         * modules/argp: Depend on vsnprintf
20600
20601 2005-01-10  Jim Meyering  <jim@meyering.net>
20602
20603         * modules/closeout (Depends-on): Add atexit.
20604
20605 2005-01-06  Bruno Haible  <bruno@clisp.org>
20606
20607         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
20608
20609 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
20610
20611         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
20612         definitions to be after all include files, to avoid collisions.
20613         Problem reported by Bob Proulx.
20614
20615 2005-01-04  Jim Meyering  <jim@meyering.net>
20616
20617         Changes imported from coreutils.
20618         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
20619         as the mkstemp template, use a temporary directory and an
20620         8.3-friendly template to avoid trouble on systems like DJGPP.
20621         Reported by Juan M. Guerrero via Stepan Kasal.
20622         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
20623         close. Remove the temporary directory right away, rather than waiting
20624         for configure's at-exit trap code to do it.
20625         Suggestion from Stepan Kasal.
20626
20627 2005-01-01  Simon Josefsson  <jas@extundo.com>
20628
20629         * gnulib-tool: Print #include directives when --import'ing.
20630
20631 2004-12-28  Simon Josefsson  <jas@extundo.com>
20632
20633         * tests/test-base64.c: Include required header files.  Remove
20634         unused variables.
20635
20636 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
20637
20638         * modules/error (Depends-on): Remove gettext.
20639
20640 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
20641
20642         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
20643         not needed.  This removes a dependency on the gettext module.
20644         [defined _LIBC]: Do not include <libintl.h>; not needed.
20645
20646 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
20647
20648         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
20649         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
20650
20651 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
20652
20653         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
20654         HAVE_DECL_STRTOLD.
20655
20656 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
20657
20658         * modules/getdate (Depends-on): Remove alloca-opt.
20659
20660 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
20661
20662         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
20663
20664 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
20665
20666         * lib/argp-parse.c: Include <stddef.h>.
20667         (alignof, alignto): New macros.
20668         (parser_init): Don't assume that void * is aligned sufficiently
20669         for struct option.
20670
20671         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
20672         need to extend the stack.
20673         (YYINITDEPTH): New macro, so that the initial stack isn't overly
20674         large.
20675
20676 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20677
20678         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
20679
20680 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
20681
20682         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
20683         (2004-10-24) change.  Apparently this was a false alarm.
20684
20685         * modules/getdate: Depend on alloca-opt, not alloca.
20686
20687 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
20688
20689         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
20690         Remove now-obsolete comment about AIX.
20691         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
20692         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
20693         (YYMAXDEPTH): New macro.
20694
20695 2004-12-18  Simon Josefsson  <jas@extundo.com>
20696
20697         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
20698
20699 2004-12-18  Bruno Haible  <bruno@clisp.org>
20700
20701         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
20702
20703 2004-12-18  Bruno Haible  <bruno@clisp.org>
20704
20705         * lib/fatal-signal.c (fatal_signals): Make non-const.
20706         (init_fatal_signals): New function.
20707         (uninstall_handlers, install_handlers): Ignore signals that were set to
20708         SIG_IGN.
20709         (at_fatal_signal): Call init_fatal_signals.
20710         (init_fatal_signal_set): Likewise. Ignore signals that were set to
20711         SIG_IGN.
20712         Reported by Paul Eggert.
20713
20714 2004-12-18  Bruno Haible  <bruno@clisp.org>
20715
20716         * doc/alloca.texi: New file.
20717         * doc/alloca-opt.texi: New file.
20718
20719 2004-12-17  Jim Meyering  <jim@meyering.net>
20720
20721         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
20722         Otherwise, install-sh could exit with improper exit status when
20723         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
20724
20725 2004-12-16  Simon Josefsson  <jas@extundo.com>
20726
20727         * tests/test-base64.c: Add license.
20728
20729 2004-12-15  Stepan Kasal  <address@hidden>
20730
20731         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
20732
20733 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
20734
20735         * modules/getcwd (Files): Add m4/d-ino.m4.
20736         Suggested by Mark D. Baushke.
20737
20738 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
20739
20740         * lib/getdate.y (textint): New member "negative".
20741         (time_zone_hhmm): New function.
20742         Expect 14 shift-reduce conflicts, not 13.
20743         (o_colon_minutes): New rule.
20744         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
20745         (yylex): Set the "negative" member of signed numbers.
20746
20747 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
20748
20749         * doc/getdate.texi (Time of day items, Time zone items):
20750         Describe new formats +00:00, UTC+00:00.
20751
20752 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
20753
20754         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
20755         spurious "-l"s.  Problem reported by Stepan Kasal.
20756
20757 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
20758
20759         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
20760         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
20761
20762 2004-12-04  Simon Josefsson  <jas@extundo.com>
20763
20764         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
20765         Vandoorselaere <yoann@prelude-ids.org>.
20766
20767 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
20768
20769         Changes imported from coreutils.
20770         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
20771         exist.
20772         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
20773
20774 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
20775
20776         Changes imported from coreutils.
20777         * lib/hard-locale.c: Assume <locale.h> exists.
20778         Include "strdup.h".
20779         (GLIBC_VERSION): New macro.
20780         (hard_locale): Assume setlocale exists.
20781         Rewrite to avoid #ifdef.
20782         Use strdup rather than malloc + strcpy.
20783         * lib/human.c: Assume <locale.h> exists.
20784         (human_readable): Assume localeconv exists.
20785
20786 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
20787
20788         * modules/hard-locale (Depends-on): Add strdup.
20789
20790 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
20791
20792         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
20793         convert T2, not T.  (Imported from libc.)
20794
20795 2004-11-30  Simon Josefsson  <jas@extundo.com>
20796
20797         * modules/restrict (License): Change to LGPL.
20798
20799 2004-11-30  Simon Josefsson  <jas@extundo.com>
20800
20801         * m4/restrict.m4: Add copyright and copying conditions.
20802
20803 2004-11-30  Simon Josefsson  <jas@extundo.com>
20804
20805         * m4/base64.m4: New file.
20806
20807 2004-11-30  Simon Josefsson  <jas@extundo.com>
20808
20809         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
20810         base64.
20811
20812         * tests/test-base64.c: New file.
20813
20814         * modules/base64: New file.
20815
20816 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
20817
20818         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
20819         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
20820
20821         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
20822
20823 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
20824
20825         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
20826         (__getcwd.c): Don't restore errno; glibc doesn't.
20827         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
20828         first, falling back to our code only if its results look suspicious.
20829         Ensure that the resulting buffer is only as large as necessary.
20830
20831         * lib/readutmp.c: Include readutmp.h first.
20832         Include <errno.h>, since readutmp.h no longer does that.
20833         * lib/readutmp.h: Don't include <errno.h>,
20834         <sys/param.h>, <time.h>; not needed to establish interface.
20835         (errno): Remove decl.
20836         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
20837         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
20838         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
20839
20840 2004-11-28  Simon Josefsson  <jas@extundo.com>
20841
20842         * lib/base64.h, base64.c: New file.
20843
20844 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
20845
20846         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
20847
20848 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
20849
20850         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
20851         (Depends-on): Remove pathmax, same.  Add mempcpy.
20852         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
20853         (Makefile.am): Append getcwd.h to lib_SOURCES.
20854         (Include): Add getcwd.h.
20855         (Maintainer): Change from Jim Meyering to "all, glibc",
20856         since getdate now uses intended-for-glibc code.
20857         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
20858         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
20859
20860 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
20861
20862         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
20863         HP's ANSI C compiler.
20864         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
20865         Declaring int functions causes warnings on some modern systems and
20866         shouldn't be needed to compile on ancient ones.
20867         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
20868         defined.
20869
20870         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
20871         with the following changes.
20872         (__set_errno): Parenthesize properly.
20873         Include <stdbool.h>.
20874         (MIN, MAX, MATCHING_INO): New macros.
20875         (__getcwd): Define with prototype, not K&R form.
20876         Use heuristics to allocate default buffer on stack if possible.
20877         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
20878         behavior, and to avoid the PATH_MAX limit when computing
20879         ../../../../...
20880         Use MATCHING_INO to compare inode number to file.
20881         Check for arithmetic overflow in size calculations.
20882         Fix bug in reallocation of dot array that caused getcwd to fail
20883         on directories nested deeper than 75.
20884         Be more careful about saving errno on error.
20885         Do not use realloc; use only free+malloc, as this is a bit
20886         more flexible and avoids a needless copy operation.
20887         Do not inspect st_dev and st_ino for symbolic links; POSIX
20888         doesn't specify the latter.
20889         Check for closedir errors.
20890         Avoid needless casts.
20891         Use "#ifdef weak_alias" around weak_alias, to be like other
20892         glibc code.
20893         The following changes to getcwd.c have effect only when used in
20894         gnulib; they have no effect inside glibc proper.
20895         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
20896         as alloca isn't used.
20897         (alloca, __alloca): Likewise.
20898         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
20899         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
20900         unconditionally, as gnulib assumes C89 or better.
20901         Do not include <sys/param.h>.
20902         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
20903         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
20904         better.
20905         (NULL) [!defined NULL]: Remove; we assume C89 or better.
20906         Include <dirent.h> in a way that is compatible with modern Autoconf.
20907         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
20908         New macros, if not already defined.
20909         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
20910         Use "_LIBC", not "defined _LIBC", for consistency.
20911         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
20912         a mempcpy module.
20913         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
20914         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
20915         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
20916         credit only to Jim Meyering and adjust the copyright dates.
20917         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
20918         <stdlib.h>, <unistd.h>, "pathmax.h".
20919         Instead, include "xgetcwd.h" (first) and "getcwd.h".
20920         (INITIAL_BUFFER_SIZE): Remove.
20921         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
20922
20923 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
20924
20925         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
20926         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
20927         Use the _ONCE methods, for efficiency.
20928         Check for fcntl.h.  In test program, include <errno.h>
20929         and <fcntl.h> if available.  Remove old K&R cruft from
20930         test program.  Check for common errors in GNU/Linux,
20931         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
20932         don't do AC_LIBOBJ, as that's getcwd.m4's job.
20933         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
20934         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
20935         name accordingly.
20936         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
20937         accommodate new getcwd.c.
20938         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
20939         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
20940         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
20941         that's all we need now.
20942
20943 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20944
20945         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
20946         argp-parse.c depends on getopt internals, that means we should
20947         always use our getopt, to be on the safe side.
20948         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
20949         order not to spoil the result of an eventual previous invocation
20950         of gl_GETOPT_SUBSTITUTE.
20951
20952 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20953
20954         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
20955         redefinition warnings. To avoid them, include the defines
20956         in `#if !defined __need_getopt ... #endif'. The only place
20957         where __getopt_argv_const is used is in definitions
20958         of getopt_long and getopt_long_only below, which are as well
20959         protected by `#ifndef __need_getopt'.
20960         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
20961         __need_getopt after including <stdio.h> and <unistd.h> These
20962         headers might have defined it.
20963
20964 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
20965
20966         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
20967
20968 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
20969
20970         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
20971         (futimens): New function, which uses futimes if available.
20972         (futimens, utimens): Support timespec==NULL, with same semantics
20973         as utime and utimens.
20974         * lib/utimens.h (futimens): New decl.
20975
20976 2004-11-23  Jim Meyering  <jim@meyering.net>
20977
20978         * lib/getopt_.h: Remove trailing blanks.
20979
20980 2004-11-23  Jim Meyering  <jim@meyering.net>
20981
20982         * lib/__fpending.c: Add comment.
20983
20984 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
20985
20986         * modules/canonicalize (Depends-on): Add xreadlink.
20987         Problem reported by James Youngman.
20988
20989 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
20990
20991         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
20992         New macros.
20993         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
20994         optopt): Use them instead of invoking ## directly; otherwise, the
20995         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
20996
20997 2004-11-19  Bruno Haible  <bruno@clisp.org>
20998
20999         * lib/strtok_r.c: Move comments from here...
21000         * lib/strtok_r.h: ... to here.
21001
21002 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21003
21004         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
21005         implementations that mishandle size_t overflow.
21006
21007 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21008
21009         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
21010         might fail.  Problem reported by Yoann Vandoorselaere.
21011         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
21012         implementations that mishandle size_t overflow.
21013
21014 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21015
21016         * modules/canon-host (Depends-on): Add strdup.
21017
21018 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21019
21020         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
21021
21022 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21023
21024         * lib/canon-host.c: Include "strdup.h".
21025         (canon_host): Use getaddrinfo if available, so that IPv6 works.
21026         Use strdup instead of malloc/strcpy to duplicate strings.
21027
21028         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
21029         (human_space_before_unit): New constant.
21030         * lib/human.c (human_readable): Support it.
21031
21032         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
21033         (xgetcwd): Set errno correctly when failing.
21034         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
21035         the failure is actually due to a PATH_MAX problem.
21036
21037         Further getopt changes to make it more likely that glibc will
21038         buy the changes back.
21039         * lib/getopt.c (POSIXLY_CORRECT): New constant.
21040         (getopt): Use it, so to preserve glibc semantic
21041         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
21042         when compiling for libc.
21043         * lib/getopt_.h (__getopt_argv_const): Bring it back.
21044         (getopt_long, getopt_long_only): Use it.
21045
21046         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21047         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
21048         (getopt): Argv is now char * const *, as per standard.
21049         (_getopt_internal_r, _getopt_internal): Argv is now char **,
21050         not char *__getopt_argv_const *.
21051         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21052         _getopt_long_only_r): Likewise.
21053         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
21054         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21055         _getopt_long_r, _getopt_long_only_r): Likewise.
21056         * lib/getopt_.h (__getopt_argv_const): Remove.
21057         (getopt): Argv is now char * const *, as per standard.
21058
21059         * lib/getdate.y (tORDINAL): New token.
21060         (day, relunit): Allow it for relative times.
21061         (relative_time_table): Use tORDINAL for ordinals.
21062
21063 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21064
21065         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
21066         Document that "second" isn't allowed as an ordinal number.
21067
21068 2004-11-16  Jim Meyering  <jim@meyering.net>
21069
21070         * modules/closeout (Depends-on): Add fpending.
21071
21072 2004-11-15  Jim Meyering  <jim@meyering.net>
21073
21074         * lib/closeout.c: Include "__fpending.h" once again.
21075         Include <stdbool.h>.
21076         (close_stdout): Don't fail just because stdout was closed initially,
21077         since some programs don't write to stdout in the normal course of
21078         operation (other than --version and --help), and we don't want this
21079         function to make e.g. `touch file >&-' fail.
21080         But do fail if it was closed and someone has tried to write to it.
21081         E.g., `printf foo >&-' must fail.
21082
21083 2004-11-13  Jim Meyering  <jim@meyering.net>
21084
21085         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
21086
21087 2004-11-12  Simon Josefsson  <jas@extundo.com>
21088
21089         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
21090         small doc fix is still pending.
21091
21092 2004-11-11  Simon Josefsson  <jas@extundo.com>
21093
21094         * modules/strtok_r: New file.
21095
21096         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21097         strtok_r.
21098
21099 2004-11-11  Simon Josefsson  <jas@extundo.com>
21100
21101         * m4/strtok_r.m4: New file.
21102
21103         * m4/getopt.m4: Replace opterr.
21104
21105 2004-11-11  Simon Josefsson  <jas@extundo.com>
21106
21107         * lib/strtok_r.h, strtok_r.c: New file.
21108
21109 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21110
21111         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
21112         of replacing opterr, getopt, etc.  This should handle the
21113         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
21114
21115 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21116
21117         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
21118         we can stop lying to compilers about the constness of argv when we
21119         are compiled outside glibc.
21120         (getopt, getopt_long, getopt_long_only): Use it.
21121         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21122         _getopt_internal, getopt): Likewise.
21123         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21124         _getopt_long_only_r): Likewise.
21125         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21126         _getopt_long_r, _getopt_long_only_r): Likewise.
21127
21128         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
21129         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
21130         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
21131         the other external symbols.
21132         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
21133         declaration, since the above renaming now works around collisions.
21134
21135 2004-11-11  Jim Meyering  <jim@meyering.net>
21136
21137         * lib/linebreak.c: Remove trailing blanks.
21138         * lib/alloca_.h: Likewise.
21139         * lib/acosl.c: Likewise.
21140         * lib/euidaccess.c: Likewise.
21141         * lib/allocsa.h: Likewise.
21142
21143 2004-11-10  Simon Josefsson  <jas@extundo.com>
21144
21145         * m4/getaddrinfo.m4: New file.
21146
21147 2004-11-10  Simon Josefsson  <jas@extundo.com>
21148
21149         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
21150
21151 2004-11-10  Simon Josefsson  <jas@extundo.com>
21152
21153         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21154         getaddrinfo.
21155
21156         * modules/getaddrinfo: New file.
21157
21158 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21159
21160         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
21161
21162 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21163
21164         * lib/mktime.c (SHR): New macro, which is a portable
21165         substitute for >> that should work even on Crays.
21166         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
21167         Problem reported by Mark D. Baushke in
21168         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
21169         * lib/getdate.y (SHR): Likewise.
21170         (tm_diff): Use it.
21171         * lib/strftime.c (SHR): Likewise.
21172         (tm_diff): Use it.
21173         * lib/quotearg.c (struct quoting_options): Use unsigned int for
21174         quote_these_too, so that right shifts are well defined.  All uses
21175         changed.
21176
21177 2004-11-10  Jim Meyering  <jim@meyering.net>
21178
21179         Ensure that no close failure goes unreported.
21180         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
21181         return early when it seems there's nothing to flush.
21182         Don't include __fpending.h.
21183
21184 2004-11-10  Jim Meyering  <jim@meyering.net>
21185
21186         * modules/closeout (Depends-on): Remove fpending.
21187
21188 2004-11-10  Jim Meyering  <jim@meyering.net>
21189
21190         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
21191
21192 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21193
21194         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
21195         gl_FUNC_STRFTIME.
21196         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
21197         and AC_REQUIRE when possible, to avoid duplicate checks.
21198         Check for <wchar.h>.
21199
21200 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21201
21202         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
21203
21204 2004-11-09  Bruno Haible  <bruno@clisp.org>
21205
21206         * m4/sockpfaf.m4: New file.
21207
21208 2004-11-05  Bruno Haible  <bruno@clisp.org>
21209
21210         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
21211         Reported by Mark D. Baushke <mdb@cvshome.org>.
21212
21213 2004-11-04  Bruno Haible  <bruno@clisp.org>
21214
21215         2004-09-11  Bruno Haible  <bruno@clisp.org>
21216                 * allocsa.valgrind: New file.
21217         2004-02-06  Bruno Haible  <bruno@clisp.org>
21218                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
21219                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
21220                 Reported by Christopher Seip <chris.seip@hp.com>.
21221
21222 2004-11-04  Bruno Haible  <bruno@clisp.org>
21223
21224         * modules/allocsa (Files): Add lib/allocsa.valgrind.
21225         (Makefile.am): Distribute it.
21226
21227 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
21228
21229         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
21230         with errno == ERANGE if the buffer is too small.
21231         Problem reported by Mark D. Baushke.
21232
21233 2004-11-03  Albert Chin  <china@thewrittenword.com>
21234             Paul Eggert  <eggert@cs.ucla.edu>
21235
21236         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
21237         equivalent, substitute $ac_type for equivalent type rather than
21238         blindly using uint32_t *always* which won't work if uint32_t is not
21239         available.  Define _UINT32_T to work around typedef of uint32_t if
21240         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
21241         2.5.1.
21242
21243 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21244
21245         * m4/jm-macros.m4: Sync from coreutils.
21246         (gl_MACROS): Check for mbrlen, for pathchk.
21247         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
21248
21249 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21250
21251         * lib/xreadlink.c (MAXSIZE): New macro.
21252         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
21253         size does not exceed MAXSIZE.  Avoid cast.
21254         As suggested by Mark D. Baushke in
21255         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
21256         if readlink fails with buffer size just under MAXSIZE, try again
21257         with MAXSIZE.
21258
21259 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21260
21261         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
21262
21263 2004-11-02  Derek R. Price  <derek@ximbiot.com>
21264         and  Paul Eggert  <eggert@cs.ucla.edu>
21265
21266         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
21267         (get_date): Overparenthesize to avoid GCC warning.
21268
21269 2004-11-02  Bruno Haible  <bruno@clisp.org>
21270
21271         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
21272         returns void.
21273
21274 2004-11-02  Bruno Haible  <bruno@clisp.org>
21275
21276         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
21277         function returns void.
21278
21279 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21280
21281         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
21282         fflush_unlocked, flockfile, funlockfile, funlockfile,
21283         fputs_unlocked, putc_unlocked.
21284
21285 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21286
21287         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21288         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
21289         already declared.
21290
21291 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21292
21293         * modules/getdate (Files): Add doc/getdate.texi.
21294         (Depends-on): Add setenv, xalloc.
21295
21296 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21297
21298         * lib/getdate.y: Add support for TZ="foo" within a date string.
21299         Fix some bugs near time_t boundaries.  Reject dates with
21300         out-of-range components, e.g., "Sept 31".
21301         Include <stdlib.h>, "setenv.h", "xalloc.h".
21302         (ISDIGIT_LOCALE): Remove; unused.
21303         Note that the TZ and time functions used here are not reentrant.
21304         (mktime_ok, get_tz): New functions.
21305         (TZBUFSIZE): New constant.
21306         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
21307         This requires that we sometimes generate our own TZ="XXX..." setting.
21308
21309 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21310
21311         * doc/getdate.texi: New file, from coreutils with modifications for
21312         the new TZ parsing.
21313
21314 2004-10-27  Derek R. Price  <derek@ximbiot.com>
21315
21316         * lib/mktime.c (not_equal_tm): Remove redundant check.
21317
21318 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21319
21320         * modules/regex (lib_SOURCES): Add regex.c.
21321         Reported by James Youngman in
21322         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
21323
21324 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21325
21326         * lib/getdate.y: Use Bison 1.875 features, and some minor
21327         code cleanups.  This change does not affect semantics.
21328         Don't include <stdlib.h>; no longer needed.
21329         Don't include unlocked-io.h; only the "#if TEST" code uses
21330         stdio, and performance isn't crucial there.
21331         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
21332         Bison 1.875 features as described below.
21333         All uses of "PC." replaced by "pc->".
21334         (YYSTYPE): Add a forward declaration.
21335         (yylex, yyerror): Use full prototypes in forward decls.
21336         Use "%pure-parser" rather than obsolescent "%pure_parser".
21337         Use %parse-param and %lex-param instead of obsolescent
21338         YYPARSE_PARAM and YYLEX_PARAM.
21339         (meridian_table, month_and_day_table, time_units_table,
21340         relative_time_table, time_zone_table, military_table,
21341         lookup_zone, lookup_word, get_date):
21342         Use NULL instead of 0 where appropriate.
21343         (to_hour): Avoid abort (), to avoid a dependency on
21344         stdlib.h.
21345         (yyerror, yylex): Now accepts parser_control * arg.
21346         (main) [TEST]: Use '\0' rather than 0 for char.
21347
21348 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21349
21350         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
21351
21352 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21353
21354         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
21355         It's now the caller's responsibility to handle the case where
21356         !HAVE_GETPAGESIZE && !defined getpagesize.
21357
21358         * lib/mktime.c (leapyear): Arg is long int, not int.
21359
21360 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
21361
21362         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
21363
21364 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
21365
21366         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
21367         missing.  Problem reported by James Youngman.
21368
21369 2004-10-16  Simon Josefsson  <jas@extundo.com>
21370
21371         * gnulib-tool: Fix comments.  Fix parse problem.
21372         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
21373
21374 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
21375
21376         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
21377         implementation of getopt_long.  Problem reported by Alexander Taler in:
21378         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
21379
21380 2004-10-15  Bruno Haible  <bruno@clisp.org>
21381
21382         * gnulib-tool: Untabify. Initialize supplied_libname.
21383         (func_usage): More homogenous output.
21384         (func_modules_transitive_closure, func_modules_to_filelist,
21385         func_emit_lib_Makefile_am): New functions.
21386         (func_import): New function, extracted from big case statement. Use
21387         func_get_license, func_modules_transitive_closure,
21388         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
21389         opt_lgpl. Don't use test -a, as it's not portable.
21390         (func_create_testdir): Use func_modules_transitive_closure,
21391         func_modules_to_filelist, func_emit_lib_Makefile_am.
21392
21393 2004-10-15  Bruno Haible  <bruno@clisp.org>
21394
21395         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
21396
21397 2004-10-15  Bruno Haible  <bruno@clisp.org>
21398
21399         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
21400         the portions belonging to each module.
21401         Suggested by Derek Robert Price <derek@ximbiot.com>.
21402
21403 2004-10-12  Simon Josefsson  <jas@extundo.com>
21404
21405         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21406         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
21407         to real functions.
21408
21409 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21410
21411         * modules/vsnprintf: New file.
21412
21413 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21414
21415         * m4/vsnprintf.m4: New file.
21416
21417 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21418
21419         * lib/vsnprintf.h: New file.
21420         * lib/vsnprintf.c: New file.
21421
21422 2004-10-11  Bruno Haible  <bruno@clisp.org>
21423
21424         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
21425         vsnprintf.
21426
21427 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
21428
21429         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
21430
21431 2004-10-07  Bruno Haible  <bruno@clisp.org>
21432
21433         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
21434         fits into the provided buffer.
21435
21436 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
21437
21438         * lib/diacrit.c, diacrit.h: Add GPL notice.
21439
21440         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
21441         notice.
21442         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
21443         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
21444         This avoids a potential constant-folding bug.
21445
21446 2004-10-05  Bruno Haible  <bruno@clisp.org>
21447
21448         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
21449         for the declaration of strsep.
21450
21451 2004-10-05  Bruno Haible  <bruno@clisp.org>
21452
21453         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
21454
21455 2004-10-04  Simon Josefsson  <jas@extundo.com>
21456
21457         * modules/memmem: New file.
21458         * tests/test-memmem.c: New file.
21459         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
21460
21461 2004-10-04  Simon Josefsson  <jas@extundo.com>
21462
21463         * m4/memmem.m4: New file.
21464
21465 2004-10-04  Simon Josefsson  <jas@extundo.com>
21466
21467         * lib/memmem.h: New file.
21468         * lib/memmem.c: New file, taken from glibc.
21469
21470 2004-10-04  Simon Josefsson  <jas@extundo.com>
21471
21472         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
21473         '#ifdef USE_UNLOCKED_IO'.
21474
21475 2004-10-04  Simon Josefsson  <jas@extundo.com>
21476
21477         * config/srclist.txt: Add memmem from glibc.
21478
21479 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21480
21481         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
21482
21483         * modules/argmatch, modules/argp, modules/closeout, modules/error,
21484         modules/exclude, modules/getdate, modules/getline,
21485         modules/getndelim2, modules/getpass, modules/getpass-gnu,
21486         modules/getusershell, modules/linebuffer, modules/md5,
21487         modules/mountlist, modules/posixtm, modules/readtokens,
21488         modules/readutmp, modules/regex, modules/sha1,
21489         modules/version-etc, modules/yesno:
21490         Remove dependency on unlocked-io.
21491
21492 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21493
21494         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
21495
21496         * m4/unlocked-io.m4: Add copyright notice.
21497         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
21498
21499 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21500
21501         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
21502         * lib/xmalloc.c (xmemdup): Likewise.
21503         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
21504         XFREE): Remove these long-obsolescent macros.
21505         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
21506         * lib/xstrdup.c: Remove.
21507
21508         * lib/regex.c (re_comp): Cast gettext return value to char *,
21509         Problem reported by Martin Neitzel via Mark D. Baushke.
21510
21511 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21512
21513         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
21514         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
21515         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
21516         regex.c, sha1.c, version-etc.c, yesno.c:
21517         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
21518         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
21519         the includer's responsibility.
21520
21521         Sync from coreutils.
21522
21523         * lib/modechange.c (mode_compile): Don't decrement a pointer that
21524         points to the start of a string, as the C Standard says the
21525         resulting behavior is undefined.
21526
21527         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
21528         simple -> simple_backups, numbered_existing ->
21529         numbered_existing_backups, numbered -> numbered_backups
21530         to avoid shadowing problems.  All uses changed.
21531         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
21532         * lib/backupfile.c (check_extension, numbered_backup):
21533         Rename locals to avoid shadowing 'basename'.
21534         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
21535         once.
21536
21537         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
21538         * lib/.cvsignore: Add getopt.h.
21539
21540 2004-10-04  Bruno Haible  <bruno@clisp.org>
21541
21542         * modules/README: New file.
21543         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
21544         not a module.
21545
21546 2004-10-02  Jim Meyering  <jim@meyering.net>
21547
21548         * lib/dirfd.h, getpagesize.h: Add copyright notice.
21549
21550 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21551
21552         * modules/strsep: New file.
21553
21554 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21555
21556         * m4/strsep.m4: New file.
21557
21558 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21559
21560         * lib/strsep.h: New file.
21561         * lib/strsep.c: New file.
21562
21563 2004-10-01  Simon Josefsson  <jas@extundo.com>
21564
21565         * lib/snprintf.c (snprintf): Handle size==0.
21566
21567 2004-10-01  Simon Josefsson  <jas@extundo.com>
21568             Bruno Haible  <bruno@clisp.org>
21569
21570         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
21571         (snprintf): Declare 'args'.
21572
21573 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
21574
21575         * lib/snprintf.c: Remove comments as to why each header is needed.
21576
21577 2004-10-01  Bruno Haible  <bruno@clisp.org>
21578
21579         * MODULES.html.sh: Add strsep.
21580
21581 2004-09-30  Simon Josefsson  <jas@extundo.com>
21582
21583         * modules/snprintf: New file.
21584
21585 2004-09-30  Simon Josefsson  <jas@extundo.com>
21586
21587         * m4/snprintf.m4: New file.
21588
21589 2004-09-30  Simon Josefsson  <jas@extundo.com>
21590
21591         * lib/snprintf.h, lib/snprintf.c: New files.
21592
21593 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21594
21595         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
21596         (hol_entry_help): Never translate an empty string.
21597         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
21598         * lib/argp.h (OPTION_NO_TRANS): New option.
21599
21600 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
21601
21602         * modules/argp (Maintainer): Replace Simon Josefsson
21603         by Sergey Poznyakoff.
21604
21605 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
21606
21607         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
21608         changes merged back into glibc.
21609
21610 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
21611
21612         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
21613
21614 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
21615
21616         * lib/xvasprintf.c: Include xalloc.h.
21617         (xvasprintf): Use xalloc_die, not xmalloc_die.
21618
21619 2004-09-29  Bruno Haible  <bruno@clisp.org>
21620
21621         * modules/alloca-opt: New file, derived from modules/alloca.
21622         * modules/allocsa: Depend on alloca-opt instead of alloca.
21623         * modules/setenv: Likewise.
21624         * modules/vasnprintf: Likewise.
21625         * MODULES.html.sh: Add alloca-opt.
21626
21627 2004-09-28  Simon Josefsson  <jas@extundo.com>
21628
21629         * gnulib-tool: New parameter --lgpl, to asseert that modules are
21630         LGPL, and to replace license template from GPL to LGPL.
21631
21632 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
21633
21634         * modules/dummy: Change license to LGPL.
21635
21636 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
21637
21638         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
21639
21640 2004-09-24  Simon Josefsson  <jas@extundo.com>
21641
21642         * modules/minmax (License): Change from GPL to LGPL.
21643
21644 2004-09-23  Simon Josefsson  <jas@extundo.com>
21645
21646         * gnulib-tool (--import): Typo.
21647
21648 2004-09-23  Simon Josefsson  <jas@extundo.com>
21649
21650         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
21651
21652 2004-09-22  Bruno Haible  <bruno@clisp.org>
21653
21654         * modules/*: Add 'License' field.
21655         * gnulib-tool: Accept --extract-license option.
21656         (func_get_license): New function.
21657
21658 2004-09-21  Bruno Haible  <bruno@clisp.org>
21659
21660         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
21661         Reported by Simon Josefsson.
21662
21663 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
21664
21665         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
21666         gl_AC_TYPE_LONG_LONG.
21667
21668 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
21669
21670         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
21671
21672 2004-09-18  Simon Josefsson  <jas@extundo.com>
21673         and  Paul Eggert  <eggert@cs.ucla.edu>
21674
21675         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
21676         calls with autoreconf.  Define GL_LIB.
21677
21678 2004-09-14  Karl Berry  <karl@gnu.org>
21679
21680         * config/srclist.txt: unsync setenv.c, sigh.
21681
21682 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
21683
21684         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
21685         Problem reported by Bruno Haible in:
21686         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
21687
21688 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
21689
21690         * config/srclist.txt: Comment out argp-pvh.c.
21691
21692 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
21693
21694         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
21695         in case some system header has #define'd it.  Problem reported by
21696         Soeren D. Schulze in
21697         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
21698
21699 2004-09-09  Karl Berry  <karl@gnu.org>
21700
21701         * regex.[ch]: delete from the root.  These were supposed to be
21702                 synced with emacs cvs, but this has not happened for about
21703                 a year, and anyway nothing else uses emacs regex.[ch].
21704                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
21705                 lib/regex[.ch] is untouched.
21706
21707 2004-09-09  Bruno Haible  <bruno@clisp.org>
21708
21709         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
21710
21711 2004-09-09  Bruno Haible  <bruno@clisp.org>
21712
21713         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
21714         modifications.
21715         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
21716
21717 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
21718
21719         * modules/xvasprintf: New file.
21720         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
21721
21722 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
21723
21724         * lib/xvasprintf.h: New file.
21725         * lib/xvasprintf.c: New file.
21726         * lib/xasprintf.c: New file.
21727
21728 2004-09-08  Bruno Haible  <bruno@clisp.org>
21729
21730         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
21731
21732 2004-09-08  Bruno Haible  <bruno@clisp.org>
21733
21734         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
21735         length is > INT_MAX.
21736         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
21737         more.
21738
21739 2004-09-08  Bruno Haible  <bruno@clisp.org>
21740
21741         * lib/stdint_.h: New file, taken from GNU clisp.
21742
21743 2004-09-08  Bruno Haible  <bruno@clisp.org>
21744             Oskar Liljeblad  <oskar@osk.mine.nu>
21745
21746         * modules/stdint: New file.
21747         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
21748
21749 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
21750
21751         Import from coreutils.
21752         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
21753         strings on unbounded length.  alloca's performance benefits aren't
21754         that important here.
21755         (V_STRDUP): Remove.
21756         (parse_with_separator): New function, with most of the internals
21757         of the old parse_user_spec.  Allow user to omit both user and group,
21758         for compatibility with FreeBSD.
21759         Clone only the user name, not the entire spec.
21760         Do not set *uid, *gid unless entirely successful.
21761         Avoid memory leak in some failing cases.
21762         Fix regression for USER.GROUP reported by Dmitry V. Levin in
21763         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
21764         (parse_user_spec): Rewrite to use parse_with_separator.
21765
21766 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
21767
21768         * modules/userspec: Don't depend on alloca.
21769
21770 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
21771
21772         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
21773
21774 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
21775
21776         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
21777         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
21778         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
21779
21780 2004-08-16  Simon Josefsson  <jas@extundo.com>
21781
21782         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
21783         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
21784         Add --dry-run for --import.
21785         Let user provided command line parameters override configure.ac
21786         settings.
21787
21788 2004-08-12  Simon Josefsson  <jas@extundo.com>
21789
21790         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
21791         as discussed with Paul Eggert in threads rooted at
21792         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
21793         and
21794         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
21795         Before, the test was empty, and relied on ELIDE_CODE in source
21796         code.)
21797         (gl_PREREQ_GETOPT): New macro.
21798         (gl_GETOPT): Use them.
21799
21800 2004-08-12  Simon Josefsson  <jas@extundo.com>
21801
21802         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
21803         * lib/getopt_.h: Renamed from getopt.h.
21804
21805 2004-08-12  Simon Josefsson  <jas@extundo.com>
21806
21807         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
21808         Change default library name from libfoo to libgnu.
21809         Now, if you have a configure.ac that says:
21810                 gl_SOURCE_BASE(gl)
21811                 gl_M4_BASE(gl/m4)
21812                 gl_MODULES(error getopt etcetera)
21813                 gl_INIT
21814         you can import all you need by running:
21815                 ../gnulib/gnulib-tool --import
21816
21817         * modules/getopt (Files): Rename getopt.h to getopt_.h.
21818         (Makefile.am): Rewrite, use logic from argz.
21819         (Include): Use <getopt.h> instead of "getopt.h".
21820
21821 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21822
21823         * modules/argp (Files): Add m4/unlocked-io.m4.
21824         (Depends-on): Add extensions.
21825
21826 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21827
21828         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
21829         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
21830         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
21831         Check for program_invocation_name, program_invocation_short_name,
21832         flockfile, funlockfile, features.h, _getopt_long_only_r.
21833
21834 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21835
21836         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
21837         its complicated substitute.
21838         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
21839         and program_invocation_name.
21840         (__argp_basename) [!_LIBC]: Remove; the only use was
21841         replaced by its body.
21842         (__argp_short_program_name): Change condition from
21843         !defined __argp_short_program_name to
21844         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
21845         to match argp-namefrob.h.
21846         (__argp_failure): Don't assume strerror_r returns char *.
21847         * lib/argp-parse.c (N_): Define unconditionally.
21848         (argp_default_options): Fill out initializers with 0 to avoid
21849         gcc warnings.
21850
21851 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21852
21853         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
21854         getopt1.c.
21855
21856 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
21857
21858         Merge from coreutils.
21859
21860         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
21861
21862         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
21863         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
21864
21865 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
21866
21867         Merge from coreutils.
21868
21869         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
21870         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
21871         for Reliant Unix 5.43.
21872
21873         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
21874         (union fooround): Use uintmax_t, not long int.
21875         The rest is a merge from libc:
21876         [defined _LIBC]: Include <shlib-compat.h>.
21877         (_obstack) [defined _LIBC]: Remove after 2.3.4.
21878
21879         * lib/settime.c (settime): Recode to avoid warning with
21880         Sun Forte C 6U2.
21881
21882         * lib/strverscmp.c: Convert to UTF-8.
21883
21884 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
21885
21886         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
21887         m4/uintmax_t.m4.
21888
21889 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
21890
21891         * modules/xalloc-die: New file.
21892         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
21893
21894         * modules/md5 (Files): Add m4/uint32_t.m4.
21895         * modules/sha1: Renamed from modules/sha.
21896         (Files):
21897         Rename lib/sha.h to lib/sha1.h.
21898         Rename lib/sha.c to lib/sha1.c.
21899         Rename m4/sha.m4 to m4/sha1.m4.
21900         (lib_SOURCES): Likewise.
21901         (configure.ac): Rename gl_SHA to gl_SHA1.
21902         (Include): sha.h -> sha1.h.
21903
21904 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
21905
21906         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
21907         * m4/sha1.m4: Renamed from sha.m4.
21908         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
21909
21910 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
21911
21912         * lib/obstack.h (obstack_empty_p):
21913         Don't assume that chunk->contents is suitably aligned.
21914         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
21915         Likewise. Problem reported by Benno in
21916         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
21917
21918         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
21919         readable.  This could be improved further but it'd take some work.
21920
21921 2004-08-08  Simon Josefsson  <jas@extundo.com>
21922
21923         * modules/xgethostname (Depends-on): Remove exit and error (not
21924         used).
21925
21926         * modules/getpass-gnu: Add getpass.h.
21927         (Depends-on): Add stdbool.
21928         * modules/getpass: Add getpass.h.
21929
21930 2004-08-08  Simon Josefsson  <jas@extundo.com>
21931
21932         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
21933         Check getpass declaration.
21934
21935 2004-08-08  Simon Josefsson  <jas@extundo.com>
21936
21937         * lib/xgethostname.c: Don't include error.h (not used).
21938
21939         * lib/getpass.h: Add.
21940         * lib/getpass.c: Include getpass.h first.
21941
21942 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
21943
21944         * lib/xalloc-die.c: New file.
21945         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
21946         All uses removed.
21947         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
21948         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
21949         xalloc-die.c.
21950         (_, N_, xalloc_die): Move to xalloc-die.c.
21951         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
21952         so that we needn't mess with xalloc_msg_memory_exhausted.
21953
21954         * lib/sha1.h: Renamed from sha.h.
21955         (SHA1_H): Renamed from _SHA_H.
21956         (sha1_ctx): Renamed from sha_ctx.
21957         (sha1_init_ctx): Renamed from sha_init_ctx.
21958         (sha1_process_block): Renamed from sha_process_block.
21959         (sha1_process_bytes): Renamed from sha_process_bytes.
21960         (sha1_finish_ctx): Renamed from sha_finish_ctx.
21961         (sha1_read_ctx): Renamed from sha_read_ctx.
21962         (sha1_stream): Renamed from sha_stream.
21963         (sha1_buffer): Renamed from sha_buffer.
21964         * lib/sha1.c: Likewise; renamed from sha.c.
21965         Do not include <sys/types.h>.
21966         Include <stddef.h> rather than <stdlib.h>.
21967
21968 2004-08-08  Bruno Haible  <bruno@clisp.org>
21969
21970         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
21971         FILESYSTEM_PREFIX_LEN.
21972         * lib/progreloc.c: Likewise.
21973         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
21974
21975 2004-08-06  Simon Josefsson  <jas@extundo.com>
21976
21977         * modules/progname (Depends-on): Don't depend on stdbool.
21978
21979 2004-08-06  Simon Josefsson  <jas@extundo.com>
21980
21981         * modules/getsubopt: New file.
21982         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21983         getsubopt.
21984
21985 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
21986
21987         More merge from coreutils.
21988
21989         * m4/utimens.m4, m4/utimecmp.m4: New files.
21990         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
21991         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
21992         prereq.m4, sha.m4: Import changes from coreutils.
21993
21994 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
21995
21996         More merge from coreutils.
21997         * modules/raise, modules/readtokens0, modules/utimens:
21998         * modules/utimecmp, module/xnanosleep: New files.
21999         * modules/strftime: Add lib/strftime.h.
22000         Change include from <time.h> to "strftime.h".
22001         * modules/yesno: Add lib/yesno.h.
22002         * modules/backupfile: Remove lib/addext.c.
22003         * modules/euidaccess: Add stat-macros.h.
22004         * modules/canonicalize, modules/euidaccess,
22005         modules/filemode, modules/lchown, modules/makepath,
22006         modules/rmdir, modules/stat: Likewise.
22007
22008 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22009
22010         Merge from tar.
22011         * lib/argp-help.c (make_hol, hol_append): Don't assume that
22012         SIZE_MAX is a valid preprocessor constant.
22013         (__argp_basename): Change from "#ifndef _LIBC"
22014         to "#ifndef __argp_short_program_name", so that
22015         we don't compile these functions for tar.
22016
22017         More merges from coreutils.
22018         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
22019         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
22020         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
22021         * lib/addext.c: Remove; no longer needed.
22022         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
22023         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
22024         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
22025         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
22026         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
22027         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
22028         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
22029         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
22030         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
22031         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
22032         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
22033         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
22034         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
22035         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
22036         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
22037         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
22038         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
22039         Import changes from coreutils.
22040
22041 2004-08-05  Simon Josefsson  <jas@extundo.com>
22042
22043         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
22044
22045 2004-08-05  Simon Josefsson  <jas@extundo.com>
22046
22047         * m4/getsubopt.m4: New file.
22048
22049 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22050
22051         Merge from coreutils.
22052
22053         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
22054         * m4/getcwd-path-max.m4: New files.
22055
22056         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
22057         FILESYSTEM_PREFIX_LEN ->
22058         FILE_SYSTEM_PREFIX_LEN.
22059         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
22060         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
22061         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
22062         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
22063
22064         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
22065         prerequisite modules now handle the DOS stuff.
22066         Don't check for unistd.h.
22067
22068 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22069
22070         Merge from coreutils.
22071
22072         * lib/.gdb-history: Remove; this doesn't belong here.
22073
22074         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
22075         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
22076         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
22077         * lib/getcwd.c: New files.
22078
22079         * lib/dirname.h: Include <stdbool.h>.
22080         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
22081         for consistency with POSIX terminology.  All uses changed.
22082         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
22083         (strip_trailing_slashes): Use bool for booleans.
22084         * lib/stripslash.c (strip_trailing_slashes): Likewise.
22085
22086         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
22087         sometimes returns a positive errno value even when it succeeds.
22088         (print_errno_message) [!LIBC]: Fall back on strerror if
22089         __strerror_r fails.
22090
22091         * lib/path-concat.c (mempcpy): Don't define if a system header defines
22092         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
22093         (longest_relative_suffix): New function.
22094         (path_concat): Use it.  Assume first argument is not NULL.
22095         Port to DOS.  Omit redundant separators.
22096         Report an error instead of returning NULL.
22097         Use mempcpy instead of memcpy.
22098         (xpath_concat): Remove: not declared or used.
22099
22100         * lib/same.h: Include <stdbool.h>
22101         (same_name): Return bool, not int.
22102         * lib/same.c (same_name): Likewise.
22103         (errno): Don't declare; we assume C89 or better now.
22104
22105         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
22106         if not already defined.
22107
22108         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
22109         * lib/dup-safer.c (errno): Likewise.
22110
22111 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22112
22113         Merge from coreutils.
22114         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
22115         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
22116         * modules/path-concat: Don't depend on strdup.
22117
22118 2004-08-03  Simon Josefsson  <jas@extundo.com>
22119
22120         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
22121         * lib/progname.h: Don't include stdbool.h.
22122
22123 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22124
22125         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
22126         * MODULES.html.sh (func_all_modules): Remove fatal.
22127
22128 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22129
22130         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
22131
22132 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22133
22134         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
22135         working.
22136
22137 2004-08-02  Simon Josefsson  <jas@extundo.com>
22138
22139         * lib/getsubopt.h: New file, with comments from Bruno Haible.
22140         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
22141         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
22142
22143 2004-08-01  Simon Josefsson  <jas@extundo.com>
22144
22145         * lib/xgetdomainname.c: Include stdlib.h, for free().
22146
22147 2004-07-19  Bruno Haible  <bruno@clisp.org>
22148
22149         * MODULES.html.sh (func_all_modules): Add dummy.
22150
22151 2004-07-16  Simon Josefsson  <jas@extundo.com>
22152
22153         * modules/dummy: New file.
22154
22155 2004-07-16  Simon Josefsson  <jas@extundo.com>
22156
22157         * lib/dummy.c: New file.
22158
22159 2004-07-16  Bruno Haible  <bruno@clisp.org>
22160
22161         * lib/backupfile.h: Add extern "C" for C++.
22162         * lib/closeout.h: Likewise.
22163         * lib/copy-file.h: Likewise.
22164         * lib/findprog.h: Likewise.
22165         * lib/full-write.h: Likewise.
22166         * lib/pathname.h: Likewise.
22167         * lib/progname.h: Likewise.
22168         * lib/stpcpy.h: Likewise.
22169         * lib/stpncpy.h: Likewise.
22170         * lib/strcase.h: Likewise.
22171         * lib/strstr.h: Likewise.
22172         * lib/xalloc.h: Likewise.
22173
22174         * lib/mbswidth.h: Add extern "C" for C++.
22175         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
22176
22177 2004-07-13  Robert Millan  <robertmh@gnu.org>
22178
22179         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
22180
22181 2004-07-09  Simon Josefsson  <jas@extundo.com>
22182
22183         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
22184         failed without this.)
22185
22186 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22187
22188         * modules/chown (Files): Add lib/fchown-stub.c, since
22189         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
22190
22191 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22192
22193         * lib/fchown-stub.c: New file.
22194
22195 2004-06-24  Jim Meyering  <jim@meyering.net>
22196
22197         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
22198
22199 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22200
22201         * modules/argz: Omit "#include".
22202
22203         * MODULES.html.sh (func_all_modules): Add calloc, to match
22204         2004-06-01 addition of calloc module.
22205
22206 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22207
22208         * m4/argz.m4: New file, which is autoupdated from libtool.
22209
22210 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22211
22212         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
22213         libtool.
22214
22215 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22216
22217         * config/srclist-update: Don't insist on "USA." before the
22218         close-comment, as libtool omits the period and puts the */ on a
22219         separate line.
22220         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
22221         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
22222
22223 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
22224
22225         * modules/argz: New file.
22226         * MODULES.html.sh (func_all_modules): Add argz.
22227
22228 2004-06-12  Jim Meyering  <jim@meyering.net>
22229         and  Paul Eggert  <eggert@cs.ucla.edu>
22230
22231         * modules/hash (Files): Add lib/xalloc.h.
22232         * modules/pipe (Depends-on): Add wait-process.
22233         * modules/stat (Depends-on): Add xalloc.
22234         * modules/userspec (Files): Add lib/userspec.h.
22235         * modules/xstrto
22236
22237         Upgrade from gettext-0.13.
22238         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
22239         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
22240         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
22241
22242 2004-06-10  Jim Meyering  <jim@meyering.net>
22243
22244         * lib/calloc.c: New file.
22245
22246 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
22247
22248         * lib/getdate.y (yylex): Allow space between sign and number.
22249         Problem reported by Dan Jacobson.
22250
22251 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22252
22253         Merge from coreutils CVS.
22254
22255         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
22256         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
22257         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
22258         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
22259         xstrtol.m4: Fix copyright date and/or serial number.
22260
22261         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
22262         See if we need an fchown replacement.
22263         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
22264         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
22265         and use the replacement function if we detect either defect.
22266
22267         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
22268         gl_UTIMECMP.
22269
22270 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22271         and  Jim Meyering  <jim@meyering.net>
22272
22273         Merge from coreutils CVS.
22274
22275         * lib/stat-macros.h: New file, with contents from file-type.h
22276         and coreutils' system.h.
22277         * lib/file-type.c: Include "stat-macros.h".
22278         * lib/file-type.h (file_type): Move all macro definitions to new file,
22279         stat-macros.h.
22280
22281         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
22282         Wrap old code with this conditional.
22283         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
22284         function that does not dereference symlinks.
22285         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
22286
22287         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
22288         dependency problems.
22289         (xreadlink): Accept new arg SIZE, for efficiency.
22290         All decls and uses changed.
22291         * lib/xreadlink.h: Include <stddef.h>, for size_t.
22292
22293         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
22294         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
22295
22296         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
22297         sysexits.h.
22298
22299 2004-06-01  Jim Meyering  <jim@meyering.net>
22300
22301         * m4/calloc.m4: New file.
22302
22303 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
22304
22305         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
22306         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
22307         Also, fix a typo in a diagnostic.
22308
22309 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22310
22311         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
22312         or AC_FUNC_REALLOC.
22313
22314 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22315
22316         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
22317         macros to be defined.
22318         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
22319         the allocator returns NULL because the requested size is zero.
22320
22321 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
22322
22323         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
22324         var.  Add comment explaining why libc still defines it.  This
22325         merges the following patch from glibc:
22326         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
22327
22328 2004-05-20  Andreas Schwab  <schwab@suse.de>
22329
22330         * m4/free.m4: Replace free if it not known to work, not the other
22331         way round.
22332
22333 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
22334
22335         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
22336         present in glibc since revision 1.1 of this file.
22337         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
22338         obstack_alignment_mask, obstack_alloc, obstack_base,
22339         obstack_blank, obstack_blank_fast, obstack_chunk_size,
22340         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
22341         obstack_grow0, obstack_init, obstack_int_grow,
22342         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
22343         obstack_next_free, obstack_object_size, obstack_ptr_grow,
22344         obstack_ptr_grow_fast, obstack_room): Remove declarations of
22345         nonexistent functions.
22346
22347 2004-05-18  Karl Berry  <karl@gnu.org>
22348
22349         * config/srclist.txt: break link for vasnprintf.c.
22350
22351 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22352
22353         Port obstack to the AS/400, where pointers are 16 bytes wide and
22354         you cannot cast an integer to a valid pointer.  This patch is
22355         currently waiting to be integrated into glibc; see
22356         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
22357
22358         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
22359         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
22360         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
22361         (struct obstack): temp member is now a union of a pointer and
22362         an integer, instead of an integer.  All integer uses changed.
22363         This does not affect the physical layout of struct obstack,
22364         except on hosts (like the AS/400) where the size or alignment of
22365         void * is greater than that of ptrdiff_t.
22366         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
22367         __STDC__)]: Store temporary in pointer member of union, not
22368         integer member.
22369         * lib/obstack.c: Include <stddef.h>, for offsetof.
22370         (struct fooalign): Remove; it doesn't need a name.
22371         (union fooround): Change double to long double, and add void *.
22372         (DEFAULT_ALIGNMENT): Use offsetof to compute.
22373         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
22374         not a macro.  Hence the values are always int; so remove all
22375         casts-to-int in uses.
22376
22377 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22378
22379         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
22380         we can get this patch merged into glibc.
22381
22382 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22383             Paul Eggert  <eggert@cs.ucla.edu>
22384
22385         * m4/argp: Depend on alloca.
22386
22387 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22388             Paul Eggert  <eggert@cs.ucla.edu>
22389
22390         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
22391         freecoding.
22392
22393 2004-05-17  Bruno Haible  <bruno@clisp.org>
22394
22395         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
22396         precision that consists of a '.' followed by an empty digit string.
22397         Patch by Tor Lillqvist <tml@iki.fi>.
22398
22399 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22400
22401         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
22402         for backward compatibility with older code.  We need our own
22403         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
22404         it under some other name, and our alloca.h will define it.
22405
22406 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22407             Derek Price  <derek@ximbiot.com>
22408
22409         * lib/alloca.c: Include <alloca.h>, to get our interface.
22410         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
22411         include <alloca.h> first.  Use C89 prototype for alloca; this
22412         requires including <stddef.h> for size_t.  Use extern "C" if C++.
22413         Use #elif for simplicity, since we can assume C89 now.
22414         Don't try to source the system alloca.h since it will not be found
22415         and to prevent recursively including its replacement.
22416         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
22417         * lib/regex.c: Likewise.
22418
22419 2004-05-16  Derek Price  <derek@ximbiot.com>
22420             Paul Eggert  <eggert@cs.ucla.edu>
22421
22422         getline cleanup.  This changes the getndelim2 API: both order of
22423         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
22424         no delimiter).
22425
22426         * lib/getline.c: Don't include stddef.h or stdio.h, since our
22427         interface does that.
22428         (getline): Always use getdelim, so that we don't have two
22429         copies of this code.
22430         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
22431         if available.
22432         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
22433         (GETNDELIM2_MAXIMUM): New macro.
22434         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
22435         instead of the old practice of delim2==0.  All callers changed.
22436         Return -1 on overflow, instead of returning junk.
22437         Do not set *linesize unless allocation succeeds.
22438         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
22439         that we include sys/types.h.
22440         * lib/getnline.h: Likewise.
22441         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
22442         (getndelim2): Reorder arguments.
22443         * lib/getnline.c (getnline, getndelim):
22444         Don't discard the NMAX argument.
22445         (getnline): Invoke getndelim, to avoid code duplication.
22446         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
22447         of (size_t) -1 by callers of the getnline family.
22448
22449 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22450
22451         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
22452         Check for gettimeofday.
22453         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
22454         Check for settimeofday, stime.
22455
22456 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22457
22458         * lib/nanosleep.c (suspended): Change its type from int to
22459         sig_atomic_t volatile.
22460         (first_call): Make it private to rpl_nanosleep, and have it
22461         be zero initially as that's a bit faster.
22462         (my_usleep): Round up fractional times instead of truncating them,
22463         as this is the usual meaning for 'sleep'.
22464
22465         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
22466         doesn't work.
22467         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
22468         (ENOSYS): Define if not defined.
22469         (settime): Fall back on stime if it exists and settimeofday fails.
22470         But don't bother with fallbacks if a method fails with errno == EPERM.
22471
22472 2004-05-11  Jim Meyering  <jim@meyering.net>
22473
22474         Prior to this change, the save_cwd caller required read access to the
22475         current directory on most systems (ones with the fchdir function).
22476
22477         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
22478         fails, try write-only, and finally, resort to using xgetcwd.
22479
22480 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
22481
22482         * lib/obstack.c, obstack.h: Import changes from libc.
22483
22484 2004-04-28  Bruno Haible  <bruno@clisp.org>
22485
22486         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
22487         also implicitly appends .exe to executables.
22488         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
22489         accepts Windows pathnames.
22490         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22491         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22492         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22493         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22494         Reported by Derek Robert Price <derek@ximbiot.com>.
22495
22496 2004-04-21  Karl Berry  <karl@gnu.org>
22497
22498         * config/srclist.txt (localcharset.c): break sync.
22499
22500 2004-04-20  Paul Eggert  <eggert@twinsun.com>
22501
22502         * m4/host-os.m4: Add a copyright notice.
22503
22504 2004-04-20  Jim Meyering  <jim@meyering.net>
22505
22506         Change UTILS_ to gl_ in AC_DEFINE'd names.
22507         Change utils_- and jm_-prefixed variables, too.
22508         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
22509         UTILS_FUNC_MKDIR_TRAILING_SLASH.
22510         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
22511
22512         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
22513         Don't emit trailing blanks.
22514         Also rename jm_-prefixed variables to have gl_ prefix.
22515
22516         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
22517         Also rename jm_-prefixed variables to have gl_ prefix.
22518
22519         * m4/jm-macros.m4: Reflect the renamings.
22520         * m4/prereq.m4: Likewise.
22521
22522 2004-04-20  Jim Meyering  <jim@meyering.net>
22523
22524         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
22525         memory.
22526
22527 2004-04-20  Jim Meyering  <jim@meyering.net>
22528             Bruno Haible  <bruno@clisp.org>
22529
22530         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
22531         memory when realloc fails.
22532
22533 2004-04-19  Jim Meyering  <jim@meyering.net>
22534
22535         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
22536         now that readutmp.c may call `free (0)'.
22537
22538 2004-04-19  Bruno Haible  <bruno@clisp.org>
22539
22540         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
22541         * m4/inttypes_h.m4: Likewise.
22542         * m4/stdint_h.m4: Likewise.
22543         * m4/intmax_t.m4: Likewise.
22544         * m4/uintmax_t.m4: Likewise.
22545
22546 2004-04-18  Jim Meyering  <jim@meyering.net>
22547
22548         * m4/prereq.m4: Don't forbid jm_ prefix.
22549
22550         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
22551         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
22552         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
22553         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
22554         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
22555         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
22556         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
22557         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
22558         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
22559         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
22560         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
22561         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
22562         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
22563         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
22564         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
22565         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
22566         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
22567         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
22568         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
22569
22570 2004-04-18  Jim Meyering  <jim@meyering.net>
22571
22572         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
22573         failure, don't leak memory and do call END_UTMP_ENT.
22574
22575 2004-04-16  Jim Meyering  <jim@meyering.net>
22576
22577         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
22578         coreutils' stat program.
22579         (gl_PREREQ): Don't require jm_PREREQ_STAT.
22580
22581 2004-04-11  Paul Eggert  <eggert@twinsun.com>
22582
22583         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
22584         C89.
22585         (CHAR_BIT): Remove, since we assume C89.
22586         Include <stdint.h> if available, as per current Autoconf CVS advice.
22587
22588 2004-03-31  Jim Meyering  <jim@meyering.net>
22589
22590         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
22591         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
22592         * m4/xalloc.m4: Likewise.
22593
22594 2004-03-30  Paul Eggert  <eggert@twinsun.com>
22595
22596         Merge from coreutils.
22597
22598         * m4/inttostr.m4: New file.
22599         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
22600         Require AM_STDBOOL_H and gl_TIMESPEC instead.
22601         Require gl_CLOCK_TIME.
22602         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
22603
22604 2004-03-30  Paul Eggert  <eggert@twinsun.com>
22605
22606         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
22607         not bool, to be more consistent with Unix conventions.
22608         Suggested by Bruno Haible.
22609
22610         Merge from coreutils.
22611
22612         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
22613         * lib/umaxtostr.c: New files.
22614
22615         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
22616         the usual <time.h> dance.
22617         (get_date): Change signature to support fractional time stamps.
22618         All callers changed.
22619         * lib/getdate.y: Include "getdate.h" first, as we can now
22620         assume C89 and don't need to worry about 'const'.
22621         Similarly, include "unlocked-io.h" near start, not in middle.
22622         Include <limits.h>.
22623         (textint.value): Use long int rather than int.
22624         (textint.digits): Use size_t rather than int.
22625         (BILLION, LOG10_BILLION): New constants.
22626         (parser_control): New member rel_ns.  Members day_ordinal,
22627         time_zone, month, day, hour, minutes, rel_year, rel_month,
22628         rel_day, rel_hour, rel_minutes, rel_seconds
22629         are now long int, not int.  Member seconds is now struct timespec,
22630         not int.  New member timespec_seen.  Members dates_seen, days_seen,
22631         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
22632         not int.
22633         (%union.intval): Now long int, not int.
22634         New member timespec.
22635         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
22636         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
22637         (spec): Now is a timespec or an item list.
22638         (timespec, items): New nonterminals.
22639         (time, rel, relunit, number, get_date):
22640         Add support for fractional seconds.
22641         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
22642         (gmtime, localtime, mktime): Remove decls; not needed with C89.
22643         (to_hour): First arg is now long int, not int.
22644         (to_year): Returns long int, not int.
22645         Don't treat year -70 like 70.
22646         (tm_diff): Returns long int, not int.
22647         (lookup_word): Use bool instead of int when appropriate.
22648         (yylex): Use size_t for count, not int.
22649         Detect overflow when parsing large integer constants.
22650         Add support for fractions.
22651         (get_date): Make pointers 'const' if possible.
22652         Use more-portable code to detect integer overflow.
22653         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
22654         Don't use ctime; it's not reliable if the year has >4 digits.
22655
22656         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
22657         This is for compatibility with BSD.
22658
22659         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
22660         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
22661         From coreutils' system.h.
22662
22663         * lib/userspec.c: Don't include "posixver.h".
22664         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
22665         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
22666         compatible extension.  Simplify code by removing a boolean int
22667         that was always nonzero if a string was nonnull.
22668
22669 2004-03-30  Jim Meyering  <jim@meyering.net>
22670
22671         Merge from coreutils.
22672
22673         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
22674         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
22675         on some systems one must include <grp.h> before it.
22676         Reported by Christian Krackowizer.
22677
22678 2004-03-30  Jim Meyering  <jim@meyering.net>
22679
22680         Merge from coreutils.
22681
22682         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
22683
22684         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
22685         an empty input stream.
22686
22687         * lib/readtokens.c: Include <stdbool.h>.
22688         (readtoken): Use `size_t' rather than int/long.
22689         All callers adjusted.
22690         Use `bool' rather than `int' where appropriate.
22691         Use memset rather than an explicit loop.
22692         Use x2nrealloc rather than xrealloc.
22693         Allow the use of `\0' as a delimiter.
22694         (readtokens): Likewise.
22695         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
22696
22697 2004-03-30  Jim Meyering  <jim@meyering.net>
22698
22699         * m4/realloc.m4: Remove file, since now it does no more than
22700         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
22701         the `configure.ac' section of module/realloc.
22702         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
22703
22704 2004-03-30  Bruno Haible  <bruno@clisp.org>
22705
22706         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
22707         nonnull.
22708
22709 2004-03-29  Paul Eggert  <eggert@twinsun.com>
22710
22711         Merge changes to getloadavg.c from coreutils and Emacs.
22712
22713         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
22714         Define to an expression, not to the empty string.
22715         Include cloexec.h and xalloc.h.
22716         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
22717         Use set_cloexec_flag rather than rolling our own.
22718         * lib/cloexec.c, lib/cloexec.h: New files.
22719
22720 2004-03-29  Paul Eggert  <eggert@twinsun.com>
22721
22722         * m4/cloexec.m4: New file.
22723
22724 2004-03-18  Paul Eggert  <eggert@twinsun.com>
22725
22726         * lib/getopt.h: Sync with libc CVS.
22727
22728 2004-03-18  Paul Eggert  <eggert@twinsun.com>
22729             Bruno Haible  <bruno@clisp.org>
22730
22731         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
22732         mbswidth.
22733
22734 2004-03-18  Paul Eggert  <eggert@twinsun.com>
22735             Bruno Haible  <bruno@clisp.org>
22736
22737         * lib/mbswidth.h: Include <wchar.h> only if
22738         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
22739         <wchar.h>.
22740         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
22741
22742 2004-03-09  Paul Eggert  <eggert@twinsun.com>
22743
22744         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
22745         Sync with libc CVS.
22746         * lib/getopt_int.h: New file, also synced from libc.
22747
22748 2004-03-09  Paul Eggert  <eggert@twinsun.com>
22749
22750         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
22751         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
22752         Bring back getopt.c, getopt.h, getopt1.c.
22753
22754 2004-03-07  Paul Eggert  <eggert@twinsun.com>
22755
22756         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
22757         All uses changed.  Check for sa_sigaction member; this fixes
22758         a bug first reported by Jason Andrade in
22759         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
22760
22761 2004-03-07  Paul Eggert  <eggert@twinsun.com>
22762
22763         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
22764         '#if' expressions.  Unlike the code it replaces, it does not
22765         depend on (defined _SC_PAGESIZE).  However, it does depend on
22766         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
22767         first reported by Jason Andrade in
22768         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
22769
22770 2004-02-25  Simon Josefsson  <jas@extundo.com>
22771
22772         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
22773
22774 2004-02-25  Simon Josefsson  <jas@extundo.com>
22775
22776         * lib/strdup.h: New file.
22777         * lib/strdup.c: Include it.
22778         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
22779         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
22780
22781 2004-02-23  Karl Berry  <karl@gnu.org>
22782
22783         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
22784         (from fencepost.gnu.org:/gd/gnuorg).
22785
22786 2004-02-23  Karl Berry  <karl@gnu.org>
22787
22788         * config/srclistvars.sh (GNUORG) [karl]: redefine.
22789         * config/srclist.txt: add maintain/standards documents.
22790
22791 2004-02-18  Bruno Haible  <bruno@clisp.org>
22792
22793         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
22794         Reported by Derek Robert Price <derek@ximbiot.com>.
22795
22796 2004-02-16  Karl Berry  <karl@gnu.org>
22797
22798         * config/mkinstalldirs, install-sh: update from automake.
22799
22800 2004-02-06  Karl Berry  <karl@gnu.org>
22801
22802         * m4/po.m4: update from gettext 0.14.1.
22803
22804 2004-02-06  Karl Berry  <karl@gnu.org>
22805
22806         * lib/config.charset: update from gettext 0.14.1.
22807
22808 2004-02-05  Paul Eggert  <eggert@twinsun.com>
22809
22810         Add comments and code, prompted by suggestions from Bruno Haible
22811         for sh-quote.
22812         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
22813         describing the enum quoting_style values.
22814         * lib/quotearg.c (quotearg_alloc): New function.
22815         (quotearg_buffer_restyled): Treat lone { and } as special.
22816         Treat = as special.  Work around bug with older shells
22817         that "see" a '\' that is really the 2nd byte of a multibyte char.
22818         Quote empty string with shell_quoting_style.
22819
22820 2004-02-03  Bruno Haible  <bruno@clisp.org>
22821
22822         * m4/pipe.m4: New file, from GNU gettext.
22823
22824 2004-02-03  Bruno Haible  <bruno@clisp.org>
22825
22826         * lib/pipe.h: New file, from GNU gettext.
22827         * lib/pipe.c: New file, from GNU gettext.
22828
22829 2004-01-27  Bruno Haible  <bruno@clisp.org>
22830
22831         * m4/execute.m4: New file, from GNU gettext.
22832
22833 2004-01-27  Bruno Haible  <bruno@clisp.org>
22834
22835         * lib/execute.h: New file, from GNU gettext.
22836         * lib/execute.c: New file, from GNU gettext.
22837         * lib/w32spawn.h: New file, from GNU gettext.
22838
22839 2004-01-24  Paul Eggert  <eggert@twinsun.com>
22840
22841         Merge from diffutils.
22842
22843         * lib/file-type.c (file_type): Add typed memory objects.
22844         * lib/file-type.h (S_TYPEISTMO): New macro.
22845
22846         * lib/c-stack.h (c_stack_action): Remove argv argument.
22847         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
22848         (die): Don't calculate message unless segv_action returns.
22849         (get_stack_location, min_address_from_argv, max_address_from_argv,
22850         volatile stack_base, volatile_stack_size): Remove.
22851         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
22852         that every segmentation violation is a stack overflow.  (Ouch!)
22853         See Debian bug 136249 (still outstanding) for more info about why
22854         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
22855
22856 2004-01-24  Paul Eggert  <eggert@twinsun.com>
22857
22858         Exit-status fix from coreutils.
22859
22860         Use exit_failure consistently in place of EXIT_FAILURE,
22861         so that program exit statuses are consistent on failure.
22862
22863         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
22864         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
22865         * lib/argmatch.h: Comment fix to match the above.
22866         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
22867         Now a macro referring to exit_failure, instead of a separate
22868         variable.  Include "exitfail.h" to get it.
22869         * lib/xstrtol.h: Include "exitfail.h".
22870         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
22871
22872         * lib/long-options.c (parse_long_options): Use prototype
22873         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
22874         for clarity.
22875
22876 2004-01-21  Jim Meyering  <jim@meyering.net>
22877
22878         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
22879         so as not to conflict with a different-sized __mktime_internal
22880         function in GNU libc.
22881         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
22882         Problem building statically-linked `ls' reported by Michael Brunnbauer.
22883
22884 2004-01-20  Karl Berry  <karl@gnu.org>
22885
22886         * config/config.guess: update from config.
22887
22888         * config/srclistvars.sh: GNUWWWLICENSES for karl.
22889
22890 2004-01-20  Bruno Haible  <bruno@clisp.org>
22891
22892         Safer stack allocation.
22893         * lib/setenv.c: Include allocsa.h.
22894         (alloca): Remove fallback definition.
22895         (freea): Remove macro.
22896         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
22897         instead of freea.
22898
22899 2004-01-20  Bruno Haible  <bruno@clisp.org>
22900
22901         * m4/eealloc.m4: New file, from GNU gettext.
22902
22903 2004-01-20  Bruno Haible  <bruno@clisp.org>
22904
22905         * m4/allocsa.m4: New file, from GNU gettext.
22906
22907 2004-01-20  Bruno Haible  <bruno@clisp.org>
22908
22909         * lib/xallocsa.h: New file, from GNU gettext.
22910         * lib/xallocsa.c: New file, from GNU gettext.
22911
22912 2004-01-20  Bruno Haible  <bruno@clisp.org>
22913
22914         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
22915
22916 2004-01-20  Bruno Haible  <bruno@clisp.org>
22917
22918         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
22919         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
22920         specially.
22921
22922 2004-01-20  Bruno Haible  <bruno@clisp.org>
22923
22924         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
22925         patch.
22926
22927 2004-01-20  Bruno Haible  <bruno@clisp.org>
22928
22929         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
22930
22931 2004-01-20  Bruno Haible  <bruno@clisp.org>
22932
22933         * lib/eealloc.h: New file.
22934
22935 2004-01-20  Bruno Haible  <bruno@clisp.org>
22936
22937         * lib/binary-io.h: Avoid warnings on Cygwin.
22938
22939 2004-01-20  Bruno Haible  <bruno@clisp.org>
22940
22941         * lib/allocsa.h: New file, from GNU gettext.
22942         * lib/allocsa.c: New file, from GNU gettext.
22943
22944 2004-01-18  Karl Berry  <karl@gnu.org>
22945
22946         * doc/gpl.texi, doc/lgpl.texi: new files.
22947
22948 2004-01-18  Karl Berry  <karl@gnu.org>
22949
22950         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
22951         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
22952
22953 2004-01-15  Paul Eggert  <eggert@twinsun.com>
22954
22955         Merge from coreutils.
22956
22957         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
22958         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
22959         (gl_DEFAULT_POSIX2_VERSION): Move
22960         the documentation from 'configure' into 'config.hin',
22961         so that 'configure --help' isn't burdened by it and
22962         we don't have to worry about its formatting there.
22963         Reword the documentation so that it's more succinct
22964         and can be run together into a single paragraph.
22965         * m4/same.m4 (gl_SAME): Check for pathconf.
22966
22967 2004-01-15  Paul Eggert  <eggert@twinsun.com>
22968
22969         Merge from coreutils.
22970
22971         * lib/posixver.c: Include posixver.h.
22972
22973         * lib/same.c: Include <stdbool.h>, <limits.h>.
22974         (_POSIX_NAME_MAX): Define if not defined.
22975         (MIN): New macro.
22976         (same_name): If file names are silently truncated, report
22977         that the file names are the same if they are the same after
22978         the silent truncation.
22979
22980         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
22981         conversion function.
22982         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
22983         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
22984         longer needed.
22985
22986 2004-01-15  Jim Meyering  <jim@meyering.net>
22987
22988         Merge from coreutils.
22989
22990         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
22991         if no library is required.
22992         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
22993         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
22994         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
22995         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
22996         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
22997         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
22998         value, $ac_cv_search_crypt, if it's "none required".
22999         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
23000         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
23001         not gl_FUNC_GETLOADAVG.
23002         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
23003         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
23004
23005 2004-01-15  Jim Meyering  <jim@meyering.net>
23006
23007         Merge from coreutils.
23008
23009         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
23010         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
23011         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
23012
23013         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
23014         optional configure-time default.
23015
23016         * lib/version-etc.c (version_etc_copyright): Update copyright date.
23017
23018         * lib/xreadlink.c (xreadlink): Correct outdated comment.
23019
23020 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
23021
23022         Merge from coreutils.
23023
23024         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
23025         value, $ac_cv_search_nanosleep, if it's "none required".
23026
23027 2004-01-14  Paul Eggert  <eggert@twinsun.com>
23028
23029         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
23030         with like-named macro in fnmatch.c.
23031         (EXT): Use an internal constant instead.
23032
23033         Merge fnmatch patches from glibc.
23034         * lib/fnmatch.c (mbsinit): Remove define.
23035         Add libc_hidden_ver (__fnmatch, fnmatch).
23036         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
23037         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
23038
23039 2004-01-14  Karl Berry  <karl@gnu.org>
23040
23041         * config/install-sh: update from automake.
23042
23043 2004-01-13  Karl Berry  <karl@gnu.org>
23044
23045         * config/install-sh: update from automake.
23046
23047 2004-01-09  Karl Berry  <karl@gnu.org>
23048
23049         * config/install-sh: update from automake.
23050
23051 2004-01-05  Karl Berry  <karl@gnu.org>
23052
23053         * config/config.{sub,guess}: update from config.
23054
23055 2003-12-31  Karl Berry  <karl@gnu.org>
23056
23057         * config/depcomp: update from automake.
23058
23059 2003-12-14  Karl Berry  <karl@gnu.org>
23060
23061         * lib/config.charset: update from gettext-runtime.
23062
23063 2003-12-03  Paul Eggert  <eggert@twinsun.com>
23064
23065         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
23066         Bug reported by Alfred M. Szmidt.
23067
23068 2003-12-03  Bruno Haible  <bruno@clisp.org>
23069
23070         * m4/gettext.m4: Upgrade from gettext-0.13.
23071         * m4/po.m4: Upgrade from gettext-0.13.
23072         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
23073         * m4/intmax.m4: New file, from gettext-0.13.
23074         * m4/printf-posix.m4: New file, from gettext-0.13.
23075
23076 2003-11-29  Karl Berry  <karl@gnu.org>
23077
23078         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
23079
23080 2003-11-25  Paul Eggert  <eggert@twinsun.com>
23081             Bruno Haible  <bruno@clisp.org>
23082
23083         * lib/printf-parse.h: Don't include sys/types.h.
23084         (ARG_NONE): New macro.
23085         (char_directive): Change type of *arg_index fields to size_t.
23086         * lib/printf-parse.c: Don't include sys/types.h.
23087         (SSIZE_MAX): Remove macro.
23088         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
23089         Remove unnecessary overflow check.
23090         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
23091         fields.
23092
23093 2003-11-25  Bruno Haible  <bruno@clisp.org>
23094
23095         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
23096
23097 2003-11-25  Bruno Haible  <bruno@clisp.org>
23098
23099         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
23100         gt_TYPE_SSIZE_T.
23101
23102 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23103
23104         * modules/alloca: Remove dependency on xalloc.
23105
23106 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23107
23108         * lib/alloca.c: Remove dependency on xalloc module.
23109         (xalloc_die): Remove.
23110         (memory_full) [!defined emacs]: New macro.
23111         [!defined emacs]: Don't include xalloc.h.
23112         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
23113         address arithmetic overflows.  Change datatypes a bit to avoid
23114         unnecessary casts.
23115
23116 2003-11-22  Jim Meyering  <jim@meyering.net>
23117
23118         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
23119         s/size/size_t/.
23120
23121 2003-11-21  Karl Berry  <karl@gnu.org>
23122
23123         * config/config.{sub,guess}: update from config.
23124
23125 2003-11-18  Karl Berry  <karl@gnu.org>
23126
23127         * config/config.{sub,guess}: update from config.
23128
23129         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
23130
23131 2003-11-17  Paul Eggert  <eggert@twinsun.com>
23132
23133         * README: Mention that S+T cannot overflow if S is the size of
23134         an existing object and T is sufficiently small.
23135
23136 2003-11-17  Jim Meyering  <jim@meyering.net>
23137
23138         On systems without utime and without a utimes function capable of
23139         dealing with a NULL struct utimbuf* argument, this utime replacement
23140         could -- in unusual circumstances -- leak a file descriptor.
23141         * lib/utime.c: Include <unistd.h> and <errno.h>.
23142         (utime_null): Be sure to close `fd' and to preserve errno.
23143         Reported by Geoff Collyer via Arnold Robbins.
23144
23145 2003-11-17  Bruno Haible  <bruno@clisp.org>
23146
23147         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
23148         (Depends-on): Add xsize.
23149
23150 2003-11-17  Bruno Haible  <bruno@clisp.org>
23151
23152         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
23153
23154 2003-11-17  Bruno Haible  <bruno@clisp.org>
23155
23156         * lib/vasnprintf.c (alloca): Remove fallback definition.
23157         (freea): Remove definition.
23158         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
23159         Reported by Paul Eggert.
23160
23161 2003-11-16  Paul Eggert  <eggert@twinsun.com>
23162             Bruno Haible  <bruno@clisp.org>
23163
23164         Protect against address arithmetic overflow.
23165         * lib/printf-args.h: Include stddef.h.
23166         (arguments): Change type of field 'count' to size_t.
23167         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
23168         'unsigned int' where appropriate.
23169         * lib/printf-parse.h: Include sys/types.h.
23170         (char_directive): Change type of *arg_index fields to ssize_t.
23171         (char_directives): Change type of fields 'count', max_*_length to
23172         size_t.
23173         * lib/printf-parse.c: Include sys/types.h and xsize.h.
23174         (SSIZE_MAX): Define fallback value.
23175         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
23176         instead of 'int' where appropriate. Check a_allocated, d_allocated
23177         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
23178         * lib/vasnprintf.c: Include xsize.h.
23179         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
23180         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
23181         overflow. Avoid wraparound when converting a width or precision from
23182         decimal to binary.
23183
23184 2003-11-16  Bruno Haible  <bruno@clisp.org>
23185
23186         Update from GNU gettext.
23187         * lib/printf-parse.c: Generalize to it can be compiled for wide
23188         strings.
23189         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
23190         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
23191         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
23192         SNPRINTF): New macros.
23193         Don't include <alloca.h> if the file is used inside libintl.
23194         (local_wcslen): New function, for Solaris 2.5.1.
23195         (VASNPRINTF): Use it instead of wcslen.
23196
23197 2003-11-16  Bruno Haible  <bruno@clisp.org>
23198
23199         * lib/xsize.h (xmax): New function.
23200         (xsum, xsum3, xsum4): Declare as "pure" functions.
23201
23202 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23203
23204         * modules/xalloc (Files): Undo latest change, since xalloc.h
23205         no longer needs SIZE_MAX or PTRDIFF_MAX.
23206
23207 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23208
23209         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
23210         gl_PTRDIFF_MAX.
23211
23212 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23213
23214         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
23215         "return", to pacify some unknown compiler.  Problem reported
23216         by Joerg Schilling.
23217
23218 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23219
23220         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
23221         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
23222         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
23223         heuristic is just as accurate as far as we know, and it removes a
23224         dependency on size_max.m4 and ptrdiff_max.m4.
23225
23226 2003-11-11  Bruno Haible  <bruno@clisp.org>
23227
23228         * modules/xsize (Files): Add m4/size_max.m4.
23229         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
23230
23231 2003-11-11  Bruno Haible  <bruno@clisp.org>
23232
23233         * m4/size_max.m4: New file.
23234         * m4/ptrdiff_max.m4: New file.
23235         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
23236         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
23237         (gl_XALLOC): Invoke it.
23238
23239 2003-11-11  Bruno Haible  <bruno@clisp.org>
23240
23241         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
23242         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
23243         defined.
23244
23245 2003-11-10  Paul Eggert  <eggert@twinsun.com>
23246
23247         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
23248         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
23249         rejected some allocations of exactly SIZE_MAX - 2 bytes.
23250         From Bruno Haible.
23251         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
23252         not (size_t) -1, since it's defined here.
23253
23254 2003-11-09  Karl Berry  <karl@gnu.org>
23255
23256         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
23257
23258 2003-11-06  Paul Eggert  <eggert@twinsun.com>
23259
23260         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
23261         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
23262         Reject sizes of exactly SIZE_MAX bytes.
23263         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
23264         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
23265
23266 2003-11-05  Bruno Haible  <bruno@clisp.org>
23267
23268         * lib/xsize.h: Include limits.h, to avoid a possible collision with
23269         SIZE_MAX defined in <limits.h> on Solaris.
23270
23271 2003-11-04  Jim Meyering  <jim@meyering.net>
23272
23273         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
23274         variable names, rather than @VAR@.
23275         * modules/poll: Likewise.
23276
23277 2003-11-04  Bruno Haible  <bruno@clisp.org>
23278
23279         * modules/xsize: New file.
23280         * modules/linebreak: Depend on xsize.
23281         * MODULES.html.sh (func_all_modules): Add xsize.
23282
23283 2003-11-04  Bruno Haible  <bruno@clisp.org>
23284
23285         * m4/xsize.m4: New file.
23286
23287 2003-11-04  Bruno Haible  <bruno@clisp.org>
23288
23289         * lib/xsize.h: New file.
23290         * lib/linebreak.c: Include xsize.h.
23291         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
23292         argument for overflow.
23293         Suggested by Paul Eggert.
23294
23295 2003-11-03  Karl Berry  <karl@gnu.org>
23296
23297         * config/config.{guess,sub}: update from config.
23298
23299 2003-11-03  Jim Meyering  <jim@meyering.net>
23300
23301         * modules/userspec (lib_SOURCES): Add userspec.h.
23302         (Include): Add "userspec.h".
23303         Improve description.
23304
23305 2003-11-03  Jim Meyering  <jim@meyering.net>
23306
23307         * lib/userspec.c: Include "userspec.h".
23308         * lib/userspec.h: New file.
23309
23310 2003-11-03  Bruno Haible  <bruno@clisp.org>
23311
23312         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
23313
23314 2003-11-03  Bruno Haible  <bruno@clisp.org>
23315
23316         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
23317         available, to avoid (extremely rare) race condition.
23318         Suggested by Paul Eggert.
23319
23320 2003-11-02  Karl Berry  <karl@gnu.org>
23321
23322         * config/srclist.txt (vasprintf.c): sync broken, sigh.
23323
23324 2003-10-31  Paul Eggert  <eggert@twinsun.com>
23325
23326         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
23327         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
23328         (read_filesystem_list): Set and use me_type_malloced.
23329         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
23330         whatever the type happens to be), for brevity and consistency.
23331         Check for size calculation overflow on Alphas running OSF/1.
23332
23333 2003-10-31  Jim Meyering  <jim@meyering.net>
23334
23335         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
23336
23337         * lib/linebuffer.c: Include <string.h> for declaration of memset.
23338
23339 2003-10-30  Paul Eggert  <eggert@twinsun.com>
23340             Bruno Haible  <bruno@clisp.org>
23341
23342         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
23343         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
23344
23345 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
23346
23347         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
23348         netbsd*-gnu*.  Suggested by Robert Millan.
23349
23350 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23351
23352         * modules/group-member: Depend on stdbool.
23353
23354 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23355
23356         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
23357
23358 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23359
23360         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
23361         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
23362         after the 'gnu' in these cases.  This fixes some bugs in the
23363         previous change, and is based on suggestions by Robert Millan.
23364
23365 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23366
23367         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
23368         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
23369         no longer needed.
23370         * lib/quotearg.c (quotearg_n_options): Use it.
23371         * lib/group-member.c: Include <stdbool.h>.
23372         (free_group_info): Arg is now const *; don't free arg.
23373         (get_group_info): Now returns bool and accepts struct group_info *,
23374         rather than returning a malloc'ed struct group_info *.
23375         All uses changed.  Check for overflow in internal size calculation.
23376
23377         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
23378         rather than xmalloc/xrealloc.
23379         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
23380         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
23381         conformance bug: the old code used a pointer after freeing the
23382         storage that it addressed.
23383         * lib/hash.c (hash_initialize): Simplify the code by using
23384         xalloc_oversized rather than doing it by hand.
23385         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
23386         the buffer preserved.  Use free and xmalloc instead.
23387         * lib/quotearg.c (quotearg_n_options): Likewise.
23388         Use a simpler test for size overflow.  Don't use xalloc_oversized
23389         because unsigned int might be wider than size_t (!); this suggests
23390         that we should switch from unsigned int to size_t for slot numbers.
23391
23392 2003-10-28  Paul Eggert  <eggert@twinsun.com>
23393
23394         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
23395         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
23396         NetBSD kernels.  Requested by Richard Stallman.
23397
23398 2003-10-27  Paul Eggert  <eggert@twinsun.com>
23399
23400         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
23401         to allocate the returned structure.  Do not allocate a subarray,
23402         as x2nrealloc will do that.
23403         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
23404         instead of xnrealloc.
23405         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
23406
23407 2003-10-27  Bruno Haible  <bruno@clisp.org>
23408
23409         * lib/stdbool_.h: Better support for BeOS.
23410
23411 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23412
23413         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
23414         now uses inline.
23415
23416 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23417
23418         * lib/xalloc.h (xalloc_oversized): New static inline function, for
23419         callers that want to do their own size-overflow checking.  Include
23420         <stdbool.h>, since xalloc_oversized returns bool.
23421         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
23422         to use xalloc_oversized.
23423
23424         Add two functions x2realloc, x2nrealloc, for programs that grow
23425         arrays dynamically by doubling their sizes.
23426         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
23427         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
23428         New functions.
23429
23430         Port to C99 semantics for 'inline' of external functions.
23431         Bug reported by Bruno Haible.
23432         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
23433         with the old contents of xnmalloc.
23434         (xnmalloc, xmalloc): Use it.
23435         (xnrealloc_inline): New static inline function,
23436         with the old contents of xnrealloc.
23437         (xnrealloc, xrealloc): Use it.
23438
23439         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
23440         that.
23441
23442 2003-10-26  Karl Berry  <karl@gnu.org>
23443
23444         * config/srclist.txt (COPYING.DOC): no longer available from
23445         /gd/gnuorg; don't know where the ultimate source is.
23446
23447 2003-10-25  Paul Eggert  <eggert@twinsun.com>
23448
23449         Fix several address-calculation bugs in the hash modules,
23450         plus some minor code cleanup.
23451
23452         * lib/hash.h: Include <stdbool.h>, for bool.
23453         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
23454         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
23455         hash_get_n_entries, hash_get_max_bucket_length,
23456         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
23457         hash_rehash): Use size_t rather than unsigned.
23458         * lib/hash.c (struct hash_table, hash_get_n_buckets,
23459         hash_get_n_buckets_used, hash_get_n_entries,
23460         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
23461         hash_get_entries, hash_do_for_each, hash_string, is_prime,
23462         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
23463         Likewise.
23464         (SIZE_MAX): Define if not defined.
23465         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
23466         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
23467         hash_print):
23468         Use const * when possible.
23469         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
23470         (check_tuning): Fix bug: if tuning parameters were very close to
23471         0 or 1, rounding errors could have caused subscript violations.
23472         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
23473         (hash_initialize): Add 'fail:' label
23474         to free table and return NULL, and use it to simplify code.
23475         Use calloc rather than clearing the storage ourself.
23476         (hash_initialize, hash_rehash): Check for arithmetic overflow in
23477         buffer size calculations.
23478         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
23479         Include <stddef.h>, for size_t.
23480         * lib/hash-pjw.c (hash_pjw): Likewise.
23481         Switch to method described by Bruno Haible.
23482         Include <limits.h>, for CHAR_BIT.
23483         (SIZE_BITS): New macro.
23484
23485 2003-10-23  Paul Eggert  <eggert@twinsun.com>
23486
23487         * m4/getline.m4 (AM_FUNC_GETLINE):
23488         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
23489         hosts.  Problem reported by Derek Robert Price in
23490         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
23491         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
23492         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
23493
23494 2003-10-21  Paul Eggert  <eggert@twinsun.com>
23495
23496         * lib/getndelim2.c (getndelim2): When size calculation overflows,
23497         ceiling the allocation at NMAX bytes rather than silently
23498         discarding input bytes before NMAX is reached.  This makes
23499         a difference only if NMAX exceeds SIZE_MAX / 2.
23500
23501         * lib/obstack.c: Merge from glibc.
23502         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
23503         Add libc_hidden_def (_obstack_newchunk).
23504         (_obstack_free) [! defined _LIBC]: Remove.
23505         [defined _LIBC]: Make a strong alias from obstack_free, rather than
23506         a clone of the function body.
23507         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
23508         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
23509
23510         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
23511         glibc.
23512         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
23513         arg to memcpy.
23514
23515         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
23516         (obstack_ptr_grow_fast, obstack_int_grow_fast):
23517         Don't use lvalue casts, as GCC plans to remove support for them
23518         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
23519         was also present in the non-GCC version, indicating that this
23520         code had always been buggy and had never been widely used.
23521         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
23522         Use the fast variant of each macro, rather than copying the
23523         definiens of the fast variant; that way, we'll be more likely to
23524         catch future bugs in the fast variants.
23525
23526 2003-10-20  Bruno Haible  <bruno@clisp.org>
23527
23528         * modules/wait-process: New file.
23529         * MODULES.html.sh (func_all_modules): Add wait-process.
23530
23531 2003-10-20  Bruno Haible  <bruno@clisp.org>
23532
23533         * m4/wait-process.m4: New file.
23534
23535 2003-10-20  Bruno Haible  <bruno@clisp.org>
23536
23537         * lib/wait-process.h: New file, from GNU gettext.
23538         * lib/wait-process.c: New file, from GNU gettext.
23539
23540 2003-10-19  Jim Meyering  <jim@meyering.net>
23541
23542         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
23543         HPUX 10.20.
23544
23545 2003-10-18  Karl Berry  <karl@gnu.org>
23546
23547         * config/config.guess: update from config.
23548
23549 2003-10-16  Paul Eggert  <eggert@twinsun.com>
23550
23551         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
23552         (getgroups): First arg is int, not size_t.
23553         Don't let 'free' mangle errno.
23554
23555 2003-10-16  Paul Eggert  <eggert@twinsun.com>
23556
23557         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
23558
23559 2003-10-16  Karl Berry  <karl@gnu.org>
23560
23561         * config/config.{guess,sub}: update from config.
23562
23563 2003-10-16  Jim Meyering  <jim@meyering.net>
23564
23565         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
23566         memcpy.
23567
23568 2003-10-15  Paul Eggert  <eggert@twinsun.com>
23569
23570         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
23571         (SIZE_MAX): Remove.
23572         (new_exclude, add_exclude_file): Initial size no longer needs to
23573         be a power of 2.
23574         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
23575         our own address arithmetic overflow checking.
23576
23577         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
23578         (fnmatch): Do not alloca more than 2000 wide characters;
23579         instead, use malloc for large buffers.
23580         Check for address arithmetic overflow, and return -1
23581         with errno set to ENOMEM in that case.
23582         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
23583         (NEW_PATTERN): Do not alloca more than 8000 bytes;
23584         instead, return -1.  Check for address arithmetic overflow.
23585
23586 2003-10-14  Paul Eggert  <eggert@twinsun.com>
23587
23588         Handle invalid suffixes and overflow independently, so that
23589         callers can treat them independently as needed.  Fix some bugs in
23590         suffix handling, e.g., "100k@" was not diagnosed as an invalid
23591         suffix for a human-readable blocksize.  The major caller-visible
23592         change is the addition of a new
23593         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
23594         that both overflow and suffix chars were found.
23595
23596         * lib/human.c (humblock): Don't check separately for invalid suffix
23597         char; that is xstrtoumax's job (now that its bug is fixed).
23598         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
23599         INTMAX_MAX]: New macros.
23600         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
23601         TYPE_MAXIMUM): New macros.
23602         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
23603         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
23604         if overflow occurs, as it's what __strtol does and it's more useful
23605         in practice.
23606         (__xstrtol): If __strtol reports some error other than ERANGE,
23607         reflect it to the caller as LONGINT_INVALID.  If it reports
23608         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
23609         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
23610         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
23611         value.
23612         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
23613         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
23614         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
23615         [defined UINTMAX_MAX]: New macros.
23616
23617 2003-10-14  Bruno Haible  <bruno@clisp.org>
23618
23619         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
23620
23621 2003-10-14  Bruno Haible  <bruno@clisp.org>
23622
23623         * m4/sig_atomic_t: New file, from GNU gettext.
23624         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
23625
23626 2003-10-14  Bruno Haible  <bruno@clisp.org>
23627
23628         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
23629         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
23630         Also use volatile where needed.
23631
23632 2003-10-12  Paul Eggert  <eggert@twinsun.com>
23633
23634         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
23635         Change maintainer from Bruno Haible to 'all'.
23636
23637 2003-10-12  Paul Eggert  <eggert@twinsun.com>
23638
23639         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
23640
23641 2003-10-12  Paul Eggert  <eggert@twinsun.com>
23642
23643         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
23644         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
23645         and define in terms of the other primitives.
23646         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
23647         (SIZE_MAX): Define if not already defined.
23648         (array_size_overflow): New function.
23649         (xalloc_die): Abort instead of exiting if 'error' returns.
23650         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
23651         (xmalloc, xrealloc): Use them.
23652         (xcalloc): Check for address arithmetic overflow.
23653         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
23654         a bit faster than strcpy.
23655
23656 2003-10-10  Simon Josefsson  <jas@extundo.com>
23657
23658         * modules/argp (Depends-on): Add restrict and strcase.
23659
23660 2003-10-10  Simon Josefsson  <jas@extundo.com>
23661
23662         * m4/argp.m4: Add AC_C_INLINE.
23663
23664 2003-10-08  Paul Eggert  <eggert@twinsun.com>
23665
23666         Merge getpass from libc, plus a few fixes.
23667
23668         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
23669         Include <stdbool.h>.
23670         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
23671         __fsetlocking to empty.
23672         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
23673         do include <bits/libc-lock.h>.
23674         Do not include <fcntl.h>; not needed.
23675         [_LIBC]: Include <wchar.h>.
23676         (NOTCANCEL_MODE): New macro.
23677         (flockfile, funlockfile) [_LIBC]: New macros.
23678         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
23679         [!_LIBC]: New macros.
23680         (call_fclose): New function.
23681         (getpass): Use it.  Save tty stream separately; this simplifies the
23682         code and makes it more reliable if stdin happens to equal stdout.
23683         Invoke __fsetlocking on tty.
23684         Handle thread cancellation if needed.
23685         Namespace cleanup (use __tcgetattr, __getline).
23686         Use bool for Booleans.
23687         [USE_IN_LIBIO]: Handle wide streams.
23688         [!_LIBC]: Unconditionally do the fseek, since we don't know what
23689         stream might go where.
23690
23691         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
23692         doesn't have to include <stdio.h> before us.
23693         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
23694         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
23695         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
23696         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
23697         if not declared, so that we can use getpass.c code from libc without
23698         rewriting it.
23699         (flockfile, ftrylockfile, funlockfile): New macros.
23700
23701 2003-10-08  Paul Eggert  <eggert@twinsun.com>
23702
23703         * modules/getpass: Depend on stdbool.
23704
23705 2003-10-08  Paul Eggert  <eggert@twinsun.com>
23706
23707         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
23708
23709 2003-10-07  Karl Berry  <karl@gnu.org>
23710
23711         * config/config.{guess,sub}: update from config.
23712
23713 2003-10-06  Jim Meyering  <jim@meyering.net>
23714             Bruno Haible  <bruno@clisp.org>
23715
23716         This lets translators provide better translations for the
23717         "Written by ..." part of --version output.
23718         * lib/version-etc.h: Include stdarg.h.
23719         (version_etc_copyright): Declare as readonly.
23720         (version_etc): Make this function variadic with a NULL-terminated list
23721         of author name strings.
23722         (version_etc_va): New declaration.
23723         * lib/version-etc.c: Include stdarg.h, stdlib.h.
23724         (version_etc_copyright): Declare as readonly.
23725         (version_etc_va): New function. Provide a different translatable string
23726         for each possible number of authors < 10. Abbreviate when there are 10
23727         authors or more.
23728         (version_etc): Make this function variadic. Call version_etc_va.
23729         Suggestion from Gary V. Vaughan.
23730
23731         * lib/long-options.h (parse_long_options): Change prototype: the
23732         authors string is moved to the end and becomes variadic.
23733         * lib/long-options.c: Include stdarg.h.
23734         (parse_long_options): Make this function variadic, too.
23735         Call version_etc_va, not version_etc.
23736
23737 2003-10-06  Bruno Haible  <bruno@clisp.org>
23738
23739         * modules/version-etc-2: Remove file.
23740         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
23741
23742 2003-10-06  Bruno Haible  <bruno@clisp.org>
23743
23744         * modules/fatal-signal: New file.
23745         * MODULES.html.sh (func_all_modules): Add fatal-signal.
23746
23747 2003-10-06  Bruno Haible  <bruno@clisp.org>
23748
23749         * m4/fatal-signal.m4: New file.
23750         * m4/signalblocking.m4: New file, from GNU gettext.
23751
23752 2003-10-06  Bruno Haible  <bruno@clisp.org>
23753
23754         * lib/version-etc-2.h: Remove file.
23755         * lib/version-etc-2.c: Remove file.
23756
23757 2003-10-06  Bruno Haible  <bruno@clisp.org>
23758
23759         * lib/fatal-signal.h: New file, from GNU gettext.
23760         * lib/fatal-signal.c: New file, from GNU gettext.
23761
23762 2003-10-05  Paul Eggert  <eggert@twinsun.com>
23763
23764         * README: Rework advice for preventing empty .o files.
23765         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
23766         not <sys/types.h>.
23767
23768 2003-10-04  Karl Berry  <karl@gnu.org>
23769
23770         * lib/argp*: update from libc.
23771
23772 2003-10-04  Karl Berry  <karl@gnu.org>
23773
23774         * config/config.{guess,sub}: update from config.
23775
23776 2003-10-02  Bruno Haible  <bruno@clisp.org>
23777
23778         * modules/lchown (Include): Add lchown.h.
23779         * modules/time_r (Include): Use "..." syntax.
23780         * modules/xgetdomainname (Include): Add xgetdomainname.h.
23781
23782 2003-10-01  Simon Josefsson  <jas@extundo.com>
23783
23784         * MODULES.html.sh (func_all_modules): Move gethostname from section
23785         'based on' to section 'lacking' POSIX:2001.
23786
23787 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
23788
23789         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
23790         to output mode on the same stream.
23791
23792 2003-09-29  Paul Eggert  <eggert@twinsun.com>
23793
23794         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
23795         Fix arg typo in previous patch.
23796
23797 2003-09-28  Jim Meyering  <jim@meyering.net>
23798
23799         * lib/error.c: Correct cpp indentation.
23800
23801 2003-09-27  Paul Eggert  <eggert@twinsun.com>
23802
23803         * modules/free: New file.
23804
23805 2003-09-27  Paul Eggert  <eggert@twinsun.com>
23806
23807         * m4/free.m4: New file.
23808
23809 2003-09-27  Paul Eggert  <eggert@twinsun.com>
23810
23811         * lib/minmax.h (MIN, MAX)
23812         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
23813         Omit the special code that used __typeof__, since we worry that
23814         it could be more trouble than it's worth.  See:
23815         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
23816         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
23817
23818         * lib/free.c: New file.
23819
23820 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
23821
23822         Trivial fixes to Makefile.am parts of module listings.
23823         * modules/strstr: Append strstr.h to lib_SOURCES.
23824         * modules/strcase: Likewise, for strcase.h.
23825
23826 2003-09-27  Karl Berry  <karl@gnu.org>
23827
23828         * config/mkinstalldirs: update from automake.
23829
23830 2003-09-26  Paul Eggert  <eggert@twinsun.com>
23831
23832         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
23833         (error_tail): Do not loop, reallocating temporary buffer, since
23834         the output cannot contain more wide characters than the input
23835         contains bytes, the size must be big enough already.  This avoids
23836         one potential size overflow calculation.  Check for size overflow
23837         when calculating temporary buffer size.  Free temporary buffer
23838         when done, if it was allocated with malloc; this plugs a memory
23839         leak.  Remove casts from void * to pointers, that are no longer
23840         needed now that we're assuming C89 or better.
23841
23842         Merge error changes from glibc.
23843
23844         * lib/error.c, error.h: Update copyright notice header to match glibc.
23845         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
23846         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
23847         Disable cancellation while printing error.
23848         * lib/error.h: Prepend __ to parameter names.
23849
23850 2003-09-26  Jim Meyering  <jim@meyering.net>
23851
23852         * lib/error.c (error_tail): Move some declarations
23853         into inner scope where the local variables are used.
23854
23855 2003-09-26  Bruno Haible  <bruno@clisp.org>
23856
23857         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
23858         stpncpy().
23859         Don't define stpncpy through config.h; it's now done through stpncpy.h.
23860
23861 2003-09-26  Bruno Haible  <bruno@clisp.org>
23862
23863         * lib/stpncpy.h (gnu_stpncpy): New declaration.
23864         (stpncpy): Define as alias for gnu_stpncpy.
23865         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
23866
23867 2003-09-25  Simon Josefsson  <jas@extundo.com>
23868
23869         * lib/xgetdomainname.h: New file.
23870         * lib/xgetdomainname.c: New file.
23871
23872 2003-09-25  Simon Josefsson  <jas@extundo.com>
23873             Bruno Haible  <bruno@clisp.org>
23874
23875         * modules/getdomainname: New file.
23876         * modules/xgetdomainname: New file.
23877         * MODULES.html.sh (func_all_modules): Add getdomainname,
23878         xgetdomainname.
23879
23880 2003-09-25  Simon Josefsson  <jas@extundo.com>
23881             Bruno Haible  <bruno@clisp.org>
23882
23883         * m4/getdomainname.m4: New file.
23884
23885 2003-09-25  Simon Josefsson  <jas@extundo.com>
23886             Bruno Haible  <bruno@clisp.org>
23887
23888         * lib/getdomainname.h: New file.
23889         * lib/getdomainname.c: New file.
23890
23891 2003-09-25  Karl Berry  <karl@gnu.org>
23892
23893         * lib/argp-fmtstream.c, argp-help.c: update from libc.
23894
23895 2003-09-25  Karl Berry  <karl@gnu.org>
23896
23897         * config/install-sh: update from automake.
23898
23899 2003-09-25  Bruno Haible  <bruno@clisp.org>
23900
23901         * modules/version-etc-2: New file, from modules/version-etc with
23902         modifications.
23903         * MODULES.html.sh (func_all_modules): Add version-etc-2.
23904
23905 2003-09-25  Bruno Haible  <bruno@clisp.org>
23906
23907         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
23908         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
23909
23910 2003-09-24  Simon Josefsson  <jas@extundo.com>
23911
23912         * modules/xgethostname: Add xgethostname.h.
23913
23914 2003-09-24  Paul Eggert  <eggert@twinsun.com>
23915
23916         * lib/linebuffer.c (freebuffer): Don't free the argument, just
23917         the buffer associated with the argument.  Bug reported by
23918         Simon Josefsson.
23919
23920 2003-09-24  Paul Eggert  <eggert@twinsun.com>
23921
23922         * README: Document assumptions that 'int' is at least 32 bits
23923         wide, that integer arithmetic is 2's complement without overflow,
23924         that there are no holes in integer values, that adding sizes of
23925         two nonoverlapping objects can't overflow, and that all-bits-zero
23926         yields scalar zero.  Fix spelling and capitalization typos.
23927
23928 2003-09-19  Karl Berry  <karl@gnu.org>
23929
23930         * lib/argp.h: update from libc.
23931
23932 2003-09-17  Paul Eggert  <eggert@twinsun.com>
23933
23934         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
23935         to avoid spurious warnings like "AC_RUN_IFELSE was called before
23936         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
23937
23938 2003-09-17  Paul Eggert  <eggert@twinsun.com>
23939
23940         * gnulib-tool: Use "test -h", not "test -L", for portability
23941         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
23942         (tags_regexp): Remove, since \| doesn't conform to POSIX.
23943         (sed_extract_prog): Issue s commands one-by-one, rather than
23944         using \| in one s command.
23945
23946 2003-09-16  Paul Eggert  <eggert@twinsun.com>
23947
23948         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
23949         input error, instead of returning NULL the next time we are called
23950         (and therefore losing track of errno).
23951
23952 2003-09-16  Bruno Haible  <bruno@clisp.org>
23953
23954         * gnulib-tool (func_create_testdir): Warn about duplicated
23955         dependencies.
23956
23957 2003-09-15  Paul Eggert  <eggert@twinsun.com>
23958
23959         * modules/argmatch, modules/fatal, modules/obstack,
23960         modules/xalloc, modules/xgethostname: Sort dependencies by
23961         importance, not alphabetically.
23962
23963 2003-09-15  Paul Eggert  <eggert@twinsun.com>
23964
23965         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
23966         fails, so that the caller gets the proper errno.
23967
23968         * lib/readutmp.c (read_utmp): Likewise.
23969         Check for fstat error.  Close stream and free storage
23970         when failing.
23971
23972 2003-09-14  Karl Berry  <karl@gnu.org>
23973
23974         * config/srclist.txt (strdup.c): disable for c89 changes.
23975
23976 2003-09-14  Jim Meyering  <jim@meyering.net>
23977
23978         * lib/getloadavg.c: Correct cpp indentation.
23979         * lib/strdup.c: Likewise.
23980         * lib/vasnprintf.c: Likewise.
23981
23982 2003-09-14  Bruno Haible  <bruno@clisp.org>
23983
23984         * modules/fwriteerror: New file.
23985         * MODULES.html.sh (func_all_modules): Add fwriteerror.
23986
23987 2003-09-14  Bruno Haible  <bruno@clisp.org>
23988
23989         * lib/fwriteerror.h: New file.
23990         * lib/fwriteerror.c: New file.
23991
23992 2003-09-12  Paul Eggert  <eggert@twinsun.com>
23993
23994         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
23995         modules/xgethostname, modules/xalloc: Depend on exit.
23996
23997 2003-09-12  Paul Eggert  <eggert@twinsun.com>
23998
23999         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
24000
24001         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
24002         and AC_MINIX, too, so that their extensions are available.
24003
24004         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
24005         This macro has been superseded by gl_BACKUPFILE.
24006
24007         More patches to assume C89 or better.
24008
24009         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
24010
24011         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
24012         unconditionally.
24013         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
24014         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
24015         Include <string.h>, <stdlib.h> unconditionally.
24016         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
24017         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
24018         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
24019         headers or for string.h.
24020         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
24021         or strtoul.
24022
24023         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
24024         headers.
24025         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
24026         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24027         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
24028         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
24029         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24030         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
24031         memcpy, memset.
24032         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
24033         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
24034         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
24035         strtol.
24036         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
24037         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
24038         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
24039         strtoul.
24040
24041 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24042
24043         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
24044         * lib/obstack.c [!defined _LIBC]: Likewise.
24045         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
24046         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
24047         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
24048
24049         More changes to assume C89 or better.
24050
24051         * lib/error.c (error_tail): Assume vprintf.
24052
24053         * lib/argmatch.c (getenv): Remove decl.
24054         * lib/progreloc.c (get_full_program_name): Define via prototype.
24055         * lib/setenv.c (clearenv): Likewise.
24056         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
24057         needed.
24058         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
24059         (malloc, memcpy): Remove decls.
24060         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
24061         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
24062         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24063         (memcpy): Remove macro.
24064         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
24065         (__P): Remove.  All uses removed.
24066         (PTR): Remove.  All uses changed to void *.
24067         (CHAR_BIT, NULL): Remove.
24068         (spaces, zeros, memset_space, memset_zero)
24069         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
24070         Remove.
24071         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
24072         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
24073         Define with prototype.
24074         Remove now-unnecessary prototype decl.
24075         (extra_args_spec): Assume ANSI C.  All uses changed.
24076         (extra_args_spec_iso): Remove.
24077         (my_strftime, emacs_strftimeu): Define via prototype.
24078         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
24079         unconditionally.
24080         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
24081         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
24082         (strtoul, strtol): Remove decls.
24083         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
24084         LONG_MAX): Remove.
24085         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24086         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
24087         (LOCALE_PARAM_PROTO): New macro.
24088         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
24089         (INTERNAL (strtol), strtol): Define with a prototype.
24090         (PARAMS): Remove.  All uses removed.
24091         * lib/tempname.c: Include <string.h> unconditionally.
24092         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
24093         * lib/xgethostname.c (main): Define with a prototype.
24094         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
24095         Include <stdlib.h> unconditionally.
24096         (calloc, malloc, realloc, free): Remove decls.
24097         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
24098         Include <stdlib.h> unconditionally.  Sort include file names.
24099         (strtod): Remove.
24100         (xstrtod): Define with a prototype.
24101         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
24102         (strtol, strtoul): Remove decls.
24103
24104 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24105
24106         More patches to assume C89 or better.
24107         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
24108         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
24109         string.h, memchr, STDC_HEADERS.
24110
24111 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24112
24113         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
24114         Include <stdlib.h>, <string.h> unconditionally.
24115         Remove now-unnecessary cast to char *.
24116         * lib/strnlen.c: Include <string.h> unconditionally.
24117         * lib/yesno.c (yesno): Define with a prototype.
24118
24119 2003-09-11  Bruno Haible  <bruno@clisp.org>
24120
24121         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
24122
24123 2003-09-10  Jim Meyering  <jim@meyering.net>
24124
24125         * lib/error.c: Correct indentation of cpp directives.
24126
24127 2003-09-10  Bruno Haible  <bruno@clisp.org>
24128
24129         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
24130         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
24131         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
24132         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
24133         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
24134         <stdlib.h> and <string.h> checks.
24135         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
24136         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
24137
24138 2003-09-10  Bruno Haible  <bruno@clisp.org>
24139
24140         * lib/strcspn.c: Include <string.h> unconditionally.
24141         * lib/strpbrk.c: Include <string.h> unconditionally.
24142         * lib/strstr.c: Include <string.h> unconditionally.
24143         * lib/unicodeio.c: Include <string.h> unconditionally.
24144         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
24145         * lib/unsetenv.c: Likewise.
24146         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
24147         * lib/yesno.c: Include <stdlib.h> unconditionally.
24148         (rpmatch): Add prototype.
24149
24150 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24151
24152         More patches to assume C89 or better.
24153         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
24154         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
24155         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
24156         or for string.h.
24157         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
24158         stdlib.h.
24159         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
24160         C headers.
24161         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
24162         string.h.
24163         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
24164         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
24165         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
24166         or for string.h.
24167         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
24168         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
24169         C headers.
24170         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
24171         memcpy.
24172         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
24173         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
24174         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
24175         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
24176         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
24177         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
24178         string.h, free.
24179         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
24180         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
24181         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
24182         C headers, or for string.h.
24183         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
24184         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
24185         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
24186         headers, memory.h, stdlib.h, string.h, strings.h.
24187         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
24188         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
24189         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
24190         strchr.
24191         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
24192         headers, memory.h, string.h.
24193         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
24194         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
24195         free.
24196         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
24197         headers.
24198         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
24199         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
24200         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
24201         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
24202         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
24203
24204 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24205
24206         More K&R removal.
24207
24208         * lib/acosl.c (main): Use a prototype.
24209         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
24210         tanl.c: Likewise.
24211
24212         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
24213
24214         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
24215         (getopt, etopt_long, getopt_long_only, _getopt_internal)
24216         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
24217         with a prototype.
24218         * lib/getopt.c (const): Remove macro.
24219         Include <string.h> unconditionally.
24220         (my_index): Remove; all uses changed to strchr.
24221         (strlen): Remove decl.
24222         (exchange): Remove forward decl; no longer needed.
24223         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
24224         Define with prototype.
24225         * lib/getopt1.c (const): Remove macro.
24226         (getopt_long, getopt_long_only, main): Define with prototype.
24227
24228         * lib/getugroups.c: Include <string.h> unconditionally.
24229
24230         * lib/getusershell.c: Include <stdlib.h> unconditionally.
24231         (getusershell, setusershell, endusershell, readname, main):
24232         Define with prototypes.
24233
24234         * lib/group-member.c: Include group-member.h first.
24235         Include <stdlib.h> unconditionally.
24236
24237         * lib/hard-locale.c: Include hard-locale.h first.
24238         Include <stdlib.h>, <string.h> unconditionally.
24239
24240         * lib/hash.c (free, malloc): Remove decls.
24241         Include <stdlib.h> unconditionally.
24242
24243         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
24244         (getenv): Do not declare.
24245
24246         * lib/idcache.c: Include <string.h> unconditionally.
24247
24248         * lib/long-options.c: Include long-options.h first, to test interface.
24249         Include <stdlib.h> unconditionally.
24250
24251         * lib/makepath.c: Include makepath.h first, to test interface.
24252         Include <stdlib.h> and <string.h> unconditionally.
24253
24254         * lib/linebuffer.c: Include <stdlib.h>.
24255         (free): Remove decl.
24256
24257         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
24258         stddef.h. rpl_malloc returns void *, not char *.
24259         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
24260         prototype.
24261
24262         * lib/md5.h: Include <limits.h> unconditionally.
24263         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
24264         (__P): Remove; all uses removed.
24265         * lib/md5.c: Include "md5.h" first.
24266         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
24267         md5_buffer, md5_process_bytes, md5_process_block):
24268         Define with prototypes.
24269         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
24270         * lib/sha.c: Include "sha.h" first.
24271         Include <stdlib.h>, <string.h> unconditionally.
24272
24273         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
24274         * lib/memcmp.c (__ptr_t): Likewise.
24275         * lib/memrchr.c (__ptr_t): Likewise.
24276         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
24277         Include <string.h> unconditionally.
24278         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
24279         * lib/memchr.c: Include <stdlib.h> unconditionally.
24280         * lib/memchr.c (LONG_MAX): Remove.
24281         * lib/memrchr.c (LONG_MAX): Likewise.
24282         * lib/memchr.c (__memchr): Define via a prototype.
24283         * lib/memrchr.c (__memrchr): Likewise.
24284         * lib/memcmp.c (__P): Remove, and remove all uses.
24285         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
24286         Remove forward decls; no longer needed.
24287         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
24288         Use types required by C89 in prototype.
24289
24290         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
24291         * lib/savedir.c: Likewise.
24292         * lib/mkdir.c (free): Remove decl.
24293         * lib/rmdir.c (rmdir): Define with a prototype.
24294         * lib/savedir.c: Include savedir.h first, to test interface.
24295
24296         * lib/mktime.c (STDC_HEADERS): Remove.
24297         Include <stdlib.h>, <string.h> unconditionally.
24298
24299         * lib/modechange.c: Include <stdlib.h> unconditionally.
24300         (malloc): Remove decl.
24301
24302         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
24303         (free): Remove decl.
24304
24305         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
24306         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
24307         (This type really should be intptr_t, but that's a C99ism.)
24308         (_obstack_memcpy): Remove: all uses changed to memcpy.
24309         Include <string.h> unconditionally.
24310         (struct obstack): Assume __STDC__ for types of members
24311         chunkfun, freefun, extra_arg.
24312         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
24313         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
24314         obstack_begin, obstack_specify_allocation,
24315         obstack_specify_allocation_with_arg, obstack_chunkfun,
24316         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
24317         Remove unprototyped decls and the macros that use them.
24318         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
24319         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
24320         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
24321         (defined __STDC__ && __STDC__)]:
24322         Remove nonprototyped code.
24323         Include <stdlib.h> unconditionally.
24324         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
24325         _obstack_allocated_p, _obstack_free, obstack_free,
24326         _obstack_memory_used, print_and_abort):
24327         Define using prototypes.
24328         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
24329         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
24330         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
24331         obstack_next_free, obstack_object_size, obstack_room) [0]:
24332         Remove unused, unprototyped code.
24333
24334         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
24335
24336         * lib/physmem.c (physmem_total, physmem_available, main): Define
24337         with prototypes.
24338
24339         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
24340         (main): Define with a prototype.
24341
24342         * lib/posixver.c (getenv): Remove decl.
24343
24344         * lib/putenv.c (malloc): Returns void *, not char *.
24345         Include <string.h> unconditionally.
24346         (strchr, memcpy, NULL): Do not define.
24347
24348         * lib/readtokens.c: Include readtokens.h first, to test interface.
24349         Include <stdlib.h>, <string.h> unconditionally.
24350         (init_tokenbuffer): Define with a prototype.
24351
24352         * lib/regex.c (PARAMS): Remove.  All uses removed.
24353         All uses of _RE_ARGS removed, too.
24354         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
24355         unconditionally.
24356         (bzero): Assume memset exists.
24357         (memcmp, memcpy, NULL): Remove.
24358         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
24359         char, or assignments to local vars of type signed char.
24360         (init_syntax_once, PREFIX(extract_number_and_incr),
24361         PREFIX(print_partial_compiled_pattern),
24362         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
24363         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
24364         PREFIX(regex_grow_registers), PREFIX(regex_compile),
24365         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
24366         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
24367         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
24368         wcs_compile_range, byte_compile_range, truncate_wchar,
24369         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
24370         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
24371         count_mbs_length, wcs_re_match_2_internal,
24372         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
24373         PREFIX(alt_match_null_string_p),
24374         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
24375         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
24376         regfree, PREFIX(extract_number)): Define with prototype.  Remove
24377         now-unnecessary declaration, if any.
24378         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
24379         regcomp, regexec):
24380         Remove now-unnecessary casts among pointer types.
24381         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
24382
24383         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
24384         (free): Remove decl.
24385
24386         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
24387
24388         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
24389         (free): Remove decl.
24390
24391         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
24392         * lib/xgetcwd.c: Likewise.
24393
24394         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
24395         (free): Remove decl.
24396
24397         * lib/strchrnul.c (strchrnul): Define with a prototype.
24398         Fix bug: c_in was not converted to char before searching.
24399
24400         The following changes are not K&R related:
24401
24402         * lib/group-member.h: Include <sys/types.h>, so that this file is
24403         self-contained.
24404         * lib/makepath.h: Likewise.
24405
24406         * lib/getusershell.c (readname, default_index, line_size, readname):
24407         Use size_t, not int, for sizes.
24408         (readname): If the size overflows, report an error instead of
24409         looping forever.
24410
24411 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24412
24413         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
24414         libc.
24415
24416 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24417
24418         * README: New section: portability guidelines.
24419
24420 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24421
24422         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
24423         C89 spec.
24424
24425 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24426
24427         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
24428
24429 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24430
24431         Assume C89 or better; remove K&R cruft.
24432         A few of these changes were first proposed by Derek Robert Price
24433         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
24434
24435         * lib/addext.c: Include <string.h> unconditionally.
24436         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
24437         Don't declare getenv or malloc.
24438
24439         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
24440         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
24441         (NULL): Remove.
24442         (find_stack_direction, alloca): Use prototypes.
24443
24444         * lib/atexit.c (atexit): Define using a prototype.
24445
24446         * lib/basename.c, dirname.c, stripslash.c:
24447         Include <string.h> unconditionally.
24448
24449         * lib/bcopy.c: Include <stddef.h>.
24450         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
24451
24452         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
24453
24454         * lib/error.h (error, error_at_line, error_print_progname)
24455         [! (defined (__STDC__) && __STDC__)]: Remove decls.
24456         * lib/error.c: Include error.h first, to check interface.
24457         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24458         (VA_START): Remove; all uses changeed to va_start.
24459         (exit, strerror): Remove decls.
24460         (error_print_progname): Prototype uncondionally.
24461         Don't include <errno.h>; no longer needed.
24462         (private_strerror): Remove.
24463         (error_tail): Always define.
24464         (error, error_at_line): Assume C89 or better; always use prototypes.
24465         * lib/fatal.c: Include "fatal.h" first, to test interface.
24466         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24467         (VA_START): Remove; all uses changed to va_start.
24468         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
24469         this case.
24470         (exit): Remove decl.
24471         (fatal): Prototype unconditionally.  Assume va_start works.
24472         Abort at end, to pacify gcc.
24473
24474         * lib/euidaccess.c (main): Define with a prototype.
24475
24476         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
24477
24478         * lib/exitfail.c: Include <stdlib.h> unconditionally.
24479
24480         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
24481         prototypes.
24482         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
24483         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
24484         (getenv): Remove decl.
24485         (fnmatch): Define using a prototype.
24486         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
24487         (FCT): Define using a prototype.
24488
24489         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
24490
24491         * lib/gethostname.c: Include <stddef.h>.
24492         (gethostname): Define with prototype.  Length is size_t, not int.
24493
24494 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24495
24496         Assume C89 or better; remove K&R cruft.
24497         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
24498         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
24499         string.h, getenv, malloc.
24500         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
24501         headers.
24502         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
24503         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
24504         do not check for strerror.
24505         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
24506         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
24507         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
24508         do not check for doprnt or vprintf.
24509         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
24510         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
24511
24512 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24513
24514         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
24515         getversion.c should have been removed then, but was accidentally
24516         preserved.
24517
24518         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
24519         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
24520
24521 2003-09-08  Karl Berry  <karl@gnu.org>
24522
24523         * config/config.sub, config.guess, srclistvars.sh: update from savannah
24524                 config, forget about prep.
24525
24526         * config/depcomp, missing: update from automake.
24527
24528 2003-09-07  Paul Eggert  <eggert@twinsun.com>
24529
24530         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
24531         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
24532
24533 2003-09-07  Paul Eggert  <eggert@twinsun.com>
24534
24535         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
24536         copy_tm_result.  Bug reported by Simon Josefsson in
24537         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
24538
24539 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24540
24541         * m4/time_r.m4: New file.
24542         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
24543         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
24544         is. Check for timegm declaration.
24545         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
24546         Do not check for gmtime_r.
24547         Replace mktime if __mktime_internal does not exist and if mktime
24548         hasn't been replaced already.
24549
24550 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24551
24552         * lib/time_r.c, lib/time_r.h: New files.
24553
24554         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
24555         __localtime_r.
24556         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
24557         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
24558
24559         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
24560         __gmtime_r.
24561         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
24562         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
24563         Include <time_r.h>.
24564
24565         * lib/timegm.c: Switch to glibc implementation, with the following
24566         changes:
24567         [defined HAVE_CONFIG_H]: Include <config.h>.
24568         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
24569         (__mktime_internal) [!defined _LIBC]: New decl.
24570         (__gmtime_r) [!defined _LIBC]: New macro and function.
24571         (timegm): Use a prototype, since gnulib assumes C89.
24572         Do not bother declaring tmp to be const, as it's not really usefu.
24573         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
24574         (timegm): Declare only if HAVE_DECL_TIMEGM.
24575
24576 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24577
24578         * MODULES.html.sh (func_all_modules): Add time_r.
24579         * modules/time_r: New file.
24580         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
24581         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
24582
24583 2003-09-03  Paul Eggert  <eggert@twinsun.com>
24584
24585         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
24586         Bug reported by Lute Kamstra in
24587         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
24588
24589         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
24590         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
24591         course with correspondingly smaller numbers for tomorrow and
24592         yesterday.  From Tadayoshi Funaba.  Originally installed into
24593         sh-utils on 1999-08-07, but the patch got lost (I guess during the
24594         coreutils merge?).
24595
24596 2003-08-31  Simon Josefsson  <jas@extundo.com>
24597
24598         * modules/timegm: New file.
24599         * MODULES.html.sh (func_all_modules): Add timegm.
24600
24601 2003-08-31  Simon Josefsson  <jas@extundo.com>
24602
24603         * m4/timegm.m4: New file.
24604
24605 2003-08-31  Simon Josefsson  <jas@extundo.com>
24606
24607         * lib/timegm.h: New file.
24608         * lib/timegm.c: New file.  Based on
24609         wget-1.8.2/src/http.c:mktime_from_utc.
24610
24611 2003-08-31  Karl Berry  <karl@gnu.org>
24612
24613         * lib/argp.h: update from libc.
24614
24615 2003-08-28  Bruno Haible  <bruno@clisp.org>
24616
24617         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
24618         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
24619         followed by '#define fnmatch fnmatch_posix' gives an error.
24620
24621 2003-08-28  Bruno Haible  <bruno@clisp.org>
24622
24623         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
24624         warning on QNX, which defines O_BINARY to 000000.
24625
24626 2003-08-27  Jim Meyering  <jim@meyering.net>
24627
24628         * m4/mkstemp.m4: Require that the system mkstemp be able to create
24629         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
24630         would fail after 32.  Reported by Danny Levinson.  Details here:
24631         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
24632
24633 2003-08-24  Bruno Haible  <bruno@clisp.org>
24634
24635         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
24636         MSVC7 <stdio.h> is included later.
24637
24638 2003-08-22  Simon Josefsson  <jas@extundo.com>
24639
24640         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
24641
24642 2003-08-20  Karl Berry  <karl@gnu.org>
24643
24644         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
24645
24646 2003-08-20  Bruno Haible  <bruno@clisp.org>
24647
24648         * modules/progname: New file.
24649         * MODULES.html.sh (func_all_modules): Add progname.
24650
24651 2003-08-20  Bruno Haible  <bruno@clisp.org>
24652
24653         * lib/progname.h: New file, from GNU gettext.
24654         * lib/progname.c: New file, from GNU gettext.
24655         * lib/progreloc.c: New file, from GNU gettext.
24656
24657 2003-08-19  Jim Meyering  <jim@meyering.net>
24658
24659         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
24660         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
24661
24662 2003-08-19  Bruno Haible  <bruno@clisp.org>
24663
24664         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
24665         more.
24666
24667 2003-08-19  Bruno Haible  <bruno@clisp.org>
24668
24669         * lib/xstrdup.c: Assume <string.h> exists.
24670
24671 2003-08-18  Paul Eggert  <eggert@twinsun.com>
24672
24673         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
24674         in makefile rules.
24675
24676 2003-08-18  Jim Meyering  <jim@meyering.net>
24677
24678         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
24679         * m4/lib-ld.m4: Likewise.
24680
24681 2003-08-18  Jim Meyering  <jim@meyering.net>
24682
24683         * lib/setenv.h: Indent nested cpp directive.
24684         * lib/vasnprintf.c: Remove trailing blanks.
24685
24686 2003-08-17  Simon Josefsson  <jas@extundo.com>
24687
24688         * modules/xstrndup: New file.
24689         * MODULES.html.sh (func_all_modules): Add xstrndup.
24690
24691 2003-08-17  Simon Josefsson  <jas@extundo.com>
24692
24693         * modules/argp: Fix autoconf macro name. Add more dependencies.
24694
24695 2003-08-17  Simon Josefsson  <jas@extundo.com>
24696
24697         * m4/xstrndup.m4: New file.
24698
24699 2003-08-17  Simon Josefsson  <jas@extundo.com>
24700
24701         * m4/argp.m4: New file.
24702
24703 2003-08-17  Simon Josefsson  <jas@extundo.com>
24704             Bruno Haible  <bruno@clisp.org>
24705
24706         * lib/xstrndup.h: New file.
24707         * lib/xstrndup.c: New file.
24708
24709 2003-08-17  Bruno Haible  <bruno@clisp.org>
24710
24711         * modules/strndup (Files, Include): Add lib/strndup.h.
24712
24713 2003-08-17  Bruno Haible  <bruno@clisp.org>
24714
24715         * modules/euidaccess (Files): Add lib/euidaccess.h.
24716
24717 2003-08-17  Bruno Haible  <bruno@clisp.org>
24718
24719         * lib/strndup.h: New file.
24720
24721 2003-08-17  Bruno Haible  <bruno@clisp.org>
24722
24723         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
24724         like AC_GNU_SOURCE.
24725         * modules/extensions (configure.ac): Comment out the invocation of
24726         gl_USE_SYSTEM_EXTENSIONS.
24727
24728 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24729
24730         Merges from coreutils, etc.
24731         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
24732         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
24733         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
24734         fixing a typo.
24735         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
24736         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
24737
24738 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24739
24740         Document merge from coreutils.
24741         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
24742         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
24743         * modules/utime: Add m4/utimes-null.m4.
24744
24745 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24746
24747         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
24748         space, undoing this 2003-08-12 change:
24749         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
24750
24751 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24752
24753         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
24754         strtoul.c from libc, undoing this 2003-08-12 change:
24755         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
24756
24757 2003-08-16  Jim Meyering  <jim@meyering.net>
24758
24759         Merges from coreutils.
24760         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
24761         prefix.  Adjust cache variables similarly.  Create 500 rather than
24762         just 300 files, to exercise bug on Darwin6.5, too.
24763         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
24764         $missing_dir.
24765         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
24766         AM_SYS_POSIX_TERMIOS.
24767         Reported by mkc@mathdogs.com.
24768         Also change use of $am_cv_sys_posix_termios
24769         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
24770         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
24771         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
24772         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
24773         in /proc/mounts until it finds one with matching device number.  This
24774         is unnecessary when the FILE argument *is* a mount point.  No stat call
24775         is necessary in that case.  So, disable the statvfs-testing code on
24776         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
24777         as RedHat bug# 84846.
24778         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
24779         to 1MB, so as not to render systems with no stack size limit (e.g.,
24780         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
24781         Include <unistd.h>.  On some systems,
24782         it is required for the definition of _SC_PAGESIZE.
24783
24784 2003-08-16  Jim Meyering  <jim@meyering.net>
24785
24786         Merge from coreutils.
24787         * lib/xstrtoimax.c: #else #if -> #elif.
24788         * lib/xstrtoumax.c: Likewise.
24789
24790 2003-08-16  Jim Meyering  <jim@meyering.net>
24791
24792         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
24793         * m4/utimes.m4: Removed.
24794         * m4/utimes-null.m4: Renamed from utimes.m4.
24795
24796         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
24797         to 1MB, so as not to render systems with no stack size limit (e.g.,
24798         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
24799         Include <unistd.h>.  On some systems,
24800         it is required for the definition of _SC_PAGESIZE.
24801
24802 2003-08-16  Jim Meyering  <jim@meyering.net>
24803         and Paul Eggert  <eggert@cs.ucla.edu>
24804
24805         Merges from coreutils, etc.
24806
24807         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
24808         using the latest version from cvs.  This avoids problems with #line
24809         directives using a vendor (Sun) compiler.
24810         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
24811         Don't set GETGROUPS_LIB here; now it's
24812         done via getgroups.m4's wrapper function.
24813         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
24814         rather than just in sh-util/configure.in, so that the
24815         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
24816         same.
24817         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
24818         AC_FUNC_GETLOADAVG where to find getloadavg.c.
24819         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
24820         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
24821         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
24822         Remove code that is now done by the newly-required macros.
24823         Append $(EXEEXT) to DF_PROG.
24824         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
24825         Do not invoke or require the following here,
24826         since prereq.m4 or some gnulib .m4 now does this for us:
24827         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
24828         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
24829         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
24830         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
24831         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
24832         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
24833         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
24834         AC_FUNC_OBSTACK.
24835         Do not replace the following functions, as this is now the job
24836         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
24837         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
24838         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
24839         atexit getpass, strdup, getpagesize.
24840         Replace 'raise'.
24841         Do not check for the following functions, as this is now the job
24842         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
24843         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
24844         setregid.
24845         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
24846         Check for sys/sysctl.h.
24847         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
24848         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
24849         of checking for ssize_t ourselves.
24850
24851         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
24852         Require every macro that gnulib/modules/* suggests for us.
24853         (jm_PREREQ_ADDEXT): New macro.
24854         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
24855         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
24856
24857         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
24858         (gl_PHYSMEM): Use it.
24859         Also check for `table' function.
24860         Check for new headers and functions.
24861         Add check for sys/sysmp.h.
24862         With suggestions from Kaveh Ghazi.
24863         Ignore headers that are present but cannot be compiled.  This
24864         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
24865         C 5.4.
24866
24867 2003-08-15  Paul Eggert  <eggert@twinsun.com>
24868
24869         Document merge from coreutils.
24870         * modules/userspec: Depend on posixver.
24871         * modules/strftime: Depend on tzset.
24872
24873 2003-08-15  Paul Eggert  <eggert@twinsun.com>
24874
24875         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
24876         rather than tab, after '#' in shell-script copyright notices.
24877         Suggested by Bruno Haible.
24878
24879 2003-08-15  Paul Eggert  <eggert@twinsun.com>
24880
24881         * config/srclist-update: Use three spaces, rather than tab, after '#'
24882         in shell-script copyright notices.  Suggested by Bruno Haible.
24883         Remove unnecessary parenthesization in regular expression.
24884
24885 2003-08-15  Jim Meyering  <jim@meyering.net>
24886
24887         Merge from coreutils.
24888         * lib/xgethostname.c: Include <stdlib.h>.
24889         (xghostname): Don't exit for anything other than memory-related
24890         failure; just return NULL.
24891         * lib/userspec.c: Include "posixver.h".
24892         (parse_user_spec): Accept `.' as a separator only
24893         in pre-POSIX-200112 mode.
24894         * lib/strtoimax.c: Use #elif rather than #else #if.
24895         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
24896         Remove function, now that we can rely on a working tzset function.
24897         [!_LIBC]: Ensure that the required autoconf test has been run.
24898         [!defined _NL_CURRENT && HAVE_STRFTIME]:
24899         Use underlying_strftime for %r.
24900         * lib/sha.c: Merge in some clean-up and optimization changes from
24901         glibc.
24902         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
24903         Ensure that it is a multiple of 64.
24904         Rearrange loop exit tests so as to avoid performing an
24905         additional fread after encountering an error or EOF.
24906         * lib/realloc.c: Update copyright date.
24907
24908 2003-08-15  Jim Meyering  <jim@meyering.net>
24909         and Paul Eggert  <eggert@twinsun.com>
24910
24911         Merge from coreutils.
24912         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
24913         member but strut utmpx does not.  Needed for AIX 4.3.3.
24914         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
24915
24916 2003-08-15  Jim Meyering  <jim@meyering.net>
24917         and Paul Eggert  <eggert@cs.ucla.edu>
24918
24919         Merges from coreutils, etc.
24920         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
24921         Require gl_FUNC_TZSET_CLOBBER.
24922         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
24923         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
24924         members.
24925
24926 2003-08-14  Paul Eggert  <eggert@twinsun.com>
24927
24928         Help the merge from coreutils.
24929         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
24930         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
24931         * m4/tzset.m4: Use it too.
24932
24933 2003-08-14  Paul Eggert  <eggert@twinsun.com>
24934
24935         * modules/tzset: New file.
24936
24937 2003-08-14  Jim Meyering  <jim@meyering.net>
24938
24939         Merges from coreutils.
24940         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
24941         variable names, rather than @FNMATCH_H@.
24942         * modules/alloca: Likewise for $(ALLOCA_H).
24943
24944         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
24945         the three copies of the literal target, `fnmatch.h'.
24946         * modules/alloca (alloca.h): Likewise.
24947
24948 2003-08-14  Jim Meyering  <jim@meyering.net>
24949
24950         Merge from coreutils.
24951         * m4/tzset.m4: New file.
24952         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
24953         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
24954         otherwise, AIX 5.1 systems would end up using the latter.
24955         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
24956         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
24957         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
24958         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
24959
24960 2003-08-14  Jim Meyering  <jim@meyering.net>
24961
24962         Merge from coreutils.
24963         * lib/obstack.h: Whitespace changes.
24964         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
24965         and xcalloc return values.
24966         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
24967         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
24968         hang on OSF/1 5.1 for DIR on both local and remote file systems.
24969         Reported by (and fix confirmed by) Nelson H. F. Beebe.
24970         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
24971         error from mntctl.
24972         Use mntctl's return value to drive the entry-processing loop, since
24973         we can't rely on the value of the vmt_length member in the last
24974         entry.  On some systems doing so could result in exhausting
24975         virtual memory.  Based in part on a patch from Mike Jetzer.
24976
24977 2003-08-14  Jim Meyering  <jim@meyering.net>
24978         and Paul Eggert  <eggert@twinsun.com>
24979
24980         Merges from coreutils, plus other fixes.
24981         * lib/physmem.c: Merge in portability changes from gcc/libiberty
24982         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
24983         for credits and details.  Thanks to Kaveh Ghazi for helping
24984         to keep these files in sync.
24985         (ARRAY_SIZE): Define it.
24986         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
24987         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
24988         (memcasecmp): Don't assume size_t fits in unsigned int.
24989         Remove casts and duplicate code.
24990         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
24991         (memcpy): Remove definition.
24992         Merge in some clean-up and optimization changes from glibc.
24993         [BLOCKSIZE]: Move definition to top of file.
24994         Ensure that it is a multiple of 64.
24995         Rearrange loop exit tests so as to avoid performing an
24996         additional fread after encountering an error or EOF.
24997         * lib/md5.h (md5_uintptr): Define.
24998         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
24999         return to the initial working directory.  Preserve errno
25000         for caller.
25001         * lib/idcache.c: Include "xalloc.h".
25002         (xmalloc, xrealloc): Remove decls.
25003         (getuser): Remove casts no longer required in C89.
25004         * lib/human.c: Include stdio.h, for sprintf.
25005         * lib/group-member.c: Include "xalloc.h".
25006         (xmalloc, xrealloc): Remove decls.
25007         (get_group_info): Remove casts no longer required in C89.
25008         * lib/getusershell.c (readname): Remove casts no longer required in
25009         C89.
25010         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
25011         * lib/getline.c: Whitespace fix, from coreutils.
25012
25013 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25014
25015         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
25016         Check for isascii.
25017
25018         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25019         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25020         Undo previous (whitespace-only) change.
25021
25022 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25023
25024         * lib/exclude.c: Include <ctype.h>
25025         (IN_CTYPE_DOMAIN): New macro.
25026         (is_space): New fn.
25027         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
25028         and empty lines.
25029
25030         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25031         Undo previous (whitespace-only) change.
25032
25033 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25034
25035         * config/srclist-update: Change update back to the old behavior,
25036         leaving whitespace alone.  Use one 'sed' command rather than a
25037         pipeline.
25038         (fixlicense): Now a variable, not a function.
25039         (remove_trailing_blanks): Remove.
25040         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
25041         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25042         Undo previous (whitespace-only) change.
25043
25044 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25045
25046         Merge from coreutils.
25047         * modules/euidaccess: Add lib_SOURCES, include for new
25048         file euidaccess.h
25049
25050 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25051
25052         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25053         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25054         Normalize leading white space and remove trailing white space.
25055
25056         Merge from coreutils
25057         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
25058
25059         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
25060         0.12.1.  These files are now being upgraded automatically by
25061         ../config/srclist-update.
25062
25063 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25064
25065         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25066         Normalize leading white space and remove trailing white space.
25067         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
25068         notice, as per ../config/srclist-update.
25069
25070         Merge from coreutils.
25071         * lib/euidaccess.h: New file.
25072         * lib/euidaccess.c: Include it.
25073         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
25074         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
25075         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
25076
25077 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25078
25079         * config/srclist-update: Add copyright notice.
25080         (remove_id_lines, remove_trailing_blanks): New constants.
25081         (fixfile): Use them to normalize spacing a bit in copied files.
25082         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25083         Normalize leading white space and remove trailing white space.
25084
25085         * config/texinfo.tex: Sync with texinfo.
25086
25087         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
25088         strtoul.c from libc, to merge coreutils whitespace changes.
25089
25090         * config/srclist.txt: Get the following m4 files from gettext:
25091         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
25092         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
25093         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
25094         wint_t.m4.
25095
25096 2003-08-12  Karl Berry  <karl@gnu.org>
25097
25098         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
25099         been made.
25100
25101 2003-08-11  Paul Eggert  <eggert@twinsun.com>
25102
25103         * modules/gnu-source, m4/gnu-source.m4:
25104         Remove; we're assuming Autoconf 2.54 or later now.
25105         Suggested by Bruno Haible.
25106         * MODULES.html.sh (func_all_modules): Remove gnu-source.
25107
25108 2003-08-11  Bruno Haible  <bruno@clisp.org>
25109
25110         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
25111
25112 2003-08-11  Bruno Haible  <bruno@clisp.org>
25113
25114         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
25115         (vasnprintf): Use it instead of wcslen.
25116
25117 2003-08-11  Bruno Haible  <bruno@clisp.org>
25118
25119         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
25120         value to ensure that _Bool promotes to int. Use #define for _Bool when
25121         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
25122
25123 2003-08-10  Karl Berry  <karl@gnu.org>
25124
25125         * lib/regex.h: update from libc (whitespace fix).
25126
25127 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25128
25129         Merge some files from coreutils.  These changes were
25130         originally made by Jim Meyering.
25131         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
25132         many older Unixes require this.
25133         * lib/alloca.c (alloca): Remove cast to argument of free;
25134         no longer needed in C89.
25135         * lib/alloca_.h, regex.h: Fix white space to match
25136         what GNU indent does.
25137
25138 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25139
25140         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
25141         apparently Emacs's Unicode mode got confused before my 2003-08-05
25142         checkin.
25143
25144 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25145
25146         * m4/extensions.m4: New file.
25147         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
25148         Require gl_USE_SYSTEM_EXTENSIONS.
25149         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
25150         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
25151
25152 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25153
25154         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
25155         * modules/extensions, modules/gnu-source: New files.
25156         * modules/timespec, modules/unlocked-io: Depend on extensions.
25157
25158 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25159
25160         * modules/restrict: New file.
25161         * MODULES.html.sh (func_all_modules): Add restrict.
25162         * modules/regex: Depend on restrict.
25163
25164 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25165
25166         * m4/restrict.m4: New file.
25167         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
25168
25169 2003-08-07  Bruno Haible  <bruno@clisp.org>
25170
25171         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
25172         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
25173
25174 2003-08-07  Bruno Haible  <bruno@clisp.org>
25175
25176         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
25177         makes the module 'getndelim2' compatible with the module 'getline'.
25178
25179 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25180
25181         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
25182         byte with "\201" to avoid glitches when editing that source file
25183         with multi-gnome-terminal.
25184
25185 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25186
25187         * lib/bumpalloc.h: Remove.
25188
25189 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25190
25191         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
25192         * modules/bumpalloc: Remove.
25193
25194 2003-08-04  Paul Eggert  <eggert@twinsun.com>
25195
25196         * lib/getloadavg.c: Change copyright notice and spacing to conform to
25197         GNU coding style.
25198
25199         Merge from coreutils.
25200         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
25201         1. From glibc.
25202         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
25203         from Karl Berry, implemented by Jim Meyering.
25204         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
25205         from Dmitry V. Levin.
25206         Remove anachronistic cast of xrealloc.
25207         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
25208         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
25209         type. Otherwise, it wouldn't compile with at least /bin/cc on
25210         ymp-cray-unicos9.0.2.X.
25211         Combine two mostly-identical uses of alloca into one.
25212         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
25213
25214 2003-08-04  Dave Love  <d.love@dl.ac.uk>
25215
25216         [From Emacs.]
25217
25218         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
25219         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
25220         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
25221         obsolete NLIST_NAME_UNION.
25222         [__GNU__]: Undef BSD and FSCALE.
25223         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
25224
25225 2003-08-03  Paul Eggert  <eggert@twinsun.com>
25226
25227         * lib/stdbool_.h (_Bool): Make it signed char, instead of
25228         an enum type, so that it's guaranteed to promote to int.  See:
25229         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
25230
25231 2003-08-03  Karl Berry  <karl@gnu.org>
25232
25233         * config/depcomp: update from automake.
25234
25235 2003-07-31  Paul Eggert  <eggert@twinsun.com>
25236
25237         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
25238         (strerror): Don't assume that a printable int fits in 14 bytes.
25239
25240 2003-07-31  Bruno Haible  <bruno@clisp.org>
25241
25242         * modules/getpass-gnu: New file.
25243         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
25244
25245 2003-07-31  Bruno Haible  <bruno@clisp.org>
25246
25247         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
25248
25249 2003-07-24  Karl Berry  <karl@gnu.org>
25250
25251         * config/missing: update from automake.
25252
25253 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
25254             Bruno Haible  <bruno@clisp.org>
25255
25256         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
25257         * lib/getline.c (getline, getdelim): Likewise.
25258         Remove _GNU_SOURCE define; now it's defined in config.h through
25259         m4/getline.m4.
25260
25261 2003-07-23  Karl Berry  <karl@gnu.org>
25262
25263         * config/config.sub: update from prep.
25264
25265 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25266
25267         * modules/xalloc (Depends-on): Add exitfail.
25268         * modules/xmemcoll: Likewise.
25269
25270 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25271
25272         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
25273         over-parenthesization in macros.
25274
25275         Sync with coreutils.
25276
25277         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
25278         required by C99.
25279
25280         Use `exit_failure' for xalloc and xmemcoll instead of their own
25281         private exit-failure variables.
25282         * lib/xalloc.h (xalloc_exit_failure): Remove.
25283         * lib/xmalloc.c: Likewise.  Include exitfail.h.
25284         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
25285         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
25286         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
25287         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
25288
25289 2003-07-20  Jim Meyering  <jim@meyering.net>
25290
25291         * modules/closeout (Depends-on): Add exitfail.
25292         Suggestion from Bruno Haible.
25293
25294 2003-07-19  Karl Berry  <karl@gnu.org>
25295
25296         * config/config.sub: update from prep.
25297
25298 2003-07-18  Paul Eggert  <eggert@twinsun.com>
25299
25300         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
25301         Remove.
25302         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
25303         to test that it can stand by itself.  Include "exitfail.h".
25304         Clients should set exit_failure instead.
25305         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
25306
25307 2003-07-18  Bruno Haible  <bruno@clisp.org>
25308
25309         * modules/getndelim2: New file.
25310         * modules/getline: Share files with module getndelim2.
25311         * modules/getnline: Depend on getndelim2 instead of sharing files with
25312         it. Add getnline.c to lib_SOURCES.
25313         * MODULES.html.sh (func_all_modules): Add getndelim2.
25314
25315 2003-07-18  Bruno Haible  <bruno@clisp.org>
25316
25317         * m4/getndelim2.m4: New file.
25318         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
25319         invoke gl_PREREQ_GETNDELIM2.
25320         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
25321         gl_PREREQ_GETNDELIM2.
25322         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
25323         gl_GETNDELIM2.
25324
25325 2003-07-18  Bruno Haible  <bruno@clisp.org>
25326
25327         * lib/getndelim2.h: New file.
25328         * lib/getndelim2.c: Make into a module of its own. Include config.h,
25329         getndelim2.h.
25330         (getndelim2): Make non-static. Change return type to ssize_t.
25331         * lib/getline.h: Change argument names.
25332         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
25333         * lib/getnline.c: Include getndelim2.h.
25334
25335 2003-07-18  Andreas Schwab  <schwab@suse.de>
25336
25337         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
25338
25339 2003-07-17  Karl Berry  <karl@gnu.org>
25340
25341         * config/config.sub: update from prep.
25342
25343 2003-07-17  Bruno Haible  <bruno@clisp.org>
25344
25345         * modules/getnline: New file.
25346         * modules/getline: Add lib/getndelim2.c to source file list.
25347         * MODULES.html.sh (func_all_modules): Add getnline.
25348
25349 2003-07-17  Bruno Haible  <bruno@clisp.org>
25350
25351         * m4/getnline.m4: New file.
25352
25353 2003-07-17  Bruno Haible  <bruno@clisp.org>
25354
25355         * m4/Makefile.am.in: Remove file.
25356         * m4/Makefile.am: Remove file.
25357         * m4/Makefile.in: Remove file.
25358
25359 2003-07-17  Bruno Haible  <bruno@clisp.org>
25360
25361         * lib/getnline.h: New file.
25362         * lib/getnline.c: New file.
25363         * lib/getndelim2.c: New file, extracted from getline.c.
25364         (getndelim2): Renamed from getdelim2, with added nmax argument.
25365         * lib/getline.c: Include getndelim2.c.
25366         (getdelim2): Moved out to getndelim2.c.
25367         (getline, getdelim): Update.
25368
25369 2003-07-17  Bruno Haible  <bruno@clisp.org>
25370
25371         * lib/Makefile.am: Remove file.
25372         * lib/Makefile.in: Remove file.
25373
25374 2003-07-17  Bruno Haible  <bruno@clisp.org>
25375
25376         * configure.in: Remove file.
25377         * Makefile.in: Remove file.
25378
25379 2003-07-17  Bruno Haible  <bruno@clisp.org>
25380
25381         * MODULES.html.sh: Put the </BODY> right before </HTML>.
25382
25383 2003-07-16  Karl Berry  <karl@gnu.org>
25384
25385         * config/srclist-update: was running fixlicense twice, which caused
25386                 texinfo.tex to be nullified for some reason.  Simplify,
25387                 $gplsrc is no longer needed as far as I can see?
25388
25389 2003-07-16  Jim Meyering  <jim@meyering.net>
25390
25391         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
25392
25393 2003-07-15  Paul Eggert  <eggert@twinsun.com>
25394
25395         * config/srclist.txt: Get the following files from gettext-runtime/intl
25396         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
25397         ref-del.sin.  From Bruno Haible.
25398         * config/srclist-update (fixfile): Change grep pattern again, since the
25399         previous fix didn't work (there was another trailing $).  Use
25400         '[$]' to escape the $s.
25401
25402 2003-07-15  Karl Berry  <karl@gnu.org>
25403
25404         * lib/vasnprintf.c: update from gettext.
25405
25406 2003-07-15  Karl Berry  <karl@gnu.org>
25407
25408         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
25409         gets expanded when surrounded by '$'.
25410
25411 2003-07-15  Jim Meyering  <jim@meyering.net>
25412
25413         * modules/save-cwd: Don't depend on error.  From Derek Price.
25414
25415 2003-07-15  Jim Meyering  <jim@meyering.net>
25416
25417         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
25418
25419 2003-07-14  Simon Josefsson  <jas@extundo.com>
25420
25421         * modules/mempcpy: New file.
25422         * MODULES.html.sh (func_all_modules): Add mempcpy.
25423
25424 2003-07-14  Simon Josefsson  <jas@extundo.com>
25425
25426         * m4/mempcpy.m4: New file.
25427
25428 2003-07-14  Simon Josefsson  <jas@extundo.com>
25429
25430         * lib/mempcpy.h: New file.
25431         * lib/mempcpy.c: New file.
25432
25433 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25434
25435         * modules/getdate, modules/posixtm: Depend on mktime.
25436
25437 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25438
25439         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
25440         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
25441         unicodeio.c, unicodeio.h, unlocked-io.h:
25442         Switch from LGPL to GPL.
25443
25444 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25445
25446         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
25447         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
25448         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
25449         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
25450         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
25451         updated automatically by ../config/srclist-update.  This changes
25452         their license from LPGL to GPL.
25453
25454 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25455
25456         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
25457         assumed to refer to the root of the most recent stable gettext version.
25458         * config/srclistvars.sh: Add defaults for eggert.
25459         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
25460         Match "This program" as well as "The program".  This is needed
25461         for gettext.
25462
25463 2003-07-14  Jim Meyering  <jim@meyering.net>
25464
25465         Don't emit diagnostics.  Let callers do that.
25466         * lib/save-cwd.c: Don't include "error.h".
25467         (save_cwd): Don't call error.  Ensure that errno is valid
25468         when returning nonzero.
25469
25470         * lib/save-cwd.h (restore_cwd): Update prototype.
25471         * lib/save-cwd.c (restore_cwd): Remove two parameters.
25472         Simplify.  Don't call error upon failure.  Let callers do that.
25473         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
25474         when auditing is enabled.  But don't bother updating the #if.
25475
25476 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
25477
25478         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
25479         it breaks C++ compilation.
25480         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
25481
25482 2003-07-10  Simon Josefsson  <jas@extundo.com>
25483
25484         * modules/strchrnul (Makefile.am): Add strchrnul.h.
25485
25486 2003-07-10  Jim Meyering  <jim@meyering.net>
25487
25488         * m4/clock_time.m4: Remove trailing blank.
25489         * m4/intmax_t.m4: Likewise.
25490
25491 2003-07-10  Jim Meyering  <jim@meyering.net>
25492
25493         * lib/vasnprintf.c: Remove trailing blanks.
25494         Make cpp indentation consistent.
25495
25496 2003-07-09  Paul Eggert  <eggert@twinsun.com>
25497
25498         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
25499         posixver.c, strftime.c, strnlen.c, strverscmp.c:
25500         Switch from LGPL to GPL.
25501
25502 2003-07-09  Paul Eggert  <eggert@twinsun.com>
25503
25504         * config/srclist.txt: Sort sublists.  Add
25505         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
25506         that differ from gnulib for one reason or another; we'd like this list
25507         to be smaller but for now let's document what we have.
25508
25509 2003-07-08  Paul Eggert  <eggert@twinsun.com>
25510
25511         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
25512         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
25513         and sweeter "eval x=$x".
25514         * config/srclist.txt: Get lib/argp* from glibc.
25515
25516 2003-07-07  Paul Eggert  <eggert@twinsun.com>
25517
25518         * lib/mktime.c: Fix some boundary cases and remove need for floating
25519         point.
25520
25521         Issue a compile-time diagnostic if time_t is floating point, or if
25522         two's complement arithmetic is not in effect, or if arithmetic
25523         right shift does not propagate the sign.  These assumptions were
25524         all in the original code but they weren't checked.
25525
25526         (TIME_T_MIDPOINT, verify): New macros.
25527         (__isleap): Remove; it has integer overflow problems.
25528         (leapyear): New function, without those problems.
25529         (ydhms_tm_diff): Remove; splitting into two parts.
25530         (ydhms_diff): New function, containing the arithmetic part of
25531         the old ydhms_tm_diff function.  Issue a compile-time
25532         diagnostic if we are not using C99 integer division.
25533         Avoid casts when possible.
25534         (guess_time_tm): New function, containing the checking part of
25535         the old ydhms_tm_diff function.  Return the new value, rather than
25536         the difference between it and the old.  Accept a new argument T
25537         so that *T specifies the old value.  Check for overflow in the result.
25538
25539         (__mktime_internal): Use a time_t offset, not a long int offset.
25540         This undoes the 2003-06-04 change, which is no longer needed now
25541         that we have better overflow checking.
25542         (localtime_offset): Likewise.
25543
25544         (__mktime_internal): Avoid harmful overflow on hosts where time_t
25545         and long are 64-bit but int is only 32-bit.
25546         (ydhms_diff): Use long int to store year1 and yday1.
25547         Issue a compile-time diagnostic if long int is not wide enough.
25548
25549         (__mktime_internal): Use long int to store adjusted year and yday.
25550         Use plain C rather than preprocessor commands, if that doesn't
25551         affect efficiency.
25552         Check for overflow (and try to repair) after each probe
25553         rather than checking only at the very end.  This avoids some bugs
25554         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
25555         does not equal GMT offset at maximum time).
25556         Use integer to check for overflow rather than floating point; this
25557         is more portable to non-IEEE hosts, and is a tad faster.
25558         When we detect that we are oscillating between two values,
25559         don't check whether tm_isdst has the requested value, since
25560         we already know the answer.  When tm_isdst has the wrong value,
25561         use a different heuristic to find the right one, based on the
25562         extreme values actually observed in practice in tz2003a,
25563         rather than the (overly optimistic) "previous 3 calendar quarters".
25564
25565         (not_equal_tm, print_tm, check_result): Use "const T" rather than
25566         "T const" to accommodate glibc style.
25567         (check_result): Use less-confusing report format.  "long" -> "long int.
25568         (main): Likewise.
25569         Don't loop if the iteration overflows time_t.
25570         Allow a negative step in the iteration.
25571
25572 2003-07-06  Karl Berry  <karl@gnu.org>
25573
25574         * config/depcomp: update from automake.
25575         * config/config.sub: update from prep.
25576
25577 2003-07-03  Karl Berry  <karl@gnu.org>
25578
25579         * config/config.guess: update from prep.
25580
25581 2003-07-01  Paul Eggert  <eggert@twinsun.com>
25582
25583         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
25584         xreadlink.c now includes it unconditionally.
25585
25586 2003-07-01  Paul Eggert  <eggert@twinsun.com>
25587
25588         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
25589         having it depend on HAVE_SYS_TYPES_H.
25590
25591 2003-07-01  Bruno Haible  <bruno@clisp.org>
25592
25593         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
25594         <sys/types.h> should be sufficient.
25595         Reported by Paul Eggert.
25596
25597 2003-06-26  Karl Berry  <karl@gnu.org>
25598
25599         * config/depcomp: update from automake.
25600
25601 2003-06-26  Bruno Haible  <bruno@clisp.org>
25602
25603         * modules/human: Depend on module stdbool.
25604
25605 2003-06-25  Bruno Haible  <bruno@clisp.org>
25606
25607         * modules/readlink: New file.
25608         * modules/xreadlink: Depend on it.
25609         * MODULES.html.sh (func_all_modules): Add readlink.
25610
25611 2003-06-25  Bruno Haible  <bruno@clisp.org>
25612
25613         * m4/readlink.m4: New file.
25614
25615 2003-06-25  Bruno Haible  <bruno@clisp.org>
25616
25617         * lib/readlink.c: New file.
25618
25619 2003-06-22  Karl Berry  <karl@gnu.org>
25620
25621         * config/srclist.txt: update mkinstalldirs from automake.
25622         * config/mkinstalldirs: update.
25623
25624 2003-06-22  Bruno Haible  <bruno@clisp.org>
25625
25626         Portability to mingw32.
25627         * m4/ssize_t.m4: New file, from GNU gettext.
25628         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
25629         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
25630
25631 2003-06-22  Bruno Haible  <bruno@clisp.org>
25632
25633         * modules/safe-read: Add m4/ssize_t.m4.
25634         * modules/xreadlink: Add m4/ssize_t.m4.
25635
25636 2003-06-20  Bruno Haible  <bruno@clisp.org>
25637
25638         Assume C89, so PARAMS isn't needed.
25639         * lib/unicodeio.h (PARAMS): Remove.
25640         * lib/unicodeio.c: Don't use PARAMS.
25641
25642 2003-06-18  Karl Berry  <karl@gnu.org>
25643
25644         * config/config.{guess,sub}: update from prep.
25645
25646 2003-06-18  Jim Meyering  <jim@meyering.net>
25647
25648         Merge changes from coreutils.
25649         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
25650         Remove explicit declarations of xmalloc and realloc.
25651         Include xalloc.h.
25652         (read_utmp): Remove anachronistic cast of xmalloc.
25653
25654 2003-06-17  Paul Eggert  <eggert@twinsun.com>
25655
25656         Assume C89, so PARAMS isn't needed.
25657         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
25658         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
25659         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
25660         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
25661         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
25662         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
25663         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
25664         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
25665         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
25666         lib/xstrtod.h, lib/xstrtol.h: Likewise.
25667         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
25668         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
25669         no longer needed. Anyway, config.h should always be included before any
25670         other file.
25671
25672 2003-06-11  Simon Josefsson  <jas@extundo.com>
25673
25674         * modules/sysexits: New file.
25675         * MODULES.html.sh (func_all_modules): Add sysexits.
25676
25677 2003-06-11  Simon Josefsson  <jas@extundo.com>
25678
25679         * lib/sysexit_.h: New file.
25680
25681 2003-06-11  Derek Price  <derek@ximbiot.com>
25682
25683         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
25684         necessary.
25685
25686 2003-06-11  Bruno Haible  <bruno@clisp.org>
25687
25688         * m4/sysexits.m4: New file.
25689
25690 2003-06-10  Simon Josefsson  <jas@extundo.com>
25691
25692         * lib/argp.h: New file, from glibc.
25693         * lib/argp-ba.c: New file, from glibc.
25694         * lib/argp-eexst.c: New file, from glibc.
25695         * lib/argp-fmtstream.c: New file, from glibc.
25696         * lib/argp-fmtstream.h: New file, from glibc.
25697         * lib/argp-fs-xinl.c: New file, from glibc.
25698         * lib/argp-help.c: New file, from glibc.
25699         * lib/argp-namefrob.h: New file, from glibc.
25700         * lib/argp-parse.c: New file, from glibc.
25701         * lib/argp-pv.c: New file, from glibc.
25702         * lib/argp-pvh.c: New file, from glibc.
25703         * lib/argp-xinl.c: New file, from glibc.
25704
25705 2003-06-10  Simon Josefsson  <jas@extundo.com>
25706
25707         * modules/strchrnul: New file.
25708
25709 2003-06-10  Simon Josefsson  <jas@extundo.com>
25710
25711         * modules/argp: New file.
25712
25713 2003-06-10  Simon Josefsson  <jas@extundo.com>
25714
25715         * m4/strchrnul.m4: New file.
25716
25717 2003-06-10  Simon Josefsson  <jas@extundo.com>
25718
25719         * lib/strchrnul.h: New file.
25720         * lib/strchrnul.c: New file.
25721
25722 2003-06-10  Bruno Haible  <bruno@clisp.org>
25723
25724         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
25725
25726 2003-06-07  Karl Berry  <karl@gnu.org>
25727
25728         * config/config.{guess,sub}: update from prep.
25729
25730 2003-06-07  Jim Meyering  <jim@meyering.net>
25731
25732         * modules/strtod: Use $(...) notation, not @...@ for
25733         AC_REPLACE'd variables.
25734         * modules/localcharset: Likewise.
25735
25736 2003-06-07  Jim Meyering  <jim@meyering.net>
25737
25738         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
25739         in place of my name in the copyright comment.
25740         Remove definition and uses of __P.
25741
25742         From coreutils.
25743         * lib/stat.c: Don't declare xmalloc explicitly.
25744         Instead, include "xalloc.h".
25745         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
25746         xrealloc, and xcalloc return values.
25747         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
25748         Improve comment.
25749         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
25750
25751 2003-06-07  Bruno Haible  <bruno@clisp.org>
25752
25753         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
25754         avoid AC_CONFIG_LINKS.
25755         * modules/fnmatch (Makefile.am): Use explicit creation rule for
25756         fnmatch.h, to avoid AC_CONFIG_LINKS.
25757         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
25758
25759 2003-06-07  Bruno Haible  <bruno@clisp.org>
25760
25761         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
25762         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
25763         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
25764         directory.
25765         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
25766         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
25767         directory.
25768
25769 2003-06-06  Jim Meyering  <jim@meyering.net>
25770
25771         Merge from coreutils.
25772         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
25773         Consolidate declarations and initializations of *_base* locals.
25774
25775         Merge from coreutils.
25776         This avoids a core dump on systems without GNU putenv,
25777         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
25778         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
25779         (unsetenv): New static function, from GNU libc.
25780         (rpl_putenv): Use it.
25781
25782         * lib/modechange.c: Remove trailing blanks.
25783
25784         Merge from coreutils.
25785         * lib/fsusage.c: Remove declaration of statfs.
25786         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
25787
25788         * lib/posixtm.c: Include <stdbool.h> unconditionally.
25789
25790 2003-06-06  Jim Meyering  <jim@meyering.net>
25791
25792         * lib/stdbool_.h: Renamed from stdbool.h.in.
25793
25794 2003-06-06  Jim Meyering  <jim@meyering.net>
25795             Bruno Haible  <bruno@clisp.org>
25796
25797         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
25798         Adjust Makefile.am snippet not to redirect directly to target.
25799         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
25800
25801 2003-06-05  Paul Eggert  <eggert@twinsun.com>
25802
25803         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
25804         mismatch, look in future quarters as well as past.  This fixes a
25805         bug when processing fall-backwards gaps immediately after a long
25806         period of daylight-saving time.
25807
25808         * lib/mktime.c: Assume freestanding C89 or better.
25809         (HAVE_LIMITS_H): Remove.  Assume it's 1.
25810         (__P): Remove; not used.
25811         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
25812         (mktime, not_equal_tm, print_tm, check_result,
25813         main): Use prototypes.  Use const * where appropriate.
25814         (main): Fix typo in testing code that uncovered by above changes.
25815         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
25816
25817 2003-06-04  Paul Eggert  <eggert@twinsun.com>
25818
25819         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
25820         locale.h, localeconv.  This merges changes from coreutils.
25821
25822         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
25823         It can be removed after the next Autoconf is released.
25824         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
25825         needed.
25826
25827 2003-06-04  Paul Eggert  <eggert@twinsun.com>
25828
25829         * lib/mktime.c: Fix Debian bug 177940
25830         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
25831         (localtime_offset): Now long int, not time_t, because we want it
25832         to be guaranteed to be signed.  All uses changed.
25833         (__mktime_internal): If overflow would occur when adding offset,
25834         don't add it.
25835
25836         Merge 'human' changes from coreutils.  Rewrite to support
25837         locale-specific notations like thousands separators.
25838         * lib/human.c: Simplify authorship notice.
25839         Include human.h immediately after config.h.
25840         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
25841         <limits.h>: Do not include, since human.h does.
25842         (SIZE_MAX, UINTMAX_MAX): New macros.
25843         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
25844         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
25845         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
25846         (power_letter): Renamed from suffixes.
25847         (generate_suffix_backwards): Remove.
25848         (adjust_value): Now takes int style (because of human.h changes)
25849         and long double value (for greater precision on some platforms).
25850         (group_number): New function.
25851         (human_readable): Use it.  Use integer options, not enum.
25852         Put the options before the sizes in the arg list.
25853         Support all the new options.
25854         The old human_readable function has been removed;
25855         use inttostr.h instead.
25856         (human_readable, default_block_size, humblock):
25857         Use uintmax_t, not int, for block sizes.
25858         (human_readable_inexact, block_size_types): Remove.
25859         (block_size_opts): New constant.
25860         (human_options): Renamed from human_block_size, with new signature
25861         that allows block sizes up to UINTMAX_MAX.  All callers changed.
25862         * lib/human.h: Add copyright and authorship notice.
25863         Include <limits.h> and <stdbool.h> unconditionally.
25864         (PARAMS): Remove.  All uses removed.
25865         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
25866         (enum human_inexact_style): Remove tag; now a nameless enum.
25867         (human_floor, human_ceiling, human_round_to_even): Now have
25868         values 2, 0, 1 rather than -1, 1, 0.
25869         (human_group_digits, human_suppress_point_zero, human_autoscale,
25870         human_base_1024, human_SI, human_B): New constants.
25871         (human_readable_inexact, human_block_size): Remove.
25872         (human_readable): Size args are now uintmax_t, not int.
25873         (human_options): New decl.
25874
25875         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
25876         unnecessary now that we assume C89 or better.  This change
25877         imported from coreutils.
25878
25879         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
25880         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
25881         in the 2003-05-30 sync from glibc.
25882
25883         .h files should stand alone, but we shouldn't include <sys/types.h>
25884         if we can get away with just <stddef.h>.
25885
25886         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
25887         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
25888         rather than <sys/types.h>, as we merely need size_t.
25889         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
25890         to get size_t.
25891         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
25892         Include <stdio.h>, to get FILE.
25893         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
25894         memcasecmp.h has included <stddef.h> and all we need is size_t.
25895         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
25896         our interface, instead of including <sys/types.h>
25897
25898 2003-06-04  Paul Eggert  <eggert@twinsun.com>
25899
25900         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
25901         now, as glibc mktime is buggy on non-glibc systems.
25902
25903 2003-06-03  Karl Berry  <karl@gnu.org>
25904
25905         * config/config.sub: update from prep.
25906
25907 2003-06-02  Paul Eggert  <eggert@twinsun.com>
25908
25909         [from coreutils]
25910         Fix some minor time-related bugs with POSIX time arguments.
25911         Some valid time stamps were being rejected (notably -1, and
25912         time stamps before 1900 on 64-bit hosts).  And some invalid
25913         time stamps were being accepted, e.g. September 31.
25914
25915         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
25916         that we can return (time_t) -1 successfully.
25917         * lib/posixtm.c: Likewise.
25918         [HAVE_STDBOOL_H]: Include <stdbool.h>.
25919         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
25920         (t): Remove static var.
25921         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
25922         of static var.  All uses changed.
25923         (year): Do not reject years before 1900; they can occur with
25924         64-bit time_t.
25925         (posix_time_parse): Do not check for out-of-range components;
25926         that is now the caller's responsibility, since our checks were
25927         only approximations.
25928         (posixtime): Use mktime to check for out-of-range components,
25929         since it knows them exactly.
25930         If mktime returns (time_t) -1, check whether an error actually occurred
25931         by invoking localtime on -1.
25932         (main) [TEST_POSIXTIME]: Check for input data errors, and report
25933         posixtime failures better.
25934         Improve the test data (in comments only).
25935
25936 2003-06-02  Karl Berry  <karl@gnu.org>
25937
25938         * config/mkinstalldirs (version): new variable.
25939         (--version): new option.
25940         (usage): improve message.
25941
25942 2003-05-30  Karl Berry  <karl@gnu.org>
25943
25944         * lib/mktime.c: update from libc.
25945
25946 2003-05-30  Bruno Haible  <bruno@clisp.org>
25947
25948         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
25949         * config/config.rpath: Upgrade to gettext-0.12.1.
25950
25951 2003-05-30  Bruno Haible  <bruno@clisp.org>
25952
25953         * m4/gettext.m4: Upgrade to gettext-0.12.1.
25954         * m4/nls.m4: New file, from gettext-0.12.1.
25955         * m4/po.m4: New file, from gettext-0.12.1.
25956         * m4/progtest.m4: Upgrade to gettext-0.12.1.
25957
25958 2003-05-30  Bruno Haible  <bruno@clisp.org>
25959
25960         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
25961         * lib/localcharset.h: Likewise.
25962         * lib/localcharset.c: Likewise.
25963
25964 2003-05-29  Karl Berry  <karl@gnu.org>
25965
25966         * config/config.rpath: update from gettext.
25967
25968 2003-05-28  Paul Eggert  <eggert@twinsun.com>
25969
25970         Assume the headers required for C89 freestanding compilers.
25971         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
25972         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
25973         * m4/human.m4 (gl_HUMAN): Likewise.
25974         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
25975         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
25976         * m4/userspec.m4 (gl_USERSPEC): Likewise.
25977         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
25978         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
25979         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
25980
25981 2003-05-28  Paul Eggert  <eggert@twinsun.com>
25982
25983         Assume the headers required for C89 freestanding compilers.
25984         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
25985         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
25986         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
25987         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
25988         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
25989         define, since <limits.h> is guaranteed to do that.
25990         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
25991         * lib/exclude.c: Include <stdbool.h> unconditionally.
25992         * lib/tempname.c: Include <stddef.h> unconditionally.
25993         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
25994         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
25995         <stddef.h> does that.
25996         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
25997         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
25998         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
25999         needed.
26000         * lib/xstrtol.c: Likewise.
26001         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
26002         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
26003
26004         * lib/addext.c (addext): Use assignment rather than cast, to avoid
26005         warnings on some platforms.
26006
26007         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26008         arbitrarily.
26009
26010 2003-05-26  Jim Meyering  <jim@meyering.net>
26011
26012         Merge in a change from coreutils:
26013         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
26014         that is guaranteed to be `no'.  Use `no_such_member' to indicate
26015         that condition, rather than `-1' which is slightly misleading.
26016         Change the name of the cache variable to have the gl_ prefix.
26017         Prompted by a patch from Richard Dawe for DJGPP.
26018
26019 2003-05-24  Karl Berry  <karl@gnu.org>
26020
26021         * config/config.guess: update from prep.
26022
26023 2003-05-22  Karl Berry  <karl@gnu.org>
26024
26025         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
26026
26027 2003-05-20  Karl Berry  <karl@gnu.org>
26028
26029         * config/config.guess: update from prep.
26030
26031 2003-05-18  Karl Berry  <karl@gnu.org>
26032
26033         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
26034         might actually be set by the user.
26035
26036         * config/depcomp, install-sh, mdate-sh: update from automake.
26037
26038 2003-05-17  Bruno Haible  <bruno@clisp.org>
26039
26040         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
26041         invalid expansion for AC_EGREP_CPP.
26042         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
26043         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
26044         Suggested by Akim Demaille <akim@epita.fr> in
26045         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
26046
26047 2003-05-12  Jim Meyering  <jim@meyering.net>
26048
26049         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
26050         the space-padded-by-default conversion specifiers, %e, %k, %l.
26051
26052 2003-05-12  Bruno Haible  <bruno@clisp.org>
26053
26054         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
26055         the string is longer than 4 KB.
26056
26057 2003-05-11  Karl Berry  <karl@gnu.org>
26058
26059         * config/config.{guess,sub}: update from prep.
26060
26061 2003-05-09  Bruno Haible  <bruno@clisp.org>
26062
26063         * modules/error: Add m4/strerror_r.m4 to file list.
26064
26065 2003-05-03  Bruno Haible  <bruno@clisp.org>
26066
26067         Upgrade to Unicode-4.0.
26068         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
26069         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
26070         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
26071         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
26072         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
26073         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
26074         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
26075         Change width of U+E0100..U+E01EF from 1 to 0.
26076
26077 2003-04-25  Jim Meyering  <jim@meyering.net>
26078
26079         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
26080         of type size_t, not int.
26081
26082 2003-04-25  Bruno Haible  <bruno@clisp.org>
26083
26084         * lib/copy-file.c: Include <stddef.h>, for size_t.
26085
26086 2003-04-21  Paul Eggert  <eggert@twinsun.com>
26087
26088         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
26089         code which expansion is under static control.  Patch imported from
26090         Akim Demaille's patch to Bison; see
26091         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
26092
26093 2003-04-14  Bruno Haible  <bruno@clisp.org>
26094
26095         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
26096
26097 2003-04-11  Jim Meyering  <jim@meyering.net>
26098
26099         Merge changes from Coreutils.
26100
26101         2003-03-22  Jim Meyering  <jim@meyering.net>
26102
26103         * lib/strftime.c (widen): Cast alloca return value to proper type.
26104
26105         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
26106
26107         From GNU libc.
26108         * lib/strftime.c (my_strftime): Handle very large width
26109         specifications for numeric values correctly.  Improve checks for
26110         overflow.
26111
26112         2003-01-19  Jim Meyering  <jim@meyering.net>
26113
26114         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
26115         definitions.
26116         (nl_get_alt_digit) [! defined my_strftime]: Define.
26117         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
26118         _nl_get_alt_digit and _nl_get_walt_digit.
26119
26120         * lib/strftime.c (my_strftime): Merge in locale-related changes from
26121         libc. These changes have no effect outside of _LIBC.
26122
26123 2003-04-10  Bruno Haible  <bruno@clisp.org>
26124
26125         * modules/findprog: New file.
26126         * MODULES.html.sh (func_all_modules): Add it.
26127
26128 2003-04-10  Bruno Haible  <bruno@clisp.org>
26129
26130         * m4/findprog.m4: New file.
26131         * m4/eaccess.m4: New file.
26132
26133 2003-04-10  Bruno Haible  <bruno@clisp.org>
26134
26135         * lib/findprog.h: New file, from GNU gettext.
26136         * lib/findprog.c: New file, from GNU gettext.
26137
26138 2003-04-05  Jim Meyering  <jim@meyering.net>
26139
26140         Merge changes from Coreutils.
26141
26142         * lib/exclude.h (PARAMS): Remove definition and uses.
26143         * lib/exclude.c: Remove uses of `PARAMS'.
26144
26145         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
26146         Add test-cases for DOS filenames. Declare program_name.
26147         (main): Set up program_name.  Patch by Rich Dawe.
26148
26149         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
26150         error from mntctl.
26151         Use mntctl's return value to drive the entry-processing loop, since
26152         we can't rely on the value of the vmt_length member in the last
26153         entry.  On some systems doing so could result in exhausting
26154         virtual memory.  Based in part on a patch from Mike Jetzer.
26155
26156 2003-04-04  Bruno Haible  <bruno@clisp.org>
26157
26158         * modules/linebreak: New file.
26159         * MODULES.html.sh (func_all_modules): Add it.
26160
26161 2003-04-04  Bruno Haible  <bruno@clisp.org>
26162
26163         * m4/linebreak.m4: New file.
26164
26165 2003-04-04  Bruno Haible  <bruno@clisp.org>
26166
26167         * lib/linebreak.h: New file, from GNU gettext.
26168         * lib/linebreak.c: New file, from GNU gettext with slight
26169         modifications.
26170         * lib/lbrkprop.h: New file, from GNU gettext.
26171
26172 2003-04-03  Bruno Haible  <bruno@clisp.org>
26173
26174         * modules/utf8-ucs4: New file.
26175         * modules/utf16-ucs4: New file.
26176         * modules/ucs4-utf8: New file.
26177         * modules/ucs4-utf16: New file.
26178         * MODULES.html.sh (func_all_modules): Add them.
26179
26180 2003-04-03  Bruno Haible  <bruno@clisp.org>
26181
26182         * m4/utf-ucs4.m4: New file.
26183         * m4/ucs4-utf.m4: New file.
26184
26185 2003-04-03  Bruno Haible  <bruno@clisp.org>
26186
26187         * lib/utf8-ucs4.h: New file, from GNU gettext.
26188         * lib/utf16-ucs4.h: New file, from GNU gettext.
26189         * lib/ucs4-utf8.h: New file, from GNU gettext.
26190         * lib/ucs4-utf16.h: New file, from GNU gettext.
26191
26192 2003-04-02  Bruno Haible  <bruno@clisp.org>
26193
26194         * modules/binary-io: New file.
26195         * MODULES.html.sh (func_all_modules): Add it.
26196
26197 2003-04-02  Bruno Haible  <bruno@clisp.org>
26198
26199         * lib/binary-io.h: New file, from GNU gettext.
26200
26201 2003-04-01  Bruno Haible  <bruno@clisp.org>
26202
26203         * modules/pathname: New file.
26204         * MODULES.html.sh (func_all_modules): Add it.
26205
26206 2003-04-01  Bruno Haible  <bruno@clisp.org>
26207
26208         * lib/pathname.h: New file, from GNU gettext.
26209         * lib/concatpath.c: New file, from GNU gettext.
26210
26211 2003-03-30  Bruno Haible  <bruno@clisp.org>
26212
26213         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
26214
26215 2003-03-30  Bruno Haible  <bruno@clisp.org>
26216
26217         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
26218         function chown() doesn't exist.
26219
26220 2003-03-28  Bruno Haible  <bruno@clisp.org>
26221
26222         * modules/copy-file: New file.
26223         * MODULES.html.sh (func_all_modules): Add it.
26224
26225 2003-03-28  Bruno Haible  <bruno@clisp.org>
26226
26227         * m4/copy-file.m4: New file.
26228
26229 2003-03-28  Bruno Haible  <bruno@clisp.org>
26230
26231         * lib/copy-file.h: New file, from GNU gettext.
26232         * lib/copy-file.c: New file, from GNU gettext.
26233
26234 2003-03-18  Jim Meyering  <jim@meyering.net>
26235
26236         * lib/quote.c (quote_n): Fix typo in comment.
26237
26238 2003-03-18  Bruno Haible  <bruno@clisp.org>
26239
26240         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
26241         checking.
26242         * m4/onceonly_2_57.m4: Likewise.
26243
26244 2003-03-17  Bruno Haible  <bruno@clisp.org>
26245
26246         * m4/onceonly.m4: Require autoconf 2.54 or newer.
26247         (m4_quote): Remove macro.
26248         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
26249
26250 2003-03-14  Jim Meyering  <jim@meyering.net>
26251
26252         Merge changes from Coreutils.
26253         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
26254         to be const, in order to avoid warnings.
26255         (obstack_room): Likewise.
26256         (obstack_empty_p): Likewise.
26257
26258 2003-03-14  Bruno Haible  <bruno@clisp.org>
26259
26260         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
26261         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
26262
26263 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26264
26265         Merge changes from Bison.
26266         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
26267         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
26268         when compiling Bison 1.875's `bitset bset = obstack_alloc
26269         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
26270         * lib/hash.c: Include <stdbool.h> unconditionally.
26271
26272 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26273
26274         * m4/onceonly.m4 (m4_quote): New macro.
26275         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
26276         Quote AC_FOREACH variable-expansions properly.
26277
26278 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26279
26280         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
26281
26282 2003-03-09  Paul Eggert  <eggert@twinsun.com>
26283
26284         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
26285         Reported by Bruce Becker; see:
26286         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
26287
26288 2003-03-03  Paul Eggert  <eggert@twinsun.com>
26289             Bruno Haible  <bruno@clisp.org>
26290
26291         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
26292         Reported by John Hughes, see
26293         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
26294
26295 2003-02-20  Bruno Haible  <bruno@clisp.org>
26296
26297         * MODULES.html.sh (func_all_modules): Add poll.
26298
26299 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26300
26301         * modules/poll: New file.
26302
26303 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26304
26305         * lib/poll_.h: New file.
26306         * lib/poll.c: New file.
26307
26308 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26309
26310         * m4/poll.m4: New file.
26311
26312 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26313
26314         * modules/mathl: New file.
26315
26316 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26317
26318         * lib/mathl.h: New file.
26319         * lib/acosl.c: New file.
26320         * lib/asinl.c: New file.
26321         * lib/atanl.c: New file.
26322         * lib/ceill.c: New file.
26323         * lib/cosl.c: New file.
26324         * lib/expl.c: New file.
26325         * lib/floorl.c: New file.
26326         * lib/frexpl.c: New file.
26327         * lib/ldexpl.c: New file.
26328         * lib/logl.c: New file.
26329         * lib/sincosl.c: New file.
26330         * lib/sinl.c: New file.
26331         * lib/sqrtl.c: New file.
26332         * lib/tanl.c: New file.
26333         * lib/trigl.c: New file.
26334         * lib/trigl.h: New file.
26335
26336 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26337
26338         * m4/mathl.m4: New file.
26339
26340 2003-02-18  Bruno Haible  <bruno@clisp.org>
26341
26342         * MODULES.html.sh (func_all_modules): Add mathl.
26343
26344 2003-02-17  Bruno Haible  <bruno@clisp.org>
26345
26346         * modules/mkdtemp: New module.
26347         * MODULES.html.sh (func_all_modules): Add it.
26348
26349 2003-02-17  Bruno Haible  <bruno@clisp.org>
26350
26351         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
26352
26353 2003-02-17  Bruno Haible  <bruno@clisp.org>
26354
26355         * lib/mkdtemp.h: New file, from GNU gettext.
26356         * lib/mkdtemp.c: New file, from GNU gettext.
26357
26358 2003-02-02  Jim Meyering  <jim@meyering.net>
26359
26360         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
26361         e.g. glibc-2.2.93.
26362
26363 2003-01-31  Bruno Haible  <bruno@clisp.org>
26364
26365         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
26366         'rpl_rename'.
26367         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
26368         'rpl_strnlen'.
26369         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
26370         'rpl_strtod'.
26371         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
26372         'rpl_utime'.
26373
26374 2003-01-31  Bruno Haible  <bruno@clisp.org>
26375
26376         * lib/rename.c: #undef rename before defining rpl_rename.
26377         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
26378
26379 2003-01-30  Bruno Haible  <bruno@clisp.org>
26380
26381         * modules/vasnprintf, modules/vasprintf: New modules.
26382         * MODULES.html.sh (func_all_modules): Add them.
26383
26384 2003-01-30  Bruno Haible  <bruno@clisp.org>
26385
26386         * m4/signed.m4: New file, from GNU gettext.
26387         * m4/longdouble.m4: New file, from GNU gettext.
26388         * m4/wchar_t.m4: New file, from GNU gettext.
26389         * m4/wint_t.m4: New file, from GNU gettext.
26390         * m4/vasnprintf.m4: New file.
26391         * m4/vasprintf.m4: New file.
26392
26393 2003-01-30  Bruno Haible  <bruno@clisp.org>
26394
26395         * lib/printf-args.h: New file, from GNU gettext.
26396         * lib/printf-args.c: New file, from GNU gettext.
26397         * lib/printf-parse.h: New file, from GNU gettext.
26398         * lib/printf-parse.c: New file, from GNU gettext.
26399         * lib/vasnprintf.h: New file, from GNU gettext.
26400         * lib/vasnprintf.c: New file, from GNU gettext.
26401         * lib/asnprintf.c: New file, from GNU gettext.
26402         * lib/vasprintf.h: New file, from GNU gettext with modifications.
26403         * lib/vasprintf.c: New file, from GNU gettext.
26404         * lib/asprintf.c: New file, from GNU gettext.
26405
26406 2003-01-29  Bruno Haible  <bruno@clisp.org>
26407
26408         * modules/stpncpy: New module.
26409         * MODULES.html.sh (func_all_modules): Add it.
26410
26411 2003-01-29  Bruno Haible  <bruno@clisp.org>
26412
26413         * m4/stpncpy.m4: New file.
26414
26415 2003-01-29  Bruno Haible  <bruno@clisp.org>
26416
26417         * lib/stpncpy.h: New file, from GNU gettext with modifications.
26418         * lib/stpncpy.c: New file, from GNU gettext with modifications.
26419
26420 2003-01-28  Bruno Haible  <bruno@clisp.org>
26421
26422         * modules/c-ctype: New module.
26423         * MODULES.html.sh (func_all_modules): Add it.
26424
26425 2003-01-28  Bruno Haible  <bruno@clisp.org>
26426
26427         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
26428         Paul Eggert.
26429         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
26430         Paul Eggert.
26431
26432 2003-01-27  Bruno Haible  <bruno@clisp.org>
26433
26434         * modules/xsetenv: New module.
26435         * MODULES.html.sh (func_all_modules): Add it.
26436
26437 2003-01-27  Bruno Haible  <bruno@clisp.org>
26438
26439         * lib/xsetenv.h: New file, from GNU gettext.
26440         * lib/xsetenv.c: New file, from GNU gettext.
26441
26442 2003-01-23  Jim Meyering  <jim@meyering.net>
26443
26444         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
26445         from working on systems without dirfd (at least Irix and OSF1/Tru64).
26446
26447 2003-01-23  Bruno Haible  <bruno@clisp.org>
26448
26449         * modules/minmax: New module.
26450         * MODULES.html.sh (func_all_modules): Add it.
26451
26452 2003-01-23  Bruno Haible  <bruno@clisp.org>
26453
26454         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
26455         Eggert.
26456
26457 2003-01-22  Bruno Haible  <bruno@clisp.org>
26458
26459         * modules/exit: New module.
26460         * MODULES.html.sh (func_all_modules): Add it.
26461
26462 2003-01-22  Bruno Haible  <bruno@clisp.org>
26463
26464         * lib/exit.h: New file, from GNU gettext.
26465
26466 2003-01-19  Bruno Haible  <bruno@clisp.org>
26467
26468         * gnulib-tool: Recognize option --extract-maintainer.
26469         (func_get_maintainer): New function.
26470         * modules/*: Add Maintainer entry.
26471
26472 2003-01-16  Jim Meyering  <jim@meyering.net>
26473
26474         * m4/regex.m4: The `regex' struct is both input and output.
26475         Initialize it before each use.  Patch by Tim Waugh.
26476
26477 2003-01-16  Bruno Haible  <bruno@clisp.org>
26478
26479         * MODULES.html.sh: Add a table of contents. Add the module name as
26480         leftmost column. Add hyperlinks.
26481
26482 2003-01-15  Bruno Haible  <bruno@clisp.org>
26483
26484         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
26485
26486 2003-01-15  Bruno Haible  <bruno@clisp.org>
26487
26488         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
26489         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
26490         suffix.
26491
26492 2003-01-15  Bruno Haible  <bruno@clisp.org>
26493
26494         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
26495
26496 2003-01-15  Bruno Haible  <bruno@clisp.org>
26497
26498         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
26499         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
26500
26501 2003-01-14  Jim Meyering  <jim@meyering.net>
26502
26503         * lib/same.c (same_name): Tweak a comment.
26504
26505 2003-01-14  Bruno Haible  <bruno@clisp.org>
26506
26507         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
26508         when a string comparison is sufficient.
26509
26510 2003-01-14  Bruno Haible  <bruno@clisp.org>
26511
26512         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
26513         'unsigned int'.
26514
26515 2003-01-14  Bruno Haible  <bruno@clisp.org>
26516
26517         * lib/hash-pjw.c: Add comment about low quality of this function.
26518
26519 2003-01-13  Bruno Haible  <bruno@clisp.org>
26520
26521         * modules/stpcpy: Distribute lib/stpcpy.h.
26522         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
26523
26524 2003-01-13  Bruno Haible  <bruno@clisp.org>
26525
26526         * modules/*: Add a description.
26527         * modules/strpbrk: Fix Makefile.am snippet.
26528         * modules/strtoimax: Fix dependencies.
26529         * modules/strtoumax: Likewise.
26530
26531 2003-01-13  Bruno Haible  <bruno@clisp.org>
26532
26533         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
26534         * modules/alloca (Makefile.am): All object files depend on alloca.h.
26535         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
26536
26537 2003-01-13  Bruno Haible  <bruno@clisp.org>
26538
26539         * gnulib-tool (func_create_testdir): Store config/* files in the main
26540         directory.
26541         * config.rpath: Move to ...
26542         * config/config.rpath: ... here.
26543         * modules/gettext: Contains config/config.rpath, not config.rpath.
26544         * modules/iconv: Likewise.
26545
26546 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26547
26548         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26549         to avoid collisions with libcurses and libreadline.
26550
26551         * m4/getstr.m4: Remove.
26552         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
26553
26554 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26555
26556         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26557         to avoid collisions with libcurses and libreadline.
26558
26559         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
26560         * lib/getstr.h, getstr.c: Remove.
26561         * lib/getline.c: Include "getline.h", to check interface.
26562         Move body of old getstr.c here: this defines MIN_CHUNK and
26563         declares getdelim2, which is renamed from getstr.
26564         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
26565
26566         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
26567         All uses changed.
26568         * lib/linebuffer.h: Likewise.
26569         (readline): Remove backward-compatibility macro.
26570
26571 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26572
26573         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26574         to avoid collisions with libcurses and libreadline.
26575         * getstr: Remove.
26576         * MODULES.html.sh: Remove getstr.
26577         * modules/getline: Depend on unlocked-io, not getstr.
26578
26579 2003-01-12  Jim Meyering  <jim@meyering.net>
26580
26581         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
26582
26583 2003-01-10  Bruno Haible  <bruno@clisp.org>
26584
26585         * modules/alloca: Change Makefile.am requirements. Simplify Include
26586         requirements. Add lib/alloca_.h to file list.
26587
26588 2003-01-10  Bruno Haible  <bruno@clisp.org>
26589
26590         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
26591
26592 2003-01-10  Bruno Haible  <bruno@clisp.org>
26593
26594         * lib/alloca_.h: New file.
26595         * lib/getdate.y: Unconditionally include alloca.h.
26596         * lib/makepath.c: Likewise.
26597         * lib/setenv.c: Likewise.
26598         * lib/userspec.c: Likewise.
26599
26600 2003-01-09  Karl Berry  <karl@gnu.org>
26601
26602         * MODULES.html.sh: include `dirname $0` in PATH, to find
26603         gnulib-tool.
26604
26605 2003-01-09  Bruno Haible  <bruno@clisp.org>
26606
26607         * modules/stdbool: Change configure.ac, Makefile.am requirements.
26608         Simplify Include requirements. Add lib/stdbool.h.in to file list.
26609
26610 2003-01-09  Bruno Haible  <bruno@clisp.org>
26611
26612         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
26613
26614 2003-01-09  Bruno Haible  <bruno@clisp.org>
26615
26616         * lib/stdbool.h.in: New file.
26617
26618 2003-01-09  Bruno Haible  <bruno@clisp.org>
26619
26620         * gnulib-tool (func_all_modules): Ignore files ending in ~.
26621         * MODULES.html.sh: Likewise.
26622
26623 2003-01-08  Jim Meyering  <jim@meyering.net>
26624
26625         * lib/full-write.c: Undefine and define-away `const' after inclusion
26626         of errno.h, not before.  Suggestion from Bruno Haible.
26627
26628 2003-01-08  Bruno Haible  <bruno@clisp.org>
26629
26630         * modules/full-read: Depend on full-write.
26631
26632 2003-01-08  Bruno Haible  <bruno@clisp.org>
26633
26634         * lib/safe-read.c: Include specification header first, to ensure its
26635         selfcontainedness.
26636         * lib/full-write.c: Likewise.
26637
26638 2003-01-07  Jim Meyering  <jim@meyering.net>
26639
26640         * lib/full-write.c: Rework so that it may serve to define full_read,
26641         too.
26642         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
26643
26644 2003-01-07  Bruno Haible  <bruno@clisp.org>
26645
26646         * lib/strtoimax.c: Include <stdint.h> as an alternative to
26647         <inttypes.h>.
26648         * lib/xstrtol.h: Likewise.
26649         * lib/xstrtoimax.c: Likewise.
26650         * lib/xstrtoumax.c: Likewise.
26651         * lib/human.h: Likewise.
26652
26653         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
26654         on systems that have <inttypes.h> but not <stdint.h>.
26655
26656 2003-01-07  Bruno Haible  <bruno@clisp.org>
26657
26658         * MODULES.html.sh: Add copyright notice.
26659         (missed_files): Omit CVS directory entries.
26660         (func_module): Make it work with sed-3.02.
26661         * MODULES.txt: Remove file.
26662
26663 2003-01-06  Jim Meyering  <jim@meyering.net>
26664
26665         * lib/version-etc.c: Update year in translatable copyright string.
26666
26667 2003-01-03  Karl Berry  <karl@gnu.org>
26668
26669         * config/config.{guess,sub}: update from prep.
26670
26671 2003-01-02  Karl Berry  <karl@gnu.org>
26672
26673         * doc/COPYING.DOC: belatedly updated to 1.2.
26674
26675 2003-01-01  Karl Berry  <karl@gnu.org>
26676
26677         * gnulib-tool (func_verify_module): report module name $module in
26678         error message, not $1.
26679         * gnulib-tool (create-testdir): don't complain if destdir couldn't
26680         be created, only if it doesn't exist.
26681         * gnulib-tool (last_checkin_date): don't expand the $Date here.
26682
26683 2002-12-31  Paul Eggert  <eggert@twinsun.com>
26684
26685         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
26686
26687 2002-12-31  Paul Eggert  <eggert@twinsun.com>
26688
26689         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
26690         memcmp if strcoll doesn't work.
26691
26692 2002-12-31  Bruno Haible  <bruno@clisp.org>
26693
26694         * lib/utime.c (utime_null): No need to call ftruncate if the file was
26695         nonempty.
26696
26697 2002-12-31  Bruno Haible  <bruno@clisp.org>
26698
26699         * lib/memcoll.c (STRCOLL): New macro.
26700         (memcoll): Use it.
26701
26702 2002-12-31  Bruno Haible  <bruno@clisp.org>
26703
26704         * lib/localcharset.h: New file.
26705         * lib/localcharset.c: Include it.
26706         * lib/unicodeio.c: Likewise.
26707
26708 2002-12-31  Bruno Haible  <bruno@clisp.org>
26709
26710         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
26711         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
26712
26713 2002-12-31  Bruno Haible  <bruno@clisp.org>
26714
26715         * lib/getline.h: Include <stddef.h>, for size_t.
26716
26717         * lib/unicodeio.h: Include <stddef.h>, for size_t.
26718         * lib/unicodeio.c: Don't include <stddef.h>.
26719
26720 2002-12-31  Bruno Haible  <bruno@clisp.org>
26721
26722         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
26723         HAVE_TM_ZONE.
26724
26725 2002-12-24  Karl Berry  <karl@gnu.org>
26726
26727         * config/config.guess: update from prep.
26728
26729 2002-12-24  Bruno Haible  <bruno@clisp.org>
26730
26731         General infrasructure.
26732         * m4/README: Rewritten.
26733         * m4/onceonly.m4: New file.
26734         * m4/onceonly_2_57.m4: New file.
26735
26736         Module atexit.
26737         * m4/atexit.m4: New file.
26738
26739         Module strtod.
26740         * m4/strtod.m4: New file.
26741
26742         Module strtol.
26743         * m4/strtol.m4: New file.
26744
26745         Module strtoul.
26746         * m4/strtoul.m4: New file.
26747
26748         Module memchr.
26749         * m4/memchr.m4: New file.
26750
26751         Module memcmp.
26752         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
26753         (jm_FUNC_MEMCMP): Invoke it.
26754
26755         Module memcpy.
26756         * m4/memcpy.m4: New file.
26757
26758         Module memmove.
26759         * m4/memmove.m4: New file.
26760
26761         Module memset.
26762         * m4/memset.m4: New file.
26763
26764         Module strcspn.
26765         * m4/strcspn.m4: New file.
26766
26767         Module strpbrk.
26768         * m4/strpbrk.m4: New file.
26769
26770         Module strstr.
26771         * m4/strstr.m4: New file.
26772
26773         Module strerror.
26774         * m4/strerror.m4: New file.
26775
26776         Module mktime.
26777         * m4/mktime.m4: Renamed from jm-mktime.m4.
26778         (gl_PREREQ_MKTIME): New macro.
26779         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
26780
26781         Module malloc.
26782         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
26783         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
26784         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
26785
26786         Module realloc.
26787         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
26788         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
26789         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
26790
26791         Module strftime.
26792         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
26793         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
26794         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
26795         gl_TM_GMTOFF.
26796         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
26797
26798         Module xalloc.
26799         * m4/xalloc.m4: New file.
26800
26801         Module alloca.
26802         * m4/alloca.m4: New file.
26803
26804         Module putenv.
26805         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
26806         (jm_FUNC_PUTENV): Invoke it.
26807
26808         Module setenv.
26809         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
26810         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
26811         when invoked twice.
26812         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
26813         gt_FUNC_SETENV.
26814
26815         Module memrchr.
26816         * m4/memrchr.m4: New file.
26817
26818         Module stpcpy.
26819         * m4/stpcpy.m4: New file.
26820
26821         Module strcase.
26822         * m4/strcase.m4: New file.
26823
26824         Module strdup.
26825         * m4/strdup.m4: New file.
26826
26827         Module strnlen.
26828         * m4/strnlen.m4: New file.
26829
26830         Module strndup.
26831         * m4/strndup.m4: New file.
26832
26833         Module xstrtod.
26834         * m4/xstrtod.m4: New file.
26835
26836         Module xstrtol.
26837         * m4/xstrtol.m4: New file.
26838
26839         Module getdate.
26840         * m4/getdate.m4: New file.
26841
26842         Module unlocked-io.
26843         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
26844         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
26845         * m4/jm-glibc-io.m4n: Remove file.
26846
26847         Module long-options.
26848         * m4/long-options.m4: New file.
26849
26850         Module md5.
26851         * m4/md5.m4: New file.
26852
26853         Module sha.
26854         * m4/sha.m4: New file.
26855
26856         Module getstr.
26857         * m4/getstr.m4: New file.
26858
26859         Module getline.
26860         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
26861         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
26862         <sys/types.h>, for size_t. Use the function name gnu_getline, not
26863         simply getline. Infoke gl_PREREQ_GETLINE.
26864
26865         Module obstack.
26866         * m4/obstack.m4: New file.
26867
26868         Module hash.
26869         * m4/hash.m4: New file.
26870
26871         Module readtokens.
26872         * m4/readtokens.m4: New file.
26873
26874         Module strverscmp.
26875         * m4/strverscmp.m4: New file.
26876
26877         Module stdbool.
26878         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
26879         OSF/1.
26880
26881         Module strtoll.
26882         * m4/strtoll.m4: New file.
26883
26884         Module strtoull.
26885         * m4/strtoull.m4: New file.
26886
26887         Module strtoimax.
26888         * m4/strtoimax.m4: New file.
26889
26890         Module strtoumax.
26891         * m4/strtoumax.m4: New file.
26892
26893         Module xstrtoimax.
26894         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
26895         jm_AC_PREREQ_XSTRTOIMAX.
26896         Moved the strtol prerequisites to strtol.m4.
26897         Moved the strtoll prerequisites to strtoll.m4.
26898         Moved the strtoimax prerequisites to strtoimax.m4.
26899
26900         Module xstrtoumax.
26901         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
26902         jm_AC_PREREQ_XSTRTOUMAX.
26903         Moved the strtoul prerequisites to strtoul.m4.
26904         Moved the strtoull prerequisites to strtoull.m4.
26905         Moved the strtoumax prerequisites to strtoumax.m4.
26906
26907         Module chown.
26908         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
26909         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
26910
26911         Module dup2.
26912         * m4/dup2.m4: New file.
26913
26914         Module ftruncate.
26915         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
26916         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
26917
26918         Module getgroups.
26919         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
26920         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
26921
26922         Module gettimeofday.
26923         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
26924         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
26925         gl_PREREQ_GETTIMEOFDAY.
26926
26927         Module mkdir.
26928         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
26929         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
26930
26931         Module mkstemp.
26932         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
26933         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
26934         jm_AC_TYPE_UINTMAX_T.
26935         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
26936
26937         Module stat.
26938         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
26939         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
26940
26941         Module lstat.
26942         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
26943         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
26944
26945         Module timespec.
26946         * m4/timespec.m4 (gl_TIMESPEC): New macro.
26947         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
26948         * m4/st_mtim.m4: Indentation.
26949
26950         Module nanosleep.
26951         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
26952         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
26953         gl_PREREQ_NANOSLEEP.
26954
26955         Module regex.
26956         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
26957         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
26958         (gl_REGEX): New macro.
26959
26960         Module rename.
26961         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
26962         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
26963
26964         Module rmdir.
26965         * m4/rmdir.m4: New file.
26966
26967         Module utime.
26968         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
26969         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
26970         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
26971
26972         Module dirname.
26973         * m4/dirname.m4: New file.
26974
26975         Module getopt.
26976         * m4/getopt.m4: New file.
26977
26978         Module unistd-safer.
26979         * m4/unistd-safer.m4: New file.
26980
26981         Module fnmatch.
26982         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
26983         declaration.
26984         (gl_PREREQ_FNMATCH_EXTRA): New macro.
26985         (gl_FUNC_FNMATCH_POSIX): New macro.
26986         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
26987         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
26988         simply fnmatch.
26989
26990         Module exclude.
26991         * m4/exclude.m4: New file.
26992
26993         Module human.
26994         * m4/human.m4: New file.
26995
26996         Module acl.
26997         * m4/acl.m4: Nop.
26998
26999         Module backupfile.
27000         * m4/backupfile.m4: New file.
27001         * m4/d-ino.m4: Indentation.
27002
27003         Module fsusage.
27004         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
27005         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
27006         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
27007
27008         Module dirfd.
27009         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
27010         requirements.
27011
27012         Module euidaccess.
27013         * m4/euidaccess.m4: New file.
27014
27015         Module file-type.
27016         * m4/file-type.m4: New file.
27017
27018         Module fileblocks.
27019         * m4/fileblocks.m4: New file.
27020
27021         Module filemode.
27022         * m4/filemode.m4: New file.
27023
27024         Module isdir.
27025         * m4/isdir.m4: New file.
27026
27027         Module lchown.
27028         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
27029         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
27030
27031         Module makepath.
27032         * m4/makepath.m4: New file.
27033
27034         Module modechange.
27035         * m4/modechange.m4: New file.
27036
27037         Module mountlist.
27038         * m4/mountlist.m4: New file.
27039         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
27040         Indentation.
27041
27042         Module path-concat.
27043         * m4/path-concat.m4: New file.
27044
27045         Module pathmax.
27046         * m4/pathmax.m4: New file.
27047
27048         Module same.
27049         * m4/same.m4: New file.
27050
27051         Module save-cwd.
27052         * m4/save-cwd.m4: New file.
27053
27054         Module savedir.
27055         * m4/savedir.m4: New file.
27056
27057         Module xgetcwd.
27058         * m4/xgetcwd.m4: New file.
27059         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
27060
27061         Module xreadlink.
27062         * m4/xreadlink.m4: New file.
27063
27064         Module safe-read.
27065         * m4/safe-read.m4: New file.
27066
27067         Module safe-write.
27068         * m4/safe-write.m4: New file.
27069
27070         Module closeout.
27071         * m4/closeout.m4: New file.
27072
27073         Module stdio-safer.
27074         * m4/stdio-safer.m4: New file.
27075
27076         Module getpass.
27077         * m4/getpass.m4: New file.
27078
27079         Module getugroups.
27080         * m4/getugroups.m4: New file.
27081
27082         Module group-member.
27083         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
27084         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
27085
27086         Module idcache.
27087         * m4/idcache.m4: New file.
27088
27089         Module userspec.
27090         * m4/userspec.m4: New file.
27091
27092         Module gettime.
27093         * m4/clock_time.m4: New file.
27094         * m4/gettime.m4: New file.
27095
27096         Module settime.
27097         * m4/settime.m4: New file.
27098
27099         Module posixtm.
27100         * m4/posixtm.m4: New file.
27101
27102         Module gethostname.
27103         * m4/gethostname.m4: New file.
27104
27105         Module canon-host.
27106         * m4/canon-host.m4: New file.
27107
27108         Module gettext.
27109         * m4/codeset.m4: New file, from gettext-0.11.5.
27110         * m4/gettext.m4: New file, from gettext-0.11.5.
27111         * m4/glibc21.m4: New file, from gettext-0.11.5.
27112         * m4/iconv.m4: New file, from gettext-0.11.5.
27113         * m4/intdiv0.m4: New file, from gettext-0.11.5.
27114         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
27115         * m4/inttypes.m4: New file, from gettext-0.11.5.
27116         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
27117         * m4/isc-posix.m4: New file, from gettext-0.11.5.
27118         * m4/lcmessage.m4: New file, from gettext-0.11.5.
27119         * m4/lib-ld.m4: New file, from gettext-0.11.5.
27120         * m4/lib-link.m4: New file, from gettext-0.11.5.
27121         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
27122         * m4/progtest.m4: New file, from gettext-0.11.5.
27123         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
27124         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
27125         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
27126
27127         Module localcharset.
27128         * m4/localcharset.m4: New file.
27129
27130         Module hard-locale.
27131         * m4/hard-locale.m4: New file.
27132
27133         Module mbswidth.
27134         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
27135         onceonly macros.
27136         * m4/mbrtowc.m4: Add comment.
27137
27138         Module memcasecmp.
27139         * m4/memcasecmp.m4: New file.
27140
27141         Module memcoll.
27142         * m4/memcoll.m4: New file.
27143
27144         Module unicodeio.
27145         * m4/unicodeio.m4: New file.
27146
27147         Module rpmatch.
27148         * m4/rpmatch.m4: New file.
27149
27150         Module yesno.
27151         * m4/yesno.m4: New file.
27152
27153         Module exitfail.
27154         * m4/exitfail.m4: New file.
27155
27156         Module c-stack.
27157         * m4/c-stack.m4 (gl_C_STACK): New macro.
27158         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
27159
27160         Module error.
27161         * m4/error.m4 (gl_ERROR): New macro.
27162         (jm_PREREQ_ERROR): Use onceonly macros.
27163
27164         Module fatal.
27165         * m4/fatal.m4: New file.
27166
27167         Module getloadavg.
27168         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
27169         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
27170
27171         Module getpagesize.
27172         * m4/getpagesize.m4: New file.
27173
27174         Module getusershell.
27175         * m4/getusershell.m4: New file.
27176
27177         Module physmem.
27178         * m4/physmem.m4: New file.
27179
27180         Module posixver.
27181         * m4/posixver.m4: New file.
27182
27183         Module quotearg.
27184         * m4/quotearg.m4: New file.
27185
27186         Module quote.
27187         * m4/quote.m4: New file.
27188
27189         Module readutmp.
27190         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
27191
27192         Module sig2str.
27193         * m4/sig2str.m4: New file.
27194
27195         Other.
27196         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
27197         ulonglong.m4.
27198         * m4/intmax_t.m4: New file.
27199         * m4/d-type.m4: Indentation.
27200         * m4/jm-macros.m4: Update.
27201         * m4/prereq.m4 (jm_PREREQ): Update.
27202         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
27203         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
27204         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
27205         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
27206         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
27207         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
27208         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
27209         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
27210         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
27211         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
27212         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
27213         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
27214         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
27215         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
27216         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
27217         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
27218         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
27219         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
27220         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
27221
27222 2002-12-24  Bruno Haible  <bruno@clisp.org>
27223
27224         * MODULES.txt: Update according to m4/ changes.
27225
27226         Module gettext.
27227         * config.rpath: New file, from gettext-0.11.5.
27228
27229         * modules/*: New module descriptions.
27230         * gnulib-tool: New file.
27231         * MODULES.html.sh: New file.
27232
27233 2002-12-21  Karl Berry  <karl@gnu.org>
27234
27235         * doc/fdl.texi: update to version 1.2.
27236
27237 2002-12-19  Karl Berry  <karl@gnu.org>
27238
27239         * config/config.guess: update from prep.
27240
27241 2002-12-18  Bruno Haible  <bruno@clisp.org>
27242
27243         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
27244         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
27245
27246 2002-12-17  Bruno Haible  <bruno@clisp.org>
27247
27248         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
27249         stdlib.h, string.h.
27250
27251 2002-12-17  Bruno Haible  <bruno@clisp.org>
27252
27253         * lib/canon-host.c (strdup): Remove unused declaration.
27254
27255         * lib/fsusage.c: Include full_read.h.
27256         (get_fs_usage): Use full_read instead of safe_read.
27257
27258         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
27259
27260 2002-12-12  Karl Berry  <karl@gnu.org>
27261
27262         * config/config.guess: update from prep.
27263
27264 2002-12-11  Bruno Haible  <bruno@clisp.org>
27265
27266         * m4/setenv.m4: New file, from gettext-0.11.5.
27267
27268 2002-12-11  Bruno Haible  <bruno@clisp.org>
27269
27270         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
27271         not unsetenv().
27272         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
27273         modifications:
27274
27275         2002-12-11  Bruno Haible  <bruno@clisp.org>
27276
27277                 * setenv.c (alloca): Fall back to malloc.
27278                 (freea): New macro.
27279                 (setenv): Use freea() to free memory allocated with alloca().
27280
27281         2002-11-13  Bruno Haible  <bruno@clisp.org>
27282
27283                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
27284                 function declarations.
27285                 * unsetenv.c (unsetenv): Likewise.
27286
27287         2002-03-04  Bruno Haible  <bruno@clisp.org>
27288
27289                 Portability to AIX 4.3.3.
27290                 * unsetenv.c: New file, extracted from setenv.c.
27291                 * setenv.c: Move the unsetenv() function to unsetenv.c.
27292
27293         2001-12-20  Bruno Haible  <bruno@clisp.org>
27294
27295                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
27296                 use malloc instead. For SunOS 4.
27297
27298         2001-12-11  Bruno Haible  <bruno@clisp.org>
27299
27300                 * setenv.c: Declare alloca.
27301                 (compar_fn_t): New typedef.
27302                 (KNOWN_VALUE, STORE_VALUE): Use it.
27303
27304         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
27305         setenv.h.
27306
27307 2002-12-10  Paul Eggert  <eggert@twinsun.com>
27308
27309         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
27310         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
27311         Choose values that are less likely to collide with system fnmatch
27312         options.
27313         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
27314         defined (e.g., a pure POSIX system).
27315         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
27316         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
27317
27318 2002-12-06  Paul Eggert  <eggert@twinsun.com>
27319
27320         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
27321         a pain in practice to deal with generated m4 files.  This change
27322         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
27323
27324         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
27325         and jm-glibc-io.m4, as they are no longer a special case.
27326         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
27327         kludge and the auto-generation stuff.  Check only whether the
27328         functions are declared, not whether they exist, since older hosts
27329         that don't declare the functions can't use the optimization anyway.
27330
27331 2002-12-06  Jim Meyering  <jim@meyering.net>
27332
27333         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
27334
27335         Merge in changes from libc's misc/error.c, in preparation
27336         for the merge of gnulib's changes back into libc.
27337
27338         * lib/error.c (_): Define only if not already defined.
27339         Move definition to follow all #include directives.
27340         Include unlocked-io.h only if !_LIBC.
27341         [_LIBC]: Include <libio/libioP.h>.
27342         [USE_IN_LIBIO]: Include <libio/iolibio.h>
27343         (fflush): Tweak definition to use INTUSE.
27344         (putc): Define.
27345
27346 2002-12-05  Paul Eggert  <eggert@twinsun.com>
27347
27348         * lib/alloca.c [defined emacs]: Include "lisp.h".
27349         (xalloc_die) [defined emacs]: New macro.
27350         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
27351         [! defined emacs]: Include <xalloc.h>.
27352         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
27353         (pointer): Typedef to POINTER_TYPE *.
27354         (malloc): Remove decl; we now always use xmalloc.
27355         (alloca): Use old-style definition, since Emacs needs this.
27356         Check for arithmetic overflow when computing combined size.
27357
27358 2002-12-04  Paul Eggert  <eggert@twinsun.com>
27359
27360         Do not generate unlocked-io.h automatically, since it's easier to
27361         maintain it by hand.
27362
27363         * lib/unlocked-io.h: New file, from GNU diffutils,
27364         but with proper copyright notice and attribution.
27365         * lib/gen-uio: Remove.
27366         * lib/Makefile.am: Add copyright notice.
27367         (libfetish_a_SOURCES): Add unlocked-io.h.
27368         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
27369         (DISTCLEANFILES, io_functions): Remove macros.
27370         (EXTRA_DIST): Remove gen_uio.
27371         (unlocked-io.h): Remove rule.
27372
27373 2002-12-04  Jim Meyering  <jim@meyering.net>
27374
27375         Reflect the fact that stat.c and lstat.c are no longer generated.
27376         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
27377         (DISTCLEANFILES): Likewise.
27378         (EXTRA_DIST): Likewise.
27379         (all_local): Don't depend on stat.c or lstat.c.
27380         (stat.c, lstat.c): Remove rules.
27381         (EXTRA_DIST): Remove xstat.in.
27382
27383         * lib/xstat.in: Remove file.  Contents moved into stat.c.
27384         * lib/stat.c: New file.  Contents mostly from xstat.in.
27385         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
27386         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
27387
27388         * lib/safe-read.c: Rework so that it may serve to define safe_write,
27389         too.
27390         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
27391
27392 2002-12-03  Jim Meyering  <jim@meyering.net>
27393
27394         * lib/safe-read.c, safe-write.c: Change variable names and comments,
27395         but not semantics, to minimize the differences between these two files.
27396         (safe_read): Change comment to mention SAFE_READ_ERROR.
27397
27398         * lib/safe-read.c (IS_EINTR): Define.
27399         (safe_read): Use IS_EINTR in place of in-function cpp directives.
27400
27401 2002-12-02  Jim Meyering  <jim@meyering.net>
27402
27403         * lib/safe-read.c (EINTR): Define.
27404         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
27405         (INT_MAX): Provide fallback.
27406         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
27407
27408         * lib/safe-read.h (SAFE_READ_ERROR): Define.
27409
27410 2002-12-02  Bruno Haible  <bruno@clisp.org>
27411
27412         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
27413         Define, taken from safe-read.c.
27414         (INT_MAX): Provide fallback.
27415         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
27416         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
27417
27418         * lib/safe-read.c (EINTR): Remove definition.
27419         (safe_read): Don't use EINTR if it is absent.
27420
27421 2002-12-01  Jim Meyering  <jim@meyering.net>
27422
27423         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
27424         zero.
27425         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
27426
27427 2002-11-27  Paul Eggert  <eggert@twinsun.com>
27428
27429         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
27430         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
27431         with `if (! (value < limit)) abort ();', for readability.
27432
27433 2002-11-26  Karl Berry  <karl@gnu.org>
27434
27435         * lib/strdup.c: copy from libc again, with jim's ok.
27436         * lib/.cppi-disable: re-add strdup.c
27437
27438 2002-11-25  Karl Berry  <karl@gnu.org>
27439
27440         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
27441         instead of "strtol.c".
27442
27443 2002-11-25  Karl Berry  <karl@gnu.org>
27444
27445         * config/install-sh: update from automake for variable quoting, $0 in
27446         error msgs, etc.
27447
27448         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
27449         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
27450         entry.
27451
27452 2002-11-25  Jim Meyering  <jim@meyering.net>
27453
27454         * lib/mktime.c: Sync from libc, now that it has the latest fix.
27455
27456 2002-11-24  Karl Berry  <karl@gnu.org>
27457
27458         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
27459         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
27460
27461 2002-11-24  Jim Meyering  <jim@meyering.net>
27462
27463         Update from coreutils:
27464
27465         * lib/mktime.c: Merge in changes from libc.
27466
27467         Avoid a link-time failure on some Linux systems.
27468         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
27469         (otherwise).
27470         (__mon_yday): Declare with the STATIC attribute.
27471         (__mktime_internal): Likewise.
27472         Based on a report from Greg Schafer.
27473
27474 2002-11-23  Jim Meyering  <jim@meyering.net>
27475
27476         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
27477         Use `unsigned', not `int', as type of index.
27478
27479         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
27480
27481         * lib/fsusage.c: Remove unneeded parentheses around operands of
27482         `defined'.
27483
27484 2002-11-22  Paul Eggert  <eggert@twinsun.com>
27485
27486         * lib/quotearg.h: Allow multiple inclusion by surrounding with
27487         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
27488         so that we can be included first.
27489         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
27490         * lib/quotearg.c: Include quotearg.h immediately after config.h.
27491         No need to include stddef.h or sys/types.h any more.
27492         Surround local include files with "", not "<>".
27493         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
27494         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
27495         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
27496         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
27497         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
27498         (ISPRINT): Remove; no longer needed now that we assume C89.
27499
27500         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
27501         Preserve errno.
27502
27503         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
27504         quotearg_char): Use SIZE_MAX rather than
27505         (size_t) -1 when we are talking about "infinity".
27506
27507         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
27508
27509 2002-11-22  Paul Eggert  <eggert@twinsun.com>
27510
27511         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
27512         hint that one should use `if (! x) abort ();' rather than `assert
27513         (x);', and anyway it's one less thing to worry about configuring.
27514         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
27515         hash_rehash, hash_insert): Use abort rather than assert.
27516
27517 2002-11-22  Bruno Haible  <bruno@clisp.org>
27518
27519         * lib/safe-read.h: Assume C89. Add comments.
27520         (safe_read): Change return type to size_t.
27521         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
27522         byte counts > SSIZE_MAX correctly.
27523         * lib/safe-write.h: New file.
27524         * lib/safe-write.c: New file.
27525         * lib/full-read.h: New file.
27526         * lib/full-read.c: New file.
27527         * lib/full-write.h: Assume C89. Add comments.
27528         * lib/full-write.c: Include safe-write.h.
27529         (full_write): Rewritten to use safe_write.
27530         Suggested by Jim Meyering and Paul Eggert.
27531
27532 2002-11-21  Jim Meyering  <jim@meyering.net>
27533
27534         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
27535
27536         Merge in changes from the coreutils.
27537
27538         2002-09-25  Paul Eggert  <eggert@twinsun.com>
27539         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
27540         <stdint.h>.
27541         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
27542         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
27543         int.  Work more efficiently if X is the same width as uintmax_t.
27544         Do not compare X to -1, to avoid bogus compiler warning.
27545         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
27546         Don't assume that f_frsize and f_bsize are the same type.
27547
27548         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
27549         warning on FreeBSD.
27550
27551         * lib/makepath.c (make_path): Restore umask *before* creating the final
27552         component.
27553         (make_path): Minor reformatting.
27554
27555         * lib/xmalloc.c: Adjust to work with new autoconf macros,
27556         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
27557         HAVE_MALLOC/HAVE_REALLOC.
27558
27559         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
27560         dummy ones.  At least on GNU/Linux systems, `auto' means something
27561         else.
27562         From Michael Stone.
27563
27564 2002-11-21  Bruno Haible  <bruno@clisp.org>
27565
27566         Remove case insensitive option matching.
27567         * lib/argmatch.h (argcasematch): Remove declaration.
27568         (ARGCASEMATCH): Remove macro.
27569         (__xargmatch_internal): Remove case_sensitive argument.
27570         (XARGMATCH): Update.
27571         (XARGCASEMATCH): Remove macro.
27572         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
27573         case_sensitive argument.
27574         (argcasematch): Remove function.
27575         (__xargmatch_internal): Remove case_sensitive argument.
27576         (main): Use XARGMATCH instead of XARGCASEMATCH.
27577
27578         * lib/xmalloc.c: Change compile-time error message. Add comment about
27579         required autoconf version.
27580
27581 2002-11-20  Paul Eggert  <eggert@twinsun.com>
27582
27583         Merge argmatch cleanups from Bison.  Assume C89.
27584
27585         * lib/argmatch.c: Include config.h here, not in argmatch.h.
27586         Include stdlib.h, for EXIT_FAILURE.
27587         Always include <string.h>, since we assume C89.
27588         (EXIT_FAILURE): Remove pre-C89 bug workaround.
27589         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
27590         Include <stddef.h> instead, since it's all we need for size_t.
27591         (PARAMS): Remove.  All uses removed.
27592         (ARRAY_CARDINALITY): Do not bother to #undef.
27593         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
27594         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
27595         Remove unnecessary parentheses.
27596         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
27597         Insert necessary parentheses.
27598         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
27599         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
27600
27601 2002-11-19  Bruno Haible  <bruno@clisp.org>
27602
27603         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
27604         * lib/mbswidth.h: Include <stddef.h>, for size_t.
27605
27606         * lib/mbswidth.h (PARAMS): Remove macro.
27607         (mbswidth, mbsnwidth): Use ANSI C function declarations.
27608         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
27609
27610         * lib/gcd.h (PARAMS): Remove macro.
27611         (gcd): Use ANSI C function declarations.
27612         * lib/gcd.c (gcd): Likewise.
27613
27614 2002-11-15  Bruno Haible  <bruno@clisp.org>
27615
27616         * lib/strcspn.c: Include <stddef.h>.
27617         (strcspn): Use ANSI C function declaration. Change return type to
27618         size_t. Use NULL.
27619         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
27620         (strpbrk): Use NULL.
27621         * lib/strpbrk.h (PARAMS): Remove macro.
27622         (strpbrk): Use ANSI C function declaration.
27623         * lib/strstr.c: Don't include <sys/types.h>.
27624         * lib/strstr.h (PARAMS): Remove macro.
27625         (strstr): Use ANSI C function declarations.
27626
27627 2002-11-14  Karl Berry  <karl@gnu.org>
27628
27629         * config/mkinstalldirs: `do' on separate line, instead of
27630         `for var; do'.
27631
27632 2002-11-06  Bruno Haible  <bruno@clisp.org>
27633
27634         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
27635         * lib/gcd.c (gcd): Likewise.
27636
27637 2002-11-05  Bruno Haible  <bruno@clisp.org>
27638
27639         * lib/gcd.h: New file, from gettext-0.11.5.
27640         * lib/gcd.c: New file, from gettext-0.11.5.
27641
27642 2002-11-05  Bruno Haible  <bruno@clisp.org>
27643
27644         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27645         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27646         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27647         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27648
27649         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
27650         <libintl.h>.
27651         * lib/makepath.c: Include gettext.h instead of <locale.h> and
27652         <libintl.h>.
27653
27654         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
27655         * lib/human.c: Include gettext.h instead of <libintl.h>.
27656         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
27657         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
27658         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
27659         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
27660         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
27661         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
27662         (textdomain): Remove definition.
27663         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
27664
27665         * lib/long-options.c: Remove include of <libintl.h> and definition of
27666         _.
27667         * lib/same.c: Remove include of <libintl.h> and definition of _.
27668
27669 2002-11-04  Owen Taylor  <otaylor@redhat.com>
27670
27671         * lib/config.charset: A few additions for Solaris.
27672
27673 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
27674
27675         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
27676         * lib/localcharset.c (locale_charset): Declare as extern "C".
27677
27678 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
27679
27680         * lib/config.charset: msdos in uk_UA uses CP1125.
27681
27682 2002-11-04  Bruno Haible  <bruno@clisp.org>
27683
27684         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
27685         * lib/strcase.h: New file, from GNU gettext-0.11.5.
27686         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
27687         * lib/strstr.h: New file, from GNU gettext-0.11.5.
27688         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
27689
27690 2002-11-04  Bruno Haible  <bruno@clisp.org>
27691
27692         * lib/localcharset.c (locale_charset): Don't return an empty string.
27693
27694 2002-11-04  Bruno Haible  <bruno@clisp.org>
27695
27696         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
27697         aliases.
27698
27699 2002-11-04  Bruno Haible  <bruno@clisp.org>
27700
27701         * lib/config.charset: Update for newest glibc. Add canonical names
27702         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
27703
27704 2002-11-04  Bruno Haible  <bruno@clisp.org>
27705
27706         * lib/config.charset: Add support for NetBSD.
27707
27708 2002-11-04  Bruno Haible  <bruno@clisp.org>
27709
27710         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
27711
27712 2002-11-01  Bruno Haible  <bruno@clisp.org>
27713
27714         * configure.in: Add AC_CONFIG_AUX_DIR call.
27715         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
27716         test/Makefile.
27717         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
27718
27719 2002-09-28  Karl Berry  <karl@gnu.org>
27720
27721         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
27722         installed automake until the next release, since changes have been
27723         made.
27724
27725 2002-09-25  Karl Berry  <karl@gnu.org>
27726
27727         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
27728         * lib/getopt*: copy from libc/posix.
27729         * lib/gettext.h: copy from gettext.
27730         * lib/.cppi-disable: add strdup.c, gettext.h.
27731
27732 2002-09-25  Karl Berry  <karl@gnu.org>
27733
27734         * config/srclist.txt: enable gettext.h check.
27735         * config/config.{guess,sub}: update from prep.
27736         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
27737                 from automake 1.6.3.
27738         See srclist*.
27739
27740 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
27741
27742         * regex.c (PATFETCH): Remove the translating fetch.
27743         (PATFETCH_RAW): Rename to PATFETCH.
27744         (set_image_of_range): New fun.
27745         (SET_RANGE_TABLE_WORK_AREA): Use it.
27746         (regex_compile): Don't translate the pattern chars so eagerly.
27747         Only do it when inserting an `exactn' bytecode or when handling
27748         a char-range.
27749         (mutually_exclusive_p): Avoid empty statement.
27750
27751 2002-07-06  Jim Meyering  <meyering@lucent.com>
27752
27753         * m4/README: Don't mention Makefile.am.in.
27754         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
27755
27756 2002-07-01  Jim Meyering  <meyering@lucent.com>
27757
27758         * lib/c-stack.c: Include sys/time.h.
27759         From Volker Borchert.
27760
27761 2002-06-26  Paul Eggert  <eggert@twinsun.com>
27762
27763         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
27764
27765 2002-06-26  Paul Eggert  <eggert@twinsun.com>
27766
27767         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
27768         New macro.  Use it uniformly instead of
27769         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
27770         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
27771         reported by Vin Shelton.
27772
27773 2002-06-22  Paul Eggert  <eggert@twinsun.com>
27774
27775         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
27776         Do not assume SA_SIGINFO behavior.
27777         Bug reported by Jim Meyering on NetBSD 1.5.2.
27778
27779 2002-06-22  Jim Meyering  <meyering@lucent.com>
27780
27781         * m4/c-stack.m4: New file, from diffutils-2.8.2.
27782         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
27783
27784         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
27785         now that configure.ac uses AC_GNU_SOURCE.
27786         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
27787         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
27788
27789         Update to latest tools.  Suggestions from Paul Eggert.
27790         * m4/stdbool.m4: New file, from diffutils-2.8.2.
27791         * m4/gnu-source.m4: Update from diffutils-2.8.2.
27792         * m4/fnmatch.m4: Likewise.
27793         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
27794         to AC_HEADER_STDBOOL
27795
27796 2002-06-22  Jim Meyering  <meyering@lucent.com>
27797
27798         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
27799         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
27800
27801 2002-06-22  Jim Meyering  <meyering@lucent.com>
27802
27803         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
27804
27805         * lib/exitfail.c, exitfail.h: Likewise.
27806         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
27807
27808         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
27809         of fnmatch.h.
27810         (EXTRA_DIST): Add fnmatch_loop.c.
27811         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
27812
27813         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
27814         * lib/fnmatch.c: Update from diffutils-2.8.2.
27815         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
27816         * lib/fnmatch.h: Remove file.
27817
27818 2002-06-21  Jim Meyering  <meyering@lucent.com>
27819
27820         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
27821         * m4/mbrtowc.m4: Likewise.
27822
27823         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
27824         * m4/mbswidth.m4: Reflect name change:
27825         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
27826         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
27827
27828         * m4/lib-link.m4: Update from gettext-0.11.2.
27829         * m4/gettext.m4: Likewise.
27830
27831         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
27832         From Alfred M. Szmidt.
27833
27834 2002-06-18  Paul Eggert  <eggert@twinsun.com>
27835
27836         * lib/file-type.h: Report an error if neither S_ISREG nor
27837         S_IFREG is defined, instead of using a test specific to glibc
27838         2.2.  This should be safe, since POSIX requires S_ISREG and
27839         Unix Version 7 had S_IFREG.  We don't need to check for
27840         <sys/types.h> since we don't use any symbols that it defines.
27841
27842 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
27843
27844         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
27845         $@-t, so that each temporary file name is unique and valid in the first
27846         8 characters, for operation under DOS.
27847
27848 2002-06-15  Paul Eggert  <eggert@twinsun.com>
27849
27850         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
27851
27852 2002-06-15  Jim Meyering  <meyering@lucent.com>
27853
27854         Work even with DJGPP 2.03, which lacks support for symlinks.
27855         From Richard Dawe.
27856         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
27857         is defined.
27858         * lib/lchown.c (S_ISLNK): Likewise.
27859
27860 2002-06-15  Jim Meyering  <meyering@lucent.com>
27861
27862         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
27863         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
27864         have been included before this file.
27865
27866 2002-06-14  Jim Meyering  <meyering@lucent.com>
27867
27868         * lib/file-type.h: Use the version from diffutils-2.8.2.
27869         * lib/file-type.c: Likewise.
27870
27871 2002-06-07  Jim Meyering  <meyering@lucent.com>
27872
27873         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
27874         They're needed at least for NetBSD 1.5.2.
27875         ($statxfs_includes): Include those same headers.
27876         ($statxfs_includes): Include sys/vfs.h if available.
27877         ($statxfs_includes): Likewise for sys/statvfs.h.
27878         Check for the following members in both structs statfs and statvfs:
27879         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
27880
27881 2002-06-01  Jim Meyering  <meyering@lucent.com>
27882
27883         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
27884         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
27885
27886 2002-05-28  Jim Meyering  <meyering@lucent.com>
27887
27888         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
27889         Reported by Volker Borchert.
27890
27891 2002-05-27  Jim Meyering  <meyering@lucent.com>
27892
27893         Fix a problem seen only on nonconforming systems whereby ls.c's
27894         use of localtime, and then of gettimeofday would cause trouble:
27895         the localtime call used to initialize rpl_gettimeofday's save
27896         mechanism would clobber ls's current local time information so
27897         that in any long listing the first file would always be listed
27898         with date 1970-01-01.  Analysis by Volker Borchert.
27899
27900         * lib/gettimeofday.c (localtime): Undefine.
27901         (rpl_localtime): New function.
27902
27903 2002-05-27  Jim Meyering  <meyering@lucent.com>
27904
27905         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
27906         localtime.
27907
27908         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
27909         use the replacement function; it wouldn't resolve at link time.
27910         Reported by Volker Borchert.
27911
27912 2002-05-22  Jim Meyering  <meyering@lucent.com>
27913
27914         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
27915         file-type.h.
27916         * lib/file-type.h: New file.
27917         * lib/file-type.c (file_type): New file/function.  Extracted from
27918         diffutils.
27919
27920 2002-04-30  Jim Meyering  <meyering@lucent.com>
27921
27922         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
27923
27924 2002-04-29  Paul Eggert  <eggert@twinsun.com>
27925
27926         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
27927
27928 2002-04-29  Paul Eggert  <eggert@twinsun.com>
27929
27930         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
27931         Do not check for alloca.h (no longer used) or stdbool.h (was never
27932         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
27933
27934 2002-04-29  Paul Eggert  <eggert@twinsun.com>
27935
27936         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
27937
27938 2002-04-29  Jim Meyering  <meyering@lucent.com>
27939
27940         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
27941         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
27942         Use AC_FUNC_STRNLEN here instead.
27943
27944         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
27945         With autoconf-2.53a, it's part of AC_PROG_CC.
27946
27947 2002-04-28  Paul Eggert  <eggert@twinsun.com>
27948
27949         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
27950         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
27951
27952 2002-04-28  Paul Eggert  <eggert@twinsun.com>
27953
27954         * lib/sig2str.h, lib/sig2str.c: New files.
27955         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
27956
27957 2002-04-28  Paul Eggert  <eggert@twinsun.com>
27958
27959         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
27960         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
27961         of 127, since 64 is the largest conceivable number for ancient
27962         nonstandard hosts.
27963         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
27964
27965 2002-04-28  Jim Meyering  <meyering@lucent.com>
27966
27967         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
27968
27969 2002-04-24  Jim Meyering  <meyering@lucent.com>
27970
27971         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
27972         (jm_PREREQ): Use it.
27973
27974         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
27975         mach/mach.h fcntl.h.
27976         Check for this function: setlocale.
27977
27978 2002-04-24  Jim Meyering  <meyering@lucent.com>
27979
27980         * lib/gettext.h: New file, from Gettext.
27981         * lib/Makefile.am (INCLUDES): Remove -I../intl.
27982         (libfetish_a_SOURCES): Add gettext.h.
27983
27984 2002-04-16  Jim Meyering  <meyering@lucent.com>
27985
27986         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
27987         ut_pid, ut_id, ut_exit.
27988
27989 2002-04-16  Jim Meyering  <meyering@lucent.com>
27990
27991         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
27992         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
27993         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
27994
27995 2002-04-12  Jim Meyering  <meyering@lucent.com>
27996
27997         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
27998         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
27999         existence of the getmntinfo function.  Needed for Darwin 5.3.
28000
28001         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
28002         This is necessary at least on Darwin 5.3.
28003
28004         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
28005         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
28006         strnlen.o in the library, and that makes some versions of ranlib
28007         object.
28008
28009 2002-04-12  Jim Meyering  <meyering@lucent.com>
28010
28011         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
28012
28013 2002-04-09  Jim Meyering  <meyering@lucent.com>
28014
28015         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
28016         to be more precise.  Rather than saying we're checking whether the
28017         function `works', say what we're testing.
28018         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
28019         Reported by Bruno Haible.
28020
28021 2002-03-10  Jim Meyering  <meyering@lucent.com>
28022
28023         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
28024         Suggestion from Santiago Vila.
28025
28026 2002-03-08  Jim Meyering  <meyering@lucent.com>
28027
28028         * lib/rename.c: Mention that this wrapper is needed also on
28029         mips-dec-ultrix4.4 systems.
28030
28031 2002-03-02  Jim Meyering  <meyering@lucent.com>
28032
28033         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
28034         not HAVE_CLOCK_SETTIME.
28035
28036 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28037
28038         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
28039         Check for clock_settime.
28040
28041 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28042
28043         * lib/nanosleep.h: Rename to....
28044         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
28045
28046         * lib/gettime.c: New file.
28047         * lib/settime.c: New file.
28048         * lib/stime.c: Remove.
28049
28050         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
28051         timespec.h.  Remove nanosleep.h.
28052
28053 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28054
28055         * m4/acl.m4: New file.
28056         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
28057         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
28058
28059 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28060
28061         * lib/acl.c, lib/acl.h: New files.
28062         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
28063
28064 2002-02-24  Jim Meyering  <meyering@lucent.com>
28065
28066         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
28067         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
28068         cause trouble.  Reported by Nelson Beebe.
28069
28070 2002-02-23  Paul Eggert  <eggert@twinsun.com>
28071
28072         * lib/path-concat.c (xpath_concat): Reorder code to pacify
28073         compilers that don't know that xalloc_die never returns.
28074
28075 2002-02-20  Jim Meyering  <meyering@lucent.com>
28076
28077         * lib/getdate.c: Regenerate using bison-1.33.
28078
28079 2002-02-17  Jim Meyering  <meyering@lucent.com>
28080
28081         * config/config.guess (main): Don't use `head -1'; it's no longer
28082         portable. Use `sed 1q' instead.
28083
28084 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
28085
28086         * m4/codeset.m4: Upgrade to gettext-0.11.
28087         * m4/gettext.m4: Upgrade to gettext-0.11.
28088         * m4/glibc21.m4: Upgrade to gettext-0.11.
28089         * m4/iconv.m4: Upgrade to gettext-0.11.
28090         * m4/isc-posix.m4: Upgrade to gettext-0.11.
28091         * m4/lcmessage.m4: Upgrade to gettext-0.11.
28092         * m4/lib-ld.m4: New file, from gettext-0.11.
28093         * m4/lib-link.m4: New file, from gettext-0.11.
28094         * m4/lib-prefix.m4: New file, from gettext-0.11.
28095         * m4/progtest.m4: Upgrade to gettext-0.11.
28096
28097 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28098
28099         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
28100         (jm_PREREQ): Use it.
28101
28102 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28103
28104         * lib/posixver.c, lib/posixver.h: New files.
28105         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28106
28107 2002-02-02  Paul Eggert  <eggert@twinsun.com>
28108             Bruno Haible  <bruno@clisp.org>
28109
28110         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
28111         (fwrite_success_callback): New declaration.
28112         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
28113         print_unicode_char. Call failure callback instead of error.
28114         (fwrite_success_callback): New function.
28115         (exit_failure_callback): New function.
28116         (fallback_failure_callback): New function.
28117         (print_unicode_char): Call unicode_to_mb.
28118
28119 2002-01-26  Jim Meyering  <meyering@lucent.com>
28120
28121         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
28122         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
28123
28124 2002-01-26  Jim Meyering  <meyering@lucent.com>
28125
28126         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
28127
28128 2002-01-22  Paul Eggert  <eggert@twinsun.com>
28129
28130         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
28131
28132 2002-01-22  Jim Meyering  <meyering@lucent.com>
28133
28134         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
28135         Otherwise, some versions of automake would omit the rule that makes
28136         Makefile from Makefile.in.
28137
28138 2002-01-21  Paul Eggert  <eggert@twinsun.com>
28139
28140         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
28141         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28142         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
28143         (memcoll): Set errno to zero if there is no error.
28144
28145         * lib/quotearg.c (quotearg_buffer_restyled):
28146         Fix bug with quoting buffers containing NUL when backslashing escapes.
28147         This bug was exposed by the other changes in this patch.
28148         (quotearg_n_options): New arg ARGSIZE.
28149         All callers changed.
28150         (quoting_options_from_style): New function.
28151         (quotearg_n_style): Use it.
28152         (quotearg_n_style_mem): New function.
28153
28154         * lib/quotearg.h (quotearg_n_style_mem): New function.
28155
28156 2002-01-19  Jim Meyering  <meyering@lucent.com>
28157
28158         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
28159         Remove useless quotes: DF_PROG="df".
28160         * m4/strnlen.m4: New file.
28161
28162 2002-01-16  Paul Eggert  <eggert@twinsun.com>
28163
28164         * lib/backupfile.c (ISDIGIT): Comment fix.
28165         * lib/getdate.y (ISDIGIT): Likewise.
28166         * lib/posixtm.c (ISDIGIT, year): Likewise.
28167         * lib/strverscmp.c (ISDIGIT): Likewise.
28168         * lib/userspec.c (ISDIGIT): Likewise.
28169
28170 2002-01-16  Jim Meyering  <meyering@lucent.com>
28171
28172         * lib/getdate.y: Add three semicolons, each just before a closing
28173         brace. Bison (as of version 1.31) no longer papers over that mistake.
28174
28175 2002-01-05  Jim Meyering  <meyering@lucent.com>
28176
28177         * lib/version-etc.c (version_etc_copyright): Update copyright year.
28178
28179 2001-12-19  Paul Eggert  <eggert@twinsun.com>
28180
28181         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
28182         not silently exit merely because the output buffer happens to
28183         have nothing pending.
28184
28185 2001-12-18  Paul Eggert  <eggert@twinsun.com>
28186
28187         See the big note in ../ChangeLog.
28188         * lib/human.c (suffixes): Prefer K to k for 1024.
28189         (generate_suffix_backwards): New function.
28190         (human_readable_inexact): Use it.
28191         * lib/xstrtol.c (__xstrtol): If there is no number but there
28192         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
28193         Accept 'K' as well as 'k'.
28194
28195 2001-12-15  Jim Meyering  <meyering@lucent.com>
28196
28197         * lib/regex.h (__restrict_arr): Update from libc.
28198
28199         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
28200         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
28201         (STREQ): Define.
28202
28203 2001-12-14  Jim Meyering  <meyering@lucent.com>
28204
28205         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
28206         Suggestion from Bruno Haible.
28207
28208 2001-12-10  Jim Meyering  <meyering@lucent.com>
28209
28210         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
28211         xrealloc, Instead, include "xalloc.h".
28212         (initbuffer): Don't cast xmalloc return value to char*.
28213         (readline): Reword comment.
28214         Don't cast xrealloc return value to char*
28215         Return NULL, not 0.
28216
28217 2001-12-09  Jim Meyering  <meyering@lucent.com>
28218
28219         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
28220         about `signed and unsigned type in conditional expression'.
28221         * lib/posixtm.c (posix_time_parse): Likewise.
28222
28223         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
28224
28225         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
28226         to avoid a pedantic warning.
28227
28228         * lib/getstr.c: Don't include assert.h.
28229         (getstr): Remove warning-evoking assertions.
28230         Return -1 if offset parameter is out of bounds.
28231         Change the type of a local from int to size_t.
28232
28233         * lib/strftime.c (my_strftime_localtime_r): Include this function
28234         definition in the `#if ! HAVE_TM_GMTOFF' block.
28235
28236         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
28237         Include xalloc.h instead.
28238
28239 2001-12-02  Jim Meyering  <meyering@lucent.com>
28240
28241         * lib/tempname.c: Don't declare getenv, thus reverting the change of
28242         2001-11-18.  It's no longer necessary, now that stdlib.h is always
28243         included.
28244
28245         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
28246         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
28247
28248 2001-11-30  Akim Demaille  <akim@epita.fr>
28249
28250         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
28251         before being defined.
28252
28253 2001-11-27  Paul Eggert  <eggert@twinsun.com>
28254
28255         * lib/quotearg.h (quotearg_n, quotearg_n_style):
28256         First arg is int, not unsigned.
28257         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
28258         (SIZE_MAX, UINT_MAX): New macros.
28259         (quotearg_n_options): Abort if N is negative.
28260         Avoid overflow check on hosts where size_t is 64 bits and int
28261         is 32 bits, as overflow is impossible there.
28262         Fix off-by-one typo that caused unnecessary reallocation.
28263
28264 2001-11-27  Jim Meyering  <meyering@lucent.com>
28265
28266         * lib/tempname.c: Merge with version from libc.
28267         * lib/regex.c: Likewise.
28268
28269         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
28270         systems for which STDC_HEADERS is 0, it was not included, resulting in
28271         a warning about an integer-to-pointer conversion problem with getenv.
28272         Reported by Volker Borchert.
28273
28274 2001-11-26  Jim Meyering  <meyering@lucent.com>
28275
28276         * lib/gtod.h: Remove file.
28277         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
28278         * lib/gettimeofday.c: Don't include gtod.h.
28279         (GTOD_init): Remove function.
28280         (rpl_gettimeofday): Do its job here instead, rather than aborting.
28281         Suggestion from Volker Borchert.
28282
28283 2001-11-23  Jim Meyering  <meyering@lucent.com>
28284
28285         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
28286         it.
28287         * lib/hash.c (struct hash_table): Define it here instead.
28288
28289 2001-11-22  Jim Meyering  <meyering@lucent.com>
28290
28291         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
28292
28293 2001-11-20  Jim Meyering  <meyering@lucent.com>
28294
28295         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
28296         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
28297
28298 2001-11-19  Jim Meyering  <meyering@lucent.com>
28299
28300         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
28301         directory.  Use "conftestXXXXXX" as the template.
28302         Suggestion from Paul Eggert.
28303
28304         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
28305         immediately, so the test doesn't mistakenly hit the max-open-files
28306         limit.
28307
28308 2001-11-18  Paul Eggert  <eggert@twinsun.com>
28309
28310         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
28311         (TEMPORARIES): New macro.
28312         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
28313         removes an artificial limitation (e.g. HP-UX 10.20, where
28314         TMP_MAX is 17576).
28315
28316 2001-11-18  Jim Meyering  <meyering@lucent.com>
28317
28318         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
28319
28320 2001-11-18  Jim Meyering  <meyering@lucent.com>
28321
28322         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
28323         on SunOS 4.
28324
28325         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
28326         files will be created before anything else.
28327
28328 2001-11-17  Paul Eggert  <eggert@twinsun.com>
28329
28330         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
28331         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
28332
28333 2001-11-17  Jim Meyering  <meyering@lucent.com>
28334
28335         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
28336         Prompted by a report from Bob Proulx.
28337
28338         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
28339         Instead, require UTILS_FUNC_MKSTEMP.
28340
28341 2001-11-17  Jim Meyering  <meyering@lucent.com>
28342
28343         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
28344         Now, that's done as part of AC_FUNC_STRTOD.
28345
28346 2001-11-17  Jim Meyering  <meyering@lucent.com>
28347
28348         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
28349         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
28350         rather than group writable.  Patch by Juan F. Codagnone.
28351
28352         * lib/readtokens.c: Remove explicit declarations of xmalloc and
28353         xrealloc, Instead, include "xalloc.h".
28354
28355         * lib/mountlist.c: Include unlocked-io.h after all system headers.
28356         Remove explicit declarations of xmalloc, xrealloc,
28357         and xstrdup.  Instead, include "xalloc.h".
28358
28359         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
28360         unlocked-io.h.
28361         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
28362         Likewise.
28363         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
28364
28365         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
28366         Reported by Padraig Brady.
28367
28368         * lib/mkstemp.c: #undef mkstemp.
28369         Include config.h.
28370         (rpl_mkstemp): Rename from mkstemp.
28371         Protoize.
28372
28373 2001-11-16  Jim Meyering  <meyering@lucent.com>
28374
28375         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
28376         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
28377         determine the amount of total physical memory, use pstat_getstatic.
28378         HPUX-11 doesn't define _SC_PHYS_PAGES.
28379         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
28380         If sysconf couldn't be used to determine the amount of available
28381         physical memory, use both pstat_getstatic and pstat_getdynamic.
28382         Based on a patch from Bob Proulx.
28383
28384 2001-11-10  Jim Meyering  <meyering@lucent.com>
28385
28386         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
28387         (jm_PREREQ): Use it.
28388
28389 2001-11-09  Jim Meyering  <meyering@lucent.com>
28390
28391         * m4/jm-macros.m4: Require autoconf-2.52f.
28392         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
28393         Use these AC_-prefixed names, not the AM_-prefixed ones.
28394
28395         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
28396
28397 2001-11-05  Jim Meyering  <meyering@lucent.com>
28398
28399         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
28400
28401 2001-11-04  Jim Meyering  <meyering@lucent.com>
28402
28403         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
28404         $DEFS.
28405
28406 2001-11-03  Jim Meyering  <meyering@lucent.com>
28407
28408         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
28409         of AC_DEFUN.
28410
28411         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
28412         know the name of the variable in the macro definition.
28413
28414 2001-11-03  Jim Meyering  <meyering@lucent.com>
28415
28416         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
28417         in argmatch_to_argument call.
28418
28419         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
28420         argument.
28421
28422         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
28423         e.g., a fault due to an attempt to free a NULL pointer.
28424
28425 2001-11-01  Jim Meyering  <meyering@lucent.com>
28426
28427         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
28428         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
28429
28430 2001-11-01  Jim Meyering  <meyering@lucent.com>
28431
28432         * lib/dirfd.c, lib/dirfd.h: New files.
28433         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
28434
28435         * lib/hash.c (hash_print) [TESTING]: Clean up.
28436
28437 2001-10-22  Paul Eggert  <eggert@twinsun.com>
28438
28439         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
28440         to avoid a warning if -Wall.
28441
28442 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
28443
28444         * README: New file
28445         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
28446         (per RMS's instructions, this is now the canonical source)
28447         * lgpl/, gpl/: New directories.
28448
28449 2001-10-21  Paul Eggert  <eggert@twinsun.com>
28450
28451         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
28452
28453 2001-10-21  Jim Meyering  <meyering@lucent.com>
28454
28455         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
28456         this code would end up calling gettext even in packages built
28457         with --disable-nls.
28458         * lib/getopt.c (_): Likewise.
28459         * lib/regex.c (_): Likewise.
28460
28461 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28462
28463         * m4/error.m4 (jm_PREREQ_ERROR):
28464         Do not invoke AC_CHECK_FUNCS with strerror_r, as
28465         AC_FUNC_STRERROR_R does that.
28466         Check for strerror declaration.
28467
28468         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
28469         are supposed to have them these days.
28470         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
28471         Merge changes from latest Autoconf CVS.
28472         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
28473         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
28474         POSIX decided to standardize on the int flavor of strerror_r.
28475
28476 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28477
28478         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
28479         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
28480         Use strerror_r that is only a macro, even if it is not a function.
28481         (strerror): Check for HAVE_DECL_STRERROR before declaring.
28482         (private_strerror): Use prototypes, not old-style function definition.
28483         (print_errno_message): New function.
28484         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
28485         char*-flavored one.
28486         (error_tail, error, error_at_line): Use it.
28487
28488 2001-10-11  Jim Meyering  <meyering@lucent.com>
28489
28490         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
28491         and quote_n (1, ... to avoid clobbering a buffer.
28492
28493 2001-10-05  Jim Meyering  <meyering@lucent.com>
28494
28495         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
28496         hash-pjw.h.
28497         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
28498         * lib/hash-pjw.h: New file.
28499
28500 2001-09-30  Jim Meyering  <meyering@lucent.com>
28501
28502         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
28503         `struct fsstat' has the `f_fstypename' member.
28504         Use that to define FS_TYPE, which is now used to make
28505         the getfsstat link test tighter.
28506
28507 2001-09-30  Jim Meyering  <meyering@lucent.com>
28508
28509         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
28510         Include <sys/ucred.h>, for Apple Darwin.
28511         Include sys/mount.h and sys/fs_types.h only if available.
28512         (FS_TYPE): Define.
28513         (read_filesystem_list): Use FS_TYPE.
28514
28515 2001-09-29  Paul Eggert  <eggert@twinsun.com>
28516
28517         * lib/exclude.c (excluded_filename): 0 -> false, since it's
28518         a boolean context.
28519
28520 2001-09-29  Jim Meyering  <meyering@lucent.com>
28521
28522         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
28523         [one-argument getmntent function]): Include stdio.h before mntent.h.
28524         SunOS 4.1.x needs it for the declaration of `FILE'.
28525         Patch by Volker Borchert.
28526
28527         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
28528         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
28529         sys/fs_types.h, and make the link-test for getfsstat guard #include
28530         directives with appropriate #if HAVE_*_H tests so that we can
28531         detect getfsstat on Apple Darwin1.3.7 systems.
28532         Reported by Nelson Beebe.
28533         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
28534
28535 2001-09-28  Paul Eggert  <eggert@twinsun.com>
28536
28537         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
28538         #defines strtoimax.  Also treat the other strto* functions
28539         like strtoimax.
28540
28541         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
28542         Check for strtoul and strtoumax,
28543         as those declarations are made even in the signed case.
28544         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
28545         Likewise, for strtol and strtoimax.
28546
28547 2001-09-28  Paul Eggert  <eggert@twinsun.com>
28548
28549         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
28550         #defines strtoimax.  Also treat the other strto* functions
28551         like strtoimax.
28552
28553         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
28554         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
28555         (strtoimax, strtoumax): Do not declare if already defined as a macro.
28556
28557 2001-09-26  Jim Meyering  <meyering@lucent.com>
28558
28559         Most macros in unlocked-io.h had the wrong number of arguments.
28560         * lib/gen-uio: New script.
28561         (USE_UNLOCKED_IO): Define to 1 if not already defined.
28562         * lib/unlocked-io.hin: Remove file.
28563         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
28564         rather than trying to embed it here.
28565         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
28566         Reported by Padraig Brady.
28567
28568 2001-09-25  Volker Borchert  <bt@teknon.de>
28569
28570         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
28571         `result'.
28572
28573 2001-09-24  Jim Meyering  <meyering@lucent.com>
28574
28575         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
28576
28577 2001-09-23  Jim Meyering  <meyering@lucent.com>
28578
28579         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
28580         instead of the mere test for existence of mntent.h.  The latter
28581         would get a false-positive on AIX 3.4 systems.
28582         In the outer getmntent if-block, don't die if neither of the getmntent
28583         tests succeeds.  Instead, just fall through and continue with the
28584         remaining tests.
28585
28586 2001-09-23  Jim Meyering  <meyering@lucent.com>
28587
28588         * lib/mountlist.c: Remove useless parentheses in #if directives.
28589         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
28590         the deprecated MOUNTED symbol is no longer defined in mntent.h.
28591
28592 2001-09-22  Jim Meyering  <meyering@lucent.com>
28593
28594         * m4/gettext.m4: New file.  From gettext.
28595         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
28596         * m4/progtest.m4: Likewise
28597         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
28598         * m4/glibc21.m4: Likewise.
28599
28600         * m4/libintl.m4: Remove.  No longer used.
28601
28602 2001-09-22  Jim Meyering  <meyering@lucent.com>
28603
28604         * lib/localcharset.c: Update from latest gettext.
28605         * lib/config.charset: Likewise.
28606
28607 2001-09-20  Jim Meyering  <meyering@lucent.com>
28608
28609         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
28610         strtoimax.
28611         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
28612         strtoumax.
28613
28614 2001-09-20  Jim Meyering  <meyering@lucent.com>
28615
28616         * lib/xstrtol.c (strtoimax): Guard declaration with
28617         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
28618         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
28619         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
28620         (strtoumax): Likewise, for completeness (it wasn't necessary).
28621
28622 2001-09-17  Paul Eggert  <eggert@twinsun.com>
28623
28624         * lib/strtoimax.c (HAVE_LONG_LONG):
28625         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
28626         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
28627         to work around bug in IBM C compiler.
28628
28629 2001-09-17  Jim Meyering  <meyering@lucent.com>
28630
28631         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
28632         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
28633         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
28634         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
28635         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
28636         whenever the right hand side need not be expanded by the shell.
28637
28638 2001-09-16  Paul Eggert  <eggert@twinsun.com>
28639
28640         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
28641         library.  It's not correct, as some older glibcs are buggy.
28642         fnmatch wasn't fixed until glibc 2.2.
28643
28644         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
28645         special shell magic here.
28646
28647 2001-09-16  Jim Meyering  <meyering@lucent.com>
28648
28649         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
28650         * m4/jm-macros.m4: Require it.
28651
28652 2001-09-16  Jim Meyering  <meyering@lucent.com>
28653
28654         * lib/mkdir.c: New file.
28655
28656 2001-09-15  Jim Meyering  <meyering@lucent.com>
28657
28658         * m4/jm-macros.m4: Check for help2man.
28659
28660 2001-09-11  Jim Meyering  <meyering@lucent.com>
28661
28662         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
28663         The body, by Paul Eggert, was moved here from configure.in.
28664         * m4/jm-macros.m4: Require UTILS_HOST_OS.
28665
28666 2001-09-04  Paul Eggert  <eggert@twinsun.com>
28667
28668         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
28669         (jm_PREREQ): Use it.
28670
28671 2001-09-04  Paul Eggert  <eggert@twinsun.com>
28672
28673         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
28674         Use ssize_t, not int, to store result of readlink.
28675         Check for ssize_t overflow as well as size_t overflow,
28676         as POSIX says the result of readlink is implementation-defined
28677         when ssize_t overflows.
28678         Remove unnecessary cast to char*.
28679         Use free+malloc instead of realloc, as the storage doesn't need
28680         to be preserved and it's clearer and can be more efficient that way.
28681         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
28682         * lib/xreadlink.h (xreadlink): Update prototype.
28683
28684 2001-09-04  Paul Eggert  <eggert@twinsun.com>
28685
28686         * lib/xgetcwd.c: Revert some of the previous change; intead,
28687         fix the HAVE_GETCWD_NULL code to behave more like the
28688         !HAVE_GETCWD_NULL code used to.
28689
28690         Include "xalloc.h".
28691         (xgetcwd): Do not return NULL when memory is exhausted; instead,
28692         invoke xalloc_die.
28693
28694 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28695
28696         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
28697         sys/param.h, as pathmax.h includes them.
28698
28699 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28700
28701         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
28702         (jm_PREREQ_XGETCWD): New macro.
28703
28704         * m4/getcwd.m4: New file.
28705
28706 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28707
28708         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
28709         like the HAVE_GETCWD_NULL code.
28710         Include pathmax.h if not HAVE_GETCWD.
28711         Do not include xalloc.h.
28712         (INITIAL_BUFFER_SIZE): New symbol.
28713         Do not use xmalloc / xrealloc, since the caller is responsible for
28714         handling errors.  Preserve errno around `free' during failure.
28715         Do not overrun buffer when using getwd.
28716
28717 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28718
28719         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
28720         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
28721         getcwd (NULL, 0).
28722
28723 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28724
28725         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
28726         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
28727         spotted by Jim Meyering.
28728
28729 2001-09-03  Jim Meyering  <meyering@lucent.com>
28730
28731         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
28732         failure.
28733
28734 2001-09-02  Jim Meyering  <meyering@lucent.com>
28735
28736         * lib/error.c: Update from GNU libc.
28737
28738 2001-09-01  Jim Meyering  <meyering@lucent.com>
28739
28740         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
28741         Used by df.
28742
28743 2001-09-01  Jim Meyering  <meyering@lucent.com>
28744
28745         * lib/xreadlink.c: New file.
28746         * lib/xreadlink.h: New file.
28747         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
28748         xreadlink.h.
28749
28750         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
28751         doesn't conflict with sparc Solaris 7's definition in
28752         /usr/include/sys/int_types.h.
28753
28754         * lib/exclude.c: Use `""', not `<>' to #include non-system header
28755         files.
28756         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
28757         and strncasecmp as r-values.  Unixware didn't have declarations.
28758
28759 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28760
28761         * lib/xstrtol.h: Add copyright notice.
28762         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
28763         LONGINT_INVALID_SUFFIX_CHAR.
28764
28765 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28766
28767         * lib/xstrtol.c (strtoimax): New decl.
28768
28769 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28770
28771         * lib/xgetcwd.c: Don't include pathmax.h.
28772         Include stdlib.h and unistd.h if available.
28773         Include xalloc.h.
28774         (xmalloc, xstrdup, free): Remove decls.
28775         (xgetcwd): Don't assume sizes fit in unsigned.
28776         Check for overflow when computing sizes.
28777         Simplify reallocation code.
28778
28779 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28780
28781         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
28782         a directory's st_size can have an arbitrary value, so the old
28783         usage could waste an arbitrary amount of memory.  All uses
28784         changed.
28785         * lib/savedir.h: Update prototype.
28786
28787 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28788
28789         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
28790
28791         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
28792         old strtoimax.c.
28793
28794         Also, make the following further changes to make this file's
28795         configuration more similar to that of strtol.c:
28796         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
28797         (strtoumax, uintmax_t, strtoull, strtol): Remove.
28798         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
28799         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
28800         changed to signed values.
28801
28802         And make the following changes as well:
28803         Fix copyright notice, as 1999 was missing.
28804         (verify): New macro.
28805         (strtoimax): Check sizes at compile-time, not run-time.
28806         Prefer strtol to strtoll if both work.
28807         (main): Remove; it was not that useful and was a pain to maintain.
28808
28809         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
28810
28811 2001-08-31  Jim Meyering  <meyering@lucent.com>
28812
28813         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
28814         Use an initial, malloc'd, buffer of length 128 rather than
28815         a statically allocated one of length 1024.
28816
28817 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28818
28819         Simplify code, partly by assuming autoconf 2.52 semantics.
28820
28821         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
28822
28823         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
28824         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
28825         All uses removed.
28826         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
28827         Move AC_REQUIRE to next-to-top level, to avoid confusion.
28828         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
28829         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
28830         jm_AC_HEADER_INTTYPES_H.
28831         * m4/jm-macros.m4 (jm_MACROS): Likewise.
28832
28833         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
28834
28835         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
28836         Quote first arg of AC_DEFUN.
28837         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
28838         since they are needed to parse the include file even if we need
28839         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
28840         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
28841         but with opposite signedness.
28842
28843 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28844
28845         Merge 'exclude' changes from tar 1.13.22.
28846         This fixes one or two unlikely storage allocation overflow bugs,
28847         but doesn't change user-visible behavior otherwise.
28848
28849 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28850
28851         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
28852         (jm_PREREQ_EXCLUDE): New macro.
28853
28854 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28855
28856         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
28857         tm to be declared.
28858
28859 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28860
28861         * lib/hash.c: Remove '2001' from copyright notice.
28862
28863 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28864
28865         * lib/full-write.h: New file.
28866         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
28867         * lib/full-write.c: Correct credits, as cccp.c no longer
28868         exists and anyway it was so heavily changed from the old cccp
28869         code as to be unrecognizable.  Include full-write.h.
28870         (full_write) Return size_t, with short writes meaning failure.
28871         All callers changed.  This fixes a bug with large buffers
28872         on 64-bit hosts.
28873         * lib/utime.c: Include full-write.h.
28874
28875 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28876
28877         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
28878         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
28879         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
28880         Include if available.
28881         (<xalloc.h>): Include
28882         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
28883         (verify): New macro.  Use it to verify that EXCLUDE macros do not
28884         collide with FNM macros.
28885         (struct patopts): New struct.
28886         (struct exclude): Use it, as exclude patterns now come with options.
28887         (new_exclude): Support above changes.
28888         (new_exclude, add_exclude_file):
28889         Initial size must now be a power of two to simplify overflow checking.
28890         (free_exclude, fnmatch_no_wildcards): New function.
28891         (excluded_filename): No longer requires options arg, as the options
28892         are determined by add_exclude.  Now returns bool, not int.
28893         (excluded_filename, add_exclude):
28894         Add support for the fancy new exclusion options.
28895         (add_exclude, add_exclude_file): Now takes int options arg.
28896         Check for arithmetic overflow when computing sizes.
28897         (add_exclude_file): xrealloc might modify errno, so don't
28898         realloc until after errno might be used.
28899
28900         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
28901         New macros.
28902         (free_exclude): New decl.
28903         (add_exclude, add_exclude_file): Now takes int options arg.
28904         (excluded_filename): No longer requires options arg, as the options
28905         are determined by add_exclude.  Now returns bool, not int.
28906
28907 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28908
28909         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
28910
28911 2001-08-27  Jim Meyering  <meyering@lucent.com>
28912
28913         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
28914
28915         * lib/version-etc.c (N_): Remove definition.
28916         Revert most of last change.
28917         Instead, simply don't mark the `Copyright...' string for translation.
28918         Based on advice from Paul Eggert.
28919
28920         * lib/strtoxmax.c: Tweak comment.
28921
28922 2001-08-26  Jim Meyering  <meyering@lucent.com>
28923
28924         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
28925
28926         * m4/xstrtoimax.m4: New file.
28927         * m4/xstrtoumax.m4: Add comments explaining why we
28928         AC_REPLACE_FUNCS(strtol).
28929
28930 2001-08-26  Jim Meyering  <meyering@lucent.com>
28931
28932         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
28933         of copyright with `%s' so translators don't get an untranslated
28934         message in 2002.
28935         (COPYRIGHT_YEAR): Define.
28936         (version_etc): Use fprintf rather than fputs.
28937         Suggestion from Ulrich Drepper.
28938
28939         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
28940
28941         * lib/strtoll.c: New file, from GNU libc.
28942         * lib/xstrtoimax.c: New file.
28943
28944         * lib/xstrtol.h: Add xstrtoimax.
28945         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
28946         * lib/strtoimax.c: New file.  Likewise, but first define
28947         STRTOUXMAX_SIGNED.
28948
28949         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
28950         ...
28951         * lib/strtoxmax.c: ... then renamed to this.
28952
28953 2001-08-18  Paul Eggert  <eggert@twinsun.com>
28954
28955         * m4/inttypes.m4: Add AC_PREREQ(2.13).
28956         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
28957         (jm_AC_TYPE_INTMAX_T): New macro.
28958         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
28959
28960         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
28961
28962         * m4/longlong.m4: Renamed from ulonglong.m4.
28963         * m4/inttypes.m4: Renamed from inttypes_h.m4.
28964         * m4/uintmax_t.m4: Removed.
28965
28966 2001-08-13  Paul Eggert  <eggert@twinsun.com>
28967
28968         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
28969         Port to Solaris 8, where 'sed' requires a space after the 'r'
28970         command, and where sh dislikes "$/".  Clean up the spacing a bit.
28971         Redirect output to $tmp just once.
28972
28973 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
28974
28975         * lib/addext.c (<errno.h>): Include.
28976         (errno): Declare if not defined.
28977         (addext): Work correctly when pathconf returns -1 and leaves
28978         errno alone because there is no limit.  Also, work even if
28979         pathconf returns a value greater than SIZE_MAX.
28980
28981 2001-08-12  Jim Meyering  <meyering@lucent.com>
28982
28983         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
28984         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
28985         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
28986         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
28987         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
28988         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
28989         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
28990         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
28991         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
28992         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
28993         utime.m4, utimes.m4, xstrtoumax.m4:
28994         Quote the first argument in each use of AC_DEFUN.
28995
28996 2001-08-12  Jim Meyering  <meyering@lucent.com>
28997
28998         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
28999         Simply `return getcwd (NULL, 0);'.
29000         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
29001         Use 1300 as initial value for length, not PATH_MAX.
29002
29003         * lib/pathmax.h: Clean up cpp syntax.
29004
29005 2001-08-12  Jim Meyering  <meyering@lucent.com>
29006
29007         * lib/gettimeofday.c: New file.
29008         * lib/gtod.h: New file.
29009         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
29010
29011 2001-08-05  Jim Meyering  <meyering@lucent.com>
29012
29013         * m4/jm-macros.m4: Require autoconf-2.52.
29014
29015 2001-08-04  Jim Meyering  <meyering@lucent.com>
29016
29017         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
29018         stmt, to get in sync with glibc.
29019
29020 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29021
29022         The following changes are from gettext 0.10.39 as maintained by
29023         Bruno Haible.
29024
29025         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
29026         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
29027         with inverted sense.  All uses changed.
29028
29029         * lib/mbswidth.c: Don't include <limits.h>.
29030         Include <stdlib.h> and <string.h> unconditionally.
29031         (iswcntrl, mbsinit, ISCNTRL): New macros.
29032         (mbsnwidth): Use K&R style function declarations.
29033         Don't bother checking for MB_LEN_MAX == 1, since the compiler
29034         can optimize it when MB_CUR_MAX == 1.
29035         The width of control characters is zero, not 1.
29036
29037 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29038
29039         The following changes are from gettext 0.10.39 as maintained by
29040         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
29041
29042         * m4/codeset.m4: Upgrade to serial AM1.
29043         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
29044         all uses changed.  Quote first arg of AC_DEFUN.
29045         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
29046
29047         * m4/iconv.m4: Upgrade to serial AM2.
29048         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
29049         Add --with-libconv-prefix.
29050         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
29051         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
29052         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
29053         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
29054         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
29055
29056         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
29057         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
29058         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
29059         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
29060         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
29061         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
29062         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
29063         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
29064         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
29065
29066         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
29067         string.h any more.
29068
29069         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
29070         not the default value.
29071
29072         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
29073         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
29074         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
29075         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
29076         Also check for iswcntrl, used for wcwidth fallback.
29077         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
29078         to Autoconf 2.13.
29079
29080 2001-08-03  Jim Meyering  <meyering@lucent.com>
29081
29082         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
29083         as it was in the original.  Reported by Paul Eggert.
29084
29085 2001-07-16  Jim Meyering  <meyering@lucent.com>
29086
29087         * m4/gettimeofday.m4: New file.
29088         Prompted by a report from Bernhard Baehr.
29089
29090 2001-07-15  Jim Meyering  <meyering@lucent.com>
29091
29092         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
29093         stuff. Now it's in ../Makefile.cfg.
29094
29095 2001-07-15  Jim Meyering  <meyering@lucent.com>
29096
29097         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
29098         (BUILT_SOURCES): Add unlocked-io.h.
29099         (io_functions): Define.
29100         (unlocked-io.h): New rule.
29101         (DISTCLEANFILES): Add unlocked-io.h.
29102         (all-local): Depend on unlocked-io.h, to ensure it is created.
29103
29104         * lib/unlocked-io.hin: New file
29105
29106         * lib/regex.c: Update from glibc.
29107
29108 2001-07-05  Jim Meyering  <meyering@lucent.com>
29109
29110         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
29111         recommendation.
29112         (libfetish_a_SOURCES): Put all .h files here instead.
29113         Remove a thus-exposed (better checks in automake) duplicate and
29114         two unnecessary .h files.
29115
29116 2001-07-04  Jim Meyering  <meyering@lucent.com>
29117
29118         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
29119         that generates jm-glibc-io.m4 so that it doesn't trigger any make
29120         distcheck failure.
29121
29122 2001-07-02  Jim Meyering  <meyering@lucent.com>
29123
29124         The following changes were prompted by suggestions from Bruno Haible.
29125
29126         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
29127         is now generated.
29128         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
29129         definition of EXTRA_DIST.
29130         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
29131         ensure that the generated file is created/updated whenever the list
29132         of $(unlocked_functions) is changed.
29133         (jm-glibc-io.m4): New rule.
29134         (unlocked-io.h): New rule -- currently unused.
29135
29136 2001-06-24  Jim Meyering  <meyering@lucent.com>
29137
29138         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
29139         unmatched right bracket, rather than kludging it with an extra,
29140         falsely-matching quote in a comment.  Patch by Akim Demaille.
29141
29142 2001-06-11  Jim Meyering  <meyering@lucent.com>
29143
29144         * lib/regex.c: Update from GNU libc.
29145
29146 2001-05-27  Jim Meyering  <meyering@lucent.com>
29147
29148         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
29149         Check for ut_type in struct utmp.
29150
29151 2001-05-27  Jim Meyering  <meyering@lucent.com>
29152
29153         * lib/readutmp.h (UT_TYPE): Define.
29154
29155 2001-05-24  Jim Meyering  <meyering@lucent.com>
29156
29157         * lib/argmatch.c: Include "quote.h".
29158         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
29159         quote function.  Reported by Göran Uddeborg.
29160
29161 2001-05-22  Jim Meyering  <meyering@lucent.com>
29162
29163         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
29164         now that we use the package-supplied version unconditionally.
29165         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
29166
29167 2001-05-21  Jim Meyering  <meyering@lucent.com>
29168
29169         * m4/regex.m4: Change a couple backticks to single quotes to avoid
29170         shell syntax errors.
29171
29172 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29173
29174         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
29175
29176 2001-05-20  Paul Eggert  <eggert@twinsun.com>
29177
29178         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
29179         Don't bother to check library strftime, since
29180         we'll be using our own my_strftime function anyway.
29181         Define my_strftime instead of strftime.
29182
29183 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
29184
29185         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
29186         which is not yet declared.
29187
29188 2001-05-15  Jim Meyering  <meyering@lucent.com>
29189
29190         * m4/regex.m4: Use proper quoting so brackets appear in the test
29191         program.
29192         Reported by, and with help from, Bruno Haible.
29193
29194 2001-05-13  Jim Meyering  <meyering@lucent.com>
29195
29196         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
29197         undefined.
29198
29199 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29200
29201         dirname code cleanup.  base_name now behaves more compatibly
29202         with POSIX basename when given file names that have trailing
29203         slashes, and similarly for dir_name.  Add new primitives
29204         base_len and dir_len.  Put the directory-name-related decls
29205         into dirname.h.
29206
29207         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
29208         * lib/backupfile.c (base_name): Likewise.
29209         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
29210         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
29211         * lib/makepath.c (strip_trailing_slashes): Likewise.
29212         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
29213         ISSLASH): Likewise.
29214         * lib/rename.c (strip_trailing_slashes): Likewise.
29215         * lib/same.c (base_name): Likewise.
29216         * lib/stripslash.c (ISSLASH): Likewise.
29217
29218         * lib/addext.c: Include <dirname.h> after size_t is defined.
29219         * lib/backupfile.c: Likewise.
29220
29221         * lib/addext.c (addext): Use base_len to trim redundant
29222         trailing slashes instead of doing it ourselves.
29223         But do not trim the last slash if it is not redundant.
29224
29225         * lib/backupfile.c (find_backup_file_name,
29226         max_backup_version): Use base_len instead of rolling it ourselves.
29227         Handle the case of "" and (on DOS) "C:" correctly.
29228
29229         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
29230         needed. Include <string.h>, <dirname.h>.
29231         (base_name): Allow file names ending in slashes, other than names
29232         that are all slashes.  In this case, return the basename followed
29233         by the slashes.  This is more general, and can be used in places
29234         where the original base_name purposely had an assertion failure.
29235         (base_len): New function.
29236
29237         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
29238         Do not include <assert.h>; no longer needed.
29239         Include xalloc.h.
29240         (memrchr): Remove decl.
29241         (dir_name_r): Remove.
29242         (dir_len): Renamed from dirlen.  All callers changed.
29243         Rewrite in terms of base_name, for simplicity and consistency.
29244         (dir_name): Never return NULL.  All callers changed.
29245         Do not include <stdlib.h> in test program; no longer needed.
29246         return 0; is fine for test program.
29247
29248         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
29249         New macros.
29250         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
29251
29252         * lib/path-concat.c (path_concat): Use base_len to compute
29253         base length, not strlen; this means we cannot rely on memcpy
29254         to null-terminate.
29255
29256         * lib/same.c (STREQ): Remove.
29257         (same_name): Handle the case where the basename ends in trailing '/'.
29258
29259         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
29260         a slash was stripped.  Do not strip the last slash after a
29261         file system prefix.
29262
29263 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29264
29265         * lib/Makefile.am (libfetish_a_SOURCES):
29266         Add strftime.c, since we now compile it on all hosts.
29267
29268         * lib/strftime.c (my_strftime):
29269         Define to nstrftime if emacs, but only if my_strftime is not defined.
29270         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
29271         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
29272         Add one more extra argument: a nanoseconds value.
29273         All uses changed.
29274         (ns): New macro.
29275         (my_strftime function): Add %N format.
29276         (emacs_strftimeu): Renamed from emacs_strftime,
29277         with extra ut argument.
29278
29279 2001-05-09  Paul Eggert  <eggert@twinsun.com>
29280
29281         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
29282
29283 2001-04-21  Jim Meyering  <meyering@lucent.com>
29284
29285         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
29286         doesn't interfere.
29287
29288 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29289
29290         * m4/ftruncate.m4: Check for chsize.
29291         Link with ftruncate.o unconditionally if ftruncate is missing.
29292         This was required when cross-compiling to i586-mingw32msvc.
29293
29294 2001-04-08  Jim Meyering  <meyering@lucent.com>
29295
29296         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
29297         recomputed; that's necessary when the offset spans a DST transition.
29298         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
29299
29300 2001-04-02  Jim Meyering  <meyering@lucent.com>
29301
29302         * lib/regex.h, regex.c: Update from GNU libc.
29303
29304 2001-03-24  Jim Meyering  <meyering@lucent.com>
29305
29306         * m4/jm-macros.m4: Require autoconf-2.49d.
29307
29308 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
29309
29310         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
29311
29312 2001-03-19  Paul Eggert  <eggert@twinsun.com>
29313
29314         * lib/version-etc.c (version_etc_copyright): Update to 2001.
29315
29316 2001-03-17  Jim Meyering  <meyering@lucent.com>
29317
29318         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
29319         now that the version in autoconf is equivalent.
29320         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
29321
29322         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
29323         Suggestion from Akim Demaille.
29324
29325         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
29326         (jm_PREREQ_TEMPNAME): New function.
29327
29328 2001-03-16  Paul Eggert  <eggert@twinsun.com>
29329
29330         * lib/tempname.c (uint64_t): Define to uintmax_t if
29331         not defined, and if UINT64_MAX is not defined.
29332         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
29333         Reported by John David Anglin.
29334
29335 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
29336
29337         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
29338         resolve alias if codeset is empty.
29339         * lib/config.charset (BeOS): Use wildcard syntax.
29340
29341 2001-03-13  Jim Meyering  <meyering@lucent.com>
29342
29343         * lib/path-concat.c (path_concat)
29344         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
29345         concatenating e.g., `C:' and `foo'.
29346         From Bruno Haible.
29347
29348 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29349
29350         * lib/localcharset.c (locale_charset): Don't use
29351         setlocale(LC_CTYPE,NULL). Don't return NULL.
29352         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
29353
29354 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29355
29356         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
29357         support for DOS/DJGPP.
29358
29359 2001-03-01  Paul Eggert  <eggert@twinsun.com>
29360
29361         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
29362         lacks mkstemp.  Compile our own tempname.c if we compile our own
29363         mkstemp.c, as mkstemp relies on tempname.
29364
29365 2001-03-01  Jim Meyering  <meyering@lucent.com>
29366
29367         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
29368         AH_VERBATIM really does output its argument verbatim.
29369
29370 2001-02-28  Paul Eggert  <eggert@twinsun.com>
29371
29372         * lib/Makefile.am (libfetish_a_SOURCES):
29373         Add dup-safer.c, fopen-safer.c.
29374         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
29375
29376         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
29377         * lib/unistd-safer.h: New files.
29378
29379 2001-02-25  Paul Eggert  <eggert@twinsun.com>
29380
29381         The mkstemp replacement is taken from glibc 2.2.2, with some
29382         portability fixes for use outside glibc, as follows:
29383
29384         * lib/tempname.c (struct_stat64): New macro.
29385         (direxists, __gen_tempname): Use it.
29386         This avoids a portability problem with Solaris 8.
29387
29388         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
29389         (<stddef.h>, <stdint.h>, <string.h>):
29390         Include only if STDC_HEADERS || _LIBC.
29391         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
29392         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
29393         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
29394         (__set_errno): Define this macro if <errno.h> doesn't.
29395         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
29396         Define these macros if <stdio.h> doesn't.
29397         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
29398         Define these macros if <sys/stat.h>
29399         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
29400         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
29401         __xstat64): Define if not _LIBC.
29402         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
29403         (__gen_tempname): Invoke gettimeofday only if
29404         HAVE_GETTIMEOFDAY || _LIBC;
29405         otherwise, fall back on plain "time".
29406         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
29407
29408         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
29409
29410         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
29411
29412 2001-02-18  Paul Eggert  <eggert@twinsun.com>
29413
29414         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
29415
29416 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29417
29418         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
29419         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
29420         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
29421         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
29422
29423 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29424
29425         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
29426         Remove workaround macros for hosts that have mbrtowc but not
29427         mbstate_t, as we now insist on proper declarations for both
29428         before using mbrtowc.
29429
29430 2001-02-17  Jim Meyering  <meyering@lucent.com>
29431
29432         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
29433         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
29434         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
29435         UnixWare 7.1.1.
29436
29437         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
29438         rather than AC_CACHE_VAL.
29439
29440 2001-02-17  Jim Meyering  <meyering@lucent.com>
29441
29442         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
29443         around included file name.
29444
29445         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
29446
29447         * lib/strftime.c: Update from GNU libc (the only changes were to
29448         comments).
29449
29450 2001-02-17  Jim Meyering  <meyering@lucent.com>
29451
29452         * lib/regex.c: Update from libc.
29453
29454 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
29455
29456         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
29457         clash.
29458
29459 2001-02-16  Paul Eggert  <eggert@twinsun.com>
29460
29461         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
29462         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
29463         Reported by Mark Hounschell via Paul Eggert.
29464
29465 2001-02-07  Jim Meyering  <meyering@lucent.com>
29466
29467         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
29468
29469 2001-02-05  Jim Meyering  <meyering@lucent.com>
29470
29471         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
29472         it includes the patch required for `large file' support with at least
29473         HP-UX's 10.20 /bin/cc.
29474
29475 2001-02-03  Jim Meyering  <meyering@lucent.com>
29476
29477         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
29478         AS_IF, now that it works once again (mysteriously).
29479         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29480
29481 2001-01-30  Jim Meyering  <meyering@lucent.com>
29482
29483         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
29484         * m4/chown.m4: Rename conftestchown to conftest.chown.
29485         * m4/rename.m4: s/conftestdir/conftest.d1/ and
29486         s/conftestdir2/conftest.d2/.
29487         * m4/utimes.m4: s/conftestdata/conftest.data/
29488         Inspired by Pavel Roskin's change in autoconf.
29489
29490 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
29491
29492         * lib/config.charset: Update for FreeBSD 4.2.
29493
29494 2001-01-27  Jim Meyering  <meyering@lucent.com>
29495
29496         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
29497         a use of AS_IF.
29498         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29499
29500 2001-01-26  Jim Meyering  <meyering@lucent.com>
29501
29502         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
29503         quotearg.c includes it.
29504
29505 2001-01-26  Jim Meyering  <meyering@lucent.com>
29506
29507         * lib/quotearg.c: Include stddef.h.
29508         * lib/quote.c: Include stddef.h.
29509         Reported by Axel Kittenberger.
29510
29511         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
29512         line in double quotes so that it evokes a better diagnostic.
29513         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
29514         Reported by Axel Kittenberger.
29515
29516 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
29517
29518         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
29519         as if it was a `charset'.
29520
29521 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
29522
29523         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
29524         has const.
29525
29526 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
29527
29528         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
29529         to avoid a warning.  Add back 'const' to inptr.
29530
29531 2001-01-20  Jim Meyering  <meyering@lucent.com>
29532
29533         Be sure that headers are checked before used in code compiled
29534         for the type checks.
29535         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
29536         In place of that, invoke jm_CHECK_ALL_TYPES.
29537         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
29538         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
29539         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
29540         The check for ssize_t was mistakenly run before the test for unistd.h.
29541
29542         The configure-time check for stdbool.h was missing.
29543         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
29544         (jm_PREREQ_HASH): New function.
29545
29546 2001-01-17  Jim Meyering  <meyering@lucent.com>
29547
29548         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
29549         for autoconf-2.49c.
29550         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
29551
29552 2001-01-16  Jim Meyering  <meyering@lucent.com>
29553
29554         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
29555         From Bruno Haible.
29556
29557 2001-01-14  Jim Meyering  <meyering@lucent.com>
29558
29559         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
29560         foo and bar.  Create conftestdir/ in the script, not in the C code.
29561         Remove directories in the script, not in the C code.
29562         Remove conftestdir{,2} before trying to create the directory.
29563         Make the entire configure script fail if the mkdir fails.
29564
29565 2001-01-14  Jim Meyering  <meyering@lucent.com>
29566
29567         * lib/rename.c: New file.  From Volker Borchert.
29568         Include stdlib.h, string.h or strings.h, and xalloc.h.
29569         Use strip_trailing_slashes rather than open-coding it.
29570
29571 2001-01-03  Paul Eggert  <eggert@twinsun.com>
29572
29573         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
29574
29575 2001-01-03  Jim Meyering  <meyering@lucent.com>
29576
29577         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
29578         of local `inptr' to avoid warning with some system declarations of
29579         iconv.
29580
29581 2001-01-02  Volker Borchert  <bt@teknon.de>
29582
29583         * m4/rename.m4: New file.
29584         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
29585
29586 2001-01-01  Jim Meyering  <meyering@lucent.com>
29587
29588         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
29589         even on systems with utmpx.h.  It's necessary for the declaration of
29590         utmp's ut_user member.  Reported by Andreas Jaeger.
29591
29592         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
29593         available. They are required for the declarations of getgrgid and
29594         getpwuid resp.
29595         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
29596         Reported by Andreas Jaeger.
29597
29598 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
29599
29600         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
29601         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
29602         so `make install' also works in VPATH builds.
29603
29604 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
29605
29606         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
29607         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
29608         can be used in subdirectories.
29609
29610 2000-12-29  Paul Eggert  <eggert@twinsun.com>
29611
29612         * lib/modechange.c: Do not assume that mode_t uses the
29613         traditional octal encoding.  E.g. "chmod 1 FOO" should set
29614         the other-execute bit of FOO even if S_IXOTH != 1.
29615
29616         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
29617         WOTH, XOTH, ALLM): New macros.
29618         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
29619          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
29620         Use them.
29621         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
29622         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
29623         (mode_compile):
29624         No need to use uintmax_t; unsigned long is long enough.
29625         Don't bother to get suffix since we don't use it.
29626
29627 2000-12-26  Jim Meyering  <meyering@lucent.com>
29628
29629         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
29630         better with autoheader.
29631
29632 2000-12-24  Jim Meyering  <meyering@lucent.com>
29633
29634         * lib/hash.c (is_prime): Return explicit boolean values.
29635         (hash_get_first): Return NULL to appease Irix5.6's 89.
29636         Reported by Nelson Beebe.
29637
29638 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
29639
29640         * lib/localcharset.c (locale_charset): Add support for Win32.
29641
29642 2000-12-18  Paul Eggert  <eggert@twinsun.com>
29643
29644         * lib/physmem.h, lib/physmem.c: New files.
29645
29646         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
29647         (noinst_HEADERS): Add physmem.h.
29648
29649         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
29650         't' for compatibility with Solaris 8 sort.
29651
29652 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
29653
29654         * lib/config.charset: Add support for BeOS.
29655
29656 2000-12-17  Jim Meyering  <meyering@lucent.com>
29657
29658         * m4/dos.m4 (jm_AC_DOS): New file and macro.
29659         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
29660
29661 2000-12-16  Jim Meyering  <meyering@lucent.com>
29662
29663         This bug had a serious impact on chown: `chown N:M FILE' (for integer
29664         N and M) would have treated it like `chown N:N FILE'.
29665
29666         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
29667
29668 2000-12-16  Jim Meyering  <meyering@lucent.com>
29669
29670         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
29671         SHELLS_FILE to a file name that's useful on djgpp systems.
29672         Include stdlib.h.
29673         (ADDITIONAL_DEFAULT_SHELLS): Define.
29674         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
29675         Based mostly on a patch from Prashant TR.
29676
29677 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
29678
29679         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
29680         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
29681         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
29682
29683 2000-12-08  Andreas Schwab  <schwab@suse.de>
29684
29685         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
29686         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
29687
29688 2000-12-07  Jim Meyering  <meyering@lucent.com>
29689
29690         * lib/stripslash.c (ISSLASH): Define.
29691         (strip_trailing_slashes): Use ISSLASH rather than comparing against
29692         `/'.
29693         From Prashant TR.
29694
29695         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
29696         (dir_name_r): Declare this function as static.
29697         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
29698         manifest itself on a name containing a mix of slashes and
29699         backslashes.
29700         Make this function work with names starting with a DOS-style
29701         drive letter and colon prefix.
29702         (dir_name): Append `.' if necessary.
29703         Based mostly on patches from Prashant TR and Eli Zaretskii.
29704
29705         * lib/dirname.h (dir_name_r): Remove prototype.
29706
29707 2000-12-06  Paul Eggert  <eggert@twinsun.com>
29708
29709         * m4/off_t-format.m4: Remove this file.
29710         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
29711
29712 2000-12-06  Jim Meyering  <meyering@lucent.com>
29713
29714         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
29715         replacement strtoull, we may well need the replacement strtoul, too.
29716         Check for declarations of strtoul and strtoull.
29717         Check for strtol.  Mainly as a cue to cause automake to include
29718         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
29719         Check for limits.h -- strtol.c needs it.
29720
29721 2000-12-05  Jim Meyering  <meyering@lucent.com>
29722
29723         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
29724
29725 2000-12-04  Jim Meyering  <meyering@lucent.com>
29726
29727         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
29728         Also include memory.h, stdlib.h, unistd.h if appropriate.
29729         Reported by Andreas Jaeger (conflicting declaration of malloc).
29730
29731 2000-12-02  Jim Meyering  <meyering@lucent.com>
29732
29733         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
29734         * m4/jm-macros.m4 (jm_MACROS): require it.
29735
29736 2000-12-02  Jim Meyering  <meyering@lucent.com>
29737
29738         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
29739
29740 2000-12-01  Paul Eggert  <eggert@twinsun.com>
29741
29742         * lib/memrchr.c: Include <config.h> before any system include file.
29743
29744 2000-11-30  Jim Meyering  <meyering@lucent.com>
29745
29746         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
29747
29748 2000-11-30  Jim Meyering  <meyering@lucent.com>
29749
29750         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
29751
29752 2000-11-29  Paul Eggert  <eggert@twinsun.com>
29753
29754         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
29755
29756 2000-11-26  Jim Meyering  <meyering@lucent.com>
29757
29758         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
29759
29760 2000-11-22  Paul Eggert  <eggert@twinsun.com>
29761
29762         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
29763         size of (size_t) -1; it's not portable.
29764
29765 2000-11-17  Jim Meyering  <meyering@lucent.com>
29766
29767         * lib/strstr.c: Update from GNU libc.
29768
29769 2000-11-17  Akim Demaille  <akim@epita.fr>
29770
29771         * lib/obstack.h: Formatting changes.
29772         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
29773         prevent type checking.
29774         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
29775         cast the value to (void *): assigning a `foo *' to a `void *'
29776         variable is valid.
29777         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
29778
29779 2000-11-16  Jim Meyering  <meyering@lucent.com>
29780
29781         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
29782
29783 2000-11-11  Jim Meyering  <meyering@lucent.com>
29784
29785         * lib/error.c: Add a couple #includes, merging from GNU libc version.
29786
29787 2000-11-10  Jim Meyering  <meyering@lucent.com>
29788
29789         * lib/obstack.h: Update from GNU libc.
29790         * lib/obstack.c: Likewise.
29791
29792 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
29793
29794         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
29795
29796 2000-11-06  Paul Eggert  <eggert@twinsun.com>
29797
29798         * lib/getusershell.c (setusershell): Use rewind rather than
29799         fseek/fseeko, to avoid configuration hassles with fseeko.
29800         Don't bother opening SHELLS_FILE if shellstream is NULL;
29801         it's not necessary.
29802
29803 2000-11-05  Jim Meyering  <meyering@lucent.com>
29804
29805         * lib/makepath.h (make_dir): Declare.
29806         * lib/makepath.c (make_dir): Remove `static' attribute.
29807         Tweak a comment.
29808
29809 2000-11-04  Jim Meyering  <meyering@lucent.com>
29810
29811         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
29812
29813 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
29814
29815         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
29816         last one in a bucket, advance to the next bucket.
29817
29818 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
29819
29820         * lib/fnmatch.c: Do not comment out all the code if we are using
29821         the GNU C library, because in some cases we are replacing buggy
29822         code in the GNU C library itself.
29823
29824 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
29825
29826         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
29827         (regex_compile): Catch bogus \(\1\).
29828
29829 2000-10-30  Paul Eggert  <eggert@twinsun.com>
29830
29831         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
29832         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
29833         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
29834
29835 2000-10-30  Paul Eggert  <eggert@twinsun.com>
29836
29837         * lib/error.h, getline.h, modechange.h:
29838         Remove "2000" from Copyright line, as the file hasn't been
29839         changed this year other than in the copyright notice.
29840
29841         * lib/xalloc.h: Add "2000" to Copyright line, as this file
29842         was changed this year.
29843
29844 2000-10-29  Jim Meyering  <meyering@lucent.com>
29845
29846         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
29847         renaming.
29848         * m4/ls-mntd-fs.m4: Likewise
29849
29850 2000-10-29  Jim Meyering  <meyering@lucent.com>
29851
29852         * lib/xstat.in: Fix grammar in comment.
29853
29854 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
29855
29856         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
29857         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
29858         doesn't define __restrict_arr.
29859
29860 2000-10-28  Jim Meyering  <meyering@lucent.com>
29861
29862         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
29863         (jm_PREREQ_MEMCHR): New function.
29864
29865 2000-10-28  Jim Meyering  <meyering@lucent.com>
29866
29867         * lib/memchr.c: Update from libc.
29868         Adjust for portability:
29869         [HAVE_STDLIB_H]: Include stdlib.h.
29870         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
29871         Undef __memchr, too.
29872         [!weak_alias]: Define __memchr to memchr.
29873
29874         * lib/regex.c: Update from libc.
29875         * lib/regex.h: Likewise.
29876         * lib/getopt1.c: Likewise.
29877         * lib/memcmp.c: Likewise.
29878
29879         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
29880         Avoid using fseek, when possible -- it's broken by design.
29881         Patch by Ulrich Drepper.
29882
29883 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
29884
29885         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
29886         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
29887         Giving in to popular pressure to shut up the compiler with casts.
29888
29889 2000-10-26  Jim Meyering  <meyering@lucent.com>
29890
29891         * lib/strftime.c: Update from libc.
29892
29893 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
29894
29895         * regex.c: More `unsigned char' -> `re_char' changes.
29896         Also change several `int' into `re_wchar_t'.
29897         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
29898         (PUSH_FAILURE_POINTER): Don't cast any more.
29899         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
29900         We want GCC to complain, since this piece of code makes
29901         re_match non-reentrant, which *should* be fixed.
29902         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
29903         (EXTEND_BUFFER): Use RETALLOC.
29904         (SET_LIST_BIT): Don't cast.
29905         (re_wchar_t): New type.
29906         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
29907         that those two functions will always properly return.
29908         (IMMEDIATE_QUIT_CHECK): Cast to void.
29909         (analyse_first): Use recursion rather than an explicit stack.
29910         (re_compile_fastmap): Can't fail anymore.
29911         (re_search_2): Don't check re_compile_fastmap for failure.
29912         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
29913         Now also sets the new value (passed in a new argument).
29914         (re_match_2_internal): Use it.
29915         Also, use a new var `reg' of type size_t when looping through regs
29916         rather than reuse the inappropriate `mcnt'.
29917
29918 2000-10-25  Jim Meyering  <meyering@lucent.com>
29919
29920         * lib/obstack.c: Update from libc.
29921
29922 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
29923
29924         * regex.c (regex_compile): Change the way of handling a range from
29925         a char less than 256 to a char not less than 256.
29926
29927 2000-10-24  Andrew Innes  <andrewi@gnu.org>
29928
29929         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
29930         NT-Emacs only.
29931         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
29932         so that re_search functions only quit when callers expect them to.
29933
29934 2000-10-23  Jim Meyering  <meyering@lucent.com>
29935
29936         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
29937         wrong.  That set_locale call must not have any side effects.
29938         From Paul Eggert.
29939
29940 2000-10-22  Jim Meyering  <meyering@lucent.com>
29941
29942         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
29943         [CYCLIC]: Remove now-unused definition.
29944
29945         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
29946         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
29947         Suggestion from Ulrich Drepper.
29948
29949 2000-10-21  Jim Meyering  <meyering@lucent.com>
29950
29951         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
29952         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
29953         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
29954
29955 2000-10-21  Jim Meyering  <meyering@lucent.com>
29956
29957         * lib/dirname.c (memrchr): Declare if necessary.
29958         (dir_name): Remove the restriction that there be no
29959         trailing slashes.  Now, this code skips past them, effectively
29960         ignoring them.
29961         [TEST_DIRNAME] (main): New unit tests.
29962
29963         * lib/memrchr.c: New file from GNU libc.
29964         Undef __memrchr, too.
29965         [!weak_alias]: Define __memrchr to memrchr.
29966         Guard weak_alias use with `#ifdef weak_alias'.
29967
29968 2000-10-21  Jim Meyering  <meyering@lucent.com>
29969
29970         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
29971         (dir_name): Use dir_name_r.
29972         * lib/dirname.h (dir_name_r): Declare it.
29973
29974 2000-10-17  Jim Meyering  <meyering@lucent.com>
29975
29976         * lib/quote.h (PARAMS): Define and use.
29977         Reported by Akim Demaille.
29978
29979         * lib/getopt.c: Update from libc.
29980
29981 2000-10-16  Jim Meyering  <meyering@lucent.com>
29982
29983         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
29984         setlocale.
29985         From Jan Fedak.
29986
29987 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
29988
29989         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
29990
29991 2000-09-25  Jim Meyering  <meyering@lucent.com>
29992
29993         * lib/md5.h (rol): Define (from GnuPG).
29994
29995         * lib/sha.c: Give credit (GnuPG) where due.
29996         (M): Use rol rather than open-coding it.
29997         Add a FIXME comment.
29998
29999 2000-09-21  Jim Meyering  <meyering@lucent.com>
30000
30001         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
30002         Reported by Michael Stone.
30003
30004 2000-09-20  Jim Meyering  <meyering@lucent.com>
30005
30006         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
30007         (noinst_HEADERS): Add sha.h.
30008         Based on code from Scott G. Miller and from GnuPG.
30009
30010 2000-09-18  Jim Meyering  <meyering@lucent.com>
30011
30012         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
30013         LIBS. Otherwise, everyone ends up linking with -lelf for some
30014         configurations.
30015         Reported by Mike Stone.
30016
30017 2000-09-15  Jim Meyering  <meyering@lucent.com>
30018
30019         * lib/regex.c: Update from libc.
30020
30021 2000-09-10  Jim Meyering  <meyering@lucent.com>
30022
30023         * lib/getopt.c (_getopt_internal): Update from glibc.
30024
30025 2000-09-09  Jim Meyering  <meyering@lucent.com>
30026
30027         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
30028         think it should be used as a general replacement for isascii.
30029         * lib/fnmatch.c: Likewise.
30030         * lib/mbswidth.c: Likewise
30031         * lib/regex.c: Likewise.
30032
30033         Don't use atoi.
30034         * lib/userspec.c: Include sys/param.h and limits.h.
30035         Include xstrtol.h.
30036         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
30037         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
30038         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
30039         UID, GID.  Check range.
30040
30041 2000-09-06  Jim Meyering  <meyering@lucent.com>
30042
30043         * lib/getopt.c (_getopt_internal): Update from glibc.
30044
30045 2000-08-30  Jim Meyering  <meyering@lucent.com>
30046
30047         * lib/strftime.c: Merge in changes from GNU libc.
30048
30049 2000-08-26  Jim Meyering  <meyering@lucent.com>
30050
30051         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
30052         * m4/fpending.m4: New file.
30053
30054 2000-08-26  Jim Meyering  <meyering@lucent.com>
30055
30056         * lib/closeout.c: Include "__fpending.h".
30057         (close_stdout_status): Return right away if there's nothing to flush.
30058
30059         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
30060         * lib/__fpending.c: New file.
30061         * lib/__fpending.h: New file.
30062
30063 2000-08-20  Jim Meyering  <meyering@lucent.com>
30064
30065         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
30066         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
30067         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
30068
30069 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
30070
30071         Improve fileutils installation on systems where running
30072         programs (like install) can't be unlinked.
30073         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
30074         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
30075
30076 2000-08-07  Paul Eggert  <eggert@twinsun.com>
30077
30078         Standardize on "memory exhausted" instead of "Memory exhausted"
30079         or "virtual memory exhausted".
30080         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
30081         "virtual memory exhausted".
30082         * lib/same.c (same_name): Invoke xalloc_die instead of printing
30083         our own message.
30084         * lib/userspec.c (parse_user_spec): Likewise.
30085         * lib/bumpalloc.h: comment fix
30086         * lib/same.c, userspec.c: Include xalloc.h.
30087
30088         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
30089         not char *const and pointing to a constant array.
30090         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
30091         (xrealloc): Comment fix.
30092
30093         * lib/userspec.c (parse_user_spec):
30094         Don't translate a message until just before returning,
30095         to avoid unnecessary translation.
30096
30097 2000-08-07  Jim Meyering  <meyering@lucent.com>
30098
30099         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
30100         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
30101         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
30102         getgroups.c, gethostname.c, getopt.h, group-member.c,
30103         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
30104         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
30105         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
30106         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
30107         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
30108         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
30109         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
30110         yesno.c: Back out Copyright date changes for each file with no change
30111         this year.  This eases coordination with other programs using the same
30112         source code modules.  From Paul Eggert.
30113
30114 2000-08-06  Paul Eggert  <eggert@twinsun.com>
30115
30116         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
30117         not char, for compatibility with glibc 2.1.3 strftime.c.
30118
30119 2000-08-03  Greg McGary  <greg@mcgary.org>
30120
30121         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
30122         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
30123         (EXTEND_BUFFER): Use them.
30124
30125 2000-08-01  Jim Meyering  <meyering@lucent.com>
30126
30127         * lib/dirname.c (ISSLASH): Define.
30128         (BACKSLASH_IS_PATH_SEPARATOR): Define.
30129         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
30130         both `\' and `/' may be use as path separators.
30131         Based on a patch from Prashant TR.
30132
30133 2000-07-31  Paul Eggert  <eggert@twinsun.com>
30134
30135         * lib/quotearg.c (quotearg_n_options): Don't make the initial
30136         slot vector a constant, since it might get modified.
30137
30138 2000-07-31  Jim Meyering  <meyering@lucent.com>
30139
30140         * lib/xmalloc.c: Use `virtual memory exhausted', not
30141         `Memory exhausted'.
30142         * lib/obstack.c (print_and_abort): Likewise.
30143
30144 2000-07-30  Paul Eggert  <eggert@twinsun.com>
30145
30146         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
30147         buffer, so that the caller can always quote one small
30148         component of a "memory exhausted" message in slot 0.
30149         From a suggestion by Jim Meyering.
30150
30151 2000-07-30  Jim Meyering  <meyering@lucent.com>
30152
30153         * lib/makepath.c (make_path): Quote the other instance, too.
30154
30155         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
30156         (STATIC_BUF_SIZE): Define.
30157         (quotearg_n_options): Use only statically allocated storage when
30158         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
30159         than STATIC_BUF_SIZE.
30160
30161 2000-07-29  Jim Meyering  <meyering@lucent.com>
30162
30163         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
30164         * lib/dirname.c (dir_name): Likewise.
30165
30166         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
30167         `/'.
30168
30169         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
30170         (dir_name): Assert that there are no trailing slashes.
30171
30172 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
30173
30174         * lib/mbswidth.h (mbswidth): Add a flags argument.
30175         (mbswidth): New declaration.
30176         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
30177         * lib/mbswidth.c (mbswidth): Add a flags argument.
30178         (mbsnwidth): New function.
30179
30180 2000-07-24  Jim Meyering  <meyering@lucent.com>
30181
30182         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
30183
30184 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30185
30186         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
30187
30188 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30189
30190         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
30191         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
30192         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
30193         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
30194         invoke multibyte primitives.
30195
30196 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30197
30198         * lib/quotearg.c:
30199         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
30200         so that mbstate_t is always defined.
30201
30202         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
30203         be 1 in at least one GCC installation, and this configuration
30204         error is likely to be common.  Ignoring MB_LEN_MAX hurts
30205         performance on hosts that have mbrtowc but have only unibyte
30206         locales, but I assume these hosts are rare.
30207
30208 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30209
30210         * lib/mbswidth.c (_XOPEN_SOURCE):
30211         Don't define; this causes problems on Solaris 7.
30212         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
30213
30214 2000-07-23  Jim Meyering  <meyering@lucent.com>
30215
30216         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
30217         too: getgrgid, getpwuid, getuid.
30218
30219 2000-07-23  Jim Meyering  <meyering@lucent.com>
30220
30221         * lib/basename.c (base_name): Add an assertion.
30222
30223 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
30224
30225         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
30226         shadow its mbsinit function.
30227
30228 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30229
30230         * lib/mbswidth.h: New file.
30231         * lib/mbswidth.c: New file.
30232         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
30233         (noinst_HEADERS): Add mbswidth.h.
30234
30235 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30236
30237         * lib/config.charset: Add support for FreeBSD. Improve support for
30238         HP-UX and IRIX 6.
30239
30240 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
30241
30242         * m4/mbswidth.m4: New file.
30243         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
30244
30245 2000-07-15  Jim Meyering  <meyering@lucent.com>
30246
30247         * lib/makepath.c: Include quote.h.
30248         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
30249         corresponding argument in a `quote (...)' call.
30250         Give better diagnostics.
30251
30252         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
30253         (noinst_HEADERS): Add quote.h.
30254
30255         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
30256         from tar's src/misc.c.
30257         * lib/quote.h: New file.  Prototypes for same.
30258
30259 2000-07-14  Paul Eggert  <eggert@twinsun.com>
30260
30261         From a suggestion by Bruno Haible.
30262         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
30263         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
30264         to decide whether to define the BeOS workaround macro;
30265         this adjusts to the change to AC_MBSTATE_T.
30266
30267 2000-07-14  Jim Meyering  <meyering@lucent.com>
30268
30269         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
30270         jm_AC_TYPE_UINTMAX_T.
30271
30272 2000-07-13  Paul Eggert  <eggert@twinsun.com>
30273
30274         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
30275
30276         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
30277         quotearg_buffer_restyled): Add support for
30278         clocale_quoting_style.  Undo previous change to
30279         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
30280         and "{RIGHT QUOTATION MARK}" msgids.
30281
30282 2000-07-10  Paul Eggert  <eggert@twinsun.com>
30283
30284         From a suggestion by Bruno Haible.
30285         * m4/mbstate_t.m4 (AC_MBSTATE_T):
30286         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
30287         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
30288         and mbstate_t, to a single-part test that simply defines mbstate_t.
30289         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
30290         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
30291
30292 2000-07-10  Jim Meyering  <meyering@lucent.com>
30293
30294         * m4/strerror_r.m4: Mirror the correction made in autoconf.
30295
30296         * m4/gnu-source.m4: Output to confdefs.h directly.
30297         Suggestion from Akim Demaille.
30298
30299 2000-07-09  Paul Eggert  <eggert@twinsun.com>
30300
30301         The old behavior of quoting `like this' doesn't look good with
30302         newer, ISO-style fonts.  See:
30303         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
30304
30305         Instead, quote "like this" by default.  Let the translator
30306         tailor the locale-specific quoting behavior by providing
30307         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
30308
30309         * lib/quotearg.c (N_): New macro.
30310         (gettext_default): New function.
30311         (quotearg_buffer_restyled): Use
30312         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
30313         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
30314
30315 2000-07-09  Jim Meyering  <meyering@lucent.com>
30316
30317         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
30318         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
30319
30320         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
30321         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
30322
30323 2000-07-09  Jim Meyering  <meyering@lucent.com>
30324
30325         * lib/Most files: Update copyright dates to include 2000.
30326
30327 2000-07-08  Jim Meyering  <meyering@lucent.com>
30328
30329         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
30330         if not defined.
30331         (xgethostname): Remove now-unnecessary #ifdef.
30332         Move declaration of `err' into loop where it's used.
30333
30334 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30335         and Bruno Haible  <haible@clisp.cons.org>
30336
30337         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
30338         only if the test for an object-type mbstate_t fails.  This
30339         prevents us from mistakenly reporting that mbstate_t is a
30340         system object type after we "#define mbstate_t int" to work
30341         around its lack.
30342
30343 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30344         and Bruno Haible  <haible@clisp.cons.org>
30345
30346         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
30347
30348 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30349
30350         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
30351         to strerror_r.
30352         Include <ctype.h> for use of isalpha.
30353
30354 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30355
30356         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
30357         by allocating a larger buffer. Test the gethostname return value for
30358         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
30359         returns an error and ENAMETOOLONG isn't defined.
30360
30361 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30362
30363         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
30364         dimension.
30365
30366 2000-07-04  Jim Meyering  <meyering@lucent.com>
30367
30368         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
30369         of the deprecated AC_CHECKING.
30370
30371 2000-07-04  Jim Meyering  <meyering@lucent.com>
30372
30373         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
30374         Reported by Bruno Haible.
30375
30376 2000-07-04  Jim Meyering  <meyering@lucent.com>
30377
30378         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
30379         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
30380         lacks mbrtowc.
30381
30382 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30383
30384         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
30385         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
30386
30387 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30388         and Bruno Haible  <haible@clisp.cons.org>
30389
30390         * lib/quotearg.c (mbrtowc):
30391         Assign to *pwc, and return 1 only if result is nonzero.
30392         (iswprint): Use ISPRINT when substituting our own mbrtowc.
30393
30394 2000-07-03  Jim Meyering  <meyering@lucent.com>
30395
30396         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
30397
30398 2000-07-03  Jim Meyering  <meyering@lucent.com>
30399
30400         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
30401         This is necessary to get a definition of e.g., UTMP_FILE on
30402         HP-UX 10.20.
30403         From Bob Proulx.
30404
30405 2000-07-02  Jim Meyering  <meyering@lucent.com>
30406
30407         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
30408
30409         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
30410         AC_LIBOBJ(function_name).
30411         * m4/chown.m4: Likewise.
30412         * m4/fnmatch.m4: Likewise.
30413         * m4/ftruncate.m4: Likewise.
30414         * m4/getgroups.m4: Likewise.
30415         * m4/getline.m4: Likewise.
30416         * m4/group-member.m4: Likewise.
30417         * m4/jm-macros.m4: Likewise.
30418         * m4/lstat.m4: Likewise.
30419         * m4/malloc.m4: Likewise.
30420         * m4/memcmp.m4: Likewise.
30421         * m4/nanosleep.m4: Likewise.
30422         * m4/putenv.m4: Likewise.
30423         * m4/realloc.m4: Likewise.
30424         * m4/regex.m4: Likewise.
30425         * m4/stat.m4: Likewise.
30426         * m4/strftime.m4: Likewise.
30427
30428 2000-07-02  Jim Meyering  <meyering@lucent.com>
30429
30430         * lib/quotearg.c (mbstate_t): Don't define here.
30431
30432 2000-07-02  Jim Meyering  <meyering@lucent.com>
30433
30434         * lib/nanosleep.c (SIGCONT): Define if not already defined.
30435
30436 2000-07-01  Jim Meyering  <meyering@lucent.com>
30437
30438         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
30439
30440 2000-07-01  Jim Meyering  <meyering@lucent.com>
30441
30442         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
30443         problem.
30444
30445 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30446
30447         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
30448         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
30449
30450 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30451
30452         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
30453         per change in ../m4/ls-mntd-fs.m4.
30454         (read_filesystem_list): Ignore symbolic links.
30455
30456 2000-06-29  Jim Meyering  <meyering@lucent.com>
30457
30458         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
30459         for declaration of strcmp.
30460
30461         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
30462
30463         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
30464         Avoid warning by casting result to `char *' to remove `const'.
30465
30466 2000-06-28  Jim Meyering  <meyering@lucent.com>
30467
30468         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
30469         included by quotearg.c, for which we perform this test.  From
30470         Bruno Haible.
30471
30472 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30473
30474         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
30475         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
30476         <utmpx.h> exists, put readutmp.o into LIBOBJS.
30477
30478 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30479
30480         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
30481
30482 2000-06-26  Paul Eggert  <eggert@twinsun.com>
30483
30484         savedir now sets errno on failure and invokes xmalloc to get memory.
30485         Fix a couple of other minor bugs while we're at it.
30486
30487         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
30488         (NAMLEN): Remove macro.
30489         (malloc, realloc): Remove decls.
30490         (stpcpy): Likewise.
30491         ("xalloc.h"): Include.
30492         (NAME_SIZE_DEFAULT): New macro.
30493         (savedir): Use xmalloc / xrealloc to allocate memory.
30494         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
30495         Skip "" directory entries.
30496         Use strlen to calculate directory entry length, since the old method
30497         is rarely used these days and isn't worth supporting.
30498         Don't use a pointer after freeing it.
30499         Check for integer overflow when calculating allocation size.
30500         Use memcpy to copy entries, instead of stpcpy.
30501         Set errno properly when returning NULL.
30502         Check for readdir error.
30503
30504 2000-06-26  Jim Meyering  <meyering@lucent.com>
30505
30506         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
30507
30508 2000-06-25  Jim Meyering  <meyering@lucent.com>
30509
30510         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
30511         Linux header bug when _XOPEN_SOURCE is defined to 500.
30512
30513 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
30514
30515         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
30516         deficiency.
30517
30518 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
30519
30520         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
30521         Include xalloc.h.
30522         Don't include <stdlib.h>.  Don't declare malloc, realloc.
30523
30524 2000-06-24  Jim Meyering  <meyering@lucent.com>
30525
30526         * m4/strerror_r.m4: Revive this file -- to try out an experimental
30527         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
30528         for which strerror does return char*, but which lacks a conveniently
30529         accessible declaration of the function.  If the compile-test says
30530         strerror_r doesn't work, then resort to a `run'-test that works on
30531         BeOS and segfaults on DEC Unix.
30532
30533 2000-06-24  Jim Meyering  <meyering@lucent.com>
30534
30535         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
30536
30537 2000-06-23  Paul Eggert  <eggert@twinsun.com>
30538
30539         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
30540         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
30541
30542 2000-06-23  Paul Eggert  <eggert@twinsun.com>
30543
30544         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
30545         (mbrtowc, mbstate_t): Define substitutes if
30546         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
30547         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
30548         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
30549
30550 2000-06-23  Jim Meyering  <meyering@lucent.com>
30551
30552         * m4/afs.m4: Add missing AC_MSG_RESULT.
30553         Reported by Bruno Haible.
30554
30555         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
30556         Suggestion from Bruno Haible.
30557
30558 2000-06-23  Jim Meyering  <meyering@lucent.com>
30559
30560         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
30561
30562 2000-06-21  Jim Meyering  <meyering@lucent.com>
30563
30564         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
30565
30566 2000-06-21  Jim Meyering  <meyering@lucent.com>
30567
30568         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
30569         (noinst_HEADERS): Add getstr.h.
30570
30571         * lib/getline.c (getstr): Move into a separate file.
30572         * lib/getstr.c (getstr): New file, extracted from getline.c, with
30573         the following changes: new parameter, delim2; both delim[12]
30574         parameters have type `int', not `char'.  The latter would lose
30575         with 8-bit delimiters.
30576         * lib/getstr.h: New file.
30577
30578 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30579
30580         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
30581         than 1024, return a memory chunk of least possible size, instead
30582         of size PATH_MAX + 2. In the loop, increment the size proportionally.
30583         Use free/xmalloc instead of xrealloc to avoid copying for very long
30584         paths.
30585
30586 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30587
30588         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
30589         the empty string.
30590
30591 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30592
30593         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
30594         address, not strdup.  Include <stdlib.h> and don't declare free().
30595
30596 2000-06-19  Jim Meyering  <meyering@lucent.com>
30597
30598         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
30599
30600 2000-06-18  Jim Meyering  <meyering@lucent.com>
30601
30602         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
30603
30604         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
30605         `checking whether...' message to be consistent with that of the
30606         lstat test.
30607
30608 2000-06-18  Jim Meyering  <meyering@lucent.com>
30609
30610         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
30611         Besides, these days every porting target provides a mkdir function.
30612
30613         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
30614         needed. (this snippet comes from src/system.h).
30615
30616 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
30617
30618         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
30619
30620 2000-06-15  Paul Eggert  <eggert@twinsun.com>
30621
30622         * lib/human.c (adjust_value): New function.
30623         (human_readable_inexact): Apply rounding style even when
30624         printing approximate values.
30625
30626 2000-06-14  Paul Eggert  <eggert@twinsun.com>
30627
30628         * lib/human.c (human_readable_inexact): Allow an input block
30629         size that is not a multiple of the output block size, and vice versa.
30630         Reported by Piergiorgio Sartor.
30631
30632 2000-06-14  Paul Eggert  <eggert@twinsun.com>
30633
30634         * lib/getdate.y (get_date): Apply relative times after time
30635         zone indicator, not before.  Reported by Todd A. Jacobs.
30636
30637 2000-06-13  Jim Meyering  <meyering@lucent.com>
30638
30639         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
30640
30641         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
30642
30643 2000-06-12  Paul Eggert  <eggert@twinsun.com>
30644
30645         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
30646
30647 2000-06-12  Jim Meyering  <meyering@lucent.com>
30648
30649         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
30650         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
30651         optional argument.
30652         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
30653         the optional argument, `lib'.
30654
30655 2000-06-08  Jim Meyering  <meyering@lucent.com>
30656
30657         * m4/largefile.m4: Remove file (now that it's part of autoconf).
30658
30659 2000-06-04  Paul Eggert  <eggert@twinsun.com>
30660
30661         Rewrite largefile configuration so that we don't need to run
30662         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
30663         AC_CANONICAL_HOST in configure.in -- jmm]
30664
30665         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
30666         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
30667         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
30668         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
30669         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
30670         All uses changed.
30671         Instead of inspecting the output of getconf, try to compile the
30672         test program without and with the macro definition.
30673         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
30674         for getconf.  Instead, check for the needed flags by compiling
30675         test programs.
30676
30677 2000-06-04  Paul Eggert  <eggert@twinsun.com>
30678
30679         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
30680
30681 2000-06-04  Jim Meyering  <meyering@lucent.com>
30682
30683         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
30684         SunOS 4.1.4 for which gid_t is an unsigned type.
30685
30686 2000-06-03  Jim Meyering  <meyering@lucent.com>
30687
30688         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
30689         now that autoconf requires that.
30690
30691         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
30692         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
30693         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
30694
30695 2000-06-03  Jim Meyering  <meyering@lucent.com>
30696
30697         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
30698
30699 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
30700
30701         * m4/glibc21.m4: New file.
30702         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
30703
30704 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
30705
30706         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
30707         newer, don't install charset.alias.
30708         * lib/config.charset: Change the Linux/glibc rules so they become empty
30709         on glibc-2.1 or newer.
30710
30711 2000-06-02  Jim Meyering  <meyering@lucent.com>
30712
30713         * lib/mountlist.c: Back out last change.  Instead, do this...
30714         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
30715         me_dummy member using the same `ignore'-testing code.
30716         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
30717         fs_type strings.
30718         From Mark D. Roth.
30719
30720 2000-05-29  Jim Meyering  <meyering@lucent.com>
30721
30722         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
30723         mounts with the `ignore' attribute.  Based on a patch from
30724         Mark D. Roth.
30725
30726 2000-05-28  Jim Meyering  <meyering@lucent.com>
30727
30728         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
30729         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
30730         * m4/stat.m4: Likewise.
30731         * m4/lstat.m4: Likewise.
30732         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
30733
30734         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
30735         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
30736
30737 2000-05-26  Jim Meyering  <meyering@lucent.com>
30738
30739         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
30740
30741 2000-05-24  Jim Meyering  <meyering@lucent.com>
30742
30743         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
30744         autoconf requires that.
30745         * m4/lib-check.m4: Likewise.
30746         * m4/jm-macros.m4: Likewise.
30747         * m4/strftime.m4: Likewise.
30748
30749         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
30750         AC_CHECK_DECLS, now that autoconf requires that.
30751
30752 2000-05-22  Jim Meyering  <meyering@lucent.com>
30753
30754         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
30755         * m4/lstat.m4: Likewise.
30756
30757 2000-05-22  Jim Meyering  <meyering@lucent.com>
30758
30759         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
30760
30761 2000-05-20  Jim Meyering  <meyering@lucent.com>
30762
30763         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
30764         (jm_PREREQ): Use it.
30765
30766 2000-05-18  Jim Meyering  <meyering@lucent.com>
30767
30768         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
30769         back, too, since it may have been modified by allocate_entry.
30770         (hash_delete): Rewrite to use neither the assignment operator
30771         nor the comma operator in an if-expression.
30772
30773 2000-05-15  Paul Eggert  <eggert@twinsun.com>
30774
30775         * lib/closeout.c:
30776         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
30777         Remove; no longer needed.
30778         "quotearg.h": Add include.
30779         (file_name): Do not bother to explicitly initialize to NULL; it's less
30780         efficient on some hosts.
30781         (close_stdout_status): Remove test as to whether stdout was already
30782         closed; it breaks for the case "echo x | sort >&-".
30783         Quote file name colons.
30784         Do not assume that _("write error") lacks format strings.
30785
30786 2000-05-15  Jim Meyering  <meyering@lucent.com>
30787
30788         * lib/version-etc.c (version_etc_copyright): Update the copyright
30789         string used in all --version output.
30790
30791 2000-05-14  Jim Meyering  <meyering@lucent.com>
30792
30793         * lib/closeout.c (close_stdout_set_file_name): New function.
30794         (close_stdout_status): Use new file-scoped global.
30795         Return right away if fstat says the stdout file descriptor is invalid.
30796         * lib/closeout.h (close_stdout_set_file_name): Declare.
30797
30798 2000-05-10  Jim Meyering  <meyering@lucent.com>
30799
30800         * lib/closeout.c [default_exit_status]: New file-scoped variable.
30801         (close_stdout_set_status): New function.
30802         * lib/closeout.h (close_stdout_set_status): Declare.
30803
30804 2000-05-09  Jim Meyering  <meyering@lucent.com>
30805
30806         * m4/gettext.m4: Rename this...
30807         * m4/libintl.m4: ...to this.
30808
30809 2000-05-08  Jim Meyering  <meyering@lucent.com>
30810
30811         * lib/long-options.c: Don't include closeout.h.
30812         (parse_long_options): Don't call close_stdout for --version.
30813
30814 2000-05-06  Paul Eggert  <eggert@twinsun.com>
30815
30816         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
30817         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
30818         2.1.3 bug.  This avoids a clash when files like regex.c define
30819         _GNU_SOURCE.
30820
30821 2000-05-06  Jim Meyering  <meyering@lucent.com>
30822
30823         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
30824         (AC_REPLACE_FUNCS): Add strnlen.
30825
30826         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
30827         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
30828
30829         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
30830         AC_SEARCH_LIBS call for nanosleep.
30831         (LIB_NANOSLEEP): Set and AC_SUBST.
30832
30833 2000-05-06  Jim Meyering  <meyering@lucent.com>
30834
30835         * lib/strnlen.c: Undefine __strnlen and strnlen.
30836         [!weak_alias]: Define __strnlen to strnlen.
30837
30838         * lib/atexit.c: New file, from libiberty.
30839
30840 2000-05-06  Jim Meyering  <meyering@lucent.com>
30841
30842         * lib/closeout.c (close_stdout_status): Also check for errors on the
30843         stderr stream.
30844
30845 2000-05-05  Jim Meyering  <meyering@lucent.com>
30846
30847         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
30848         AC_SEARCH_LIBS call for clock_gettime.
30849         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
30850
30851         * m4/search-libs.m4: Update from autoconf.
30852
30853         su doesn't work on Solaris 2.6.
30854         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
30855         <shadow.h>.  Reported by Dragos Harabor.
30856
30857 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
30858
30859         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
30860         memcpy instead of xmalloc, xrealloc, path_concat.
30861         (locale_charset): Treat empty environment variables as absent.
30862         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
30863
30864 2000-05-04  Jim Meyering  <meyering@lucent.com>
30865
30866         * lib/getopt.c: Update from glibc.
30867         * lib/obstack.c: Likewise.
30868         * lib/obstack.h: Likewise.
30869         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
30870         file
30871
30872         * lib/regex.h: Likewise.
30873         * lib/strndup.c: Likewise.
30874         * lib/strnlen.c: New file, from glibc.
30875
30876 2000-05-03  Jim Meyering  <meyering@lucent.com>
30877
30878         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
30879
30880 2000-05-02  Paul Eggert  <eggert@twinsun.com>
30881
30882         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
30883         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
30884         compile-time test, rather than inspecting host and OS, to
30885         decide whether to define _LARGEFILE_SOURCE.
30886
30887 2000-05-01  Jim Meyering  <meyering@lucent.com>
30888
30889         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
30890
30891         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
30892         Based on a patch from Bruno Haible.
30893
30894 2000-05-01  Jim Meyering  <meyering@lucent.com>
30895
30896         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
30897
30898 2000-04-29  Jim Meyering  <meyering@lucent.com>
30899
30900         * lib/path-concat.c: Declare strdup only if it's not defined.
30901         * lib/canon-host.c: Likewise.
30902
30903 2000-04-28  Jim Meyering  <meyering@lucent.com>
30904
30905         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
30906         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
30907         is included first, then limits.h is included by locale.h by libintl.h.
30908         From John David Anglin.
30909
30910 2000-04-25  Jim Meyering  <meyering@lucent.com>
30911
30912         * lib/makepath.c (S_IRWXUGO): Define.
30913         (make_path): Always perform explicit chmod if MODE specifies any
30914         of the `special' permission bits.  Prompted by a bug report against
30915         install from Mate Wierdl and Joost van Baal.
30916
30917 2000-04-18  Jim Meyering  <meyering@lucent.com>
30918
30919         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
30920         (jm_PREREQ): Use it.
30921
30922 2000-04-18  Jim Meyering  <meyering@lucent.com>
30923
30924         * lib/README: New file.
30925
30926         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
30927         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
30928
30929 2000-04-17  Jim Meyering  <meyering@lucent.com>
30930
30931         Get it right :-)
30932         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
30933         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
30934         Suggestion from Akim Demaille.
30935
30936 2000-04-17  Jim Meyering  <meyering@lucent.com>
30937
30938         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
30939         the definition of it to rpl_strftime also defined-away the system's
30940         declaration.
30941
30942 2000-04-15  Jim Meyering  <meyering@lucent.com>
30943
30944         Use `C' to denote so-called `contiguous' files, the same way
30945         that tar does.
30946         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
30947         (ftypelet): Use S_ISCTG.
30948         From Michael Deutschmann.
30949
30950 2000-04-14  Jim Meyering  <meyering@lucent.com>
30951
30952         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
30953         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
30954         clobbered.
30955
30956 2000-04-14  Jim Meyering  <meyering@lucent.com>
30957
30958         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
30959
30960 2000-04-13  Jim Meyering  <meyering@lucent.com>
30961
30962         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
30963         AH_VERBATIM to insert required #ifndef into config.h.in.
30964         Suggestion from Akim Demaille.
30965
30966 2000-04-12  Jim Meyering  <meyering@lucent.com>
30967
30968         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
30969         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
30970         Christian Krackowizer.
30971
30972         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
30973         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
30974         (AC_SYS_LARGEFILE): Require.
30975         (AM_C_PROTOTYPES): Require.
30976
30977 2000-04-08  Jim Meyering  <meyering@lucent.com>
30978
30979         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
30980         names don't conflict.  Reported by Eli Zaretskii.
30981
30982 2000-04-07  Jim Meyering  <meyering@lucent.com>
30983
30984         * lib/putenv.c: Move inclusion of errno.h so it follows that of
30985         sys/types.h, to work around system header problems on AIX 3.2.5.
30986         From Bruno Haible.
30987
30988 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
30989
30990         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
30991         bug.  Deal with the different error behavior of Irix iconv.
30992
30993 2000-04-05  Paul Eggert  <eggert@twinsun.com>
30994
30995         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
30996         IRIX if the installer said otherwise.
30997
30998 2000-04-05  Jim Meyering  <meyering@lucent.com>
30999
31000         Portability tweaks required for ultrix4.3.
31001         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
31002         (jm_CHECK_DECLS): Add getutent to the list of functions.
31003         (_jm_DECL_HEADERS): Add utmpx.h.
31004         From John David Anglin.
31005
31006         * m4/strftime.m4: Back out the 2000-04-02 change.
31007         Instead of that change, simply undefine putenv in the test program.
31008
31009 2000-04-05  Jim Meyering  <meyering@lucent.com>
31010
31011         Portability tweaks required for ultrix4.3.
31012         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
31013         getutent.
31014         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
31015         * lib/canon-host.c: Declare strdup.
31016         * lib/path-concat.c: Likewise.
31017         From John David Anglin.
31018
31019 2000-04-04  Jim Meyering  <meyering@lucent.com>
31020
31021         Be more DOS 8.3-friendly.
31022         * lib/ref-add.sin: Renamed from ref-add.sed.in.
31023         * lib/ref-del.sin: Renamed from ref-del.sed.in.
31024         * lib/Makefile.am: Reflect renaming.
31025         Reported by Eli Zaretskii.
31026
31027         Use a temporary file name that won't clash with `charset.alias'
31028         in the DOS 8.3 name space.
31029         * lib/Makefile.am (charset_tmp): Define.
31030         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
31031         (uninstall-local): Likewise.
31032         Reported by Eli Zaretskii.
31033
31034 2000-04-03  Jim Meyering  <meyering@lucent.com>
31035
31036         * m4/gettext.m4: Fix typo in comment.
31037
31038         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
31039         textutils/configure.in).  Suggestion from Paul Eggert.
31040         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
31041
31042 2000-04-02  Paul Eggert  <eggert@twinsun.com>
31043
31044         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
31045         variable in the shell rather than using putenv, which isn't
31046         portable.  This avoids the configure-time inter-test dependency
31047         on the potentially-renamed putenv function.
31048
31049 2000-03-30  Paul Eggert  <eggert@twinsun.com>
31050
31051         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
31052         before checking struct stat.st_blksize, so that
31053         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
31054
31055 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31056
31057         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
31058         since strftime.c uses HAVE_STRFTIME to decide whether to use
31059         the underlying strftime.
31060
31061 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31062
31063         * lib/time/strftime.c (my_strftime): Make sure we call the system
31064         strftime, not ourselves, when invoking the underlying strftime.
31065
31066 2000-03-24  Jim Meyering  <meyering@lucent.com>
31067
31068         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
31069         (charset_alias): Define.
31070         (install-exec-local): Factor out common code.
31071         (uninstall-local): Split lines longer than 80.
31072         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
31073         (SUFFIXES): Define.
31074         (.sed.in.sed): New rule.  Don't redirect directly to $@.
31075         (CLEANFILES): Add ref-add.sed and ref-del.sed.
31076
31077 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
31078
31079         * lib/config.charset: Output a line containing "Packages using this
31080         file".
31081         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
31082         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
31083         ref-del.sed): New rules.
31084
31085 2000-03-17  Jim Meyering  <meyering@lucent.com>
31086
31087         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
31088         Otherwise, include <strings.h>
31089
31090 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
31091
31092         * lib/unicodeio.c (utf8_wctomb): New function.
31093         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
31094         format instead of in UCS-4 with platform dependent endianness.
31095
31096 2000-03-10  Jim Meyering  <meyering@lucent.com>
31097
31098         * m4/lib-check.m4: Look for getspnam in -lgen, too.
31099         From Marco Franzen.
31100
31101 2000-03-07  Paul Eggert  <eggert@twinsun.com>
31102
31103         * lib/savedir.c (savedir): Work even if directory size is
31104         negative; this can happen with some screwy NFS configurations.
31105
31106 2000-03-06  Jim Meyering  <meyering@lucent.com>
31107
31108         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
31109         if it's NULL (because we ran out of memory).  From Bruno Haible.
31110
31111 2000-03-05  Jim Meyering  <meyering@lucent.com>
31112
31113         * lib/localcharset.c ("path-concat.h"): Include.
31114         (get_charset_aliases): Use path_concat instead of ANSI string
31115         concatenation.
31116
31117         * lib/unicodeio.h (PARAMS): Define.
31118         Use it to guard prototype.
31119
31120 2000-03-04  Jim Meyering  <meyering@lucent.com>
31121
31122         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
31123         for lib/localcharset.c.
31124
31125 2000-03-04  Jim Meyering  <meyering@lucent.com>
31126
31127         * lib/Makefile.am (install-exec-local): Create $(libdir) before
31128         installing into it.
31129         (uninstall-local): Uncomment this rule so `make distcheck' works
31130         once again.
31131
31132         * lib/unicodeio.c (<errno.h>): Include it.
31133         (errno): Declare if not defined.
31134
31135         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
31136
31137         * lib/config.charset: New version, incorporating remarks from a linux
31138         i18n mailing list.  From Bruno Haible.
31139
31140 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
31141
31142         * m4/codeset.m4: New file.
31143         * m4/iconv.m4: New file.
31144         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
31145
31146 2000-03-03  Jim Meyering  <meyering@lucent.com>
31147
31148         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
31149
31150 2000-03-02  Jim Meyering  <meyering@lucent.com>
31151
31152         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
31153         the messages come out on separate lines.
31154
31155         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
31156         rather than jm_CHECK_DECLARATIONS.
31157         * m4/decl.m4: Remove now-unused file.
31158
31159         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
31160         geteuid.
31161
31162 2000-03-02  Jim Meyering  <meyering@lucent.com>
31163
31164         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
31165
31166 2000-03-01  Jim Meyering  <meyering@lucent.com>
31167
31168         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
31169         * lib/unicodeio.c: Likewise.
31170
31171 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
31172
31173         * lib/config.charset: New file.
31174         * lib/localcharset.c: New file.
31175         * lib/unicodeio.h, lib/unicodeio.c: New files.
31176         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
31177         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
31178         (noinst_HEADERS): Add unicodeio.h.
31179         (all-local, install-exec-local, charset.alias): New targets.
31180
31181 2000-02-28  Paul Eggert  <eggert@twinsun.com>
31182
31183         * lib/quotearg.c (ALERT_CHAR): New macro.
31184         (quotearg_buffer_restyled): Use it.
31185
31186 2000-02-27  Jim Meyering  <meyering@lucent.com>
31187
31188         * m4/check-decl.m4: Add getenv to the list.
31189
31190 2000-02-27  Jim Meyering  <meyering@lucent.com>
31191
31192         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
31193         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
31194
31195         * lib/backupfile.c: Guard inclusion of stdlib.h with
31196         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
31197         Declare malloc if needed.
31198
31199         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
31200         `#ifndef HAVE_DECL..'
31201         now that autoconf always defines the HAVE_DECL_ symbols.
31202         * lib/human.c: Likewise.
31203         * lib/same.c: Likewise.
31204         * lib/strtoumax.c: Likewise.
31205
31206         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
31207         declaration check was not run.
31208         * lib/hash.c: Likewise.
31209         * lib/human.c: Likewise.
31210         * lib/same.c: Likewise.
31211         * lib/strtoumax.c: Likewise.
31212
31213         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
31214         `.', then first look up the entire `.'-containing string as a login
31215         name.
31216
31217 2000-02-23  Jim Meyering  <meyering@lucent.com>
31218
31219         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
31220         in place of my hack.
31221
31222 2000-02-18  Paul Eggert  <eggert@twinsun.com>
31223
31224         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
31225         (textint): New typedef.
31226         (parser_control): Member year changed from int to textint.
31227         All uses changed.
31228         (YYSTYPE): Removed; replaced by %union with int and textint members.
31229         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
31230         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
31231         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
31232         (tSNUMBER, tUNUMBER): Now of type <textintval>.
31233         (date, number, to_year): Use width of number in digits, not its value,
31234         to determine whether it's a 2-digit year, or a 2-digit time.
31235         (yylex): Store number of digits of numeric tokens.
31236         Reported by John Kendall.
31237
31238         (parser_control): Changed from struct parser_control to typedef (for
31239         consistency).  All uses changed.
31240
31241         (tID): Removed; not used.
31242         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
31243
31244 2000-02-14  Paul Eggert  <eggert@twinsun.com>
31245
31246         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
31247         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
31248
31249 2000-02-12  Jim Meyering  <meyering@lucent.com>
31250
31251         * lib/userspec.c (ISDIGIT): Define it.
31252         (isdigit): Remove definition.
31253         (is_number): Use ISDIGIT, not isdigit.
31254         <libintl.h>: Include.
31255         (_ and N_): Define.
31256         (parse_user_spec): Mark translatable strings.
31257
31258 2000-02-10  Jim Meyering  <meyering@lucent.com>
31259
31260         With these changes, nanosleep.[ch] are finally enough like the other
31261         lib/* replacement files to compile on a few more losing systems.
31262
31263         * lib/nanosleep.h: Don't include config.h.
31264         Remove prototype from declaration of nanosleep.
31265         (PARAMS): Remove now-unneeded definition.
31266         * lib/nanosleep.c: #undef nanosleep.
31267         (rpl_nanosleep): Rename from nanosleep.
31268
31269 2000-02-10  Jim Meyering  <meyering@lucent.com>
31270
31271         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
31272         gnu_nanosleep to rpl_nanosleep.
31273
31274 2000-02-09  Jim Meyering  <meyering@lucent.com>
31275
31276         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
31277         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
31278
31279 2000-02-08  Akim Demaille  <akim@epita.fr>
31280
31281         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
31282         `[' and `]' and remove uses of `changequote'.
31283         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
31284         (AC_SYS_LARGEFILE): Likewise.
31285         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
31286         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
31287         of changequote.
31288         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
31289         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
31290         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
31291         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
31292
31293 2000-02-05  Jim Meyering  <meyering@lucent.com>
31294
31295         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
31296         Remove explicit use of AC_HEADER_TIME.  It is required by
31297         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
31298         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
31299         in autoconf whereby the expansion of the latter ended up preceding
31300         the expansion of its prerequisite, AC_HEADER_TIME.
31301         Reported by Volker Borchert.
31302
31303 2000-02-03  Jim Meyering  <meyering@lucent.com>
31304
31305         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
31306
31307 2000-02-03  Jim Meyering  <meyering@lucent.com>
31308
31309         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
31310         rather than with `#if HAVE_UTMPNAME'.
31311
31312 2000-02-02  Jim Meyering  <meyering@lucent.com>
31313
31314         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
31315         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
31316         Reported by Eli Zaretskii.
31317
31318 2000-02-01  Jim Meyering  <meyering@lucent.com>
31319
31320         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
31321
31322 2000-01-31  Jim Meyering  <meyering@lucent.com>
31323
31324         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
31325         functions.  Add the time.h and sys/time.h headers along with the
31326         AC_REQUIRE'ment of AC_HEADER_TIME.
31327
31328 2000-01-31  Jim Meyering  <meyering@lucent.com>
31329
31330         * lib/nanosleep.h (nanosleep): Guard declaration with
31331         `#if ! HAVE_DECL_NANOSLEEP'.
31332         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
31333         the declaration in that vendor's sys/timers.h.
31334         Reported by Christian Krackowizer.
31335
31336         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
31337         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
31338         (ISPRINT): Likewise.
31339         Reported by Tom Tromey.
31340
31341 2000-01-30  Jim Meyering  <meyering@lucent.com>
31342
31343         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
31344
31345         * m4/prereq.m4 (utmp_includes): Define.
31346         Check for ut_user and ut_name members in both struct utmpx
31347         and struct utmp.
31348
31349 2000-01-30  Jim Meyering  <meyering@lucent.com>
31350
31351         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
31352         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
31353         header files where only utmpx.ut_user is declared.
31354
31355         * lib/readutmp.h (UT_USER): Define.
31356
31357 2000-01-29  Jim Meyering  <meyering@lucent.com>
31358
31359         * m4/lib-check.m4: New file containing library-related checks from
31360         fileutils and sh-utils (textutils had none).
31361
31362 2000-01-28  Jim Meyering  <meyering@lucent.com>
31363
31364         * m4/perl.m4: Change format of warning message to look more like that
31365         from the missing script.  Suggestion from François Pinard.
31366
31367 2000-01-25  Jim Meyering  <meyering@lucent.com>
31368
31369         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
31370         well as time.h in the compile check.
31371         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
31372         Fix typo in cross-compiling case: s/yes/no/.
31373
31374 2000-01-23  Jim Meyering  <meyering@lucent.com>
31375
31376         * m4/jm-macros.m4: Move df-related tests here from
31377         fileutils/configure.in
31378
31379         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
31380         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
31381
31382         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
31383         s/space/ac_fsusage_space/.
31384         (jm_FILE_SYSTEM_USAGE): Take two parameters.
31385
31386         * m4/ftruncate.m4: New file (derived from part of
31387         fileutils/configure.in).
31388         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
31389         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
31390
31391         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
31392         AC_SUBST these here, rather than just in sh-util/configure.in, so
31393         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
31394         all the same.
31395         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
31396         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
31397         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
31398         (AC_SUBST(POW_LIBM)): Likewise.
31399         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
31400
31401 2000-01-23  Jim Meyering  <meyering@lucent.com>
31402
31403         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
31404         obstack.c.
31405
31406 2000-01-22  Jim Meyering  <meyering@lucent.com>
31407
31408         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
31409
31410         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
31411
31412         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
31413         configure.in
31414         (AC_CHECK_HEADERS): Likewise for sh-utils.
31415         (AC_CHECK_HEADERS): Likewise for textutils.
31416         Merge the three lists of headers.
31417
31418         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
31419         from fileutils' configure.in.
31420
31421         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
31422         code. Moved tests into their own function (_jm_DECL_HEADERS) in
31423         check-decl.m4.
31424
31425         * m4/check-decl.m4: Use #if rather than #ifdef.
31426         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
31427         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
31428         (_jm_DECL_HEADERS): Define new function.
31429         (jm_CHECK_DECLARATIONS): Require it.
31430
31431 2000-01-22  Jim Meyering  <meyering@lucent.com>
31432
31433         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
31434         [! HAVE_DECL_STRTOULL]: Declare strtoull.
31435         Required for some AIX systems.  Reported by Christian Krackowizer.
31436         [TESTING] (main): New function.
31437
31438         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
31439         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
31440         letters.
31441
31442         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
31443         iswprint.
31444
31445         * lib/strverscmp.c (ISDIGIT): Define.
31446         (strverscmp): Use ISDIGIT, not isdigit.
31447
31448 2000-01-19  Jim Meyering  <meyering@lucent.com>
31449
31450         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
31451         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
31452         defines `struct timespec' in <sys/time.h>
31453
31454         * m4/c-bs-a.m4: Remove uses of changequote altogether.
31455         Thanks to Akim for explaining.
31456
31457 2000-01-17  Paul Eggert  <eggert@twinsun.com>
31458
31459         * lib/nanosleep.c (nanosleep):
31460         Don't use SA_INTERRUPT to decide whether to call sigaction, as
31461         POSIX.1 doesn't require SA_INTERRUPT and some systems
31462         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
31463         it's been part of POSIX.1 since day 1 (in 1988).
31464
31465 2000-01-17  Jim Meyering  <meyering@lucent.com>
31466
31467         * lib/interlock: Remove unused file.  Reported by François Pinard.
31468
31469 2000-01-16  Paul Eggert  <eggert@twinsun.com>
31470
31471         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
31472         alert, backslash, formfeed, and vertical tab unnecessarily in
31473         shell quoting style.
31474
31475 2000-01-16  Jim Meyering  <meyering@lucent.com>
31476
31477         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
31478         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
31479         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
31480         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
31481
31482 2000-01-16  Jim Meyering  <meyering@lucent.com>
31483
31484         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
31485         because the latter didn't work.
31486
31487 2000-01-15  Jim Meyering  <meyering@lucent.com>
31488
31489         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
31490         (AC_REPLACE_FUNCS): Add memcpy and memset.
31491         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
31492         Add strpbrk.
31493         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
31494
31495 2000-01-12  Jim Meyering  <meyering@lucent.com>
31496
31497         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
31498         (jm_PREREQ): Use it.
31499         (jm_PREREQ_READUTMP): New macro.
31500         (jm_PREREQ): Use it.
31501
31502 2000-01-11  Paul Eggert  <eggert@twinsun.com>
31503
31504         Quote multibyte characters correctly.
31505         * m4/c-bs-a.m4: New file.
31506         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
31507         (jm_PREREQ): Use it.
31508
31509 2000-01-11  Paul Eggert  <eggert@twinsun.com>
31510
31511         * m4/uintmax_t.m4: Port to autoconf 2.13.
31512
31513 2000-01-08  Jim Meyering  <meyering@ascend.com>
31514
31515         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
31516         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
31517
31518 2000-01-04  Jim Meyering  <meyering@ascend.com>
31519
31520         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
31521         jm_STRUCT_DIRENT_D_TYPE.
31522         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
31523         jm_STRUCT_DIRENT_D_INO.
31524         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
31525         jm_STRUCT_UTIMBUF.
31526         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
31527         renamings.
31528         * m4/utime.m4: Likewise.
31529
31530         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
31531         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
31532
31533 2000-01-03  Paul Eggert  <eggert@twinsun.com>
31534
31535         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
31536         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
31537
31538 2000-01-02  Jim Meyering  <meyering@ascend.com>
31539
31540         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
31541         remember if this is necessary.
31542
31543 1999-12-26  Jim Meyering  <meyering@ascend.com>
31544
31545         * m4/jm-macros.m4: Use it here.
31546         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
31547
31548 1999-12-23  Jim Meyering  <meyering@ascend.com>
31549
31550         * m4/jm-macros.m4: Check for clock_gettime (moved from
31551         fileutils/configure.in)
31552         Check for gettimeofday.
31553
31554 1999-12-20  Jim Meyering  <meyering@ascend.com>
31555
31556         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
31557         autoconf-2.14a-1999-12-20.
31558
31559 1999-12-19  Jim Meyering  <meyering@ascend.com>
31560
31561         * m4/lstat-slash.m4: New file.
31562         * m4/jm-macros.m4: Use the new macro:
31563         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31564
31565 1999-12-07  Jim Meyering  <meyering@ascend.com>
31566
31567         * m4/perl.m4: Require that File::Compare be available, too.
31568         Too many systems seem to lack it.
31569
31570         * m4/strftime.m4: Add checks for most of the cpp macros tested in
31571         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
31572
31573 1999-11-18  Paul Eggert  <eggert@twinsun.com>
31574
31575         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
31576         problem with the QNX 4.25 shell, which doesn't propagate exit
31577         status of failed commands inside shell assignments.
31578
31579 1999-11-17  Jim Meyering  <meyering@ascend.com>
31580
31581         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
31582
31583 1999-11-07  Jim Meyering  <meyering@ascend.com>
31584
31585         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
31586
31587 1999-11-06  Jim Meyering  <meyering@ascend.com>
31588
31589         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
31590         * m4/jm-macros.m4 (jm_MACROS): Use it here.
31591
31592 1999-11-05  Jim Meyering  <meyering@ascend.com>
31593
31594         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
31595         configure.in of textutils, fileutils, and sh-utils into this one
31596         (shared between those packages) file.
31597         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
31598         AC_STRUCT_ST_BLKSIZE.
31599
31600 1999-11-03  Jim Meyering  <meyering@ascend.com>
31601
31602         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
31603         of AC_CHECK_TYPE checks includes unistd.h.
31604         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
31605         Suggestion from Akim Demaille.
31606
31607 1999-10-30  Jim Meyering  <meyering@ascend.com>
31608
31609         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
31610         m4-quoted string.
31611         * m4/ls-mntd-fs.m4: Likewise.
31612         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
31613         * m4/jm-winsz1.m4: Likewise.
31614
31615         * m4/const.m4: Remove file, since the fix made it into the experimental
31616         version of autoconf.
31617         * m4/mktime.m4: Likewise.
31618
31619         * m4/check-type.m4: Remove file, now that the latest version of
31620         AC_CHECK_TYPE takes a third arg to specify additional #includes.
31621
31622         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
31623         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
31624         AC_CHECK_TYPE.
31625
31626 1999-10-04  Jim Meyering  <meyering@ascend.com>
31627
31628         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
31629
31630 1999-09-22  Paul Eggert  <eggert@twinsun.com>
31631
31632         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
31633         2.95.1 bug with HP-UX 10.20.
31634
31635 1999-09-17  Jim Meyering  <meyering@ascend.com>
31636
31637         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
31638         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
31639         due to missing strdup (against sh-utils-2.0).
31640
31641 1999-08-29  Jim Meyering  <meyering@ascend.com>
31642
31643         * m4/jm-macros.m4: Require jm_BISON.
31644         * m4/bison.m4: New file.
31645
31646 1999-08-17  Paul Eggert  <eggert@twinsun.com>
31647
31648         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
31649         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
31650
31651 1999-08-05  Jim Meyering  <meyering@ascend.com>
31652
31653         * m4/getline.m4: Rename test file from conftestdata to conftest.data
31654         to avoid conflicts with `conftest' on 8+3 filesystems.
31655         Suggestion from Eli Zaretskii.
31656
31657 1999-08-04  Jim Meyering  <meyering@ascend.com>
31658
31659         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
31660         fileutils and sh-utils (textutils's getline test was inadequate).
31661         (AM_FUNC_GETLINE): Run this test.
31662         (AC_CHECK_FUNCS): Check for getdelim.
31663         Reported by Bob Proulx.
31664
31665 1999-08-02  Jim Meyering  <meyering@ascend.com>
31666
31667         * m4/jm-macros.m4: Add a comment.
31668
31669 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31670
31671         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
31672         <inttypes.h> defines strtoumax as a macro (and not as a
31673         function).
31674
31675 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31676
31677         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
31678         that we can shift, multiply and divide unsigned long long
31679         values; Ultrix cc can't do it.
31680
31681 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31682
31683         * m4/mktime.m4: New file, which is a preview of what should appear
31684         in the next public autoconf release.
31685
31686 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31687
31688         * m4/lfs.m4: Remove this file.
31689         * m4/largefile.m4: New file.  It contains the old contents of
31690         lfs.m4, except that all names with prefix AC_LFS have been
31691         changed to use the prefix AC_SYS_LARGEFILE instead, to be
31692         compatible with future autoconf versions.  Also, some minor m4
31693         quoting problems have been fixed.
31694
31695 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31696
31697         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
31698         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
31699         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
31700         and simplify the shell code.
31701
31702 1999-08-01  Jim Meyering  <meyering@ascend.com>
31703
31704         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
31705         m4.
31706
31707 1999-07-20  Jim Meyering  <meyering@ascend.com>
31708
31709         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
31710
31711 1999-07-15  Jim Meyering  <meyering@ascend.com>
31712
31713         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
31714
31715 1999-05-22  Jim Meyering  <meyering@ascend.com>
31716
31717         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
31718
31719 1999-05-20  Jim Meyering  <meyering@ascend.com>
31720
31721         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
31722         Add a colon after each `then' in case $4 is empty.
31723
31724 1999-05-16  Jim Meyering  <meyering@ascend.com>
31725
31726         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
31727
31728 1999-05-10  Jim Meyering  <meyering@ascend.com>
31729
31730         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
31731
31732         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
31733         AC_FUNC_MKTIME.
31734
31735 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
31736
31737         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
31738
31739 1999-05-04  Paul Eggert  <eggert@twinsun.com>
31740
31741         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
31742         not CPPFLAGS, so that linking works correctly in IRIX.
31743
31744 1999-04-30  Paul Eggert  <eggert@twinsun.com>
31745
31746         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
31747
31748 1999-04-20  Paul Eggert  <eggert@twinsun.com>
31749
31750         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
31751         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
31752         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
31753         jm_AC_TYPE_UNSIGNED_LONG_LONG.
31754         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
31755
31756         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
31757
31758 1999-04-20  Jim Meyering  <meyering@ascend.com>
31759
31760         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
31761         AC_REPLACE xstroull if necessary.  From Paul Eggert.
31762         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
31763
31764 1999-04-18  Jim Meyering  <meyering@ascend.com>
31765
31766         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
31767         * m4/jm-macros.m4: Use it.
31768
31769 1999-04-06  Jim Meyering  <meyering@ascend.com>
31770
31771         * m4/strftime.m4: Remove test for %f.
31772
31773 1999-03-29  Jim Meyering  <meyering@ascend.com>
31774
31775         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
31776         superset of the AC_TYPE_* checks in the textutils, fileutils,
31777         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
31778         AC_TYPE_PID_T.
31779
31780 1999-03-28  Jim Meyering  <meyering@ascend.com>
31781
31782         * m4/jm-macros.m4: Define GNU_PACKAGE here.
31783         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
31784         replaced e.g., in the *.sh files of the sh-utils.
31785
31786 1999-03-20  Jim Meyering  <meyering@ascend.com>
31787
31788         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
31789         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
31790         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
31791
31792 1999-03-19  Jim Meyering  <meyering@ascend.com>
31793
31794         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
31795
31796 1999-03-12  Jim Meyering  <meyering@ascend.com>
31797
31798         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
31799
31800 1999-03-07  Jim Meyering  <meyering@ascend.com>
31801
31802         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
31803         declared.
31804
31805 1999-02-17  Jim Meyering  <meyering@ascend.com>
31806
31807         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
31808         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
31809
31810 1999-02-07  Jim Meyering  <meyering@ascend.com>
31811
31812         * m4/group-member.m4: New file -- extracted from sh-utils'
31813         configure.in.
31814
31815         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
31816         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
31817
31818 1999-02-06  Jim Meyering  <meyering@ascend.com>
31819
31820         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
31821         * m4/fnmatch.m4: Likewise.
31822         * m4/getgroups.m4: Likewise.
31823         * m4/lstat.m4: Likewise.
31824         * m4/malloc.m4: Likewise.
31825         * m4/putenv.m4: Likewise.
31826         * m4/realloc.m4: Likewise.
31827         * m4/regex.m4: Likewise.
31828         * m4/stat.m4: Likewise.
31829         * m4/strftime.m4: Likewise.
31830         Suggestion from Alain Magloire.
31831
31832         * m4/chown.m4: Use `.$ac_objext', not `.o'.
31833         * m4/fnmatch.m4: Likewise.
31834         * m4/getgroups.m4: Likewise.
31835         * m4/getline.m4: Likewise.
31836         * m4/lstat.m4: Likewise.
31837         * m4/malloc.m4: Likewise.
31838         * m4/memcmp.m4: Likewise.
31839         * m4/putenv.m4: Likewise.
31840         * m4/realloc.m4: Likewise.
31841         * m4/regex.m4: Likewise.
31842         * m4/stat.m4: Likewise.
31843         * m4/strftime.m4: Likewise.
31844         Suggestion from Alain Magloire.
31845
31846         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
31847         an argument.
31848
31849         * m4/regex.m4: Add a run-time Test for proper operation of
31850         re_compile_pattern.
31851
31852 1999-01-31  Jim Meyering  <meyering@ascend.com>
31853
31854         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
31855
31856 1999-01-30  Jim Meyering  <meyering@ascend.com>
31857
31858         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
31859
31860         * m4/jm-mktime.m4: Make this a wrapper around the official
31861         AM_FUNC_MKTIME rather than my private copy, now that the official one
31862         is up to date.
31863         * m4/mktime.m4: Remove file.
31864
31865         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
31866         * m4/uptime.m4: Likewise.
31867         * m4/uintmax_t.m4: Likewise.
31868
31869 1999-01-28  Jim Meyering  <meyering@ascend.com>
31870
31871         * m4/jm-macros.m4: Use jm_AFS.
31872         * m4/afs.m4: New file (from fileutils' configure.in).
31873
31874         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
31875         * m4/chown.m4: Likewise.
31876         * m4/d-ino.m4: Likewise.
31877         * m4/d-type.m4: Likewise.
31878         * m4/fnmatch.m4: Likewise.
31879         * m4/getgroups.m4: Likewise.
31880         * m4/gettext.m4: Likewise.
31881         * m4/jm-mktime.m4: Likewise.
31882         * m4/jm-winsz2.m4: Likewise.
31883         * m4/lcmessage.m4: Likewise.
31884         * m4/ls-mntd-fs.m4: Likewise.
31885         * m4/malloc.m4: Likewise.
31886         * m4/memcmp.m4: Likewise.
31887         * m4/putenv.m4: Likewise.
31888         * m4/realloc.m4: Likewise.
31889         * m4/st_mtim.m4: Likewise.
31890         * m4/strftime.m4: Likewise.
31891
31892 1999-01-16  Jim Meyering  <meyering@ascend.com>
31893
31894         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
31895         (ARGMATCH_DIE_DECL): Define.
31896
31897 1999-01-12  Jim Meyering  <meyering@ascend.com>
31898
31899         * m4/Makefile.am.in: Rewrite to avoid using fmt.
31900         Reported by Lars Hecking.
31901
31902 1999-01-10  Jim Meyering  <meyering@ascend.com>
31903
31904         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
31905         gross kludge.
31906         * m4/inttypes_h.m4: Likewise.
31907         * m4/lstat.m4: Likewise.
31908         * m4/malloc.m4: Likewise.
31909         * m4/readdir.m4: Likewise.
31910         * m4/realloc.m4: Likewise.
31911         * m4/st_dm_mode.m4: Likewise.
31912         * m4/stat.m4: Likewise.
31913         * m4/utimbuf.m4: Likewise.
31914         * m4/utimes.m4: Likewise.
31915
31916         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
31917         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
31918         comments in config.h.in are meaningful.
31919
31920         * m4/jm-macros.m4: Require autoconf-2.13 here.
31921
31922         * m4/regex.m4: By default, don't use the included regex.c on systems
31923         with glibc 2.  Suggestion from Uli Drepper.
31924
31925 1999-01-02  Jim Meyering  <meyering@ascend.com>
31926
31927         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
31928
31929 1998-12-18  Jim Meyering  <meyering@ascend.com>
31930
31931         * m4/Makefile.am.in (Makefile.am): Simplify rule.
31932         Based on a suggestion from Lars Hecking.
31933
31934 1998-11-16  Paul Eggert  <eggert@twinsun.com>
31935
31936         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
31937
31938 1998-11-16  Jim Meyering  <meyering@ascend.com>
31939
31940         * m4/lfs.m4: Double-quote the `uname...` expression.
31941
31942 1998-11-14  Jim Meyering  <meyering@ascend.com>
31943
31944         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
31945         * m4/stat.m4: Likewise.
31946
31947 1998-11-03  Jim Meyering  <meyering@ascend.com>
31948
31949         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
31950         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
31951
31952 1998-10-18  Jim Meyering  <meyering@ascend.com>
31953
31954         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
31955
31956 1998-10-17  Jim Meyering  <meyering@ascend.com>
31957
31958         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
31959         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
31960         calls for those previously hard-coded headers.  Instead, take a new
31961         parameter.
31962         (jm_CHECK_DECLARATIONS): Reflect interface change.
31963         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
31964         (jm_CHECK_DECL_LOCALTIME_R): New macro.
31965
31966         * m4/mktime.m4: Test for spring-forward gap before long-running test.
31967
31968 1998-10-14  Jim Meyering  <meyering@ascend.com>
31969
31970         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
31971         instead of "TZ=America/Vancouver".  From Paul Eggert.
31972
31973 1998-10-11  Jim Meyering  <meyering@ascend.com>
31974
31975         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
31976         This adds a test for a recently added compatibility fix for mktime.c.
31977         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
31978
31979 1998-09-27  Jim Meyering  <meyering@ascend.com>
31980
31981         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
31982
31983         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
31984         ../configure.in, including a change from Gordon Matzigkeit to allow
31985         cross-compiling for the Hurd.
31986
31987         * m4/glibc.m4: New file/macro to test for the GNU C Library
31988         versions 1 and 2.  From Gordon Matzigkeit.
31989         Indent.
31990
31991 1998-09-21  Jim Meyering  <meyering@ascend.com>
31992
31993         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
31994
31995 1998-08-18  Paul Eggert  <eggert@twinsun.com>
31996
31997         Port nanosecond-resolution times to UnixWare 2.1.2 and
31998         pedantic Solaris 2.6.
31999
32000         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
32001         AC_STRUCT_ST_MTIM.
32002         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
32003         Generate name of ns member, instead of just 1 or undef.
32004         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
32005
32006 1998-08-15  Jim Meyering  <meyering@ascend.com>
32007
32008         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
32009         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
32010         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
32011         instead of jm_TYPE_SSIZE_T.
32012
32013 1998-08-12  Jim Meyering  <meyering@ascend.com>
32014
32015         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
32016
32017 1998-08-02  Jim Meyering  <meyering@ascend.com>
32018
32019         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
32020         in acconfig.h manually.
32021
32022 1998-07-31  Paul Eggert  <eggert@twinsun.com>
32023
32024         * m4/st_mtim.m4: New file.
32025
32026 1998-07-28  Jim Meyering  <meyering@ascend.com>
32027
32028         * m4/utimes.m4: Undef stat.
32029
32030 1998-07-25  Jim Meyering  <meyering@ascend.com>
32031
32032         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
32033         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
32034
32035 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
32036
32037         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
32038         uid and gid actually remain unchanged.
32039
32040 1998-07-07  Jim Meyering  <meyering@ascend.com>
32041
32042         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
32043
32044 1998-07-04  Jim Meyering  <meyering@ascend.com>
32045
32046         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
32047         to prove that this macro can be used in packages without regex.c.
32048
32049 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
32050
32051         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
32052         is to be used.
32053
32054 1998-07-03  Jim Meyering  <meyering@ascend.com>
32055
32056         * m4/gettext.m4: Add -lintl if it's found to be necessary.
32057
32058         * m4/gettext.m4: New file -- from gettext-0.10.35.
32059         * m4/lcmessage.m4: Likewise.
32060         * m4/progtest.m4: Likewise.
32061
32062         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
32063         * m4/jm-macros.m4: Require the new macro.
32064
32065 1998-06-29  Jim Meyering  <meyering@ascend.com>
32066
32067         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
32068         for the definition of NGROUPS (used in a system header included
32069         by sys/mount.h).
32070
32071 1998-06-28  Jim Meyering  <meyering@ascend.com>
32072
32073         * m4/ls-mntd-fs.m4: New file.
32074         * m4/fstypename.m4: New file.
32075
32076         * m4/jm-macros.m4: Require the new macro.
32077         * m4/jm-glibc-io.m4: New file.
32078
32079 1998-05-19  Jim Meyering  <meyering@ascend.com>
32080
32081         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
32082         * m4/lchown.m4: New file.
32083
32084         * m4/Makefile.am.in: New file.
32085         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
32086
32087 1998-05-14  Jim Meyering  <meyering@ascend.com>
32088
32089         * m4/Makefile.am (EXTRA_DIST): Add them.
32090         * m4/jm-macros.m4: New file.
32091         * m4/utimbuf.m4: New file.
32092
32093 1998-05-12  Jim Meyering  <meyering@ascend.com>
32094
32095         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
32096
32097 1998-05-11  Jim Meyering  <meyering@ascend.com>
32098
32099         * m4/isc-posix.m4: New file.
32100
32101 1998-05-10  Jim Meyering  <meyering@ascend.com>