9395cc35aee0b1d931c82b481e0a6447086c318f
[gnulib.git] / ChangeLog
1 2007-07-13  Bruno Haible  <bruno@clisp.org>
2
3         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
4         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
5
6 2007-07-12  Bruno Haible  <bruno@clisp.org>
7
8         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
9         in the modules files.
10
11 2007-07-11  Karl Berry  <karl@gnu.org>
12
13         * MODULES.html.sh (func_module): use
14          sed -e '\|^'"${includefile}"'$|d' 
15          instead of /.../d, to avoid errors on $includefile's containing /.
16
17 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
18
19         * gnulib-tool (func_import): Avoid duplication of --avoid
20         statements
21         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
22         names to `_' in variable names.
23
24 2007-07-10  Eric Blake  <ebb9@byu.net>
25
26         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
27         * NEWS: Document this change.
28
29 2007-07-08  Bruno Haible  <bruno@clisp.org>
30
31         Update to Unicode 5.0.
32         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
33         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
34         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
35         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
36         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
37         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
38         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
39         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
40         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
41         U+10A3F, U+1D242..U+1D244.
42         (nonspacing_table_ind): Update.
43         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
44         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
45
46 2007-07-08  Bruno Haible  <bruno@clisp.org>
47
48         Update to Unicode 5.0.
49         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
50         code transform. Extend the name index field of unicode_name_to_code and
51         unicode_code_to_name from 16 to 24 bits.
52         * lib/uniname/uniname.c (unicode_character_name,
53         unicode_name_character): Add the range 0x12xxx to the code transform.
54         * lib/uniname/uninames.h: Regenerated.
55         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
56
57 2007-07-07  Bruno Haible  <bruno@clisp.org>
58
59         * modules/wcwidth-tests: New file.
60         * tests/test-wcwidth.c: New file.
61
62         Work around MacOS X wcwidth() bug.
63         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
64         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
65         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
66         original wcwidth in non-UTF-8 locales.
67         * modules/wcwidth (Depends-on): Add localcharset, streq,
68         uniwidth/width.
69         * doc/functions/wcwidth.texi: Update.
70
71 2007-07-07  Bruno Haible  <bruno@clisp.org>
72
73         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
74         (wcwidth): New declaration.
75         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
76         macros.
77         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
78         here. Prepare for creating <wchar.h> unconditionally.
79         * modules/wchar (Depends-on): Add link-warning.
80         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
81         REPLACE_WCWIDTH, and GL_LINK_WARNING.
82         * lib/wcwidth.h: Remove file.
83         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
84         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
85         * modules/wcwidth (Files): Remove lib/wcwidth.h.
86         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
87         (Include): Replace wcwidth.h with <wchar.h>.
88         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
89         * lib/mbchar.h: Don't include wcwidth.h.
90         * lib/mbswidth.c: Likewise.
91         * NEWS: Mention the change.
92
93 2007-07-07  Bruno Haible  <bruno@clisp.org>
94
95         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
96         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
97         definition with an external declaration.
98         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
99         defined as a function. Remove AC_C_INLINE requirement.
100         * modules/wcwidth (Files): Add lib/wcwidth.c.
101         (Makefile.am): Remove redundant statement.
102
103 2007-07-07  Bruno Haible  <bruno@clisp.org>
104
105         * MODULES.html.sh (Unicode string functions): Add the new modules.
106
107         * tests/uniwidth/test-u32-strwidth.c: New file.
108         * modules/uniwidth/u32-strwidth-tests: New file.
109
110         * lib/uniwidth/u32-strwidth.c: New file.
111         * modules/uniwidth/u32-strwidth: New file.
112
113         * tests/uniwidth/test-u16-strwidth.c: New file.
114         * modules/uniwidth/u16-strwidth-tests: New file.
115
116         * lib/uniwidth/u16-strwidth.c: New file.
117         * modules/uniwidth/u16-strwidth: New file.
118
119         * tests/uniwidth/test-u8-strwidth.c: New file.
120         * modules/uniwidth/u8-strwidth-tests: New file.
121
122         * lib/uniwidth/u8-strwidth.c: New file.
123         * modules/uniwidth/u8-strwidth: New file.
124
125         * tests/uniwidth/test-u32-width.c: New file.
126         * modules/uniwidth/u32-width-tests: New file.
127
128         * lib/uniwidth/u32-width.c: New file.
129         * modules/uniwidth/u32-width: New file.
130
131         * tests/uniwidth/test-u16-width.c: New file.
132         * modules/uniwidth/u16-width-tests: New file.
133
134         * lib/uniwidth/u16-width.c: New file.
135         * modules/uniwidth/u16-width: New file.
136
137         * tests/uniwidth/test-u8-width.c: New file.
138         * modules/uniwidth/u8-width-tests: New file.
139
140         * lib/uniwidth/u8-width.c: New file.
141         * modules/uniwidth/u8-width: New file.
142
143         * tests/uniwidth/test-uc_width.c: New file.
144         * modules/uniwidth/width-tests: New file.
145
146         * lib/uniwidth/width.c: New file, from GNU libiconv.
147         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
148         * modules/uniwidth/width: New file.
149
150         * lib/uniwidth.h: New file, from GNU libiconv.
151         * modules/uniwidth/base: New file.
152
153 2007-07-07  Bruno Haible  <bruno@clisp.org>
154
155         * lib/uniname.h: New file, from GNU gettext.
156         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
157         * lib/uniname/uninames.h: New file, from GNU gettext.
158         * lib/uniname/uniname.c: New file, from GNU gettext.
159         * tests/uniname/test-uninames.sh: New file.
160         * tests/uniname/test-uninames.c: New file, from GNU gettext.
161         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
162         * modules/uniname/base: New file.
163         * modules/uniname/uniname: New file.
164         * modules/uniname/uniname-tests: New file.
165         * MODULES.html.sh (Unicode string functions): Add the new modules.
166
167 2007-07-06  Bruno Haible  <bruno@clisp.org>
168
169         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
170
171 2007-07-06  Bruno Haible  <bruno@clisp.org>
172
173         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
174         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
175         includes <cygwin/sys_time.h> which includes <sys/select.h> which
176         include <sys/time.h>.
177         Reported by Eric Blake.
178
179 2007-07-06  Eric Blake  <ebb9@byu.net>
180
181         Fix testing canonicalize on cygwin.
182         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
183         Revert patch from 2007-06-19.
184         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
185         canonicalize module is also in use.
186         * tests/test-canonicalize.c: New file.
187         * tests/test-canonicalize.sh: Likewise.
188         * modules/canonicalize-tests: Likewise.
189
190 2007-07-06  Jim Meyering  <jim@meyering.net>
191
192         * lib/getugroups.c (getugroups): Detect getgrent failure.
193         Adjust comment to reflect reality: this function may return -1.
194
195 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
196
197         * build-aux/bootstrap (TP_URL,get_translations): Update to use
198         the new TP address.
199         (usage): Fix typo
200         (gnulib_mk): New variable.
201
202 2007-07-05  Jim Meyering  <jim@meyering.net>
203
204         Don't let endgrent clobber errno, no matter how improbable.
205         * lib/getugroups.c (getugroups): Save and restore errno around
206         endgrent call.
207
208         Close the group DB even when failing with 2^31 or more members.
209         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
210
211 2007-07-04  Jim Meyering  <jim@meyering.net>
212
213         * lib/getugroups.h: New file.
214         * lib/getugroups.c: Include "getugroups.h".
215         Remove uses of "register" keyword.
216         Move local variable, "cp", down into scope where used.
217         Give "username" parameter the "const" attribute.
218         * modules/getugroups (Files): Add lib/getugroups.h
219
220 2007-07-04  Karl Berry  <karl@gnu.org>
221
222         * MODULES.html.sh (func_all_modules): Complete rename of
223         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
224
225 2007-07-02  Bruno Haible  <bruno@clisp.org>
226
227         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
228         mode, when inttypes.h comes from gnulib.
229         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
230
231 2007-07-02  Simon Josefsson  <simon@josefsson.org>
232
233         * NEWS: Mention lgpl module name change.
234
235         * modules/lgpl-2.1: Renamed from lgpl.
236
237         * NEWS: Mention gpl module name change.
238
239         * modules/gpl-3.0: New file, based on gpl-2.0.
240
241         * modules/gpl-2.0: Renamed from gpl.
242
243         * modules/gpl: Fix filename, doc/gpl.texi is now found at
244         doc/gpl-2.0.texi.
245
246 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
247
248         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
249         #define __STDC_LIMIT_MACROS temporarily while including
250         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
251         Problem reported by Joel E. Denny in
252         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
253
254 2007-07-01  Bruno Haible  <bruno@clisp.org>
255
256         * lib/unistdio.h: New file.
257         * lib/unistdio/u-asnprintf.h: New file.
258         * lib/unistdio/u-asprintf.h: New file.
259         * lib/unistdio/u-printf-args.c: New file.
260         * lib/unistdio/u-printf-args.h: New file.
261         * lib/unistdio/u-printf-parse.h: New file.
262         * lib/unistdio/u-snprintf.h: New file.
263         * lib/unistdio/u-sprintf.h: New file.
264         * lib/unistdio/u-vasprintf.h: New file.
265         * lib/unistdio/u-vsnprintf.h: New file.
266         * lib/unistdio/u-vsprintf.h: New file.
267         * lib/unistdio/ulc-asnprintf.c: New file.
268         * lib/unistdio/ulc-asprintf.c: New file.
269         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
270         * lib/unistdio/ulc-printf-parse.c: New file.
271         * lib/unistdio/ulc-snprintf.c: New file.
272         * lib/unistdio/ulc-sprintf.c: New file.
273         * lib/unistdio/ulc-vasnprintf.c: New file.
274         * lib/unistdio/ulc-vasprintf.c: New file.
275         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
276         * lib/unistdio/ulc-vsnprintf.c: New file.
277         * lib/unistdio/ulc-vsprintf.c: New file.
278         * lib/unistdio/u8-asnprintf.c: New file.
279         * lib/unistdio/u8-asprintf.c: New file.
280         * lib/unistdio/u8-printf-parse.c: New file.
281         * lib/unistdio/u8-snprintf.c: New file.
282         * lib/unistdio/u8-sprintf.c: New file.
283         * lib/unistdio/u8-vasnprintf.c: New file.
284         * lib/unistdio/u8-vasprintf.c: New file.
285         * lib/unistdio/u8-vsnprintf.c: New file.
286         * lib/unistdio/u8-vsprintf.c: New file.
287         * lib/unistdio/u8-u8-asnprintf.c: New file.
288         * lib/unistdio/u8-u8-asprintf.c: New file.
289         * lib/unistdio/u8-u8-snprintf.c: New file.
290         * lib/unistdio/u8-u8-sprintf.c: New file.
291         * lib/unistdio/u8-u8-vasnprintf.c: New file.
292         * lib/unistdio/u8-u8-vasprintf.c: New file.
293         * lib/unistdio/u8-u8-vsnprintf.c: New file.
294         * lib/unistdio/u8-u8-vsprintf.c: New file.
295         * lib/unistdio/u16-asnprintf.c: New file.
296         * lib/unistdio/u16-asprintf.c: New file.
297         * lib/unistdio/u16-printf-parse.c: New file.
298         * lib/unistdio/u16-snprintf.c: New file.
299         * lib/unistdio/u16-sprintf.c: New file.
300         * lib/unistdio/u16-vasnprintf.c: New file.
301         * lib/unistdio/u16-vasprintf.c: New file.
302         * lib/unistdio/u16-vsnprintf.c: New file.
303         * lib/unistdio/u16-vsprintf.c: New file.
304         * lib/unistdio/u16-u16-asnprintf.c: New file.
305         * lib/unistdio/u16-u16-asprintf.c: New file.
306         * lib/unistdio/u16-u16-snprintf.c: New file.
307         * lib/unistdio/u16-u16-sprintf.c: New file.
308         * lib/unistdio/u16-u16-vasnprintf.c: New file.
309         * lib/unistdio/u16-u16-vasprintf.c: New file.
310         * lib/unistdio/u16-u16-vsnprintf.c: New file.
311         * lib/unistdio/u16-u16-vsprintf.c: New file.
312         * lib/unistdio/u32-asnprintf.c: New file.
313         * lib/unistdio/u32-asprintf.c: New file.
314         * lib/unistdio/u32-printf-parse.c: New file.
315         * lib/unistdio/u32-snprintf.c: New file.
316         * lib/unistdio/u32-sprintf.c: New file.
317         * lib/unistdio/u32-vasnprintf.c: New file.
318         * lib/unistdio/u32-vasprintf.c: New file.
319         * lib/unistdio/u32-vsnprintf.c: New file.
320         * lib/unistdio/u32-vsprintf.c: New file.
321         * lib/unistdio/u32-u32-asnprintf.c: New file.
322         * lib/unistdio/u32-u32-asprintf.c: New file.
323         * lib/unistdio/u32-u32-snprintf.c: New file.
324         * lib/unistdio/u32-u32-sprintf.c: New file.
325         * lib/unistdio/u32-u32-vasnprintf.c: New file.
326         * lib/unistdio/u32-u32-vasprintf.c: New file.
327         * lib/unistdio/u32-u32-vsnprintf.c: New file.
328         * lib/unistdio/u32-u32-vsprintf.c: New file.
329         * tests/unistdio/test-ulc-asnprintf1.c: New file.
330         * tests/unistdio/test-ulc-asnprintf1.h: New file.
331         * tests/unistdio/test-ulc-printf1.h: New file.
332         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
333         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
334         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
335         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
336         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
337         * tests/unistdio/test-ulc-vasprintf1.c: New file.
338         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
339         * tests/unistdio/test-ulc-vsprintf1.c: New file.
340         * tests/unistdio/test-u8-asnprintf1.c: New file.
341         * tests/unistdio/test-u8-asnprintf1.h: New file.
342         * tests/unistdio/test-u8-printf1.h: New file.
343         * tests/unistdio/test-u8-vasnprintf1.c: New file.
344         * tests/unistdio/test-u8-vasnprintf2.c: New file.
345         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
346         * tests/unistdio/test-u8-vasnprintf3.c: New file.
347         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
348         * tests/unistdio/test-u8-vasprintf1.c: New file.
349         * tests/unistdio/test-u8-vsnprintf1.c: New file.
350         * tests/unistdio/test-u8-vsprintf1.c: New file.
351         * tests/unistdio/test-u16-asnprintf1.c: New file.
352         * tests/unistdio/test-u16-asnprintf1.h: New file.
353         * tests/unistdio/test-u16-printf1.h: New file.
354         * tests/unistdio/test-u16-vasnprintf1.c: New file.
355         * tests/unistdio/test-u16-vasnprintf2.c: New file.
356         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
357         * tests/unistdio/test-u16-vasnprintf3.c: New file.
358         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
359         * tests/unistdio/test-u16-vasprintf1.c: New file.
360         * tests/unistdio/test-u16-vsnprintf1.c: New file.
361         * tests/unistdio/test-u16-vsprintf1.c: New file.
362         * tests/unistdio/test-u32-asnprintf1.c: New file.
363         * tests/unistdio/test-u32-asnprintf1.h: New file.
364         * tests/unistdio/test-u32-printf1.h: New file.
365         * tests/unistdio/test-u32-vasnprintf1.c: New file.
366         * tests/unistdio/test-u32-vasnprintf2.c: New file.
367         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
368         * tests/unistdio/test-u32-vasnprintf3.c: New file.
369         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
370         * tests/unistdio/test-u32-vasprintf1.c: New file.
371         * tests/unistdio/test-u32-vsnprintf1.c: New file.
372         * tests/unistdio/test-u32-vsprintf1.c: New file.
373         * modules/unistdio/base: New file.
374         * modules/unistdio/u-printf-args: New file.
375         * modules/unistdio/ulc-asnprintf: New file.
376         * modules/unistdio/ulc-asprintf: New file.
377         * modules/unistdio/ulc-fprintf: New file.
378         * modules/unistdio/ulc-printf-parse: New file.
379         * modules/unistdio/ulc-snprintf: New file.
380         * modules/unistdio/ulc-sprintf: New file.
381         * modules/unistdio/ulc-vasnprintf: New file.
382         * modules/unistdio/ulc-vasprintf: New file.
383         * modules/unistdio/ulc-vfprintf: New file.
384         * modules/unistdio/ulc-vsnprintf: New file.
385         * modules/unistdio/ulc-vsprintf: New file.
386         * modules/unistdio/u8-asnprintf: New file.
387         * modules/unistdio/u8-asprintf: New file.
388         * modules/unistdio/u8-printf-parse: New file.
389         * modules/unistdio/u8-snprintf: New file.
390         * modules/unistdio/u8-sprintf: New file.
391         * modules/unistdio/u8-vasnprintf: New file.
392         * modules/unistdio/u8-vasprintf: New file.
393         * modules/unistdio/u8-vsnprintf: New file.
394         * modules/unistdio/u8-vsprintf: New file.
395         * modules/unistdio/u8-u8-asnprintf: New file.
396         * modules/unistdio/u8-u8-asprintf: New file.
397         * modules/unistdio/u8-u8-snprintf: New file.
398         * modules/unistdio/u8-u8-sprintf: New file.
399         * modules/unistdio/u8-u8-vasnprintf: New file.
400         * modules/unistdio/u8-u8-vasprintf: New file.
401         * modules/unistdio/u8-u8-vsnprintf: New file.
402         * modules/unistdio/u8-u8-vsprintf: New file.
403         * modules/unistdio/u16-asnprintf: New file.
404         * modules/unistdio/u16-asprintf: New file.
405         * modules/unistdio/u16-printf-parse: New file.
406         * modules/unistdio/u16-snprintf: New file.
407         * modules/unistdio/u16-sprintf: New file.
408         * modules/unistdio/u16-vasnprintf: New file.
409         * modules/unistdio/u16-vasprintf: New file.
410         * modules/unistdio/u16-vsnprintf: New file.
411         * modules/unistdio/u16-vsprintf: New file.
412         * modules/unistdio/u16-u16-asnprintf: New file.
413         * modules/unistdio/u16-u16-asprintf: New file.
414         * modules/unistdio/u16-u16-snprintf: New file.
415         * modules/unistdio/u16-u16-sprintf: New file.
416         * modules/unistdio/u16-u16-vasnprintf: New file.
417         * modules/unistdio/u16-u16-vasprintf: New file.
418         * modules/unistdio/u16-u16-vsnprintf: New file.
419         * modules/unistdio/u16-u16-vsprintf: New file.
420         * modules/unistdio/u32-asnprintf: New file.
421         * modules/unistdio/u32-asprintf: New file.
422         * modules/unistdio/u32-printf-parse: New file.
423         * modules/unistdio/u32-snprintf: New file.
424         * modules/unistdio/u32-sprintf: New file.
425         * modules/unistdio/u32-vasnprintf: New file.
426         * modules/unistdio/u32-vasprintf: New file.
427         * modules/unistdio/u32-vsnprintf: New file.
428         * modules/unistdio/u32-vsprintf: New file.
429         * modules/unistdio/u32-u32-asnprintf: New file.
430         * modules/unistdio/u32-u32-asprintf: New file.
431         * modules/unistdio/u32-u32-snprintf: New file.
432         * modules/unistdio/u32-u32-sprintf: New file.
433         * modules/unistdio/u32-u32-vasnprintf: New file.
434         * modules/unistdio/u32-u32-vasprintf: New file.
435         * modules/unistdio/u32-u32-vsnprintf: New file.
436         * modules/unistdio/u32-u32-vsprintf: New file.
437         * modules/unistdio/ulc-asnprintf-tests: New file.
438         * modules/unistdio/ulc-vasnprintf-tests: New file.
439         * modules/unistdio/ulc-vasprintf-tests: New file.
440         * modules/unistdio/ulc-vsnprintf-tests: New file.
441         * modules/unistdio/ulc-vsprintf-tests: New file.
442         * modules/unistdio/u8-asnprintf-tests: New file.
443         * modules/unistdio/u8-vasnprintf-tests: New file.
444         * modules/unistdio/u8-vasprintf-tests: New file.
445         * modules/unistdio/u8-vsnprintf-tests: New file.
446         * modules/unistdio/u8-vsprintf-tests: New file.
447         * modules/unistdio/u16-asnprintf-tests: New file.
448         * modules/unistdio/u16-vasnprintf-tests: New file.
449         * modules/unistdio/u16-vasprintf-tests: New file.
450         * modules/unistdio/u16-vsnprintf-tests: New file.
451         * modules/unistdio/u16-vsprintf-tests: New file.
452         * modules/unistdio/u32-asnprintf-tests: New file.
453         * modules/unistdio/u32-vasnprintf-tests: New file.
454         * modules/unistdio/u32-vasprintf-tests: New file.
455         * modules/unistdio/u32-vsnprintf-tests: New file.
456         * modules/unistdio/u32-vsprintf-tests: New file.
457         * MODULES.html.sh (Unicode string functions): Add the new modules.
458
459 2007-07-01  Bruno Haible  <bruno@clisp.org>
460
461         * lib/sprintf.c (sprintf): Limit the available length estimation,
462         to avoid address wraparound.
463         * lib/vsprintf.c (vsprintf): Likewise.
464         * modules/sprintf-posix (Dependencies): Add stdint.
465         * modules/vsprintf-posix (Dependencies): Likewise.
466
467 2007-07-01  Bruno Haible <bruno@clisp.org>
468
469         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
470         Windows PATH as well. Conservative double-quoting. Comments.
471
472 2007-07-01  Bruno Haible <bruno@clisp.org>
473             Eric Blake  <ebb9@byu.net>
474             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
475
476         * gnulib-tool (self_abspathname): Fix algorithm to cope with
477         empty components in $PATH, denoting '.'.
478
479 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
480
481         * gnulib-tool: Fix indentation.
482         (func_create_megatestdir): Likewise.
483         Report by Bruno Haible.
484
485 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
486
487         Sync from Automake.
488         * build-aux/gnupload: Fix shell portability issues with for loops.
489         Report by Karl Berry.
490
491 2007-06-29  Simon Josefsson  <simon@josefsson.org>
492
493         * build-aux/maint.mk (POURL): Use translationproject.org.
494
495 2007-06-27  Simon Josefsson  <simon@josefsson.org>
496             Bruno Haible  <bruno@clisp.org>
497
498         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
499         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
500         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
501         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
502         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
503
504 2007-06-27  Bruno Haible  <bruno@clisp.org>
505
506         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
507         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
508
509 2007-06-26  Karl Berry  <karl@gnu.org>
510
511         * MODULES.html.sh: remove xreadlink-with-size.
512
513 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
514
515         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
516         method that I hope also handles the double-include problem noted
517         by Bruno Haible in
518         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
519
520 2007-06-23  Bruno Haible  <bruno@clisp.org>
521
522         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
523         Don't let the 'mostlyclean' target fail if the last subdirectory could
524         not be removed.
525         Reported by Karl Berry.
526
527 2007-06-23  Bruno Haible  <bruno@clisp.org>
528
529         * gnulib-tool (echo): Add a speedier workaround for ksh.
530         * tests/test-echo.sh: Likewise.
531
532 2007-06-23  Bruno Haible  <bruno@clisp.org>
533
534         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
535         * tests/test-echo.sh: Likewise.
536
537 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
538
539         * gnulib-tool (IFS): Initialize early, so we don't set it to
540         empty later.
541         (self_abspathname): Rewrite algorithm to set it, reindent.
542         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
543         (func_create_megatestdir): Merge some sed scripts.
544
545 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
546
547         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
548         exposed by Sun Studio 11 cc on Solaris 8.
549
550 2007-06-22  Bruno Haible  <bruno@clisp.org>
551
552         * gnulib-tool (echo): Ensure the echo primitive does not interpret
553         backslashes.
554         * tests/test-echo.sh: New file.
555
556 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
557
558         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
559         simplify `sed_replace_build_aux' scripts, they are portable but
560         echoing them with `echo' is not.
561         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
562
563 2007-06-21  Karl Berry  <karl@gnu.org>
564
565         * config/srclist.txt: guess we can't handle the licenses via
566         srclist at the moment.
567
568 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
569
570         * MODULES.html.sh: Add include_next.
571         * modules/include_next: New file.
572
573 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
574
575         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
576         INCLUDE_NEXT.
577         (gl_CHECK_NEXT_HEADERS): New macro.
578         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
579         the obsolescent gl_ABSOLUTE_HEADER.
580         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
581         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
582         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
583         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
584         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
585         * m4/math_h.m4 (gl_MATH_H): Likewise.
586         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
587         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
588         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
589         * m4/stdint.m4 (gl_STDINT_H): Likewise.
590         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
591         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
592         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
593         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
594         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
595         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
596         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
597         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
598         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
599         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
600         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
601         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
602         * m4/inttypes.m4 (gl_INTTYPES_H): Define
603         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
604         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
605         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
606         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
607         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
608         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
609         * lib/float_.h: Likewise.
610         * lib/inttypes_.h: Likewise.
611         * lib/math_.h: Likewise.
612         * lib/search_.h: Likewise.
613         * lib/signal_.h: Likewise.
614         * lib/stdint_.h: Likewise.
615         * lib/stdio_.h: Likewise.
616         * lib/stdlib_.h: Likewise.
617         * lib/string_.h: Likewise.
618         * lib/sys_stat_.h: Likewise.
619         * lib/sys_time_.h: Likewise.
620         * lib/time_.h: Likewise.
621         * lib/unistd_.h: Likewise.
622         * lib/wchar_.h: Likewise.
623         * lib/wctype_.h: Likewise.
624         * lib/dirent_.h: Likewise.
625         * lib/iconv_.h: Likewise.
626         * lib/locale_.h: Likewise.
627         * lib/netinet_in_.h: Likewise.
628         * lib/sys_select_.h: Likewise.
629         * lib/sys_socket_.h: Likewise.
630         * lib/sysexits_.h: Likewise.
631         * modules/fcntl (Depends-on): Depend on include_next, not
632         absolute_header.
633         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
634         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
635         * modules/fchdir: Likewise.
636         * modules/float: Likewise.
637         * modules/iconv_open: Likewise.
638         * modules/inttypes: Likewise.
639         * modules/locale: Likewise.
640         * modules/math: Likewise.
641         * modules/netinet_in: Likewise.
642         * modules/search: Likewise.
643         * modules/signal: Likewise.
644         * modules/stdint: Likewise.
645         * modules/stdio: Likewise.
646         * modules/stdlib: Likewise.
647         * modules/string: Likewise.
648         * modules/sys_select: Likewise.
649         * modules/sys_socket: Likewise.
650         * modules/sys_stat: Likewise.
651         * modules/sys_time: Likewise.
652         * modules/sysexits: Likewise.
653         * modules/time: Likewise.
654         * modules/unistd: Likewise.
655         * modules/wchar: Likewise.
656         * modules/wctype: Likewise.
657         * modules/sys_stat: Change maintainer to "all".
658         * modules/unistd: Likewise.
659
660 2007-06-20  Karl Berry  <karl@gnu.org>
661
662         * config/srclist.txt: track www changes in license files.
663
664 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
665
666         * build-aux/bootstrap: Remove stray dot.
667         Make sure build_aux settings are honored when linking
668         gnulib_extra_files.
669
670 2007-06-19  Eric Blake  <ebb9@byu.net>
671
672         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
673         Allow compilation on cygwin.
674
675 2007-06-19  Jim Meyering  <jim@meyering.net>
676
677         xreadlink-with-size: Remove module.  No longer used.
678         Ex-callers now use xreadlink or mreadlink-with-size.
679         * modules/xreadlink-with-size: Remove module.
680         * lib/xreadlink-with-size.c: Remove file.
681         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
682         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
683         just before the function definition *is* accurate.
684
685         Eliminate one way canonicalize_filename_mode could exit.
686         * lib/canonicalize.c (canonicalize_filename_mode):
687         Use mreadlink_with_size, not xreadlink_with_size.
688
689 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
690
691         Detect porting problems to FreeBSD/arm, which has time_t wider than
692         long int.  Original problem reported for GNU diff by Xin Li in
693         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
694         * modules/getdate (Depends-on): Add intprops, verify.
695         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
696         is an integer type no wider than long int.
697
698 2007-06-18  Jim Meyering  <jim@meyering.net>
699
700         New module: mreadlink-with-size.
701         * MODULES.html.sh: Add mreadlink-with-size.
702         * modules/mreadlink-with-size: New module
703         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
704         not xreadlink-with-size.
705         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
706
707 2007-06-16  Bruno Haible  <bruno@clisp.org>
708
709         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
710         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
711         Reported by Gary V. Vaughan <gary@gnu.org>.
712
713 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
714
715         Revamp lchown so that it lives in unistd.h where it belongs.
716         * lib/lchown.h: Remove.
717         * lib/dirchownmod.c: Don't include lib/lchown.h.
718         * lib/fchownat.c: Likewise.
719         * lib/openat.c: Likewise.
720         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
721         does not follow symlinks.
722         (EOPNOTSUPP): Define if not defined.
723         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
724         is defined to 0.
725         (lchown): New decl.
726         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
727         Do not check for lchown decl.
728         Set REPLACE_LCHOWN.
729         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
730         REPLACE_LCHOWN.
731         * modules/chown: Make it clear it follows symlinks.
732         * modules/lchown: Make it clear it doesn't follow symlinks.
733         (Files): Remove lib/lchown.h
734         (Depends-on): Add unistd.
735         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
736         (Include): Include <unistd.h>, not "lchown.h".
737         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
738         REPLACE_LCHOWN.
739
740 2007-06-15  Jim Meyering  <jim@meyering.net>
741
742         Change license (GPL to LGPL) of fsusage and dependents.
743         * modules/fsusage (License): Change to LGPL.
744         * modules/full-read (License): Likewise.
745         * modules/full-write (License): Likewise.
746         * modules/safe-read (License): Likewise.
747         * modules/safe-write (License): Likewise.
748
749 2007-06-14  Ben Pfaff  <blp@gnu.org>
750
751         Missing part of allocsa -> malloca transition.
752         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
753         gl_MALLOCA.
754
755 2007-06-12  Bruno Haible  <bruno@clisp.org>
756
757         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
758         to ia64, x86_64, i386.
759         Reported by Eric Blake.
760
761 2007-06-12  Bruno Haible  <bruno@clisp.org>
762
763         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
764         cross-compiling to x86_64.
765
766 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
767
768         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
769         glitch reported by Ralf Wildenhues in
770         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
771
772         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
773         Vin Shelton.
774
775 2007-06-11  Bruno Haible  <bruno@clisp.org>
776
777         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
778         replacement string.
779         Reported by Eric Blake.
780
781 2007-06-10  Bruno Haible  <bruno@clisp.org>
782
783         Prepare vasnprintf code for use with Unicode strings.
784         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
785         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
786         TYPE_U32_STRING.
787         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
788         a_u32_string variants.
789         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
790         * lib/printf-args.c: Don't include config.h and the specification
791         header if PRINTF_FETCHARGS is already defined.
792         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
793         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
794         TYPE_U16_STRING, TYPE_U32_STRING.
795         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
796         u16_directive, u16_directives, u32_directive, u32_directives): New
797         types.
798         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
799         New declarations.
800         * lib/printf-parse.c: Don't include config.h and the specification
801         header if PRINTF_PARSE is already defined. Eliminate the set of
802         parameters for WIDE_CHAR_VERSION; the user of this file must provide
803         them now. Include c-ctype.h.
804         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
805         directive and CHAR_T_ONLY_ASCII.
806         * lib/vasnprintf.c: Don't include config.h and the specification header
807         if VASNPRINTF is already defined.
808         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
809         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
810         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
811         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
812         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
813         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
814         code accordingly.
815         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
816         pad_ourselves also in this case, with the 'c' and 's' directives, and
817         with a different notion of "width".
818         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
819
820 2007-06-10  Bruno Haible  <bruno@clisp.org>
821
822         * modules/unistr/u32-mbsnlen: New file.
823         * lib/unistr/u32-mbsnlen.c: New file.
824
825         * modules/unistr/u16-mbsnlen: New file.
826         * lib/unistr/u16-mbsnlen.c: New file.
827
828         * modules/unistr/u8-mbsnlen: New file.
829         * lib/unistr/u8-mbsnlen.c: New file.
830
831         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
832         declarations.
833
834 2007-06-10  Bruno Haible  <bruno@clisp.org>
835
836         * lib/string_.h (mbsnlen): New declaration.
837         * lib/mbsnlen.c: New file.
838         * m4/mbsnlen.m4: New file.
839         * modules/mbsnlen: New file.
840         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
841         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
842         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
843
844 2007-06-10  Bruno Haible  <bruno@clisp.org>
845
846         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
847
848 2007-06-10  Bruno Haible  <bruno@clisp.org>
849
850         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
851         * lib/mbuiter.h: Likewise.
852
853 2007-06-10  Bruno Haible  <bruno@clisp.org>
854
855         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
856         declaration.
857
858 2007-06-10  Karl Berry  <karl@gnu.org>
859
860         * config/srclist.txt: remove gettext entries, Bruno prefers
861         to update individually.
862
863 2007-06-10  Bruno Haible  <bruno@clisp.org>
864
865         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
866         'maxlen'. Ensure only length + width bytes are allocated, not
867         length + 1 + width.
868
869 2007-06-09  Bruno Haible  <bruno@clisp.org>
870
871         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
872         (CHAR_T): Remove macro.
873         (VASNPRINTF): Update.
874
875 2007-06-09  Bruno Haible  <bruno@clisp.org>
876
877         * MODULES.html.sh (Unicode string functions): Add the new modules.
878
879         * modules/uniconv/u32-conv-to-enc: New file.
880         * lib/uniconv/u32-conv-to-enc.c: New file.
881         * modules/uniconv/u32-conv-to-enc-tests: New file.
882         * tests/uniconv/test-u32-conv-to-enc.c: New file.
883
884         * modules/uniconv/u16-conv-to-enc: New file.
885         * lib/uniconv/u16-conv-to-enc.c: New file.
886         * lib/uniconv/u-conv-to-enc.h: New file.
887         * modules/uniconv/u16-conv-to-enc-tests: New file.
888         * tests/uniconv/test-u16-conv-to-enc.c: New file.
889
890         * modules/uniconv/u8-conv-to-enc: New file.
891         * lib/uniconv/u8-conv-to-enc.c: New file.
892         * modules/uniconv/u8-conv-to-enc-tests: New file.
893         * tests/uniconv/test-u8-conv-to-enc.c: New file.
894
895         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
896         u32_conv_to_encoding): New declarations.
897
898 2007-06-09  Bruno Haible  <bruno@clisp.org>
899
900         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
901
902 2007-06-09  Bruno Haible  <bruno@clisp.org>
903
904         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
905         * modules/malloca: Renamed from modules/allocsa, updated.
906         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
907         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
908         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
909         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
910         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
911         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
912         * modules/xmalloca: Renamed from modules/xallocsa, updated.
913         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
914         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
915         * modules/c-strcasestr (Depends-on): Update.
916         * lib/c-strcasestr.c: Update.
917         * modules/c-strstr (Depends-on): Update.
918         * lib/c-strstr.c: Update.
919         * modules/canonicalize-lgpl (Depends-on): Update.
920         * lib/canonicalize-lgpl.c: Update.
921         * modules/clean-temp (Depends-on): Update.
922         * lib/clean-temp.c: Update.
923         * modules/csharpcomp (Depends-on): Update.
924         * lib/csharpcomp.c: Update.
925         * modules/csharpexec (Depends-on): Update.
926         * lib/csharpexec.c: Update.
927         * modules/javacomp (Depends-on): Update.
928         * lib/javacomp.c: Update.
929         * modules/javaexec (Depends-on): Update.
930         * lib/javaexec.c: Update.
931         * modules/mbscasestr (Depends-on): Update.
932         * lib/mbscasestr.c: Update.
933         * modules/mbsstr (Depends-on): Update.
934         * lib/mbsstr.c: Update.
935         * modules/setenv (Depends-on): Update.
936         * lib/setenv.c: Update.
937         * modules/strcasestr (Depends-on): Update.
938         * lib/strcasestr.c: Update.
939         * modules/striconveha (Depends-on): Update.
940         * lib/striconveha.c: Update.
941         * modules/relocatable-prog-wrapper (Files): Update.
942         * lib/relocwrapper.c: Update.
943         * build-aux/install-reloc: Update.
944         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
945
946 2007-06-08  Bruno Haible  <bruno@clisp.org>
947
948         Port to uClibc.
949         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
950         * lib/fpurge.c (fpurge): Likewise.
951         * lib/freading.c (freading): Likewise.
952         * lib/fseeko.c (rpl_fseeko): Likewise.
953         * lib/fseterr.c (fseterr): Likewise.
954         * lib/fwriting.c (fwriting): Likewise.
955         * tests/test-fflush.c (main): Avoid a failure on uClibc.
956
957 2007-06-08  Bruno Haible  <bruno@clisp.org>
958
959         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
960         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
961         * modules/gettext (Files): Add m4/intlmacosx.m4.
962
963 2007-06-07  Bruno Haible  <bruno@clisp.org>
964
965         * modules/localename-tests: New file.
966         * tests/test-localename.c: New file.
967
968         New module 'localename'.
969         * lib/localename.h: New file.
970         * lib/localename.c: New file, from GNU gettext.
971         * m4/localename.m4: New file.
972         * modules/localename: New file.
973
974 2007-06-07  Bruno Haible  <bruno@clisp.org>
975
976         Work around the lack of <wchar.h> on some builds of uClibc.
977         * doc/headers/wchar.texi: Update.
978         * lib/wchar_.h: Include <wchar.h> only if it exists.
979         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
980         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
981         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
982         doesn't exist.
983         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
984         * modules/mbfile (Depends-on): Add wchar.
985         * modules/mbiter (Depends-on): Likewise.
986         * modules/mbuiter (Depends-on): Likewise.
987         Reported by Simon Josefsson.
988
989 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
990
991         Work around problem reported by Steven M. Schweda in
992         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
993         Tru64 5.1B with the Compaq compiler environment installed declares
994         an 'isblank' function but does not define it in the C library.
995         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
996         * lib/regex_internal.h (isblank): Likewise.
997         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
998         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
999
1000 2007-06-05  Bruno Haible  <bruno@clisp.org>
1001
1002         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
1003         ia64.
1004         * modules/printf-safe: New file.
1005         * modules/fprintf-posix (Depends-on): Add printf-safe.
1006         * modules/printf-posix (Depends-on): Likewise.
1007         * modules/snprintf-posix (Depends-on): Likewise.
1008         * modules/sprintf-posix (Depends-on): Likewise.
1009         * modules/vasnprintf-posix (Depends-on): Likewise.
1010         * modules/vasprintf-posix (Depends-on): Likewise.
1011         * modules/vfprintf-posix (Depends-on): Likewise.
1012         * modules/vprintf-posix (Depends-on): Likewise.
1013         * modules/vsnprintf-posix (Depends-on): Likewise.
1014         * modules/vsprintf-posix (Depends-on): Likewise.
1015         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
1016         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
1017         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
1018         "no" on i386, x86_64, ia64.
1019         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
1020         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1021         on i386, x86_64, ia64.
1022         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
1023         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1024         on i386, x86_64, ia64.
1025         * tests/test-vasnprintf-posix.c: Include float.h.
1026         (LDBL80_WORDS): New macro.
1027         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1028         on i386, x86_64, ia64.
1029         * tests/test-vasprintf-posix.c: Include float.h.
1030         (LDBL80_WORDS): New macro.
1031         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1032         on i386, x86_64, ia64.
1033         * tests/test-snprintf-posix.c: Include float.h.
1034         * tests/test-sprintf-posix.c: Likewise.
1035         * tests/test-vsnprintf-posix.c: Likewise.
1036         * tests/test-vsprintf-posix.c: Likewise.
1037
1038 2007-06-05  Bruno Haible  <bruno@clisp.org>
1039
1040         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
1041         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
1042         non-IEEE numbers on i386, x86_64, ia64.
1043         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
1044         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
1045         * tests/test-isnanl.h: Include float.h.
1046         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
1047
1048 2007-06-05  Bruno Haible  <bruno@clisp.org>
1049
1050         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
1051         also the %a / %A. Handle the %a / %A code before this extra handling.
1052
1053 2007-06-05  Bruno Haible  <bruno@clisp.org>
1054
1055         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
1056         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
1057
1058 2007-06-05  Bruno Haible  <bruno@clisp.org>
1059
1060         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
1061         typo in variable name.
1062
1063 2007-06-05  Eric Blake  <ebb9@byu.net>
1064
1065         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
1066         Reported by Simon Josefsson.
1067
1068 2007-06-04  Bruno Haible  <bruno@clisp.org>
1069
1070         Avoid test failures on some PowerPC platforms.
1071         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
1072         Define differently for PowerPC.
1073         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
1074         Reported by Gary V. Vaughan <gary@gnu.org>.
1075
1076 2007-06-02  Bruno Haible  <bruno@clisp.org>
1077
1078         Fix test-stdint failure on FreeBSD/ia64.
1079         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
1080         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
1081         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
1082         * doc/headers/stdint.texi: Update.
1083
1084 2007-06-01  Bruno Haible  <bruno@clisp.org>
1085
1086         * tests/test-binary-io.c (main): Pass a third argument to open().
1087         Reported by Gary V. Vaughan <gary@gnu.org>.
1088
1089 2007-06-01  Bruno Haible  <bruno@clisp.org>
1090
1091         * doc/functions/frexpl.texi: Update for mingw.
1092
1093 2007-06-01  Bruno Haible  <bruno@clisp.org>
1094
1095         * tests/test-lseek.c (main): Disable test of errno for invalid third
1096         argument.
1097         * doc/functions/lseek.texi: Update.
1098         Reported by Gary V. Vaughan <gary@gnu.org>.
1099
1100 2007-05-28  Bruno Haible  <bruno@clisp.org>
1101
1102         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
1103
1104 2007-05-31  Eric Blake  <ebb9@byu.net>
1105
1106         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
1107         cross compiling.
1108
1109 2007-05-30  Eric Blake  <ebb9@byu.net>
1110         and Bruno Haible  <bruno@clisp.org>
1111
1112         Work around mingw test failures exposed by m4-1.4.9b.
1113         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
1114         * tests/test-unistd.c: Disable uid_t and git_t tests for the
1115         moment.
1116
1117 2007-05-30  Bruno Haible  <bruno@clisp.org>
1118
1119         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
1120         assuming that they are closed. Needed on HP-UX 11.
1121
1122 2007-05-29  Bruno Haible  <bruno@clisp.org>
1123
1124         Fix a problem with #include_next.
1125         * lib/dirent_.h: Split the double-inclusion guard.
1126         * lib/fcntl_.h: Likewise.
1127         * lib/float_.h: Likewise.
1128         * lib/iconv_.h: Likewise.
1129         * lib/inttypes_.h: Likewise.
1130         * lib/locale_.h: Likewise.
1131         * lib/math_.h: Likewise.
1132         * lib/netinet_in_.h: Likewise.
1133         * lib/search_.h: Likewise.
1134         * lib/signal_.h: Likewise.
1135         * lib/stdint_.h: Likewise.
1136         * lib/stdio_.h: Likewise.
1137         * lib/stdlib_.h: Likewise.
1138         * lib/string_.h: Likewise.
1139         * lib/sys_select_.h: Likewise.
1140         * lib/sys_socket_.h: Likewise.
1141         * lib/sys_stat_.h: Likewise.
1142         * lib/sys_time_.h: Likewise.
1143         * lib/sysexits_.h: Likewise.
1144         * lib/time_.h: Likewise.
1145         * lib/unistd_.h: Likewise.
1146         * lib/wchar_.h: Likewise.
1147         * lib/wctype_.h: Likewise.
1148
1149 2007-05-29  Bruno Haible  <bruno@clisp.org>
1150
1151         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
1152         for the moment.
1153
1154 2007-05-29  Bruno Haible  <bruno@clisp.org>
1155
1156         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
1157         invocation.
1158         Reported by Eric Blake.
1159
1160 2007-05-29  Bruno Haible  <bruno@clisp.org>
1161
1162         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
1163         compiling case.
1164
1165 2007-05-29  Eric Blake  <ebb9@byu.net>
1166             Bruno Haible  <bruno@clisp.org>
1167
1168         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
1169         cross compiles.
1170
1171 2007-05-28  Eric Blake  <ebb9@byu.net>
1172
1173         * modules/closein-tests (test_closein_LDADD): Support test on
1174         cygwin with libtool.
1175
1176 2007-05-28  Bruno Haible  <bruno@clisp.org>
1177
1178         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
1179         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
1180         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
1181         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
1182         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
1183         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
1184         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
1185         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
1186         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
1187
1188 2007-05-28  Eric Blake  <ebb9@byu.net>
1189
1190         Unconditionally include <config.h> in unit tests.
1191         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
1192         * tests/test-allocsa.c, tests/test-arcfour.c,
1193         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
1194         tests/test-array_list.c, tests/test-array_oset.c,
1195         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
1196         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
1197         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
1198         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
1199         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
1200         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
1201         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
1202         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
1203         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
1204         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
1205         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
1206         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
1207         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
1208         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
1209         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
1210         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
1211         test-md5.c, test-memmem.c, test-printf-posix.c,
1212         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
1213         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
1214         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
1215         test-strcasestr.c, test-striconv.c, test-striconveh.c,
1216         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
1217         test-vasnprintf-posix2.c, test-vasnprintf.c,
1218         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
1219         test-vfprintf-posix.c, test-vprintf-posix.c,
1220         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
1221         test-xvasprintf.c: Likewise.
1222
1223 2007-05-28  Bruno Haible  <bruno@clisp.org>
1224
1225         * gnulib-tool (func_import): Remember the --with-tests command-line
1226         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
1227         Reported by Eric Blake.
1228
1229 2007-05-28  Bruno Haible  <bruno@clisp.org>
1230
1231         * modules/ftell-tests: New file.
1232         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
1233         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
1234
1235         * lib/ftell.c: New file.
1236         * modules/ftell: New file.
1237         * m4/ftell.m4: New file.
1238         * doc/functions/ftell.texi: Update.
1239         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
1240         REPLACE_FTELL.
1241         * lib/stdio_.h (rpl_ftell): New declaration.
1242         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
1243         REPLACE_FTELL.
1244
1245 2007-05-28  Eric Blake  <ebb9@byu.net>
1246
1247         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
1248
1249 2007-05-28  Bruno Haible  <bruno@clisp.org>
1250
1251         * modules/fseek-tests: New file.
1252         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
1253         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
1254
1255         * lib/fseek.c: New file.
1256         * modules/fseek: New file.
1257         * m4/fseek.m4: New file.
1258         * doc/functions/fseek.texi: Update.
1259         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
1260         REPLACE_FSEEK.
1261         * lib/stdio_.h (rpl_fseek): New declaration.
1262         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
1263         REPLACE_FSEEK.
1264
1265 2007-05-28  Bruno Haible  <bruno@clisp.org>
1266
1267         * lib/stdio_.h (fflush): More comments.
1268
1269 2007-05-28  Bruno Haible  <bruno@clisp.org>
1270
1271         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
1272         runtime test.
1273
1274 2007-05-28  Eric Blake  <ebb9@byu.net>
1275
1276         Improve lseek module.
1277         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
1278         * lib/unistd_.h (lseek): Scale back link warning message.
1279         * tests/test-lseek.c: Beef up test.
1280         * tests/test-lseek.sh: Exercise more facets of lseek.
1281         Reported by Bruno Haible.
1282
1283 2007-05-28  Bruno Haible  <bruno@clisp.org>
1284
1285         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
1286         to define.
1287
1288 2007-05-27  Bruno Haible  <bruno@clisp.org>
1289
1290         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
1291
1292 2007-05-27  Bruno Haible  <bruno@clisp.org>
1293
1294         * modules/openmp: New file.
1295         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
1296         Noah Misch.
1297
1298 2007-05-26  Bruno Haible  <bruno@clisp.org>
1299
1300         * modules/chdir-long (Depends-on): Add fchdir.
1301         * modules/chdir-safer (Depends-on): Likewise.
1302         * modules/fts (Depends-on): Likewise.
1303         * modules/fts-lgpl (Depends-on): Likewise.
1304         * modules/openat (Depends-on): Likewise.
1305         * modules/savewd (Depends-on): Likewise.
1306
1307 2007-05-24  Eric Blake  <ebb9@byu.net>
1308
1309         Fix lseek on mingw.
1310         * modules/lseek: New module.
1311         * m4/lseek.m4: New file.
1312         * lib/lseek.c: New file.
1313         * modules/lseek-tests: New file.
1314         * tests/test-lseek.c: New file.
1315         * tests/test-lseek.sh: New file.
1316         * MODULES.html.sh: Document lseek module.
1317         * modules/fflush (Depends-on): Add lseek, fseeko.
1318         * modules/fseeko (Depends-on): Likewise.
1319         * modules/ftello (Depends-on): Likewise.
1320         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
1321         broken.
1322         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
1323         broken.
1324         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
1325         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
1326         * lib/ftello.c (rpl_ftello): Likewise.
1327         * tests/test-fseeko.c (main): Test this.
1328         * tests/test-fseeko.sh: Likewise.
1329         * tests/test-ftello.c (main): Likewise.
1330         * tests/test-ftello.sh: Likewise.
1331         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
1332         implies replacing fseek.
1333         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
1334         HAVE_FTELLO.
1335         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
1336         * modules/unistd (Makefile.am): Likewise.
1337         * lib/unistd_.h (lseek): Declare a replacement.
1338         * doc/functions/lseek.texi (lseek): Document this fix.
1339         * doc/functions/fseek.texi (fseek): Likewise.
1340         * doc/functions/ftell.texi (ftell): Likewise.
1341
1342 2007-05-24  Bruno Haible  <bruno@clisp.org>
1343
1344         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
1345         in the printed representation of a NaN.
1346         * tests/test-vasprintf-posix.c (test_function): Likewise.
1347         * tests/test-snprintf-posix.h (test_function): Likewise.
1348         * tests/test-sprintf-posix.h (test_function): Likewise.
1349         Reported by Eric Blake.
1350
1351 2007-05-23  Eric Blake  <ebb9@byu.net>
1352
1353         Fix fseeko/ftello on cygwin 1.5.24.
1354         * doc/functions/fseeko.texi (fseeko): Document the fix.
1355         * doc/functions/ftello.texi (ftello): Document the fix.
1356         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
1357         * doc/functions/stdout.text (stdout): New file.
1358         * doc/functions/stderr.text (stderr): New file.
1359         * doc/gnulib.texi (Function Substitutes): Use new files.
1360         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
1361         prior to 1.7.0.
1362         * tests/test-ftello.c (main): Likewise for ftello.
1363         * tests/test-fseeko.sh: New file.
1364         * tests/test-ftello.sh: New file.
1365         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
1366         with seekable stdin.
1367         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
1368         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
1369         (gl_REPLACE_FSEEKO): New macro.
1370         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
1371         * modules/fseeko (Files): Distribute fseeko.c.
1372         * modules/ftello (Files): Distribute ftello.c.
1373         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
1374         mode.
1375         * lib/ftello.c (rpl_ftello): New file.
1376         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
1377         fseeko, ftello.
1378         (gl_STDIN_LARGE_OFFSET): New macro.
1379         * modules/stdio (Makefile.am): Perform the replacement.
1380         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
1381
1382 2007-05-23  Bruno Haible  <bruno@clisp.org>
1383
1384         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
1385         GNULIB_POSIXCHECK is defined.
1386
1387 2007-05-21  Bruno Haible  <bruno@clisp.org>
1388
1389         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
1390         Check also the output for NaN arguments. When cross-compiling, guess
1391         no on IRIX.
1392         * lib/vasnprintf.c: Update comments.
1393         * tests/test-vasnprintf-posix.c (strisnan): New function.
1394         (test_function): Use it.
1395         * tests/test-vasprintf-posix.c (strisnan): New function.
1396         (test_function): Use it.
1397         * tests/test-snprintf-posix.h (strisnan): New function.
1398         (test_function): Use it.
1399         * tests/test-sprintf-posix.h (strisnan): New function.
1400         (test_function): Use it.
1401         Reported by Eric Blake.
1402
1403 2007-05-20  Bruno Haible  <bruno@clisp.org>
1404
1405         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
1406         numbers that fails on BeOS.
1407         * doc/functions/frexpl.texi: Update.
1408
1409 2007-05-20  Jim Meyering  <jim@meyering.net>
1410
1411         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
1412         forced upon us by glibc-2.6.
1413
1414 2007-05-20  Bruno Haible  <bruno@clisp.org>
1415
1416         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
1417         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
1418         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
1419         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
1420         NEED_PRINTF_INFINITE.
1421         (is_infinitel): New function.
1422         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
1423         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
1424         gl_PREREQ_VASNPRINTF_INFINITE.
1425         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
1426         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1427         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
1428         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
1429         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
1430         gl_PREREQ_VASNPRINTF_INFINITE.
1431         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1432         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1433         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1434         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1435         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1436         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1437         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1438         * doc/functions/fprintf.texi: Update.
1439         * doc/functions/printf.texi: Update.
1440         * doc/functions/snprintf.texi: Update.
1441         * doc/functions/sprintf.texi: Update.
1442         * doc/functions/vfprintf.texi: Update.
1443         * doc/functions/vprintf.texi: Update.
1444         * doc/functions/vsnprintf.texi: Update.
1445         * doc/functions/vsprintf.texi: Update.
1446
1447 2007-05-20  Bruno Haible  <bruno@clisp.org>
1448
1449         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
1450         was not found in libc.
1451         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
1452
1453 2007-05-20  Bruno Haible  <bruno@clisp.org>
1454
1455         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1456         printed as "-nan" instead of "nan".
1457         * tests/test-vasprintf-posix.c (test_function): Likewise.
1458         * tests/test-snprintf-posix.h (test_function): Likewise.
1459         * tests/test-sprintf-posix.h (test_function): Likewise.
1460         Needed for HP-UX 11.
1461
1462 2007-05-20  Jim Meyering  <jim@meyering.net>
1463
1464         Fix buggy test for the fchownat-deref bug.
1465         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
1466         symlink required for the run-test.  Without it, this test would
1467         always declare that fchownat doesn't work, and client code would
1468         unnecessarily use the replacement function with fixed libc.
1469         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
1470         Reported by Greg Schafer.
1471
1472 2007-05-19  Bruno Haible  <bruno@clisp.org>
1473
1474         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
1475         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
1476         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
1477         Needed for IRIX 6.5 and Solaris 2.5.1.
1478
1479 2007-05-19  Bruno Haible  <bruno@clisp.org>
1480
1481         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
1482         (test_function): Skip tests involving -0.0 on platforms where
1483         -0.0 = 0.0.
1484         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
1485         (test_function): Skip tests involving -0.0 on platforms where
1486         -0.0 = 0.0.
1487         * tests/test-snprintf-posix.h (have_minus_zero): New function.
1488         (test_function): Skip tests involving -0.0 on platforms where
1489         -0.0 = 0.0.
1490         * tests/test-sprintf-posix.h (have_minus_zero): New function.
1491         (test_function): Skip tests involving -0.0 on platforms where
1492         -0.0 = 0.0.
1493         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
1494         tests.
1495         * tests/test-printf-posix.h (test_function): Likewise.
1496         * tests/test-printf-posix.output: Remove all -0.0 related results.
1497         Needed for IRIX 6.5.
1498
1499 2007-05-19  Bruno Haible  <bruno@clisp.org>
1500
1501         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1502         printed as "nan0x7fffffff" instead of "nan".
1503         * tests/test-vasprintf-posix.c (test_function): Likewise.
1504         * tests/test-snprintf-posix.h (test_function): Likewise.
1505         * tests/test-sprintf-posix.h (test_function): Likewise.
1506         * tests/test-fprintf-posix.h (NaN): Remove macro.
1507         (test_function): Remove all NaN related tests.
1508         * tests/test-printf-posix.h (NaN): Remove macro.
1509         (test_function): Remove all NaN related tests.
1510         * tests/test-printf-posix.output: Remove all NaN related results.
1511         Needed for IRIX 6.5.
1512
1513 2007-05-19  Bruno Haible  <bruno@clisp.org>
1514
1515         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
1516         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
1517
1518 2007-05-19  Bruno Haible  <bruno@clisp.org>
1519
1520         * lib/float_.h: New file.
1521         * m4/float_h.m4: New file.
1522         * modules/float: New file.
1523         * modules/isnanl (Dependencies): Add float.
1524         * modules/isnanl-nolibm (Dependencies): Likewise.
1525         * modules/mathl (Dependencies): Likewise.
1526         * modules/printf-frexpl (Dependencies): Likewise.
1527         * modules/signbit (Dependencies): Likewise.
1528         * modules/vasnprintf (Dependencies): Likewise.
1529         * doc/headers/float.texi: Update.
1530
1531 2007-05-19  Jim Meyering  <jim@meyering.net>
1532
1533         * lib/utimens.c (gl_futimens): Rename from futimens,
1534         now that glibc-2.6 declares futimens.
1535         * lib/utimens.h: Likewise.
1536
1537 2007-05-19  Bruno Haible  <bruno@clisp.org>
1538
1539         Avoid test failures on mingw.
1540         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
1541         * tests/test-printf-posix.sh: Likewise.
1542         * tests/test-vfprintf-posix.sh: Likewise.
1543         * tests/test-vprintf-posix.sh: Likewise.
1544
1545 2007-05-19  Bruno Haible  <bruno@clisp.org>
1546
1547         Fix *printf result for NaN, Inf, -0.0 on mingw.
1548         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
1549         * lib/vasnprintf.c: Include math.h and isnan.h.
1550         (is_infinite_or_zero): New function.
1551         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
1552         values in the %f, %F, %e, %E, %g, %G directives.
1553         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
1554         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1555         gl_PRINTF_INFINITE and test its result. Invoke
1556         gl_PREREQ_VASNPRINTF_INFINITE.
1557         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1558         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1559         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1560         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1561         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1562         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1563         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1564         * doc/functions/fprintf.texi: Update.
1565         * doc/functions/printf.texi: Update.
1566         * doc/functions/snprintf.texi: Update.
1567         * doc/functions/sprintf.texi: Update.
1568         * doc/functions/vfprintf.texi: Update.
1569         * doc/functions/vprintf.texi: Update.
1570         * doc/functions/vsnprintf.texi: Update.
1571         * doc/functions/vsprintf.texi: Update.
1572
1573 2007-05-19  Bruno Haible  <bruno@clisp.org>
1574
1575         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
1576         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
1577         Instead of multiplying with 10^k, set extra_zeroes to k.
1578         (scale10_round_long_double): Remove function.
1579
1580 2007-05-18  Bruno Haible  <bruno@clisp.org>
1581
1582         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
1583         introduced on 2007-05-06.
1584
1585 2007-05-18  Bruno Haible  <bruno@clisp.org>
1586
1587         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
1588         %g directives.
1589         * tests/test-vasprintf-posix.c (test_function): Likewise.
1590         * tests/test-snprintf-posix.h (test_function): Likewise.
1591         * tests/test-sprintf-posix.h (test_function): Likewise.
1592
1593 2007-05-18  Bruno Haible  <bruno@clisp.org>
1594
1595         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
1596         (strmatch): New function.
1597         (test_function): Test the %f directive on numbers of various exponents.
1598         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
1599         (strmatch): New function.
1600         (test_function): Test the %f directive on numbers of various exponents.
1601         * tests/test-snprintf-posix.h (strmatch): New function.
1602         (test_function): Test the %f directive on numbers of various exponents.
1603         * tests/test-sprintf-posix.h (strmatch): New function.
1604         (test_function): Test the %f directive on numbers of various exponents.
1605         * tests/test-snprintf-posix.c (SIZEOF): New macro.
1606         * tests/test-sprintf-posix.c (SIZEOF): New macro.
1607         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
1608         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
1609
1610 2007-05-18  Bruno Haible  <bruno@clisp.org>
1611
1612         Add support for 'long double' number output.
1613         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
1614         * lib/vasnprintf.c: Include math.h and float+.h.
1615         (mp_limb_t): New type.
1616         (GMP_LIMB_BITS): New macro.
1617         (mp_twolimb_t): New type.
1618         (GMP_TWOLIMB_BITS): New macro.
1619         (mpn_t): New type.
1620         (multiply, divide, convert_to_decimal, decode_long_double,
1621         scale10_round_long_double, scale10_round_decimal_long_double,
1622         floorlog10l): New functions.
1623         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
1624         for the %f, %F, %e, %E, %g, %G directives.
1625         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
1626         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1627         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
1628         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
1629         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1630         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1631         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1632         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1633         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1634         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1635         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1636         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
1637         * modules/snprintf-posix (Depends-on): Likewise.
1638         * modules/sprintf-posix (Depends-on): Likewise.
1639         * modules/vasnprintf-posix (Depends-on): Likewise.
1640         * modules/vasprintf-posix (Depends-on): Likewise.
1641         * modules/vfprintf-posix (Depends-on): Likewise.
1642         * modules/vsnprintf-posix (Depends-on): Likewise.
1643         * modules/vsprintf-posix (Depends-on): Likewise.
1644         * modules/vasnprintf (Files): Add lib/float+.h.
1645         * doc/functions/fprintf.texi: Update.
1646         * doc/functions/printf.texi: Update.
1647         * doc/functions/snprintf.texi: Update.
1648         * doc/functions/sprintf.texi: Update.
1649         * doc/functions/vfprintf.texi: Update.
1650         * doc/functions/vprintf.texi: Update.
1651         * doc/functions/vsnprintf.texi: Update.
1652         * doc/functions/vsprintf.texi: Update.
1653
1654 2007-05-18  Bruno Haible  <bruno@clisp.org>
1655
1656         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
1657
1658 2007-05-18  Bruno Haible  <bruno@clisp.org>
1659
1660         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
1661         for printing 64-bit integers. Needed for mingw.
1662
1663 2007-05-18  Bruno Haible  <bruno@clisp.org>
1664
1665         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
1666         gl_FUNC_FREXPL_WORKS.
1667         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
1668
1669 2007-05-18  Bruno Haible  <bruno@clisp.org>
1670
1671         * modules/frexpl-nolibm-tests: New file.
1672
1673         * modules/frexpl-nolibm: New file.
1674         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
1675
1676 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
1677
1678         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
1679         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
1680         GCC 4.2, which otherwise issues a lot of warnings.
1681         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
1682         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
1683         Likewise.
1684         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
1685         * modules/iconv_open (iconv.h): Likewise.
1686         * modules/locale (locale.h): Likewise.
1687         * modules/netinet_in (netinet/in.h): Likewise.
1688         * modules/sys_select (sys_select.h): Likewise.
1689         * modules/sys_socket (sys/socket.h): Likewise.
1690         * modules/sys_stat (sys/stat.h): Likewise.
1691         * modules/sysexits (sysexits.h): Likewise.
1692         * modules/unistd (unistd.h): Likewise.
1693
1694 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1695
1696         * modules/closein-tests (Makefile.am): Distribute
1697         `test-closein.sh'.
1698
1699 2007-05-17  Bruno Haible  <bruno@clisp.org>
1700
1701         * tests/test-printf-posix.output: Renamed from
1702         tests/test-fprintf-posix.out.
1703         * modules/fprintf-posix-tests: Update.
1704         * modules/printf-posix-tests: Update.
1705         * modules/vfprintf-posix-tests: Update.
1706         * modules/vprintf-posix-tests: Update.
1707         * tests/test-fprintf-posix.sh: Update.
1708         * tests/test-printf-posix.sh: Update.
1709         * tests/test-vfprintf-posix.sh: Update.
1710         * tests/test-vprintf-posix.sh: Update.
1711         Reported by Ralf Wildenhues.
1712
1713 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
1714
1715         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
1716         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
1717         GCC 4.2, which otherwise issues a lot of warnings.
1718         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
1719         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
1720         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
1721         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
1722         it should no longer be needed.
1723         * lib/string_.h: Likewise.
1724         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
1725         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
1726         * modules/inttypes (inttypes.h): Likewise.
1727         * modules/math (math.h): Likewise.
1728         * modules/search (search.h): Likewise.
1729         * modules/signal (signal.h): Likewise.
1730         * modules/stdint (stdint.h): Likewise.
1731         * modules/stdio (stdio.h): Likewise.
1732         * modules/stdlib (stdlib.h): Likewise.
1733         * modules/string (string.h): Likewise.
1734         * modules/sys_time (sys/time.h): Likewise.
1735         * modules/time (time.h): Likewise.
1736         * modules/wchar (wchar.h): Likewise.
1737         * modules/wctype (wtype.h): Likewise.
1738
1739 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
1740
1741         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
1742
1743 2007-05-13  Bruno Haible  <bruno@clisp.org>
1744
1745         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
1746         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
1747         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
1748         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
1749         (gl_PREREQ_STRTOK_R): Don't require it here.
1750
1751 2007-05-13  Bruno Haible  <bruno@clisp.org>
1752
1753         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
1754         when used in C++ mode.
1755
1756 2007-05-12  Bruno Haible  <bruno@clisp.org>
1757
1758         * lib/linebuffer.h: Tweak doc.
1759         * lib/linebuffer.c: Likewise.
1760
1761 2007-05-12  James Youngman  <jay@gnu.org>
1762
1763         * lib/linebuffer.c (readlinebuffer_delim): New function,
1764         like readlinebuffer, but use a caller-specified delimiter.
1765         (readlinebuffer): Just call readlinebuffer_delim with '\n'
1766         as the delimiter.
1767         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
1768
1769 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
1770
1771         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
1772         * modules/openat (Files): Remove openat-die.c.
1773         (Depends-on): Add openat-die.
1774         * modules/openat-die: New module.
1775
1776 2007-05-06  Bruno Haible  <bruno@clisp.org>
1777
1778         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
1779         Update with info about Cygwin.
1780         * doc/functions/fprintf.texi: Update.
1781         * doc/functions/printf.texi: Update.
1782         * doc/functions/snprintf.texi: Update.
1783         * doc/functions/sprintf.texi: Update.
1784         * doc/functions/vfprintf.texi: Update.
1785         * doc/functions/vprintf.texi: Update.
1786         * doc/functions/vsnprintf.texi: Update.
1787         * doc/functions/vsprintf.texi: Update.
1788         Reported by Eric Blake.
1789
1790 2007-05-06  Bruno Haible  <bruno@clisp.org>
1791
1792         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
1793         padding ourselves for the floating-point directives.
1794         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
1795         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
1796         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
1797         gl_PRINTF_FLAG_ZERO and test its result. Invoke
1798         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
1799         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1800         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
1801         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1802         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1803         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1804         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1805         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1806         * tests/test-snprintf-posix.h (test_function): Also check the width
1807         and some flags in the %f directive.
1808         * tests/test-sprintf-posix.h (test_function): Likewise.
1809         * tests/test-vasnprintf-posix.c (test_function): Likewise.
1810         * tests/test-vasprintf-posix.c (test_function): Likewise.
1811         * doc/functions/fprintf.texi: Update.
1812         * doc/functions/printf.texi: Update.
1813         * doc/functions/snprintf.texi: Update.
1814         * doc/functions/sprintf.texi: Update.
1815         * doc/functions/vfprintf.texi: Update.
1816         * doc/functions/vprintf.texi: Update.
1817         * doc/functions/vsnprintf.texi: Update.
1818         * doc/functions/vsprintf.texi: Update.
1819
1820 2007-05-06  Bruno Haible  <bruno@clisp.org>
1821
1822         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
1823         pass the ' flag character to sprintf or snprintf.
1824         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
1825         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
1826         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
1827         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
1828         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
1829         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1830         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
1831         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1832         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1833         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1834         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1835         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1836         * tests/test-snprintf-posix.h (test_function): Also check the grouping
1837         flag.
1838         * tests/test-sprintf-posix.h (test_function): Likewise.
1839         * tests/test-vasnprintf-posix.c (test_function): Likewise.
1840         * tests/test-vasprintf-posix.c (test_function): Likewise.
1841         * doc/functions/fprintf.texi: Update.
1842         * doc/functions/printf.texi: Update.
1843         * doc/functions/snprintf.texi: Update.
1844         * doc/functions/sprintf.texi: Update.
1845         * doc/functions/vfprintf.texi: Update.
1846         * doc/functions/vprintf.texi: Update.
1847         * doc/functions/vsnprintf.texi: Update.
1848         * doc/functions/vsprintf.texi: Update.
1849
1850 2007-05-01  Bruno Haible  <bruno@clisp.org>
1851
1852         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
1853
1854 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
1855
1856         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
1857         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
1858
1859 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
1860
1861         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
1862         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
1863         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
1864
1865 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
1866
1867         * lib/argp-help.c (struct hol_entry): New member `ord'.
1868         (HOL_ENTRY_PTRCMP): Use ord for comparison
1869         (hol_sort): Initialize ord.
1870
1871 2007-05-01  Bruno Haible  <bruno@clisp.org>
1872
1873         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
1874         Reported by Eric Blake.
1875         * doc/gnulib.texi (Function Substitutes): Update.
1876
1877 2007-05-01  Bruno Haible  <bruno@clisp.org>
1878
1879         * doc/functions.texi: Remove file, now redundant through
1880         doc/functions/*.texi.
1881
1882 2007-05-01  Bruno Haible  <bruno@clisp.org>
1883
1884         * modules/argp (Depends-on): Add sleep.
1885
1886 2007-05-01  Bruno Haible  <bruno@clisp.org>
1887
1888         * modules/sleep-tests: New file.
1889         * tests/test-sleep.c: New file.
1890
1891         * modules/sleep: New file.
1892         * lib/sleep.c: New file.
1893         * m4/sleep.m4: New file.
1894         * lib/unistd_.h (sleep): New declaration.
1895         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
1896         HAVE_SLEEP.
1897         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
1898         * doc/functions/sleep.texi: Document the sleep module.
1899
1900 2007-05-01  Bruno Haible  <bruno@clisp.org>
1901
1902         * lib/sigprocmask.h: Remove file.
1903         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
1904         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
1905         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
1906         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
1907         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
1908         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
1909         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
1910         HAVE_SIGSET_T as a shell variable.
1911         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
1912         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
1913         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
1914         (Depends-on): Add signal. Remove verify.
1915         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
1916         (Include): Mention <signal.h> instead of sigprocmask.h.
1917         * NEWS: Mention the change.
1918         * lib/fatal-signal.c: Don't include sigprocmask.h.
1919
1920 2007-05-01  Bruno Haible  <bruno@clisp.org>
1921
1922         * modules/signal: New file.
1923         * lib/signal_.h: New file.
1924         * m4/signal_h.m4: New file.
1925
1926 2007-05-01  Bruno Haible  <bruno@clisp.org>
1927
1928         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
1929         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
1930         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
1931         HAVE_WCTYPE_CTMP_BUG into wctype.h.
1932
1933 2007-05-01  Bruno Haible  <bruno@clisp.org>
1934
1935         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
1936         configure time.
1937         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
1938         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
1939         * modules/sys_stat (Makefile.am): Substitute their values into
1940         sys/stat.h.
1941
1942 2007-05-01  Bruno Haible  <bruno@clisp.org>
1943
1944         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
1945         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
1946         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
1947
1948 2007-05-01  Bruno Haible  <bruno@clisp.org>
1949
1950         * doc/header/assert.texi: Undo last change: don't mention the gnulib
1951         'assert' module here.
1952
1953 2007-05-01  Bruno Haible  <bruno@clisp.org>
1954
1955         * doc/functions/*.texi: New files.
1956         * doc/functions/google-ranking.txt: New file.
1957         * doc/gnulib.texi (Function Substitutes): New chapter.
1958         (ctime, inet_ntoa): Remove sections.
1959         * doc/ctime.texi: Remove file.
1960         * doc/inet_ntoa.texi: Remove file.
1961         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
1962         dependencies.
1963         (%.info): New rule, specifying a --reference-limit.
1964
1965 2007-05-01  Bruno Haible  <bruno@clisp.org>
1966
1967         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
1968
1969 2007-05-01  Bruno Haible  <bruno@clisp.org>
1970
1971         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
1972         the portability of 'mkdir' to mingw systems.
1973
1974 2007-05-01  Bruno Haible  <bruno@clisp.org>
1975
1976         * doc/headers/google-ranking.txt: New file.
1977
1978 2007-04-30  Eric Blake  <ebb9@byu.net>
1979
1980         Prefer fseeko to fseek.
1981         * modules/getpass (Depends-on): Add fseeko.
1982         * lib/getpass.c (getpass): Use fseeko, not fseek.
1983
1984 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
1985
1986         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
1987         assumes the sorting is stable, while most qsort implementations
1988         are not.  Use argument addresses to ensure they never compare as
1989         equal.
1990
1991         * tests/test-argp-2.sh (usage-indent test): Fix output
1992         (func_compare): Restore diff options
1993         * tests/test-argp.c: Restore #include "progname.h"
1994
1995 2007-04-29  Bruno Haible  <bruno@clisp.org>
1996
1997         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
1998         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
1999         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
2000         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2001         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
2002         (configure.ac): Define CHECK_SNPRINTF_POSIX.
2003         (TESTS, check_PROGRAMS): Add test-snprintf.
2004         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
2005         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
2006         (TESTS, check_PROGRAMS): Add test-vsnprintf.
2007         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
2008         assertions that fail on HP-UX, OSF/1, or IRIX.
2009         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
2010
2011 2007-04-29  Bruno Haible  <bruno@clisp.org>
2012
2013         * MODULES.html.sh (posix_functions): Remove 'contents'.
2014
2015 2007-04-29  Karl Berry  <karl@gnu.org>
2016
2017         * config/srclist.txt (gendocs_template_min): new entry.
2018
2019 2007-04-29  Bruno Haible  <bruno@clisp.org>
2020
2021         Work around fpurge bug on BSD systems.
2022         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
2023         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
2024         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
2025         fpurge to rpl_fpurge if the system already has this function.
2026         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
2027         the case where the system already has this function. Correct invariants
2028         on BSD systems.
2029         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
2030         BSD systems.
2031
2032 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
2033
2034         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
2035         proposed by Sven Verdoolaege.
2036
2037         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
2038         options.
2039         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
2040         (usage and help tests): Update
2041
2042 2007-04-29  Bruno Haible  <bruno@clisp.org>
2043
2044         * tests/test-fflush.c (main): Use a file of size 17, not 10.
2045         Print more information in case of failure. Disable a test on BeOS.
2046
2047 2007-04-29  Bruno Haible  <bruno@clisp.org>
2048
2049         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
2050         This helps debugging on systems on which no gdb is available.
2051
2052 2007-04-29  Bruno Haible  <bruno@clisp.org>
2053
2054         * lib/freading.h: Improve comments.
2055         * lib/fwriting.h: Likewise.
2056         * tests/test-freading.c (main): Don't check freading immediately after
2057         repositioning. Needed for glibc.
2058
2059 2007-04-29  Bruno Haible  <bruno@clisp.org>
2060
2061         * lib/freading.c (freading): Trivial simplification.
2062
2063 2007-04-28  Bruno Haible  <bruno@clisp.org>
2064
2065         * tests/test-fwriting.c (main): Also test the interaction between
2066         fflush and fwriting.
2067         * modules/fwriting-tests (Depends-on): Add fflush.
2068
2069         * tests/test-freading.c (main): Also test the interaction between
2070         fflush and freading.
2071         * modules/freading-tests (Depends-on): Add fflush.
2072
2073 2007-04-28  Bruno Haible  <bruno@clisp.org>
2074
2075         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
2076         fseeko and ftello.
2077         Suggested by Eric Blake.
2078
2079 2007-04-28  Jim Meyering  <jim@meyering.net>
2080
2081         Avoid false-negative in gl_STDINT_H's C99 conformance test.
2082         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
2083         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
2084
2085 2007-04-27  Eric Blake  <ebb9@byu.net>
2086
2087         * doc/headers/assert.texi (assert.h): Document assert module use.
2088
2089 2007-04-27  Bruno Haible  <bruno@clisp.org>
2090
2091         * doc/headers/*.texi: New files.
2092         * doc/gnulib.texi (Header File Substitutes): New chapter.
2093         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
2094         dependencies.
2095         (standards.info ,standards.html, standards.dvi): Update dependencies.
2096         (mostlyclean, clean): New targets.
2097
2098 2007-04-27  Bruno Haible  <bruno@clisp.org>
2099
2100         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
2101         * modules/sysexits (Files, Makefile.am): Update.
2102
2103         * lib/sys_socket_.h: Renamed from lib/socket_.h.
2104         * modules/sys_socket (Files, Makefile.am): Update.
2105
2106         * lib/sys_stat_.h: Renamed from lib/stat_.h.
2107         * modules/sys_stat (Files, Makefile.am): Update.
2108
2109 2007-04-27  Eric Blake  <ebb9@byu.net>
2110
2111         * lib/freading.h: Improve comments.
2112         * lib/fwriting.h: Likewise.
2113         * lib/fflush.c: Likewise.
2114
2115         Fix closein for mingw.
2116         * modules/closein-tests: Add tests for closein.
2117         * tests/test-closein.c: New file.
2118         * tests/test-closein.sh: Likewise.
2119         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
2120         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
2121
2122 2007-04-27  Bruno Haible  <bruno@clisp.org>
2123
2124         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
2125         version is < 6.
2126         * lib/math_.h [__DECC]: Likewise.
2127         * lib/stdio_.h [__DECC]: Likewise.
2128         * lib/stdlib_.h [__DECC]: Likewise.
2129         * lib/string_.h [__DECC]: Likewise.
2130         * lib/time_.h [__DECC]: Likewise.
2131         * lib/wchar_.h [__DECC]: Likewise.
2132         * lib/wctype_.h [__DECC]: Likewise.
2133
2134 2007-04-27  Bruno Haible  <bruno@clisp.org>
2135
2136         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
2137
2138 2007-04-27  Bruno Haible  <bruno@clisp.org>
2139
2140         * lib/fflush.c: Add comments.
2141         * modules/fpurge-tests (Depends-on): Add fflush.
2142         * modules/freadable-tests (Depends-on): Likewise.
2143         * modules/fwritable-tests (Depends-on): Likewise.
2144
2145 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
2146
2147         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
2148         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
2149         Report by Bruno Haible <bruno@clisp.org>.
2150
2151 2007-04-26  Eric Blake  <ebb9@byu.net>
2152
2153         Fix fflush on mingw.
2154         * modules/fflush (Depends-on): Add freading.
2155         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
2156         but unread data.
2157
2158 2007-04-26  Eric Blake  <ebb9@byu.net>
2159         and Bruno Haible  <bruno@clisp.org>
2160
2161         Implement freading and fwriting.
2162         * lib/freading.c: New file.
2163         * lib/freading.h: Likewise.
2164         * m4/freading.m4: Likewise.
2165         * modules/freading: Likewise.
2166         * modules/freading-tests: Likewise.
2167         * tests/test-freading.c: Likewise.
2168         * lib/fwriting.c: New file.
2169         * lib/fwriting.h: Likewise.
2170         * m4/fwriting.m4: Likewise.
2171         * modules/fwriting: Likewise.
2172         * modules/fwriting-tests: Likewise.
2173         * tests/test-fwriting.c: Likewise.
2174         * MODULES.html.sh (File stream based Input/Output): Mention them.
2175
2176 2007-04-26  Bruno Haible  <bruno@clisp.org>
2177
2178         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
2179         'long' when we assume it.
2180         Suggested by Eric Blake.
2181
2182 2007-04-26  Bruno Haible  <bruno@clisp.org>
2183
2184         Ensure fseeko, ftello are declared on glibc systems.
2185         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
2186         * modules/fseeko (configure.ac-early): Likewise.
2187         * modules/ftello (configure.ac-early): Likewise.
2188         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
2189         AC_FUNC_FSEEKO for this.
2190         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
2191         (gl_CHECK_FSEEKO): Remove macro.
2192
2193 2007-04-26  Bruno Haible  <bruno@clisp.org>
2194
2195         * tests/test-fflush.c (main): Also check the ftell result after
2196         fflush and fseek/fseeko.
2197         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
2198         file descriptor position cache in the stream.
2199         * lib/fseeko.c (rpl_fseeko): Likewise.
2200
2201 2007-04-26  Bruno Haible  <bruno@clisp.org>
2202
2203         * modules/fflush-tests (Depends-on): Add fseeko.
2204
2205 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
2206             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2207
2208         * lib/argz_.h: ensure error_t definition is obtained in same
2209         mechanism system argz.h would have.
2210         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
2211         argz facilities are known bad.  Err on the side of caution if
2212         cross-compiling.
2213
2214 2007-04-25  Eric Blake  <ebb9@byu.net>
2215
2216         * lib/fpurge.c (includes): Use stdlib.h for free.
2217         * tests/test-fflush.c (main): Also test fflush-fseeko.
2218
2219 2007-04-25  Bruno Haible  <bruno@clisp.org>
2220
2221         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
2222         * lib/fseeko.c: New file.
2223         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
2224         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
2225         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
2226         gl_FUNC_FSEEKO.
2227         (gl_FUNC_FSEEKO): Invoke it.
2228         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
2229         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
2230         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
2231
2232 2007-04-25  Bruno Haible  <bruno@clisp.org>
2233
2234         * modules/fflush (Depends-on): Add ftello.
2235
2236 2007-04-25  Bruno Haible  <bruno@clisp.org>
2237
2238         * modules/ftello-tests: New file.
2239         * tests/test-ftello.c: New file.
2240
2241         * modules/ftello: New file.
2242         * m4/ftello.m4: New file.
2243         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
2244         HAVE_FTELLO.
2245         * lib/stdio_.h (ftello): New declaration.
2246         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
2247         HAVE_FTELLO.
2248
2249 2007-04-25  Bruno Haible  <bruno@clisp.org>
2250
2251         * modules/fseeko-tests: New file.
2252         * tests/test-fseeko.c: New file.
2253
2254         * modules/fseeko: New file.
2255         * m4/fseeko.m4: New file.
2256         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
2257         HAVE_FSEEKO.
2258         * lib/stdio_.h (fseeko): New declaration.
2259         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
2260         HAVE_FSEEKO.
2261
2262 2007-04-25  Bruno Haible  <bruno@clisp.org>
2263
2264         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
2265
2266 2007-04-25  Bruno Haible  <bruno@clisp.org>
2267
2268         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
2269         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
2270         * tests/test-unistd.c: Likewise.
2271         * tests/test-fcntl.c: Likewise.
2272
2273 2007-04-23  Eric Blake  <ebb9@byu.net>
2274
2275         * lib/fflush.c: Fix missing include.
2276         Reported by Bruno Haible.
2277
2278 2007-04-23  Bruno Haible  <bruno@clisp.org>
2279
2280         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
2281         Reported by Eric Blake.
2282
2283 2007-04-23  Bruno Haible  <bruno@clisp.org>
2284
2285         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
2286
2287 2007-04-23  Bruno Haible  <bruno@clisp.org>
2288
2289         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
2290
2291 2007-04-23  Bruno Haible  <bruno@clisp.org>
2292
2293         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
2294         Needed on HP-UX 11.
2295
2296 2007-04-16  Eric Blake  <ebb9@byu.net>
2297
2298         Make fflush rely on fpurge.
2299         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
2300         open coding all variants.
2301         * modules/fflush (Depends-on): Add fpurge and unistd.
2302         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
2303         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
2304
2305         Fix --with-tests compilation on cygwin.
2306         * modules/argmatch-tests (Makefile.am): List gnulib library first
2307         in LDADD.
2308         * modules/argp-tests (Makefile.am): Likewise.
2309         * modules/array-list-tests (Makefile.am): Likewise.
2310         * modules/array-oset-tests (Makefile.am): Likewise.
2311         * modules/avltree-list-tests (Makefile.am): Likewise.
2312         * modules/avltree-oset-tests (Makefile.am): Likewise.
2313         * modules/avltreehash-list-tests (Makefile.am): Likewise.
2314         * modules/carray-list-tests (Makefile.am): Likewise.
2315         * modules/dirname-tests (Makefile.am): Likewise.
2316         * modules/frexp-tests (Makefile.am): Likewise.
2317         * modules/isnanl-tests (Makefile.am): Likewise.
2318         * modules/linked-list-tests (Makefile.am): Likewise.
2319         * modules/linkedhash-list-tests (Makefile.am): Likewise.
2320         * modules/lock-tests (Makefile.am): Likewise.
2321         * modules/rbtree-list-tests (Makefile.am): Likewise.
2322         * modules/rbtree-oset-tests (Makefile.am): Likewise.
2323         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
2324         * modules/tls-tests (Makefile.am): Likewise.
2325         * modules/tsearch-tests (Makefile.am): Likewise.
2326         * modules/xvasprintf-tests (Makefile.am): Likewise.
2327
2328         Fix fpurge for cygwin.
2329         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
2330         value.
2331         * modules/fpurge-tests (Depends-on): Clean up trash.
2332
2333 2007-04-16  Simon Josefsson  <simon@josefsson.org>
2334
2335         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
2336
2337         * m4/autobuild.m4: Re-indent.
2338
2339 2007-04-13  Bruno Haible  <bruno@clisp.org>
2340
2341         * modules/fpurge-tests: New file.
2342         * tests/test-fpurge.c: New file.
2343
2344         * modules/fpurge: New file.
2345         * lib/fpurge.h: New file.
2346         * lib/fpurge.c: New file.
2347         * m4/fpurge.m4: New file.
2348
2349 2007-04-13  Bruno Haible  <bruno@clisp.org>
2350
2351         * modules/fbufmode-tests: New file.
2352         * tests/test-fbufmode.c: New file.
2353
2354         * modules/fbufmode: New file.
2355         * lib/fbufmode.h: New file.
2356         * lib/fbufmode.c: New file.
2357         * m4/fbufmode.m4: New file.
2358
2359 2007-04-13  Bruno Haible  <bruno@clisp.org>
2360
2361         * modules/fwritable-tests: New file.
2362         * tests/test-fwritable.c: New file.
2363
2364         * modules/fwritable: New file.
2365         * lib/fwritable.h: New file.
2366         * lib/fwritable.c: New file.
2367         * m4/fwritable.m4: New file.
2368
2369 2007-04-13  Bruno Haible  <bruno@clisp.org>
2370
2371         * modules/freadable-tests: New file.
2372         * tests/test-freadable.c: New file.
2373
2374         * modules/freadable: New file.
2375         * lib/freadable.h: New file.
2376         * lib/freadable.c: New file.
2377         * m4/freadable.m4: New file.
2378
2379 2007-04-13  Bruno Haible  <bruno@clisp.org>
2380
2381         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
2382         MOSTLYCLEANFILES.
2383
2384 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
2385
2386         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
2387         gzip bootstrap.conf to avoid dragging in i18n machinery.
2388         (gnulib_tool_option): Use it.
2389
2390 2007-04-13  Bruno Haible  <bruno@clisp.org>
2391
2392         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
2393         %F directives.
2394         * tests/test-vasprintf-posix.c (test_function): Likewise.
2395         * tests/test-snprintf-posix.h (test_function): Likewise.
2396         * tests/test-sprintf-posix.h (test_function): Likewise.
2397         * tests/test-fprintf-posix.h (test_function): Likewise.
2398         * tests/test-printf-posix.h (test_function): Likewise.
2399         * tests/test-fprintf-posix.out: Likewise.
2400
2401 2007-04-13  Bruno Haible  <bruno@clisp.org>
2402
2403         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
2404         * modules/tls-tests (configure.ac): Likewise.
2405         Reported by Arto C. Nirkko <anirkko@insel.ch>.
2406
2407 2007-04-13  Bruno Haible  <bruno@clisp.org>
2408
2409         * lib/tls.c (glthread_tls_get): Fix return type.
2410         Patch by Arto C. Nirkko <anirkko@insel.ch>.
2411
2412 2007-04-12  Eric Blake  <ebb9@byu.net>
2413
2414         * modules/gettime (Depends-on): Remove gettime.
2415         Reported by Dmitry V. Levin.
2416
2417 2007-04-12  Bruno Haible  <bruno@clisp.org>
2418
2419         * modules/fflush (Include): Mention <stdio.h>.
2420         * modules/strtoimax (Include): Mention <inttypes.h>.
2421         * modules/strtoumax (Include): Likewise.
2422
2423 2007-04-12  Eric Blake  <ebb9@byu.net>
2424
2425         * .cvsignore: New file.
2426         * .gitignore: Likewise.
2427
2428 2007-04-12  Bruno Haible  <bruno@clisp.org>
2429
2430         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
2431         not before, since $(LDADD) often contains libgnu.a.
2432         * modules/striconv-tests (test_striconv_LDADD): Likewise.
2433         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
2434         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
2435         Needed on Cygwin.
2436
2437 2007-04-12  Eric Blake  <ebb9@byu.net>
2438
2439         Work around glibc's failure to flush stdin on fclose.
2440         * lib/closein.c (close_stdin): Flush stdin before closing.
2441
2442         Work around glibc's failure to reset seekable stdin on exit.
2443         * modules/closein: New module.
2444         * lib/closein.c: New file.
2445         * lib/closein.h: Likewise.
2446         * m4/closein.m4: Likewise.
2447         * MODULES.html.sh (File stream based Input/Output): Document it.
2448
2449 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2450
2451         * gnulib-tool: Rename generated 'autobuild' script to
2452         'do-autobuild' in --create-megatestdir output.
2453
2454         * doc/gnulib.texi (Build robot for gnulib): Fix.
2455
2456 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2457
2458         * modules/sysexits (Depends-on): Add absolute-header.
2459
2460 2007-04-12  Eric Blake  <ebb9@byu.net>
2461
2462         No need to preserve errno on success.
2463         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
2464         Reported by Bruno Haible.
2465
2466 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2467
2468         * MODULES.html.sh (Support for maintaining and releasing
2469         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
2470
2471 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2472
2473         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
2474
2475 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2476
2477         * modules/autobuild: New module.
2478
2479         * m4/autobuild.m4: New file.
2480
2481 2007-04-11  Bruno Haible  <bruno@clisp.org>
2482
2483         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
2484         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
2485         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
2486         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
2487         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2488         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2489         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2490         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2491         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2492         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2493         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
2494         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2495         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2496         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
2497         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2498         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2499         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
2500         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2501         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2502         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
2503         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2504         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2505         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
2506         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2507         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2508         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
2509         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2510         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2511         Reported by Eric Blake.
2512
2513 2007-04-11  Bruno Haible  <bruno@clisp.org>
2514
2515         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
2516
2517 2007-04-10  Bruno Haible  <bruno@clisp.org>
2518
2519         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
2520         for NaN and Infinity. Needed on FreeBSD 6.1.
2521         * tests/test-vasnprintf-posix.c (test_function): Undo last change
2522         regarding results for "%010a" of Infinity and NaN.
2523         * tests/test-vasprintf-posix.c (test_function): Likewise.
2524         * tests/test-snprintf-posix.h (test_function): Likewise.
2525         * tests/test-sprintf-posix.h (test_function): Likewise.
2526         * tests/test-fprintf-posix.h (test_function): Likewise.
2527         * tests/test-printf-posix.h (test_function): Likewise.
2528         * tests/test-fprintf-posix.out: Likewise.
2529
2530 2007-04-10  Bruno Haible  <bruno@clisp.org>
2531
2532         * modules/locale-tests: New file.
2533         * tests/test-locale.c: New file.
2534
2535         * modules/locale: New file.
2536         * lib/locale_.h: New file.
2537         * m4/locale_h.m4: New file.
2538
2539 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
2540             Bruno Haible  <bruno@clisp.org>
2541
2542         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
2543         be determined, test for availability of the copysignf, copysign,
2544         copysignl functions.
2545         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
2546         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
2547         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
2548
2549 2007-04-09  Eric Blake  <ebb9@byu.net>
2550
2551         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
2552         * modules/stdio (Makefile.am): Support fflush.
2553         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
2554         * modules/fflush: New file.
2555         * lib/fflush.c: Likewise.
2556         * m4/fflush.m4: Likewise.
2557         * modules/fflush-tests: New test.
2558         * tests/test-fflush.c: Likewise.
2559         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
2560
2561 2007-04-06  Bruno Haible  <bruno@clisp.org>
2562
2563         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
2564         (VASNPRINTF): Use signbit for faster determination whether to print a
2565         minus sign.
2566         * modules/vasnprintf (Files): Remove lib/float+.h.
2567         * modules/fprintf-posix (Depends-on): Add signbit.
2568         * modules/snprintf-posix (Depends-on): Likewise.
2569         * modules/sprintf-posix (Depends-on): Likewise.
2570         * modules/vasnprintf-posix (Depends-on): Likewise.
2571         * modules/vasprintf-posix (Depends-on): Likewise.
2572         * modules/vfprintf-posix (Depends-on): Likewise.
2573         * modules/vsnprintf-posix (Depends-on): Likewise.
2574         * modules/vsprintf-posix (Depends-on): Likewise.
2575
2576 2007-04-06  Bruno Haible  <bruno@clisp.org>
2577
2578         * tests/test-frexp.c (main): Test also the sign bit of zero results.
2579         * tests/test-frexpl.c (main): Likewise.
2580         * tests/test-ldexpl.c (main): Likewise.
2581         * modules/frexp-tests (Depends-on): Add signbit.
2582         * modules/frexpl-tests (Depdends-on): Likewise.
2583         * modules/ldexpl-tests (Depdends-on): Likewise.
2584
2585 2007-04-06  Bruno Haible  <bruno@clisp.org>
2586
2587         * modules/signbit-tests: New file.
2588         * tests/test-signbit.c: New file.
2589
2590         * modules/signbit: New file.
2591         * lib/signbitf.c: New file.
2592         * lib/signbitd.c: New file.
2593         * lib/signbitl.c: New file.
2594         * m4/signbit.m4: New file.
2595         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
2596         (signbit): New macro.
2597         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
2598         REPLACE_SIGNBIT.
2599         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
2600         REPLACE_FREXPL into math.h.
2601
2602 2007-04-06  Bruno Haible  <bruno@clisp.org>
2603
2604         * modules/isnanf-nolibm-tests: New file.
2605         * tests/test-isnanf.c: New file.
2606
2607         * modules/isnanf-nolibm: New file.
2608         * lib/isnanf.h: New file.
2609         * lib/isnanf.c: New file.
2610         * lib/isnan.c: Consider the USE_FLOAT macro.
2611         * m4/isnanf.m4: New file.
2612
2613 2007-04-06  Bruno Haible  <bruno@clisp.org>
2614
2615         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
2616         (Link): New section.
2617
2618         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
2619
2620 2007-04-06  Bruno Haible  <bruno@clisp.org>
2621
2622         Assume the 'long double' type.
2623         * m4/longdouble.m4: Remove file.
2624         * config/srclist.txt: Don't mention longdouble.m4.
2625         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
2626         * lib/float+.h: Likewise.
2627         * lib/frexp.c: Likewise.
2628         * lib/printf-args.h: Likewise.
2629         * lib/printf-args.c: Likewise.
2630         * lib/printf-frexp.c: Likewise.
2631         * lib/printf-parse.c: Likewise.
2632         * lib/vasnprintf.c: Likewise.
2633         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
2634         * m4/intl.m4: Likewise.
2635         * m4/isnanl.m4: Likewise.
2636         * m4/printf.m4: Likewise.
2637         * m4/printf-frexpl.m4: Likewise.
2638         * m4/vasnprintf.m4: Likewise.
2639         * modules/allocsa (Files): Remove m4/longdouble.m4.
2640         * modules/gettext (Files): Likewise.
2641         * modules/relocatable-prog-wrapper (Files): Likewise.
2642         * modules/vasnprintf (Files): Likewise.
2643         * modules/isnanl (Files): Likewise.
2644         (Include): Simplify.
2645         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
2646         (Include): Simplify.
2647         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
2648         (Include): Simplify.
2649         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
2650         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2651         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
2652         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2653         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
2654         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2655         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
2656         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2657         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
2658         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2659         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
2660         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
2661         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
2662         * tests/test-isnanl.c: Likewise.
2663         * tests/test-snprintf-posix.h: Likewise.
2664         * tests/test-sprintf-posix.h: Likewise.
2665         * tests/test-vasnprintf-posix.c: Likewise.
2666         * tests/test-vasnprintf-posix2.c: Likewise.
2667         * tests/test-vasprintf-posix.c: Likewise.
2668
2669 2007-04-06  Bruno Haible  <bruno@clisp.org>
2670
2671         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
2672         * lib/math_.h [__DECC]: Include the overridden include file through
2673         #include_next, outside the double-inclusion guard.
2674         * lib/stdio_.h [__DECC]: Likewise.
2675         * lib/stdlib_.h [__DECC]: Likewise.
2676         * lib/string_.h [__DECC]: Likewise.
2677         * lib/time_.h [__DECC]: Likewise.
2678         * lib/wchar_.h [__DECC]: Likewise.
2679         * lib/wctype_.h [__DECC]: Likewise.
2680         * lib/inttypes_.h [__DECC]: Likewise.
2681         Reported by Albert Chin <china@thewrittenword.com> in
2682         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
2683
2684 2007-04-04  Eric Blake  <ebb9@byu.net>
2685
2686         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
2687         1.5.x.
2688
2689 2007-04-04  Bruno Haible  <bruno@clisp.org>
2690
2691         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
2692         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
2693
2694 2007-04-04  Bruno Haible  <bruno@clisp.org>
2695
2696         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
2697         results for "%010a" of Infinity and NaN.
2698         * tests/test-vasprintf-posix.c (test_function): Likewise.
2699         * tests/test-snprintf-posix.h (test_function): Likewise.
2700         * tests/test-sprintf-posix.h (test_function): Likewise.
2701         * tests/test-fprintf-posix.h (test_function): Remove these tests.
2702         * tests/test-printf-posix.h (test_function): Likewise.
2703         * tests/test-fprintf-posix.out: Update.
2704         Needed for FreeBSD 6.1.
2705
2706 2007-04-04  Bruno Haible  <bruno@clisp.org>
2707
2708         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
2709         directly used by the gnulib modules nor by gnulib-tool.
2710
2711 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
2712
2713         * DEPENDENCIES: Give overall description of version dependency
2714         desirability.  Use more-typical names for apps.
2715         Add shell, coreutils, diffutils, grep, tar, gzip.
2716
2717 2007-04-04  Simon Josefsson  <simon@josefsson.org>
2718
2719         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
2720
2721 2007-04-04  Karl Berry  <karl@gnu.org>
2722
2723         * MODULES.html.sh (func_module): missing '.
2724
2725 2007-04-03  Bruno Haible  <bruno@clisp.org>
2726
2727         * modules/argmatch-tests (Makefile.am): New variable
2728         test_argmatch_LDADD.
2729         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
2730         * modules/array-list-tests (Makefile.am): New variable
2731         test_array_list_LDADD.
2732         * modules/array-oset-tests (Makefile.am): New variable
2733         test_array_oset_LDADD.
2734         * modules/avltree-list-tests (Makefile.am): New variable
2735         test_avltree_list_LDADD.
2736         * modules/avltree-oset-tests (Makefile.am): New variable
2737         test_avltree_oset_LDADD.
2738         * modules/avltreehash-list-tests (Makefile.am): New variable
2739         test_avltreehash_list_LDADD.
2740         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
2741         test_canonicalize_lgpl_LDADD.
2742         * modules/carray-list-tests (Makefile.am): New variable
2743         test_carray_list_LDADD.
2744         * modules/dirname-tests (Makefile.am): New variable
2745         test_dirname_LDADD.
2746         * modules/linked-list-tests (Makefile.am): New variable
2747         test_linked_list_LDADD.
2748         * modules/linkedhash-list-tests (Makefile.am): New variable
2749         test_linkedhash_list_LDADD.
2750         * modules/rbtree-list-tests (Makefile.am): New variable
2751         test_rbtree_list_LDADD.
2752         * modules/rbtree-oset-tests (Makefile.am): New variable
2753         test_rbtree_oset_LDADD.
2754         * modules/rbtreehash-list-tests (Makefile.am): New variable
2755         test_rbtreehash_list_LDADD.
2756         * modules/xvasprintf-tests (Makefile.am): New variable
2757         test_xvasprintf_LDADD.
2758         Reported by Eric Blake.
2759
2760 2007-04-03  Eric Blake  <ebb9@byu.net>
2761
2762         * DEPENDENCIES: Weaken m4 requirements.
2763
2764 2007-04-03  Bruno Haible  <bruno@clisp.org>
2765
2766         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
2767         * modules/isnanl-tests (configure.ac): Likewise.
2768
2769 2007-04-03  Ben Pfaff  <blp@gnu.org>
2770
2771         * modules/iconv_open: Add $(srcdir)/ to source directory
2772         references in Makefile fragments that call gperf, to fix VPATH
2773         builds.
2774
2775 2007-04-03  Bruno Haible  <bruno@clisp.org>
2776
2777         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
2778         * lib/ldexpl.c: Undo last change.
2779
2780 2007-04-03  Bruno Haible  <bruno@clisp.org>
2781
2782         * modules/printf-frexpl (Depends-on): Undo last change.
2783         (Files): Add m4/ldexpl.m4.
2784
2785 2007-04-03  Bruno Haible  <bruno@clisp.org>
2786
2787         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
2788         * modules/isnanl (Link): New section.
2789
2790         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
2791         * modules/frexp (Link): New section.
2792
2793         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
2794         * modules/frexpl (Link): New section.
2795
2796         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
2797         * modules/ldexpl (Link): New section.
2798
2799 2007-04-03  Bruno Haible  <bruno@clisp.org>
2800
2801         * modules/TEMPLATE-EXTENDED: New file.
2802         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
2803
2804 2007-04-03  Bruno Haible  <bruno@clisp.org>
2805
2806         * DEPENDENCIES: New file.
2807         Suggested by Simon Josefsson.
2808
2809 2007-04-03  Bruno Haible  <bruno@clisp.org>
2810
2811         * doc/gnulib.texi: Escape @.
2812
2813 2007-04-03  James Youngman  <jay@gnu.org>
2814         and Paul Eggert  <eggert@cs.ucla.edu>
2815
2816         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
2817         birthtime on all systems that have birthtime, not just those which
2818         use st_birthtimensec rather than st_birthtim.  Putting zero in
2819         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
2820         that the birth time is not available for files on an NFS mount.
2821
2822 2007-04-03  Simon Josefsson  <simon@josefsson.org>
2823
2824         * modules/memxor: Move back from crypto/, suggested by Bruno.
2825         * modules/crypto/hmac-sha1: Fix memxor dependency.
2826
2827         * modules/crypto/gc: Moved from ../.
2828
2829 2007-04-02  Eric Blake  <ebb9@byu.net>
2830
2831         * lib/ldexpl.c (includes): Avoid libm.
2832
2833         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
2834
2835 2007-04-02  Bruno Haible  <bruno@clisp.org>
2836
2837         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
2838         on IRIX.
2839
2840 2007-04-02  Bruno Haible  <bruno@clisp.org>
2841
2842         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
2843         x86 or x86_64 platforms running MacOS X.
2844         Reported by Ryan Schmidt <@ryandesign.com>.
2845
2846 2007-04-02  Bruno Haible  <bruno@clisp.org>
2847
2848         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
2849         i386.
2850
2851 2007-04-01  Simon Josefsson  <simon@josefsson.org>
2852
2853         * modules/crypto/arcfour: Moved from ../.
2854         * modules/crypto/arcfour-tests: Moved from ../.
2855         * modules/crypto/arctwo: Moved from ../.
2856         * modules/crypto/arctwo-tests: Moved from ../.
2857         * modules/crypto/des: Moved from ../.
2858         * modules/crypto/des-tests: Moved from ../.
2859         * modules/crypto/gc-arcfour: Moved from ../.
2860         * modules/crypto/gc-arcfour-tests: Moved from ../.
2861         * modules/crypto/gc-arctwo: Moved from ../.
2862         * modules/crypto/gc-arctwo-tests: Moved from ../.
2863         * modules/crypto/gc-des: Moved from ../.
2864         * modules/crypto/gc-des-tests: Moved from ../.
2865         * modules/crypto/gc-hmac-md5: Moved from ../.
2866         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
2867         * modules/crypto/gc-hmac-sha1: Moved from ../.
2868         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
2869         * modules/crypto/gc-md2: Moved from ../.
2870         * modules/crypto/gc-md2-tests: Moved from ../.
2871         * modules/crypto/gc-md4: Moved from ../.
2872         * modules/crypto/gc-md4-tests: Moved from ../.
2873         * modules/crypto/gc-md5: Moved from ../.
2874         * modules/crypto/gc-md5-tests: Moved from ../.
2875         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
2876         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
2877         * modules/crypto/gc-random: Moved from ../.
2878         * modules/crypto/gc-rijndael: Moved from ../.
2879         * modules/crypto/gc-rijndael-tests: Moved from ../.
2880         * modules/crypto/gc-sha1: Moved from ../.
2881         * modules/crypto/gc-sha1-tests: Moved from ../.
2882         * modules/crypto/gc-tests: Moved from ../.
2883         * modules/crypto/hmac-md5: Moved from ../.
2884         * modules/crypto/hmac-md5-tests: Moved from ../.
2885         * modules/crypto/hmac-sha1: Moved from ../.
2886         * modules/crypto/hmac-sha1-tests: Moved from ../.
2887         * modules/crypto/md2: Moved from ../.
2888         * modules/crypto/md2-tests: Moved from ../.
2889         * modules/crypto/md4: Moved from ../.
2890         * modules/crypto/md4-tests: Moved from ../.
2891         * modules/crypto/md5: Moved from ../.
2892         * modules/crypto/md5-tests: Moved from ../.
2893         * modules/crypto/memxor: Moved from ../.
2894         * modules/crypto/rijndael: Moved from ../.
2895         * modules/crypto/rijndael-tests: Moved from ../.
2896         * modules/crypto/sha1: Moved from ../.
2897
2898 2007-03-30  James Youngman  <jay@gnu.org>
2899
2900         * tests/test-stat-time.c (prepare_test): use chmod() rather than
2901         rename() to change the ctime of a file (because ctime is unaffected
2902         by rename on jfs2 on AIX 5.1).
2903         (main): Start by doing cleanup, in case a previous run failed leaving
2904         test files behind.
2905
2906 2007-03-31  Bruno Haible  <bruno@clisp.org>
2907
2908         Support old proprietary implementations of iconv.
2909         * modules/iconv_open: New file.
2910         * lib/iconv_.h: New file.
2911         * m4/iconv_h.m4: New file.
2912         * lib/iconv_open.c: New file.
2913         * lib/iconv_open-aix.gperf: New file.
2914         * lib/iconv_open-hpux.gperf: New file.
2915         * lib/iconv_open-irix.gperf: New file.
2916         * lib/iconv_open-osf.gperf: New file.
2917         * m4/iconv_open.m4: New file.
2918         * modules/linebreak (Depends-on): Add iconv_open.
2919         * modules/striconv (Depends-on): Likewise.
2920         * modules/striconveh (Depends-on): Likewise.
2921         * modules/unicodeio (Depends-on): Likewise.
2922         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
2923         (iconv_t)(-1).
2924         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
2925         conversion if cd is (iconv_t)(-1).
2926         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
2927         is not possible.
2928
2929 2007-03-31  Bruno Haible  <bruno@clisp.org>
2930
2931         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
2932         work on Solaris either. Protect also second use of "autodetect_jp".
2933
2934 2007-03-31  Bruno Haible  <bruno@clisp.org>
2935
2936         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
2937         the function is not present.
2938
2939 2007-03-31  Bruno Haible  <bruno@clisp.org>
2940
2941         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
2942         the function is not present.
2943
2944 2007-03-31  Bruno Haible  <bruno@clisp.org>
2945
2946         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
2947         a bug in HP-UX iconv_open().
2948
2949 2007-03-31  Bruno Haible  <bruno@clisp.org>
2950
2951         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
2952         (Mathematics <math.h>): New section, add fpieee.
2953         (Input/output <stdio.h>): Add fseterr.
2954         (Mathematics <math.h>): New section, add printf-frexp.
2955         (Container data structures): Add sublist.
2956         (Core language properties): Add fpucw, inline.
2957         (Functions for greatest-width integer types <inttypes.h>): Add
2958         imaxabs, imaxdiv, inttypes.
2959         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
2960         isnanl-nolibm, ldexp.
2961         (Mathematics <math.h>): New section, add printf-frexpl.
2962         (Support for systems lacking POSIX:2001): Add fprintf-posix,
2963         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
2964         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
2965         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
2966         (Unicode string functions): Add unistr/u*-mbtoucr.
2967         (Java): Add javacomp-script, javaexec-script.
2968         (C#): Add csharpcomp-script, csharpexec-script.
2969         (Support for building libraries and executables): Add havelib,
2970         relocatable-*.
2971         (Support for maintaining and releasing projects): Renamed from
2972         'Support for maintaining and release projects'. Add announce-gen.
2973
2974 2007-03-31  Bruno Haible  <bruno@clisp.org>
2975
2976         * README: Talk primarily about git.
2977         (git and CVS): Renamed from CVS.
2978         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
2979         gnulib is available through git.
2980         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
2981
2982 2007-03-30  Bruno Haible  <bruno@clisp.org>
2983
2984         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
2985         * lib/poll_.h: Likewise.
2986         * lib/stat_.h: Likewise.
2987         * lib/sys_time_.h: Likewise.
2988         * lib/sysexit_.h: Likewise.
2989         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
2990         * lib/stdbool_.h: Likewise.
2991         * lib/byteswap_.h: Add double-inclusion guard.
2992
2993 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
2994
2995         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
2996
2997 2007-03-30  Karl Berry  <karl@gnu.org>
2998
2999         * config/srclist-update: double space after USA in the license
3000         substitution, since that's how it's usually (?) written.
3001
3002 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
3003
3004         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
3005         reported by Bruno Haible.
3006
3007 2007-03-29  Bruno Haible  <bruno@clisp.org>
3008
3009         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
3010         a bug in AIX iconv().
3011
3012 2007-03-29  Bruno Haible  <bruno@clisp.org>
3013
3014         * modules/ldexpl-tests: New file.
3015         * tests/test-ldexpl.c: New file.
3016
3017 2007-03-29  Bruno Haible  <bruno@clisp.org>
3018
3019         * lib/ldexpl.c: Include fpucw.h.
3020         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
3021         multiplication.
3022         * modules/ldexpl (Depends-on): Add fpucw.
3023
3024 2007-03-29  Bruno Haible  <bruno@clisp.org>
3025
3026         * modules/ldexpl: New file.
3027         * m4/ldexpl.m4: New file.
3028         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
3029         set.
3030         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
3031         REPLACE_LDEXPL.
3032         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
3033         REPLACE_LDEXPL.
3034         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
3035         gl_FUNC_LDEXPL_WORKS.
3036         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
3037         * modules/mathl (Files): Remove lib/ldexpl.c.
3038         (Depends-on): Add ldexpl.
3039
3040 2007-03-29  Bruno Haible  <bruno@clisp.org>
3041
3042         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
3043
3044 2007-03-29  Bruno Haible  <bruno@clisp.org>
3045
3046         * tests/test-striconveh.c (main): Don't assume that a direct conversion
3047         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
3048         and possibly also HP-UX.
3049         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3050         work on AIX, IRIX, HP-UX, OSF/1.
3051         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
3052         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
3053         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
3054         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
3055         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
3056         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
3057
3058 2007-03-29  Bruno Haible  <bruno@clisp.org>
3059
3060         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
3061
3062 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3063
3064         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
3065         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
3066
3067 2007-03-29  Eric Blake  <ebb9@byu.net>
3068
3069         * lib/acl-internal.h: Remove redundant include.
3070         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
3071         Cygwin when a file is locked.
3072
3073 2007-03-29  Bruno Haible  <bruno@clisp.org>
3074
3075         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
3076         file.
3077         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
3078
3079 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3080
3081         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
3082         try to remove a parent directory if the child couldn't be removed
3083         (except for the first rmdir, which could fail because the child
3084         doesn't exist).  Problem reported by Jeff Blaine in
3085         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
3086
3087 2007-03-28  Bruno Haible  <bruno@clisp.org>
3088
3089         * lib/striconveh.c (utf8conv_carefully): New function.
3090         (mem_cd_iconveh_internal): Invoke it.
3091
3092 2007-03-28  Bruno Haible  <bruno@clisp.org>
3093
3094         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
3095         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
3096         input.
3097         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
3098         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
3099         unistr/u8-uctomb.
3100
3101 2007-03-28  Bruno Haible  <bruno@clisp.org>
3102
3103         * modules/unistr/u8-mbtoucr: New file.
3104         * lib/unistr/u8-mbtoucr.c: New file.
3105         * modules/unistr/u16-mbtoucr: New file.
3106         * lib/unistr/u16-mbtoucr.c: New file.
3107         * modules/unistr/u16-mbtoucr: New file.
3108         * lib/unistr/u16-mbtoucr.c: New file.
3109         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
3110
3111 2007-03-27  Simon Josefsson  <simon@josefsson.org>
3112             Bruno Haible  <bruno@clisp.org>
3113
3114         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
3115         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
3116         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
3117
3118         * m4/stdio_h.m4: Add stubs for vasprintf too.
3119
3120         * modules/stdio: Support vasprintf in sed command.
3121
3122         * modules/vasprintf: Depend on stdio for prototypes.  Remove
3123         vasprintf.h.  Add stdio module indicator.
3124
3125         * lib/stdio_.h: Declare asprintf and vasprintf, based on
3126         vasprintf.h.
3127
3128         * lib/vasprintf.h: File removed.
3129
3130         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
3131         * lib/vasprintf.c: Ditto.
3132         * lib/xvasprintf.c: Ditto.
3133         * tests/test-vasprintf-posix.c: Ditto.
3134         * tests/test-vasprintf.c: Ditto.
3135
3136 2007-03-27  Bruno Haible  <bruno@clisp.org>
3137
3138         Make vasnprintf multithread-safe.
3139         * lib/vasnprintf.c (decimal_point_char): New function.
3140         (VASNPRINTF): Use it.
3141         Suggested by Simon Josefsson.
3142
3143 2007-03-27  Eric Blake  <ebb9@byu.net>
3144
3145         Support sub-second birthtime on cygwin.
3146         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
3147         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
3148         (get_stat_birthtime): Also work with st_birthtim.
3149
3150 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
3151
3152         * lib/stat-time.h (USE_BIRTHTIME): Remove.
3153         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
3154         (get_stat_birthtime_ns): Do not try to use "spare" fields.
3155         (get_stat_birthtime_ns): Simplify compile-time tests.
3156         (get_stat_birthtime): Change the API to look like
3157         get_stat_mtime etc., except return a negative tv_nsec on error.
3158         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
3159         Don't check for "spare" fields.
3160         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
3161         or for struct stat.st_birthtime, as these tests aren't used.
3162         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
3163
3164 2007-03-27  Bruno Haible  <bruno@clisp.org>
3165
3166         * lib/stat-time.h: Include <sys/stat.h>.
3167
3168 2007-03-27  James Youngman  <jay@gnu.org>
3169
3170         * lib/stat-time.h (get_stat_birthtime): New function for
3171           retrieving st_birthtime as provided by UFS2 (hence *BSD).
3172         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
3173           and its variants.
3174         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
3175         * modules/stat-time-test: New file.
3176         * tests/test-stat-time.c: New test, devised by Bruno Haible.
3177
3178 2007-03-26  Bruno Haible  <bruno@clisp.org>
3179
3180         Better support of signalling NaNs.
3181         * lib/atanl.c: Include isnanl.h.
3182         (atanl): Perform test for NaN at the beginning of the function and
3183         through a call to isnanl.
3184         * lib/cosl.c: Include isnanl.h.
3185         (cosl): Perform test for NaN at the beginning of the function and
3186         through a call to isnanl.
3187         * lib/ldexpl.c: Include isnanl.h.
3188         (ldexpl): Perform test for NaN through a call to isnanl.
3189         * lib/logl.c: Include isnanl.h.
3190         (logl): Perform test for NaN at the beginning of the function and
3191         through a call to isnanl.
3192         * lib/sinl.c: Include isnanl.h.
3193         (sinl): Perform test for NaN at the beginning of the function and
3194         through a call to isnanl.
3195         * lib/sqrtl.c: Include isnanl.h.
3196         (sqrtl): Perform test for NaN at the beginning of the function and
3197         through a call to isnanl.
3198         * lib/tanl.c: Include isnanl.h.
3199         (tanl): Perform test for NaN at the beginning of the function and
3200         through a call to isnanl.
3201         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
3202         * modules/mathl (Depends-on): Add isnanl.
3203
3204 2007-03-26  Eric Blake  <ebb9@byu.net>
3205
3206         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
3207         regression in logic sense of previous patch.
3208
3209 2007-03-26  Bruno Haible  <bruno@clisp.org>
3210
3211         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
3212         unportable shell command "if ! ...".
3213         Reported by Ralf Wildenhues.
3214
3215 2007-03-25  Bruno Haible  <bruno@clisp.org>
3216
3217         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
3218         <sysexits.h> file, and only add EX_CONFIG.
3219         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
3220         absolute file name and whether it is sufficient. Substitute also
3221         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
3222         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
3223         ABSOLUTE_SYSEXITS_H into sysexits.h.
3224
3225 2007-03-25  Bruno Haible  <bruno@clisp.org>
3226
3227         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
3228         hints is NULL.
3229
3230 2007-03-25  Bruno Haible  <bruno@clisp.org>
3231
3232         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
3233         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
3234
3235 2007-03-25  Bruno Haible  <bruno@clisp.org>
3236
3237         * lib/vasnprintf.c: Include langinfo.h.
3238         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
3239         multithread-safe.
3240         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
3241         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
3242         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
3243         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
3244         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
3245         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
3246         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
3247         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
3248         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
3249         Reported by Simon Josefsson.
3250
3251 2007-03-25  Bruno Haible  <bruno@clisp.org>
3252
3253         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
3254         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
3255         * modules/vasnprintf (Depends-on): Add stdint.
3256
3257 2007-03-25  Bruno Haible  <bruno@clisp.org>
3258
3259         * modules/fpieee: New file.
3260         * m4/fpieee.m4: New file.
3261         * modules/isnan-nolibm (Depends-on): Add fpieee.
3262         * modules/isnanl-nolibm (Depends-on): Add fpieee.
3263         * modules/isnanl (Depends-on): Add fpieee.
3264
3265 2007-03-25  Bruno Haible  <bruno@clisp.org>
3266
3267         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
3268
3269 2007-03-25  Bruno Haible  <bruno@clisp.org>
3270
3271         Avoid test failures on IRIX 6.5.
3272         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
3273         (main): Use it.
3274         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
3275         macros.
3276         (main): Use them.
3277
3278 2007-03-25  Bruno Haible  <bruno@clisp.org>
3279
3280         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
3281         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
3282         exists but doesn't work.
3283         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
3284         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
3285         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
3286         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
3287
3288 2007-03-25  Bruno Haible  <bruno@clisp.org>
3289
3290         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
3291         returns inf. Needed on IRIX 6.5.
3292
3293 2007-03-25  Bruno Haible  <bruno@clisp.org>
3294
3295         * tests/test-frexpl.c: Include isnanl-nolibm.h.
3296         (main): Use isnanl instead of x != x idiom.
3297         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
3298
3299         * tests/test-frexp.c: Include isnan.h.
3300         (main): Use isnan instead of x != x idiom.
3301         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
3302
3303 2007-03-25  Bruno Haible  <bruno@clisp.org>
3304
3305         * tests/test-frexp.c (NaN): New function/macro.
3306         (main): Use it instead of 0.0 / 0.0.
3307         * tests/test-isnan.c (NaN): New function/macro.
3308         (main): Use it instead of 0.0 / 0.0.
3309         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
3310         (test_function): Use it instead of 0.0 / 0.0.
3311         * tests/test-vasprintf-posix.c (NaN): New function/macro.
3312         (test_function): Use it instead of 0.0 / 0.0.
3313         * tests/test-snprintf-posix.h (NaN): New function/macro.
3314         (test_function): Use it instead of 0.0 / 0.0.
3315         * tests/test-sprintf-posix.h (NaN): New function/macro.
3316         (test_function): Use it instead of 0.0 / 0.0.
3317         * tests/test-fprintf-posix.h (NaN): New function/macro.
3318         (test_function): Use it instead of 0.0 / 0.0.
3319         * tests/test-printf-posix.h (NaN): New function/macro.
3320         (test_function): Use it instead of 0.0 / 0.0.
3321
3322         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
3323
3324 2007-03-25  Bruno Haible  <bruno@clisp.org>
3325
3326         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
3327
3328 2007-03-25  Bruno Haible  <bruno@clisp.org>
3329
3330         * lib/regexec.c (merge_state_with_log): Make static.
3331
3332 2007-03-25  Bruno Haible  <bruno@clisp.org>
3333
3334         * lib/trigl.c (kernel_rem_pio2): Make static.
3335
3336 2007-03-25  Bruno Haible  <bruno@clisp.org>
3337
3338         * lib/sincosl.c (sincosl_table): Make static.
3339
3340 2007-03-25  Bruno Haible  <bruno@clisp.org>
3341
3342         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
3343         if the compiler does not support C99.
3344
3345 2007-03-25  Bruno Haible  <bruno@clisp.org>
3346
3347         * modules/time (Makefile.am): Ensure all rule action lines start with a
3348         tab.
3349
3350 2007-03-24  Bruno Haible  <bruno@clisp.org>
3351
3352         * modules/tsearch-tests: New file.
3353         * tests/test-tsearch.sh: New file.
3354         * tests/test-tsearch.c: New file, mostly copied from glibc.
3355
3356         * modules/search-tests: New file.
3357         * tests/test-search.c: New file.
3358
3359         * modules/search: New file.
3360         * lib/search_.h: New file, incorporating lib/tsearch.h.
3361         * m4/search_h.m4: New file.
3362         * lib/tsearch.h: Remove file.
3363         * lib/tsearch.c: Include search.h instead of tsearch.h.
3364         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
3365         HAVE_TSEARCH.
3366         * modules/tsearch (Files): Remove lib/tsearch.h.
3367         (Depends-on): Add search.
3368         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
3369         (Include): Change tsearch.h into search.h.
3370
3371 2007-03-24  Bruno Haible  <bruno@clisp.org>
3372
3373         * modules/fpucw: New file.
3374         * lib/fpucw.h: New file.
3375         * lib/frexp.c: Include fpucw.h.
3376         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3377         (FUNC): Use them.
3378         * lib/printf-frexp.c: Include fpucw.h.
3379         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3380         (FUNC): Use them.
3381         * lib/vasnprintf.c: Include fpucw.h.
3382         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
3383         'long double' calculations.
3384         * tests/test-frexpl.c: Include fpucw.h.
3385         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3386         * tests/test-printf-frexpl.c: Include fpucw.h.
3387         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3388         * modules/frexpl (Depends-on): Add fpucw.
3389         * modules/printf-frexpl (Depends-on): Likewise.
3390         * modules/fprintf-posix (Depends-on): Likewise.
3391         * modules/snprintf-posix (Depends-on): Likewise.
3392         * modules/sprintf-posix (Depends-on): Likewise.
3393         * modules/vasnprintf-posix (Depends-on): Likewise.
3394         * modules/vasprintf-posix (Depends-on): Likewise.
3395         * modules/vfprintf-posix (Depends-on): Likewise.
3396         * modules/vsnprintf-posix (Depends-on): Likewise.
3397         * modules/vsprintf-posix (Depends-on): Likewise.
3398         * modules/frexpl-tests (Depends-on): Likewise.
3399         * modules/printf-frexpl-tests (Depends-on): Likewise.
3400
3401 2007-03-24  Bruno Haible  <bruno@clisp.org>
3402
3403         * lib/float+.h: New file.
3404         * lib/isnan.c: Include float+.h.
3405         (SIZE): New macro.
3406         (FUNC): Compare only SIZE bytes of the value.
3407         * lib/vasnprintf.c: Include float+.h.
3408         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
3409         SIZEOF_LDBL or SIZEOF_DBL bytes.
3410         * modules/isnan-nolibm (Files): Add lib/float+.h.
3411         * modules/isnanl-nolibm (Files): Add lib/float+.h.
3412         * modules/isnanl (Files): Add lib/float+.h.
3413         * modules/vasnprintf (Files): Add lib/float+.h.
3414
3415 2007-03-24  Bruno Haible  <bruno@clisp.org>
3416
3417         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
3418         include isnanl-nolibm.h.
3419
3420 2007-03-24  Bruno Haible  <bruno@clisp.org>
3421
3422         * tests/test-read-file.c (main): Don't produce spurious output for
3423         expected situations. Make the test fail if it encountered unexpected
3424         results.
3425
3426 2007-03-24  Bruno Haible  <bruno@clisp.org>
3427
3428         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
3429         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
3430
3431 2007-03-24  Bruno Haible  <bruno@clisp.org>
3432
3433         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
3434
3435 2007-03-24  Bruno Haible  <bruno@clisp.org>
3436
3437         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
3438         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
3439
3440         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
3441         * modules/utf8-ucs4: Turn into a symbolic link to module
3442         unistr/u8-mbtouc.
3443
3444         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
3445         utf8-ucs4-unsafe.
3446         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
3447         unistr/u8-mbtouc-unsafe.
3448
3449         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
3450         * modules/utf16-ucs4: Turn into a symbolic link to module
3451         unistr/u16-mbtouc.
3452
3453         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
3454         utf16-ucs4-unsafe.
3455         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
3456         unistr/u16-mbtouc-unsafe.
3457
3458         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
3459         * modules/ucs4-utf8: Turn into a symbolic link to module
3460         unistr/u8-ubtomb.
3461
3462         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
3463         * modules/ucs4-utf16: Turn into a symbolic link to module
3464         unistr/u16-ubtomb.
3465
3466 2007-03-24  Bruno Haible  <bruno@clisp.org>
3467
3468         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
3469         Enable the function only if HAVE_INLINE.
3470         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
3471         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3472         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
3473         Enable the function only if HAVE_INLINE.
3474         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
3475         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3476         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
3477         Enable the function only if HAVE_INLINE.
3478         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
3479         Enable the function only if HAVE_INLINE.
3480         * modules/utf8-ucs4: Update.
3481         * modules/utf8-ucs4-unsafe: Update.
3482         * modules/utf16-ucs4: Update.
3483         * modules/utf16-ucs4-unsafe: Update.
3484         * modules/ucs4-utf8: Update.
3485         * modules/ucs4-utf16: Update.
3486
3487 2007-03-24  Bruno Haible  <bruno@clisp.org>
3488
3489         * lib/utf8-ucs4.h: Remove file.
3490         * lib/utf8-ucs4-unsafe.h: Remove file.
3491         * lib/utf16-ucs4.h: Remove file.
3492         * lib/utf16-ucs4-unsafe.h: Remove file.
3493         * lib/ucs4-utf8.h: Remove file.
3494         * lib/ucs4-utf16.h: Remove file.
3495         * lib/unistr.h: Include their previous contents.
3496         * m4/utf-ucs4.m4: Remove file.
3497         * m4/ucs4-utf.m4: Remove file.
3498         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.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/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.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 (Files): Remove lib/utf16-ucs4.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/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
3514         (Depends-on): Add unistr/base.
3515         (configure.ac): Remove gl_UTF_UCS4.
3516         (Makefile.am): Update.
3517         (Include): Change to unistr.h.
3518         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.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         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
3524         (Depends-on): Add unistr/base.
3525         (configure.ac): Remove gl_UCS4_UTF.
3526         (Makefile.am): Update.
3527         (Include): Change to unistr.h.
3528         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
3529         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
3530         utf8-ucs4-unsafe.h.
3531         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
3532         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
3533         utf16-ucs4-unsafe.h.
3534         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
3535         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
3536         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
3537         * lib/unistr/u8-strchr.c: Likewise.
3538         * lib/unistr/u8-strrchr.c: Likewise.
3539         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
3540         * lib/unistr/u16-strchr.c: Likewise.
3541         * lib/unistr/u16-strrchr.c: Likewise.
3542         * lib/striconveh.c: Update.
3543         * lib/linebreak.c: Update.
3544
3545 2007-03-24  Bruno Haible  <bruno@clisp.org>
3546
3547         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
3548         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
3549
3550 2007-03-22  Bruno Haible  <bruno@clisp.org>
3551
3552         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
3553
3554 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
3555
3556         * MODULES.html.sh (File system functions): New module write-any-file.
3557         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
3558         * m4/write-any-file.m4: New files.
3559
3560 2007-03-23  Eric Blake  <ebb9@byu.net>
3561
3562         * gnulib-tool: Rearrange space-tab sequences, since some editors
3563         like to eat them.
3564
3565 2007-03-23  Eric Blake  <ebb9@byu.net>
3566
3567         * lib/version-etc.c (version_etc_va): Update license wording to
3568         be more concise.  Recommended by Richard Stallman.
3569
3570 2007-03-22  Bruno Haible  <bruno@clisp.org>
3571
3572         * lib/poll.c (MSG_PEEK): New fallback definition.
3573
3574 2007-03-22  Bruno Haible  <bruno@clisp.org>
3575
3576         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
3577         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
3578         (main): Update.
3579         Fixes a compilation error on BeOS.
3580
3581 2007-03-22  Bruno Haible  <bruno@clisp.org>
3582
3583         * modules/frexpl-tests: New file.
3584         * tests/test-frexpl.c: New file.
3585
3586         * modules/frexpl: New file.
3587         * m4/frexpl.m4: New file.
3588         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
3589         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
3590         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
3591         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
3592         (Depends-on): Add frexpl. Remove isnanl-nolibm.
3593         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
3594
3595 2007-03-22  Bruno Haible  <bruno@clisp.org>
3596
3597         * lib/frexpl.c: Share code with lib/frexp.c.
3598         * modules/mathl (Files): Add lib/frexp.c.
3599         (Depends-on): Add isnanl-nolibm.
3600
3601 2007-03-22  Bruno Haible  <bruno@clisp.org>
3602
3603         * modules/printf-frexp (Files): Add m4/frexp.m4.
3604         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
3605         only if the found frexp function actually works.
3606
3607 2007-03-22  Bruno Haible  <bruno@clisp.org>
3608
3609         * lib/frexp.c: Remove older implementation that uses divisions.
3610
3611 2007-03-21  Bruno Haible  <bruno@clisp.org>
3612
3613         * modules/frexp-tests: New file.
3614         * tests/test-frexp.c: New file.
3615
3616         * modules/frexp: New file.
3617         * lib/frexp.c: New file.
3618         * m4/frexp.m4: New file.
3619         * lib/math_.h (frexp): New declaration.
3620         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
3621         REPLACE_FREXP.
3622         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
3623
3624 2007-03-21  Bruno Haible  <bruno@clisp.org>
3625
3626         * modules/isnanl-tests: New file.
3627         * tests/test-isnanl.c: New file.
3628
3629         * modules/isnanl: New file.
3630         * lib/isnanl.h: New file.
3631         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
3632         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
3633         gl_FUNC_ISNANL_WORKS.
3634         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
3635         New macros.
3636
3637 2007-03-21  Bruno Haible  <bruno@clisp.org>
3638
3639         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
3640         lib/isnanl.h.
3641         (Include): Update.
3642         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
3643         * lib/vasnprintf.c: Update.
3644         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
3645         tests/test-isnanl.h, remove tests/test-isnanl.c.
3646         (Makefile.am): Update.
3647         * tests/test-isnanl-nolibm.c: New file.
3648         * tests/test-isnanl.h: New file.
3649         * tests/test-isnanl.c: Remove file.
3650
3651 2007-03-21  Jim Meyering  <jim@meyering.net>
3652
3653         When trying to open ".", treat ESTALE like EACCES.
3654         * lib/savewd.c (savewd_save): Resort to forking not just upon
3655         failure with EACCES, but also when errno is ESTALE.
3656
3657 2007-03-20  Bruno Haible  <bruno@clisp.org>
3658
3659         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
3660         Needed on AIX 5.1. Reported by Matthew Woehlke.
3661
3662 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
3663
3664         Suggestions by Bruno Haible:
3665         * lib/acl-internal.h: Include "gettext.h" rather than rolling
3666         our own.
3667         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
3668         * modules/acl (Depends-on): Add gettext.
3669
3670 2007-03-19  Bruno Haible  <bruno@clisp.org>
3671
3672         * modules/iconvme: Remove file.
3673         * lib/iconvme.h: Remove file.
3674         * lib/iconvme.c: Remove file.
3675         * m4/iconvme.m4: Remove file.
3676
3677 2007-03-19  Bruno Haible  <bruno@clisp.org>
3678
3679         * doc/relocatable-maint.texi: Break long shell script line.
3680         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
3681
3682 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
3683
3684         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
3685         handle file_has_acl.
3686         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
3687         * lib/acl.c: Move header inclusions and related macro defns into
3688         lib/acl-internal.h.
3689         (S_ISLNK): Remove defn, since that's now done for us.
3690         (file_has_acl): Move to lib/file-has-acl.c.
3691         Call acl_trivial if available.  This is the crucial part of the fix.
3692         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
3693         shared within the library.  Rewrite a bit, partly to make it compatible
3694         with the GNU coding style.
3695         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
3696         Remove unnecessary double-quotes.
3697         Don't test for acl_to_text; the build will catch that.
3698         Replace acl_entries if it doesn't exist and it is needed.
3699         Check for -lsec and acl_trivial (as used on Solaris 10).
3700         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
3701         lib/file-has-acl.c.
3702         (Depends-on): Add sys_stat, for S_ISLNK.
3703
3704 2007-03-19  Ben Pfaff  <blp@gnu.org>
3705
3706         * doc/gnulib.texi: Fix typos.
3707         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
3708
3709 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
3710
3711         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
3712         If size is zero here, buf must be zero.
3713
3714 2007-03-19  Simon Josefsson  <simon@josefsson.org>
3715
3716         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
3717         <bruno@clisp.org>.
3718
3719 2007-03-18  Bruno Haible  <bruno@clisp.org>
3720
3721         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
3722         Suggested by Eric Blake.
3723
3724 2007-03-18  Ben Pfaff  <blp@gnu.org>
3725
3726         * doc/relocatable.texi: Recommend using as prefix a directory
3727         that does not exist and will never be created.  Based on
3728         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
3729         and others.
3730
3731 2007-03-17  Bruno Haible  <bruno@clisp.org>
3732
3733         * lib/fchownat.c: Include lchown.h.
3734
3735 2007-03-17  Bruno Haible  <bruno@clisp.org>
3736
3737         Fix endless loop when the given allocated size was > INT_MAX.
3738         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
3739         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
3740         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
3741         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
3742         * lib/sprintf.c (sprintf): Likewise.
3743
3744 2007-03-17  Bruno Haible  <bruno@clisp.org>
3745
3746         * tests/test-argp-2.sh (func_compare): Output a context diff.
3747
3748 2007-03-17  Bruno Haible  <bruno@clisp.org>
3749
3750         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
3751         locale's decimal-point character.
3752
3753 2007-03-17  Bruno Haible  <bruno@clisp.org>
3754
3755         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
3756         before comparing it. Needed because on some platforms (e.g. x86) a
3757         'long double' occupies less bytes than sizeof (long double).
3758
3759 2007-03-17  Bruno Haible  <bruno@clisp.org>
3760
3761         * tests/test-crc.c (main): Make printf statements 64-bit clean.
3762         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
3763         * tests/test-getaddrinfo.c (simple): Likewise.
3764         * tests/test-read-file.c (main): Likewise.
3765
3766 2007-03-17  Bruno Haible  <bruno@clisp.org>
3767
3768         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
3769
3770 2007-03-17  Bruno Haible  <bruno@clisp.org>
3771
3772         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
3773         unused variable.
3774
3775 2007-03-17  Bruno Haible  <bruno@clisp.org>
3776
3777         * tests/test-c-strcasecmp.c: Include c-strcase.h.
3778         * tests/test-c-strncasecmp.c: Likewise.
3779
3780 2007-03-17  Bruno Haible  <bruno@clisp.org>
3781
3782         * modules/stdlib (Depends-on): Add unistd.
3783         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
3784         Needed for MacOS X 10.3.
3785
3786 2007-03-17  Bruno Haible  <bruno@clisp.org>
3787
3788         * lib/unistr/u-strdup.h: Include <stdlib.h>.
3789
3790 2007-03-17  Bruno Haible  <bruno@clisp.org>
3791
3792         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
3793
3794 2007-03-17  Bruno Haible  <bruno@clisp.org>
3795
3796         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
3797         to reflect files copied from gnulib (with or without modifications).
3798         Suggested by Jim Meyering.
3799
3800 2007-03-17  Eric Blake  <ebb9@byu.net>
3801
3802         * NEWS: Document stdlib change from 2007-02-18.
3803
3804 2007-03-17  Jim Meyering  <jim@meyering.net>
3805
3806         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
3807         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
3808         someone uses a name containing shell meta-characters.
3809         Reported by Alfred M. Szmidt.
3810
3811         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
3812
3813 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
3814
3815         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
3816         and copy gettext configuration files only if configure.ac contains
3817         a use of AM_GNU_GETTEXT_VERSION.
3818
3819 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
3820
3821         * build-aux/bootstrap (gnulib_name): New variable.
3822         (gnulib_tool_options): Use it.
3823
3824 2007-03-13  Simon Josefsson  <simon@josefsson.org>
3825
3826         * tests/test-des.c: Use new namespace.
3827
3828 2007-03-15  Bruno Haible  <bruno@clisp.org>
3829
3830         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
3831         Reported by James Youngman <jay@gnu.org>.
3832
3833 2007-03-15  Bruno Haible  <bruno@clisp.org>
3834
3835         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
3836         declared prototype. Needed with cc on OSF/1 5.1.
3837
3838 2007-03-15  Bruno Haible  <bruno@clisp.org>
3839
3840         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
3841         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
3842         (struct gl_list_implementation): Add dispose_fn argument to the
3843         'create_empty', 'create' methods.
3844         (struct gl_list_impl_base): Add field 'dispose_fn'.
3845         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
3846         argument.
3847         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
3848         dispose_fn argument.
3849         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
3850         dispose_fn on the dropped values.
3851         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
3852         dispose_fn argument.
3853         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
3854         dropped values.
3855         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
3856         (gl_tree_remove_node): Call dispose_fn on the dropped value.
3857         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
3858         (gl_tree_remove_node): Call dispose_fn on the dropped value.
3859         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
3860         argument.
3861         (gl_tree_list_free): Call dispose_fn on the dropped values.
3862         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
3863         the dropped values.
3864         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
3865         Add dispose_fn argument.
3866         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
3867         Call dispose_fn on the dropped values.
3868         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
3869         Add dispose_fn argument.
3870         (gl_sublist_create): Initialize the 'dispose_fn' field.
3871         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
3872         * tests/test-array_list.c (main): Update.
3873         * tests/test-carray_list.c (main): Update.
3874         * tests/test-avltree_list.c (main): Update.
3875         * tests/test-rbtree_list.c (main): Update.
3876         * tests/test-avltreehash_list.c (main): Update.
3877         * tests/test-rbtreehash_list.c (main): Update.
3878         * tests/test-linked_list.c (main): Update.
3879         * tests/test-linkedhash_list.c (main): Update.
3880         * tests/test-array_oset.c (main): Update.
3881
3882 2007-03-15  Bruno Haible  <bruno@clisp.org>
3883
3884         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
3885         (gl_oset_create_empty): Add dispose_fn argument.
3886         (struct gl_oset_implementation): Add dispose_fn argument to
3887         'create_empty' method.
3888         (struct gl_oset_impl_base): Add dispose_fn field.
3889         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
3890         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
3891         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
3892         values.
3893         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
3894         (gl_tree_oset_free): Call dispose_fn on the dropped values.
3895         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
3896         dropped value.
3897         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
3898         dropped value.
3899         * tests/test-array_oset.c (main): Update.
3900         * tests/test-avltree_oset.c (main): Update.
3901         * tests/test-rbtree_oset.c (main): Update.
3902         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
3903
3904 2007-03-13  Bruno Haible  <bruno@clisp.org>
3905
3906         * tests/test-stdbool.c (i): Update after last patch.
3907
3908 2007-03-12  Bruno Haible  <bruno@clisp.org>
3909
3910         * lib/quotearg.c: Include <wctype.h> early, before the definition of
3911         the iswprint macro. Needed on Solaris 2.5.1.
3912
3913 2007-03-12  Bruno Haible  <bruno@clisp.org>
3914
3915         * tests/test-printf-frexp.c (main): Declare x as volatile.
3916
3917 2007-03-12  Simon Josefsson  <simon@josefsson.org>
3918
3919         * doc/gnulib.texi (Build robot for gnulib): New section.
3920
3921 2007-03-12  Jim Meyering  <jim@meyering.net>
3922
3923         * build-aux/bootstrap: New file.
3924         * build-aux/bootstrap.conf: New file, from coreutils.
3925
3926 2007-03-11  Bruno Haible  <bruno@clisp.org>
3927
3928         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
3929
3930 2007-03-12  Simon Josefsson  <simon@josefsson.org>
3931
3932         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
3933         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
3934         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
3935
3936 2007-03-11  Bruno Haible  <bruno@clisp.org>
3937
3938         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
3939         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
3940
3941 2007-03-11  Bruno Haible  <bruno@clisp.org>
3942
3943         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
3944         formula. Needed for SunPRO C 5.0.
3945
3946 2007-03-11  Bruno Haible  <bruno@clisp.org>
3947
3948         * modules/long-options (Depends-on): Add getopt.
3949
3950 2007-03-11  Bruno Haible  <bruno@clisp.org>
3951
3952         * modules/modechange (Depends-on): Add stdbool.
3953
3954 2007-03-11  Bruno Haible  <bruno@clisp.org>
3955
3956         * modules/i-ring (Depends-on): Add stdbool.
3957
3958 2007-03-11  Bruno Haible  <bruno@clisp.org>
3959
3960         * modules/gc-des (Depends-on): Add stdbool.
3961
3962 2007-03-11  Bruno Haible  <bruno@clisp.org>
3963
3964         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
3965
3966 2007-03-11  Bruno Haible  <bruno@clisp.org>
3967
3968         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
3969
3970 2007-03-11  Bruno Haible  <bruno@clisp.org>
3971
3972         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
3973
3974 2007-03-11  Bruno Haible  <bruno@clisp.org>
3975
3976         * lib/vasnprintf.c (sprintf): Undefine.
3977
3978 2007-03-11  Bruno Haible  <bruno@clisp.org>
3979
3980         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
3981         initializers in SunPRO C and Compaq C compilers.
3982
3983 2007-03-11  Bruno Haible  <bruno@clisp.org>
3984
3985         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
3986         decrementing code ANSI C compliant.
3987
3988 2007-03-11  Bruno Haible  <bruno@clisp.org>
3989
3990         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
3991         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
3992
3993 2007-03-11  Bruno Haible  <bruno@clisp.org>
3994
3995         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
3996         <stdbool.h> substitute doesn't pass.
3997
3998 2007-03-11  Bruno Haible  <bruno@clisp.org>
3999
4000         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
4001
4002 2007-03-11  Bruno Haible  <bruno@clisp.org>
4003
4004         * gnulib-tool (func_create_megatestdir): Create also an autobuild
4005         script, for submission to autobuild.josefsson.org.
4006
4007 2007-03-10  Bruno Haible  <bruno@clisp.org>
4008
4009         * modules/canonicalize-lgpl-tests: New file.
4010         * tests/test-canonicalize-lgpl.sh: New file.
4011         * tests/test-canonicalize-lgpl.c: New file.
4012
4013         * modules/c-strcase-tests: New file.
4014         * tests/test-c-strcase.sh: New file.
4015         * tests/test-c-strcasecmp.c: New file.
4016         * tests/test-c-strncasecmp.c: New file.
4017
4018         * modules/atexit-tests: New file.
4019         * tests/test-atexit.sh: New file.
4020         * tests/test-atexit.c: New file.
4021
4022 2007-03-10  Bruno Haible  <bruno@clisp.org>
4023
4024         * tests/test-binary-io.sh: Use temporary filenames that are not so
4025         likely to clash with those of other tests (in a parallel make).
4026         * tests/test-binary-io.c: Likewise.
4027
4028 2007-03-10  Bruno Haible  <bruno@clisp.org>
4029
4030         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
4031         fallback; use #error instead.
4032         Suggested by Simon Josefsson.
4033
4034 2007-03-10  Bruno Haible  <bruno@clisp.org>
4035
4036         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
4037         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
4038         first and the last.
4039
4040 2007-03-10  Bruno Haible  <bruno@clisp.org>
4041
4042         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
4043
4044 2007-03-10  Bruno Haible  <bruno@clisp.org>
4045
4046         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
4047         "make distcheck".
4048         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
4049         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
4050         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
4051
4052 2007-03-10  Bruno Haible  <bruno@clisp.org>
4053
4054         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
4055         variable.
4056         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
4057         variable.
4058
4059 2007-03-09  Eric Blake  <ebb9@byu.net>
4060         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
4061
4062         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
4063         types are not being provided by gnulib.
4064         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
4065         types are supported.
4066
4067 2007-03-10  Bruno Haible  <bruno@clisp.org>
4068
4069         * lib/stdio_.h (__attribute__): New macro.
4070         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
4071         vsprintf): Specify __attribute__ __format__ for GCC.
4072         Suggested by Eric Blake.
4073
4074 2007-03-09  Bruno Haible  <bruno@clisp.org>
4075
4076         * modules/printf-posix-tests: New file.
4077         * tests/test-printf-posix.sh: New file.
4078         * tests/test-printf-posix.c: New file.
4079
4080         * modules/printf-posix: New file.
4081         * lib/printf.c: New file.
4082         * m4/printf-posix-rpl.m4: New file.
4083         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
4084         REPLACE_PRINTF.
4085         * lib/stdio_.h (printf): New declaration.
4086         (format, __format__, ____printf____, ____scanf____, ____strftime____,
4087         ____strfmon____): New macros.
4088         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
4089         REPLACE_PRINTF.
4090
4091 2007-03-09  Bruno Haible  <bruno@clisp.org>
4092
4093         * tests/test-vasnprintf-posix2.sh: New file.
4094         * tests/test-vasnprintf-posix2.c: New file.
4095         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
4096         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
4097         (Makefile.am): Activate test-vasnprintf-posix2.sh.
4098
4099         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
4100         a locale dependent decimal point, rather than always '.'.
4101
4102 2007-03-09  Eric Blake  <ebb9@byu.net>
4103
4104         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
4105         spite of platforms like Tandem/NSK that define it to -1.
4106
4107 2007-03-08  Bruno Haible  <bruno@clisp.org>
4108
4109         * modules/vprintf-posix-tests: New file.
4110         * tests/test-vprintf-posix.sh: New file.
4111         * tests/test-vprintf-posix.c: New file.
4112         * tests/test-printf-posix.h: New file.
4113
4114         * modules/vprintf-posix: New file.
4115         * lib/vprintf.c: New file.
4116         * m4/vprintf-posix.m4: New file.
4117         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
4118         REPLACE_VPRINTF.
4119         * lib/stdio_.h (vprintf): New declaration.
4120         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
4121         REPLACE_VPRINTF.
4122
4123 2007-03-08  Bruno Haible  <bruno@clisp.org>
4124
4125         * modules/fprintf-posix-tests: New file.
4126         * tests/test-fprintf-posix.sh: New file.
4127         * tests/test-fprintf-posix.c: New file.
4128
4129         * modules/fprintf-posix: New file.
4130         * lib/fprintf.c: New file.
4131         * m4/fprintf-posix.m4: New file.
4132         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
4133         REPLACE_FPRINTF.
4134         * lib/stdio_.h (fprintf): New declaration.
4135         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
4136         REPLACE_FPRINTF.
4137
4138 2007-03-08  Bruno Haible  <bruno@clisp.org>
4139
4140         * modules/vfprintf-posix-tests: New file.
4141         * tests/test-vfprintf-posix.sh: New file.
4142         * tests/test-vfprintf-posix.c: New file.
4143         * tests/test-fprintf-posix.h: New file.
4144         * tests/test-fprintf-posix.out: New file.
4145
4146         * modules/vfprintf-posix: New file.
4147         * lib/vfprintf.c: New file.
4148         * m4/vfprintf-posix.m4: New file.
4149         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
4150         REPLACE_VFPRINTF.
4151         * lib/stdio_.h (vfprintf): New declaration.
4152         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
4153         REPLACE_VFPRINTF.
4154
4155 2007-03-08  Bruno Haible  <bruno@clisp.org>
4156
4157         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
4158
4159 2007-03-08  Bruno Haible  <bruno@clisp.org>
4160
4161         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
4162         instead of 'expr' invocations.
4163         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
4164         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
4165         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
4166         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
4167         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
4168         Suggested by Paul Eggert.
4169
4170 2007-03-08  Bruno Haible  <bruno@clisp.org>
4171
4172         * modules/fseterr-tests: New file.
4173         * tests/test-fseterr.c: New file.
4174
4175         * modules/fseterr: New file.
4176         * lib/fseterr.h: New file.
4177         * lib/fseterr.c: New file.
4178
4179 2007-03-08  Bruno Haible  <bruno@clisp.org>
4180
4181         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
4182         * lib/getopt_.h: Likewise.
4183         * lib/mbswidth.h: Likewise.
4184         * lib/setenv.h: Likewise.
4185         * lib/vasnprintf.h: Likewise.
4186         * lib/vasprintf.h: Likewise.
4187         * lib/verror.h: Likewise.
4188         * lib/xsetenv.h: Likewise.
4189         * lib/xvasprintf.h: Likewise.
4190
4191 2007-03-08  Jim Meyering  <jim@meyering.net>
4192
4193         * users.txt: Add parted.
4194
4195         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
4196
4197 2007-03-07  Bruno Haible  <bruno@clisp.org>
4198
4199         * m4/printf.m4: Make the shell script snippets copy&pastable.
4200
4201 2007-03-02  Bruno Haible  <bruno@clisp.org>
4202
4203         * lib/netinet_in_.h: New file.
4204         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
4205         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
4206         * modules/netinet_in (Files): Add lib/netinet_in_.h.
4207         (Depends-on): Add absolute-header.
4208         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
4209         into netinet/in.h.
4210
4211 2007-03-03  Bruno Haible  <bruno@clisp.org>
4212
4213         * lib/sys_select_.h: New file.
4214         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
4215         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
4216         * modules/sys_select (Files): Add lib/sys_select_.h.
4217         (Depends-on): Add absolute-header.
4218         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
4219         into sys/select.h.
4220
4221 2007-03-02  Bruno Haible  <bruno@clisp.org>
4222
4223         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
4224         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
4225         values.
4226         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
4227         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
4228         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
4229         * modules/sys_socket (Depends-on): Add absolute-header.
4230         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
4231         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
4232         (Include): Remove requirement of inclusion of <sys/types.h>.
4233
4234 2007-03-02  Bruno Haible  <bruno@clisp.org>
4235
4236         * lib/byteswap_.h (bswap_32): Fix formula.
4237
4238 2007-03-06  Bruno Haible  <bruno@clisp.org>
4239
4240         * modules/sprintf-posix-tests: New file.
4241         * tests/test-sprintf-posix.c: New file.
4242
4243         * modules/sprintf-posix: New file.
4244         * lib/sprintf.c: New file.
4245         * m4/sprintf-posix.m4: New file.
4246         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
4247         REPLACE_SPRINTF.
4248         * lib/stdio_.h (sprintf): New declaration.
4249         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
4250         REPLACE_SPRINTF.
4251
4252 2007-03-06  Bruno Haible  <bruno@clisp.org>
4253
4254         * modules/vsprintf-posix-tests: New file.
4255         * tests/test-vsprintf-posix.c: New file.
4256         * tests/test-sprintf-posix.h: New file.
4257
4258         * modules/vsprintf-posix: New file.
4259         * lib/vsprintf.c: New file.
4260         * m4/vsprintf-posix.m4: New file.
4261         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
4262         REPLACE_VSPRINTF.
4263         * lib/stdio_.h (vsprintf): New declaration.
4264         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
4265         REPLACE_VSPRINTF.
4266
4267 2007-03-06  Bruno Haible  <bruno@clisp.org>
4268
4269         * modules/vsnprintf (Depend-on): Remove minmax.
4270
4271 2007-03-06  Bruno Haible  <bruno@clisp.org>
4272
4273         * modules/snprintf-posix-tests: New file.
4274         * tests/test-snprintf-posix.c: New file.
4275
4276         * modules/snprintf-posix: New file.
4277         * m4/snprintf-posix.m4: New file.
4278         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
4279         gl_FUNC_SNPRINTF.
4280         (gl_FUNC_SNPRINTF): Invoke it.
4281         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
4282         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
4283         is set.
4284         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
4285
4286 2007-03-06  Bruno Haible  <bruno@clisp.org>
4287
4288         * modules/vsnprintf-posix-tests: New file.
4289         * tests/test-vsnprintf-posix.c: New file.
4290         * tests/test-snprintf-posix.h: New file.
4291
4292         * modules/vsnprintf-posix: New file.
4293         * m4/vsnprintf-posix.m4: New file.
4294         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
4295         gl_FUNC_VSNPRINTF.
4296         (gl_FUNC_VSNPRINTF): Invoke it.
4297         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
4298         * lib/stdio_.h (vsnprintf): Define as a replacement if
4299         REPLACE_VSNPRINTF is set.
4300         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
4301
4302 2007-03-06  Bruno Haible  <bruno@clisp.org>
4303
4304         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
4305         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
4306
4307 2007-03-06  Bruno Haible  <bruno@clisp.org>
4308
4309         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
4310         (asinl): Declare also if HAVE_DECL_ASINL is set.
4311         (atanl): Declare also if HAVE_DECL_ATANL is set.
4312         (ceill): Declare also if HAVE_DECL_CEILL is set.
4313         (cosl): Declare also if HAVE_DECL_COSL is set.
4314         (expl): Declare also if HAVE_DECL_EXPL is set.
4315         (floorl): Declare also if HAVE_DECL_FLOORL is set.
4316         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
4317         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
4318         (logl): Declare also if HAVE_DECL_LOGL is set.
4319         (sinl): Declare also if HAVE_DECL_SINL is set.
4320         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
4321         (tanl): Declare also if HAVE_DECL_TANL is set.
4322         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
4323         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
4324         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
4325         declaration of frexpl, ldexpl.
4326         * modules/printf-frexpl (Depends-on): Add math.
4327         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
4328
4329 2007-03-05  Bruno Haible  <bruno@clisp.org>
4330
4331         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
4332         frexpl and ldexpl are declared.
4333         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
4334
4335 2007-03-05  Bruno Haible  <bruno@clisp.org>
4336
4337         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
4338         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
4339
4340 2007-03-05  Bruno Haible  <bruno@clisp.org>
4341
4342         * lib/stdio_.h: Include <stddef.h>.
4343
4344 2007-03-05  Bruno Haible  <bruno@clisp.org>
4345
4346         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
4347
4348 2007-03-05  Bruno Haible  <bruno@clisp.org>
4349
4350         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
4351         NetBSD 4, from Ralf Wildenhues.
4352
4353 2007-03-04  Bruno Haible  <bruno@clisp.org>
4354
4355         * lib/vasprintf.h: Update #if logic for the case when the functions
4356         exist but are overridden.
4357
4358 2007-03-04  Bruno Haible  <bruno@clisp.org>
4359
4360         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
4361         implementations: glibc-2.4 and MacOS X 10.3.
4362         * tests/test-vasnprintf-posix.c (test_function): Test also the case
4363         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
4364         * tests/test-vasprintf-posix.c (test_function): Likewise.
4365
4366 2007-03-04  Bruno Haible  <bruno@clisp.org>
4367
4368         * modules/vasprintf-posix-tests: New file.
4369         * tests/test-vasprintf-posix.c: New file.
4370
4371         * modules/vasprintf-posix: New file.
4372         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
4373         defined.
4374         * m4/vasprintf-posix.m4: New file.
4375         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
4376         gl_FUNC_VASPRINTF.
4377         (gl_FUNC_VASPRINTF): Invoke it.
4378         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
4379         here.
4380         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
4381
4382 2007-03-04  Bruno Haible  <bruno@clisp.org>
4383
4384         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
4385         REPLACE_GETTIMEOFDAY.
4386         * modules/sys_time (Makefile.am): Likewise.
4387         * m4/sys_time_h.m4: Likewise.
4388         * m4/gettimeofday.m4: Likewise.
4389
4390 2007-03-04  Bruno Haible  <bruno@clisp.org>
4391
4392         * modules/vasnprintf-posix-tests: New file.
4393         * tests/test-vasnprintf-posix.c: New file.
4394
4395         * modules/vasnprintf-posix: New file.
4396         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
4397         printf-frexpl.h.
4398         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
4399         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
4400         REPLACE_VASNPRINTF is defined.
4401         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
4402         gl_FUNC_VASNPRINTF.
4403         (gl_FUNC_VASNPRINTF): Invoke it.
4404         * m4/vasnprintf-posix.m4: New file.
4405         * m4/printf.m4: New file.
4406
4407 2007-03-04  Bruno Haible  <bruno@clisp.org>
4408
4409         Compile progreloc.c only if --enable-relocatable is specified.
4410         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
4411         if --enable-relocatable was specified.
4412         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
4413         lib_SOURCES.
4414
4415 2007-03-04  Jim Meyering  <jim@meyering.net>
4416
4417         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
4418         Use it consistently, rather than enumerating errno constants.
4419
4420 2007-03-04  Bruno Haible  <bruno@clisp.org>
4421
4422         * modules/xvasprintf-tests: New file.
4423         * tests/test-xvasprintf.c: New file.
4424
4425         * modules/vasprintf-tests: New file.
4426         * tests/test-vasprintf.c: New file.
4427
4428         * modules/vasnprintf-tests: New file.
4429         * tests/test-vasnprintf.c: New file.
4430
4431         * modules/vsnprintf-tests: New file.
4432         * tests/test-vsnprintf.c: New file.
4433
4434         * modules/snprintf-tests: New file.
4435         * tests/test-snprintf.c: New file.
4436
4437 2007-03-04  Bruno Haible  <bruno@clisp.org>
4438
4439         Compile relocatable.c only if --enable-relocatable is specified.
4440         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
4441         gl_RELOCATABLE_LIBRARY.
4442         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
4443         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
4444         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
4445         gl_RELOCATABLE_LIBRARY.
4446         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
4447         (Makefile.am): Remove lib_SOURCES.
4448         * modules/relocatable-lib-lgpl (configure.ac): Invoke
4449         gl_RELOCATABLE_LIBRARY.
4450         (Makefile.am): Remove lib_SOURCES.
4451         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
4452         always.
4453         * modules/relocatable-prog-wrapper (configure.ac): Invoke
4454         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
4455
4456 2007-03-04  Bruno Haible  <bruno@clisp.org>
4457
4458         * modules/argmatch-tests: New file.
4459         * tests/test-argmatch.c: New file.
4460
4461         * tests/test-allocsa.c (main): Halve the number of loop runs.
4462
4463         * modules/alloca-opt-tests: New file.
4464         * tests/test-alloca-opt.c: New file.
4465
4466 2007-03-04  Jim Meyering  <jim@meyering.net>
4467
4468         Work around difference between Linux ACLs and Solaris 10 ZFS.
4469         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
4470         for EINVAL.
4471
4472 2007-03-03  Bruno Haible  <bruno@clisp.org>
4473
4474         * modules/relocatable-prog (Depends-on): Add back progreloc's
4475         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
4476
4477 2007-03-03  Bruno Haible  <bruno@clisp.org>
4478
4479         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
4480         * modules/relocatable-lib: New file.
4481
4482 2007-03-03  Bruno Haible  <bruno@clisp.org>
4483
4484         * modules/relocatable-prog: Renamed from modules/relocatable.
4485         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
4486
4487 2007-03-03  Bruno Haible  <bruno@clisp.org>
4488
4489         * modules/relocatable-script (Files): Add doc/relocatable.texi,
4490         m4/relocatable-lib.m4.
4491         (Depends-on): Remove 'relocatable'.
4492         (configure.ac): Add gl_RELOCATABLE_NOP.
4493
4494 2007-03-03  Bruno Haible  <bruno@clisp.org>
4495
4496         * modules/relocatable-prog-wrapper: New file.
4497         * modules/relocatable (Depends-on): Add it. Remove all other
4498         dependencies except progname.
4499         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
4500
4501         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
4502         (gl_FUNC_STRERROR): Nop.
4503         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
4504
4505         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
4506         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
4507
4508         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
4509         (gl_FUNC_READLINK): Update.
4510
4511         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
4512
4513 2007-03-03  Bruno Haible  <bruno@clisp.org>
4514
4515         * lib/xreadlink.c: Include <unistd.h> unconditionally.
4516         * modules/xreadlink (Depends-on): Add unistd.
4517         * modules/xreadlink-with-size (Depends-on): Likewise.
4518
4519 2007-03-03  Bruno Haible  <bruno@clisp.org>
4520
4521         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
4522         extracted from gt_FUNC_SETENV.
4523         (gt_FUNC_SETENV): Remove macro.
4524         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
4525         remove gt_FUNC_SETENV.
4526
4527 2007-03-03  Bruno Haible  <bruno@clisp.org>
4528
4529         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
4530         ENABLE_RELOCATABLE here.
4531         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
4532
4533 2007-03-03  Bruno Haible  <bruno@clisp.org>
4534
4535         * modules/rbtreehash-list-tests (Depends-on): Add progname.
4536         * tests/test-rbtreehash_list.c: Include progname.h.
4537         (main): Call set_program_name.
4538
4539         * modules/rbtree-oset-tests (Depends-on): Add progname.
4540         * tests/test-rbtree_oset.c: Include progname.h.
4541         (main): Call set_program_name.
4542
4543         * modules/rbtree-list-tests (Depends-on): Add progname.
4544         * tests/test-rbtree_list.c: Include progname.h.
4545         (main): Call set_program_name.
4546
4547         * modules/linked-list-tests (Depends-on): Add progname.
4548         * tests/test-linked_list.c: Include progname.h.
4549         (main): Call set_program_name.
4550
4551 2007-03-03  Bruno Haible  <bruno@clisp.org>
4552
4553         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
4554         All uses of __restrict changed to _Restrict_.
4555         * lib/glob_.h (__restrict): Remove macro.
4556
4557 2007-03-02  Bruno Haible  <bruno@clisp.org>
4558
4559         * modules/gettext (configure.ac): Require gettext infrastructure
4560         from version 0.16.1.
4561
4562 2007-03-02  Bruno Haible  <bruno@clisp.org>
4563
4564         * modules/linkedhash-list-tests (Depends-on): Add progname.
4565         * tests/test-linkedhash_list.c: Include progname.h.
4566         (main): Call set_program_name.
4567
4568         * modules/carray-list-tests (Depends-on): Add progname.
4569         * tests/test-carray_list.c: Include progname.h.
4570         (main): Call set_program_name.
4571
4572         * modules/avltreehash-list-tests (Depends-on): Add progname.
4573         * tests/test-avltreehash_list.c: Include progname.h.
4574         (main): Call set_program_name.
4575
4576         * modules/avltree-oset-tests (Depends-on): Add progname.
4577         * tests/test-avltree_oset.c: Include progname.h.
4578         (main): Call set_program_name.
4579
4580         * modules/avltree-list-tests (Depends-on): Add progname.
4581         * tests/test-avltree_list.c: Include progname.h.
4582         (main): Call set_program_name.
4583
4584         * modules/array-oset-tests (Depends-on): Add progname.
4585         * tests/test-array_oset.c: Include progname.h.
4586         (main): Call set_program_name.
4587
4588         * modules/array-list-tests (Depends-on): Add progname.
4589         * tests/test-array_list.c: Include progname.h.
4590         (main): Call set_program_name.
4591
4592         * modules/argp-tests (Depends-on): Add progname.
4593         * tests/test-argp.c: Include argp.h first. Include progname.h.
4594         (main): Call set_program_name.
4595
4596 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
4597
4598         * doc/gnulib-tool.texi (Initial import): Reword description of
4599         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
4600         limited effect even if defined after the first system include.
4601
4602 2007-03-01  Bruno Haible  <bruno@clisp.org>
4603
4604         * build-aux/config.libpath: Update to libtool-1.5.22.
4605         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
4606
4607 2007-03-01  Bruno Haible  <bruno@clisp.org>
4608
4609         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
4610         foo_CFLAGS.
4611         Reported by Ralf Wildenhues.
4612
4613 2007-03-01  Bruno Haible  <bruno@clisp.org>
4614
4615         * build-aux/install-reloc: Remove object files left over by some
4616         compilers.
4617         Reported by Ralf Wildenhues.
4618
4619 2007-03-01  Bruno Haible  <bruno@clisp.org>
4620
4621         * build-aux/install-reloc: Break long lines.
4622
4623 2007-03-01  Bruno Haible  <bruno@clisp.org>
4624
4625         * doc/relocatable.texi: Document that it may not work on OpenBSD.
4626         Reported by Ralf Wildenhues.
4627
4628 2007-03-01  Bruno Haible  <bruno@clisp.org>
4629
4630         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
4631         include ordering constraints.
4632
4633 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
4634
4635         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
4636         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
4637         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
4638         as another example.
4639         * lib/time_.h: Fix misspelling.
4640         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4641         Require gl_HEADER_TIME_H_DEFAULTS.
4642         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
4643         * m4/time_r.m4 (gl_TIME_R): Likewise.
4644         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
4645
4646 2007-03-01  Bruno Haible  <bruno@clisp.org>
4647
4648         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
4649         * m4/utimens.m4 (gl_UTIMENS): Likewise.
4650
4651 2007-03-01  Jim Meyering  <jim@meyering.net>
4652
4653         * modules/xreadlink (Maintainer): Add my name.
4654         * modules/xreadlink-with-size (Depends-on): Alphabetize.
4655
4656 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
4657             Bruno Haible  <bruno@clisp.org>
4658
4659         * build-aux/install-reloc: Compile also c-ctype.c.
4660         * build-aux/relocatable.sh.in: New file.
4661         * doc/relocatable.texi: New file.
4662         * doc/relocatable-maint.texi: New file.
4663         * doc/gnulib.texi: Include relocatable-maint.texi.
4664         * lib/progreloc.c: Include unistd.h unconditionally.
4665         * lib/relocwrapper.c: Include unistd.h unconditionally.
4666         Include c-ctype.h.
4667         (add_dotbin): Use c_tolower.
4668         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
4669         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
4670         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
4671         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
4672         to m4/relocatable-lib.m4.
4673         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
4674         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
4675         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
4676         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
4677         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
4678         * modules/relocatable: New file.
4679         * modules/relocatable-lib: New file.
4680         * modules/relocatable-script: New file.
4681
4682 2007-02-28  Bruno Haible  <bruno@clisp.org>
4683
4684         Import --enable-relocatable infrastructure.
4685         * build-aux/config.libpath: New file, from GNU gettext.
4686         * build-aux/install-reloc: New file, from GNU gettext.
4687         * build-aux/reloc-ldflags: New file, from GNU gettext.
4688         * lib/relocatable.h: New file, from GNU gettext.
4689         * lib/relocatable.c: New file, from GNU gettext.
4690         * lib/relocwrapper.c: New file, from GNU gettext.
4691         * m4/relocatable.m4: New file, from GNU gettext.
4692
4693 2007-02-28  Bruno Haible  <bruno@clisp.org>
4694
4695         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
4696
4697         * modules/xreadlink: New file, from GNU gettext with modifications.
4698         * lib/xreadlink.c: New file, from GNU gettext.
4699         * lib/xreadlink.h: Add comments.
4700         (xreadlink): New declaration.
4701
4702         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
4703         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
4704         lib/xreadlink-with-size.c.
4705         (configure.ac): Remove gl_XREADLINK invocation.
4706         (Makefile.am): Augment lib_SOURCES.
4707         * m4/xreadlink.m4: Remove file.
4708         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
4709         (xreadlink_with_size): Renamed from xreadink.
4710         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
4711         * modules/canonicalize (Depends-on): Replace xreadlink with
4712         xreadlink-with-size.
4713         * lib/canonicalize.c (canonicalize_filename_mode): Update.
4714
4715 2007-02-25  Jim Meyering  <jim@meyering.net>
4716
4717         * build-aux/announce-gen: When complaining about excess arguments,
4718         list them.
4719
4720 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
4721
4722         * README: Document signed integer overflow situation more
4723         accurately.
4724
4725 2007-02-25  Bruno Haible  <bruno@clisp.org>
4726
4727         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
4728         'a' or 'A' conversion.
4729
4730 2007-02-25  Bruno Haible  <bruno@clisp.org>
4731
4732         * modules/filename: Renamed from modules/pathname.
4733         (Files): Replace lib/pathname.h with lib/filename.h. Replace
4734         lib/concatpath.c with lib/concat-filename.c.
4735         (Makefile.am): Update.
4736         (Include): Replace pathname.h with filename.h.
4737         * lib/filename.h: Renamed from lib/pathname.h.
4738         (concatenated_filename): Renamed from concatenated_pathname.
4739         * lib/concat-filename.c: Renamed from lib/concatpath.c.
4740         (concatenated_filename): Renamed from concatenated_pathname.
4741         * lib/findprog.c: Include filename.h instead of pathname.h.
4742         (find_in_path): Update.
4743         * lib/javacomp.c: Include filename.h instead of pathname.h.
4744         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
4745         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
4746         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
4747         is_oldgcj_14_13_usable, is_javac_usable): Update.
4748         * lib/javaexec.c: Include filename.h instead of pathname.h.
4749         (execute_java_class): Update.
4750         * modules/findprog: Update.
4751         * modules/javacomp: Update.
4752         * modules/javaexec: Update.
4753         * MODULES.html.sh (File system functions): Add 'filename', remove
4754         'pathname'.
4755
4756 2007-02-25  Bruno Haible  <bruno@clisp.org>
4757
4758         * modules/printf-frexpl-tests: New file.
4759         * tests/test-printf-frexpl.c: New file.
4760
4761         * modules/printf-frexpl: New file.
4762         * lib/printf-frexpl.h: New file.
4763         * lib/printf-frexpl.c: New file.
4764         * m4/printf-frexpl.m4: New file.
4765
4766 2007-02-25  Bruno Haible  <bruno@clisp.org>
4767
4768         * modules/printf-frexp-tests: New file.
4769         * tests/test-printf-frexp.c: New file.
4770
4771         * modules/printf-frexp: New file.
4772         * lib/printf-frexp.h: New file.
4773         * lib/printf-frexp.c: New file.
4774         * m4/printf-frexp.m4: New file.
4775
4776 2007-02-25  Bruno Haible  <bruno@clisp.org>
4777
4778         Assume automake >= 1.10 for the tests.
4779         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
4780         * modules/arctwo-tests: Likewise.
4781         * modules/argp-tests: Likewise.
4782         * modules/avltree-list-tests: Likewise.
4783         * modules/avltree-oset-tests: Likewise.
4784         * modules/avltreehash-list-tests: Likewise.
4785         * modules/carray-list-tests: Likewise.
4786         * modules/crc-tests: Likewise.
4787         * modules/des-tests: Likewise.
4788         * modules/gc-arcfour-tests: Likewise.
4789         * modules/gc-arctwo-tests: Likewise.
4790         * modules/gc-des-tests: Likewise.
4791         * modules/gc-hmac-md5-tests: Likewise.
4792         * modules/gc-hmac-sha1-tests: Likewise.
4793         * modules/gc-md2-tests: Likewise.
4794         * modules/gc-md4-tests: Likewise.
4795         * modules/gc-md5-tests: Likewise.
4796         * modules/gc-pbkdf2-sha1-tests: Likewise.
4797         * modules/gc-rijndael-tests: Likewise.
4798         * modules/gc-sha1-tests: Likewise.
4799         * modules/gc-tests: Likewise.
4800         * modules/getaddrinfo-tests: Likewise.
4801         * modules/hmac-md5-tests: Likewise.
4802         * modules/hmac-sha1-tests: Likewise.
4803         * modules/linked-list-tests: Likewise.
4804         * modules/linkedhash-list-tests: Likewise.
4805         * modules/lock-tests: Likewise.
4806         * modules/md2-tests: Likewise.
4807         * modules/md4-tests: Likewise.
4808         * modules/md5-tests: Likewise.
4809         * modules/rbtree-list-tests: Likewise.
4810         * modules/rbtree-oset-tests: Likewise.
4811         * modules/rbtreehash-list-tests: Likewise.
4812         * modules/read-file-tests: Likewise.
4813         * modules/rijndael-tests: Likewise.
4814         * modules/stdint-tests: Likewise.
4815         * modules/tls-tests: Likewise.
4816
4817 2007-02-24  Bruno Haible  <bruno@clisp.org>
4818
4819         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
4820         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
4821         function; instead check whether isnan with a double argument links.
4822         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
4823         function; instead check whether isnan with a 'long double' argument
4824         links.
4825         Reported by Eric Blake <ebb9@byu.net>.
4826
4827 2007-02-24  Bruno Haible  <bruno@clisp.org>
4828
4829         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
4830         defined.
4831         * lib/isnanl.c: Remove all code. Just include isnan.c.
4832         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
4833
4834 2007-02-25  Jim Meyering  <jim@meyering.net>
4835
4836         Avoid conflicting types for 'unsetenv' on FreeBSD.
4837         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
4838         conflicting with FreeBSD's (5.0 and 6.1) function declaration
4839         in stdlib.h.
4840
4841 2007-02-24  Bruno Haible  <bruno@clisp.org>
4842
4843         * modules/isnanl-nolibm-tests: New file.
4844         * tests/test-isnanl.c: New file.
4845
4846         * modules/isnanl-nolibm: New file.
4847         * lib/isnanl.h: New file.
4848         * lib/isnanl.c: New file.
4849         * m4/isnanl.m4: New file.
4850
4851 2007-02-24  Bruno Haible  <bruno@clisp.org>
4852
4853         * modules/isnan-nolibm-tests: New file.
4854         * tests/test-isnan.c: New file.
4855
4856         * modules/isnan-nolibm: New file.
4857         * lib/isnan.h: New file.
4858         * lib/isnan.c: New file.
4859         * m4/isnan.m4: New file.
4860
4861 2007-02-24  Bruno Haible  <bruno@clisp.org>
4862
4863         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
4864         assume that an exponent fits in 20 bits.
4865
4866 2007-02-24  Jim Meyering  <jim@meyering.net>
4867
4868         * m4/regex.m4: Update the description of the configure-time option,
4869         --without-included-regex, to state accurately what the defaults are,
4870         and perhaps to give people an idea why using this option is risky.
4871
4872 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
4873
4874         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
4875         loops on small arguments.  This attempts to avoid the problem
4876         Bruno Haible reported for AIX 4.3.2 in
4877         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
4878
4879 2007-02-23  Bruno Haible  <bruno@clisp.org>
4880
4881         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
4882         Needed for help2man.
4883
4884 2007-02-23  Karl Berry  <karl@gnu.org>
4885
4886         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
4887         exists, foo.h should be cvs-ignored, not committed.
4888
4889 2007-02-23  Eric Blake  <ebb9@byu.net>
4890
4891         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
4892         * lib/stat-time.h (includes): Likewise.
4893         * lib/utimecmp.c (includes): Likewise.
4894         * lib/utimens.h (includes): Likewise.
4895         * lib/getdate.y (includes): Also include "timespec.h" for use
4896         internal to the module.
4897         * modules/utimens (Depends-on): Revert yesterday's patch.
4898         * modules/nanosleep (Depends-on): Add missing dependency.
4899
4900 2007-02-22  Bruno Haible  <bruno@clisp.org>
4901
4902         * lib/glob.c: Don't include getlogin_r.h.
4903
4904 2007-02-22  Jim Meyering  <jim@meyering.net>
4905
4906         * modules/utimens (Depends-on): Add timespec, required for
4907         utimens.h's inclusion of timespec.h.
4908
4909 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
4910
4911         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
4912         long unreadable paths in GNU/Linux.  Problem reported by Andreas
4913         Schwab in
4914         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
4915         I'll try to think of a better way to fix the Solaris problem.
4916
4917         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
4918         like glibc; on Solaris 10, it fails with errno == EINVAL.
4919         POSIX says the behavior is unspecified if the first argument is NULL,
4920         so play it safe and never pass NULL to the system getcwd.
4921
4922 2007-02-21  Jim Meyering  <jim@meyering.net>
4923
4924         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
4925         of gettimeofday.  It would conflict with the one now always
4926         provided via sys_time_.h.  Reported by Matthew Woehlke, as
4927         an IRIX 6.5 build failure.
4928
4929 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
4930
4931         Minor fixups to port to Solaris 10 with Sun C 5.8.
4932         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
4933         * modules/getcwd (Depends-on): Add dirfd.
4934         * lib/putenv.c (putenv): #undef it.
4935         (rpl_putenv): New decl.
4936         (malloc, free): Include <stdlib.h> rather than prototyping separately.
4937
4938 2007-02-20  Bruno Haible  <bruno@clisp.org>
4939
4940         * modules/stdio-tests: New file.
4941         * tests/test-stdio.c: New file.
4942
4943         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
4944         (Depends-on): Add stdio.
4945         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
4946         (Include): Use <stdio.h> instead of vsnprintf.h.
4947         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
4948         HAVE_DECL_VSNPRINTF.
4949         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
4950
4951         * modules/snprintf (Files): Remove lib/snprintf.h.
4952         (Depends-on): Add stdio.
4953         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
4954         (Include): Use <stdio.h> instead of snprintf.h.
4955         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
4956         HAVE_DECL_SNPRINTF.
4957         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
4958         * lib/getaddrinfo.c: Likewise.
4959
4960         * modules/stdio: New file.
4961         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
4962         * lib/snprintf.h: Remove file.
4963         * lib/vsnprintf.h: Remove file.
4964         * lib/.cppi-disable: Remove snprintf.h.
4965         * m4/stdio_h.m4: New file.
4966         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
4967
4968 2007-02-20  Jim Meyering  <jim@meyering.net>
4969
4970         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
4971         used by e.g., mingw.  From Bruno Haible.
4972
4973 2007-02-19  Bruno Haible  <bruno@clisp.org>
4974
4975         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
4976         warnings.
4977         Reported by Ben Pfaff <blp@cs.stanford.edu>.
4978
4979 2007-02-19  Bruno Haible  <bruno@clisp.org>
4980
4981         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
4982         from mingw users.
4983
4984 2007-02-19  Bruno Haible  <bruno@clisp.org>
4985
4986         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
4987         warnings.
4988         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
4989
4990 2007-02-19  Jim Meyering  <jim@meyering.net>
4991
4992         Don't use FD after a successful "fdopendir (fd)".
4993         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
4994         Reset it by calling dirfd on the just-obtained DIR*.
4995
4996         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
4997         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
4998
4999 2007-02-18  Bruno Haible  <bruno@clisp.org>
5000
5001         * lib/readlink.c: Include <unistd.h>.
5002         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
5003         HAVE_READLINK.
5004         * modules/readlink (Depends-on): Add unistd.
5005         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5006         (Include): Add <unistd.h>.
5007
5008         * lib/getlogin_r.h: Remove file.
5009         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
5010         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
5011         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
5012         HAVE_DECL_GETLOGIN_R.
5013         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
5014         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5015         (Include): Use <unistd.h> instead of getlogin_r.h.
5016
5017         * lib/getcwd.h: Remove file.
5018         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
5019         * lib/xgetcwd.c: Likewise.
5020         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
5021         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
5022         * modules/getcwd (Files): Remove lib/getcwd.h.
5023         (Depends-on): Add unistd.
5024         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5025         (Include): Use <unistd.h> instad of getcwd.h.
5026
5027         * lib/ftruncate.c: Include <unistd.h> first.
5028         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
5029         Set HAVE_FTRUNCATE.
5030         * modules/ftruncate (Depends-on): Add unistd.
5031         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5032
5033         * lib/fchdir.c: Include <unistd.h> first.
5034         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
5035         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
5036         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
5037         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5038         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
5039
5040         * lib/dup2.c: Include <unistd.h> first.
5041         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
5042         HAVE_DUP2.
5043         * modules/dup2 (Depends-on): Add unistd.
5044         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5045
5046         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
5047         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
5048         REPLACE_CHOWN. Don't define chown as a macro here.
5049         * modules/chown (Depends-on): Add unistd.
5050         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5051
5052         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
5053         Add definition for GL_LINK_WARNING.
5054         (chown, dup2): New declarations.
5055         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
5056         link warning.
5057         (ftruncate): New declaration.
5058         (getcwd): New declaration, taken from old getcwd.h.
5059         (getlogin_r): New declaration, taken from old getlogin_r.h.
5060         (readlink): New declaration.
5061         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
5062         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
5063         (gl_PREREQ_UNISTD): Remove macro.
5064         (gl_UNISTD_MODULE_INDICATOR): New macro.
5065         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
5066         many new variables. Don't set UNISTD_H.
5067         * modules/unistd (Description): Change.
5068         (Depends-on): Add link-warning.
5069         (configure.ac): Update.
5070         (Makefile.am): Create unistd.h always. Substitute many new variables
5071         into it.
5072
5073 2007-02-18  Bruno Haible  <bruno@clisp.org>
5074
5075         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
5076         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
5077         HAVE_GETSUBOPT.
5078         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
5079         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
5080         * lib/getsubopt.h: Remove file.
5081         * modules/getsubopt (Files): Remove lib/getsubopt.h.
5082         (Depends-on): Add stdlib.
5083         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5084         (Includes): Use <stdlib.h> instead of getsubopt.h.
5085         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
5086         Set HAVE_GETSUBOPT.
5087         * lib/getsubopt.c: Don't include getsubopt.h.
5088
5089 2007-02-18  Bruno Haible  <bruno@clisp.org>
5090
5091         * modules/fchdir (Depends-on): Add dup2.
5092
5093 2007-02-18  Bruno Haible  <bruno@clisp.org>
5094
5095         * lib/stdlib_.h: Handle glibc's special invocation convention
5096         specially.
5097
5098 2007-02-18  Bruno Haible  <bruno@clisp.org>
5099
5100         * modules/stdlib-tests: New file.
5101         * tests/test-stdlib.c: New file.
5102
5103         * modules/mkstemp (Files): Remove lib/mkstemp.h.
5104         (Depends-on): Add stdlib.
5105         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5106         (Includes): Use <stdlib.h> instead of mkstemp.h.
5107         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5108         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
5109         * lib/mkstemp.c: Don't include mkstemp.h.
5110         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
5111         * lib/stdlib--.h: Don't include mkstemp.h.
5112
5113         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
5114         (Depends-on): Add stdlib.
5115         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5116         (Includes): Use <stdlib.h> instead of mkdtemp.h.
5117         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5118         HAVE_MKDTEMP.
5119         * lib/mkdtemp.c: Don't include mkdtemp.h.
5120         * lib/clean-temp.c: Don't include mkdtemp.h.
5121
5122         * modules/exit (Files): Remove lib/exit.h.
5123         (Depends-on): Add stdlib.
5124         (Makefile.am): Remove lib_SOURCES.
5125         (Include): Use <stdlib.h> instead of exit.h.
5126         * lib/argmatch.c: Don't include exit.h.
5127         * lib/execute.c: Likewise.
5128         * lib/pagealign_alloc.c: Likewise.
5129         * lib/pipe.c: Likewise.
5130         * lib/wait-process.c: Likewise.
5131         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
5132         * lib/exitfail.c: Likewise.
5133         * lib/savewd.c: Likewise.
5134         * lib/xsetenv.c: Likewise.
5135
5136         * modules/stdlib: New file.
5137         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
5138         and extra comments about mkstemp().
5139         * lib/exit.h: Remove file.
5140         * lib/mkdtemp.h: Remove file.
5141         * lib/mkstemp.h: Remove file.
5142         * m4/stdlib_h.m4: New file.
5143         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
5144
5145 2007-02-18  Bruno Haible  <bruno@clisp.org>
5146
5147         * modules/math-tests: New file.
5148         * tests/test-math.c: New file.
5149
5150         * modules/math: New file.
5151         * modules/mathl (Files): Remove lib/mathl.h.
5152         (Depends-on): Add math.
5153         (Makefile.am): Don't mention mathl.h.
5154         (Include): Use <math.h> instead of mathl.h.
5155         * lib/math_.h: New file.
5156         * lib/mathl.h: Remove file.
5157         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
5158         mathl.h.
5159         * lib/asinl.c: Likewise.
5160         * lib/atanl.c: Likewise.
5161         * lib/ceill.c: Likewise.
5162         * lib/cosl.c: Likewise.
5163         * lib/expl.c: Likewise.
5164         * lib/floorl.c: Likewise.
5165         * lib/frexpl.c: Likewise.
5166         * lib/ldexpl.c: Likewise.
5167         * lib/logl.c: Likewise.
5168         * lib/sincosl.c: Likewise.
5169         * lib/sinl.c: Likewise.
5170         * lib/sqrtl.c: Likewise.
5171         * lib/tanl.c: Likewise.
5172         * lib/trigl.c: Likewise.
5173         * m4/math_h.m4: New file.
5174         * MODULES.html.sh (Mathematics): Add math.
5175
5176 2007-02-17  Bruno Haible  <bruno@clisp.org>
5177
5178         * modules/wctype-tests: New file.
5179         * tests/test-wctype.c: New file.
5180
5181         * modules/wchar-tests: New file.
5182         * tests/test-wchar.c: New file.
5183
5184         * modules/unistd-tests: New file.
5185         * tests/test-unistd.c: New file.
5186
5187         * modules/time-tests: New file.
5188         * tests/test-time.c: New file.
5189
5190         * modules/sysexits-tests: New file.
5191         * tests/test-sysexits.c: New file.
5192
5193         * modules/sys_time-tests: New file.
5194         * tests/test-sys_time.c: New file.
5195
5196         * modules/sys_stat-tests: New file.
5197         * tests/test-sys_stat.c: New file.
5198
5199         * modules/sys_socket-tests: New file.
5200         * tests/test-sys_socket.c: New file.
5201
5202         * modules/sys_select-tests: New file.
5203         * tests/test-sys_select.c: New file.
5204
5205         * modules/string-tests: New file.
5206         * tests/test-string.c: New file.
5207
5208         * modules/stdbool-tests: New file.
5209         * tests/test-stdbool.c: New file.
5210
5211         * modules/netinet_in-tests: New file.
5212         * tests/test-netinet_in.c: New file.
5213
5214         * modules/inttypes-tests: New file.
5215         * tests/test-inttypes.c: New file.
5216
5217         * modules/fcntl-tests: New file.
5218         * tests/test-fcntl.c: New file.
5219
5220         * modules/byteswap-tests: New file.
5221         * tests/test-byteswap.c: New file.
5222
5223         * modules/arpa_inet-tests: New file.
5224         * tests/test-arpa_inet.c: New file.
5225
5226 2007-02-17  Bruno Haible  <bruno@clisp.org>
5227
5228         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
5229         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
5230         if the corresponding module is not enabled. Emit link warnings if
5231         the function is used nevertheless.
5232         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
5233         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
5234         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
5235         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
5236         * modules/inttypes (Depends-on): Add link-warning.
5237         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5238         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
5239         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
5240         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
5241         * modules/imaxdiv (configure.ac): Likewise.
5242         * modules/strtoimax (configure.ac): Likewise.
5243         * modules/strtoumax (configure.ac): Likewise.
5244
5245 2007-02-17  Bruno Haible  <bruno@clisp.org>
5246
5247         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
5248         gl_STRING_MODULE_INDICATOR_DEFAULTS.
5249         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
5250         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
5251
5252 2007-02-17  Bruno Haible  <bruno@clisp.org>
5253
5254         * modules/link-warning: New file.
5255         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
5256         * lib/string_.h (GL_LINK_WARNING): Remove definition.
5257         * modules/string (Depends-on): Add link-warning.
5258         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5259         string.h.
5260         * MODULES.html.sh (Support for building libraries and executables): Add
5261         link-warning.
5262
5263 2007-02-17  Bruno Haible  <bruno@clisp.org>
5264
5265         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
5266         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
5267         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
5268         long lines.
5269
5270 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
5271             Bruno Haible  <bruno@clisp.org>
5272
5273         * modules/tmpfile: New file.
5274         * lib/tmpfile.c: New file.
5275         * m4/tmpfile.m4: New file.
5276         * MODULES.html.sh (func_all_modules): New section "Input/output".
5277
5278 2007-02-15  Bruno Haible  <bruno@clisp.org>
5279
5280         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
5281         (supports_delete_on_close): New function.
5282         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
5283
5284 2007-02-14  Bruno Haible  <bruno@clisp.org>
5285
5286         * modules/mbspcasecmp-tests: New file.
5287         * tests/test-mbspcasecmp.sh: New file.
5288         * tests/test-mbspcasecmp.c: New file.
5289
5290         New module mbspcasecmp.
5291         * modules/mbspcasecmp: New file.
5292         * lib/mbspcasecmp.c: New file.
5293         * lib/string_.h (strncasecmp): Change warning message.
5294         (mbspcasecmp): New declaration.
5295         * m4/mbspcasecmp.m4: New file.
5296         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5297         GNULIB_MBSPCASECMP.
5298         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
5299         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
5300
5301 2007-02-14  Bruno Haible  <bruno@clisp.org>
5302
5303         * modules/mbsncasecmp-tests: New file.
5304         * tests/test-mbsncasecmp.sh: New file.
5305         * tests/test-mbsncasecmp.c: New file.
5306
5307         New module mbsncasecmp.
5308         * modules/mbsncasecmp: New file.
5309         * lib/mbsncasecmp.c: New file.
5310         * lib/string_.h (mbsncasecmp): New declaration.
5311         * m4/mbsncasecmp.m4: New file.
5312         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5313         GNULIB_MBSNCASECMP.
5314         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
5315         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
5316
5317 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
5318
5319         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
5320         Verify that it doesn't overlap with our flags.
5321         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
5322         do not have the desired effect in multibyte locales; instead, use
5323         mbscasecmp.
5324         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
5325         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
5326         we don't require GNU fnmatch ourselves (if our users require it, they
5327         should do so explicitly).
5328
5329         Fix regex code so it doesn't rely on strcasecmp.
5330         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
5331         Otherwise, include gnulib's langinfo.h.
5332         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
5333         undesirable behavior in non-C locales.  Instead, rely on localecharset.
5334         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
5335         * modules/regex (FILES): Remove m4/codeset.m4.
5336         (Depends-on): Add localcharset.  Remove strcase.
5337
5338 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5339
5340         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
5341         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
5342
5343 2007-02-13  Bruno Haible  <bruno@clisp.org>
5344
5345         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
5346         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5347
5348 2007-02-12  Bruno Haible  <bruno@clisp.org>
5349
5350         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
5351         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
5352         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
5353         time warning rather than a link error.
5354
5355 2007-02-12  Bruno Haible  <bruno@clisp.org>
5356
5357         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
5358         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
5359         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5360
5361 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5362
5363         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
5364         args, not 2.
5365
5366 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5367
5368         New module 'time', so that apps can include <time.h> as per
5369         POSIX and GNU instead of separate include files like time_r.h
5370         and timegm.h.  This implementation tries out a simpler approach
5371         for replacing decls in standard include files (as compared to
5372         the string module), somewhat as an experiment.
5373
5374         * config/srclist.txt: Comment out mktime.c for now.
5375         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
5376         since it doesn't apply any more.  Use generic wording instead.
5377         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
5378         'time'.
5379         * lib/time_.h, m4/time_h.m4, modules/time: New files.
5380         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
5381         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
5382         Don't include <sys/types.h>; no longer needed since we assume C89.
5383         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
5384         * lib/strftime.c: Likewise.
5385         * lib/time_r.c: Likewise.
5386         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
5387         * lib/nanosleep.c: Include <time.h> first, to check interface.
5388         * lib/strptime.c: Likewise.
5389         * lib/time_r.c: Likewise.
5390         * lib/timegm.c: Likewise.
5391         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
5392         needed.
5393         * lib/timegm.c: Don't include timegm.h; no longer needed.
5394         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
5395         time.h now handles any problems in that area.
5396         (struct timespec, nanosleep): Remove; time.h now arranges for these.
5397         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
5398         that time.h defines struct timespec.
5399         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
5400         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
5401         handles that.
5402         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
5403         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
5404         needed.  Set REPLACE_LOCALTIME.
5405         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
5406         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
5407         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
5408         nanosleep; time_h.m4 now does that.  Don't require
5409         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
5410         module handles this now.
5411         * modules/getdate (Depends-on): Remove timespec.  Add time.
5412         * modules/nanosleep (Depends-on): Likewise.
5413         * modules/stat-time (Depends-on): Likewise.
5414         * modules/nanosleep (Include): Include time.h, not timespec.h.
5415         * modules/strptime (Files): Remove lib/strptime.h.
5416         (Depends-on): Add extensions, time.
5417         (Include): Include time.h, not strptime.h.
5418         * modules/time_r (Files): Remove lib/time_r.h.
5419         (Depends-on): Add time.
5420         (Include): Include time.h, not time_r.h.
5421         * modules/timegm: Likewise.
5422         * modules/timespec (Description): Now does timespec-related decls
5423         of our own, instead of struct timespec itself.
5424         (Depends-on): Add time; remove extensions.
5425         (Maintainer): Add self.
5426         * modules/utimecmp (Depends-on): Add time; remove timespec.
5427         * modules/utimens (Depends-on): Likewise.
5428         * modules/xnanosleep (Depends-on): Likewise.
5429
5430 2007-02-11  Bruno Haible  <bruno@clisp.org>
5431
5432         * lib/c-strstr.c: Include allocsa.h.
5433         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5434         * lib/c-strcasestr.c: Include allocsa.h.
5435         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5436         * lib/strcasestr.c: Include allocsa.h.
5437         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5438         * lib/mbsstr.c: Include allocsa.h.
5439         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5440         allocsa/freesa instead of malloc/free.
5441         * lib/mbscasestr.c: Include allocsa.h.
5442         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5443         allocsa/freesa instead of malloc/free.
5444         * modules/c-strstr (Depends-on): Add allocsa.
5445         * modules/c-strcasestr (Depends-on): Likewise.
5446         * modules/strcasestr (Depends-on): Likewise.
5447         * modules/mbsstr (Depends-on): Likewise.
5448         * modules/mbscasestr (Depends-on): Likewise.
5449
5450 2007-02-11  Bruno Haible  <bruno@clisp.org>
5451
5452         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
5453
5454         * modules/mbsspn-tests: New file.
5455         * tests/test-mbsspn.sh: New file.
5456         * tests/test-mbsspn.c: New file.
5457
5458 2007-02-11  Bruno Haible  <bruno@clisp.org>
5459
5460         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
5461
5462         * modules/mbspbrk-tests: New file.
5463         * tests/test-mbspbrk.sh: New file.
5464         * tests/test-mbspbrk.c: New file.
5465
5466 2007-02-11  Bruno Haible  <bruno@clisp.org>
5467
5468         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
5469         unneeded cast.
5470
5471         * modules/mbscspn-tests: New file.
5472         * tests/test-mbscspn.sh: New file.
5473         * tests/test-mbscspn.c: New file.
5474
5475 2007-02-11  Bruno Haible  <bruno@clisp.org>
5476
5477         * modules/mbscasecmp-tests: New file.
5478         * tests/test-mbscasecmp.sh: New file.
5479         * tests/test-mbscasecmp.c: New file.
5480
5481 2007-02-11  Bruno Haible  <bruno@clisp.org>
5482
5483         Ensure O(n) worst-case complexity of mbscasestr.
5484         * lib/mbscasestr.c: Include stdbool.h.
5485         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5486         functions.
5487         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
5488         the bookkeeping indicates that it's worth it.
5489         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
5490
5491         * modules/mbscasestr-tests: New file.
5492         * tests/test-mbscasestr1.c: New file.
5493         * tests/test-mbscasestr2.sh: New file.
5494         * tests/test-mbscasestr2.c: New file.
5495         * tests/test-mbscasestr3.sh: New file.
5496         * tests/test-mbscasestr3.c: New file.
5497         * tests/test-mbscasestr4.sh: New file.
5498         * tests/test-mbscasestr4.c: New file.
5499         * m4/locale-tr.m4: New file.
5500
5501 2007-02-11  Bruno Haible  <bruno@clisp.org>
5502
5503         Ensure O(n) worst-case complexity of mbsstr.
5504         * lib/mbsstr.c: Include stdbool.h.
5505         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5506         functions.
5507         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
5508         bookkeeping indicates that it's worth it.
5509         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
5510
5511         * modules/mbsstr-tests: New file.
5512         * tests/test-mbsstr1.c: New file.
5513         * tests/test-mbsstr2.sh: New file.
5514         * tests/test-mbsstr2.c: New file.
5515         * tests/test-mbsstr3.sh: New file.
5516         * tests/test-mbsstr3.c: New file.
5517         * m4/locale-fr.m4: New file.
5518
5519 2007-02-11  Bruno Haible  <bruno@clisp.org>
5520
5521         * lib/mbsrchr.c (mbsrchr): Fix bug.
5522
5523         * modules/mbsrchr-tests: New file.
5524         * tests/test-mbsrchr.sh: New file.
5525         * tests/test-mbsrchr.c: New file.
5526
5527 2007-02-11  Bruno Haible  <bruno@clisp.org>
5528
5529         * lib/mbschr.c (mbschr): Fix bug.
5530
5531         * modules/mbschr-tests: New file.
5532         * tests/test-mbschr.sh: New file.
5533         * tests/test-mbschr.c: New file.
5534         * m4/locale-zh.m4: New file.
5535
5536 2007-02-11  Bruno Haible  <bruno@clisp.org>
5537
5538         Support for copying multibyte string iterators.
5539         * lib/mbiter.h: Include <string.h>.
5540         (mbiter_multi_copy): New function.
5541         (mbi_copy): New macro.
5542         * lib/mbuiter.h: Include <string.h>.
5543         (mbuiter_multi_copy): New function.
5544         (mbui_copy): New macro.
5545
5546 2007-02-11  Bruno Haible  <bruno@clisp.org>
5547
5548         New module mbslen.
5549         * modules/mbslen: New file.
5550         * lib/mbslen.c: New file.
5551         * lib/string_.h (mbslen): New declaration.
5552         * m4/mbslen.m4: New file.
5553         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5554         GNULIB_MBSLEN.
5555         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
5556         * MODULES.html.sh (Internationalization functions): Add mbslen.
5557
5558 2007-02-11  Bruno Haible  <bruno@clisp.org>
5559
5560         Ensure O(n) worst-case complexity of strcasestr substitute.
5561         * lib/strcasestr.c: Include stdbool.h.
5562         (knuth_morris_pratt): New function.
5563         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
5564         bookkeeping indicates that it's worth it.
5565         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
5566
5567         * modules/strcasestr-tests: New file.
5568         * tests/test-strcasestr.c: New file.
5569
5570 2007-02-11  Bruno Haible  <bruno@clisp.org>
5571
5572         Ensure O(n) worst-case complexity of c_strcasestr.
5573         * lib/c-strcasestr.c: Include stdbool.h, string.h.
5574         (knuth_morris_pratt): New function.
5575         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
5576         the bookkeeping indicates that it's worth it.
5577         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
5578
5579         * modules/c-strcasestr-tests: New file.
5580         * tests/test-c-strcasestr.c: New file.
5581
5582 2007-02-11  Bruno Haible  <bruno@clisp.org>
5583
5584         Ensure O(n) worst-case complexity of c_strstr.
5585         * lib/c-strstr.c: Include stdbool.h, string.h.
5586         (knuth_morris_pratt): New function.
5587         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
5588         bookkeeping indicates that it's worth it.
5589         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
5590
5591         * lib/c-strstr.c: Complete rewrite for maintainability.
5592
5593         * modules/c-strstr-tests: New file.
5594         * tests/test-c-strstr.c: New file.
5595
5596 2007-02-11  Bruno Haible  <bruno@clisp.org>
5597
5598         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
5599         5.2.1 and earlier, whereby \055 was treated just like the range
5600         delimiter '-'.
5601         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
5602
5603 2007-02-08  Bruno Haible  <bruno@clisp.org>
5604
5605         * modules/regex (Depends-on): Add stdbool.
5606         Reported by Dalibor Topic <robilad@kaffe.org>.
5607
5608 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
5609
5610         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
5611         Prefer returning from main to exiting from it.
5612         Remove unnecessary parens after sizeof.
5613
5614 2007-02-05  Bruno Haible  <bruno@clisp.org>
5615
5616         New module mbssep.
5617         * modules/mbssep: New file.
5618         * lib/mbssep.c: New file.
5619         * lib/string_.h (strsep): Add a conditional link warning.
5620         (mbssep): New declaration.
5621         * m4/mbssep.m4: New file.
5622         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5623         GNULIB_MBSSEP.
5624         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
5625         * MODULES.html.sh (Internationalization functions): Add mbssep.
5626
5627 2007-02-05  Bruno Haible  <bruno@clisp.org>
5628
5629         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
5630         Optimize search in case of 1 delimiter.
5631
5632 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
5633
5634         * lib/acl.h: Include sys/types.h before sys/acl.h.
5635
5636 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
5637
5638         Merge upstream fix for glibc bugzilla #3957:
5639
5640         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
5641
5642         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
5643         bit for RE_HAT_LISTS_NOT_NEWLINE.
5644         (build_charclass_op): Remove bogus comment.
5645
5646 2007-02-05  Simon Josefsson  <simon@josefsson.org>
5647
5648         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
5649
5650 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
5651
5652         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
5653         * lib/memmem.c [!defined _LIBC]: Include config.h.
5654
5655 2007-02-04  Bruno Haible  <bruno@clisp.org>
5656
5657         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
5658         warning message.
5659
5660 2007-02-04  Bruno Haible  <bruno@clisp.org>
5661
5662         New module mbstok_r.
5663         * modules/mbstok_r: New file.
5664         * lib/mbstok_r.c: New file.
5665         * lib/string_.h (strtok_r): Change argument names to match the
5666         comments. Add a conditional link warning.
5667         (mbstok_r): New declaration.
5668         * m4/mbstok_r.m4: New file.
5669         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5670         GNULIB_MBSTOK_R.
5671         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
5672         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
5673
5674 2007-02-04  Bruno Haible  <bruno@clisp.org>
5675
5676         New module mbsspn.
5677         * modules/mbsspn: New file.
5678         * lib/mbsspn.c: New file.
5679         * lib/string_.h (strspn): Add a conditional link warning.
5680         (mbsspn): New declaration.
5681         * m4/mbsspn.m4: New file.
5682         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5683         GNULIB_MBSSPN.
5684         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
5685         * MODULES.html.sh (Internationalization functions): Add mbsspn.
5686
5687 2007-02-04  Bruno Haible  <bruno@clisp.org>
5688
5689         New module mbspbrk.
5690         * modules/mbspbrk: New file.
5691         * lib/mbspbrk.c: New file.
5692         * lib/string_.h (strpbrk): Add a conditional link warning.
5693         (mbspbrk): New declaration.
5694         * m4/mbspbrk.m4: New file.
5695         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5696         GNULIB_MBSPBRK.
5697         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
5698         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
5699
5700 2007-02-04  Bruno Haible  <bruno@clisp.org>
5701
5702         New module mbscspn.
5703         * modules/mbscspn: New file.
5704         * lib/mbscspn.c: New file.
5705         * lib/string_.h (strcspn): Add a conditional link warning.
5706         (mbscspn): New declaration.
5707         * m4/mbscspn.m4: New file.
5708         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5709         GNULIB_MBSCSPN.
5710         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
5711         * MODULES.html.sh (Internationalization functions): Add mbscspn.
5712
5713 2007-02-04  Bruno Haible  <bruno@clisp.org>
5714
5715         New module mbscasestr, reduced goal of strcasestr.
5716         * modules/mbscasestr: New file.
5717         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
5718         (mbscasestr): Renamed from strcasestr.
5719         * lib/strcasestr.c: Don't include mbuiter.h.
5720         (strcasestr): Remove support for multibyte locales.
5721         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
5722         Change the conditional link warning.
5723         (mbscasestr): New declaration.
5724         * m4/mbscasestr.m4: New file.
5725         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
5726         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
5727         REPLACE_STRCASESTR.
5728         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
5729         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
5730         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
5731         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
5732         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
5733         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
5734         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
5735         (Depends-on): Remove mbuiter.
5736         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
5737
5738 2007-02-04  Bruno Haible  <bruno@clisp.org>
5739
5740         Simplify handling of strncasecmp.
5741         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
5742         the conditional link warning.
5743         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
5744         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
5745         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
5746         * modules/strcase (configure.ac): Don't invoke
5747         gl_STRING_MODULE_INDICATOR.
5748         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
5749
5750 2007-02-04  Bruno Haible  <bruno@clisp.org>
5751
5752         New module mbscasecmp, reduced goal of strcasecmp.
5753         * modules/mbscasecmp: New file.
5754         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
5755         (mbscasecmp): Renamed from strcasecmp.
5756         * lib/strcasecmp.c: Don't include mbuiter.h.
5757         (strcasecmp): Remove support for multibyte locales.
5758         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
5759         Change the conditional link warning.
5760         (mbscasecmp): New declaration.
5761         * m4/mbscasecmp.m4: New file.
5762         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
5763         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
5764         REPLACE_STRCASECMP.
5765         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
5766         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5767         GNULIB_MBSCASECMP.
5768         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
5769         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
5770         * modules/strcase (Files): Remove m4/mbrtowc.m4.
5771         (Depends-on): Remove mbuiter.
5772         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
5773
5774 2007-02-04  Bruno Haible  <bruno@clisp.org>
5775
5776         New module mbsstr. Remove module strstr.
5777         * modules/mbsstr: New file.
5778         * modules/strstr: Remove file.
5779         * lib/mbsstr.c: Renamed from lib/strstr.c.
5780         (mbsstr): Renamed from strstr.
5781         * lib/string_.h (strstr): Remove declaration. Change the conditional
5782         link warning.
5783         (mbsstr): New declaration.
5784         * m4/mbsstr.m4: New file.
5785         * m4/strstr.m4: Remove file.
5786         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
5787         REPLACE_STRSTR.
5788         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
5789         Don't initialize GNULIB_STRSTR.
5790         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
5791         substitute GNULIB_STRSTR and REPLACE_STRSTR.
5792         * MODULES.html.sh (Internationalization functions): Add mbsstr.
5793         (Support for systems lacking ANSI C 89): Remove strstr.
5794
5795 2007-02-04  Bruno Haible  <bruno@clisp.org>
5796
5797         New module mbsrchr.
5798         * modules/mbsrchr: New file.
5799         * lib/mbsrchr.c: New file.
5800         * lib/string_.h (strrchr): Add a conditional link warning.
5801         (mbsrchr): New declaration.
5802         * m4/mbsrchr.m4: New file.
5803         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5804         GNULIB_MBSRCHR.
5805         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
5806         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
5807
5808 2007-02-04  Bruno Haible  <bruno@clisp.org>
5809
5810         New module mbschr.
5811         * modules/mbschr: New file.
5812         * lib/mbschr.c: New file.
5813         * lib/string_.h (strchr): Add a conditional link warning.
5814         (mbschr): New declaration.
5815         * m4/mbschr.m4: New file.
5816         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5817         GNULIB_MBSCHR.
5818         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
5819         * MODULES.html.sh (Internationalization functions): Add mbschr.
5820
5821 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
5822
5823         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
5824
5825         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
5826
5827 2007-02-04  Bruno Haible  <bruno@clisp.org>
5828
5829         New module description section 'configure.ac-early'.
5830         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
5831         (func_get_autoconf_early_snippet): New function.
5832         (func_import, func_create_testdir): Use it. Remove special cases for
5833         modules 'extensions' and 'lock'.
5834         * modules/extensions (configure.ac-early): Require
5835         gl_USE_SYSTEM_EXTENSIONS.
5836         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
5837
5838 2007-02-04  Bruno Haible  <bruno@clisp.org>
5839
5840         Make use of gcj-4.3's -fsource and -ftarget option.
5841         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
5842         and if so try the options -fsource and -ftarget.
5843         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
5844         source_version, ftarget_option, target_version arguments.
5845         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
5846         (is_envjavac_oldgcj_14_14_usable): Renamed from
5847         is_envjavac_gcj_14_14_usable.
5848         (is_envjavac_oldgcj_14_13_usable): Renamed from
5849         is_envjavac_gcj_14_13_usable.
5850         (is_gcj_present): Update.
5851         (is_gcj_43, is_gcj43_usable): New functions.
5852         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
5853         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
5854         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
5855         try the options -fsource and -ftarget.
5856
5857 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
5858
5859         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
5860         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
5861         larger value.
5862
5863 2007-02-03  Jim Meyering  <jim@meyering.net>
5864
5865         Give tools a better chance to allocate space for very large buffers.
5866         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
5867
5868         Make pwd and readlink work also when run with an unreadable parent dir
5869         on systems with openat support.
5870         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
5871         provided getcwd function, even when we have openat support.
5872         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
5873
5874 2007-02-02  Bruno Haible  <bruno@clisp.org>
5875
5876         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
5877         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
5878         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
5879         portability problems if one of these functions is only used on specific
5880         platforms.
5881         Reported by Paul Eggert.
5882
5883 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
5884
5885         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
5886         is causing more trouble than it's curing.
5887         * lib/regex_internal.h (__mempcpy): Remove.
5888         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
5889         (and make the code a tad smaller to boot).
5890         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
5891
5892 2007-02-02  Jim Meyering  <jim@meyering.net>
5893
5894         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
5895         section, not in the Makefile.am: one.
5896
5897 2007-02-02  Eric Blake  <ebb9@byu.net>
5898
5899         * lib/strchrnul.c: Always include config.h first.
5900
5901         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
5902         gnulib strstr is not necessary here.
5903
5904 2007-02-02  Simon Josefsson  <simon@josefsson.org>
5905
5906         * m4/socklen.m4: Fix typo.
5907
5908 2007-02-02  Eric Blake  <ebb9@byu.net>
5909
5910         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
5911         * modules/netinet_in (Makefile.am): Likewise.
5912
5913 2007-02-01  Bruno Haible  <bruno@clisp.org>
5914
5915         * lib/string_.h (GL_LINK_WARNING): New macro.
5916         (strcasecmp, strstr, strcasestr): If provided by the system,
5917         conditionally define as a macro that leads to a warning instead of to
5918         an error.
5919         (strncasecmp): Conditionally define as a macro that leads to a warning.
5920
5921 2007-02-01  Karl Berry  <karl@gnu.org>
5922
5923         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
5924
5925 2007-02-01  Bruno Haible  <bruno@clisp.org>
5926
5927         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
5928         renamings.
5929
5930 2007-02-01  Eric Blake  <ebb9@byu.net>
5931
5932         * modules/regex (Depends-on): Revert dependence on mempcpy.
5933         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
5934         module's definition of mempcpy.
5935         Reported by Paul Eggert.
5936
5937 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
5938
5939         * lib/string_.h: If the gnulib module XYZ is not present, undefine
5940         the symbol XYZ before redefining it.  This fixes a problem with
5941         programs that don't use XYZ, when compiled on systems that define
5942         XYZ to something else.
5943
5944 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
5945
5946         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
5947         occurs when "mkdir -m foo" creates a setgid directory that is (1)
5948         writeable to group or other and (2) is intended to have a special
5949         mode bit that is set or cleared.  In such a case, the directory
5950         should be neither group- nor other-writeable until the special
5951         mode bits are right.
5952
5953 2007-01-31  Eric Blake  <ebb9@byu.net>
5954
5955         * modules/mountlist (Depends-on): Add strstr.
5956
5957         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
5958         bug.
5959         * modules/string (Makefile.am): Remove redundant replacement.
5960         * modules/regex (Depends-on): Add mempcpy.
5961
5962 2007-01-31  Bruno Haible  <bruno@clisp.org>
5963
5964         New module description field 'Link'.
5965         * gnulib-tool (func_usage): Document --extract-link-directive.
5966         (sed_extract_prog): Recognize 'Link' directive.
5967         (func_get_link_directive): New function.
5968         (func_import): Show summary of link directives.
5969         Handle --extract-link-directive option.
5970         * modules/acl (Link): New section.
5971         * modules/clock-time (Link): New section.
5972         * modules/euidaccess (Link): New section.
5973         * modules/gettext (Link): New section.
5974         * modules/iconv (Link): New section.
5975         * modules/lock (Link): New section.
5976         * modules/nanosleep (Link): New section.
5977         * modules/readline (Link): New section.
5978
5979 2007-01-27  Bruno Haible  <bruno@clisp.org>
5980
5981         Enforce the use of gnulib modules for unportable <string.h> functions.
5982         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
5983         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
5984         (gl_HEADER_STRING_H_BODY): Require it.
5985         * lib/string_.h: If the gnulib module XYZ is not present, redefine
5986         the symbol XYZ to one that gives a link error.
5987         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
5988         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
5989         * modules/mempcpy (configure.ac): Likewise.
5990         * modules/memrchr (configure.ac): Likewise.
5991         * modules/stpcpy (configure.ac): Likewise.
5992         * modules/stpncpy (configure.ac): Likewise.
5993         * modules/strcase (configure.ac): Likewise.
5994         * modules/strcasestr (configure.ac): Likewise.
5995         * modules/strchrnul (configure.ac): Likewise.
5996         * modules/strdup (configure.ac): Likewise.
5997         * modules/strndup (configure.ac): Likewise.
5998         * modules/strnlen (configure.ac): Likewise.
5999         * modules/strpbrk (configure.ac): Likewise.
6000         * modules/strsep (configure.ac): Likewise.
6001         * modules/strstr (configure.ac): Likewise.
6002         * modules/strtok_r (configure.ac): Likewise.
6003
6004 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
6005
6006         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
6007
6008 2007-01-30  Jim Meyering  <jim@meyering.net>
6009
6010         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
6011
6012 2007-01-29  Bruno Haible  <bruno@clisp.org>
6013
6014         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
6015         * lib/execute.c: Likewise.
6016         * lib/pipe.c: Likewise.
6017         * lib/printf-args.h: Likewise.
6018         * lib/printf-args.c: Likewise.
6019         * lib/printf-parse.c: Likewise.
6020         * lib/vasnprintf.c: Likewise.
6021
6022 2007-01-29  Eric Blake  <ebb9@byu.net>
6023
6024         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
6025         declaration.
6026
6027 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
6028
6029         * lib/strptime.h (strptime): Use 'restrict' for args where
6030         POSIX requires this.
6031         * lib/strptime.c (strptime): Likewise.
6032         Change license notice from LGPL to GPL, since gnulib-tool will
6033         change this as needed.
6034         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
6035         defined.
6036         Include "strptime.h" first, to check interface.
6037         Do not #undef _LIBC and _NL_CURRENT.
6038         Do not include <stdlib.h>; no longer needed.
6039         Include "time_r.h" and declare ptime_locale_status
6040         only if _LIBC is not defined.
6041         (__P): Remove unused macro.
6042         (match_string): Bring back glibc version, but use it only if _LIBC
6043         is defined.
6044         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
6045         Remove unnecessary assertion and abort() call.
6046         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
6047         * m4/strptime.m4: Fix serial number comment.
6048         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
6049         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
6050         (Depends-on): Add time_r.
6051
6052 2007-01-29  Bruno Haible  <bruno@clisp.org>
6053
6054         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6055         strptime.
6056         * modules/strptime (Depends-on): Add stdbool.
6057         * lib/strptime.h: Include <time.h> always. Add comments.
6058
6059 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
6060
6061         * modules/strptime: New file.
6062         * lib/strptime.h: New file.
6063         * lib/strptime.c: New file.
6064         * m4/strptime.m4: New file.
6065
6066 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
6067
6068         * MODULES.html.sh: New module mpsort.
6069         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
6070
6071         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
6072         a circularity problem with HP-UX ia64 reported by Bob Proulx in
6073         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
6074         All uses changed.
6075         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
6076         All uses changed.
6077         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
6078         to _Restrict_.
6079         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
6080         the parameter matches the prototype.
6081
6082 2007-01-28  Jim Meyering  <jim@meyering.net>
6083
6084         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
6085         sys/time.h here, reverting that part of the previous patch:
6086         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
6087
6088 2007-01-28  Bruno Haible  <bruno@clisp.org>
6089
6090         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
6091         value of $(SYS_TIME_H).
6092         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
6093         remove it conditionally, too. [added by Jim Meyering]
6094         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
6095         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6096         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
6097         GETTIMEOFDAY_REPLACEMENT to 1.
6098
6099 2007-01-28  Bruno Haible  <bruno@clisp.org>
6100
6101         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
6102         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
6103         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
6104         Set UNISTD_H instead of UNISTD_H2.
6105         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
6106
6107 2007-01-28  Bruno Haible  <bruno@clisp.org>
6108
6109         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
6110         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
6111
6112 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6113
6114         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
6115         (func_create_testdir): Ensure C locale for `grep' and `tr'
6116         character ranges.
6117         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
6118         ACLOCAL_AMFLAGS parsing state machine.
6119
6120 2007-01-27  Bruno Haible  <bruno@clisp.org>
6121
6122         * modules/unistr/base: Update.
6123
6124 2007-01-27  Bruno Haible  <bruno@clisp.org>
6125
6126         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
6127         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
6128         * modules/unistr/u32-mbtouc-unsafe: Renamed from
6129         modules/unistr/u32-mbtouc.
6130         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
6131         * lib/unistr.h: Update.
6132         * lib/linebreak.c: Update.
6133         * modules/unistr/u32-mbtouc: Renamed from
6134         modules/unistr/u32-mbtouc-safe.
6135         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
6136         * lib/unistr.h: Update.
6137         * lib/unistr/u32-to-u8.c: Update.
6138         * lib/unistr/u32-to-u16.c: Update.
6139
6140 2007-01-27  Bruno Haible  <bruno@clisp.org>
6141
6142         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
6143         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
6144         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
6145         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
6146         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
6147         * modules/unistr/u16-mbtouc-unsafe: Renamed from
6148         modules/unistr/u16-mbtouc.
6149         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
6150         * lib/unistr.h: Update.
6151         * lib/linebreak.c: Update.
6152         * modules/linebreak: Update.
6153         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
6154         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
6155         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
6156         * modules/unistr/u16-mbtouc: Renamed from
6157         modules/unistr/u16-mbtouc-safe.
6158         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
6159         * lib/unistr.h: Update.
6160         * lib/unistr/u16-to-u8.c: Update.
6161         * modules/unistr/u16-to-u8: Update.
6162         * lib/unistr/u16-to-u32.c: Update.
6163         * modules/unistr/u16-to-u32: Update.
6164
6165 2007-01-27  Bruno Haible  <bruno@clisp.org>
6166
6167         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
6168         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
6169         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
6170         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
6171         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
6172         * modules/unistr/u8-mbtouc-unsafe: Renamed from
6173         modules/unistr/u8-mbtouc.
6174         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
6175         * lib/unistr.h: Update.
6176         * lib/striconveh.c: Update.
6177         * modules/striconveh: Update.
6178         * lib/linebreak.c: Update.
6179         * modules/linebreak: Update.
6180         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
6181         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
6182         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
6183         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
6184         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
6185         * lib/unistr.h: Update.
6186         * lib/striconveh.c: Update.
6187         * modules/striconveh: Update.
6188         * lib/unistr/u8-to-u16.c: Update.
6189         * modules/unistr/u8-to-u16: Update.
6190         * lib/unistr/u8-to-u32.c: Update.
6191         * modules/unistr/u8-to-u32: Update.
6192
6193 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6194
6195         Sync from Libtool.
6196         * lib/argz.c: Do not include strings.h nor memory.h, include
6197         string.h unconditionally.  Patch by Simon Josefsson.
6198
6199 2007-01-27  Bruno Haible  <bruno@clisp.org>
6200
6201         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
6202         from gl_HEADER_STRING_H_BODY.
6203         (gl_HEADER_STRING_H_BODY): Require it.
6204         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
6205         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
6206         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
6207         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
6208         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
6209         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
6210         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
6211         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
6212         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
6213         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
6214         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
6215         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
6216         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
6217         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
6218         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
6219
6220 2007-01-27  Bruno Haible  <bruno@clisp.org>
6221
6222         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
6223         check_PROGRAMS into noinst_PROGRAMS.
6224         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
6225         check_PROGRAMS in this case.
6226         (func_import): Set for_test to false.
6227         (func_create_testdir): Set for_test to true.
6228
6229 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
6230             Bruno Haible  <bruno@clisp.org>
6231
6232         * modules/strcasestr (Files): Remove lib/strcasestr.h.
6233         (Depends-on): Add string.
6234         (Includes): Use <string.h> instead of strcasestr.h.
6235         * modules/string (Makefile.am): Also substitute the value of
6236         REPLACE_STRCASESTR.
6237         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
6238         assume strcasestr is declared in <string.h> not <strings.h>. Also
6239         set REPLACE_STRCASESTR.
6240         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
6241         REPLACE_STRCASESTR.
6242         * lib/strcasestr.h: Remove file.
6243         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
6244         * lib/string_.h (strcasestr): New declaration.
6245
6246 2007-01-27  Bruno Haible  <bruno@clisp.org>
6247
6248         * lib/string_.h: Use 'extern'.
6249
6250 2007-01-27  Jim Meyering  <jim@meyering.net>
6251
6252         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
6253         of set-but-not-used local, "q".
6254
6255         * lib/mempcpy.c: Include <config.h> before <string.h>.
6256         This fixes a compilation error on HP-UX, due to the system's
6257         "restrict"-using mempcpy prototype.
6258
6259 2007-01-26  Bruno Haible  <bruno@clisp.org>
6260
6261         Small optimization.
6262         * lib/javacomp.c: Include c-strstr.h.
6263          (is_envjavac_gcj): Use c_strstr instead of strstr.
6264         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
6265
6266 2007-01-26  Bruno Haible  <bruno@clisp.org>
6267
6268         * MODULES.html.sh (Unicode string functions): Add the new modules.
6269
6270         * modules/uniconv/u32-strconv-to-locale: New file.
6271         * lib/uniconv/u32-strconv-to-locale.c: New file.
6272
6273         * modules/uniconv/u16-strconv-to-locale: New file.
6274         * lib/uniconv/u16-strconv-to-locale.c: New file.
6275
6276         * modules/uniconv/u8-strconv-to-locale: New file.
6277         * lib/uniconv/u8-strconv-to-locale.c: New file.
6278
6279         * modules/uniconv/u32-strconv-from-locale: New file.
6280         * lib/uniconv/u32-strconv-from-locale.c: New file.
6281
6282         * modules/uniconv/u16-strconv-from-locale: New file.
6283         * lib/uniconv/u16-strconv-from-locale.c: New file.
6284
6285         * modules/uniconv/u8-strconv-from-locale: New file.
6286         * lib/uniconv/u8-strconv-from-locale.c: New file.
6287
6288         * modules/uniconv/u32-strconv-to-enc: New file.
6289         * lib/uniconv/u32-strconv-to-enc.c: New file.
6290         * modules/uniconv/u32-strconv-to-enc-tests: New file.
6291         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
6292
6293         * modules/uniconv/u16-strconv-to-enc: New file.
6294         * lib/uniconv/u16-strconv-to-enc.c: New file.
6295         * lib/uniconv/u-strconv-to-enc.h: New file.
6296         * modules/uniconv/u16-strconv-to-enc-tests: New file.
6297         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
6298
6299         * modules/uniconv/u8-strconv-to-enc: New file.
6300         * lib/uniconv/u8-strconv-to-enc.c: New file.
6301         * modules/uniconv/u8-strconv-to-enc-tests: New file.
6302         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
6303
6304         * modules/uniconv/u32-strconv-from-enc: New file.
6305         * lib/uniconv/u32-strconv-from-enc.c: New file.
6306         * modules/uniconv/u32-strconv-from-enc-tests: New file.
6307         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
6308
6309         * modules/uniconv/u16-strconv-from-enc: New file.
6310         * lib/uniconv/u16-strconv-from-enc.c: New file.
6311         * modules/uniconv/u16-strconv-from-enc-tests: New file.
6312         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
6313
6314         * modules/uniconv/u8-strconv-from-enc: New file.
6315         * lib/uniconv/u8-strconv-from-enc.c: New file.
6316         * lib/uniconv/u-strconv-from-enc.h: New file.
6317         * modules/uniconv/u8-strconv-from-enc-tests: New file.
6318         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
6319
6320         * modules/uniconv/u32-conv-from-enc: New file.
6321         * lib/uniconv/u32-conv-from-enc.c: New file.
6322         * modules/uniconv/u32-conv-from-enc-tests: New file.
6323         * tests/uniconv/test-u32-conv-from-enc.c: New file.
6324
6325         * modules/uniconv/u16-conv-from-enc: New file.
6326         * lib/uniconv/u16-conv-from-enc.c: New file.
6327         * lib/uniconv/u-conv-from-enc.h: New file.
6328         * modules/uniconv/u16-conv-from-enc-tests: New file.
6329         * tests/uniconv/test-u16-conv-from-enc.c: New file.
6330
6331         * modules/uniconv/u8-conv-from-enc: New file.
6332         * lib/uniconv/u8-conv-from-enc.c: New file.
6333         * modules/uniconv/u8-conv-from-enc-tests: New file.
6334         * tests/uniconv/test-u8-conv-from-enc.c: New file.
6335
6336         * modules/uniconv/base: New file.
6337         * lib/uniconv.h: New file.
6338
6339 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
6340
6341         * doc/gnulib-tool.texi (Initial import): Update to match current
6342         behavior with strdup module.
6343         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
6344         * lib/memmem.h: Remove; all uses removed.  This is now done
6345         by <string.h>.
6346         * lib/mempcpy.h: Likewise.
6347         * lib/memrchr.h: Likewise.
6348         * lib/stpcpy.h: Likewise.
6349         * lib/stpncpy.h: Likewise.
6350         * lib/strcase.h: Likewise.
6351         * lib/strchrnul.h: Likewise.
6352         * lib/strdup.h: Likewise.
6353         * lib/strndup.h: Likewise.
6354         * lib/strnlen.h: Likewise.
6355         * lib/strpbrk.h: Likewise.
6356         * lib/strsep.h: Likewise.
6357         * lib/strstr.h: Likewise.
6358         * lib/strtok_r.h: Likewise.
6359         * lib/string_.h: New file.
6360         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
6361         Rely on <string.h> instead.
6362         * lib/canon-host.c: Likewise.
6363         * lib/chdir-long.c: Likewise.
6364         * lib/concatpath.c: Likewise.
6365         * lib/exclude.c: Likewise.
6366         * lib/fchdir.c: Likewise.
6367         * lib/getaddrinfo.c: Likewise.
6368         * lib/getcwd.c: Likewise.
6369         * lib/getsubopt.c: Likewise.
6370         * lib/glob.c: Likewise.
6371         * lib/hard-locale.c: Likewise.
6372         * lib/iconvme.c: Likewise.
6373         * lib/javacomp.c: Likewise.
6374         * lib/mempcpy.c: Likewise.
6375         * lib/memrchr.c: Likewise.
6376         * lib/regex_internal.h: Likewise.
6377         * lib/stpncpy.c: Likewise.
6378         * lib/strcasecmp.c: Likewise.
6379         * lib/strchrnul.c: Likewise.
6380         * lib/strdup.c: Likewise.
6381         * lib/striconv.c: Likewise.
6382         * lib/striconveh.c: Likewise.
6383         * lib/striconveha.c: Likewise.
6384         * lib/strncasecmp.c: Likewise.
6385         * lib/strndup.c: Likewise.
6386         * lib/strnlen.c: Likewise.
6387         * lib/strsep.c: Likewise.
6388         * lib/strstr.c: Likewise.
6389         * lib/strtok_r.c: Likewise.
6390         * lib/userspec.c: Likewise.
6391         * lib/w32spawn.h: Likewise.
6392         * lib/xstrndup.c: Likewise.
6393         * lib/mountlist.c (strstr): Remove decl.
6394         * m4/string_h.m4: New file.
6395         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
6396         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
6397         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
6398         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
6399         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
6400         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
6401         Set REPLACE_STRCASECMP if necessary.
6402         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
6403         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
6404         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
6405         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
6406         HAVE_DECL_STRDUP if necessary.
6407         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
6408         since gl_FUNC_STRNDUP does that now.
6409         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
6410         Check for decl here...
6411         (gl_PREREQ_STRNLEN): ... not here.
6412         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
6413         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
6414         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
6415         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
6416         necessary.
6417         * modules/string: New file.
6418         * modules/memmem (Files): Remove special-purpose include file.
6419         (Depends-on): Add string.
6420         (Include): Include <string.h>, not the removed file.
6421         * modules/mempcpy: Likewise.
6422         * modules/memrchr: Likewise.
6423         * modules/stpcpy: Likewise.
6424         * modules/stpncpy: Likewise.
6425         * modules/strcase: Likewise.
6426         * modules/strchrnul: Likewise.
6427         * modules/strdup: Likewise.
6428         * modules/strndup: Likewise.
6429         * modules/strnlen: Likewise.
6430         * modules/strpbrk: Likewise.
6431         * modules/strsep: Likewise.
6432         * modules/strstr: Likewise.
6433         * modules/strtok_r: Likewise.
6434         * tests/test-dirname.c: Don't include "strdup.h", since
6435         <string.h> now suffices.
6436         * tests/test-memmem.c: Don't include "memmem.h", since
6437         <string.h> now suffices.
6438
6439 2007-01-25  Bruno Haible  <bruno@clisp.org>
6440
6441         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
6442         *resultp is 0.
6443
6444         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
6445         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
6446         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
6447         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
6448
6449         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
6450         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
6451         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
6452         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
6453         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
6454         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
6455
6456 2007-01-24  Bruno Haible  <bruno@clisp.org>
6457
6458         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
6459         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
6460         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
6461         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
6462         gl_FUNC_FTS_CORE.
6463         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
6464         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
6465         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
6466         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
6467         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
6468         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
6469         gl_FUNC_FCHOWNAT.
6470         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
6471         gl_FUNC_STRFTIME.
6472         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
6473         Reported by Ralf Wildenhues.
6474
6475 2007-01-24  Bruno Haible  <bruno@clisp.org>
6476
6477         Drop AC_REQUIRE calls that are redundant with the module dependencies.
6478         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
6479         gl_GETADDRINFO.
6480         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
6481         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
6482         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
6483
6484 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
6485
6486         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
6487         Don't use 'exit'; just return from 'main'.
6488         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
6489
6490         * lib/fnmatch_.h: Readjust white space and comments to match
6491         glibc, to avoid spurious diffs.
6492
6493 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
6494
6495         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
6496         2004-12-01 change by Jakub Jelinek, since this code won't compile
6497         if !LIBC.  Problem reported by Bob Proulx.
6498
6499 2007-01-23  Bruno Haible  <bruno@clisp.org>
6500
6501         * lib/striconveh.c: Include c-strcaseeq.h.
6502         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
6503         * modules/striconveh (Depends-on): Add c-strcaseeq.
6504
6505 2007-01-23  Bruno Haible  <bruno@clisp.org>
6506
6507         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
6508
6509         * modules/c-strcaseeq: New file.
6510         * lib/c-strcaseeq.h: New file.
6511
6512         * modules/streq: New file.
6513         * lib/streq.h: New file.
6514
6515 2007-01-23  Bruno Haible  <bruno@clisp.org>
6516
6517         * modules/striconveha-tests: New file.
6518         * tests/test-striconveha.c: New file.
6519
6520         * lib/striconveha.h: Include <stdbool.h>.
6521         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
6522         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
6523         (mem_iconveha_notranslit): Renamed from mem_iconveha.
6524         (mem_iconveha): New function.
6525         (str_iconveha_notranslit): Renamed from str_iconveha.
6526         (str_iconveha): New function.
6527         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
6528         c-strcase.
6529
6530 2007-01-23  Bruno Haible  <bruno@clisp.org>
6531
6532         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
6533         encodings without forgiving before trying any encoding with handler.
6534         (str_iconveha): Try all encodings without forgiving before trying any
6535         encoding with handler.
6536
6537 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
6538
6539         Import the following changes from libc.
6540
6541         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
6542
6543         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
6544
6545         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
6546
6547         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
6548         normal_bracket label.
6549
6550         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
6551
6552         [BZ #361]
6553         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
6554         to normal_bracket after fetching the next character.
6555
6556 2007-01-22  Bruno Haible  <bruno@clisp.org>
6557
6558         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
6559         argument.
6560         * lib/striconveh.c (iconv_carefully_1): New function.
6561         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
6562         argument.
6563         (str_cd_iconveh): Update.
6564         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
6565         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
6566         * tests/test-striconveh.c (MAGIC): New macro.
6567         (new_offsets): New function.
6568         (main): Test call with and without offsets.
6569
6570 2007-01-22  Bruno Haible  <bruno@clisp.org>
6571
6572         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
6573         * modules/sys_select (Makefile.am): Likewise.
6574         * modules/sys_socket (Makefile.am): Likewise.
6575         * modules/sys_time (Makefile.am): Likewise.
6576
6577 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
6578
6579         * modules/gettimeofday (License): Change from GPL to LGPL, since
6580         gettimeofday is a library function.
6581
6582 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6583
6584         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
6585
6586 2007-01-21  Bruno Haible  <bruno@clisp.org>
6587
6588         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
6589
6590 2007-01-21  Bruno Haible  <bruno@clisp.org>
6591
6592         * modules/striconveha: New file.
6593         * lib/striconveha.h: New file.
6594         * lib/striconveha.c: New file.
6595         * MODULES.html.sh (Internationalization functions): Add striconveha.
6596         * lib/striconv.c (str_iconv): Optimize the case of an empty input
6597         string.
6598         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
6599
6600 2007-01-21  Bruno Haible  <bruno@clisp.org>
6601
6602         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
6603         * lib/striconveh.c (str_iconveh): Likewise.
6604
6605 2007-01-21  Bruno Haible  <bruno@clisp.org>
6606
6607         * lib/striconveh.h (mem_iconveh): New declaration.
6608         * lib/striconveh.c (mem_iconveh): New function.
6609         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
6610
6611 2007-01-21  Bruno Haible  <bruno@clisp.org>
6612
6613         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
6614
6615         * lib/striconveh.h (mem_cd_iconveh): Change specification.
6616         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
6617         original result buffer.
6618         (str_cd_iconveh): Update.
6619         * tests/test-striconveh.c (main): Update.
6620
6621         * lib/striconv.h (mem_cd_iconv): Change specification.
6622         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
6623         result buffer.
6624         (str_cd_iconv): Update.
6625         * tests/test-striconv.c (main): Update.
6626
6627 2007-01-21  Bruno Haible  <bruno@clisp.org>
6628
6629         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
6630
6631 2007-01-20  Jim Meyering  <jim@meyering.net>
6632
6633         * lib/userspec.c (parse_with_separator): If a user or group string
6634         starts with "+", skip the corresponding name-to-ID look-up, since
6635         such a look-up must fail: user and group names may not include "+".
6636
6637 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
6638
6639         * lib/poll.c: Include sys/time.h and time.h unconditionally,
6640         since we now assume the sys_time module.
6641         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
6642         check for sys/time.h; no longer needed.
6643         * modules/poll (Depends-on): Depend on sys_time.
6644
6645 2007-01-18  Bruno Haible  <bruno@clisp.org>
6646
6647         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
6648         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
6649
6650         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
6651         gettimeofday.
6652
6653         * tests/test-gettimeofday.c: Include <time.h>.
6654         (dummy): Remove variable.
6655
6656         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
6657         gl_HEADER_SYS_TIME_H.
6658         (gl_HEADER_SYS_TIME_H): New macro.
6659
6660         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
6661         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6662         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
6663         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
6664         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6665         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
6666         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
6667         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6668         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
6669         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
6670         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6671
6672         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
6673         last change; it caused a compilation error when cross-compiling to
6674         Cygwin.
6675
6676 2007-01-18  Jim Meyering  <jim@meyering.net>
6677
6678         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
6679         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
6680         than the race-prone "test -d sys || mkdir sys".
6681         (configure.ac): Use AC_PROG_MKDIR_P.
6682         * modules/sys_select: Likewise.
6683         * modules/sys_socket: Likewise.
6684         * modules/sys_time: Likewise.
6685
6686 2007-01-18  Eric Blake  <ebb9@byu.net>
6687
6688         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
6689         replace gettimeofday.
6690         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
6691         name, to avoid infinite recursion.
6692
6693 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
6694
6695         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
6696         module sys_time.
6697         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
6698         assume timespec.h defines struct timeval.
6699         * lib/settime.c: Likewise.
6700         * lib/utimens.c: Likewise.
6701         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
6702         since we now assume the gettimeofday module.
6703         * lib/tempname.c (__gen_tempname): Likewise.
6704         * lib/gettimeofday.h: Remove.
6705         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
6706         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
6707         Include <time.h>, for 'time()'.
6708         (localtime_buffer_addr): Also use this workaround if
6709         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
6710         to simplify the uses.  All uses changed.
6711         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
6712         that #undef is inside {}, and 'const' follows type name consistently.
6713         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
6714         (gettimeofday): Do not use the maximum possible value for
6715         tv->tv_usec, since that might break usages other than ls.c.
6716         Instead, we'll leave ls.c alone.  This undoes today's patch
6717         by Bruno.  Add a compile-time warning for 1s-clock resolution;
6718         we've never observed the problem but might as well keep the
6719         canary.
6720         * lib/nanosleep.c: Include timespec.h first, for interface check.
6721         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
6722         now assume the sys_time module.
6723         * lib/tempname.c: Likewise.
6724         * lib/timespec.h: Likewise.
6725         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
6726         needed.
6727         * lib/strftime.c: Likewise.
6728         * lib/timespec.h: Likewise.
6729         * lib/posixtm.c: Include posixtm.h first, for interface check.
6730         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
6731         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
6732         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
6733         * lib/sys_time_.h: New file.
6734         * lib/timespec.h (struct timespec): Use long int, not long.
6735         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6736         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
6737         Remove obsolescent call to AC_HEADER_TIME.
6738         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
6739         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
6740         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
6741         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
6742         Likewise.
6743         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
6744         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
6745         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
6746         into the sys_time module.  Check for gettimeofday just once.
6747         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
6748         for gettimeofday signature to just check the signature.  Merely
6749         compile it, since linking doesn't test signature.  Improve test for
6750         whether gettimeofday.o is actually needed.
6751         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
6752         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
6753         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
6754         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6755         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
6756         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
6757         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
6758         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
6759         than worrying about sys/time.h.
6760         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
6761         Don't bother worrying about TIME_WITH_SYS_TIME.
6762         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
6763         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
6764         * m4/sys_time_h.m4: New file.
6765         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
6766         Don't include sys/time.h.  Return from main rather than exiting.
6767         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
6768         all uses changed.
6769         * modules/gethrxtime (Depends-on): Add sys_time.
6770         * modules/gettime (Depends-on): Likewise.
6771         * modules/gettimeofday (Depends-on): Likewise.
6772         * modules/nanosleep (Depends-on): Likewise.
6773         * modules/settime (Depends-on): Likewise.
6774         * modules/tempname (Depends-on): Likewise.
6775         * modules/utimens (Depends-on): Likewise.
6776         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
6777         (Include:) Change back to <sys/time.h>.
6778         (Maintainer:) Add self.
6779         * modules/sys_time: New file.
6780         * modules/tempname (Depends-on): Add gettimeofday.
6781         * tests/test-gettimeofday.c: Include <sys/time.h>
6782         rather than gettimeofday.h.
6783
6784 2007-01-17  Bruno Haible  <bruno@clisp.org>
6785
6786         * gnulib-tool (func_get_license): Revert last patch. Instead, let
6787         the license default to GPL.
6788         (func_create_testdir): Don't complain if a module is LGPL and its
6789         tests module depends on GPLed modules.
6790
6791 2007-01-17  Bruno Haible  <bruno@clisp.org>
6792
6793         * lib/gettimeofday.c (gettimeofday): Add code for the case
6794         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
6795         maximum possible value for tv->tv_usec, rather than the minimum one.
6796
6797 2005-10-08  Martin Lambers  <marlam@marlam.de>
6798 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
6799 2007-01-16  Bruno Haible  <bruno@clisp.org>
6800
6801         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
6802         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
6803         gl_FUNC_GETTIMEOFDAY.
6804         (Include): Add gettimeofday.h.
6805         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
6806         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
6807         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
6808         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
6809         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
6810         * lib/gettimeofday.h: New file.
6811         * lib/gettimeofday.c: Include <sys/timeb.h>.
6812         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
6813         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
6814         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
6815         fall back on time().
6816
6817         * tests/test-gettimeofday.c: New file.
6818         * modules/gettimeofday-tests: New file.
6819
6820 2007-01-16  Eric Blake  <ebb9@byu.net>
6821
6822         * modules/fnmatch (Depends-on): Depend on wchar.
6823         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
6824         * m4/fnmatch.m4: Likewise.
6825         * modules/mbchar (Makefile.am): Assume <wchar.h>.
6826         * m4/mbchar.m4: Likewise.
6827         * modules/mbswidth (Depends-on): Depend on wchar.
6828         * lib/mbswidth.c: Assume <wchar.h>.
6829         * m4/mbswidth.m4: Likewise.
6830         * modules/quotearg (Depends-on): Depend on wchar.
6831         * lib/quotearg.c: Assume <wchar.h>.
6832         * m4/quotearg.m4: Likewise.
6833         * modules/regex (Depends-on): Depend on wchar.
6834         * lib/regex_internal.h: Assume <wchar.h>.
6835         * m4/regex.m4: Likewise.
6836         * modules/stdint (Depends-on): Depend on wchar.
6837         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
6838         * m4/stdint.m4: Likewise.
6839         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
6840         * modules/strftime (Depends-on): Depend on wchar.
6841         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
6842         * modules/strtol (Depends-on): Depend on wchar.
6843         * lib/strtol.c: Assume <wchar.h>.
6844         * modules/wcwidth (Depends-on): Depend on wchar.
6845         * lib/wcwidth.h: Assume <wchar.h>.
6846         * m4/wcwidth.m4: Likewise.
6847
6848 2007-01-16  Bruno Haible  <bruno@clisp.org>
6849
6850         * modules/csharpexec-script: New, created from...
6851         * modules/csharpexec: ... this.
6852
6853 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
6854
6855         * modules/javaexec-script: New, created from...
6856         * modules/javaexec: ... this.
6857
6858 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6859
6860         * modules/poll (Dependencies): Add sys_select.
6861
6862 2007-01-15  Jim Meyering  <jim@meyering.net>
6863
6864         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
6865         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
6866         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
6867         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
6868
6869 2007-01-15  Bruno Haible  <bruno@clisp.org>
6870
6871         * modules/striconveh: New file.
6872         * lib/striconveh.h: New file.
6873         * lib/striconveh.c: New file.
6874         * MODULES.html.sh (Internationalization functions): Add striconveh.
6875
6876         * modules/striconveh-tests: New file.
6877         * tests/test-striconveh.c: New file.
6878
6879 2007-01-15  Bruno Haible  <bruno@clisp.org>
6880
6881         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
6882         not from GNU libiconv or GNU libc.
6883
6884 2007-01-15  Bruno Haible  <bruno@clisp.org>
6885
6886         * doc/gnulib-intro.texi (Copyright): Explain the different license
6887         terms for module descriptions, autoconf macros, tests, documentation.
6888
6889 2007-01-14  Bruno Haible  <bruno@clisp.org>
6890
6891         * modules/striconv-tests: New file.
6892         * tests/test-striconv.c: New file.
6893
6894 2007-01-14  Bruno Haible  <bruno@clisp.org>
6895
6896         * modules/iconv-tests: New file.
6897         * tests/test-iconv.c: New file.
6898
6899 2007-01-14  Bruno Haible  <bruno@clisp.org>
6900
6901         * gnulib-tool (func_get_license): For test modules, use the license of
6902         the main module.
6903
6904 2007-01-14  Bruno Haible  <bruno@clisp.org>
6905
6906         * modules/iconv (Include): Clarify that <iconv.h> can only be included
6907         if iconv is found to exist.
6908
6909 2007-01-14  Bruno Haible  <bruno@clisp.org>
6910
6911         * modules/c-ctype-tests: New file.
6912         * tests/test-c-ctype.c: New file.
6913
6914 2007-01-14  Bruno Haible  <bruno@clisp.org>
6915
6916         * modules/binary-io-tests: New file.
6917         * tests/test-binary-io.sh: New file.
6918         * tests/test-binary-io.c: New file.
6919
6920 2007-01-14  Bruno Haible  <bruno@clisp.org>
6921
6922         * modules/array-oset-tests: New file.
6923         * tests/test-array_oset.c: New file.
6924
6925 2007-01-14  Bruno Haible  <bruno@clisp.org>
6926
6927         * modules/array-list-tests: New file.
6928         * tests/test-array_list.c: New file.
6929
6930 2007-01-14  Bruno Haible  <bruno@clisp.org>
6931
6932         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
6933         and make.
6934         Reported by Simon Josefsson in
6935         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
6936
6937 2007-01-14  Bruno Haible  <bruno@clisp.org>
6938
6939         * modules/allocsa-tests: New file.
6940         * tests/test-allocsa.c: New file.
6941
6942 2007-01-14  Bruno Haible  <bruno@clisp.org>
6943
6944         * modules/fchdir (Depends-on): Add absolute-header.
6945         * modules/unistd (Depends-on): Likewise.
6946
6947 2006-12-30  Bruno Haible  <bruno@clisp.org>
6948
6949         * modules/fchdir: New file.
6950         * modules/unistd (Files): Add lib/unistd_.h.
6951         (Makefile.am): Generate unistd.h from unistd_.h.
6952         * lib/fchdir.c: New file.
6953         * lib/dirent_.h: New file.
6954         * lib/unistd_.h: New file.
6955         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
6956         * m4/fchdir.m4: New file.
6957         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
6958         (gl_HEADER_UNISTD): Invoke it.
6959         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
6960         function.
6961         * lib/backupfile.c (opendir, closedir): Undefine.
6962         * lib/chown.c (open, close): Undefine.
6963         * lib/clean-temp.c (open, close): Undefine.
6964         * lib/copy-file.c (open, close): Undefine.
6965         * lib/execute.c (open, close): Undefine.
6966         * lib/fsusage.c (open, close): Undefine.
6967         * lib/gc-gnulib.c (open, close): Undefine.
6968         * lib/getcwd.c (opendir, closedir): Undefine.
6969         * lib/glob.c (opendir, closedir): Undefine.
6970         * lib/javacomp.c (open, close): Undefine.
6971         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
6972         * lib/openat-proc.c (open, close): Undefine.
6973         * lib/pagealign_alloc.c (open, close): Undefine.
6974         * lib/pipe.c (open, close): Undefine.
6975         * lib/progreloc.c (open, close): Undefine.
6976         * lib/savedir.c (opendir, closedir): Undefine.
6977         * lib/utime.c (open, close): Undefine.
6978         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
6979
6980 2007-01-10  Bruno Haible  <bruno@clisp.org>
6981
6982         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
6983
6984 2007-01-12  Eric Blake  <ebb9@byu.net>
6985
6986         Provide a robust <wchar.h>.  Further simplifications are now
6987         possible in other modules, but not included here.
6988         * modules/wchar: New module.
6989         * m4/wchar.m4: New file.
6990         * lib/wchar_.h: Likewise.
6991         * modules/mbchar (Depends-on): Depend on wchar, as the first use
6992         of the new module.
6993         * MODULES.html.sh (Extended multibyte and wide character utilities):
6994         New section.
6995
6996 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
6997
6998         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
6999         to a reasonable default for memory allocation.
7000         (xreadlink): Don't allocate a huge buffer, to work around a buggy
7001         file system that reports garbage st_size values for symlinks.
7002         Problem reported by Liyang Hu.
7003
7004 2007-01-11  Simon Josefsson  <simon@josefsson.org>
7005
7006         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
7007         Emacs .#* auto-save files).
7008
7009 2007-01-11  Bruno Haible  <bruno@clisp.org>
7010
7011         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
7012         directory.
7013
7014 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
7015
7016         Use @...@ consistently in lib/wctype_.h.
7017         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
7018         on it being set to 1 or 0.
7019         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
7020         go back to AC_SUBSTing it.
7021         * modules/wctype (Makefile.am): Undo previous change.
7022
7023 2007-01-10  Eric Blake  <ebb9@byu.net>
7024
7025         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
7026         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
7027         * modules/wctype (Makefile.am): Likewise.
7028         Reported by Chris McGuire.
7029
7030 2007-01-10  Jim Meyering  <jim@meyering.net>
7031
7032         fts.c: a small readability/maintainability improvement
7033         * lib/fts.c (fts_read): Make this code slightly more readable and
7034         maintainable by hoisting the "sp->fts_cur = p" assignments to
7035         immediately follow the statements that set P.  Derived from
7036         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
7037
7038 2007-01-10  Eric Blake  <ebb9@byu.net>
7039
7040         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
7041         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
7042         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7043         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
7044         Reported by Chris McGuire.
7045
7046 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7047
7048         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
7049         in sed script.
7050
7051 2007-01-09  Bruno Haible  <bruno@clisp.org>
7052
7053         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
7054         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
7055         variables.
7056         (func_module): Use them.
7057
7058 2007-01-09  Bruno Haible  <bruno@clisp.org>
7059
7060         * modules/unistr/base: New file.
7061         * lib/unistr.h: New file.
7062
7063         * modules/unistr/u8-to-u16: New file.
7064         * lib/unistr/u8-to-u16.c: New file.
7065
7066         * modules/unistr/u8-to-u32: New file.
7067         * lib/unistr/u8-to-u32.c: New file.
7068
7069         * modules/unistr/u16-to-u8: New file.
7070         * lib/unistr/u16-to-u8.c: New file.
7071
7072         * modules/unistr/u16-to-u32: New file.
7073         * lib/unistr/u16-to-u32.c: New file.
7074
7075         * modules/unistr/u32-to-u8: New file.
7076         * lib/unistr/u32-to-u8.c: New file.
7077
7078         * modules/unistr/u32-to-u16: New file.
7079         * lib/unistr/u32-to-u16.c: New file.
7080
7081         * modules/unistr/u8-check: New file.
7082         * modules/unistr/u16-check: New file.
7083         * modules/unistr/u32-check: New file.
7084         * lib/unistr/u8-check.c: New file.
7085         * lib/unistr/u16-check.c: New file.
7086         * lib/unistr/u32-check.c: New file.
7087
7088         * modules/unistr/u8-chr: New file.
7089         * modules/unistr/u16-chr: New file.
7090         * modules/unistr/u32-chr: New file.
7091         * lib/unistr/u8-chr.c: New file.
7092         * lib/unistr/u16-chr.c: New file.
7093         * lib/unistr/u32-chr.c: New file.
7094
7095         * modules/unistr/u8-cmp: New file.
7096         * modules/unistr/u16-cmp: New file.
7097         * modules/unistr/u32-cmp: New file.
7098         * lib/unistr/u8-cmp.c: New file.
7099         * lib/unistr/u16-cmp.c: New file.
7100         * lib/unistr/u32-cmp.c: New file.
7101
7102         * modules/unistr/u8-cpy: New file.
7103         * modules/unistr/u16-cpy: New file.
7104         * modules/unistr/u32-cpy: New file.
7105         * lib/unistr/u8-cpy.c: New file.
7106         * lib/unistr/u16-cpy.c: New file.
7107         * lib/unistr/u32-cpy.c: New file.
7108         * lib/unistr/u-cpy.h: New file.
7109
7110         * modules/unistr/u8-cpy-alloc: New file.
7111         * modules/unistr/u16-cpy-alloc: New file.
7112         * modules/unistr/u32-cpy-alloc: New file.
7113         * lib/unistr/u8-cpy-alloc.c: New file.
7114         * lib/unistr/u16-cpy-alloc.c: New file.
7115         * lib/unistr/u32-cpy-alloc.c: New file.
7116         * lib/unistr/u-cpy-alloc.h: New file.
7117
7118         * modules/unistr/u8-endswith: New file.
7119         * modules/unistr/u16-endswith: New file.
7120         * modules/unistr/u32-endswith: New file.
7121         * lib/unistr/u8-endswith.c: New file.
7122         * lib/unistr/u16-endswith.c: New file.
7123         * lib/unistr/u32-endswith.c: New file.
7124         * lib/unistr/u-endswith.h: New file.
7125
7126         * modules/unistr/u8-mblen: New file.
7127         * modules/unistr/u16-mblen: New file.
7128         * modules/unistr/u32-mblen: New file.
7129         * lib/unistr/u8-mblen.c: New file.
7130         * lib/unistr/u16-mblen.c: New file.
7131         * lib/unistr/u32-mblen.c: New file.
7132
7133         * modules/unistr/u8-mbtouc: New file.
7134         * modules/unistr/u16-mbtouc: New file.
7135         * modules/unistr/u32-mbtouc: New file.
7136         * lib/unistr/u8-mbtouc.c: New file.
7137         * lib/unistr/u16-mbtouc.c: New file.
7138         * lib/unistr/u32-mbtouc.c: New file.
7139
7140         * modules/unistr/u8-mbtouc-safe: New file.
7141         * modules/unistr/u16-mbtouc-safe: New file.
7142         * modules/unistr/u32-mbtouc-safe: New file.
7143         * lib/unistr/u8-mbtouc-safe.c: New file.
7144         * lib/unistr/u16-mbtouc-safe.c: New file.
7145         * lib/unistr/u32-mbtouc-safe.c: New file.
7146
7147         * modules/unistr/u8-move: New file.
7148         * modules/unistr/u16-move: New file.
7149         * modules/unistr/u32-move: New file.
7150         * lib/unistr/u8-move.c: New file.
7151         * lib/unistr/u16-move.c: New file.
7152         * lib/unistr/u32-move.c: New file.
7153         * lib/unistr/u-move.h: New file.
7154
7155         * modules/unistr/u8-next: New file.
7156         * modules/unistr/u16-next: New file.
7157         * modules/unistr/u32-next: New file.
7158         * lib/unistr/u8-next.c: New file.
7159         * lib/unistr/u16-next.c: New file.
7160         * lib/unistr/u32-next.c: New file.
7161
7162         * modules/unistr/u8-prev: New file.
7163         * modules/unistr/u16-prev: New file.
7164         * modules/unistr/u32-prev: New file.
7165         * lib/unistr/u8-prev.c: New file.
7166         * lib/unistr/u16-prev.c: New file.
7167         * lib/unistr/u32-prev.c: New file.
7168
7169         * modules/unistr/u8-set: New file.
7170         * modules/unistr/u16-set: New file.
7171         * modules/unistr/u32-set: New file.
7172         * lib/unistr/u8-set.c: New file.
7173         * lib/unistr/u16-set.c: New file.
7174         * lib/unistr/u32-set.c: New file.
7175         * lib/unistr/u-set.h: New file.
7176
7177         * modules/unistr/u8-startswith: New file.
7178         * modules/unistr/u16-startswith: New file.
7179         * modules/unistr/u32-startswith: New file.
7180         * lib/unistr/u8-startswith.c: New file.
7181         * lib/unistr/u16-startswith.c: New file.
7182         * lib/unistr/u32-startswith.c: New file.
7183         * lib/unistr/u-startswith.h: New file.
7184
7185         * modules/unistr/u8-stpcpy: New file.
7186         * modules/unistr/u16-stpcpy: New file.
7187         * modules/unistr/u32-stpcpy: New file.
7188         * lib/unistr/u8-stpcpy.c: New file.
7189         * lib/unistr/u16-stpcpy.c: New file.
7190         * lib/unistr/u32-stpcpy.c: New file.
7191         * lib/unistr/u-stpcpy.h: New file.
7192
7193         * modules/unistr/u8-stpncpy: New file.
7194         * modules/unistr/u16-stpncpy: New file.
7195         * modules/unistr/u32-stpncpy: New file.
7196         * lib/unistr/u8-stpncpy.c: New file.
7197         * lib/unistr/u16-stpncpy.c: New file.
7198         * lib/unistr/u32-stpncpy.c: New file.
7199         * lib/unistr/u-stpncpy.h: New file.
7200
7201         * modules/unistr/u8-strcat: New file.
7202         * modules/unistr/u16-strcat: New file.
7203         * modules/unistr/u32-strcat: New file.
7204         * lib/unistr/u8-strcat.c: New file.
7205         * lib/unistr/u16-strcat.c: New file.
7206         * lib/unistr/u32-strcat.c: New file.
7207         * lib/unistr/u-strcat.h: New file.
7208
7209         * modules/unistr/u8-strchr: New file.
7210         * modules/unistr/u16-strchr: New file.
7211         * modules/unistr/u32-strchr: New file.
7212         * lib/unistr/u8-strchr.c: New file.
7213         * lib/unistr/u16-strchr.c: New file.
7214         * lib/unistr/u32-strchr.c: New file.
7215
7216         * modules/unistr/u8-strcmp: New file.
7217         * modules/unistr/u16-strcmp: New file.
7218         * modules/unistr/u32-strcmp: New file.
7219         * lib/unistr/u8-strcmp.c: New file.
7220         * lib/unistr/u16-strcmp.c: New file.
7221         * lib/unistr/u32-strcmp.c: New file.
7222
7223         * modules/unistr/u8-strcpy: New file.
7224         * modules/unistr/u16-strcpy: New file.
7225         * modules/unistr/u32-strcpy: New file.
7226         * lib/unistr/u8-strcpy.c: New file.
7227         * lib/unistr/u16-strcpy.c: New file.
7228         * lib/unistr/u32-strcpy.c: New file.
7229         * lib/unistr/u-strcpy.h: New file.
7230
7231         * modules/unistr/u8-strcspn: New file.
7232         * modules/unistr/u16-strcspn: New file.
7233         * modules/unistr/u32-strcspn: New file.
7234         * lib/unistr/u8-strcspn.c: New file.
7235         * lib/unistr/u16-strcspn.c: New file.
7236         * lib/unistr/u32-strcspn.c: New file.
7237         * lib/unistr/u-strcspn.h: New file.
7238
7239         * modules/unistr/u8-strdup: New file.
7240         * modules/unistr/u16-strdup: New file.
7241         * modules/unistr/u32-strdup: New file.
7242         * lib/unistr/u8-strdup.c: New file.
7243         * lib/unistr/u16-strdup.c: New file.
7244         * lib/unistr/u32-strdup.c: New file.
7245         * lib/unistr/u-strdup.h: New file.
7246
7247         * modules/unistr/u8-strlen: New file.
7248         * modules/unistr/u16-strlen: New file.
7249         * modules/unistr/u32-strlen: New file.
7250         * lib/unistr/u8-strlen.c: New file.
7251         * lib/unistr/u16-strlen.c: New file.
7252         * lib/unistr/u32-strlen.c: New file.
7253         * lib/unistr/u-strlen.h: New file.
7254
7255         * modules/unistr/u8-strmblen: New file.
7256         * modules/unistr/u16-strmblen: New file.
7257         * modules/unistr/u32-strmblen: New file.
7258         * lib/unistr/u8-strmblen.c: New file.
7259         * lib/unistr/u16-strmblen.c: New file.
7260         * lib/unistr/u32-strmblen.c: New file.
7261
7262         * modules/unistr/u8-strmbtouc: New file.
7263         * modules/unistr/u16-strmbtouc: New file.
7264         * modules/unistr/u32-strmbtouc: New file.
7265         * lib/unistr/u8-strmbtouc.c: New file.
7266         * lib/unistr/u16-strmbtouc.c: New file.
7267         * lib/unistr/u32-strmbtouc.c: New file.
7268
7269         * modules/unistr/u8-strncat: New file.
7270         * modules/unistr/u16-strncat: New file.
7271         * modules/unistr/u32-strncat: New file.
7272         * lib/unistr/u8-strncat.c: New file.
7273         * lib/unistr/u16-strncat.c: New file.
7274         * lib/unistr/u32-strncat.c: New file.
7275         * lib/unistr/u-strncat.h: New file.
7276
7277         * modules/unistr/u8-strncmp: New file.
7278         * modules/unistr/u16-strncmp: New file.
7279         * modules/unistr/u32-strncmp: New file.
7280         * lib/unistr/u8-strncmp.c: New file.
7281         * lib/unistr/u16-strncmp.c: New file.
7282         * lib/unistr/u32-strncmp.c: New file.
7283
7284         * modules/unistr/u8-strncpy: New file.
7285         * modules/unistr/u16-strncpy: New file.
7286         * modules/unistr/u32-strncpy: New file.
7287         * lib/unistr/u8-strncpy.c: New file.
7288         * lib/unistr/u16-strncpy.c: New file.
7289         * lib/unistr/u32-strncpy.c: New file.
7290         * lib/unistr/u-strncpy.h: New file.
7291
7292         * modules/unistr/u8-strnlen: New file.
7293         * modules/unistr/u16-strnlen: New file.
7294         * modules/unistr/u32-strnlen: New file.
7295         * lib/unistr/u8-strnlen.c: New file.
7296         * lib/unistr/u16-strnlen.c: New file.
7297         * lib/unistr/u32-strnlen.c: New file.
7298         * lib/unistr/u-strnlen.h: New file.
7299
7300         * modules/unistr/u8-strpbrk: New file.
7301         * modules/unistr/u16-strpbrk: New file.
7302         * modules/unistr/u32-strpbrk: New file.
7303         * lib/unistr/u8-strpbrk.c: New file.
7304         * lib/unistr/u16-strpbrk.c: New file.
7305         * lib/unistr/u32-strpbrk.c: New file.
7306         * lib/unistr/u-strpbrk.h: New file.
7307
7308         * modules/unistr/u8-strrchr: New file.
7309         * modules/unistr/u16-strrchr: New file.
7310         * modules/unistr/u32-strrchr: New file.
7311         * lib/unistr/u8-strrchr.c: New file.
7312         * lib/unistr/u16-strrchr.c: New file.
7313         * lib/unistr/u32-strrchr.c: New file.
7314
7315         * modules/unistr/u8-strspn: New file.
7316         * modules/unistr/u16-strspn: New file.
7317         * modules/unistr/u32-strspn: New file.
7318         * lib/unistr/u8-strspn.c: New file.
7319         * lib/unistr/u16-strspn.c: New file.
7320         * lib/unistr/u32-strspn.c: New file.
7321         * lib/unistr/u-strspn.h: New file.
7322
7323         * modules/unistr/u8-strstr: New file.
7324         * modules/unistr/u16-strstr: New file.
7325         * modules/unistr/u32-strstr: New file.
7326         * lib/unistr/u8-strstr.c: New file.
7327         * lib/unistr/u16-strstr.c: New file.
7328         * lib/unistr/u32-strstr.c: New file.
7329         * lib/unistr/u-strstr.h: New file.
7330
7331         * modules/unistr/u8-strtok: New file.
7332         * modules/unistr/u16-strtok: New file.
7333         * modules/unistr/u32-strtok: New file.
7334         * lib/unistr/u8-strtok.c: New file.
7335         * lib/unistr/u16-strtok.c: New file.
7336         * lib/unistr/u32-strtok.c: New file.
7337         * lib/unistr/u-strtok.h: New file.
7338
7339         * modules/unistr/u8-uctomb: New file.
7340         * modules/unistr/u16-uctomb: New file.
7341         * modules/unistr/u32-uctomb: New file.
7342         * lib/unistr/u8-uctomb.c: New file.
7343         * lib/unistr/u16-uctomb.c: New file.
7344         * lib/unistr/u32-uctomb.c: New file.
7345
7346         * MODULES.html.sh (Unicode string functions): Add the new modules.
7347
7348 2007-01-08  Bruno Haible  <bruno@clisp.org>
7349
7350         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
7351         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
7352         subdirectories.
7353
7354 2007-01-08  Karl Berry  <karl@gnu.org>
7355
7356         * doc/error.texi: mention that main() fns must set program_name
7357         when progname is used.
7358
7359 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
7360
7361         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
7362         WCTYPE_H is empty, for the benefit of builds from non-distclean
7363         directories.  Problem reported by Eric Blake in
7364         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
7365
7366 2007-01-08  Bruno Haible  <bruno@clisp.org>
7367
7368         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
7369         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
7370         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
7371         PROVIDE_CANONICALIZE_FILENAME_MODE.
7372         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
7373
7374 2007-01-08  Bruno Haible  <bruno@clisp.org>
7375
7376         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
7377         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
7378         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
7379         * lib/fts.c: Likewise.
7380         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
7381
7382 2006-12-25  Bruno Haible  <bruno@clisp.org>
7383
7384         * modules/utf8-ucs4-safe: New file.
7385         * lib/utf8-ucs4-safe.h: New file.
7386         * lib/unistr/utf8-ucs4-safe.c: New file.
7387
7388         * modules/utf16-ucs4-safe: New file.
7389         * lib/utf16-ucs4-safe.h: New file.
7390         * lib/unistr/utf16-ucs4-safe.c: New file.
7391
7392         * MODULES.html.sh (Unicode string functions): Add the new modules.
7393
7394 2007-01-08  Bruno Haible  <bruno@clisp.org>
7395
7396         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
7397         (Depends-on): Add unitypes.
7398         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7399         (u8_mbtouc_aux): Move out to separate file.
7400         (u8_mbtouc): Use ucs4_t, uint8_t types.
7401         * lib/unistr/utf8-ucs4.c: New file.
7402
7403         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
7404         (Depends-on): Add unitypes.
7405         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7406         (u16_mbtouc_aux): Move out to separate file.
7407         (u16_mbtouc): Use ucs4_t, uint16_t types.
7408         * lib/unistr/utf16-ucs4.c: New file.
7409
7410         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
7411         (Depends-on): Add unitypes.
7412         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
7413         (u8_uctomb_aux): Move out to separate file.
7414         (u8_uctomb): Use ucs4_t, uint8_t types.
7415         * lib/unistr/ucs4-utf8.c: New file.
7416
7417         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
7418         (Depends-on): Add unitypes.
7419         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
7420         (u16_uctomb_aux): Move out to separate file.
7421         (u16_uctomb): Use ucs4_t, uint16_t types.
7422         * lib/unistr/ucs4-utf16.c: New file.
7423
7424 2006-12-25  Bruno Haible  <bruno@clisp.org>
7425
7426         * modules/unitypes: New file.
7427         * lib/unitypes.h: New file.
7428         * MODULES.html.sh (func_all_modules): New section "Unicode string
7429         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
7430         this section. Add unitypes.
7431
7432 2007-01-08  Bruno Haible  <bruno@clisp.org>
7433
7434         Avoid variable names that conflict with those from libtool.
7435         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
7436         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
7437         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
7438         library_names_spec to acl_library_names_spec, hardcode_* to
7439         acl_hardcode_*.
7440         Reported by Ralf Wildenhues.
7441
7442 2007-01-08  Bruno Haible  <bruno@clisp.org>
7443
7444         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
7445         definition.
7446         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
7447         definition.
7448         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
7449         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
7450         definition.
7451         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
7452         definition.
7453         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
7454         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
7455         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
7456         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
7457         definition.
7458         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
7459         definition.
7460         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
7461         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
7462         GC_USE_<algorithm>.
7463         * lib/gc-libgcrypt.c: Likewise.
7464         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
7465         * modules/gc-arctwo (configure.ac): Likewise.
7466         * modules/gc-des (configure.ac): Likewise.
7467         * modules/gc-hmac-md5 (configure.ac): Likewise.
7468         * modules/gc-hmac-sha1 (configure.ac): Likewise.
7469         * modules/gc-md2 (configure.ac): Likewise.
7470         * modules/gc-md4 (configure.ac): Likewise.
7471         * modules/gc-md5 (configure.ac): Likewise.
7472         * modules/gc-random (configure.ac): Likewise.
7473         * modules/gc-rijndael (configure.ac): Likewise.
7474         * modules/gc-sha1 (configure.ac): Likewise.
7475
7476 2007-01-08  Bruno Haible  <bruno@clisp.org>
7477
7478         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
7479         macro definition.
7480         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
7481         definition.
7482         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
7483         definition.
7484         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
7485         * modules/fcntl-safer (configure.ac): Likewise.
7486         * modules/fopen-safer (configure.ac): Likewise.
7487         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
7488         GNULIB_FWRITEERROR macro definition.
7489
7490 2007-01-08  Bruno Haible  <bruno@clisp.org>
7491
7492         * m4/gnulib-common.m4: New file.
7493         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
7494         (func_get_filelist): Add m4/gnulib-common.m4.
7495
7496 2007-01-08  Bruno Haible  <bruno@clisp.org>
7497
7498         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
7499         command.
7500
7501 2007-01-08  Jim Meyering  <jim@meyering.net>
7502
7503         Use a more robust test for a "can't happen" condition.
7504         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
7505         narrowed the st_size value.  Presuming the "can't happen" condition
7506         is true, that narrowing could conceivably convert an invalid st_size
7507         value into a valid one.  Instead, use a change based on Matthew
7508         Woehlke's original patch.
7509
7510         Slight readability improvement: use an assert-like macro
7511         in place of literal "abort ()" uses.
7512         * lib/fts.c (fts_assert): Define.
7513         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
7514         Use this macro instead of a bare 'abort'.
7515
7516 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
7517
7518         Don't worry about using IRIX 5.3's wctype.h broken definitions;
7519         simply work around them.
7520         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
7521         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
7522         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
7523         declaring.
7524         Don't bother to define as macros, since the standard doesn't require it.
7525         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
7526         longer worry about IRIX 5.3.
7527         (HAVE_WCTYPE_CTMP_BUG): Remove.
7528
7529 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
7530
7531         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
7532         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
7533         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
7534         Problems reported by Georg Schwarz for IRIX 5.3.
7535
7536         * gnulib-tool (autoconf_minversion): Take the maximum version number
7537         found, not the minimum.  Problem reported by James Youngman.
7538
7539 2007-01-03  Karl Berry  <karl@gnu.org>
7540
7541         * doc/error.texi: new file, explaining interaction with progname.
7542         * doc/gnulib.texi: include it.  Update copyright.
7543
7544 2007-01-03  Simon Josefsson  <simon@josefsson.org>
7545
7546         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
7547         AC_CANONICAL_HOST, to improve autobuild outputs.
7548
7549 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
7550             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
7551
7552         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
7553         sockets, server sockets, and other file descriptors.  Count errors
7554         to compute the return value.  Reorder the code a bit to be easier
7555         to follow.  Don't set event bits that were not requested (except
7556         POLLERR and POLLHUP).
7557
7558 2007-01-01  Bruno Haible  <bruno@clisp.org>
7559
7560         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
7561
7562 2007-01-03  Jim Meyering  <jim@meyering.net>
7563
7564         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
7565
7566 2007-01-02  Bruno Haible  <bruno@clisp.org>
7567
7568         * modules/settime (Include): Require timespec.h.
7569         * modules/nanosleep (Include): Likewise.
7570
7571 2007-01-01  Bruno Haible  <bruno@clisp.org>
7572
7573         * gnulib-tool (func_emit_copyright_notice): Bump year.
7574         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
7575
7576 2007-01-01  Bruno Haible  <bruno@clisp.org>
7577
7578         Improve support for OpenBSD.
7579         * build-aux/config.rpath (libname_spec): Export.
7580         (library_names_spec): New variable. Export.
7581         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
7582         library_names_spec from the config.rpath output. Locate shared library
7583         through the name pattern in library_names_spec.
7584
7585 2007-01-01  Eric Blake  <ebb9@byu.net>
7586
7587         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
7588
7589 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
7590
7591         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
7592         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
7593         assume the C locale, and avoid an "eval" that could cause trouble.
7594         Problem with SORT reported by Bob Proulx.
7595
7596         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
7597         Define.  Trivial patch from Henning Nielsen Lund, originally
7598         sent to bug-grep@gnu.org today.
7599
7600 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
7601
7602         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
7603         struct stat.  Problem reported by Henning Nielsen Lund.
7604         * lib/acl.c: Include acl.h first, to check interface.  Don't
7605         bother to include sys/types.h and sys/stat.h again.
7606
7607 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
7608
7609         Import the following change from libc; problem reported by
7610         Sven Verdoolaege.
7611
7612         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
7613
7614         [BZ #1373]
7615         * lib/argp.h: Remove __NTH for __argp_usage inline function.
7616
7617 2006-12-28  Jim Meyering  <jim@meyering.net>
7618
7619         * build-aux/announce-gen: Do not assume that the package
7620         builds any of tar.gz, tar.bz2, and .xdelta files.
7621         Suggestion from Simon Josefsson.
7622
7623 2006-12-28  Simon Josefsson  <simon@josefsson.org>
7624
7625         * modules/announce-gen: New file.
7626
7627 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
7628
7629         * lib/mbchar.h: Just include <wctype.h>; the wctype module
7630         handles its gotchas now.
7631         * lib/mbswidth.c: Likewise.
7632         * lib/wcwidth.h: Likewise.
7633         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
7634         and iswcntrl; the wctype module does this stuff now.
7635         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
7636         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7637         * modules/mbchar (Depends-on): Add wctype.
7638         * modules/mbswidth (Depends-on): Likewise.
7639         * modules/wcwidth (Depends-on): Likewise.
7640
7641 2006-12-27  Eric Blake  <ebb9@byu.net>
7642
7643         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
7644         module uses more than what <wctype.h> is required to provide.
7645
7646 2006-12-26  Eric Blake  <ebb9@byu.net>
7647
7648         * gnulib-tool (sed_extract_prog): Avoid space-tab.
7649
7650 2006-12-26  Eric Blake  <ebb9@byu.net>
7651
7652         * modules/absolute-header: New module.
7653         * modules/fcntl (Depends-on): Depend on it.
7654         * modules/inttypes (Depends-on): Likewise.
7655         * modules/stdint (Depends-on): Likewise.
7656         * modules/sys_stat (Depends-on): Likewise.
7657         * modules/wctype (Depends-on): Likewise.
7658         * MODULES.html.sh (Support for building libraries and
7659         executables): Document it.
7660
7661 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
7662
7663         * gnulib-tool (SED): Remove, undoing previous change.
7664         The problem was that it broke coreutils on Solaris, because
7665         "sed --posix" leaked into a makefile.
7666         (sed): New alias, if 'alias' and GNU sed.
7667
7668 2006-12-24  Jim Meyering  <jim@meyering.net>
7669
7670         Work around an fchownat bug in glibc-2.4:
7671         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
7672         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
7673         in spite of the -P option.
7674         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
7675         New macros.
7676         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
7677         * modules/openat (Files): Add lib/fchownat.c.
7678         * lib/openat.c (fchownat): Don't define here.  Move to...
7679         * lib/fchownat.c: ...this new file.
7680
7681 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
7682
7683         Fix bug reported by Bruno Haible in
7684         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
7685         where quotearg.c didn't compile on Mac OS X 10.2 because it
7686         lacks <wchar.h> and wint_t.
7687         * lib/wctype_.h (__wctype_wint_t): New type.
7688         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
7689         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
7690         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
7691         Arg is now of type __wctype_wint_t, not wint_t.
7692         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
7693         substitute HAVE_WINT_T.
7694         * modules/wctype (Files): Add m4/wint_t.m4.
7695         (wctype.h): Substitute HAVE_WINT_T.
7696
7697 2006-12-23  Bruno Haible  <bruno@clisp.org>
7698
7699         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
7700
7701 2006-12-23  Bruno Haible  <bruno@clisp.org>
7702
7703         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
7704         S_ISLNK.
7705         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
7706         mingw.
7707
7708 2006-12-22  Bruno Haible  <bruno@clisp.org>
7709
7710         * lib/copy-file.c: Include acl.h.
7711         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
7712         Close the file descriptors only after being done with copy_acl.
7713         * modules/copy-file (Depends-on): Add acl.
7714
7715 2006-12-22  Bruno Haible  <bruno@clisp.org>
7716
7717         * gnulib-tool (SED): New variable.
7718         Use $SED instead of sed everywhere.
7719
7720 2006-12-22  Bruno Haible  <bruno@clisp.org>
7721
7722         * modules/no-c++: New file.
7723         * m4/no-c++.m4: New file.
7724         * MODULES.html.sh (Support for building libraries and executables):
7725         Add no-c++.
7726
7727 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
7728
7729         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
7730         Include <limits.h>, and use its INT_MAX to rewrite the
7731         j loop so that it does not overflow 'int'.  Problem reported by
7732         Ralf Wildenhues in
7733         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
7734         Play it safe by shifting left by 1 rather than multiplying by 2,
7735         as GCC is less likely to optimize this away when the value
7736         is signed (when it assumes overflow leads to undefined behavior).
7737         Also, don't assume time_t uses two's complement.
7738
7739 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
7740
7741         * MODULES.html.sh: New module wctype.
7742         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
7743         * lib/fnmatch.c: Don't bother to include <wchar.h> before
7744         <wctype.h>, since the new wctype module should fix this.
7745         * lib/quotearg.c: Include <wctype.h> unconditionally, since
7746         the wctype module should arrange for it.
7747         * lib/regex_internal.h: Likewise.
7748         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
7749         since the wctype module should handle this now.
7750         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
7751         * modules/fnmatch (Depends-on): Add wctype.
7752         * modules/quotearg (Depends-on): Likewise.
7753         * modules/regex (Depends-on): Likewise.
7754
7755 2006-12-19  Bruno Haible  <bruno@clisp.org>
7756
7757         * lib/strdup.h [C++]: Wrap definitions in extern "C".
7758         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
7759
7760 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7761
7762         * modules/savewd (Depends-on): Fix dependency on fcntl.
7763
7764 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
7765
7766         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
7767         conforms to C99, rather than relying on the user's environment
7768         setting of STDINT_H.
7769
7770 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
7771         and Eric Blake  <ebb9@byu.net>
7772
7773         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
7774         This is more consistent with the other defines here.
7775         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
7776         Port to z/OS.  Problem reported by Paul Gilmartin.
7777         Change local vars to use gl_ prefix rather than ac_.
7778         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
7779         with other defines.
7780         * modules/double-slash-root: New module.
7781         * modules/dirname (Files): Remove m4/double-slash-root.m4.
7782         (Depends-on): Add double-slash-root.
7783         * MODULES.html.sh (File system functions): Mention new module.
7784
7785 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
7786
7787         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
7788         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
7789         This is for the benefit of gzip, which doesn't do i18n.
7790
7791 2006-12-12  Jim Meyering  <jim@meyering.net>
7792
7793         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
7794         Reported by Andreas Schwab <schwab@suse.de>.
7795
7796 2006-12-12  Bruno Haible  <bruno@clisp.org>
7797
7798         Merge these changes.
7799         2006-09-05  Bruno Haible  <bruno@clisp.org>
7800         * lib/iconvme.c (iconv_string): No need to save and restore errno when
7801         iconv_alloc succeeded.
7802         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
7803         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
7804         test for " && dest " at the end - dest is always != NULL there. Call
7805         iconv with 4xNULL arguments initially, to reset the state. Call iconv
7806         with 2xNULL arguments, also to flush the state storage. Handle the
7807         IRIX iconv behaviour. Realloc the final result, to throw away unused
7808         memory.
7809
7810 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
7811
7812         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
7813         and fchmodat unconditionally, since glibc 2.4 has them.
7814         Problem reported by Arkadiusz Miskiewicz.
7815
7816 2006-12-10  Bruno Haible  <bruno@clisp.org>
7817
7818         * gnulib-tool (func_import): Show the include files only for those
7819         modules that are copied and specified.
7820         Reported by Karl Berry.
7821
7822 2006-12-08  Jim Meyering  <jim@meyering.net>
7823
7824         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
7825         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
7826
7827         * build-aux/announce-gen: Add two new options, both optional:
7828         --bootstrap-tools=TOOL_LIST
7829               a comma-separated list of tools, e.g.,
7830               autoconf,automake,bison,gnulib
7831         --gnulib-snapshot-date=DATE
7832               if gnulib is in the bootstrap tool list,
7833               then report this as the snapshot date.
7834               If not specified, use the current date/time.
7835               If you specify a date here, be sure it's UTC.
7836
7837 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7838
7839         * tests/test-argp-2.sh: Fix test to match actual output.
7840         (func_compare): Fix sed script to be portable.
7841
7842 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
7843
7844         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
7845         workaround for this case.  It is not autoconfigured now; offhand
7846         it's hard to see how to autoconfigure it.
7847
7848 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
7849
7850         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
7851         a directory that is about to be chowned.  Such a directory's
7852         initial file permissions should permit the owner only and this
7853         should not be changed until after the chown, since the group and
7854         other bits would be incorrect if they granted permission before
7855         the chown.
7856
7857         Fix porting problem for iswctype reported by Georg Schwarz in:
7858         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
7859         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
7860         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
7861         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
7862         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
7863
7864 2006-12-03  Jim Meyering  <jim@meyering.net>
7865
7866         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
7867         p->fts_statp may not yet be defined.
7868         (fts_read): Instead, set it in the caller, once p->fts_statp is
7869         sure to be defined, and corresponds to a top-level directory.
7870         This bug made du -x fail.  Here's the coreutils test case:
7871         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
7872         Reported by Mike Frysinger.
7873
7874 2006-12-01  Jim Meyering  <jim@meyering.net>
7875
7876         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
7877         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
7878         Reported by Simon Josefsson.
7879
7880 2006-11-30  Jim Meyering  <jim@meyering.net>
7881
7882         * m4/warning.m4: Use the all-permissive copyright notice
7883         recommended by RMS (rather than LGPL).
7884         * m4/vararrays.m4: Likewise.
7885         * m4/flexmember.m4: Likewise.
7886
7887 2006-11-29  Bruno Haible  <bruno@clisp.org>
7888
7889         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
7890         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
7891         using +=.
7892         Reported by Simon Josefsson <simon@josefsson.org>.
7893
7894 2006-11-28  James Youngman <jay@gnu.org>
7895
7896         * README: Advise users that they might find the bug-gnulib@gnu.org
7897         and autotools-announce@gnu.org mailing lists useful.
7898
7899 2006-11-28  Bruno Haible  <bruno@clisp.org>
7900
7901         * m4/ptrdiff_max.m4: Remove file.
7902
7903 2006-11-21  Bruno Haible  <bruno@clisp.org>
7904
7905         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
7906         _AC_COMPUTE_INT.
7907         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7908         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
7909         _AC_COMPUTE_INT.
7910         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7911         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
7912         _AC_COMPUTE_INT.
7913         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7914
7915 2006-11-28  Jim Meyering  <jim@meyering.net>
7916
7917         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
7918         warning from "gcc -Wshadow" about shadowing the builtin.
7919
7920 2006-11-27  Bruno Haible  <bruno@clisp.org>
7921
7922         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
7923         _AC_COMPUTE_INT.
7924         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
7925
7926 2006-11-27  Bruno Haible  <bruno@clisp.org>
7927             Paul Eggert  <eggert@cs.ucla.edu>
7928
7929         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
7930
7931 2006-11-26  Bruno Haible  <bruno@clisp.org>
7932
7933         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
7934         noinst_LTLIBRARIES.
7935
7936 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
7937             Bruno Haible  <bruno@clisp.org>
7938
7939         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
7940         if compiling with "gcc -ansi".
7941
7942 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
7943
7944         Fix some incompatibilities with gcc -ansi -pedantic.
7945         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
7946         if compiling pedantically with GCC, unless it's C99 or later.
7947         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
7948         it mishandles gcc -ansi -pedantic as well.
7949         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
7950         if gcc -pedantic.
7951         * lib/regexec.c (check_node_accept_bytes): Don't use auto
7952         initializers for struct if -pedantic, unless it's C99 or later.
7953
7954 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
7955
7956         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
7957         Don't close an fd more than once. Identical atimes indicate
7958         success, not failure.
7959
7960 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
7961
7962         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
7963
7964 2006-11-23  Jim Meyering  <jim@meyering.net>
7965
7966         * build-aux/announce-gen: New file.  From coreutils.
7967
7968 2006-11-22  Jim Meyering  <jim@meyering.net>
7969
7970         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
7971         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
7972         (fts_read): Use a temporary to narrow the overused st_size member
7973         before using it in a switch statement.  Reported by Matthew Woehlke.
7974
7975         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
7976         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
7977
7978 2006-11-20  Bruno Haible  <bruno@clisp.org>
7979
7980         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
7981         changequote instead of pairs of brackets.
7982         Reported by Andreas Schwab <schwab@suse.de>.
7983
7984 2006-11-21  Jim Meyering  <jim@meyering.net>
7985
7986         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
7987         so as to remain compatible with older compilers.
7988         Patch from Michael Deutschmann.
7989
7990 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
7991
7992         * MODULES.html.sh (File system functions): Add openat.
7993
7994         * lib/openat.h (rpl_fstatat): New macro, if
7995         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
7996         (fstatat): Define to rpl_fstatat under the same conditions,
7997         unless COMPILING_FSTATAT.
7998         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
7999         seems to have the bug.
8000         * lib/fstatat.c: New file.
8001         * modules/openat (Files): Add it.
8002
8003 2006-11-20  Bruno Haible  <bruno@clisp.org>
8004
8005         * Makefile: New file.
8006
8007 2006-11-20  Jim Meyering  <jim@meyering.net>
8008
8009         The beginnings of syntax-related checks for gnulib.
8010         * lib/Makefile: New file.
8011         * lib/t-idcache: New script.  Ensure that the two halves of
8012         idcache.c stay in sync.
8013
8014         * lib/idcache.c: Adjust comments in user- and group- portions to
8015         be more accurate, and to be consistent with one another.
8016
8017 2006-11-20  Jim Meyering  <jim@meyering.net>
8018
8019         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
8020         continue using the flexible array member (thus, this module performs
8021         half as many malloc calls), with the addition that...
8022         (getgroup, getuser): Consistently record a non-match via an empty
8023         "name" string, and map an empty string match to a NULL return value.
8024         * modules/idcache (Depends-on): Re-add flexmember.
8025
8026         * lib/idcache.c (getuser): Remove all uses of the register keyword.
8027         (getuidbyname, getgroup, getgidbyname): Likewise.
8028
8029         Use cleaner syntax: NULL rather than 0.
8030         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
8031
8032 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8033
8034         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
8035         It mishandled the case where the group was missing.
8036         Problem reported by Greg Schafer.
8037         * modules/idcache: Likewise.
8038
8039 2006-11-18  Jim Meyering  <jim@meyering.net>
8040
8041         * check-module (%exempt_header): Add exception for some
8042         conditionally-included headers.
8043
8044         * modules/i-ring (Depends-on): Add verify.
8045         (License): Change to LGPL.
8046
8047 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
8048
8049         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
8050         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
8051         and inttostr.h.  Use snprintf rather than uinttostr, so that
8052         LGPLed code doesn't depend on GPLed.
8053
8054 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
8055
8056         * modules/inline (License): Change from GPL to LGPL.
8057
8058 2006-11-17  Jim Meyering  <jim@meyering.net>
8059
8060         * modules/d-type (License): Switch to LGPL.
8061
8062 2006-11-15  Bruno Haible  <bruno@clisp.org>
8063
8064         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
8065
8066 2006-11-15  Eric Blake  <ebb9@byu.net>
8067
8068         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
8069         the module dependency.
8070
8071 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8072             Bruno Haible  <bruno@clisp.org>
8073
8074         * gnulib-tool (func_create_testdir): Add license consistency check.
8075
8076 2006-11-15  Eric Blake  <ebb9@byu.net>
8077
8078         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
8079         random "(cached)" in configure output.
8080
8081 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8082
8083         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
8084         test for conforming inttypes.h is both announced and cached.
8085
8086         * MODULES.html.sh (seen_modules, seen_files): New variables.
8087         (func_module): Rewrite to use a few less gnulib-tool and sed
8088         invocations.  Avoid a couple of quadratic algorithms for ...
8089         (missed_modules, missed_files): ... these, with ...
8090         (func_append, func_tmpdir): ... these new functions, from
8091         gnulib-tool.  Analogously, install traps for cleanup.
8092
8093         * tests/test-gc.c (main): Remove unused variables.
8094         * tests/test-read-file.c: Include stdlib.h, for 'free'.
8095
8096 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
8097
8098         * modules/inttostr (License): Change to LGPL.
8099
8100 2006-11-14  Eric Blake  <ebb9@byu.net>
8101
8102         * modules/tempname (License): Change to LGPL.
8103
8104 2006-11-14  Eric Blake  <ebb9@byu.net>
8105
8106         * doc/functions.texi (Function Portability): *printf functions on
8107         Cygwin now understand all POSIX size specifiers.
8108
8109 2006-11-14  Bruno Haible  <bruno@clisp.org>
8110
8111         * modules/c-ctype (License): Change to LGPL.
8112
8113 2006-11-12  Bruno Haible  <bruno@clisp.org>
8114
8115         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
8116         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
8117         for GNOME libraries, for which the include files are installed in
8118         subdirectories of $prefix/include.
8119
8120 2006-11-12  Bruno Haible  <bruno@clisp.org>
8121
8122         * m4/lib-link.m4: Require at least autoconf-2.54.
8123         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
8124         name to underscores for the --with option.
8125
8126 2006-11-13  Bruno Haible  <bruno@clisp.org>
8127
8128         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
8129         the tests directory.
8130         Reported by Ralf Wildenhues.
8131
8132 2006-11-13  Bruno Haible  <bruno@clisp.org>
8133
8134         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
8135         (func_emit_initmacro_end): Undo the override here.
8136         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
8137         Works around the famous automake error in coreutils.
8138
8139 2006-11-13  Eric Blake  <ebb9@byu.net>
8140
8141         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
8142         element, not its node.
8143
8144 2006-11-12  Bruno Haible  <bruno@clisp.org>
8145
8146         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
8147         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
8148
8149 2006-11-12  Bruno Haible  <bruno@clisp.org>
8150
8151         * gnulib-tool: New option --local-symlink.
8152         (func_usage): Document it.
8153         (lsymbolic): New variable.
8154         (func_import, func_create_testdir): If --symlink was not specified,
8155         test whether --local-symlink was specified and the file comes from
8156         the local_gnulib_dir.
8157
8158 2006-11-12  Bruno Haible  <bruno@clisp.org>
8159
8160         * gnulib-tool (func_ln): New function.
8161         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
8162
8163 2006-11-12  Bruno Haible  <bruno@clisp.org>
8164
8165         Finish support for source files in subdirectories.
8166         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
8167         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
8168         AUTOMAKE_OPTIONS.
8169         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
8170
8171 2006-11-12  Bruno Haible  <bruno@clisp.org>
8172
8173         * gnulib-tool (func_get_automake_snippet): Synthesize also an
8174         EXTRA_lib_SOURCES augmentation.
8175         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
8176
8177 2006-11-12  Jim Meyering  <jim@meyering.net>
8178
8179         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
8180         file descriptors.  This also averts a failure on systems with
8181         native openat support when a traversed directory lacks "x" access.
8182         * lib/fts_.h: Include "i-ring.h"
8183         (struct FTS) [fts_fd_ring]: New member.
8184         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
8185         (FCHDIR): Add parentheses.
8186         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
8187         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
8188         When descending, rather than simply closing the previous
8189         fts_cwd_fd value, push that file descriptor onto the ring.
8190         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
8191         (fts_open): Initialize the new fd_ring member.
8192         (fts_close): Clear the ring.
8193         (fts_safe_changedir): When possible, use our new fd_ring to skip
8194         the diropen and fstat and dev/ino comparison that would normally
8195         accompany a virtual `chdir ("..")'.
8196
8197         * modules/fts (Depends-on): Add i-ring.
8198         * modules/i-ring: New module.
8199         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
8200         * m4/i-ring.m4: New file.
8201
8202 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8203
8204         * gnulib-tool (func_create_testdir): Fix replacement of
8205         `build-aux' in configure.ac.  Run autotools in gltests
8206         subdirectory.
8207         (func_create_testdir, func_create_megatestdir, test): There is
8208         no need for '--force' in most autotool invocations in a new
8209         tree.  Actually fail the whole test if any of the tools, or the
8210         configure or make stages fail.
8211
8212         Sync from Automake.
8213         * build-aux/gnupload: Revert last change.  Add pointer to upload
8214         instructions of the GNU Maintenance Instructions.
8215         Suggestion by Karl Berry.
8216
8217 2006-11-10  Jim Meyering  <jim@meyering.net>
8218
8219         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
8220
8221 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8222
8223         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
8224         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
8225         (bind_textdomain_codeset) [! ENABLE_NLS]:
8226         Evaluate all the arguments.  That way, callers get compatible behavior
8227         if the arguments have side effects.  Also, it avoids some GCC
8228         diagnostics in some cases; Joel E. Denny reported problems when Bison
8229         was configured with --enable-gcc-warnigs.
8230
8231 2006-11-10  Jim Meyering  <jim@meyering.net>
8232
8233         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
8234         relevant options in CFLAGS (like -O, -fno-inline) are taken into
8235         account.
8236
8237 2006-11-10  Jim Meyering  <jim@meyering.net>
8238
8239         * modules/inline: New file/module.
8240         * modules/xalloc (Files): Remove m4/inline.m4.
8241         (Depends-on): Add inline, instead.
8242         * modules/oset: Likewise.
8243         * modules/list: Likewise.
8244
8245 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8246
8247         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
8248         Problem reported by Matthew Woehlke.
8249
8250 2006-11-09  Bruno Haible  <bruno@clisp.org>
8251
8252         * lib/tempname.c (gen_tempname): Remove variant that invokes
8253         __gen_tempname.
8254         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
8255         __gen_tempname.
8256
8257 2006-11-08  Bruno Haible  <bruno@clisp.org>
8258
8259         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
8260         to 'yes' instead of 'cross-compiling'.
8261
8262 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
8263
8264         * lib/quotearg.h (quotearg_free): New decl.
8265         * lib/quotearg.c (quotearg_free): New function.
8266         (slot0, nslots, slotvec0, slotvec):
8267         Now file-scope so that quotearg_free can get at them.
8268
8269 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8270
8271         Sync from Automake.
8272         * build-aux/gnupload: Add missing 'gnu' to example URL.
8273         Report by Karl Berry.
8274
8275 2006-11-08  Bruno Haible  <bruno@clisp.org>
8276
8277         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
8278         Suggested by Paul Eggert.
8279
8280 2006-11-08  Jim Meyering  <jim@meyering.net>
8281
8282         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
8283         It's already included if !_LIBC.
8284         (fts_safe_changedir): Add a comment.
8285
8286 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8287
8288         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
8289         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
8290         Matthew Woehlke.
8291
8292         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
8293         definitions up, to avoid colliding with change below.
8294         (static_inline) [HAVE_INLINE]: New macro.
8295         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
8296         Provide extern decls when !HAVE_INLINE.  Do not define unless
8297         static_inline is defined, either by us or by xmalloc.c.  Use
8298         static_inline rather than static inline.
8299         (XCALLOC): Optimize sizeof(T) = 1 case.
8300         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
8301
8302 2006-11-07  Bruno Haible  <bruno@clisp.org>
8303
8304         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
8305         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
8306         AC_C_INLINE.
8307         * modules/xalloc (Files): Add m4/inline.m4.
8308
8309 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8310
8311         * README: Fix typo.
8312         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
8313         (Miscellanous Notes): ...from this.
8314
8315 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8316
8317         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
8318         Mention that offsetof should be used instead of sizeof.
8319         From Bruno Haible.
8320
8321 2006-11-07  Bruno Haible  <bruno@clisp.org>
8322
8323         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
8324
8325 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8326
8327         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8328         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
8329         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8330         (gl_tree_add_before, gl_tree_add_after):
8331         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
8332         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
8333         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
8334         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
8335         (gl_linked_add_after, gl_linked_add_at): Likewise.
8336         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
8337         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8338         (gl_tree_add_before, gl_tree_add_after): Likewise.
8339         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
8340         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
8341         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
8342
8343 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8344
8345         * lib/gl_oset.h: Use C comment style, not C++ comment style.
8346
8347 2006-11-06  Bruno Haible  <bruno@clisp.org>
8348
8349         * m4/inline.m4: New file.
8350         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
8351         * modules/list (Files): Add m4/inline.m4.
8352         * modules/oset (Files): Likewise.
8353
8354 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8355
8356         * lib/idcache.c: Include <stddef.h>, for offsetof.
8357         (struct userid.name): Change from char * to a flexible array member.
8358         All uses changed.
8359         * modules/idcache (Depends-on): Add flexmember.
8360
8361         * MODULES.html.sh (Core language properties): New module flexmember.
8362         * modules/flexmember, m4/flexmember.m4: New files.
8363
8364         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
8365         inline functions that are identical with the old xnmalloc_inline,
8366         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
8367         that we can avoid some unnecessary integer multiplications and
8368         divisions in the common case where the element size is known at
8369         compile time.
8370         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
8371         needed.
8372         (xnboundedmalloc): Remove.
8373         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
8374         arguments, for consistency with rest of this header.
8375         (xcharalloc): Rewrite using XNMALLOC.
8376         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
8377         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
8378         versions have been moved to lib/xalloc.h and renamed to be the
8379         non-*_inline versions.
8380         (xmalloc, xrealloc): Implement without reference to the xnmalloc
8381         and xnrealloc functions, since those functions are now inline and
8382         now call us.
8383         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
8384         renaming described above.
8385         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
8386         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
8387         captures the dependency in AC_C_INLINE.
8388
8389         New module canonicalize-lgpl, proposed by Charles Wilson in
8390         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
8391         with a few small changes afterwards.
8392         * MODULES.html.sh (File system functions): New module
8393         canonicalize-lgpl.
8394         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
8395         and canonicalize_file_name.
8396         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
8397         * modules/canonicalize-lgpl: New files.
8398
8399 2006-11-05  Bruno Haible  <bruno@clisp.org>
8400
8401         * gnulib-tool (func_import, func_create_testdir): Create directories
8402         also for files in subdirectories of lib/.
8403
8404 2006-11-05  Bruno Haible  <bruno@clisp.org>
8405
8406         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
8407         ANSI C compliant.
8408
8409 2006-11-03  Bruno Haible  <bruno@clisp.org>
8410
8411         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8412         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
8413         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
8414         (xnboundedmalloc): New inline function.
8415         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
8416         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
8417         xmalloc.
8418         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
8419         xmalloc.
8420         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
8421         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
8422         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
8423         xmalloc.
8424         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8425         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
8426         xmalloc.
8427         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
8428         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8429         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
8430         xmalloc.
8431         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8432         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
8433         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8434         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
8435         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
8436         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
8437         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
8438
8439 2006-11-03  Bruno Haible  <bruno@clisp.org>
8440
8441         * lib/c-ctype.h [C++]: Define functions without name mangling.
8442         * lib/fwriteerror.h [C++]: Likewise.
8443         * lib/gcd.h [C++]: Likewise.
8444         * lib/linebreak.h [C++]: Likewise.
8445
8446 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
8447
8448         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
8449         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
8450         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
8451         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
8452         Check for functions and headers just once.
8453         Check for declaration of canonicalize_file_name.
8454         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
8455
8456 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
8457
8458         * gnulib-tool (func_import): Fix typo in actioncmd.
8459
8460 2006-11-02  Bruno Haible  <bruno@clisp.org>
8461
8462         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
8463         newline sequence in the Makefile.am snippet as a space, like "make"
8464         does.
8465         Reported by Roger Persson <perrog@gmail.com>.
8466
8467 2006-11-01  Bruno Haible  <bruno@clisp.org>
8468
8469         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
8470         already declared in <string.h>.
8471         * lib/strcase.h (strncasecmp): Don't declare it if yes.
8472
8473 2006-11-01  Bruno Haible  <bruno@clisp.org>
8474
8475         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
8476         * lib/strcase.h: Include <string.h>.
8477         (strcasecmp): Define to rpl_strcasecmp here.
8478
8479 2006-11-01  Bruno Haible  <bruno@clisp.org>
8480
8481         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
8482
8483 2006-11-01  Eric Blake  <ebb9@byu.net>
8484
8485         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
8486
8487         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
8488
8489 2006-10-29  Bruno Haible  <bruno@clisp.org>
8490
8491         Make it compile in C++ mode.
8492         * lib/full-write.c (full_rw): Add a cast.
8493
8494 2006-11-01  Bruno Haible  <bruno@clisp.org>
8495
8496         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
8497         be POSIX compliant.
8498         Reported by Roger Persson <perrog@gmail.com>.
8499
8500 2006-11-01  Eric Blake  <ebb9@byu.net>
8501
8502         * lib/getopt_.h: Fix comments.
8503
8504 2006-10-31  Eric Blake  <ebb9@byu.net>
8505
8506         * modules/tmpdir (Depends-on): Add sys_stat.
8507         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
8508         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
8509         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
8510         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
8511         tempname.
8512
8513 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
8514
8515         Avoid some C++ diagnostics reported by Bruno Haible.
8516         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
8517         xmalloc.
8518         (quotearg_alloc): Use xcharalloc rather than xmalloc.
8519         (struct slotvec): Move to top level.
8520         (quotearg_n_options): Rewrite to avoid xmalloc.
8521         * lib/xalloc.h (xcharalloc): New function.
8522         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
8523         [defined __cplusplus]: Add function template that provides result
8524         type propagation.  This part of the change is from Bruno Haible.
8525
8526 2006-10-29  Bruno Haible  <bruno@clisp.org>
8527
8528         Make it compile in C++ mode.
8529         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
8530         * lib/strnlen1.c (strnlen1): Cast memchr result.
8531         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
8532         * lib/clean-temp.c (string_equals, string_hash): Add casts.
8533         (create_temp_dir): Rename local variable 'template'.
8534         (compile_csharp_using_sscli): Add cast.
8535         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
8536         * lib/findprog.c (find_in_path): Likewise.
8537         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
8538         * lib/wait-process.c (register_slave_subprocess): Likewise.
8539
8540 2006-10-22  Bruno Haible  <bruno@clisp.org>
8541
8542         * modules/tsearch: New file.
8543         * lib/tsearch.h: New file.
8544         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
8545         * m4/tsearch.m4: New file.
8546         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
8547
8548 2006-10-29  Eric Blake  <ebb9@byu.net>
8549
8550         * lib/arcfour.c: Assume config.h.
8551         * lib/arctwo.c: Likewise.
8552         * lib/base64.c: Likewise.
8553         * lib/check-version.c: Likewise.
8554         * lib/crc.c: Likewise.
8555         * lib/des.c: Likewise.
8556         * lib/gc-gnulib.c: Likewise.
8557         * lib/gc-libgcrypt.c: Likewise.
8558         * lib/gc-pbkdf2-sha1.c: Likewise.
8559         * lib/getaddrinfo.c: Likewise.
8560         * lib/getdelim.c: Likewise.
8561         * lib/getline.c: Likewise.
8562         * lib/hmac-md5.c: Likewise.
8563         * lib/hmac-sha1.c: Likewise.
8564         * lib/iconvme.c: Likewise.
8565         * lib/md2.c: Likewise.
8566         * lib/md4.c: Likewise.
8567         * lib/memxor.c: Likewise.
8568         * lib/read-file.c: Likewise.
8569         * lib/readline.c: Likewise.
8570         * lib/rijndael-alg-fst.c: Likewise.
8571         * lib/rijndael-api-fst.c: Likewise.
8572         * lib/xgetdomainname.c: Likewise.
8573
8574 2006-10-28  Eric Blake  <ebb9@byu.net>
8575
8576         * lib/xstrndup.c: Assume config.h.
8577
8578 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
8579
8580         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
8581         stat-macros.h is now for our own macros, whereas stat_h is for
8582         macros in the <sys/stat.h> name space.
8583         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
8584         (STAT_MACROS_H): Remove.
8585         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
8586         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
8587         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
8588         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
8589         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
8590         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
8591         Move these macros to ...
8592         * lib/stat_.h: here.  Don't include stat-macros.h.
8593         * lib/canonicalize.c: Don't include stat-macros.h.
8594         * lib/chown.c: Likewise.
8595         * lib/euidaccess.c: Likewise.
8596         * lib/file-type.c: Likewise.
8597         * lib/filemode.c: Likewise.
8598         * lib/glob.c: Likewise.
8599         * lib/isapipe.c: Likewise.
8600         * lib/lchown.c: Likewise.
8601         * lib/lstat.c: Likewise.
8602         * lib/mkdir-p.c: Likewise.
8603         * lib/rmdir.c: Likewise.
8604         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
8605         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
8606         unless mkdir isn't declared, to speed up 'configure'.
8607         Always create sys/stat.h, since it's unlikely any real sys/stat.h
8608         would define all the S_* symbols.
8609         * modules/canonicalize (Depends-on):
8610         Depend on sys_stat, not stat-macros.
8611         * modules/chown: Likewise.
8612         * modules/euidaccess: Likewise.
8613         * modules/filemode: Likewise.
8614         * modules/file-type: Likewise.
8615         * modules/glob: Likewise.
8616         * modules/isapipe: Likewise.
8617         * modules/lchown: Likewise.
8618         * modules/lstat: Likewise.
8619         * modules/mkancesdirs: Likewise.
8620         * modules/rmdir: Likewise.
8621         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
8622         * modules/modechange: Likewise.
8623         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
8624         (configure.ac): Remove gl_STAT_MACROS.
8625         * modules/sys_stat (Depends-on): Remove stat-macros.
8626
8627 2006-10-27  Bruno Haible  <bruno@clisp.org>
8628
8629         * m4/signed.m4: Remove file.
8630         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
8631         invocation.
8632         * modules/vasnprintf (Files): Remove m4/signed.m4.
8633
8634 2006-10-27  Bruno Haible  <bruno@clisp.org>
8635
8636         Update to GNU gettext 0.16.
8637         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
8638         m4/inttypes-h.m4, m4/signed.m4.
8639         * m4/gettext.m4: Update to GNU gettext 0.16.
8640         * m4/intl.m4: New file, from GNU gettext.
8641         * m4/intldir.m4: New file, from GNU gettext.
8642         * config/srclist.txt: Update
8643
8644 2006-10-27  Eric Blake  <ebb9@byu.net>
8645
8646         * MODULES.html.sh: Document tempname.
8647         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
8648         dependencies.
8649         (Files): Move lib/tempname.c...
8650         * modules/tempname: ...to this new module.
8651         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
8652         (gl_PREREQ_TEMPNAME): Move...
8653         * m4/tempname.m4: ...to this new file.
8654         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
8655         * modules/sys_stat (Depends-on): Add stat-macros.
8656         * lib/stat_.h (includes): Pick up stat macros.
8657         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
8658         if stat macros are broken.
8659         * lib/tempname.c (includes): No need to include "stat-macros.h".
8660         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
8661         (direxists, __path_search) [!_LIBC]: Don't compile these in
8662         gnulib; the tmpdir module covers that.
8663         * lib/tempname.h: New file.
8664
8665 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
8666
8667         * COPYING: Explain how gnulib-tool converts licence headers.
8668         Almost all wording by Eric Blake.
8669
8670 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
8671
8672         * lib/mbchar.h (is_basic_table): Make read-only.
8673         * lib/mbchar.c (is_basic_table): Likewise.
8674         Reported by John Darrington.
8675
8676 2006-10-25  Bruno Haible  <bruno@clisp.org>
8677
8678         * lib/progname.h (set_program_name): Undefine before defining.
8679
8680 2006-10-25  Bruno Haible  <bruno@clisp.org>
8681
8682         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
8683         false for non-gcc C++ compilers.
8684         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
8685
8686 2006-10-24  Bruno Haible  <bruno@clisp.org>
8687
8688         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
8689         iconv implementations like Irix iconv.
8690
8691 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
8692
8693         * modules/vararrays: New file.
8694         * m4/vararrays.m4: New file, taken from diffutils.
8695         * MODULES.html.sh: New module vararrays.
8696
8697 2006-10-24  Karl Berry  <karl@gnu.org>
8698
8699         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
8700         Don't call GNU Unix.
8701
8702 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8703
8704         * users.txt: Add Libtool.
8705
8706         Sync from Libtool:
8707
8708         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
8709
8710         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
8711         to gnulib's policy of including config.h unconditionally.
8712
8713 2006-10-24  Bruno Haible  <bruno@clisp.org>
8714
8715         * modules/wcwidth (Files): Add m4/wint_t.m4.
8716         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
8717         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
8718
8719 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
8720
8721         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
8722         to pacify GCC with some -W flags enabled.  Problem reported by
8723         Bruno Haible.
8724
8725 2006-10-24  Jim Meyering  <jim@meyering.net>
8726
8727         * MODULES.html.sh: Remove uinttostr.  It's not a module.
8728         Reported by Karl Berry.
8729
8730 2006-10-23  Bruno Haible  <bruno@clisp.org>
8731
8732         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
8733
8734 2006-10-24  Bruno Haible  <bruno@clisp.org>
8735
8736         * lib/gl_list.h: Use C comment style, not C++ comment style.
8737
8738 2006-10-23  Eric Blake  <ebb9@byu.net>
8739
8740         * lib/getaddrinfo.c (includes): Add missing include.
8741
8742 2006-10-23  Bruno Haible  <bruno@clisp.org>
8743             Paul Eggert  <eggert@cs.ucla.edu>
8744
8745         Ability to rename obstack_free.
8746         * lib/obstack.h (__obstack_free): New macro. Declare instead of
8747         obstack_free.
8748         (obstack_free): Invoke the __obstack_free macro.
8749         * lib/obstack.c (obstack_free): Use __obstack_free macro.
8750
8751 2006-10-23  Bruno Haible  <bruno@clisp.org>
8752             Paul Eggert  <eggert@cs.ucla.edu>
8753
8754         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
8755         __argc, __argv from the declaration. (They are defined as macros on
8756         mingw.)
8757
8758 2006-10-22  Bruno Haible  <bruno@clisp.org>
8759
8760         * doc/gnulib-intro.texi: New file.
8761         * doc/gnulib.texi: Include it.
8762
8763 2006-10-21  Bruno Haible  <bruno@clisp.org>
8764
8765         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
8766         "Introduction", "Miscellanous Notes", "Particular Modules".
8767
8768 2006-10-21  Bruno Haible  <bruno@clisp.org>
8769
8770         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8771         Change mostlyclean-local rule to avoid sh syntax error from bash
8772         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
8773
8774 2006-10-23  Jim Meyering  <jim@meyering.net>
8775
8776         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
8777         in place of snprintf.
8778
8779         * modules/inttostr (Files): Add lib/uinttostr.c.
8780         * lib/uinttostr.c (inttostr): New file/function.
8781         * lib/inttostr.h (uinttostr): Declare.
8782         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
8783         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
8784         Add uinttostr.
8785         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
8786
8787 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
8788
8789         * lib/canonicalize.c (ELOOP): Define if not already defined.
8790         Problem reported by Bruno Haible in
8791         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
8792
8793 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
8794
8795         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
8796         Problem reported by Perry Smith and Ville Laurikari.
8797
8798         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
8799         uses.
8800
8801 2006-10-19  Bruno Haible  <bruno@clisp.org>
8802
8803         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
8804         for mingw.
8805
8806 2006-10-19  Bruno Haible  <bruno@clisp.org>
8807
8808         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
8809         Needed for mingw.
8810
8811 2006-10-19  Bruno Haible  <bruno@clisp.org>
8812
8813         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
8814
8815 2006-10-19  Bruno Haible  <bruno@clisp.org>
8816
8817         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
8818         it.
8819
8820 2006-10-19  Bruno Haible  <bruno@clisp.org>
8821
8822         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
8823         invocation.
8824
8825 2006-10-19  Bruno Haible  <bruno@clisp.org>
8826
8827         * gnulib-tool (func_create_testdir): Don't include ftruncate and
8828         mountlist by default.
8829
8830 2006-10-16  Bruno Haible  <bruno@clisp.org>
8831
8832         * lib/c-strstr.c: Include c-strstr.h.
8833
8834 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
8835
8836         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
8837         in a slash.
8838
8839 2006-10-18  Bruno Haible  <bruno@clisp.org>
8840
8841         * lib/lock.h [C++]: Wrap definitions in extern "C".
8842
8843 2006-10-18  Bruno Haible  <bruno@clisp.org>
8844
8845         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
8846         gl_LIBOBJS list.
8847
8848 2006-10-18  Bruno Haible  <bruno@clisp.org>
8849
8850         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
8851
8852 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
8853
8854         * lib/xstrtol.h: Include gettext.h.
8855         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
8856         Problem reported by Eric Blake.
8857         * modules/xstrtol (Depends-on): Add gettext-h.
8858
8859 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
8860
8861         * lib/strftime.c (advance): New macro.
8862         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
8863         incomplete type, so you can't add 0 to it.  Problem and patch
8864         reported by Eelco Dolstra for dietlibc.
8865
8866 2006-10-18  Jim Meyering  <jim@meyering.net>
8867
8868         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
8869         type for a local, and rename it: s/up/user_proc/.
8870
8871 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
8872
8873         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
8874         READ_UTMP_USER_PROCESS.
8875         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
8876
8877 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
8878
8879         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
8880         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
8881
8882 2006-10-17  Eric Blake  <ebb9@byu.net>
8883
8884         * lib/sigprocmask.c (sigprocmask): Fix typo.
8885
8886         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
8887
8888         * modules/clean-temp (Makefile.am): Don't add to make output...
8889         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
8890         config.h.
8891
8892 2006-10-17  Bruno Haible  <bruno@clisp.org>
8893
8894         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
8895         differently if DEFAULT_TEXT_DOMAIN is set.
8896
8897 2006-10-16  Bruno Haible  <bruno@clisp.org>
8898
8899         * lib/clean-temp.c: Include fwriteerror.h.
8900
8901 2006-10-16  Bruno Haible  <bruno@clisp.org>
8902
8903         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
8904
8905 2006-10-16  Bruno Haible  <bruno@clisp.org>
8906
8907         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
8908         * lib/sigprocmask.h: Include <sys/types.h>.
8909         (sigset_t): Use the system's definition if present.
8910
8911 2006-10-17  Eric Blake  <ebb9@byu.net>
8912
8913         * lib/xvasprintf.c (includes): Assume config.h.
8914         * lib/xasprintf.c (includes): Likewise.
8915
8916 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
8917
8918         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
8919         at least as wide as intmax_t.
8920
8921 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
8922
8923         (Imported from Automake.)
8924         * build-aux/gnupload: Update to version 1.1 of directive file.
8925
8926 2006-10-16  Eric Blake  <ebb9@byu.net>
8927
8928         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
8929         match Automake 1.10a.
8930
8931 2006-10-14  Bruno Haible  <bruno@clisp.org>
8932
8933         * modules/sigprocmask: New file.
8934         * lib/sigprocmask.h: New file.
8935         * lib/sigprocmask.c: New file.
8936         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
8937         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
8938         request sigprocmask.o.
8939         (gl_PREREQ_SIGPROCMASK): New macro.
8940         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
8941         (Depends-on): Add sigprocmask.
8942         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
8943         gt_SIGNALBLOCKING. Test for 'raise' only once.
8944         * lib/fatal-signal.c: Include sigprocmask.h.
8945         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
8946         unblock_fatal_signals): Define always.
8947         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
8948         sigprocmask.
8949
8950 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
8951
8952         Sync from Automake.
8953         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
8954         which incorrectly sets the mode of an existing destination
8955         directory.  In some cases the unpatched install-sh could do the
8956         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
8957         system.  We hope this is rare in practice, but it's clearly worth
8958         fixing.  Problem reported by Alex Unleashed in
8959         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
8960         Also, don't bother to check for -m bugs unless we're using -m;
8961         suggested by Stepan Kasal.
8962
8963 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8964
8965         Sync from Automake.
8966         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
8967         `-c' flag, so they appear at the same position as in %FASTDEP%
8968         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
8969         which ignores unknown options only after the first non-option.
8970         Bug report against M4 by Nelson H. F. Beebe.
8971
8972 2006-10-13  Jim Meyering  <jim@meyering.net>
8973
8974         Fix a bug in yesterday's change.
8975         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
8976         p->fts_statp->st_dev would be used uninitialized.
8977         Ensures that we always call fts_stat on the very first entry.
8978         Miklos Szeredi reported that find -xdev stopped working.
8979
8980 2006-10-12  Bruno Haible  <bruno@clisp.org>
8981
8982         * gnulib-tool (func_get_automake_snippet): Append an automatically
8983         computed EXTRA_DIST augmentation.
8984         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
8985         * modules/alloca-opt (Makefile.am): Likewise.
8986         * modules/allocsa (Makefile.am): Likewise.
8987         * modules/arcfour (Makefile.am): Likewise.
8988         * modules/arctwo (Makefile.am): Likewise.
8989         * modules/argmatch (Makefile.am): Likewise.
8990         * modules/argz (Makefile.am): Likewise.
8991         * modules/atexit (Makefile.am): Likewise.
8992         * modules/backupfile (Makefile.am): Likewise.
8993         * modules/byteswap (Makefile.am): Likewise.
8994         * modules/c-strtod (Makefile.am): Likewise.
8995         * modules/c-strtold (Makefile.am): Likewise.
8996         * modules/calloc (Makefile.am): Likewise.
8997         * modules/canon-host (Makefile.am): Likewise.
8998         * modules/canonicalize (Makefile.am): Likewise.
8999         * modules/chdir-long (Makefile.am): Likewise.
9000         * modules/chdir-safer (Makefile.am): Likewise.
9001         * modules/check-version (Makefile.am): Likewise.
9002         * modules/chown (Makefile.am): Likewise.
9003         * modules/cloexec (Makefile.am): Likewise.
9004         * modules/close-stream (Makefile.am): Likewise.
9005         * modules/closeout (Makefile.am): Likewise.
9006         * modules/crc (Makefile.am): Likewise.
9007         * modules/csharpexec (Makefile.am): Likewise.
9008         * modules/cycle-check (Makefile.am): Likewise.
9009         * modules/des (Makefile.am): Likewise.
9010         * modules/dev-ino (Makefile.am): Likewise.
9011         * modules/dirfd (Makefile.am): Likewise.
9012         * modules/dirname (Makefile.am): Likewise.
9013         * modules/dup2 (Makefile.am): Likewise.
9014         * modules/eealloc (Makefile.am): Likewise.
9015         * modules/error (Makefile.am): Likewise.
9016         * modules/euidaccess (Makefile.am): Likewise.
9017         * modules/exclude (Makefile.am): Likewise.
9018         * modules/exitfail (Makefile.am): Likewise.
9019         * modules/fcntl-safer (Makefile.am): Likewise.
9020         * modules/fcntl (Makefile.am): Likewise.
9021         * modules/file-type (Makefile.am): Likewise.
9022         * modules/fileblocks (Makefile.am): Likewise.
9023         * modules/filemode (Makefile.am): Likewise.
9024         * modules/filenamecat (Makefile.am): Likewise.
9025         * modules/fnmatch (Makefile.am): Likewise.
9026         * modules/fopen-safer (Makefile.am): Likewise.
9027         * modules/fpending (Makefile.am): Likewise.
9028         * modules/fprintftime (Makefile.am): Likewise.
9029         * modules/free (Makefile.am): Likewise.
9030         * modules/fsusage (Makefile.am): Likewise.
9031         * modules/ftruncate (Makefile.am): Likewise.
9032         * modules/fts (Makefile.am): Likewise.
9033         * modules/gc-arcfour (Makefile.am): Likewise.
9034         * modules/gc-des (Makefile.am): Likewise.
9035         * modules/gc-hmac-md5 (Makefile.am): Likewise.
9036         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
9037         * modules/gc-md4 (Makefile.am): Likewise.
9038         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9039         * modules/gc-sha1 (Makefile.am): Likewise.
9040         * modules/gc (Makefile.am): Likewise.
9041         * modules/getaddrinfo (Makefile.am): Likewise.
9042         * modules/getcwd (Makefile.am): Likewise.
9043         * modules/getdelim (Makefile.am): Likewise.
9044         * modules/getdomainname (Makefile.am): Likewise.
9045         * modules/getgroups (Makefile.am): Likewise.
9046         * modules/gethostname (Makefile.am): Likewise.
9047         * modules/gethrxtime (Makefile.am): Likewise.
9048         * modules/getline (Makefile.am): Likewise.
9049         * modules/getloadavg (Makefile.am): Likewise.
9050         * modules/getlogin_r (Makefile.am): Likewise.
9051         * modules/getndelim2 (Makefile.am): Likewise.
9052         * modules/getopt (Makefile.am): Likewise.
9053         * modules/getpagesize (Makefile.am): Likewise.
9054         * modules/getpass-gnu (Makefile.am): Likewise.
9055         * modules/getpass (Makefile.am): Likewise.
9056         * modules/getsubopt (Makefile.am): Likewise.
9057         * modules/gettime (Makefile.am): Likewise.
9058         * modules/gettimeofday (Makefile.am): Likewise.
9059         * modules/getugroups (Makefile.am): Likewise.
9060         * modules/getusershell (Makefile.am): Likewise.
9061         * modules/glob (Makefile.am): Likewise.
9062         * modules/group-member (Makefile.am): Likewise.
9063         * modules/hard-locale (Makefile.am): Likewise.
9064         * modules/hash (Makefile.am): Likewise.
9065         * modules/hmac-md5 (Makefile.am): Likewise.
9066         * modules/hmac-sha1 (Makefile.am): Likewise.
9067         * modules/human (Makefile.am): Likewise.
9068         * modules/idcache (Makefile.am): Likewise.
9069         * modules/imaxabs (Makefile.am): Likewise.
9070         * modules/imaxdiv (Makefile.am): Likewise.
9071         * modules/inet_ntop (Makefile.am): Likewise.
9072         * modules/inet_pton (Makefile.am): Likewise.
9073         * modules/intprops (Makefile.am): Likewise.
9074         * modules/inttostr (Makefile.am): Likewise.
9075         * modules/inttypes (Makefile.am): Likewise.
9076         * modules/isapipe (Makefile.am): Likewise.
9077         * modules/javaversion (Makefile.am): Likewise.
9078         * modules/lchmod (Makefile.am): Likewise.
9079         * modules/lchown (Makefile.am): Likewise.
9080         * modules/localcharset (Makefile.am): Likewise.
9081         * modules/long-options (Makefile.am): Likewise.
9082         * modules/lstat (Makefile.am): Likewise.
9083         * modules/malloc (Makefile.am): Likewise.
9084         * modules/mathl (Makefile.am): Likewise.
9085         * modules/mbchar (Makefile.am): Likewise.
9086         * modules/md2 (Makefile.am): Likewise.
9087         * modules/md4 (Makefile.am): Likewise.
9088         * modules/md5 (Makefile.am): Likewise.
9089         * modules/memcasecmp (Makefile.am): Likewise.
9090         * modules/memchr (Makefile.am): Likewise.
9091         * modules/memcmp (Makefile.am): Likewise.
9092         * modules/memcoll (Makefile.am): Likewise.
9093         * modules/memcpy (Makefile.am): Likewise.
9094         * modules/memmem (Makefile.am): Likewise.
9095         * modules/memmove (Makefile.am): Likewise.
9096         * modules/mempcpy (Makefile.am): Likewise.
9097         * modules/memrchr (Makefile.am): Likewise.
9098         * modules/memset (Makefile.am): Likewise.
9099         * modules/memxor (Makefile.am): Likewise.
9100         * modules/mkancesdirs (Makefile.am): Likewise.
9101         * modules/mkdir-p (Makefile.am): Likewise.
9102         * modules/mkdir (Makefile.am): Likewise.
9103         * modules/mkdtemp (Makefile.am): Likewise.
9104         * modules/mkstemp (Makefile.am): Likewise.
9105         * modules/mktime (Makefile.am): Likewise.
9106         * modules/modechange (Makefile.am): Likewise.
9107         * modules/mountlist (Makefile.am): Likewise.
9108         * modules/nanosleep (Makefile.am): Likewise.
9109         * modules/obstack (Makefile.am): Likewise.
9110         * modules/openat (Makefile.am): Likewise.
9111         * modules/pagealign_alloc (Makefile.am): Likewise.
9112         * modules/pathmax (Makefile.am): Likewise.
9113         * modules/physmem (Makefile.am): Likewise.
9114         * modules/poll (Makefile.am): Likewise.
9115         * modules/posixtm (Makefile.am): Likewise.
9116         * modules/posixver (Makefile.am): Likewise.
9117         * modules/putenv (Makefile.am): Likewise.
9118         * modules/quote (Makefile.am): Likewise.
9119         * modules/quotearg (Makefile.am): Likewise.
9120         * modules/raise (Makefile.am): Likewise.
9121         * modules/read-file (Makefile.am): Likewise.
9122         * modules/readline (Makefile.am): Likewise.
9123         * modules/readlink (Makefile.am): Likewise.
9124         * modules/readtokens (Makefile.am): Likewise.
9125         * modules/readutmp (Makefile.am): Likewise.
9126         * modules/realloc (Makefile.am): Likewise.
9127         * modules/regex (Makefile.am): Likewise.
9128         * modules/rename-dest-slash (Makefile.am): Likewise.
9129         * modules/rename (Makefile.am): Likewise.
9130         * modules/rijndael (Makefile.am): Likewise.
9131         * modules/rmdir (Makefile.am): Likewise.
9132         * modules/rpmatch (Makefile.am): Likewise.
9133         * modules/safe-read (Makefile.am): Likewise.
9134         * modules/safe-write (Makefile.am): Likewise.
9135         * modules/same-inode (Makefile.am): Likewise.
9136         * modules/same (Makefile.am): Likewise.
9137         * modules/save-cwd (Makefile.am): Likewise.
9138         * modules/savedir (Makefile.am): Likewise.
9139         * modules/setenv (Makefile.am): Likewise.
9140         * modules/settime (Makefile.am): Likewise.
9141         * modules/sha1 (Makefile.am): Likewise.
9142         * modules/sig2str (Makefile.am): Likewise.
9143         * modules/snprintf (Makefile.am): Likewise.
9144         * modules/stat-macros (Makefile.am): Likewise.
9145         * modules/stat-time (Makefile.am): Likewise.
9146         * modules/stdbool (Makefile.am): Likewise.
9147         * modules/stdint (Makefile.am): Likewise.
9148         * modules/stdlib-safer (Makefile.am): Likewise.
9149         * modules/stpcpy (Makefile.am): Likewise.
9150         * modules/stpncpy (Makefile.am): Likewise.
9151         * modules/strcase (Makefile.am): Likewise.
9152         * modules/strcasestr (Makefile.am): Likewise.
9153         * modules/strchrnul (Makefile.am): Likewise.
9154         * modules/strcspn (Makefile.am): Likewise.
9155         * modules/strdup (Makefile.am): Likewise.
9156         * modules/strerror (Makefile.am): Likewise.
9157         * modules/strftime (Makefile.am): Likewise.
9158         * modules/strndup (Makefile.am): Likewise.
9159         * modules/strnlen (Makefile.am): Likewise.
9160         * modules/strpbrk (Makefile.am): Likewise.
9161         * modules/strsep (Makefile.am): Likewise.
9162         * modules/strstr (Makefile.am): Likewise.
9163         * modules/strtod (Makefile.am): Likewise.
9164         * modules/strtoimax (Makefile.am): Likewise.
9165         * modules/strtok_r (Makefile.am): Likewise.
9166         * modules/strtol (Makefile.am): Likewise.
9167         * modules/strtoll (Makefile.am): Likewise.
9168         * modules/strtoul (Makefile.am): Likewise.
9169         * modules/strtoull (Makefile.am): Likewise.
9170         * modules/strtoumax (Makefile.am): Likewise.
9171         * modules/strverscmp (Makefile.am): Likewise.
9172         * modules/sys_socket (Makefile.am): Likewise.
9173         * modules/sys_stat (Makefile.am): Likewise.
9174         * modules/sysexits (Makefile.am): Likewise.
9175         * modules/time_r (Makefile.am): Likewise.
9176         * modules/timegm (Makefile.am): Likewise.
9177         * modules/timespec (Makefile.am): Likewise.
9178         * modules/tmpfile-safer (Makefile.am): Likewise.
9179         * modules/trim (Makefile.am): Likewise.
9180         * modules/unistd-safer (Makefile.am): Likewise.
9181         * modules/unlinkdir (Makefile.am): Likewise.
9182         * modules/unlocked-io (Makefile.am): Likewise.
9183         * modules/userspec (Makefile.am): Likewise.
9184         * modules/utime (Makefile.am): Likewise.
9185         * modules/utimecmp (Makefile.am): Likewise.
9186         * modules/utimens (Makefile.am): Likewise.
9187         * modules/vasnprintf (Makefile.am): Likewise.
9188         * modules/vasprintf (Makefile.am): Likewise.
9189         * modules/vsnprintf (Makefile.am): Likewise.
9190         * modules/xalloc (Makefile.am): Likewise.
9191         * modules/xgetcwd (Makefile.am): Likewise.
9192         * modules/xnanosleep (Makefile.am): Likewise.
9193         * modules/xreadlink (Makefile.am): Likewise.
9194         * modules/xstrtod (Makefile.am): Likewise.
9195         * modules/xstrtol (Makefile.am): Likewise.
9196         * modules/xstrtold (Makefile.am): Likewise.
9197         * modules/yesno (Makefile.am): Likewise.
9198         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
9199
9200 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9201
9202         * modules/error (Makefile.am): Distribute files through
9203         EXTRA_DIST, not lib_SOURCES.
9204
9205 2006-10-12  Eric Blake  <ebb9@byu.net>
9206
9207         * modules/error (Makefile.am): Distribute files in /lib.
9208         * modules/obstack (Makefile.am): Likewise.
9209
9210 2006-10-12  Bruno Haible  <bruno@clisp.org>
9211
9212         * modules/acl (Makefile.am): Distribute all files in lib/ through
9213         EXTRA_DIST.
9214         * modules/arcfour (Makefile.am): Likewise.
9215         * modules/arctwo (Makefile.am): Likewise.
9216         * modules/argmatch (Makefile.am): Likewise.
9217         * modules/argz (Makefile.am): Likewise.
9218         * modules/atexit (Makefile.am): Likewise.
9219         * modules/backupfile (Makefile.am): Likewise.
9220         * modules/c-strtod (Makefile.am): Likewise.
9221         * modules/c-strtold (Makefile.am): Likewise.
9222         * modules/calloc (Makefile.am): Likewise.
9223         * modules/canon-host (Makefile.am): Likewise.
9224         * modules/canonicalize (Makefile.am): Likewise.
9225         * modules/chdir-long (Makefile.am): Likewise.
9226         * modules/chdir-safer (Makefile.am): Likewise.
9227         * modules/check-version (Makefile.am): Likewise.
9228         * modules/chown (Makefile.am): Likewise.
9229         * modules/cloexec (Makefile.am): Likewise.
9230         * modules/close-stream (Makefile.am): Likewise.
9231         * modules/closeout (Makefile.am): Likewise.
9232         * modules/crc (Makefile.am): Likewise.
9233         * modules/cycle-check (Makefile.am): Likewise.
9234         * modules/des (Makefile.am): Likewise.
9235         * modules/dirfd (Makefile.am): Likewise.
9236         * modules/dirname (Makefile.am): Likewise.
9237         * modules/dup2 (Makefile.am): Likewise.
9238         * modules/euidaccess (Makefile.am): Likewise.
9239         * modules/exclude (Makefile.am): Likewise.
9240         * modules/exitfail (Makefile.am): Likewise.
9241         * modules/fcntl-safer (Makefile.am): Likewise.
9242         * modules/file-type (Makefile.am): Likewise.
9243         * modules/fileblocks (Makefile.am): Likewise.
9244         * modules/filemode (Makefile.am): Likewise.
9245         * modules/filenamecat (Makefile.am): Likewise.
9246         * modules/fnmatch (Makefile.am): Likewise.
9247         * modules/fopen-safer (Makefile.am): Likewise.
9248         * modules/fpending (Makefile.am): Likewise.
9249         * modules/fprintftime (Makefile.am): Likewise.
9250         * modules/free (Makefile.am): Likewise.
9251         * modules/fsusage (Makefile.am): Likewise.
9252         * modules/ftruncate (Makefile.am): Likewise.
9253         * modules/fts (Makefile.am): Likewise.
9254         * modules/gc (Makefile.am): Likewise.
9255         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9256         * modules/getaddrinfo (Makefile.am): Likewise.
9257         * modules/getcwd (Makefile.am): Likewise.
9258         * modules/getdelim (Makefile.am): Likewise.
9259         * modules/getdomainname (Makefile.am): Likewise.
9260         * modules/getgroups (Makefile.am): Likewise.
9261         * modules/gethostname (Makefile.am): Likewise.
9262         * modules/gethrxtime (Makefile.am): Likewise.
9263         * modules/getline (Makefile.am): Likewise.
9264         * modules/getloadavg (Makefile.am): Likewise.
9265         * modules/getlogin_r (Makefile.am): Likewise.
9266         * modules/getopt (Makefile.am): Likewise.
9267         * modules/getpass (Makefile.am): Likewise.
9268         * modules/getpass-gnu (Makefile.am): Likewise.
9269         * modules/getsubopt (Makefile.am): Likewise.
9270         * modules/gettime (Makefile.am): Likewise.
9271         * modules/gettimeofday (Makefile.am): Likewise.
9272         * modules/getugroups (Makefile.am): Likewise.
9273         * modules/getusershell (Makefile.am): Likewise.
9274         * modules/glob (Makefile.am): Likewise.
9275         * modules/group-member (Makefile.am): Likewise.
9276         * modules/hard-locale (Makefile.am): Likewise.
9277         * modules/hash (Makefile.am): Likewise.
9278         * modules/hmac-md5 (Makefile.am): Likewise.
9279         * modules/hmac-sha1 (Makefile.am): Likewise.
9280         * modules/human (Makefile.am): Likewise.
9281         * modules/idcache (Makefile.am): Likewise.
9282         * modules/imaxabs (Makefile.am): Likewise.
9283         * modules/imaxdiv (Makefile.am): Likewise.
9284         * modules/inet_ntop (Makefile.am): Likewise.
9285         * modules/inet_pton (Makefile.am): Likewise.
9286         * modules/inttostr (Makefile.am): Likewise.
9287         * modules/isapipe (Makefile.am): Likewise.
9288         * modules/lchown (Makefile.am): Likewise.
9289         * modules/long-options (Makefile.am): Likewise.
9290         * modules/lstat (Makefile.am): Likewise.
9291         * modules/malloc (Makefile.am): Likewise.
9292         * modules/mathl (Makefile.am): Likewise.
9293         * modules/mbchar (Makefile.am): Likewise.
9294         * modules/md2 (Makefile.am): Likewise.
9295         * modules/md4 (Makefile.am): Likewise.
9296         * modules/md5 (Makefile.am): Likewise.
9297         * modules/memcasecmp (Makefile.am): Likewise.
9298         * modules/memchr (Makefile.am): Likewise.
9299         * modules/memcmp (Makefile.am): Likewise.
9300         * modules/memcoll (Makefile.am): Likewise.
9301         * modules/memcpy (Makefile.am): Likewise.
9302         * modules/memmem (Makefile.am): Likewise.
9303         * modules/memmove (Makefile.am): Likewise.
9304         * modules/mempcpy (Makefile.am): Likewise.
9305         * modules/memrchr (Makefile.am): Likewise.
9306         * modules/memset (Makefile.am): Likewise.
9307         * modules/memxor (Makefile.am): Likewise.
9308         * modules/mkancesdirs (Makefile.am): Likewise.
9309         * modules/mkdir (Makefile.am): Likewise.
9310         * modules/mkdir-p (Makefile.am): Likewise.
9311         * modules/mkdtemp (Makefile.am): Likewise.
9312         * modules/mkstemp (Makefile.am): Likewise.
9313         * modules/mktime (Makefile.am): Likewise.
9314         * modules/modechange (Makefile.am): Likewise.
9315         * modules/mountlist (Makefile.am): Likewise.
9316         * modules/nanosleep (Makefile.am): Likewise.
9317         * modules/openat (Makefile.am): Likewise.
9318         * modules/pagealign_alloc (Makefile.am): Likewise.
9319         * modules/physmem (Makefile.am): Likewise.
9320         * modules/poll (Makefile.am): Likewise.
9321         * modules/posixtm (Makefile.am): Likewise.
9322         * modules/posixver (Makefile.am): Likewise.
9323         * modules/putenv (Makefile.am): Likewise.
9324         * modules/quote (Makefile.am): Likewise.
9325         * modules/quotearg (Makefile.am): Likewise.
9326         * modules/raise (Makefile.am): Likewise.
9327         * modules/read-file (Makefile.am): Likewise.
9328         * modules/readline (Makefile.am): Likewise.
9329         * modules/readlink (Makefile.am): Likewise.
9330         * modules/readtokens (Makefile.am): Likewise.
9331         * modules/readutmp (Makefile.am): Likewise.
9332         * modules/realloc (Makefile.am): Likewise.
9333         * modules/regex (Makefile.am): Likewise.
9334         * modules/rename (Makefile.am): Likewise.
9335         * modules/rename-dest-slash (Makefile.am): Likewise.
9336         * modules/rijndael (Makefile.am): Likewise.
9337         * modules/rmdir (Makefile.am): Likewise.
9338         * modules/rpmatch (Makefile.am): Likewise.
9339         * modules/safe-read (Makefile.am): Likewise.
9340         * modules/safe-write (Makefile.am): Likewise.
9341         * modules/same (Makefile.am): Likewise.
9342         * modules/save-cwd (Makefile.am): Likewise.
9343         * modules/savedir (Makefile.am): Likewise.
9344         * modules/setenv (Makefile.am): Likewise.
9345         * modules/settime (Makefile.am): Likewise.
9346         * modules/sha1 (Makefile.am): Likewise.
9347         * modules/sig2str (Makefile.am): Likewise.
9348         * modules/snprintf (Makefile.am): Likewise.
9349         * modules/stdlib-safer (Makefile.am): Likewise.
9350         * modules/stpcpy (Makefile.am): Likewise.
9351         * modules/stpncpy (Makefile.am): Likewise.
9352         * modules/strcase (Makefile.am): Likewise.
9353         * modules/strcasestr (Makefile.am): Likewise.
9354         * modules/strchrnul (Makefile.am): Likewise.
9355         * modules/strcspn (Makefile.am): Likewise.
9356         * modules/strdup (Makefile.am): Likewise.
9357         * modules/strerror (Makefile.am): Likewise.
9358         * modules/strftime (Makefile.am): Likewise.
9359         * modules/strndup (Makefile.am): Likewise.
9360         * modules/strnlen (Makefile.am): Likewise.
9361         * modules/strpbrk (Makefile.am): Likewise.
9362         * modules/strsep (Makefile.am): Likewise.
9363         * modules/strstr (Makefile.am): Likewise.
9364         * modules/strtod (Makefile.am): Likewise.
9365         * modules/strtoimax (Makefile.am): Likewise.
9366         * modules/strtok_r (Makefile.am): Likewise.
9367         * modules/strtol (Makefile.am): Likewise.
9368         * modules/strtoll (Makefile.am): Likewise.
9369         * modules/strtoul (Makefile.am): Likewise.
9370         * modules/strtoull (Makefile.am): Likewise.
9371         * modules/strtoumax (Makefile.am): Likewise.
9372         * modules/strverscmp (Makefile.am): Likewise.
9373         * modules/time_r (Makefile.am): Likewise.
9374         * modules/timegm (Makefile.am): Likewise.
9375         * modules/tmpfile-safer (Makefile.am): Likewise.
9376         * modules/unistd-safer (Makefile.am): Likewise.
9377         * modules/unlinkdir (Makefile.am): Likewise.
9378         * modules/userspec (Makefile.am): Likewise.
9379         * modules/utime (Makefile.am): Likewise.
9380         * modules/utimecmp (Makefile.am): Likewise.
9381         * modules/utimens (Makefile.am): Likewise.
9382         * modules/vasnprintf (Makefile.am): Likewise.
9383         * modules/vasprintf (Makefile.am): Likewise.
9384         * modules/vsnprintf (Makefile.am): Likewise.
9385         * modules/xalloc (Makefile.am): Likewise.
9386         * modules/xgetcwd (Makefile.am): Likewise.
9387         * modules/xnanosleep (Makefile.am): Likewise.
9388         * modules/xreadlink (Makefile.am): Likewise.
9389         * modules/xstrtod (Makefile.am): Likewise.
9390         * modules/xstrtol (Makefile.am): Likewise.
9391         * modules/xstrtold (Makefile.am): Likewise.
9392         * modules/yesno (Makefile.am): Likewise.
9393
9394 2006-10-12  Jim Meyering  <jim@meyering.net>
9395
9396         * m4/getloadavg.m4: Revert the change below.
9397
9398         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
9399         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
9400         fail with a symlink, which is what coreutils' ./bootstrap now
9401         creates by default.
9402
9403 2006-10-12  Bruno Haible  <bruno@clisp.org>
9404
9405         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
9406         mingw.
9407         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
9408         MSVC and mingw explicitly.
9409
9410 2006-10-11  Simon Josefsson  <jas@extundo.com>
9411             Bruno Haible  <bruno@clisp.org>
9412
9413         Add support for multiple gnulib-tool invocations in the scope of a
9414         single configure.ac file.
9415         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
9416         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
9417         with the same contents as the _LIBADD variable.
9418         (func_emit_initmacro_start, func_emit_initmacro_end,
9419         func_emit_initmacro_done): New functions.
9420         (func_import, func_create_testdir): Invoke them. Allow the identifiers
9421         gl_LIBOBJS and gl_LTLIBOBJS.
9422
9423 2006-10-11  Bruno Haible  <bruno@clisp.org>
9424
9425         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
9426         (func_create_testdir): Don't create po/Makefile.am, don't invoke
9427         autoreconf. Instead, invoke autopoint explicitly but move back the
9428         *.m4 files from gnulib.
9429
9430 2006-10-11  Bruno Haible  <bruno@clisp.org>
9431
9432         * gnulib-tool (func_usage): Make module names after --create-testdir
9433         optional.
9434         (func_create_testdir): If no module was specified, use nearly all
9435         modules.
9436
9437 2006-10-12  Jim Meyering  <jim@meyering.net>
9438
9439         Big performance improvement for fts-based tools that use FTS_NOSTAT.
9440         Avoid spurious inode-mismatch problems on non-POSIX file systems.
9441         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
9442         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
9443         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
9444         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
9445         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
9446         (fts_set_stat_required): New function.
9447         (fts_open): Defer the calls to fts_stat, if possible or requested.
9448         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
9449         into fts_stat itself.
9450         (fts_read): Perform any required (deferred) fts_stat call.
9451         (fts_build): Likewise, for the directory we're about to open and read.
9452         In the readdir loop, carefully decide whether each entry will require
9453         an eventual call to fts_stat, using dirent.d_type info if available.
9454         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
9455         a command line argument into this function.  Update all callers.
9456         Map a return value of FTS_DOT to FTS_D for a command line argument.
9457         * modules/fts (Depends-on): Add d-type.  Alphabetize.
9458         Thanks to Miklos Szeredi for his tenacity and for the initial
9459         bug report about "find" failing on a FUSE-based file system.
9460
9461         * lib/fts.c (fts_open): Use consistent indentation.
9462
9463 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9464
9465         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
9466         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
9467         reported by Jim Meyering.  All uses of cache variables renamed
9468         to match Autoconf's.
9469         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
9470         the other one.
9471
9472         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
9473         Fix misspelling in diagnostic.
9474
9475 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9476
9477         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
9478         defined.  Problem reported by Matthew Woehlke.
9479
9480         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
9481         Add support for Tandem NonStop R series.
9482         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
9483         Use new macro.
9484
9485         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
9486         (has_trailing_slash): Omit size arg; all callers changed.
9487         Omit 'inline', since it doesn't help performance and we'd
9488         need to configure it.
9489         Don't count //, ///, etc. as having a trailing slash.
9490         As a side effect, this removes a C99ism reported by Matthew Woehlke.
9491         (rpl_rename_dest_slash): On failure, use rename's errno rather
9492         than (in some cases) an incorrect or junk errno.
9493         Simplify code by removing need to compute length; this does
9494         cause it to make two passes instead of one over the file name,
9495         but it's worth it.
9496
9497         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
9498         change, since Autoconf's version may no longer be appropriate now
9499         that we are using CVS Autoconf's version.  Add support for Tandem.
9500
9501 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9502             Bruno Haible  <bruno@clisp.org>
9503
9504         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
9505         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
9506         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
9507         gl_AC_TYPE_LONG_LONG.
9508
9509         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
9510         instead of HAVE_LONG_LONG.
9511         * lib/printf-args.c (printf_fetchargs): Likewise.
9512         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
9513         * lib/vasnprintf.c (VASNPRINTF): Likewise.
9514         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
9515         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
9516         gl_AC_TYPE_LONG_LONG.
9517
9518 2006-10-11  Bruno Haible  <bruno@clisp.org>
9519
9520         * m4/longlong.m4: Add comments.
9521         * m4/ulonglong.m4: Likewise.
9522
9523 2006-10-10  Bruno Haible  <bruno@clisp.org>
9524
9525         Make it possible to #define stpcpy, strdup to aliases.
9526         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
9527         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
9528
9529 2006-10-10  Bruno Haible  <bruno@clisp.org>
9530
9531         Make it possible to #define gcd to an alias.
9532         * lib/gcd.c: Include config.h.
9533
9534 2006-10-10  Bruno Haible  <bruno@clisp.org>
9535
9536         Make it possible to #define c_isascii to an alias.
9537         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
9538         defined. Undefine the macros before defining them, to avoid gcc
9539         warnings.
9540         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
9541         define NO_C_CTYPE_MACROS early.
9542
9543 2006-10-10  Bruno Haible  <bruno@clisp.org>
9544
9545         Make it possible to #define set_program_name to an alias.
9546         * lib/progname.c: Don't undefine set_program_name; instead, undefine
9547         ENABLE_RELOCATABLE early.
9548
9549 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
9550
9551         Port to Tandem NSK OSS, which has 64-bit signed int but at most
9552         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
9553         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
9554         More generally, don't assume that 64-bit signed int is available
9555         if unsigned int is, and vice versa.
9556         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
9557         unsigned symbols, not on their signed counterparts.
9558         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
9559         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
9560         (UINT64_C, UINTMAX_C):
9561         Likewise.
9562         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
9563         unsigned counterparts.
9564         (Have_long_long, Unsigned): New macros.
9565         (Int): Renamed from INT.
9566         (strtoimax): Use the new macros.
9567         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
9568         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
9569         * modules/inttypes (inttypes.h): Substitute
9570         HAVE_UNSIGNED_LONG_LONG_INT.
9571         * modules/stdint (stdint.h): Likewise.
9572         (Files): Add m4/ulonglong.m4.
9573
9574 2006-10-10  Bruno Haible  <bruno@clisp.org>
9575
9576         Fix a gcc -Wshadow warning.
9577         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
9578         to 'bucket'.
9579         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
9580         gl_linked_indexof_from_to): Likewise.
9581         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
9582         Likewise.
9583         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
9584         Likewise.
9585         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
9586         Reported by Eric Blake.
9587
9588 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
9589
9590         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
9591         for NetBSD.  Problem reported by Bruno Haible.
9592
9593 2006-10-09  Jim Meyering  <jim@meyering.net>
9594
9595         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
9596         Patch from Bruno Haible.
9597
9598 2006-10-09  Jim Meyering  <jim@meyering.net>
9599
9600         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
9601         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
9602         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
9603
9604 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
9605
9606         Don't include <config.h> twice; this doesn't work in some cases,
9607         e.g., when config.h has "#define intmax_t long long int" and
9608         we include <config.h>, <inttypes.h>, <config.h> in that order.
9609         Problem reported by Matthew Woehlke in:
9610         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
9611         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
9612         * lib/fts-cycle.c: Don't include config.h.
9613         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
9614         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
9615         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
9616         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
9617         inttypes.h.
9618         * lib/xstrtoumax.c: Likewise.
9619         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
9620         __strtol and the like, so that this module is more like its siblings.
9621         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
9622         Remove; no longer needed now that we assume gnulib inttypes.h.
9623
9624 2006-10-08  Bruno Haible  <bruno@clisp.org>
9625
9626         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
9627         option.
9628
9629 2006-10-07  Jim Meyering  <jim@meyering.net>
9630
9631         * modules/inttypes (inttypes.h): Revert what seems to have been
9632         an inadvertent part of today's change: use "|", not "/" in the
9633         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
9634
9635 2006-10-07  Bruno Haible  <bruno@clisp.org>
9636
9637         * modules/sublist: New file.
9638
9639 2006-10-07  Bruno Haible  <bruno@clisp.org>
9640
9641         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
9642         * modules/argz (argz.h): Likewise.
9643         * modules/arpa_inet (arpa/inet.h): Likewise.
9644         * modules/byteswap (byteswap.h): Likewise.
9645         * modules/configmake (configmake.h): Likewise.
9646         * modules/fcntl (fcntl.h): Likewise.
9647         * modules/fnmatch (fnmatch.h): Likewise.
9648         * modules/getopt (getopt.h): Likewise.
9649         * modules/glob (glob.h): Likewise.
9650         * modules/inttypes (inttypes.h): Likewise.
9651         * modules/netinet_in (netinet/in.h): Likewise.
9652         * modules/poll (poll.h): Likewise.
9653         * modules/stdbool (stdbool.h): Likewise.
9654         * modules/stdint (stdint.h): Likewise.
9655         * modules/sys_select (sys/select.h): Likewise.
9656         * modules/sys_socket (sys/socket.h): Likewise.
9657         * modules/sys_stat (sys/stat.h): Likewise.
9658         * modules/sysexits (sysexits.h): Likewise.
9659         * modules/unistd (unistd.h): Likewise.
9660         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9661         Add a "DO NOT EDIT" comment to the generated file.
9662         (func_import): Likewise for gnulib-comp.m4.
9663
9664 2006-10-07  Bruno Haible  <bruno@clisp.org>
9665
9666         * lib/gl_sublist.h: New file.
9667         * lib/gl_sublist.c: New file.
9668
9669 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
9670
9671         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
9672         name (relative to the original working directory) and the file
9673         name component (relative to the temporary working directory).  All
9674         callers changed.
9675         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
9676         * lib/mkdir-p.c (make_dir_parents): Likewise.
9677         * lib/mkdir-p.h (make_dir_parents): Likewise.
9678
9679 2006-10-06  Eric Blake  <ebb9@byu.net>
9680
9681         Define several macros for use by the clean-temp module.
9682         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
9683         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
9684         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
9685
9686         * lib/clean-temp.h (close_stream_temp): New declaration.
9687         * lib/clean-temp.c (includes): Pull in headers according to what
9688         other modules are in use.
9689         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
9690
9691 2006-10-06  Bruno Haible  <bruno@clisp.org>
9692
9693         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
9694         instead of fopen, fwriteerror.
9695
9696 2006-10-06  Bruno Haible  <bruno@clisp.org>
9697
9698         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
9699         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
9700         int.
9701         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
9702         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
9703         Return an error indicator.
9704         Suggested by Eric Blake.
9705
9706 2006-10-06  Bruno Haible  <bruno@clisp.org>
9707
9708         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
9709         Reported by Eric Blake.
9710
9711 2006-10-06  Bruno Haible  <bruno@clisp.org>
9712
9713         * modules/closeout (Description): Mention stderr too.
9714
9715 2006-10-06  Bruno Haible  <bruno@clisp.org>
9716         and Paul Eggert  <eggert@cs.ucla.edu>
9717
9718         * lib/closeout.c (close_stdout): Also close stderr.
9719         * lib/closeout.h: Update comment.
9720
9721 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
9722
9723         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
9724         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
9725         * lib/dirchownmod.c: Include lchown.h.
9726         * lib/lchown.c: Don't include files that lchown.h now includes.
9727         Don't declare chown, since lchown.h now does that.
9728         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
9729         (lchown): Define to rpl_chown if lchown is declared but
9730         does not exist.  Declare using a prototype if lchown is not
9731         declared.  Add a copyright notice.
9732         * lib/mkstemp.h: Include <unistd.h>.
9733         * lib/openat.c: Include lchown.h.
9734
9735         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
9736         we now test for that separately.
9737         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
9738         rather than O_NOFOLLOW, when testing whether it's possible to
9739         avoid a race condition reliably.
9740         * lib/savewd.c (savewd_chdir): Likewise.
9741
9742         Remove macros that are no longer needed now that stdint.h is
9743         reliable.
9744         * lib/fsusage.c (UINTMAX_MAX): Remove.
9745         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
9746         * lib/utimecmp.c (SIZE_MAX): Remove.
9747
9748         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
9749
9750         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
9751         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
9752         O_NOATIME works.
9753
9754 2006-10-05  Bruno Haible  <bruno@clisp.org>
9755
9756         * lib/gl_list.h (gl_sortedlist_search_from_to,
9757         gl_sortedlist_indexof_from_to): New declarations.
9758         (gl_list_implementation): New fields sortedlist_search_from_to,
9759         sortedlist_indexof_from_to.
9760         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
9761         inline functions.
9762         * lib/gl_list.c (gl_sortedlist_search_from_to,
9763         gl_sortedlist_indexof_from_to): New functions.
9764         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
9765         function.
9766         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
9767         (gl_array_sortedlist_search_from_to): New function.
9768         (gl_array_list_implementation): Update.
9769         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
9770         function.
9771         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
9772         (gl_carray_sortedlist_search_from_to): New function.
9773         (gl_carray_list_implementation): Update.
9774         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
9775         gl_linked_sortedlist_indexof_from_to): New functions.
9776         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
9777         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
9778         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
9779         gl_tree_sortedlist_indexof_from_to): New functions.
9780         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
9781         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
9782         Update.
9783         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
9784         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
9785         Update.
9786
9787 2006-10-05  Bruno Haible  <bruno@clisp.org>
9788
9789         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
9790         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
9791         (struct gl_list_implementation): Add fields search_from_to,
9792         indexof_from_to. Remove fields search, indexof.
9793         (gl_list_search): Use the search_from_to method.
9794         (gl_list_search_from, gl_list_search_from_to): New functions.
9795         (gl_list_indexof): Use the indexof_from_to method.
9796         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
9797         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
9798         (gl_list_search_from, gl_list_search_from_to): New functions.
9799         (gl_list_indexof): Use the indexof_from_to method.
9800         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
9801         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
9802         gl_array_indexof. Add start_index, end_index arguments.
9803         (gl_array_search_from_to): Renamed from gl_array_search. Add
9804         start_index, end_index arguments.
9805         (gl_array_remove, gl_array_list_implementation): Update.
9806         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
9807         gl_carray_indexof. Add start_index, end_index arguments.
9808         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
9809         start_index, end_index arguments.
9810         (gl_carray_remove, gl_carray_list_implementation): Update.
9811         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
9812         gl_linked_search. Add start_index, end_index arguments.
9813         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
9814         start_index, end_index arguments.
9815         (gl_linked_remove): Update.
9816         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
9817         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
9818         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
9819         field to 'size_t'.
9820         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
9821         gl_tree_search. Add start_index, end_index arguments.
9822         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
9823         start_index, end_index arguments.
9824         (gl_tree_remove): Update.
9825         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
9826         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
9827         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
9828         function.
9829         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
9830         gl_tree_search. Add start_index, end_index arguments.
9831         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
9832         start_index, end_index arguments.
9833         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
9834         Update.
9835         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
9836
9837 2006-10-05  Bruno Haible  <bruno@clisp.org>
9838
9839         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
9840
9841         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
9842         fwriteerror_temp): New declarations.
9843         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
9844         (descriptors): New variable.
9845         (cleanup): First, close the descriptors.
9846         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
9847         fclose_temp, fwriteerror_temp): New functions.
9848
9849 2006-10-04  Jim Meyering  <jim@meyering.net>
9850
9851         * lib/fts.c (fts_open): Tiny comment change.
9852
9853 2006-10-04  Bruno Haible  <bruno@clisp.org>
9854
9855         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
9856         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
9857         gl_LOCK_BODY.
9858         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
9859         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
9860         gl_LOCK_EARLY_BODY.
9861         (gl_LOCK): Require gl_LOCK_BODY.
9862
9863 2006-10-04  Bruno Haible  <bruno@clisp.org>
9864
9865         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
9866         (gl_oset_search_atleast): New declaration.
9867         (struct gl_oset_implementation): Add field 'search_atleast'.
9868         (gl_oset_search_atleast): New inline function.
9869         * lib/gl_oset.c (gl_oset_search_atleast): New function.
9870         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
9871         (gl_array_oset_implementation): Update.
9872         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
9873         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
9874         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
9875
9876 2006-10-04  Bruno Haible  <bruno@clisp.org>
9877
9878         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
9879
9880 2006-10-03  Bruno Haible  <bruno@clisp.org>
9881
9882         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
9883         from gl_avltreehash_list_implementation.
9884
9885 2006-10-03  Bruno Haible  <bruno@clisp.org>
9886
9887         * lib/gl_oset.c (gl_oset_add): Fix return type.
9888
9889 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
9890
9891         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
9892
9893 2006-10-02  Eric Blake  <ebb9@byu.net>
9894
9895         * modules/strnlen (Depends-on): Add extensions.
9896
9897 2006-10-02  Eric Blake  <ebb9@byu.net>
9898
9899         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
9900         definition in 2.60+.
9901
9902 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
9903
9904         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
9905         checks.
9906
9907 2006-10-02  Bruno Haible  <bruno@clisp.org>
9908
9909         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
9910         to the AUTOMAKE_OPTIONS.
9911         Reported by Jim Meyering.
9912
9913 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
9914
9915         Work around bug in Solaris 10 /proc file system:
9916         /proc/self/fd/NNN/.. isn't the parent directory of
9917         the directory whose file descriptor is NNN.  This needs to
9918         be worked around at run time, not compile time, since a
9919         program might be built on Solaris 8, where things work, and
9920         run on Solaris 10.
9921         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
9922         to use the following interface instead:
9923         (OPENAT_BUFFER_SIZE): New macro.
9924         (openat_proc_name): New function.
9925         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
9926         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
9927         Likewise.
9928         * lib/openat-proc.c: New file.
9929         * modules/openat (Files): Add lib/openat-proc.c.
9930         (Depends-on): Add same-inode, stdbool.
9931         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
9932
9933 2006-09-29  Bruno Haible  <bruno@clisp.org>
9934
9935         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
9936         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
9937         argument. Set stdout_closed before testing for ferror, not after.
9938         (fwriteerror, fwriteerror_no_ebadf): New functions.
9939
9940 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9941
9942         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
9943
9944 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
9945
9946         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
9947         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
9948
9949 2006-09-28  Jim Meyering  <jim@meyering.net>
9950
9951         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
9952         Include <unistd.h>.
9953
9954 2006-09-28  Bruno Haible  <bruno@clisp.org>
9955
9956         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
9957         * modules/linkedhash-list (Depends-on): Likewise.
9958         * modules/rbtreehash-list (Depends-on): Likewise.
9959
9960 2006-09-28  Bruno Haible  <bruno@clisp.org>
9961
9962         * lib/strndup.h: Simplify the redefinition of strndup.
9963         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
9964         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
9965
9966 2006-09-28  Bruno Haible  <bruno@clisp.org>
9967
9968         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
9969         * lib/gl_linkedhash_list.c: Likewise.
9970         * lib/gl_rbtreehash_list.c: Likewise.
9971
9972 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
9973
9974         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
9975         getaddrinfo.
9976
9977         * lib/__fpending.h: Don't include <stdio_ext.h> unless
9978         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
9979         it causes <stdio_ext.h> to cause a compile-time error.
9980         Problem reported by Nelson H. F. Beebe.
9981         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
9982         of HAVE_DECL___PENDING.
9983
9984         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
9985         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
9986         declaration.
9987
9988 2006-09-27  Jim Meyering  <jim@meyering.net>
9989
9990         This file could end up with a definition for a function
9991         named __strndup, rather than rpl_strndup on a system with
9992         incomplete weak_alias support.
9993         * lib/strndup.c (strndup): Rename from __strndup.
9994         Remove #defines that used to map __strndup to strndup.
9995         Don't use K&R prototypes.
9996         Remove LIBC-related code, since this file is not sync'd with glibc.
9997         * lib/strndup.h: Revamp, accordingly.
9998         * m4/strndup.m4: Modernize.
9999
10000 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
10001
10002         * modules/savewd (Depends-on): Add 'raise'.
10003         * lib/savewd.c: Include <signal.h>, for 'raise'.
10004
10005 2006-09-26  Jim Meyering  <jim@meyering.net>
10006
10007         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
10008         when we detect Darwin 8.7.0's acl_get_file bug.
10009         Rearrange to perform the new (below) run-test while $LIBS
10010         contains any acl-related library.  Set USE_ACL at the end.
10011         (gl_ACL_GET_FILE): New function.
10012
10013 2006-09-26  Eric Blake  <ebb9@byu.net>
10014
10015         * lib/verror.c: Include <config.h> unconditionally.
10016
10017 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
10018
10019         * modules/clock-time (Maintainer): Add self.
10020         * modules/getlogin_r (Depends-on): Add extensions.
10021
10022 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10023
10024         * modules/clock-time: New module.
10025         * modules/nanosleep (Depends-on): Add clock-time.
10026         * modules/gethrxtime (Depends-on): Likewise.
10027         * modules/gettime (Depends-on): Likewise.
10028         * modules/settime (Depends-on): Likewise.
10029
10030         * modules/fts-lgpl: Depend on openat.
10031         * modules/mkancesdirs: Depend on savewd.
10032         * modules/mkdir-p: Likewise.
10033
10034 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10035
10036         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
10037
10038         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
10039         `gl_have_arbitrary_file_name_length_limit' to
10040         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
10041         actually works between configure runs.
10042
10043 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10044             Bruno Haible  <bruno@clisp.org>
10045
10046         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
10047
10048 2006-09-25  Jim Meyering  <jim@meyering.net>
10049
10050         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
10051         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
10052
10053 2006-09-25  Eric Blake  <ebb9@byu.net>
10054
10055         * gnulib-tool (func_import, func_create_testdir): Fix typos in
10056         exec's in 2006-09-18 patch when shuffling fds.
10057
10058 2006-09-25  Bruno Haible  <bruno@clisp.org>
10059
10060         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
10061         Reported by Jim Meyering.
10062
10063 2006-09-24  Jim Meyering  <jim@meyering.net>
10064
10065         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
10066         compare a pointer against a literal "0".  That caused failures with
10067         at least HP-UX's hpcc.
10068
10069 2006-09-22  Simon Josefsson  <jas@extundo.com>
10070
10071         * modules/gc-sha1:
10072         * modules/gc-md4:
10073         * modules/gc-hmac-sha1:
10074         * modules/gc-hmac-md5:
10075         * modules/gc-des:
10076         * modules/gc-arcfour: Distribute more files.
10077
10078 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10079
10080         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
10081         (gl_linked_iterator_from_to): Initialize struct completely.
10082         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
10083         (gl_tree_iterator_from_to): Likewise
10084         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
10085         * lib/gl_array_list.c [lint] (gl_array_iterator)
10086         (gl_array_iterator_from_to): Likewise.
10087         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
10088         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
10089         (gl_carray_iterator_from_to): Likewise.
10090
10091         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
10092         * lib/md4.c (md4_process_block): Remove unused variable.
10093         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
10094         parentheses for clarity.
10095
10096 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10097
10098         * modules/bison-i18n (Depends-on): Add gettext.
10099
10100 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10101
10102         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
10103         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
10104         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
10105         also add missing comma that caused broken test.
10106         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
10107         stdlib.h, for `abort'.
10108         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
10109         variables.
10110         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
10111         include unistd.h if present, for `rmdir'.
10112         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
10113         variables.
10114         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
10115         in the process include standard headers for prototypes.
10116         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
10117         gets declared on GNU/Linux.
10118         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
10119         unistd.h, for `rmdir'.
10120         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
10121
10122         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
10123         always true.
10124         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
10125
10126         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
10127
10128 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10129
10130         * gnulib-tool (func_version): Create output all at once.  This
10131         may help avoid triggering unnecessary SIGPIPEs, and at any
10132         rate it doesn't hurt.
10133
10134 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10135             Bruno Haible  <bruno@clisp.org>
10136
10137         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
10138         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
10139         * m4/signed.m4 (bh_C_SIGNED): Likewise.
10140
10141         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
10142         (gl_FUNC_VASPRINTF): Invoke it.
10143
10144 2006-09-22  Bruno Haible  <bruno@clisp.org>
10145
10146         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
10147         getloadavg.c as first argument.
10148
10149 2006-09-22  Bruno Haible  <bruno@clisp.org>
10150
10151         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
10152         at the beginning of the gl_INIT macro.
10153         * modules/getloadavg (configure.ac): Pass $gl_source_base to
10154         gl_GETLOADAVG.
10155
10156 2006-09-22  Bruno Haible  <bruno@clisp.org>
10157
10158         * gnulib-tool (func_create_megatestdir): Don't include the config-h
10159         module.
10160         Suggested by Ralf Wildenhues.
10161
10162 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
10163
10164         Import this patch from libc:
10165
10166         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
10167
10168         * lib/regex_internal.c (re_string_reconstruct): Handle
10169         offset < pstr->valid_raw_len && pstr->offsets_needed case.
10170         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
10171         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
10172         re_string_context_at.
10173
10174         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
10175         now requires it.
10176         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
10177         gl_REGEX now does it for us.
10178         (gl_REGEX): Add test taken from
10179         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
10180
10181         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
10182         Check that large offsets work.  Modernize Autoconf usages.
10183         Prefer "yes" to mean a good thing rather than a bad.
10184         Don't put "#define mkstemp" in config.h, as this might interfere
10185         with standard system headers that "#define mkstemp mkstemp64".
10186
10187         * modules/mkstemp (Depends-on): Add extensions, so that
10188         mkstemp is visible on some platforms.
10189         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
10190         (Include): Change to "mkstemp.h" from <stdlib.h>.
10191         (Files): Add mkstemp.h.
10192
10193         * lib/mkstemp.h: New file, since some standard headers
10194         #define mkstemp.
10195         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
10196         Include "mkstemp.h".
10197         Make the _LIBC code resemble glibc original more,
10198         e.g., use K&R style.
10199         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
10200         (mkstemp): Remove, since mkstemp.h does this for us.
10201         * lib/stdlib--.h: Include mkstemp.h.
10202
10203         Import this patch from libc:
10204
10205         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10206
10207         * lib/tempname.c (__gen_tempname): Change attempts_min
10208         into a macro.  Use preprocessor to decide how to initialize
10209         attempts [Coverity CID 67].
10210
10211 2006-09-20  Bruno Haible  <bruno@clisp.org>
10212
10213         * lib/mkdtemp.c: Import from libc.
10214         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10215                 * sysdeps/posix/tempname.c (__gen_tempname): Change
10216                 attempts_min into a macro.  Use preprocessor to decide how to
10217                 initialize attempts [Coverity CID 67].
10218         2001-11-27  Paul Eggert  <eggert@twinsun.com>
10219                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
10220                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
10221
10222 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10223
10224         * gnulib-tool (func_exit): New function, to allow to pass the
10225         exit status portably through the trap.  Use everywhere.
10226         (--help, --version): Signal a write error.
10227         (trap): catch SIGPIPE, for write errors.
10228         Exit at the end of the trap, with the correct exit status.
10229
10230 2006-09-19  Karl Berry  <karl@gnu.org>
10231
10232         * doc/gnulib.texi: note about the license texinfo files.
10233
10234 2006-09-19  Eric Blake  <ebb9@byu.net>
10235
10236         * gnulib-tool: Avoid space-tab.
10237
10238 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10239
10240         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
10241         that prevented coreutils 6.1 from building.  Problem reported
10242         by Petter Reinholdtsen.
10243
10244 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10245
10246         * gnulib-tool (avoidlist): Fix typo that broke options like
10247         --avoid=lock that are used by coreutils bootstrap.
10248
10249 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
10250
10251         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
10252         more systematically.
10253
10254 2006-09-18  Jim Meyering  <jim@meyering.net>
10255
10256         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
10257
10258 2006-09-18  Bruno Haible  <bruno@clisp.org>
10259
10260         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
10261
10262 2006-09-18  Bruno Haible  <bruno@clisp.org>
10263
10264         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
10265         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
10266         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
10267         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
10268         * m4/gettext.m4: Require autoconf >= 2.52.
10269         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
10270         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
10271         of gl_cv_header_inttypes_h.
10272
10273 2006-09-18  Bruno Haible  <bruno@clisp.org>
10274
10275         * lib/javaversion.c: Include configmake.h.
10276
10277 2006-09-18  Bruno Haible  <bruno@clisp.org>
10278
10279         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
10280         avoid that the while loops be executed in a subshell.
10281
10282 2006-09-18  Bruno Haible  <bruno@clisp.org>
10283
10284         * MODULES.html.sh (func_module): Break long lines.
10285         Suggested by Bruce Korb <bkorb@gnu.org>.
10286
10287 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10288
10289         Speed up by a factor of 1.12.
10290         * gnulib-tool (nl): New variable.
10291         (func_import): Rewrite include directive extraction to only read each
10292         directive once.
10293
10294 2006-09-17  Bruno Haible  <bruno@clisp.org>
10295
10296         * modules/javaversion (Makefile.am): Remove DEFS setting.
10297         (Depends-on): Add configmake, for PKGDATADIR definition.
10298
10299 2006-09-17  Bruno Haible  <bruno@clisp.org>
10300
10301         * gnulib-tool (func_create_testdir): Rewrite all files at once.
10302
10303 2006-09-17  Bruno Haible  <bruno@clisp.org>
10304
10305         * gnulib-tool (func_append): New function, stolen from libtool.m4.
10306         (func_modules_transitive_closure, func_modules_add_dummy,
10307         func_modules_to_filelist, func_import, func_create_testdir,
10308         func_create_megatestdir, ...): Use it wherever possible.
10309         Suggested by Ralf Wildenhues.
10310
10311 2006-09-16  Karl Berry  <karl@gnu.org>
10312
10313         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
10314         to avoid sectioning errors.
10315         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
10316         [ifinfo]: blank line after @center-ed titles.
10317         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
10318         Spell FSF address consistently with others.
10319         (These changes approved by rms.)
10320
10321 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10322
10323         Speed up by a factor of 1.61.
10324         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
10325         already checked module names again.
10326
10327 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10328
10329         Speed up by a factor of 1.13.
10330         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
10331         for new_files, and the input to func_add_or_update.
10332
10333 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10334
10335         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
10336         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
10337
10338 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10339
10340         * modules/mkancesdirs (Depends-on): Add fcntl.
10341         * modules/savewd: New file.
10342         * MODULES.html.sh (File system functions): Add savewd.
10343
10344         * modules/configmake (Makefile.am): Add support for the
10345         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
10346
10347 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10348
10349         * m4/savewd.m4: New file.
10350
10351 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10352
10353         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
10354         (dirchownmod): New arg FD.  All callers changed.
10355         Use FD rather than opening the directory ourself, as opening is
10356         now the caller's responsibility.
10357         * lib/dirchownmod.h: Likewise.
10358         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
10359         hosts that require <sys/types.h> before <sys/stat.h>.  Include
10360         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
10361         (test_dir): Remove.
10362         (mkancesdirs): Return length of prefix of FILE that has already
10363         been made, or -2 if there is a child doing the work.  Redo
10364         algorithm so that it is O(N) rather than O(N**2).  Optimize away
10365         ".", and treat ".." specially since it might stray back into
10366         already-created areas.  Use a subprocess if necessary.  New arg
10367         WD; all users changed.  MAKE_DIR function should now return 1
10368         if it creates a directory that is not readable.  Return -2 if
10369         a child process is spun off.
10370         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
10371         Adjust signature to match code.
10372         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
10373         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
10374         all users changed.
10375         * lib/savewd.c, lib/savewd.h: New files.
10376
10377 2006-09-15  Jim Meyering  <jim@meyering.net>
10378
10379         * modules/rename-dest-slash: New module.
10380         * MODULES.html.sh (posix_compat): Add it here.
10381
10382         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
10383
10384 2006-09-15  Jim Meyering  <jim@meyering.net>
10385
10386         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
10387         file.
10388
10389         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
10390
10391 2006-09-15  Jim Meyering  <jim@meyering.net>
10392
10393         * lib/rename-dest-slash.c (has_trailing_slash): Use
10394         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
10395         (rpl_rename_dest_slash): Perform the cheaper trailing slash
10396         test before testing whether SRC is a directory.
10397         Suggestions from Bruno Haible.
10398
10399         Avoid a warning about an unused variable.
10400         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
10401         into the #ifdef block where it's used.
10402
10403         * lib/rename-dest-slash.c: New file.
10404
10405 2006-09-14  Bruno Haible  <bruno@clisp.org>
10406
10407         * lib/allocsa.c: Include <config.h> unconditionally.
10408         * lib/asnprintf.c: Likewise.
10409         * lib/asprintf.c: Likewise.
10410         * lib/c-strcasecmp.c: Likewise.
10411         * lib/c-strcasestr.c: Likewise.
10412         * lib/c-strncasecmp.c: Likewise.
10413         * lib/c-strstr.c: Likewise.
10414         * lib/classpath.c: Likewise.
10415         * lib/clean-temp.c: Likewise.
10416         * lib/concatpath.c: Likewise.
10417         * lib/copy-file.c: Likewise.
10418         * lib/csharpcomp.c: Likewise.
10419         * lib/csharpexec.c: Likewise.
10420         * lib/execute.c: Likewise.
10421         * lib/fatal-signal.c: Likewise.
10422         * lib/findprog.c: Likewise.
10423         * lib/fwriteerror.c: Likewise.
10424         * lib/gl_array_list.c: Likewise.
10425         * lib/gl_array_oset.c: Likewise.
10426         * lib/gl_avltree_list.c: Likewise.
10427         * lib/gl_avltree_oset.c: Likewise.
10428         * lib/gl_avltreehash_list.c: Likewise.
10429         * lib/gl_carray_list.c: Likewise.
10430         * lib/gl_linked_list.c: Likewise.
10431         * lib/gl_linkedhash_list.c: Likewise.
10432         * lib/gl_list.c: Likewise.
10433         * lib/gl_oset.c: Likewise.
10434         * lib/gl_rbtree_list.c: Likewise.
10435         * lib/gl_rbtree_oset.c: Likewise.
10436         * lib/gl_rbtreehash_list.c: Likewise.
10437         * lib/imaxabs.c: Likewise.
10438         * lib/imaxdiv.c: Likewise.
10439         * lib/javacomp.c: Likewise.
10440         * lib/javaexec.c: Likewise.
10441         * lib/javaversion.c: Likewise.
10442         * lib/linebreak.c: Likewise.
10443         * lib/localcharset.c: Likewise.
10444         * lib/lock.c: Likewise.
10445         * lib/mbchar.c: Likewise.
10446         * lib/mbswidth.c: Likewise.
10447         * lib/mkdtemp.c: Likewise.
10448         * lib/pipe.c: Likewise.
10449         * lib/printf-args.c: Likewise.
10450         * lib/printf-parse.c: Likewise.
10451         * lib/progname.c: Likewise.
10452         * lib/progreloc.c: Likewise.
10453         * lib/readlink.c: Likewise.
10454         * lib/sh-quote.c: Likewise.
10455         * lib/stpcpy.c: Likewise.
10456         * lib/stpncpy.c: Likewise.
10457         * lib/strcasecmp.c: Likewise.
10458         * lib/strcasestr.c: Likewise.
10459         * lib/strcspn.c: Likewise.
10460         * lib/striconv.c: Likewise.
10461         * lib/strncasecmp.c: Likewise.
10462         * lib/strnlen1.c: Likewise.
10463         * lib/strstr.c: Likewise.
10464         * lib/strtok_r.c: Likewise.
10465         * lib/tls.c: Likewise.
10466         * lib/tmpdir.c: Likewise.
10467         * lib/unicodeio.c: Likewise.
10468         * lib/unsetenv.c: Likewise.
10469         * lib/vasnprintf.c: Likewise.
10470         * lib/vasprintf.c: Likewise.
10471         * lib/wait-process.c: Likewise.
10472         * lib/xallocsa.c: Likewise.
10473         * lib/xsetenv.c: Likewise.
10474         * lib/xstriconv.c: Likewise.
10475
10476 2006-09-13  Simon Josefsson  <jas@extundo.com>
10477
10478         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
10479         that internally, suggested by Ralf Wildenhues
10480         <Ralf.Wildenhues@gmx.de>.
10481
10482 2006-09-13  Simon Josefsson  <jas@extundo.com>
10483
10484         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
10485         @LIBOBJS@.
10486         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10487
10488 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
10489
10490         * lib/_fpending.c: Include <config.h> unconditionally, since we no
10491         longer worry about uses that don't define HAVE_CONFIG_H.
10492         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
10493         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
10494         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
10495         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
10496         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
10497         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
10498         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
10499         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
10500         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
10501         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
10502         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
10503         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
10504         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
10505         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
10506         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
10507         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
10508         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
10509         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
10510         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
10511         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
10512         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
10513         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
10514         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
10515         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
10516         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
10517         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
10518         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
10519         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
10520         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
10521         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
10522         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
10523         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
10524         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
10525         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
10526         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
10527         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
10528         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
10529         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
10530         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
10531         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
10532         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
10533         Likewise.
10534
10535 2006-09-13  Eric Blake  <ebb9@byu.net>
10536
10537         * lib/getopt.c: Fix typo in last commit.
10538
10539 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
10540
10541         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
10542         dgettext.
10543
10544 2006-09-12  Jim Meyering  <jim@meyering.net>
10545
10546         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
10547         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
10548         Reported by Nelson H. F. Beebe.
10549
10550 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
10551
10552         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
10553         program_invocation_name and program_invocation_short_name are
10554         initialized.
10555         * lib/argp-namefrob.h: Move declarations of program_invocation_name
10556         and program_invocation_short_name to argp.h, so they are visible
10557         to user programs.
10558         * lib/argp.h: Likewise
10559
10560 2006-09-10  Bruno Haible  <bruno@clisp.org>
10561
10562         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
10563         m4/inttypes_h.m4, m4/uintmax_t.m4.
10564
10565 2006-09-10  Bruno Haible  <bruno@clisp.org>
10566
10567         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
10568         gl_AC_TYPE_UINTMAX_T.
10569
10570 2006-09-10  Bruno Haible  <bruno@clisp.org>
10571
10572         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
10573
10574 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
10575
10576         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
10577         convention.  Text proposed by Bruno Haible.
10578         (struct argp_option): Document the use of N_() wrappers.
10579
10580         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
10581         '\v', and translate the two parts separately, instead of feeding
10582         the whole string to gettext.  This allows to exclude
10583         '\v' from the strings visible to the translator by writing doc
10584         strings as N_("..") "\v" N_("..").
10585
10586 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
10587
10588         * config/srclist.txt: Undo latest change; the bug was fixed.
10589
10590 2006-09-09  Bruno Haible  <bruno@clisp.org>
10591
10592         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
10593         assignments if building a library without libtool.
10594         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
10595         in func_emit_lib_Makefile_am.
10596         (func_import): When building a static library libfoo.a, arrange to
10597         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
10598         (func_create_testdir): Likewise.
10599         * modules/gc (configure.ac, Makefile.am): If building statically,
10600         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
10601         * modules/iconvme (configure.ac, Makefile.am): Likewise.
10602         * modules/striconv (configure.ac, Makefile.am): Likewise.
10603         Based on a suggestion by Ralf Wildenhues.
10604
10605 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10606
10607         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
10608         Check for unistd.h too, since Autoconf doesn't assume POSIX.
10609         Also:
10610
10611         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10612         Add year_2050_test to catch glibc bug 2821
10613         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
10614
10615         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10616         Prefer #ifdef to #if.
10617
10618         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
10619         Return from 'main' instead of calling 'exit'.
10620
10621 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10622
10623         * lib/mktime.c (guess_time_tm): Fix bug where mktime
10624         returned the maximum time_t value rather than (time_t) -1.
10625         Problem originally reported by William Bardwell
10626         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
10627
10628         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
10629         Moved to here ...
10630         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
10631         ... from here.
10632
10633 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
10634
10635         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
10636         2821 is fixed.
10637
10638 2006-09-08  Jim Meyering  <jim@meyering.net>
10639
10640         Don't make generated files read-only.  That would bother too many
10641         people.  However, do retain the ability to work when targets are
10642         read-only: remove the destination and temporary files before writing
10643         them (when generated via sed or echo), or by using the -f option for
10644         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
10645         * modules/alloca-opt, modules/argz, modules/arpa_inet:
10646         * modules/byteswap, modules/configmake, modules/fcntl:
10647         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
10648         * modules/localcharset, modules/netinet_in, modules/poll:
10649         * modules/stdbool, modules/stdint, modules/sys_select:
10650         * modules/sys_socket, modules/sys_stat, modules/sysexits:
10651
10652 2006-09-08  Jim Meyering  <jim@meyering.net>
10653
10654         Avoid new build failure on FreeBSD 6.0.
10655         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
10656         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
10657         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
10658
10659 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10660
10661         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
10662
10663 2006-09-07  Jim Meyering  <jim@meyering.net>
10664
10665         Fix global typo in last change: use chmod u-w, not chmod u-x.
10666         Spotted by Paul Eggert and Bruce Korb.
10667         * modules/alloca-opt, modules/argz, modules/arpa_inet:
10668         * modules/byteswap, modules/configmake, modules/fcntl:
10669         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
10670         * modules/localcharset, modules/netinet_in, modules/poll:
10671         * modules/stdbool, modules/stdint, modules/sys_select:
10672         * modules/sys_socket, modules/sys_stat, modules/sysexits:
10673
10674 2006-09-06  Jim Meyering  <jim@meyering.net>
10675
10676         Make generated files be read-only.
10677         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
10678         Ensure that each generated file is now read-only.
10679         * modules/argz: Likewise.
10680         * modules/arpa_inet: Likewise.
10681         * modules/byteswap: Likewise.
10682         * modules/configmake: Likewise.
10683         * modules/fcntl: Likewise.
10684         * modules/fnmatch: Likewise.
10685         * modules/getopt: Likewise.
10686         * modules/glob: Likewise.
10687         * modules/inttypes: Likewise.
10688         * modules/netinet_in: Likewise.
10689         * modules/poll: Likewise.
10690         * modules/stdbool: Likewise.
10691         * modules/stdint: Likewise.
10692         * modules/sys_select: Likewise.
10693         * modules/sys_socket: Likewise.
10694         * modules/sys_stat: Likewise.
10695         * modules/sysexits: Likewise.
10696         * modules/localcharset: Same as above, but continue using temporary
10697         file named "t-$@" (why different?) rather than the "$@-t" used
10698         everywhere else.
10699
10700         * modules/sysexits (Makefile.am): Replace literal occurrences
10701         of "sysexit.h" more readable, and more consistent, "$@".
10702
10703 2006-09-06  Bruno Haible  <bruno@clisp.org>
10704
10705         * modules/striconv: New file.
10706         * modules/xstriconv: New file.
10707         * MODULES.html.sh (Internationalization functions): Add striconv,
10708         xstriconv.
10709
10710 2006-09-06  Bruno Haible  <bruno@clisp.org>
10711
10712         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
10713         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
10714         not using libtool correctly.
10715
10716 2006-09-06  Bruno Haible  <bruno@clisp.org>
10717
10718         * lib/striconv.h: New file.
10719         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
10720         iconvstring.c.
10721         * lib/xstriconv.h: New file.
10722         * lib/xstriconv.c: New file.
10723
10724 2006-09-06  Bruno Haible  <bruno@clisp.org>
10725
10726         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
10727         lib_..._LDFLAGS.
10728
10729 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10730
10731         * lib/argz_.h: Sync from Libtool.
10732
10733         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
10734                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
10735
10736         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
10737
10738 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
10739
10740         * modules/trim: New file.
10741
10742 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
10743
10744         * lib/trim.h: New file.
10745         * lib/trim.c: New file.
10746
10747 2006-09-05  Bruno Haible  <bruno@clisp.org>
10748
10749         * MODULES.html.sh (String handling): Add trim.
10750
10751 2006-09-04  Karl Berry  <karl@gnu.org>
10752
10753         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
10754         until next release.
10755
10756 2006-09-03  Bruno Haible  <bruno@clisp.org>
10757
10758         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
10759         correctly.
10760
10761 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10762
10763         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
10764         not gl_GETLOADAVG.  Omit unneeded semicolons.
10765         Problems reported by Ralf Wildenhues in
10766         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
10767         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
10768         at the end, which is the usual gnulib style.
10769
10770         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
10771         of doing all the work ourselves.
10772         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
10773         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
10774
10775 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10776
10777         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
10778         Problem reported by Ralf Wildenhues in
10779         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
10780
10781         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
10782         HAVE_STRUCT_STATFS_F_FSTYPENAME.
10783
10784 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
10785
10786         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
10787         yesterday's patch by changing test -n to test -z.
10788
10789 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10790
10791         * modules/getloadavg (Files): Add m4/getloadavg.m4.
10792         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
10793         the former is now obsolescent.
10794
10795         * modules/chdir-long (Depends-on): Add fcntl.
10796
10797 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10798
10799         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
10800         obsolescent, and programs should use gnulib instead.
10801         * m4/getloadavg.m4: New file, with contents taken from Autoconf
10802         but with prefixes changed.
10803
10804 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
10805
10806         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
10807         or stdbool.h, because they might not exist while configuring.
10808
10809         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
10810         Don't include unistd.h or limits.h; not needed, since chdir-long.h
10811         does that for us.
10812         (O_DIRECTORY): Remove.
10813
10814 2006-08-31  Eric Blake  <ebb9@byu.net>
10815
10816         * gnulib-tool: Don't let emacs change spaces to TAB.
10817
10818 2006-08-31  Bruno Haible  <bruno@clisp.org>
10819
10820         * gnulib-tool: When calling func_import more than once, do it in a
10821         subshell.
10822         Reported by Eric Blake <ebb9@byu.net>.
10823
10824 2006-08-31  Bruno Haible  <bruno@clisp.org>
10825
10826         * gnulib-tool (nl): Remove variable.
10827         (sed_transform_lib_file): Use more robust test for config-h module.
10828         (func_import): Fix typo in 2006-08-25 patch.
10829
10830 2006-08-31  Bruno Haible  <bruno@clisp.org>
10831
10832         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
10833         specified, augment Makefile.am variables instead of assigning them.
10834
10835 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10836
10837         Work around a bug in both the Linux and SunOS 64-bit kernels:
10838         nanosleep mishandles sleeps for longer than 2**31 seconds.
10839         Problem reported by Frank v Waveren in
10840         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
10841         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
10842         Check for nanosleep bug.
10843         (LIB_NANOSLEEP): Append clock_gettime library if needed.
10844
10845 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10846
10847         Work around a bug in both the Linux and SunOS 64-bit kernels:
10848         nanosleep mishandles sleeps for longer than 2**31 seconds.
10849         Problem reported by Frank v Waveren in
10850         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
10851         * lib/nanosleep.c (BILLION): New constant.
10852         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
10853         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
10854         implementation.
10855
10856 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10857
10858         * modules/nanosleep (Depends-on): Add gettime.
10859
10860 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
10861         and Simon Josefsson  <jas@extundo.com>
10862         and Oskar Liljeblad  <oskar@osk.mine.nu>
10863
10864         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
10865         * gnulib-tool (func_import): New license type 'unmodifiable license
10866         text'.
10867         * modules/fdl: Use it.  Longer description.
10868         * module/gpl, module/lgpl: New files.
10869
10870 2006-08-30  Jim Meyering  <jim@meyering.net>
10871
10872         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
10873         shadowing the parameter.
10874
10875 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10876
10877         Sync from Libtool:
10878
10879         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10880
10881         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
10882         sharing with gnulib.  Report by Eric Blake.
10883
10884 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10885
10886         * modules/isapipe: New file.
10887         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
10888
10889 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10890
10891         * modules/configmake (Makefile.am): Add a comment, and omit
10892         the CONFIGMAKE_ prefix from generated macro names.  Suggested
10893         by Bruno Haible.
10894
10895 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10896
10897         * m4/isapipe.m4: New file.
10898
10899 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
10900
10901         * lib/isapipe.c, lib/isapipe.h: New files.
10902
10903 2006-08-29  Jim Meyering  <jim@meyering.net>
10904
10905         * modules/configmake (Makefile.am): Make configmake.h depend on
10906         Makefile.  Otherwise, a stale configmake.h could hang around.
10907
10908 2006-08-29  Eric Blake  <ebb9@byu.net>
10909
10910         * lib/error.c (error_at_line, print_errno_message): Match libc, after
10911         resolution of upstream bug 3044.
10912
10913 2006-08-29  Bruno Haible  <bruno@clisp.org>
10914
10915         * modules/localcharset (Depends-on): Add configmake.
10916         (Makefile.am): Remove setting of LIBDIR through DEFS.
10917
10918 2006-08-29  Bruno Haible  <bruno@clisp.org>
10919
10920         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
10921         defined.
10922
10923 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10924
10925         * modules/fcntl: New file.
10926         * modules/chdir-safer (Depends-on): Add fcntl.
10927         * modules/fts: Likewise.
10928         * modules/mkdir-p: Likewise.
10929
10930         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
10931         This undoes the most recent change, since we're now addressing the
10932         problem in a different way.
10933
10934         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
10935         into output, since the output might be called Makefile.am even
10936         if $makefile_name is something different.
10937         (func_import): Use $makefile_am rather than
10938         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
10939         empty.
10940
10941         * modules/inttypes (Files): Add m4/inttypes-h.m4.
10942
10943 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10944
10945         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
10946         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
10947         recent change to stdint.m4, since we're now addressing the problem in a
10948         different way.
10949
10950 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10951
10952         * m4/fcntl_h.m4: New file.
10953
10954 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
10955
10956         * lib/fcntl_.h: New file.
10957         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
10958         the fcntl module.
10959         * lib/dirchownmod.c: Likewise.
10960         * lib/fts.c: Likewise.
10961
10962         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
10963         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
10964         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
10965         just before including <inttypes.h>, to avoid circular inclusion.
10966
10967 2006-08-28  Jim Meyering  <jim@meyering.net>
10968
10969         * doc/visibility.texi: Actually read and correct the grammar of the
10970         sentence affected by yesterday's change.
10971
10972 2006-08-28  Eric Blake  <ebb9@byu.net>
10973
10974         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
10975         needs wrapper.
10976
10977 2006-08-28  Eric Blake  <ebb9@byu.net>
10978
10979         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
10980
10981 2006-08-28  Eric Blake  <ebb9@byu.net>
10982
10983         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
10984
10985 2006-08-28  Bruno Haible  <bruno@clisp.org>
10986
10987         * modules/c-strstr: New file, from GNU gettext.
10988         * MODULES.html.sh (String handling): Add c-strstr.
10989
10990 2006-08-28  Bruno Haible  <bruno@clisp.org>
10991
10992         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
10993         macros.
10994         Reported by Eric Blake.
10995
10996 2006-08-28  Bruno Haible  <bruno@clisp.org>
10997
10998         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
10999         (VASNPRINTF): Return a string of length > INT_MAX without failing.
11000         * lib/vasprintf.c: Include errno.h, limits.h.
11001         (EOVERFLOW): New fallback definition.
11002         (vasprintf): Test here whether the string length is > INT_MAX.
11003         * lib/vsnprintf.c: Include errno.h, limits.h.
11004         (EOVERFLOW): New fallback definition.
11005         (vsnprintf): Fix bug when generated string was too long for the buffer.
11006         Test here whether the string length is > INT_MAX.
11007
11008 2006-08-28  Bruno Haible  <bruno@clisp.org>
11009
11010         * lib/inttypes_.h (SCNX*): Remove definitions.
11011         Reported by Eric Blake.
11012
11013 2006-08-28  Bruno Haible  <bruno@clisp.org>
11014
11015         * lib/c-strstr.h: New file, from GNU gettext.
11016         * lib/c-strstr.c: New file, from GNU gettext.
11017
11018 2006-08-28  Bruno Haible  <bruno@clisp.org>
11019
11020         * gnulib-tool: Reorder some statements.
11021
11022 2006-08-28  Bruno Haible  <bruno@clisp.org>
11023
11024         * gnulib-tool: New option --makefile-name.
11025         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
11026         $makefile_name.
11027         (func_import): Write $makefile_name to the cache file, and read it from
11028         there unless explicitly specified. Use $makefile_name as file name
11029         instead of Makefile.am. Adjust the recommendations accordingly.
11030
11031 2006-08-28  Bruno Haible  <bruno@clisp.org>
11032
11033         * gnulib-tool (func_verify_module): Check against misapplying patch.
11034
11035 2006-08-28  Bruno Haible  <bruno@clisp.org>
11036
11037         * gnulib-tool (func_relativize, func_relconcat): New functions.
11038         Give an error if --local-dir is given with --update.
11039         Remove trailing slashes from $local_gnulib_dir.
11040         (func_import): Store the relativized $local_gnulib_dir in
11041         gnulib-cache.m4, and read it from there if not specified explicitly.
11042
11043 2006-08-28  Bruno Haible  <bruno@clisp.org>
11044
11045         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
11046         is the current directory. Respect also $local_gnulib_dir.
11047
11048 2006-08-28  Bruno Haible  <bruno@clisp.org>
11049             Simon Josefsson  <jas@extundo.com>
11050
11051         BeOS portability.
11052         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
11053
11054 2006-08-27  Jim Meyering  <jim@meyering.net>
11055
11056         * doc/visibility.texi: Remove duplicate word: "pointer".
11057
11058 2006-08-26  Bruno Haible  <bruno@clisp.org>
11059
11060         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
11061         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
11062         (Makefile.am): Create inttypes.h from inttypes_.h.
11063         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
11064
11065         * modules/imaxabs: New file.
11066
11067         * modules/imaxdiv: New file.
11068
11069 2006-08-26  Bruno Haible  <bruno@clisp.org>
11070
11071         * m4/inttypes.m4: New file.
11072         * m4/_inttypes_h.m4: Remove file.
11073         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
11074         PRI_MACROS_BROKEN.
11075         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
11076
11077         * m4/imaxabs.m4: New file.
11078
11079         * m4/imaxdiv.m4: New file.
11080
11081 2006-08-26  Bruno Haible  <bruno@clisp.org>
11082
11083         * lib/inttypes_.h: New file.
11084         * lib/inttypes.h: Remove file.
11085         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
11086
11087         * lib/imaxabs.c: New file.
11088
11089         * lib/imaxdiv.c: New file.
11090
11091 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11092
11093         New config-h module, so that "make" output needn't be cluttered
11094         by -DHAVE_CONFIG_H.
11095         * MODULES.html.sh (Support for building libraries and executables):
11096         Add config-h.
11097         * modules/config-h: New file.
11098         * gnulib-tool (nl, sed_transform_lib_file): New vars.
11099         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
11100         the config-h module is used.
11101
11102         New configmake module, so that "make" output needn't be cluttered
11103         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
11104         * MODULES.html.sh (Support for building libraries and executables):
11105         Add configmake.
11106         * modules/configmake: New file.
11107
11108 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11109
11110         * m4/config-h.m4: New file.
11111
11112 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11113
11114         * config/srclist.txt: Add elisp-comp.
11115
11116 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11117
11118         * MODULES.html.sh (Support for building libraries and executables):
11119         Add elisp-comp.
11120         * build-aux/elisp-comp: New file.
11121         * modules/elisp-comp: New file.
11122
11123 2006-08-24  Bruno Haible  <bruno@clisp.org>
11124
11125         * gnulib-tool (func_create_testdir): Use non-default values of
11126         sourcebase and m4base.
11127
11128 2006-08-24  Bruno Haible  <bruno@clisp.org>
11129
11130         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
11131         HTML structure.
11132
11133 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11134
11135         * modules/openat (Depends-on): Add lchown.
11136
11137 2006-08-23  Bruno Haible  <bruno@clisp.org>
11138
11139         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
11140         of gl_LOCK_EARLY instead of gl_LOCK.
11141
11142 2006-08-23  Bruno Haible  <bruno@clisp.org>
11143
11144         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
11145         on OSF/1 to no.
11146         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
11147
11148 2006-08-23  Bruno Haible  <bruno@clisp.org>
11149
11150         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
11151         as unusable.
11152
11153         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
11154         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
11155         (gl_LOCK): New macro.
11156
11157 2006-08-22  Simon Josefsson  <jas@extundo.com>
11158
11159         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
11160         to md5 module.
11161
11162 2006-08-22  Simon Josefsson  <jas@extundo.com>
11163
11164         * MODULES.html.sh: Add "Support for maintaining and release
11165         projects".
11166
11167         * build-aux/gnupload: New file, from coreutils.
11168
11169 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11170
11171         Avoid the need for AC_LIBSOURCES in m4 macros.
11172         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
11173         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
11174         * modules/check-version (EXTRA_DIST): Add check-version.h.
11175         * modules/crc (EXTRA_DIST): Add crc.h.
11176         * modules/des (EXTRA_DIST): Add des.h.
11177         * modules/gc (EXTRA_DIST): Add gc.h.
11178         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
11179         * modules/getline (EXTRA_DIST): Add getline.h.
11180         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
11181         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
11182         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
11183         * modules/md2 (EXTRA_DIST): Add md2.h.
11184         * modules/md4 (EXTRA_DIST): Add md4.h.
11185         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
11186         * modules/read-file (EXTRA_DIST): Add read-file.h.
11187         * modules/readline (EXTRA_DIST): Add readline.h.
11188         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
11189         rijndael-api-fst.h.
11190
11191 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11192
11193         * m4/rijndael.m4 (gl_ARCFOUR):
11194         * m4/arctwo.m4 (gl_ARCTWO):
11195         * m4/check-version.m4 (gl_CHECK_VERSION):
11196         * m4/crc.m4 (gl_CRC):
11197         * m4/des.m4 (gl_DES):
11198         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
11199         * m4/gc.m4 (gl_GC):
11200         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
11201         * m4/getline.m4 (gl_FUNC_GETLINE):
11202         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
11203         * m4/hmac-md5.m4 (gl_HMAC_MD5):
11204         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
11205         * m4/md2.m4 (gl_MD2):
11206         * m4/md4.m4 (gl_MD4):
11207         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
11208         * m4/read-file.m4 (gl_FUNC_READ_FILE):
11209         * m4/readline.m4 (gl_FUNC_READLINE):
11210         * m4/rijndael.m4 (gl_RIJNDAEL):
11211         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11212         to get the necessary .h files and whatnot.
11213
11214 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11215
11216         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
11217         gnulib rather than the other way around.
11218         * config/srclistvars.sh (COREUTILS): Remove.
11219
11220 2006-08-22  Jim Meyering  <jim@meyering.net>
11221
11222         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
11223
11224         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
11225
11226 2006-08-22  Eric Blake  <ebb9@byu.net>
11227
11228         * modules/regexprops-generic: New file.
11229         * MODULES.html.sh (Support for building documentation): List it.
11230
11231 2006-08-22  Eric Blake  <ebb9@byu.net>
11232
11233         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
11234         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
11235         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
11236         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
11237
11238 2006-08-22  Bruno Haible  <bruno@clisp.org>
11239
11240         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
11241         and lib_LTLIBRARIES like the other lib_* variables.
11242
11243 2006-08-22  Bruno Haible  <bruno@clisp.org>
11244
11245         * build-aux/x-to-1.in: New file, from GNU gettext.
11246
11247 2006-08-22  Bruno Haible  <bruno@clisp.org>
11248
11249         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
11250         <utmpx.h> exists.
11251
11252 2006-08-22  Bruno Haible  <bruno@clisp.org>
11253
11254         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
11255         <utmpx.h> exists.
11256
11257 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11258
11259         BeOS portability.
11260         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
11261         exist.
11262         Problem reported by Bruno Haible.
11263
11264 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11265
11266         Avoid the need for AC_LIBSOURCES in m4 macros.
11267         * modules/acl (EXTRA_DIST): Add acl.h.
11268         * modules/argmatch (Files): Add m4/argmatch.m4.
11269         (configure.ac): Add gl_ARGMATCH.
11270         (EXTRA_DIST): Renamed from lib_SOURCES, for
11271         consistency with the other modules.  Remove argmatch.c.
11272         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
11273         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
11274         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
11275         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
11276         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
11277         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
11278         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
11279         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
11280         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
11281         * modules/closeout (EXTRA_DIST): Add closeout.h.
11282         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
11283         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
11284         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
11285         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
11286         dirname.h; remove basename.c and stripslash.c.
11287         * modules/exclude (EXTRA_DIST): Add exclude.h.
11288         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
11289         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
11290         * modules/file-type (EXTRA_DIST): Add file-type.h.
11291         * modules/filemode (EXTRA_DIST): Add filemode.h.
11292         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
11293         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11294         * modules/fpending (EXTRA_DIST): Add __fpending.h.
11295         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
11296         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
11297         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
11298         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
11299         * modules/getdate (EXTRA_DIST): Add getdate.c.
11300         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
11301         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
11302         * modules/getpass (EXTRA_DIST): Add getpass.h.
11303         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
11304         * modules/group-member (EXTRA_DIST): Add group-member.h.
11305         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
11306         * modules/hash (EXTRA_DIST): Add hash.h.
11307         * modules/human (EXTRA_DIST): Add human.h.
11308         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
11309         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
11310         * modules/lchown (EXTRA_DIST): Add lchown.h.
11311         * modules/long-options (EXTRA_DIST): Add long-options.h.
11312         * modules/lstat (EXTRA_DIST): Add lstat.h.
11313         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
11314         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
11315         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
11316         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
11317         * modules/memxor (EXTRA_DIST): Add memxor.h.
11318         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
11319         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
11320         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
11321         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
11322         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
11323         * modules/physmem (EXTRA_DIST): Add physmem.h.
11324         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
11325         * modules/posixver (EXTRA_DIST): Add posixver.h.
11326         * modules/quote (EXTRA_DIST): Add quote.h.
11327         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
11328         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
11329         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
11330         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
11331         regex_internal.h regexec.c.
11332         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
11333         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
11334         * modules/same (EXTRA_DIST): Add same.h.
11335         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
11336         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
11337         * modules/savedir (EXTRA_DIST): Add savedir.h.
11338         * modules/sha1 (EXTRA_DIST): Add sha1.h.
11339         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
11340         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
11341         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
11342         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
11343         * modules/strdup (EXTRA_DIST): Add strdup.h.
11344         * modules/strftime (EXTRA_DIST): Add strftime.h.
11345         * modules/strndup (EXTRA_DIST): Add strndup.h.
11346         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
11347         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
11348         * modules/time_r (EXTRA_DIST): Add time_r.h.
11349         * modules/timespec (EXTRA_DIST): Add timespec.h.
11350         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11351         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
11352         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
11353         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
11354         * modules/userspec (EXTRA_DIST): Add userspec.h.
11355         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
11356         * modules/utimens (EXTRA_DIST): Add utimens.h.
11357         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
11358         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
11359         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
11360         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
11361         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
11362         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
11363         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
11364         * modules/yesno (EXTRA_DIST): Add yesno.h.
11365
11366 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11367
11368         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
11369
11370         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
11371         * m4/dev-ino.m4, same-inode.m4: Remove.
11372
11373         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
11374         * m4/acl.m4 (AC_FUNC_ACL):
11375         * m4/backupfile.m4 (gl_BACKUPFILE):
11376         * m4/c-strtod.m4 (gl_C99_STRTOLD):
11377         * m4/canon-host.m4 (gl_CANON_HOST):
11378         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
11379         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
11380         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
11381         * m4/cloexec.m4 (gl_CLOEXEC):
11382         * m4/close-stream.m4 (gl_CLOSE_STREAM):
11383         * m4/closeout.m4 (gl_CLOSEOUT):
11384         * m4/dirfd.m4 (gl_FUNC_DIRFD):
11385         * m4/dirname.m4 (gl_DIRNAME):
11386         * m4/exclude.m4 (gl_EXCLUDE):
11387         * m4/exitfail.m4 (gl_EXITFAIL):
11388         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
11389         * m4/file-type.m4 (gl_FILE_TYPE):
11390         * m4/filemode.m4 (gl_FILEMODE):
11391         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
11392         * m4/fpending.m4 (gl_FUNC_FPENDING):
11393         * m4/fprintftime.m4 (gl_FPRINTFTIME):
11394         * m4/fts.m4 (gl_FUNC_FTS):
11395         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
11396         * m4/getdate.m4 (gl_GETDATE):
11397         * m4/gethrxtime.m4 (gl_GETHRXTIME):
11398         * m4/getpagesize.m4 (gl_GETPAGESIZE):
11399         * m4/getpass.m4 (gl_FUNC_GETPASS):
11400         * m4/gettime.m4 (gl_GETTIME):
11401         * m4/getugroups.m4 (gl_GETUGROUPS):
11402         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
11403         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
11404         * m4/hard-locale.m4 (gl_HARD_LOCALE):
11405         * m4/hash.m4 (gl_HASH):
11406         * m4/idcache.m4 (gl_IDCACHE):
11407         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
11408         * m4/lchown.m4 (gl_FUNC_LCHOWN):
11409         * m4/long-options.m4 (gl_LONG_OPTIONS):
11410         * m4/lstat.m4 (gl_FUNC_LSTAT):
11411         * m4/md5.m4 (gl_MD5):
11412         * m4/memcasecmp.m4 (gl_MEMCASECMP):
11413         * m4/memcoll.m4 (gl_MEMCOLL):
11414         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
11415         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
11416         * m4/memxor.m4 (gl_MEMXOR):
11417         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
11418         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
11419         * m4/modechange.m4 (gl_MODECHANGE):
11420         * m4/mountlist.m4 (gl_MOUNTLIST):
11421         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
11422         * m4/openat.m4 (gl_FUNC_OPENAT):
11423         * m4/pathmax.m4 (gl_PATHMAX):
11424         * m4/physmem.m4 (gl_PHYSMEM):
11425         * m4/posixtm.m4 (gl_POSIXTM):
11426         * m4/posixver.m4 (gl_POSIXVER):
11427         * m4/quote.m4 (gl_QUOTE):
11428         * m4/quotearg.m4 (gl_QUOTEARG):
11429         * m4/readtokens.m4 (gl_READTOKENS):
11430         * m4/readutmp.m4 (gl_READUTMP):
11431         * m4/regex.m4 (gl_REGEX):
11432         * m4/safe-read.m4 (gl_SAFE_READ):
11433         * m4/safe-write.m4 (gl_SAFE_WRITE):
11434         * m4/same.m4 (gl_SAME):
11435         * m4/save-cwd.m4 (gl_SAVE_CWD):
11436         * m4/savedir.m4 (gl_SAVEDIR):
11437         * m4/settime.m4 (gl_SETTIME):
11438         * m4/sha1.m4 (gl_SHA1):
11439         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
11440         * m4/stat-macros.m4 (gl_STAT_MACROS):
11441         * m4/stat-time.m4 (gl_STAT_TIME):
11442         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
11443         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
11444         * m4/strdup.m4 (gl_FUNC_STRDUP):
11445         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
11446         * m4/strndup.m4 (gl_FUNC_STRNDUP):
11447         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
11448         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
11449         * m4/time_r.m4 (gl_TIME_R):
11450         * m4/timespec.m4 (gl_TIMESPEC):
11451         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
11452         * m4/unlinkdir.m4 (gl_UNLINKDIR):
11453         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
11454         * m4/userspec.m4 (gl_USERSPEC):
11455         * m4/utimecmp.m4 (gl_UTIMECMP):
11456         * m4/utimens.m4 (gl_UTIMENS):
11457         * m4/xalloc.m4 (gl_XALLOC):
11458         * m4/xgetcwd.m4 (gl_XGETCWD):
11459         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
11460         * m4/xreadlink.m4 (gl_XREADLINK):
11461         * m4/xstrtod.m4 (gl_XSTRTOD):
11462         * m4/yesno.m4 (gl_YESNO):
11463         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11464         to get the necessary .h files and whatnot.
11465
11466 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
11467             Bruno Haible  <bruno@clisp.org>
11468
11469         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
11470         /bin/sh understanding of '!' conditional negation.
11471
11472 2006-08-21  Jim Meyering  <jim@meyering.net>
11473
11474         * modules/openat (Depends-on): Really alphabetize.
11475
11476         * modules/acl (Depends-on): Add error and quote.
11477
11478         * check-module (find_included_lib_files): Add at-func.c to the
11479         ok-to-include-more-than-once white list.
11480
11481         * modules/openat (Depends-on): Add lstat.  Alphabetize.
11482
11483 2006-08-21  Bruno Haible  <bruno@clisp.org>
11484
11485         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
11486         Emit a pkgdata_DATA variable only if some snippets add contents to it.
11487         Reported by Martin Lambers <marlam@marlam.de>.
11488
11489 2006-08-21  Bruno Haible  <bruno@clisp.org>
11490
11491         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
11492         specify an installation location, don't emit a noinst_LIBRARIES or
11493         noinst_LTLIBRARIES assignment.
11494
11495 2006-08-21  Bruno Haible  <bruno@clisp.org>
11496
11497         BeOS portability.
11498         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
11499         BeOS has mbrtowc() but no <wctype.h>.
11500
11501 2006-08-21  Bruno Haible  <bruno@clisp.org>
11502
11503         BeOS portability.
11504         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
11505         exist.
11506
11507 2006-08-21  Bruno Haible  <bruno@clisp.org>
11508
11509         BeOS portability.
11510         * lib/mbchar.h: Include <wctype.h> only if it exists.
11511
11512 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11513
11514         Remove files that are no longer needed by their respective modules.
11515         * m4/obstack.m4: Remove.
11516         * m4/strerror_r.m4: Remove.
11517         * m4/uint32_t.m4: Remove.
11518         * m4/uintptr_t.m4: Remove.
11519         * m4/ullong_max.m4: Remove.
11520         * m4/xstrtoimax.m4: Remove.
11521         * m4/xstrtoumax.m4: Remove.
11522
11523         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
11524         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
11525         dependencies now capture this.
11526
11527         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
11528         Do not use AC_LIBSOURCES, since gnulib modules now do this.
11529         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
11530         * m4/human.m4 (gl_HUMAN): Likewise.
11531         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
11532         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
11533
11534         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
11535
11536         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
11537         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
11538         stdint.
11539         * m4/human.m4 (gl_HUMAN): Likewise.
11540         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
11541         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
11542         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
11543         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
11544         * m4/xstrtol (gl_XSTRTOL): Likewise.
11545
11546         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
11547         AC_TYPE_LONG_LONG_INT.
11548         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
11549         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
11550         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
11551         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
11552
11553         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
11554         on stdbool.
11555
11556         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
11557         (gl_PREREQ_XSTRTOUL): Remove.
11558
11559         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
11560
11561         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
11562         mode.
11563
11564 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11565
11566         Add and change modules to make it easier for coreutils to use
11567         gnulib-tool.
11568         * modules/backupfile (Files): Remove m4/d-ino.m4.
11569         (Depends-on): Add d-ino.
11570         * modules/cycle-check (Depends-on): Add stdint.
11571         (lib_SOURCES): Add cycle-check.h.
11572         * modules/d-ino: New module.
11573         * modules/d-type: New module.
11574         * modules/error (Files): Remove m4/strerror_r.m4.
11575         * modules/filemode (Files): Add m4/st_dm_mode.m4.
11576         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
11577         m4/inttypes_h.m4, m4/uintmax_t.m4.
11578         (Depends-on): Add stdint.
11579         (lib_SOURCES): Add fsusage.h.
11580         * modules/getcwd (Files): Remove d-ino.m4.
11581         (Depends-on): Add d-ino.
11582         * modules/getndelim2 (Depends-on): Add stdint.
11583         * modules/glob (Files): Remove m4/d-type.m4.
11584         (Depends-on): Add d-type.
11585         * modules/host-os: New module.
11586         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
11587         m4/inttypes_h.m4, m4/uintmax_t.m4.
11588         * Depends-on: Add stdint.
11589         (lib_SOURCES): Add human.h.
11590         * modules/inttostr (Files): Remove m4/intmax_t.m4,
11591         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
11592         m4/uintmax_t.m4, m4/ulonglong.m4.
11593         (Depends-on): Add stdint.
11594         (EXTRA_DIST): Add inttostr.h.
11595         * modules/lchmod: New module.
11596         * modules/link-follow: New module.
11597         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
11598         (Depends-on): Add lchmod.
11599         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
11600         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
11601         (Depends-on): Add stdint.
11602         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
11603         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
11604         (Depends-on): Add stdint.
11605         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
11606         * modules/perl: New module.
11607         * modules/regex (Depends-on): Add stdint.
11608         * modules/rmdir-errno: New module.
11609         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
11610         m4/intmax_t.m4.
11611         (Depends-on): Add stdint.
11612         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
11613         m4/uintmax_t.m4.
11614         (Depends-on): Add stdint.
11615         * modules/unlink-busy: New module.
11616         * modules/utimecmp (Depends-on): Add stdint.
11617         * modules/uptime: New module.
11618         * modules/winsz-ioctl: New module.
11619         * modules/winsz-termios: New module.
11620         * modules/xnanosleep (Depends-on): Add nanosleep.
11621         * modules/ullong_max: Remove.
11622         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
11623         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
11624         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
11625         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
11626         (Depends-on): Add inttypes.
11627         (lib_SOURCES): Add xstrtol.h.
11628         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
11629         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
11630         * MODULES.html.sh: Move 'assert' into the assert section.
11631         Move 'dummy' into the linking section.
11632         Remove ullong_max.
11633         Add section for compatibility checks for POSIX:2001 functions,
11634         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
11635         winsz-ioctl, and winsz-termios into it.
11636         Add lchmod.
11637         Add top-level Misc section and put host-os, perl, and uptime
11638         into it.
11639
11640 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
11641
11642         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
11643         now assume the stdint module.  Do not include inttypes.h.
11644         * lib/fsusage.h: Likewise.
11645         * lib/getndelim2.c: Likewise.
11646         * lib/human.h: Likewise.
11647         * lib/inttostr.h: Likewise.
11648         * lib/obstack.c: Likewise.
11649         * lib/regex_internal.h: Likewise.
11650         * lib/tempname.c: Likewise.
11651         * lib/utimecmp.c: Likewise.
11652         * lib/xstrtol.h: Likewise.
11653
11654         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
11655
11656         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
11657         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
11658         * lib/xtime.h: Likewise.
11659
11660 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11661
11662         * modules/openat (Files): Add lib/fchmodat.c.
11663         Fixes problem reported by Jay Youngman.
11664
11665 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
11666
11667         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
11668         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
11669
11670 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
11671             Bruno Haible  <bruno@clisp.org>
11672
11673         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
11674         and is a script that invokes bison. Tighten the code. Add comments.
11675
11676 2006-08-18  Jim Meyering  <jim@meyering.net>
11677
11678         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
11679         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
11680         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
11681         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
11682
11683 2006-08-18  Bruno Haible  <bruno@clisp.org>
11684
11685         * modules/bison-i18n: New file.
11686         * MODULES.html.sh (Internationalization functions): Add it.
11687
11688 2006-08-18  Bruno Haible  <bruno@clisp.org>
11689
11690         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
11691         sys/statvfs.h. When getmntinfo was found, check its declaration and
11692         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
11693
11694 2006-08-18  Bruno Haible  <bruno@clisp.org>
11695
11696         * m4/bison-i18n.m4: New file, from bison.
11697
11698 2006-08-18  Bruno Haible  <bruno@clisp.org>
11699
11700         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
11701         (ME_DUMMY): Treat "kernfs" as a dummy.
11702         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
11703
11704 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11705
11706         Update from coreutils.
11707
11708         2006-08-15  Jim Meyering  <jim@meyering.net>
11709
11710         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
11711
11712         2006-01-17  Jim Meyering  <jim@meyering.net>
11713
11714         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
11715
11716         2006-01-11  Jim Meyering  <jim@meyering.net>
11717
11718         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
11719         Check for the lchmod function.
11720
11721 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
11722
11723         Update from coreutils.
11724
11725         * lib/__fpending.h: Add copyright notice.
11726         * lib/fprintftime.h: Likewise.
11727         * lib/savedir.c: Use (C) in copyright notice.
11728         * lib/savedir.h: Likewise.
11729
11730         2006-08-15  Jim Meyering  <jim@meyering.net>
11731
11732         * lib/at-func.c: New file, with the logic of all emulated at-functions.
11733         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
11734         in support of the EXPECTED_ERRNO macro.
11735         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
11736         definitions.  Instead, define the appropriate symbols and include
11737         "at-func.c".
11738         * lib/mkdirat.c (mkdirat): Likewise.
11739         * lib/fchmodat.c (fchmodat): Likewise.
11740         (ENOSYS): Remove definition.
11741         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
11742         it.  Don't include "unistd--.h" -- it wasn't ever used.
11743
11744         2006-01-17  Jim Meyering  <jim@meyering.net>
11745
11746         Rewrite fts.c not to change the current working directory,
11747         by using openat, fstatat, fdopendir, etc..
11748
11749         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
11750         (HAVE_OPENAT_SUPPORT): Define.
11751         [_LIBC] (fchdir): Don't undef or define; no longer used.
11752         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
11753         Now, this `function' always succeeds, and consumes its file descriptor
11754         parameter -- so callers must not close such FDs.  Update callers.
11755         (diropen_fd, opendirat, cwd_advance_fd): New functions.
11756         (diropen): Add parameter, SP.  Adjust all callers.
11757         Implement using diropen_fd, rather than open.
11758         (fts_open): Initialize new member, fts_cwd_fd.
11759         Remove fts_rft-setting code.
11760         (fts_close): Close fts_cwd_fd, if necessary.
11761         (__opendir2): Define in terms of opendir or opendirat,
11762         depending on whether the FST_NOCHDIR flag is set.
11763         (fts_build): Since fts_safe_changedir consumes its FD, and since
11764         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
11765         and close the dup'd file descriptor upon failure.
11766         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
11767         (fts_safe_changedir): Tweak semantics to reflect that this function
11768         now calls cwd_advance_fd and hence consumes its FD argument.
11769         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
11770         [struct FTS] (fts_rft): Remove now-unused member.
11771         [struct FTS] (fts_cycle.state): Improve comment.
11772
11773         * lib/openat.c (openat_needs_fchdir): New function.
11774         * lib/openat.h (openat_needs_fchdir): Declare it.
11775
11776 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
11777
11778         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
11779         Problem and fix reported by Pádraig Brady in
11780         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
11781
11782 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11783
11784         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
11785
11786 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11787
11788         * lib/memcoll.c (memcoll): Optimize for the common case where the
11789         arguments are bytewise equal.
11790
11791 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11792
11793         * doc/regexprops-generic.texi: Add a copyright notice.
11794
11795 2006-08-15  Bruno Haible  <bruno@clisp.org>
11796
11797         * modules/tmpdir (License): Change to LGPL.
11798
11799 2006-08-15  Bruno Haible  <bruno@clisp.org>
11800
11801         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
11802         module.
11803
11804 2006-08-14  Simon Josefsson  <jas@extundo.com>
11805
11806         * config/srclist.txt: Add gnupload.
11807
11808 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11809
11810         Change copyright notice from LGPL 2 to GPL 2, since that's the
11811         standard form used in the gnulib repository.
11812         * tests/test-lock.c: Likewise.
11813         * tests/test-stdint.c: Likewise.
11814         * tests/test-tls.c: Likewise.
11815
11816         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
11817         prelude-manager.  User shorter URLs for GNU projects, without '?'.
11818         Add copyright notice.
11819
11820         * check-module: Add copyright notice.  Output a copyright
11821         notice if "--version" is specified.
11822         * modules/COPYING: New file.
11823         * tests/test-getaddrinfo.c: Add copyright notice.
11824         * tests/test-verify.c: Likewise.
11825
11826 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11827
11828         Change copyright notice from LGPL 2 to GPL 2, since that's the
11829         standard form used in the gnulib repository.
11830         * lib/lock.c: LGPL -> GPL.
11831         * lib/lock.h: Likewise.
11832         * lib/strnlen1.c: Likewise.
11833         * lib/strnlen1.h: Likewise.
11834         * lib/tls.c: Likewise.
11835         * lib/tls.h: Likewise.
11836         * lib/tmpdir.c: Likewise.
11837
11838         * lib/TODO: Remove; this belongs only in coreutils.
11839
11840 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11841
11842         Add copyright notices to long-enough files that lack them, since
11843         otherwise the files aren't clearly free.  Use the same notice that
11844         getdate.texi already uses.
11845         * doc/alloca-opt.texi: Add copyright notice.
11846         * doc/alloca.texi: Likewise.
11847         * doc/ctime.texi: Likewise.
11848         * doc/functions.texi: Likewise.
11849         * doc/gcd.texi: Likewise.
11850         * doc/gnulib-tool.texi: Likewise.
11851         * doc/inet_ntoa.texi: Likewise.
11852         * doc/visibility.texi: Likewise.
11853
11854         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
11855         * doc/quote.texi: Add copyright notice.
11856
11857         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
11858         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
11859         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
11860         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
11861         is now obsolete, and give a pointer to the Sun list.
11862         Add copyright notice.
11863
11864 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
11865
11866         * config/srclistvars.sh: Add copyright notice.
11867
11868 2006-08-14  Eric Blake  <ebb9@byu.net>
11869
11870         Import the following change from libc:
11871
11872         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
11873
11874         Upstream bug 2997.
11875         * lib/misc/error.c: Add space between program name and message if file
11876         name is missing.
11877
11878 2006-08-12  Karl Berry  <karl@gnu.org>
11879
11880         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
11881         remove, these originate in gnulib now.
11882
11883 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11884
11885         * doc/Makefile (standards.info standards.html standards.dvi):
11886         Also depend on make-stds.texi.
11887
11888 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
11889
11890         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
11891         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
11892
11893         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
11894         in wchar_t.  Problem reported by Eric Blake.
11895
11896         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
11897         LEN is smaller than SIZE.  Suggested by Bruno Haible.
11898         Also, help the compiler to keep LEN in a register.
11899
11900 2006-08-11  Eric Blake  <ebb9@byu.net>
11901
11902         * users.txt: Sort.  Add tar.
11903
11904 2006-08-11  Bruno Haible  <bruno@clisp.org>
11905
11906         * users.txt: New file.
11907
11908 2006-08-11  Bruno Haible  <bruno@clisp.org>
11909
11910         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
11911         before <wchar.h>. Needed for OSF/1 and BSD/OS.
11912
11913 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
11914
11915         * modules/snprintf (Depends-on): Remove minmax.
11916         (Maintainer): Add self and Bruno.
11917
11918 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
11919
11920         * lib/.cppi-disable: Add snprintf.h, socket_.h.
11921         * lib/snprintf.c: Include <errno.h> and <limits.h>.
11922         (EOVERFLOW): Define if the system does not.
11923         Do not include "minmax.h"; it wasn't used.
11924         (snprintf): Don't assume size_t promotes to an unsigned type.
11925         Fix bug when generated string was too long for the buffer: the
11926         buffer's contents are supposed to be the initial prefix of the
11927         output.  Don't assume vasnprintf returns EOVERFLOW if the size
11928         exceeds INT_MAX; do the check ourselves.
11929
11930         Import the following changes from libc:
11931
11932         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
11933
11934         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
11935         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
11936         set wc to the byte which couldn't be converted.
11937         (re_string_reconstruct): Don't clear valid_raw_len before calling
11938         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
11939         tip_context using re_string_context_at.
11940
11941         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
11942
11943         * lib/posix/regex.h: g++ still cannot handled [restrict].
11944
11945         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
11946
11947         * lib/posix/regex.h: Remove special handling for VMS.
11948
11949 2006-08-10  Jim Meyering  <jim@meyering.net>
11950
11951         * modules/same-inode: New module.
11952         * modules/dev-ino: New module.
11953         * modules/cycle-check: Depend on these modules, rather than simply
11954         including their .h files.
11955         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
11956         required via m4/cycle-check.m4.
11957         * modules/same: Depend on new same-inode module, rather than
11958         including same-inode.h.
11959         * modules/chdir-safer: New file.
11960
11961         * modules/chown (Depends-on): Add stat-macros.
11962
11963 2006-08-10  Jim Meyering  <jim@meyering.net>
11964
11965         * m4/cycle-check.m4: New file.
11966         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
11967         * m4/dev-ino.m4, m4/same-inode.m4: New files.
11968
11969 2006-08-10  Eric Blake  <ebb9@byu.net>
11970
11971         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
11972         in from original proposal.
11973
11974 2006-08-10  Eric Blake  <ebb9@byu.net>
11975         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11976
11977         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
11978         namespace.
11979
11980 2006-08-10  Bruno Haible  <bruno@clisp.org>
11981
11982         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
11983         as well.
11984
11985 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
11986
11987         Sync from coreutils.
11988
11989         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
11990
11991         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
11992         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
11993
11994 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
11995
11996         * modules/restrict: Remove; no longer needed now that we assume
11997         Autoconf 2.59 or later.
11998         * MODULES.html.sh: Remove 'restrict'.
11999         * modules/argp (Depends-on): Remove 'restrict'.
12000         * modules/base64 (Depends-on): Likewise.
12001         * modules/gc (Depends-on): Likewise.
12002         * modules/getaddrinfo (Depends-on): Likewise.
12003         * modules/glob (Depends-on): Likewise.
12004         * modules/inet_ntop (Depends-on): Likewise.
12005         * modules/inet_pton (Depends-on): Likewise.
12006         * modules/memxor (Depends-on): Likewise.
12007         * modules/regex (Depends-on): Likewise.
12008         * modules/strtok_r (Depends-on): Likewise.
12009         * modules/time_r (Depends-on): Likewise.
12010
12011 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12012
12013         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
12014         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
12015         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12016         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
12017         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
12018         * m4/memxor.m4 (gl_MEMXOR): Likewise.
12019         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
12020         gl_C_RESTRICT replaced by AC_C_RESTRICT.
12021
12022         Merge from coreutils.
12023         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
12024         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
12025         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
12026         * m4/time_r.m4 (gl_TIME_R): Likewise.
12027
12028 2006-08-09  Karl Berry  <karl@gnu.org>
12029
12030         * config/srclist.txt: no more gettext-tools, per Bruno.
12031
12032 2006-08-08  Eric Blake  <ebb9@byu.net>
12033
12034         * modules/verror: New module.
12035         * MODULES.html.sh: Document it.
12036
12037 2006-08-08  Eric Blake  <ebb9@byu.net>
12038
12039         * lib/verror.h, lib/verror.c: New files.
12040
12041 2006-08-08  Eric Blake  <ebb9@byu.net>
12042
12043         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
12044         verror_at_line output complies with GNU Coding Standards even when
12045         file is NULL.
12046
12047 2006-08-07  Bruno Haible  <bruno@clisp.org>
12048
12049         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
12050         versions of AIX.
12051         Reported by Ralf Wildenhues.
12052
12053 2006-08-07  Bruno Haible  <bruno@clisp.org>
12054
12055         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
12056         in an AC_DEFUN. Needed so that the autoconf snippets can use
12057         AC_REQUIRE.
12058
12059 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12060
12061         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12062         Initialize pkgdata_DATA.
12063         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
12064         overriding it.
12065
12066 2006-08-06  Eric Blake  <ebb9@byu.net>
12067
12068         * lib/error.h: Fold in some upstream changes from glibc.
12069         * lib/error.c: Likewise.
12070
12071 2006-08-04  Bruno Haible  <bruno@clisp.org>
12072
12073         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12074         Make the mostlyclean-local rule depend on mostlyclean-generic.
12075         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
12076
12077 2006-07-31  Bruno Haible  <bruno@clisp.org>
12078
12079         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
12080         <stdlib.h>, <string.h>.
12081
12082 2006-07-30  Bruno Haible  <bruno@clisp.org>
12083
12084         * modules/readlink (License): Change to LGPL.
12085
12086 2006-07-30  Bruno Haible  <bruno@clisp.org>
12087
12088         * modules/javaversion (Makefile.am): Distribute javaversion.java and
12089         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
12090         set PKGDATADIR to point to it.
12091
12092 2006-07-30  Bruno Haible  <bruno@clisp.org>
12093
12094         * modules/csharpexec (configure.ac): Comment out macro invocation.
12095         * modules/javaexec (configure.ac): Likewise.
12096         * modules/javacomp-script (configure.ac): Likewise.
12097
12098         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
12099
12100 2006-07-30  Bruno Haible  <bruno@clisp.org>
12101
12102         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
12103         linked-list.
12104
12105 2006-07-30  Bruno Haible  <bruno@clisp.org>
12106
12107         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
12108
12109 2006-07-30  Bruno Haible  <bruno@clisp.org>
12110
12111         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12112         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
12113         get removed.
12114
12115 2006-07-29  Bruno Haible  <bruno@clisp.org>
12116
12117         Make it possible for gnulib-tool to work with locally modified or
12118         augmented gnulib repositories.
12119         * gnulib-tool (func_usage): Document --local-dir option.
12120         (local_gnulib_dir): New variable.
12121         Handle --local-dir option.
12122         (func_lookup_file): New function.
12123         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
12124         (func_get_description, func_get_filelist, func_get_description,
12125         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
12126         func_get_automake_snippet, func_get_include_directive,
12127         func_get_license, func_get_maintainer): Use func_lookup_file.
12128         (func_import, func_create_testdir): Use func_lookup_file.
12129
12130 2006-07-29  Bruno Haible  <bruno@clisp.org>
12131
12132         * modules/setenv (Depends-on): Add unistd.
12133
12134 2006-07-29  Bruno Haible  <bruno@clisp.org>
12135
12136         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
12137
12138 2006-07-29  Bruno Haible  <bruno@clisp.org>
12139
12140         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
12141
12142 2006-07-29  Bruno Haible  <bruno@clisp.org>
12143
12144         * gnulib-tool (import, update): If there is no Makefile.am, look at
12145         aclocal.m4, instead of bailing out.
12146
12147 2006-07-29  Bruno Haible  <bruno@clisp.org>
12148
12149         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
12150         Categorize the options by when they are useful.
12151
12152 2006-07-29  Bruno Haible  <bruno@clisp.org>
12153
12154         * gnulib-tool (func_usage): Document option --no-libtool.
12155         Handle option --no-libtool.
12156         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
12157         for changed semantics of $libtool variable.
12158         (func_import): Likewise. If libtool is not used, show this through
12159         an option --no-libtool.
12160         (func_create_testdir): Update.
12161
12162 2006-07-29  Bruno Haible  <bruno@clisp.org>
12163
12164         * gnulib-tool (func_import): Extend error message about missing
12165         --doc-base.
12166
12167 2006-07-29  Bruno Haible  <bruno@clisp.org>
12168
12169         * gnulib-tool (func_import): Don't create the $docbase directory if
12170         there is no file to store there.
12171
12172 2006-07-29  Bruno Haible  <bruno@clisp.org>
12173
12174         * gnulib-tool (autoconf_minversion): If a --dir option is given and
12175         relevant, look for configure.ac there, not in the current directory.
12176         Also use a simple search for AC_PREREQ, not "autoconf --trace".
12177
12178 2006-07-29  Bruno Haible  <bruno@clisp.org>
12179
12180         * gnulib-tool (SORT): New variable.
12181         (func_usage): Undocument --assume-autoconf option.
12182         Remove --assume-autoconf option handling.
12183         (autoconf_minversion): Determine from the contents of configure.ac.
12184         (func_import): Remove autoconf_minversion handling.
12185         Suggested by Eric Blake.
12186
12187 2006-07-29  Bruno Haible  <bruno@clisp.org>
12188
12189         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
12190
12191 2006-07-29  Bruno Haible  <bruno@clisp.org>
12192
12193         * config/srclist.txt (*setenv.[ch]): Remove rules.
12194
12195 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12196
12197         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
12198
12199 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12200
12201         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
12202         arpa/inet.h.
12203
12204 2006-07-28  Simon Josefsson  <jas@extundo.com>
12205
12206         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
12207         * modules/inet_pton (Depends-on): Likewise.
12208
12209 2006-07-28  Simon Josefsson  <jas@extundo.com>
12210
12211         * m4/netinet_in_h.m4: New file.
12212
12213 2006-07-28  Simon Josefsson  <jas@extundo.com>
12214
12215         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
12216         #include's.
12217
12218 2006-07-28  Simon Josefsson  <jas@extundo.com>
12219
12220         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
12221         #include's.
12222
12223 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
12224
12225         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
12226         setgid on directories only if they set these bits.
12227         * lib/modechange.h: Remove obsolete comment about masks.
12228
12229 2006-07-28  Eric Blake  <ebb9@byu.net>
12230
12231         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
12232         macro expansion.
12233
12234 2006-07-28  Bruno Haible  <bruno@clisp.org>
12235
12236         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
12237
12238 2006-07-28  Bruno Haible  <bruno@clisp.org>
12239
12240         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
12241
12242 2006-07-28  Bruno Haible  <bruno@clisp.org>
12243
12244         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
12245         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
12246         Define fallbacks.
12247         Avoids link error on FreeBSD 4.x.
12248         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12249
12250         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
12251         encoding.
12252         * lib/mbswidth.c (iswcntrl): Likewise.
12253
12254 2006-07-27  Bruno Haible  <bruno@clisp.org>
12255
12256         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
12257         test.
12258
12259 2006-07-27  Bruno Haible  <bruno@clisp.org>
12260
12261         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
12262         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
12263         defined.
12264
12265 2006-07-26  Eric Blake  <ebb9@byu.net>
12266
12267         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
12268
12269 2006-07-26  Eric Blake  <ebb9@byu.net>
12270
12271         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
12272         like mingw that lack mkstemp.
12273         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
12274         avoid compilation warning on mingw.
12275
12276 2006-07-26  Bruno Haible  <bruno@clisp.org>
12277
12278         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
12279         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
12280         INT_FAST*_MIN, INTPTR_MIN.
12281
12282 2006-07-25  Bruno Haible  <bruno@clisp.org>
12283
12284         * modules/version-etc (Depends-on): Add stdarg.
12285
12286 2006-07-25  Bruno Haible  <bruno@clisp.org>
12287
12288         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
12289         complex commands.
12290
12291 2006-07-25  Bruno Haible  <bruno@clisp.org>
12292
12293         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
12294         defined in <stdarg.h> or config.h.
12295
12296 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12297
12298         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
12299         (gl_STDIO_SAFER): Remove.
12300
12301 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12302
12303         * MODULES.html.sh (File stream based Input/Output):
12304         Add fopen-safer, tmpfile-safer; remove stdio-safer.
12305         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
12306         * modules/fopen-safer, modules/tmpfile-safer: New files.
12307         * modules/stdio-safer: Remove.
12308
12309 2006-07-24  Bruno Haible  <bruno@clisp.org>
12310
12311         * modules/tmpdir: New file.
12312         * MODULES.html.sh (File system functions): Add it.
12313
12314 2006-07-24  Bruno Haible  <bruno@clisp.org>
12315
12316         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
12317         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
12318
12319 2006-07-24  Bruno Haible  <bruno@clisp.org>
12320
12321         * modules/clean-temp: New file.
12322
12323 2006-07-24  Bruno Haible  <bruno@clisp.org>
12324
12325         * m4/tmpdir.m4: New file, from GNU gettext.
12326
12327 2006-07-24  Bruno Haible  <bruno@clisp.org>
12328
12329         * lib/tmpdir.h: New file, from GNU gettext.
12330         * lib/tmpdir.c: New file, from GNU gettext.
12331
12332 2006-07-24  Bruno Haible  <bruno@clisp.org>
12333
12334         * lib/clean-temp.h: New file, from GNU gettext.
12335         * lib/clean-temp.c: New file, from GNU gettext.
12336
12337 2006-07-23  Eric Blake  <ebb9@byu.net>
12338
12339         * modules/stdio-safer (Files): Add tmpfile-safer.c.
12340         (Depends-on): Add binary-io.
12341
12342 2006-07-23  Eric Blake  <ebb9@byu.net>
12343
12344         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
12345
12346 2006-07-23  Eric Blake  <ebb9@byu.net>
12347
12348         * lib/tmpfile-safer.c: New file.
12349         * lib/stdio-safer.h (fopen_safer): Add prototype.
12350         * lib/stdio--.h (tmpfile): Make safer.
12351
12352 2006-07-23  Bruno Haible  <bruno@clisp.org>
12353
12354         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
12355         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
12356         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
12357         gl_linked_remove_at): Use it.
12358
12359 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12360         and Simon Josefsson <jas@extundo.com>
12361
12362         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
12363
12364         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
12365
12366 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12367
12368         * modules/close-stream: New file.
12369         * modules/closeout (Description): Make it clear that it exits
12370         with a diagnostic on error.
12371         (Depends-on): Add close-stream.  Remove fpending, stdbool.
12372         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
12373
12374 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12375
12376         * m4/close-stream.m4: New file.
12377
12378 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12379
12380         * lib/close-stream.c, lib/close-stream.h: New files.
12381
12382 2006-07-22  Bruno Haible  <bruno@clisp.org>
12383
12384         Merge from GNU gettext 0.15.
12385
12386         2006-05-01  Bruno Haible  <bruno@clisp.org>
12387
12388                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
12389
12390         2006-07-22  Bruno Haible  <bruno@clisp.org>
12391
12392                 * modules/javaversion: New file.
12393                 * MODULES.html.sh (Java): Add javaversion.
12394
12395         2006-03-12  Bruno Haible  <bruno@clisp.org>
12396
12397                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
12398
12399         2005-12-04  Bruno Haible  <bruno@clisp.org>
12400
12401                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
12402                 (untested).
12403
12404         2006-06-21  Bruno Haible  <bruno@clisp.org>
12405
12406                 Avoid warnings from recent versions of mcs.
12407                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
12408                 -o, -L, -r any more. Use options documented since mcs-1.0
12409                 instead. Similarly for -g.
12410
12411         2005-12-04  Bruno Haible  <bruno@clisp.org>
12412
12413                 * build-aux/csharpcomp.sh.in: Suffix for resources is
12414                 .resources, not .resource.
12415
12416         2005-07-09  Bruno Haible  <bruno@clisp.org>
12417
12418                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
12419                 add a .dll suffix.
12420                 Reported by Mark Junker <mjscod@gmx.de>.
12421
12422         2006-07-22  Bruno Haible  <bruno@clisp.org>
12423
12424                 * modules/gettext: Upgrade to gettext-0.15.
12425                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
12426                 m4/visibility.m4.
12427                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
12428
12429 2006-07-22  Bruno Haible  <bruno@clisp.org>
12430
12431         Merge from GNU gettext 0.15.
12432
12433         2006-03-25  Bruno Haible  <bruno@clisp.org>
12434
12435                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
12436
12437         2006-07-21  Bruno Haible  <bruno@clisp.org>
12438
12439                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
12440                 "1.1".
12441
12442         2006-05-09  Bruno Haible  <bruno@clisp.org>
12443
12444                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
12445                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
12446                 for the conftestver execution.
12447
12448         2006-05-01  Bruno Haible  <bruno@clisp.org>
12449
12450                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
12451                 optional target-version argument. Verify that the compiler
12452                 groks source of the specified source-version, or add -source
12453                 option as necessary. Verify that the compiler produces
12454                 bytecode in the specified target-version, or add -target and
12455                 -source options as necessary. Make the result of the test
12456                 available as variable CONF_JAVAC. Also log error output in
12457                 config.log.
12458
12459         2006-03-11  Bruno Haible  <bruno@clisp.org>
12460
12461                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
12462
12463         2006-05-09  Bruno Haible  <bruno@clisp.org>
12464
12465                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
12466                 CLASSPATH_SEPARATOR to a semicolon.
12467
12468         2006-03-12  Bruno Haible  <bruno@clisp.org>
12469
12470                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
12471                 available as variable CONF_JAVA, for subsequent autoconf
12472                 tests. Also log error output in config.log.
12473
12474         2006-07-19  Bruno Haible  <bruno@clisp.org>
12475
12476                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
12477                 that getline works on glibc2 systems. Needed to avoid trouble
12478                 in relocatable.c.
12479                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
12480
12481         2005-12-04  Bruno Haible  <bruno@clisp.org>
12482
12483                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
12484                 launcher (untested).
12485
12486         2005-12-04  Bruno Haible  <bruno@clisp.org>
12487
12488                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
12489
12490         2006-07-22  Bruno Haible  <bruno@clisp.org>
12491
12492                 * gettext.m4: Update from GNU gettext-0.15.
12493                 * nls.m4: Likewise.
12494                 * po.m4: Likewise.
12495                 * inttypes-pri.m4: Likewise.
12496                 * inttypes-h.m4: Renamed from inttypes.m4.
12497                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
12498
12499 2006-07-22  Bruno Haible  <bruno@clisp.org>
12500
12501         Merge from GNU gettext 0.15.
12502
12503         2005-07-05  Bruno Haible  <bruno@clisp.org>
12504
12505                 * printf-args.c (printf_fetchargs): Work around broken
12506                 definition of wint_t on mingw.
12507
12508         2005-02-12  Bruno Haible  <bruno@clisp.org>
12509
12510                 * xallocsa.h: Add extern "C" for C++.
12511
12512         2006-05-17  Bruno Haible  <bruno@clisp.org>
12513
12514                 Cygwin portability.
12515                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
12516
12517         2006-04-30  Bruno Haible  <bruno@clisp.org>
12518
12519                 * progreloc.c: Include <mach-o/dyld.h> if available.
12520                 (find_executable): Use _NSGetExecutablePath when possible.
12521
12522         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
12523
12524                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
12525                 function.
12526
12527         2005-12-29  Bruno Haible  <bruno@clisp.org>
12528
12529                 * progreloc.c (set_program_name_and_installdir): Fix
12530                 compilation error.
12531
12532         2005-12-04  Bruno Haible  <bruno@clisp.org>
12533
12534                 Cygwin portability.
12535                 * progreloc.c: Include <windows.h> also on Cygwin.
12536                 (find_executable): Add support for Cygwin.
12537                 (set_program_name_and_installdir): Handle also platforms with
12538                 nonempty EXEEXT.
12539
12540         2006-07-11  Bruno Haible  <bruno@clisp.org>
12541
12542                 * javacomp.c: Fix a comment.
12543                 Reported by Jim Meyering.
12544
12545         2006-04-30  Bruno Haible  <bruno@clisp.org>
12546
12547                 * javacomp.h (compile_java_class): Add source_version,
12548                 target_version arguments.
12549                 * javacomp.c: Rewritten to choose only a compiler that
12550                 respects the specified source_version and target_version.
12551
12552         2006-06-27  Bruno Haible  <bruno@clisp.org>
12553
12554                 Assume correct S_ISDIR macro.
12555                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
12556
12557         2006-07-22  Bruno Haible  <bruno@clisp.org>
12558
12559                 * javaversion.h: New file, from GNU gettext.
12560                 * javaversion.c: New file, from GNU gettext.
12561                 * javaversion.java: New file, from GNU gettext.
12562                 * javaversion.class: New file, from GNU gettext.
12563
12564         2006-05-17  Bruno Haible  <bruno@clisp.org>
12565
12566                 Cygwin portability.
12567                 * javaexec.c (execute_java_class): Test for jview program
12568                 also on Cygwin.
12569
12570         2006-04-09  Bruno Haible  <bruno@clisp.org>
12571
12572                 * fatal-signal.c: Don't include string.h.
12573                 (at_fatal_signal): Use a copying loop instead of memcpy.
12574
12575         2005-12-04  Bruno Haible  <bruno@clisp.org>
12576
12577                 * csharpexec.c: Add support for 'clix' launcher (untested).
12578                 (execute_csharp_using_sscli): New function.
12579                 (execute_csharp_program): Call it.
12580
12581         2006-06-21  Bruno Haible  <bruno@clisp.org>
12582
12583                 Avoid warnings from recent versions of mcs.
12584                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
12585                 -o, -L, -r any more. Use options documented since mcs-1.0
12586                 instead. Similarly for -g.
12587
12588         2005-07-09  Bruno Haible  <bruno@clisp.org>
12589
12590                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
12591                 add a .dll suffix.
12592                 Reported by Mark Junker <mjscod@gmx.de>.
12593
12594         2006-06-17  Bruno Haible  <bruno@clisp.org>
12595
12596                 * config.charset: Update for NetBSD 3.0.
12597
12598         2006-05-17  Bruno Haible  <bruno@clisp.org>
12599
12600                 Cygwin portability.
12601                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
12602
12603         2006-05-16  Bruno Haible  <bruno@clisp.org>
12604
12605                 * localcharset.c [CYGWIN]: Include <windows.h>.
12606                 (get_charset_aliases): For Cygwin, return the same CPxxx
12607                 aliases list as under WIN32.
12608                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
12609                 the environment variables. Fall back to GetACP().
12610
12611         2006-04-05  Bruno Haible  <bruno@clisp.org>
12612
12613                 * config.charset: Update Juan Manuel Guerrero's address.
12614
12615         2005-02-12  Bruno Haible  <bruno@clisp.org>
12616
12617                 * allocsa.h: Add extern "C" for C++.
12618
12619         2005-02-10  Bruno Haible  <bruno@clisp.org>
12620
12621                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
12622                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
12623
12624         2006-07-22  Bruno Haible  <bruno@clisp.org>
12625
12626                 * gettext.h: Update to GNU gettext-0.15.
12627
12628 2006-07-22  Bruno Haible  <bruno@clisp.org>
12629
12630         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
12631         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
12632         lib-prefix.m4, longdouble.m4, ssize_t.m4.
12633
12634 2006-07-21  Eric Blake  <ebb9@byu.net>
12635
12636         * modules/stdlib-safer: New file.
12637         * MODULES.html.sh (File stream based Input/Output): Add
12638         stdlib-safer.
12639
12640 2006-07-21  Eric Blake  <ebb9@byu.net>
12641
12642         * lib/stdlib-safer.h: New file from coreutils, required by
12643         stdlib--.h.
12644
12645 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
12646
12647         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
12648
12649 2006-07-20  Bruno Haible  <bruno@clisp.org>
12650
12651         * gnulib-tool: Recognize new option --assume-autoconf.
12652         (autoconf_minversion): New variable.
12653         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
12654
12655 2006-07-20  Bruno Haible  <bruno@clisp.org>
12656
12657         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
12658
12659 2006-07-19  Derek R. Price  <derek@ximbiot.com>
12660
12661         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
12662         Reindent and repaginate.
12663
12664 2006-07-19  Derek Price  <derek@ximbiot.com>
12665
12666         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
12667         Correct grammar.
12668
12669 2006-07-17  Bruno Haible  <bruno@clisp.org>
12670
12671         * modules/list: New file.
12672         * modules/array-list: New file.
12673         * modules/carray-list, modules/carray-list-tests: New files.
12674         * modules/linked-list, modules/linked-list-tests: New files.
12675         * modules/avltree-list, modules/avltree-list-tests: New files.
12676         * modules/rbtree-list, modules/rbtree-list-tests: New files.
12677         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
12678         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
12679         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
12680         * modules/oset: New file.
12681         * modules/array-oset: New file.
12682         * modules/avltree-oset, modules/avltree-oset-tests: New files.
12683         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
12684         * tests/test-carray_list.c: New file.
12685         * tests/test-linked_list.c: New file.
12686         * tests/test-avltree_list.c: New file.
12687         * tests/test-rbtree_list.c: New file.
12688         * tests/test-linkedhash_list.c: New file.
12689         * tests/test-avltreehash_list.c: New file.
12690         * tests/test-rbtreehash_list.c: New file.
12691         * tests/test-avltree_oset.c: New file.
12692         * tests/test-rbtree_oset.c: New file.
12693         * MODULES.html.sh (Container data structures): New section.
12694
12695 2006-07-17  Bruno Haible  <bruno@clisp.org>
12696
12697         * m4/gl_list.m4: New file.
12698
12699 2006-07-17  Bruno Haible  <bruno@clisp.org>
12700
12701         * lib/gl_list.h: New file.
12702         * lib/gl_list.c: New file.
12703         * lib/gl_array_list.h: New file.
12704         * lib/gl_array_list.c: New file.
12705         * lib/gl_carray_list.h: New file.
12706         * lib/gl_carray_list.c: New file.
12707         * lib/gl_linked_list.h: New file.
12708         * lib/gl_linked_list.c: New file.
12709         * lib/gl_anylinked_list1.h: New file.
12710         * lib/gl_anylinked_list2.h: New file.
12711         * lib/gl_avltree_list.h: New file.
12712         * lib/gl_avltree_list.c: New file.
12713         * lib/gl_anyavltree_list1.h: New file.
12714         * lib/gl_anyavltree_list2.h: New file.
12715         * lib/gl_rbtree_list.h: New file.
12716         * lib/gl_rbtree_list.c: New file.
12717         * lib/gl_anyrbtree_list1.h: New file.
12718         * lib/gl_anyrbtree_list2.h: New file.
12719         * lib/gl_anytree_list1.h: New file.
12720         * lib/gl_anytree_list2.h: New file.
12721         * lib/gl_linkedhash_list.h: New file.
12722         * lib/gl_linkedhash_list.c: New file.
12723         * lib/gl_anyhash_list1.h: New file.
12724         * lib/gl_anyhash_list2.h: New file.
12725         * lib/gl_avltreehash_list.h: New file.
12726         * lib/gl_avltreehash_list.c: New file.
12727         * lib/gl_rbtreehash_list.h: New file.
12728         * lib/gl_rbtreehash_list.c: New file.
12729         * lib/gl_anytreehash_list1.h: New file.
12730         * lib/gl_anytreehash_list2.h: New file.
12731
12732         * lib/gl_oset.h: New file.
12733         * lib/gl_oset.c: New file.
12734         * lib/gl_array_oset.h: New file.
12735         * lib/gl_array_oset.c: New file.
12736         * lib/gl_avltree_oset.h: New file.
12737         * lib/gl_avltree_oset.c: New file.
12738         * lib/gl_rbtree_oset.h: New file.
12739         * lib/gl_rbtree_oset.c: New file.
12740         * lib/gl_anytree_oset.h: New file.
12741
12742 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
12743
12744         * m4/mkancesdirs.m4: New file.
12745         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
12746         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
12747         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
12748         it.
12749
12750 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
12751
12752         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
12753         * lib/mkancesdirs.h: New files.
12754         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
12755         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
12756         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
12757         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
12758         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
12759         callers changed.  Revamp internals significantly, by not
12760         attempting to create directories that are temporarily more
12761         permissive than the final results.  Do not attempt to use
12762         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
12763         This removes some race conditions, fixes some bugs, and simplifies
12764         things.  Use new dirchownmod function to do owner and mode changes.
12765         * lib/mkdir-p.h: Likewise.
12766         * lib/modechange.c (octal_to_mode): New function.
12767         (struct mode_change): New member mentioned.
12768         (make_node_op_equals): New arg mentioned.  All callers changed.
12769         (mode_compile): Keep track of which mode bits the user has explicitly
12770         mentioned.
12771         (mode_adjust): New arg DIR, so that we implement the X op correctly.
12772         New arg PMODE_BITS, to keep track of which mode bits the user
12773         mentioned; it treats S_ISUID and S_ISGID speciall.
12774         All callers changed.
12775         * lib/modechange.h: Likewise.
12776
12777 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
12778
12779         * MODULES.html.sh: Add mkancestors.
12780         * modules/mkancesdirs: New module.
12781         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
12782         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
12783         The chdir-safer and afs files are now orphans; I'll remove them
12784         unless someone speaks up.
12785         Add lib/dirchownmod.c, lib/dirchownmod.h.
12786         (Depends-on): Remove alloca, chown, save-cwd, dirname.
12787         Add lchown, mkancesdirs.
12788         (Maintainer): Add self.
12789
12790 2006-07-15  Karl Berry  <karl@gnu.org>
12791
12792         * gnulib-tool: help message wording/arrangement.
12793
12794 2006-07-14  Simon Josefsson  <jas@extundo.com>
12795
12796         * doc/gnulib.texi (Libtool and Windows): New section.
12797
12798 2006-07-12  Simon Josefsson  <jas@extundo.com>
12799
12800         * modules/gendocs (License): Fix license, approved by Karl.
12801
12802 2006-07-12  Eric Blake  <ebb9@byu.net>
12803
12804         * MODULES.html.sh: Add gendocs.
12805
12806 2006-07-11  Eric Blake  <ebb9@byu.net>
12807
12808         * modules/fdl: New module, to install doc/fdl.texi.
12809         * MODULES.html.sh: Add new section for documentation modules.
12810         * gnulib-tool: Avoid space-tab.
12811         (--doc-base): New option, to manage files from doc.
12812
12813 2006-07-11  Eric Blake  <ebb9@byu.net>
12814
12815         * m4/absolute-header.m4: Fix comments to match recent change.
12816
12817 2006-07-11  Eric Blake  <ebb9@byu.net>
12818
12819         * gnulib-tool: List --doc-base before --tests-base.
12820
12821 2006-07-11  Derek R. Price  <derek@ximbiot.com>
12822
12823         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
12824
12825 2006-07-11  Bruno Haible  <bruno@clisp.org>
12826
12827         * README: Mention where to put documentation.
12828
12829 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12830
12831         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
12832
12833 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
12834
12835         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
12836         to stdint.m4.
12837
12838 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
12839
12840         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
12841         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
12842         "no/such/file/stdint.h" when there is no such file, so that
12843         the resulting C code can be parsed by dodgy compilers.
12844         Problems reported by Bob Proulx.
12845
12846 2006-07-10  Derek R. Price  <derek@ximbiot.com>
12847
12848         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
12849         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
12850         macros into the GNU _D_EXACT_NAMLEN.
12851         * lib/savedir.c:  Likewise.
12852         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
12853
12854 2006-07-10  Derek R. Price  <derek@ximbiot.com>
12855         and Paul Eggert  <eggert@cs.ucla.edu>
12856
12857         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
12858         * m4/savedir.m4:
12859         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
12860         macros into the GNU _D_EXACT_NAMLEN.
12861
12862 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12863
12864         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
12865         around the absolute name, to work around a problem with the HP-UX
12866         11.23 native C compiler, reported by Bob Proulx.
12867
12868 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12869
12870         * doc/maintain.texi, make-stds.texi: Sync from
12871         <http://savannah.gnu.org/projects/gnustandards>.
12872
12873 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
12874
12875         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
12876
12877 2006-07-09  Jim Meyering  <jim@meyering.net>
12878
12879         * m4/glob.m4: Remove a doubled word in a comment.
12880
12881 2006-07-09  Jim Meyering  <jim@meyering.net>
12882
12883         * lib/argp-pv.c: Remove a doubled word in a comment.
12884         * lib/check-version.c (check_version): Likewise.
12885         * lib/javacomp.c (compile_java_class): Likewise.
12886
12887 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
12888
12889         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
12890         for the benefit of people using Autoconf 2.60.  If you want to
12891         support older Autoconf versions you can copy m4/onceonly_2_57.m4
12892         (or m4/onceonly.m4, if pre-2.57) manually.
12893
12894 2006-07-08  Jim Meyering  <jim@meyering.net>
12895
12896         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
12897         comment.
12898         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
12899         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
12900         comment.
12901
12902 2006-07-08  Jim Meyering  <jim@meyering.net>
12903
12904         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
12905
12906 2006-07-07  Simon Josefsson  <jas@extundo.com>
12907
12908         * tests/test-crc.c: Change expected crc value, the test vector
12909         were probably computed using the old broken crc.c?
12910
12911 2006-07-06  Simon Josefsson  <jas@extundo.com>
12912
12913         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
12914         now the canonical place for the M4 file).
12915
12916         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
12917         from the sys_socket dependency now.
12918
12919         * modules/inet_pton (Files): Ditto.
12920
12921         * modules/inet_ntop (Files): Ditto.
12922
12923 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
12924
12925         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
12926         not gl_PREREQ_GETUSERSHELL.
12927
12928 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12929
12930         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
12931         with only one argument, for Autoconf 2.60.
12932         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
12933         expand to nothing, so add a shell command to avoid syntax error.
12934         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
12935
12936 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12937
12938         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
12939
12940 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12941
12942         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
12943         no longer needed.  Check for isblank decl.
12944         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
12945         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
12946         of existence.
12947
12948 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12949
12950         * lib/getloadavg.c: Use __VMS, not VMS.
12951         * lib/getopt.c: Likewise.
12952         * lib/getpagesize.h: Likewise.
12953         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
12954         and probably does not work.
12955
12956 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
12957
12958         * lib/.cppi-disable: Add wcwidth.
12959         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
12960         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
12961         (ISGRAPH): Remove.  All uses changed to isgraph.
12962         (FOLD) [!defined _LIBC]: Remove special case.
12963         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
12964         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
12965         HAVE_ISBLANK.
12966         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
12967         case.
12968
12969 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
12970
12971         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
12972         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
12973         brackets.  Other minor changes to suppress some compiler
12974         warnings.
12975
12976 2006-07-06  Derek R. Price  <derek@ximbiot.com>
12977         and Paul Eggert  <eggert@cs.ucla.edu>
12978
12979         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
12980         of invoking obsolescent AC_HEADER_DIRENT macro.
12981         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
12982         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
12983         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
12984         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
12985         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
12986         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12987         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
12988         * m4/readdir.m4: Remove; no longer needed.
12989
12990 2006-07-06  Derek R. Price  <derek@ximbiot.com>
12991         and Paul Eggert  <eggert@cs.ucla.edu>
12992
12993         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
12994         Don't worry about this obsolete case any more.
12995         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
12996         directories.
12997         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
12998         worry about this obsolete case any more.
12999         * lib/fts.c: Likewise.
13000         * lib/getcwd.c: Likewise.
13001         * lib/glob.h: Likewise.
13002         * lib/savedir.c: Likewise.
13003
13004 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13005
13006         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
13007         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
13008         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
13009         needed.
13010         All uses removed.
13011         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13012         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13013         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
13014         needed.
13015         * m4/getdate.m4 (gl_GETDATE): Likewise.
13016         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13017         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13018         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13019         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13020         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13021         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13022         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
13023         needed.
13024
13025 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13026
13027         * lib/memcasecmp.c: Include <limits.h>.
13028         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
13029         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
13030         Don't assume isdigit succeeds only on '0' through '9'.
13031
13032 2006-07-05  Eric Blake  <ebb9@byu.net>
13033
13034         * modules/getaddrinfo (Depends-on): Add snprintf.
13035
13036 2006-07-05  Eric Blake  <ebb9@byu.net>
13037
13038         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
13039         to avoid 'header present but could not be compiled' on cygwin.
13040
13041 2006-07-05  Eric Blake  <ebb9@byu.net>
13042
13043         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
13044         missing from netdb.h.
13045         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
13046
13047 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13048
13049         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
13050         no longer needed.
13051         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
13052         * m4/getdate.m4 (gl_GETDATE): Likewise.
13053         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13054         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13055         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13056         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13057         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13058
13059 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13060
13061         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
13062         All uses of is_space replaced by isspace.
13063         * lib/exit.h: Don't talk about STDC_HEADERS.
13064         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
13065         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
13066         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
13067         replaced by isprint etc.
13068         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
13069         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13070         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
13071         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
13072         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
13073         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13074
13075 2006-07-05  Bruno Haible  <bruno@clisp.org>
13076
13077         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
13078         the function exists, before testing against AIX.
13079         Reported by Martin Lambers <marlam@marlam.de>.
13080
13081 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13082
13083         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
13084         From Mark D. Baushke.
13085
13086 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13087
13088         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
13089         to the absolute name, not just one, to bypass Sun C 5.8's
13090         "warning: #include of /usr/include/... may be non-portable".
13091
13092 2006-07-04  Eric Blake  <ebb9@byu.net>
13093
13094         * modules/dirname-tests: New test module.
13095         * tests/test-dirname.c: New file, replacing dirname.c
13096         TEST_DIRNAME section that was recently deleted.
13097
13098 2006-07-04  Bruno Haible  <bruno@clisp.org>
13099
13100         Assume ANSI C header files and <ctype.h> functions.
13101         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
13102         (mbsnwidth): Use isprint, iscntrl instead.
13103
13104 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13105
13106         Merge from coreutils.
13107         * MODULES.html.sh: Add xstrtold.
13108         * modules/xstrtold: New file.
13109         * modules/cycle-check (Files): Add lib/same-inode.h.
13110         * modules/dirname (Files): Add m4/double-slash-root.m4.
13111         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
13112         * modules/mkdir-p (Files): Add lib/same-inode.h.
13113         * modules/same (Files): Add lib/same-inode.h.
13114
13115 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13116
13117         * m4/absolute-header.m4: Renamed from full-header-path.m4.
13118         This is to keep the terminology clean; POSIX talks about
13119         "absolute pathnames", not "full pathnames", but the GNU
13120         Coding Standards say to use "path" for something else;
13121         so use "absolute" to keep both sides happy.
13122         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
13123         Set gl_absolute_header, not gl_full_header_path.
13124         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
13125         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
13126         All uses changed.
13127
13128         Merge from coreutils.
13129
13130         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13131
13132         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
13133         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
13134         want to require the building of c-strtod.o.
13135         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
13136         needs -lm directly.
13137         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
13138
13139         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13140
13141         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
13142         --as-needed option if available.  Problem reported by Albert Chin in
13143         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
13144         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
13145         cc merely issues a bunch of annoying warnings for --as-needed
13146         (this problem was reported by Bob Proulx).  Also, try linking with
13147         -lm to detect a bug in binutils 2.16 (this problem was reported
13148         by Ralf Wildenhues).
13149
13150         2006-06-18  Jim Meyering  <jim@meyering.net>
13151
13152         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
13153         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
13154         macro.
13155         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
13156         also check for glibc-2.4's abort-inducing bug.
13157
13158         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
13159         Low-probability clean-up should be to use rmdir to get rid of
13160         the just-created directory, not unlink.
13161
13162         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
13163         configure fail, and request a bug report to inform us about it.
13164         Add a comment that, barring reports to the contrary, in 2007 we'll
13165         assume ftruncate is universally available.
13166
13167         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13168
13169         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
13170
13171         2006-03-12  Jim Meyering  <jim@meyering.net>
13172
13173         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
13174         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
13175         * m4/same.m4 (gl_SAME): Likewise.
13176         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
13177
13178         2006-03-11  Eric Blake  <ebb9@byu.net>
13179
13180         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
13181         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
13182         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
13183         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
13184
13185 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13186
13187         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
13188         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
13189         reported by Mark D. Baushke, one in
13190         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
13191
13192         Merge from coreutils.
13193
13194         * lib/.cppi-disable: Add stdint_.h.
13195         * lib/.cvsignore: Add stdint.h.
13196
13197         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13198
13199         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
13200         both double and long double versions.
13201         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
13202         * lib/xstrtold.c: New file.
13203         * lib/xstrtod.h (xstrtold): New decl.
13204
13205         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
13206
13207         * lib/filemode.c (setst): Remove.
13208         (strmode): Rewrite to avoid setst.  This makes the code shorter,
13209         (arguably) clearer, and the generated code is a bit smaller on my
13210         Debian GNU/Linux stable x86 host.
13211
13212         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13213
13214         * lib/filemode.c: Include "filemode.h" first, to test the interface.
13215         Assume that filemode.h includes sys/types.h and sys/stat.h.
13216         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
13217         (ftypelet): Reorder to put common cases first, for efficiency.
13218         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
13219         to do 'M'.
13220         (strmode): Renamed from mode_string, and now stores 12 bytes instead
13221         of 10, for compatibility with FreeBSD.  All callers changed.
13222         (filemodestring): Now stores 12 bytes instead of 10, and sets file
13223         types that can't be deduced solely from st_mode.  First arg is now a
13224         const pointer.
13225         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
13226         (strmode): Renamed from mode_string.
13227         (filemodestring): New decl.
13228         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
13229         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
13230         needed.
13231         (S_ISPORT, S_ISWHT): New macros, if not already defined.
13232
13233         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
13234
13235         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
13236         fsusage.h now does that.  Include fsusage.h first, to test interface.
13237         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
13238         at most one method (the old code could have generated decls that
13239         didn't conform to C89, not that this was ever exercised).
13240         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
13241
13242         2006-03-19  Jim Meyering  <jim@meyering.net>
13243
13244         Work even in a chroot where d_ino values for entries in "/"
13245         don't match the stat.st_ino values for the same names.
13246         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
13247         number, iterate through all entries again, using lstat instead.
13248         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
13249         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
13250
13251         * lib/getcwd.c (__getcwd): Clarify a comment.
13252         Use memcpy in place of a call to strcpy.
13253
13254         2006-03-12  Jim Meyering  <jim@meyering.net>
13255
13256         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
13257         matches that of the current directory (which we're about to chdir ".."
13258         out of), then save the dev-ino of the parent, instead.
13259
13260         * lib/same-inode.h (SAME_INODE): New file/macro.
13261         * lib/chdir-safer.c (SAME_INODE): Remove definition.
13262         Include "same-inode.h", instead.
13263         * lib/same.c: Likewise.
13264         * lib/cycle-check.h: Include "same-inode.h".
13265         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
13266         * lib/cycle-check.c (SAME_INODE): Remove definition.
13267         * lib/root-dev-ino.h: Include "same-inode.h".
13268
13269         2006-03-11  Eric Blake  <ebb9@byu.net>
13270
13271         * lib/same.c (same_name): s/base_name/last_component/
13272         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
13273         * lib/filenamecat.c (file_name_concat): Likewise.
13274
13275         2006-03-11  Eric Blake  <ebb9@byu.net>,
13276                     Paul Eggert  <eggert@cs.ucla.edu>
13277
13278         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
13279         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
13280         drive prefix.
13281         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
13282         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
13283         (last_component): New method.
13284         * lib/dirname.c (dir_len): Determine when drive letters need a
13285         subsequent slash.  Preserve // when it is special.
13286         (dir_name): Don't append dot when drive letter is absolute.
13287         [TEST_DIRNAME]: Move into a full-blown gnulib test.
13288         * lib/basename.c (base_name): New semantics - malloc the result.
13289         Preserve // when it is special.  Preserve relative files that look
13290         like drive letters.
13291         (base_len): Preserve // when it is special.
13292         (last_component): New method, similar to old base_name semantics.
13293         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
13294         base_name.  Strip redundant slashes from ///.
13295
13296 2006-07-03  Jim Meyering  <jim@meyering.net>
13297
13298         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
13299         macro is used before the first cycle_check call.
13300
13301 2006-07-03  Eric Blake  <ebb9@byu.net>
13302
13303         * modules/dirname (Depends-on): Add xstrndup.
13304
13305 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13306
13307         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
13308         test cases, so that config.log is a bit easier to follow.
13309
13310 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13311
13312         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
13313         both are 64 bits, since this seems to be the tradition, and this
13314         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
13315         we ever run into a host that prefers long long to long in this
13316         case, we'll need another configure-time test.  Problem reported by
13317         Jim Meyering.
13318
13319 2006-07-02  Eric Blake  <ebb9@byu.net>
13320
13321         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
13322
13323 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13324
13325         * modules/inttypes (Depends-on): No longer depends on stdint.
13326         * modules/stdint (Description): Say more about assumptions.
13327         Say that the fast types might differ.  Say macros are used.
13328         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
13329         (Makefile.am): Revise list of substituted symbols to match
13330         new stdint.m4.
13331         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
13332         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
13333         * tests/test-stdint.c (verify_same_types)
13334         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
13335         the code conforms to C99/C89.
13336         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
13337         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
13338
13339 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13340
13341         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
13342         but fix a bug, by requiring at least 64 bits.
13343         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
13344         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
13345         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
13346         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
13347
13348         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
13349         changes.  Make 2.59 a prerequisite.  Check and substitute for
13350         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
13351         inttypes.h.  Do not use special include files; just use the
13352         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
13353         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
13354         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
13355         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
13356         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
13357         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
13358         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
13359         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
13360         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
13361         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
13362         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
13363         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
13364         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
13365         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
13366         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
13367         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
13368         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
13369         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
13370         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
13371         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
13372         WINT_MAX.  Check for C99 conformance more strictly, by detecting
13373         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
13374         not check for things that C99 does not require, e.g., int8_t.  If
13375         a test isn't needed unless <stdint.h> isn't working, and is
13376         unlikely to be needed for any other reason, then don't do it
13377         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
13378         size_t, since we assume C89 freestanding at least.  Do not check
13379         for sig_atomic_t, wchar_t, or wint_t, since the code now does
13380         the right thing even if the types are not defined.  Instead use:
13381         (gl_STDINT_TYPE_PROPERTIES): New macro.
13382         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
13383         testing whether <sys/types.h> clashes, as Autoconf does this for
13384         us now.  All uses removed.
13385         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
13386         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
13387         (gl_CHECK_TYPE_SAME):
13388         Remove; no longer needed.
13389         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
13390         exists, since we'll return 0 anyway in that case.
13391         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
13392
13393 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13394
13395         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
13396         possible collision with system files.
13397         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
13398         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
13399         WCHAR_MIN and WCHAR_MAX in this case.
13400         (<stddef.h>): Do not include; no longer needed.
13401         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
13402         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
13403         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
13404         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
13405         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
13406         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
13407         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
13408         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
13409         !defined(__c99))]: Include in this case too, since it's harmless
13410         now.
13411         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
13412         dangerous to do so.
13413         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
13414         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
13415         (_STDINT_MIN, _STDINT_MAX): New macros.
13416         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
13417         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
13418         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
13419         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
13420         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
13421         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
13422         macros, not typedefs; this simplifies things quite a bit.
13423         Use long int for all types narrower than int64_t.
13424         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
13425         Define in terms of long long int or int64_t or long int,
13426         not int64_t or int32_t.  This saves some compile-time testing.
13427         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
13428         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
13429         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
13430         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
13431         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
13432         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
13433         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
13434         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
13435         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
13436         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
13437         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13438         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13439         undef any previous version and define our own version, for
13440         simplicity and consistency with the new macros for types.
13441         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13442         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13443         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
13444         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
13445         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
13446         @WINT_T_SUFFIX@ to keep things simple here.
13447         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
13448         Simplify by assuming typical 8/16/32/64 host, since we're
13449         already doing that elsewhere anyway.
13450         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
13451         and assume long long int is 64 bits if available.  This
13452         speeds up 'configure'.
13453
13454 2006-07-01  Eric Blake  <ebb9@byu.net>
13455
13456         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
13457         Reported by Andreas Buening.
13458
13459 2006-07-01  Eric Blake  <ebb9@byu.net>
13460
13461         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
13462
13463 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13464
13465         * lib/getaddrinfo.c: fixed typo
13466
13467 2006-06-29  Jim Meyering  <jim@meyering.net>
13468
13469         * modules/strftime (Maintainer): Add my name, since with the
13470         FPRINTFTIME changes strftime.c has forked from glibc.
13471
13472 2006-06-29  Eric Blake  <ebb9@byu.net>
13473
13474         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
13475
13476 2006-06-29  Eric Blake  <ebb9@byu.net>
13477
13478         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
13479
13480 2006-06-29  Eric Blake  <ebb9@byu.net>
13481
13482         * lib/stat_.h: New file.
13483
13484 2006-06-29  Eric Blake  <ebb9@byu.net>
13485
13486         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
13487         unused static function.
13488
13489 2006-06-29  Eric Blake  <ebb9@byu.net>
13490
13491         * doc/functions.texi (Function Portability): Document missing lstat
13492         on mingw.
13493
13494 2006-06-29  Eric Blake  <ebb9@byu.net>
13495
13496         * MODULES.html.sh: Add sys_stat.
13497         * modules/sys_stat: New module.
13498         * modules/mkstemp (Depends-on): Add sys_stat.
13499
13500 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13501
13502         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
13503
13504 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13505
13506         * m4/c-bs-a.m4: Removed.
13507
13508 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13509
13510         * lib/strftime.c: Assume strftime() exists.
13511
13512 2006-06-29  Derek Price  <derek@ximbiot.com>
13513
13514         * modules/c-bs-a: Removed - \a is C89.
13515         * MODULES.html.sh: Remove c-bs-a.
13516
13517 2006-06-29  Bruno Haible  <bruno@clisp.org>
13518
13519         * modules/wcwidth (License): Change to LGPL.
13520
13521 2006-06-28  Simon Josefsson  <jas@extundo.com>
13522
13523         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
13524         on _WIN32.
13525
13526         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
13527         getnameinfo.
13528
13529 2006-06-28  Simon Josefsson  <jas@extundo.com>
13530
13531         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
13532
13533 2006-06-28  Simon Josefsson  <jas@extundo.com>
13534
13535         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
13536         functions there.  It will succeed on Windows XP, but on Windows
13537         2000 and (presumably) earlier, it will fail, and use the internal
13538         re-implementation.
13539         (use_win32_p): New function.
13540         (getaddrinfo): Use strtoul on servname, to support numeric ports.
13541         Support AI_NUMERICSERV to disable getservbyname.
13542         (getnameinfo): New function, only supports
13543         NI_NUMERICHOST|NI_NUMERICSERV for now.
13544
13545         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
13546         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
13547         getnameinfo.
13548
13549 2006-06-28  Eric Blake  <ebb9@byu.net>
13550
13551         * modules/wcwidth: New file.
13552         * modules/mbchar (Depends-on): Add wcwidth.
13553         * modules/mbswidth (Depends-on): Add wcwidth.
13554         * MODULES.html.sh: Add wcwidth.
13555
13556 2006-06-28  Eric Blake  <ebb9@byu.net>
13557
13558         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
13559         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
13560
13561 2006-06-28  Eric Blake  <ebb9@byu.net>
13562
13563         * lib/xvasprintf.h: Fix comments.
13564
13565 2006-06-28  Eric Blake  <ebb9@byu.net>
13566
13567         * lib/mbchar.h (wcwidth): Include wcwidth.h.
13568         * lib/mbswidth.c (wcwidth): Move from here...
13569         * lib/wcwidth.h: ...to this new file.
13570
13571 2006-06-28  Derek R. Price  <derek@ximbiot.com>
13572
13573         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
13574
13575         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
13576         it's obsolete.
13577         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
13578
13579 2006-06-28  Derek R. Price  <derek@ximbiot.com>
13580
13581         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
13582         Autoconf 2.60 says this stuff was obsolete.
13583
13584 2006-06-28  Bruno Haible  <bruno@clisp.org>
13585
13586         * modules/wcwidth (Files): Add m4/wchar_t.m4.
13587
13588 2006-06-28  Bruno Haible  <bruno@clisp.org>
13589
13590         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
13591         gt_TYPE_WCHAR_T.
13592
13593 2006-06-28  Bruno Haible  <bruno@clisp.org>
13594
13595         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
13596         declaration for wcwidth.
13597         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
13598
13599 2006-06-28  Bruno Haible  <bruno@clisp.org>
13600
13601         * lib/mkdtemp.c [MINGW]: Include <io.h>.
13602         (mkdir): Define using _mkdir.
13603
13604 2006-06-28  Bruno Haible  <bruno@clisp.org>
13605
13606         * lib/getaddrinfo.h: Fix POSIX URL.
13607         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
13608         _WIN32.
13609         (use_win32_p): Make static.
13610         (getaddrinfo): Reject service name if it is empty or does not consist
13611         solely of decimal digits, or if its value is > 65535.
13612         (getnameinfo): Remove useless casts.
13613
13614 2006-06-27  Simon Josefsson  <jas@extundo.com>
13615
13616         * modules/sys_select: New file, suggested by Bruno Haible, Paul
13617         Eggert and Martin Lambers.
13618
13619 2006-06-27  Simon Josefsson  <jas@extundo.com>
13620
13621         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
13622         Eggert and Martin Lambers.
13623
13624 2006-06-27  Bruno Haible  <bruno@clisp.org>
13625
13626         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
13627         result to 0, not to empty.
13628         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
13629
13630 2006-06-27  Bruno Haible  <bruno@clisp.org>
13631
13632         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
13633
13634 2006-06-26  Simon Josefsson  <jas@extundo.com>
13635
13636         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
13637         present.
13638
13639 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
13640
13641         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
13642         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
13643         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
13644
13645 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
13646
13647         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
13648
13649 2006-06-26  Bruno Haible  <bruno@clisp.org>
13650
13651         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
13652
13653 2006-06-26  Bruno Haible  <bruno@clisp.org>
13654
13655         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
13656
13657 2006-06-26  Bruno Haible  <bruno@clisp.org>
13658
13659         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
13660         SGI C compiler in pre-C99 mode.
13661         Suggested by Mark D. Baushke and Larry Jones.
13662
13663 2006-06-26  Bruno Haible  <bruno@clisp.org>
13664
13665         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
13666         WCHAR_MAX.
13667         Reported by Mark D. Baushke and Larry Jones.
13668
13669 2006-06-26  Bruno Haible  <bruno@clisp.org>
13670
13671         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
13672         in pre-C99 mode.
13673         Suggested by Mark D. Baushke and Larry Jones.
13674
13675 2006-06-23  Simon Josefsson  <jas@extundo.com>
13676             Bruno Haible  <bruno@clisp.org>
13677
13678         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
13679         Emit mostlyclean-local rule.
13680         (func_emit_tests_Makefile_am): Likewise.
13681         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
13682
13683 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
13684
13685         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
13686
13687 2006-06-23  Bruno Haible  <bruno@clisp.org>
13688
13689         * tests/test-stdint.c: Update to match ISO C 99 Technical
13690         Corrigendum 1.
13691
13692 2006-06-23  Bruno Haible  <bruno@clisp.org>
13693
13694         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
13695
13696 2006-06-23  Bruno Haible  <bruno@clisp.org>
13697
13698         * lib/stdint_.h: Treat IRIX like OpenBSD.
13699
13700 2006-06-23  Bruno Haible  <bruno@clisp.org>
13701
13702         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
13703         ISO C 99 Technical Corrigendum 1.
13704
13705 2006-06-22  Simon Josefsson  <jas@extundo.com>
13706
13707         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
13708         MinGW.
13709
13710 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
13711
13712         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
13713         needed.  Some compiler complained about some of them.  Problem reported
13714         by Larry Jones in
13715         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
13716
13717 2006-06-21  Simon Josefsson  <jas@extundo.com>
13718
13719         * tests/test-getaddrinfo.c: New file.
13720
13721         * modules/getaddrinfo-tests: New file.
13722
13723         * MODULES.html.sh: Add inet_pton.
13724
13725         * modules/inet_pton: New file.
13726
13727 2006-06-21  Simon Josefsson  <jas@extundo.com>
13728
13729         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
13730         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
13731         of using the (limited) gnulib implementation on Windows XP.
13732
13733         * m4/inet_pton.m4: New file.
13734
13735 2006-06-21  Simon Josefsson  <jas@extundo.com>
13736
13737         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
13738         variable.
13739
13740         * lib/socket_.h: Don't define WINVER.
13741
13742         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
13743         slightly modified to work in gnulib.
13744
13745 2006-06-21  Simon Josefsson  <jas@extundo.com>
13746
13747         * doc/gnulib.texi (Windows sockets): Add.
13748
13749 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
13750
13751         * lib/read-file.c (fread_file): Start with buffer allocation of
13752         0 bytes rather than 1 byte; this simplifies the code.
13753         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
13754         code to free buffer and save/restore errno.
13755         (internal_read_file): Remove unused local.
13756
13757 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
13758
13759         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
13760         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
13761         Problem reported by Denis Excoffier in
13762         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
13763
13764 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13765
13766         * modules/sys_socket, modules/socklen: Include sys/types since
13767         FreeBSD 4.x's sys/socket.h needs it.
13768
13769 2006-06-19  Simon Josefsson  <jas@extundo.com>
13770
13771         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
13772
13773 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13774
13775         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
13776
13777 2006-06-19  Bruno Haible  <bruno@clisp.org>
13778
13779         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
13780         and FULL_PATH_INTTYPES_H in angle brackets.
13781         Reported by Mark D. Baushke <mdb@gnu.org>.
13782
13783 2006-06-17  Eric Blake  <ebb9@byu.net>
13784
13785         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
13786         errno.
13787
13788 2006-06-17  Bruno Haible  <bruno@clisp.org>
13789
13790         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
13791         <sys/inttypes.h>.
13792
13793 2006-06-17  Bruno Haible  <bruno@clisp.org>
13794
13795         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
13796         whether errno is declared. Assume <errno.h> declares errno.
13797
13798 2006-06-17  Bruno Haible  <bruno@clisp.org>
13799
13800         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
13801
13802 2006-06-17  Bruno Haible  <bruno@clisp.org>
13803
13804         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
13805         problem on Solaris 2.5.1.
13806
13807 2006-06-16  Eric Blake  <ebb9@byu.net>
13808
13809         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
13810         * lib/unicodeio.c [!defined errno]: Likewise.
13811         * lib/strtol.c [!defined errno]: Likewise.
13812         * lib/strtod.c [!defined errno]: Likewise.
13813
13814 2006-06-15  Eric Blake  <ebb9@byu.net>
13815
13816         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
13817
13818 2006-06-15  Eric Blake  <ebb9@byu.net>
13819
13820         * config/srclist.txt (ssize_t.m4): Lose sync.
13821
13822 2006-06-15  Bruno Haible  <bruno@clisp.org>
13823
13824         * modules/stdint (Files): Include m4/full-header-path.m4,
13825         m4/size_max.m4, m4/wchar_t.m4.
13826         (Makefile.am): Many more substitutions.
13827         * modules/stdint-tests: New file.
13828         * tests/test-stdint.c: New file.
13829
13830 2006-06-15  Bruno Haible  <bruno@clisp.org>
13831
13832         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
13833         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
13834         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
13835         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
13836         gl_CHECK_TYPE_SAME): New macros.
13837
13838 2006-06-15  Bruno Haible  <bruno@clisp.org>
13839
13840         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
13841
13842 2006-06-15  Bruno Haible  <bruno@clisp.org>
13843
13844         * lib/stdint_.h: Rewritten to be fully auto-configured.
13845         Fixes bug on HP-UX/IA64.
13846
13847 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
13848
13849         * lib/getdate.y (__attribute__): Don't define if already defined.
13850         Problem reported by Larry Jones.
13851         * lib/utimens.c (__attribute__): Likewise.
13852
13853 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
13854
13855         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
13856         reported by Andreas Schwab.
13857
13858 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13859             Bruno Haible  <bruno@clisp.org>
13860
13861         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
13862         check for the declaration of strnlen and a run test that exposes the
13863         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
13864         rpl_strndup.
13865
13866 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13867             Bruno Haible  <bruno@clisp.org>
13868
13869         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
13870
13871 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13872
13873         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
13874         compile test, for Tru64 4.0D.
13875
13876 2006-05-28  Karl Berry  <karl@gnu.org>
13877
13878         * config/srclist.txt (printf-args.c): lose sync.
13879
13880 2006-05-26  Martin Lambers  <marlam@marlam.de>
13881
13882         * lib/getpass.c: Updates the test for the native W32 API, and adds
13883         missing includes, thus fixing compilation warnings.
13884
13885 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
13886
13887         * lib/exclude.c (exclude_fnmatch): New function.
13888         (excluded_file_name): Call exclude_fnmatch.
13889         * lib/exclude.h (excluded_file_name): New prototype
13890
13891 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
13892
13893         * lib/tempname.c (small_open, large_open): New macros.
13894         (__open, __open64) [!_LIBC]: Remove.
13895         (__gen_tempname): Use small_open and large_open instead of __open
13896         and __open64.  This fixes a portability bug on HP-UX 11.11i
13897         reported by Simon Wing-Tang in
13898         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
13899
13900 2006-05-24  Bruno Haible  <bruno@clisp.org>
13901
13902         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
13903         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
13904         Reported by Thorsten Maerz <torte@netztorte.de> via
13905         Aaron Stone <aaron@serendipity.cx>.
13906
13907 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
13908
13909         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
13910         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
13911         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
13912         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
13913         not really conditional on the cache.
13914         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
13915
13916 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
13917
13918         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
13919         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
13920         (my_usleep): Don't mishandle maximum value.
13921
13922 2006-05-19  Jim Meyering  <jim@meyering.net>
13923
13924         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
13925
13926 2006-05-17  Bruno Haible  <bruno@clisp.org>
13927
13928         Cygwin portability.
13929         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
13930
13931 2006-05-17  Bruno Haible  <bruno@clisp.org>
13932
13933         * lib/stdint_.h: Fix recognition of Cygwin.
13934
13935 2006-05-15  Bruno Haible  <bruno@clisp.org>
13936
13937         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
13938         on libtool patch by Ralf Wildenhues.
13939
13940 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
13941
13942         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
13943         test for C99 conformance; (bool) 0.5 is an integer constant
13944         expression, but (bool) -0.5 is not.  Problem reported by Fedor
13945         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
13946
13947 2006-05-11  Simon Josefsson  <jas@extundo.com>
13948
13949         * m4/xvasprintf.m4: Fix obvious typo.
13950
13951 2006-05-11  Jim Meyering  <jim@meyering.net>
13952
13953         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
13954         James Lemley.
13955
13956 2006-05-10  Simon Josefsson  <jas@extundo.com>
13957
13958         * lib/md4.c: Typo fix, update copyright years.
13959         (K1, K2): Don't use L because it turn computations into 64-bit on
13960         64-bit platforms.
13961
13962 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
13963
13964         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
13965         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
13966         unwanted sign propagation, e.g., on hosts with 64-bit int.
13967         There still are some problems with reeelly weird theoretical hosts
13968         (e.g., 33-bit int) but it's not worth worrying about now.
13969         * lib/sha1.c (rol): Likewise.
13970         (K1, K2, K3, K4): Remove unnecessary L suffix.
13971
13972 2006-05-10  Bruno Haible  <bruno@clisp.org>
13973
13974         * lib/des.c: Cast to avoid warnings.
13975
13976 2006-05-09  Bruno Haible  <bruno@clisp.org>
13977
13978         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
13979         (Depends-on): Depend also on xsize, stdarg.
13980         (configure.ac): Add gl_XVASPRINTF.
13981
13982 2006-05-09  Bruno Haible  <bruno@clisp.org>
13983
13984         * m4/xvasprintf.m4: New file.
13985
13986 2006-05-09  Bruno Haible  <bruno@clisp.org>
13987
13988         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
13989         (EOVERFLOW): Define fallback value.
13990         (xstrcat): New function.
13991         (xvasprintf): Recognize the special case of a string concatenation.
13992
13993 2006-05-08  Eric Blake  <ebb9@byu.net>
13994
13995         * gnulib-tool (func_version): Base copyright year on CVS date.
13996         (func_emit_copyright_notice): New function.
13997         (func_emit_lib_Makefile_am): Use it.
13998         (func_emit_tests_Makefile_am): Likewise.
13999         (func_import): Likewise.
14000
14001 2006-05-08  Bruno Haible  <bruno@clisp.org>
14002
14003         * modules/stdarg: New file.
14004         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
14005
14006 2006-05-08  Bruno Haible  <bruno@clisp.org>
14007
14008         * m4/stdarg.m4: New file, from GNU gettext.
14009
14010 2006-05-08  Bruno Haible  <bruno@clisp.org>
14011
14012         * config/srclist.txt (build-aux/config.rpath): different from latest
14013         release.
14014
14015 2006-05-08  Bruno Haible  <bruno@clisp.org>
14016
14017         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
14018
14019 2006-05-05  Jim Meyering  <jim@meyering.net>
14020
14021         * m4/warning.m4: New file, derived from bison's file by the same name.
14022
14023 2006-05-03  Bruno Haible  <bruno@clisp.org>
14024
14025         * lib/stdint_.h: Shorter URL.
14026         * lib/inttypes.h: Likewise.
14027
14028 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14029
14030         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
14031
14032 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14033
14034         * lib/verify.h: Document the internals better.  Most of this change
14035         was written by Bruno Haible.
14036
14037 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14038
14039         * doc/verify.texi: New file, partly based on a proposal by
14040         Bruno Haible.
14041
14042 2006-05-02  Bruno Haible  <bruno@clisp.org>
14043
14044         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
14045         test from here...
14046         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
14047
14048 2006-04-29  Bruno Haible  <bruno@clisp.org>
14049
14050         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
14051         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
14052
14053 2006-04-29  Bruno Haible  <bruno@clisp.org>
14054
14055         * gnulib-tool: Make --update option actually work.
14056
14057 2006-04-29  Bruno Haible  <bruno@clisp.org>
14058
14059         * doc/gcd.texi: New file.
14060         * doc/gnulib.texi: Include it.
14061
14062 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
14063
14064         * lib/getdate.y (get_date): When adding relative date, start with the
14065         initial time, not with the result of the first mktime call.
14066
14067 2006-04-25  Bruno Haible  <bruno@clisp.org>
14068
14069         * gnulib-tool (func_import): Output the include directives in three
14070         blocks, sorted separately.
14071         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14072
14073 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14074
14075         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
14076         to define main with arguments, for C++.  Reported by Eric Blake.
14077         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
14078         Prefer 'int main ()' to 'int main (void)', for C++.
14079         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
14080         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
14081         for 'main', for C99 and C++.
14082
14083 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14084
14085         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
14086         Don't assume that exit status -1 is valid.
14087         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14088         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
14089         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
14090         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
14091         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
14092         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
14093         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
14094         functions can be used without declaring them, or that you can
14095         exit with status -1.
14096         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
14097
14098 2006-04-24  Karl Berry  <karl@gnu.org>
14099
14100         * config/srclist.txt (longdouble.m4): sync lost.
14101
14102 2006-04-24  Eric Blake  <ebb9@byu.net>
14103
14104         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
14105
14106 2006-04-24  Bruno Haible  <bruno@clisp.org>
14107
14108         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
14109         poll() implementation in AIX.
14110         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14111
14112 2006-04-24  Bruno Haible  <bruno@clisp.org>
14113
14114         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
14115         assigned exactly once.
14116
14117 2006-04-23  Claudio Fontana  <claudio@gnu.org>
14118             Bruno Haible  <bruno@clisp.org>
14119
14120         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
14121         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
14122         for AM_CPPFLAGS.
14123
14124 2006-04-23  Bruno Haible  <bruno@clisp.org>
14125
14126         * modules/copy-file: Depend on unistd.
14127         * modules/execute: Likewise.
14128         * modules/fatal-signal: Likewise.
14129         * modules/findprog: Likewise.
14130         * modules/mkdtemp : Likewise.
14131         * modules/pipe: Likewise.
14132         * modules/wait-process: Likewise.
14133
14134 2006-04-23  Bruno Haible  <bruno@clisp.org>
14135
14136         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
14137         condition was already detected.
14138         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14139
14140 2006-04-23  Bruno Haible  <bruno@clisp.org>
14141
14142         * lib/copy-file.c: Include <unistd.h> unconditionally.
14143         * lib/execute.c: Likewise.
14144         * lib/fatal-signal.c: Likewise.
14145         * lib/findprog.c: Likewise.
14146         * lib/mkdtemp.c: Likewise.
14147         * lib/pipe.h: Likewise.
14148         * lib/pipe.c: Likewise.
14149         * lib/wait-process.h: Likewise.
14150
14151 2006-04-23  Bruno Haible  <bruno@clisp.org>
14152
14153         * gnulib-tool (func_usage): Fix --import description. Document
14154         --update.
14155         (func_import): Create temporary file in a temporary directory, if
14156         --dry-run is specified. Silence errors from 'grep' when there are no
14157         m4 files in $m4dir.
14158         (func_create_testdir): Silence errors from 'grep' when there are no
14159         m4 files in $m4dir.
14160         Reported by Karl Berry <karl@freefriends.org>.
14161
14162 2006-04-20  Bruno Haible  <bruno@clisp.org>
14163
14164         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
14165         one argument, so that the code will be portable to Autoconf 2.60.
14166         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
14167         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
14168         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
14169
14170 2006-04-19  Derek Price  <derek@ximbiot.com>
14171             Eric Blake  <ebb9@byu.net>
14172
14173         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
14174         rather than "/full/path.h".  Update comment to match.  Shorten &
14175         generalize m4_translit call via AS_TR_CPP.
14176
14177 2006-04-19  Derek Price  <derek@ximbiot.com>
14178             Eric Blake  <ebb9@byu.net>
14179
14180         * lib/inttypes.h: Correct grammar in comment.
14181
14182 2006-04-18  Derek Price  <derek@ximbiot.com>
14183             Paul Eggert  <eggert@cs.ucla.edu>
14184
14185         * modules/inttypes: New file.
14186         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
14187
14188 2006-04-18  Derek Price  <derek@ximbiot.com>
14189             Paul Eggert  <eggert@cs.ucla.edu>
14190
14191         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
14192         New files.
14193
14194 2006-04-18  Derek Price  <derek@ximbiot.com>
14195             Paul Eggert  <eggert@cs.ucla.edu>
14196
14197         * lib/inttypes.h: New file.
14198         * lib/strtoimax.c: Assume <inttypes.h>.
14199
14200 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
14201
14202         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
14203         isn't mounted.  Problem reported by Kir Kolyshkin.
14204
14205 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
14206
14207         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
14208         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
14209         Derek R. Price.
14210         * lib/regex.h (RE_DUP_MAX): Update comment to match current
14211         implementation.
14212
14213 2006-04-12  Eric Blake  <ebb9@byu.net>
14214
14215         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
14216         is now done automatically by the corresponding Autoconf macro.
14217
14218 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
14219
14220         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
14221         time_r.h.
14222
14223 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14224
14225         Merge regex changes from libc, removing some of our
14226         POSIX-conformance changes that were rejected and redoing them in a
14227         less-intrusive way.
14228
14229         * lib/regcomp.c (re_compile_internal, init_dfa):
14230         Length arg is now size_t, not Idx.  All uses changed.
14231         (peek_token): Forward decl now says internal_function.
14232         (__re_error_msgid, __re_error_msgid_idx):
14233         Now static rather than extern with attribute_hidden.
14234         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
14235         For some reason libc prefers K&R style defns for external functions.
14236         (regerror) [!defined _LIBC]: Likewise.
14237         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
14238         (seek_collating_symbol_entry, lookup_collation_sequence_value):
14239         (build_range_exp, build_collating_symbol):
14240         Use K&R-style defn.
14241         (re_compile_fastmap): Use '\0' to memset, not 0.
14242         (utf8_sb_map): Make the calculations more obvious.
14243         (init_dfa, parse_bracket_exp, build_charclass_op):
14244         Call calloc and cast result, as glibc does.
14245         (init_word_char, fetch_token, peek_token, peek_token_bracket):
14246         (build_range_exp, build_collating_symbol):
14247         Now internal functions.
14248
14249         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
14250
14251         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
14252         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
14253         Don't depend on VMS; depend on __VMS instead, for POSIX
14254         namespace cleanness.
14255         (regoff_t): Define to ssize_t, not long int.
14256
14257         Remove the REG_ macros named below.  Instead, make the old names
14258         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
14259         __USE_GNU_REGEX.
14260         (REG_BACKSLASH_ESCAPE_IN_LISTS):
14261         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
14262         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
14263         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
14264         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
14265         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
14266         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
14267         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
14268         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
14269         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
14270         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
14271         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
14272         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
14273         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
14274         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
14275         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
14276         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
14277         (REG_NREGS):
14278         Remove.  All uses replaced by the old RE_* names.
14279         (RE_BACKSLASH_ESCAPE_IN_LISTS):
14280         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
14281         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
14282         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
14283         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
14284         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
14285         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
14286         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
14287         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
14288         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
14289         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
14290         Don't bother having these macros be independent of each others'
14291         values, since they no longer exist in the POSIX name space.
14292
14293         Rename the following member names back to their old names,
14294         unless !__USE_GNU_REGEX.  All uses changed back.
14295         (buffer): Renamed from re_buffer.
14296         (allocated): Renamed from re_allocated.
14297         (used): Renamed from re_used.
14298         (syntax): Renamed from re_syntax.
14299         (fastmap): Renamed from re_fastmap.
14300         (translate): Renamed from re_translate.
14301         (can_be_null): Renamed from re_can_be_null.
14302         (regs_allocated): Renamed from re_regs_allocated.
14303         (fastmap_accurate): Renamed from re_fastmap_accurate.
14304         (no_sub): Renamed from re_no_sub.
14305         (not_bol): Renamed from re_not_bol.
14306         (not_eol): Renamed from re_not_eol.
14307         (newline_anchor): Renamed from re_newline_anchor.
14308         (num_regs): Renamed from rm_num_regs.
14309         (start): Renamed from rm_start.
14310         (end): Renamed from rm_end.
14311
14312         (free_state): Move up a bit.
14313
14314         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
14315         #define to be empty.
14316         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
14317         when that is what is intended.
14318         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
14319         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
14320         (MAX): New macro.
14321         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
14322         All uses changed back to re_malloc, etc.  It's now the caller's
14323         responsibility to check for overflow; all callers changed.
14324         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
14325         (re_x2nrealloc): Remove.
14326         (free_state): Remove decl.
14327
14328         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
14329         (re_set_registers, re_exec):
14330         Use K&R-style defn.
14331
14332         2006-01-31  Roland McGrath  <roland@redhat.com>
14333
14334         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
14335         Reported by Mike Frysinger <vapier@gentoo.org>.
14336
14337         2006-01-15  Andreas Jaeger  <aj@suse.de>
14338
14339         [BZ #1950]
14340         * lib/regex_internal.c (re_string_reconstruct): Adjust for
14341         build_wcs_upper_buffer change.
14342         (build_wcs_upper_buffer): Change return type.
14343
14344         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
14345
14346         * lib/regex_internal.h: Include <stdint.h> if available.
14347
14348         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
14349
14350         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
14351
14352         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
14353
14354         * lib/regcomp.c: Adjust for changed secondary hash function.
14355
14356         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
14357
14358         * lib/regex.h: Pretty printing.
14359         Clean up namespace a bit.
14360
14361         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
14362
14363         * lib/regexec.c (update_cur_sifted_state, check_arrival,
14364         check_arrival_add_next_nodes): Avoid using uninitialized variable.
14365
14366         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14367                     Ulrich Drepper  <drepper@redhat.com>
14368
14369         [BZ #1302]
14370         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
14371         changed.
14372         (bitset_word_t): Renamed from bitset_word.  All uses changed.
14373
14374         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
14375
14376         [BZ #281]
14377         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
14378         * lib/regcomp.c: Remove unnecessary uses of
14379         unsigned RE_TRANSLATE_TYPE.
14380         * lib/regex_internal.h: Likewise.
14381         * lib/regex_internal.c: Likewise.
14382         * lib/regexec.c: Likewise.
14383         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
14384
14385         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
14386
14387         * lib/regexec.c (find_recover_state): Remove unnecessary
14388         initialization.
14389         (transit_state_bkref): Make DFA a const pointer.
14390         (get_subexp): Likewise.
14391         (check_arrival): Likewise.
14392         (update_cur_sifted_state): Likewise.
14393         (re_search_internal): Likewise.
14394         (prune_impossible_nodes): Likewise.
14395         (acquire_init_state_context): Likewise.
14396         (proceed_next_node): Likewise.
14397         (set_regs): Likewise.
14398         (free_fail_stack_return): Likewise.
14399         (check_arrival_expand_ecl): Mark DFA parameter as const.
14400         (check_arrival_expand_ecl_sub): Likewise.
14401         (check_subexp_limits): Likewise.
14402         (sub_epsilon_src_nodes):  Likewise.
14403         (add_epsilon_src_nodes):  Likewise.
14404         (merge_state_array): Likewise.
14405         (update_regs): Likewise.
14406         (build_trtable): Likewise.
14407         (sift_states_backward): Mark MCTX parameter as const.
14408         (build_sifted_states): Likewise.
14409         (update_cur_sifted_state): Likewise.
14410         (sift_states_mkref): Likewise.
14411         (check_arrival_expand_ecl): Mark eclosure as const.
14412         (check_dst_limits_calc_pos_1): Likewise.
14413         * lib/regex_internal.h (re_match_context_t): Make dfa a const
14414         pointer.
14415
14416         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
14417
14418         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
14419         (transit_state_sb): Likewise.
14420         (transit_state_mb): Likewise.
14421         (sift_states_iter_mb): Likewise.
14422         (check_arrival_add_next_nodes): Likewise.
14423         (check_node_accept_bytes): Change first parameter to pointer-to-const.
14424         [_LIBC] (re_search_2_stub): Use mempcpy.
14425
14426         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
14427         mbrtowc for very simple UTF-8 case.
14428
14429         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
14430         a pointer-to-const.
14431         (re_acquire_state_context): Likewise.
14432         * lib/regex_internal.h: Adjust prototypes.
14433
14434         * lib/regex.c: Prevent using C++ compilers.
14435
14436         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
14437         (re_acquire_state_context): Likewise.
14438
14439 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14440
14441         * modules/regex (Depends-on): Add ssize_t.
14442
14443 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14444
14445         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
14446         translation table.
14447
14448 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14449
14450         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
14451
14452 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
14453             Bruno Haible  <bruno@clisp.org>
14454
14455         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
14456         <sys/types.h> and <inttypes.h>.
14457
14458 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14459
14460         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
14461         `__error_t_defined', so argp.h will not typedef the former.
14462
14463 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
14464
14465         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
14466         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
14467         glibc names.  Even if glibc is changed to conform to POSIX, the
14468         traditional names will be available anyway, since regex depends on
14469         the extensions module.  Also, fix a longstanding typo in the
14470         implementation of Spencer ERE test #75 from grep 2.3.  Problems
14471         reported by Emanuele Giaquinta.  Also, change sense of cached
14472         variable, so that the message makes sense.
14473
14474 2006-03-24  Simon Josefsson  <jas@extundo.com>
14475
14476         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
14477         including some doc fixes.
14478         (base64_encode_alloc): Fix +1 bug on allocation failures.
14479
14480 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14481
14482         * lib/base64.c (base64_encode): Do not read past end of array with
14483         unsanitized input on systems with CHAR_BIT > 8.
14484
14485 2006-03-24  Eric Blake  <ebb9@byu.net>
14486
14487         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
14488
14489 2006-03-22  Karl Berry  <karl@gnu.org>
14490
14491         * config/srclist.txt (*setenv.[ch]): get from coreutils.
14492         * config/srclistvars.sh (COREUTILS): new var.
14493
14494 2006-03-17  Jim Meyering  <jim@meyering.net>
14495
14496         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
14497         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
14498
14499 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
14500
14501         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
14502         no longer needs it.  Instead, check that regoff_t is as least
14503         as wide as ptrdiff_t.
14504
14505         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
14506         so that our regex.h stays compatible with the installed regex.
14507         This is helpful for installers who configure --without-included-regex.
14508         Problem reported by Emanuele Giaquinta.
14509
14510 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
14511
14512         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
14513         Typedef to long int, not to off_, as POSIX will likely change
14514         in that direction.
14515
14516 2006-03-15  Eric Blake  <ebb9@byu.net>
14517
14518         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
14519
14520 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
14521
14522         * lib/argp-help.c (validate_uparams): Fix typo
14523         * lib/argp-parse.c (argp_default_options): Consistently begin help
14524         messages with a lowercase letter.
14525
14526 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
14527
14528         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
14529         overrun buffers and shouldn't be used (much as gets shouldn't be
14530         used).
14531         * lib/time_r.c (asctime_r, ctime_r): Likewise.
14532
14533 2006-03-08  Simon Josefsson  <jas@extundo.com>
14534
14535         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
14536         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14537
14538 2006-03-08  Simon Josefsson  <jas@extundo.com>
14539
14540         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
14541         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14542
14543 2006-03-08  Simon Josefsson  <jas@extundo.com>
14544
14545         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
14546         signal that configure disabled the device.
14547
14548 2006-03-08  Simon Josefsson  <jas@extundo.com>
14549
14550         * build-aux/maint.mk: Fix refresh-po, to handle no translated
14551         languages.
14552
14553 2006-03-07  Simon Josefsson  <jas@extundo.com>
14554
14555         * modules/getopt (Depends-on): Add unistd.
14556
14557         * modules/unistd: New file.
14558
14559 2006-03-07  Simon Josefsson  <jas@extundo.com>
14560
14561         * modules/gc-random: New file.
14562
14563 2006-03-07  Simon Josefsson  <jas@extundo.com>
14564
14565         * m4/unistd_h.m4: New file.
14566
14567 2006-03-07  Simon Josefsson  <jas@extundo.com>
14568
14569         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
14570         test to be side-effect free by storing the result in the cache
14571         variable gl_cv_lib_readline, and moving the assignment of
14572         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
14573         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14574
14575 2006-03-07  Simon Josefsson  <jas@extundo.com>
14576
14577         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
14578         error on missing devices (the functions will return an error).
14579
14580         * m4/gc.m4: Move random stuff to gc-random.m4
14581
14582 2006-03-07  Simon Josefsson  <jas@extundo.com>
14583
14584         * lib/unistd_.h: New file.
14585
14586 2006-03-07  Simon Josefsson  <jas@extundo.com>
14587
14588         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
14589
14590 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14591
14592         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
14593         Problem reported by Juan Manuel Guerrero.
14594
14595 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14596
14597         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
14598         the unistd module.
14599         * lib/getlogin_r.c: Likewise.
14600         * lib/getlogin_r.h: Likewise.
14601         * lib/glob.c: Likewise.
14602         * lib/pagealign_alloc.c: Likewise.
14603         * lib/unistd_.h: Remove; no longer needed.
14604
14605 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
14606
14607         * MODULES.html.sh (Support for systems lacking POSIX:2001):
14608         Add unistd.
14609         * modules/c-stack (Depends-on): Add unistd.
14610         * modules/getlogin_r: Likewise.
14611         * modules/glob: Likewise.
14612         * modules/pagealign_alloc: Likewise.
14613         * modules/unistd (Files): Remove lib/unistd_.h.
14614         (EXTRA_DIST): Remove.
14615         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
14616         need unistd_.h.
14617         (MOSTLYCLEANFILES): Remove unistd.h-t.
14618
14619 2006-03-03  Simon Josefsson  <jas@extundo.com>
14620
14621         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
14622
14623 2006-03-03  Simon Josefsson  <jas@extundo.com>
14624
14625         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
14626         libidn and bison.
14627
14628 2006-03-03  Simon Josefsson  <jas@extundo.com>
14629
14630         * build-aux/maint.mk: Add indent target.
14631
14632 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
14633
14634         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
14635         our replacement poll.h in any case, to avoid a differing
14636         declaration from a system header.  Seen on AIX.
14637
14638 2006-03-01  Simon Josefsson  <jas@extundo.com>
14639
14640         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
14641         <kasal@ucw.cz>.
14642
14643 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14644
14645         * modules/gettime (Depends-on): Add extensions module.
14646         * modules/nanosleep (Depends-on): Likewise.
14647         * modules/settime (Depends-on): Likewise.
14648
14649 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
14650
14651         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
14652         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
14653         pedantically.
14654         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14655         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
14656
14657         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
14658         not "==".  Reported by Ralf Wildenhues.
14659
14660 2006-03-01  Karl Berry  <karl@gnu.org>
14661
14662         * doc/Copyright/request-*: new files, synced from gnuorg.
14663
14664 2006-03-01  Karl Berry  <karl@gnu.org>
14665
14666         * config/srclist.txt (Copyright/*): new entries.
14667
14668 2006-02-28  Simon Josefsson  <jas@extundo.com>
14669
14670         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
14671
14672 2006-02-27  Simon Josefsson  <jas@extundo.com>
14673
14674         * lib/base64.h: Indent #define's.  From Jim Meyering
14675         <jim@meyering.net>.
14676
14677 2006-02-27  Jim Meyering  <jim@meyering.net>
14678
14679         Revert the change of 2006-02-24, so these files can continue
14680         to be sync'd from gettext.
14681         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
14682         of `config.h'.
14683
14684 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
14685
14686         * modules/intprops: New file.
14687         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
14688         Add intprops.
14689         * modules/getloadavg (Files): Remove lib/intprops.h.
14690         (Depends-on): Add intprops.
14691         * modules/human: Likewise.
14692         * modules/inttostr: Likewise.
14693         * modules/openat: Likewise.
14694         * modules/sig2str: Likewise.
14695         * modules/userspec: Likewise.
14696         * modules/utimecmp: Likewise.
14697         * modules/xnanosleep: Likewise.
14698         * modules/xstrtol: Likewise.
14699
14700 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
14701
14702         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
14703         * modules/lock-tests (TESTS): Use $(EXEEXT).
14704         * modules/tls-tests: Likewise.
14705         * modules/argp-tests: Likewise.
14706         (check_PROGRAMS): New var, replacing...
14707         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
14708
14709 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14710
14711         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
14712         `config.h'.
14713
14714 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
14715
14716         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
14717
14718 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14719
14720         Sync from coreutils.
14721         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
14722         gl_CHDIR_SAFER.
14723
14724 2006-02-22  Jim Meyering  <jim@meyering.net>
14725
14726         Sync from coreutils.
14727         * m4/chdir-safer.m4: New file.
14728
14729 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
14730
14731         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
14732         AT_FDCWD exceeds INT_MAX.
14733         * lib/openat.h (AT_FDCWD): Likewise.
14734
14735 2006-02-17  Eric Blake  <address@hidden>
14736
14737         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
14738
14739 2006-02-16  Simon Josefsson  <jas@extundo.com>
14740
14741         * modules/getaddrinfo (Depends-on): Add sys_socket.
14742
14743 2006-02-15  Simon Josefsson  <jas@extundo.com>
14744
14745         * build-aux/maint.mk: Add dsyntax-check rule.
14746
14747 2006-02-15  Eric Blake  <ebb9@byu.net>
14748
14749         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
14750         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
14751         'present but cannot compile' warnings on cygwin.
14752         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
14753         use ws2tcpip.h if sys/socket.h works.
14754         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
14755         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
14756
14757 2006-02-14  Simon Josefsson  <jas@extundo.com>
14758
14759         * modules/maintainer-makefile (Files): Rename.
14760
14761         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
14762         and (the local) Makefile.cfg to maint-cfg.mk.
14763
14764         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
14765         to the latter.
14766
14767         * modules/maintainer-makefile: New module.
14768
14769         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
14770         severaly stripped to make it possible to build it up from scratch
14771         with reliable tests.
14772
14773         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
14774         fixes to permit overriding the default actions when configure and
14775         makefile are not available.
14776
14777 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
14778
14779         Sync from coreutils.
14780         * modules/lstat (Depends-on): Don't depend on xalloc.
14781         (License): Change from GPL to LGPL, since this is now simply a
14782         replacement for a libc function.
14783
14784 2006-02-14  Jim Meyering  <jim@meyering.net>
14785
14786         Sync from coreutils.
14787
14788         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
14789         failure on deficient systems, and simplify gnulib lgpl dependencies.
14790         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
14791         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
14792
14793         * lib/xalloc-die.c: Remove unused definition of N_.
14794
14795 2006-02-14  Jim Meyering  <jim@meyering.net>
14796
14797         Sync from coreutils.
14798         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
14799         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
14800         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
14801         double-quote uses of that variable, to accommodate the rare case in
14802         which getmntent is available in none of the libraries checked.  This
14803         happens at least on FreeBSD 5.0.
14804
14805 2006-02-13  Simon Josefsson  <jas@extundo.com>
14806
14807         * gnulib-tool (Usage): Fix --import, from
14808         karl@freefriends.org (Karl Berry).
14809
14810 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
14811
14812         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
14813
14814 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
14815
14816         * lib/argp-namefrob.h: Restore changes accidentally lost during the
14817         "autoupdate" on 2005-12-12.
14818
14819 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
14820
14821         * modules/closeout (Depends-on): Remove atexit.
14822
14823 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
14824
14825         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
14826         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
14827
14828 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
14829
14830         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
14831         __EXTENSIONS__ if this causes compilation to fail.  Problem
14832         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
14833         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
14834
14835 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
14836
14837         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
14838         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
14839         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
14840         All uses changed.
14841
14842 2006-01-26  Simon Josefsson  <jas@extundo.com>
14843
14844         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
14845         prototype is visible on mingw32.
14846
14847         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
14848         for mingw32.
14849
14850         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
14851         mingw32).
14852
14853 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
14854
14855         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
14856         attempt to open for write; this always fails, at least on POSIX
14857         hosts.  This reinstates the 2006-01-09 change, which was
14858         inadvertently removed.
14859
14860 2006-01-26  Bruno Haible  <bruno@clisp.org>
14861
14862         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
14863         Reported by Paul Eggert.
14864
14865 2006-01-26  Bruno Haible  <bruno@clisp.org>
14866             Paul Eggert  <eggert@cs.ucla.edu>
14867
14868         * lib/stdbool_.h (_Bool)
14869         [(! (defined __cplusplus || defined __BEOS__)
14870           && !defined __GNUC__
14871           && !(defined __HP_cc || defined __xlc__
14872                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
14873                || defined __sgi))]:
14874         #define to signed char in these cases too; this simplifies
14875         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
14876         etc., separately) and makes it more conservative.
14877
14878 2006-01-25  Simon Josefsson  <jas@extundo.com>
14879
14880         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
14881         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
14882         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
14883
14884 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14885
14886         * lib/argp-namefrob.h: Bugfix. Remove stray #
14887
14888 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
14889
14890         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
14891         so that we test the test.
14892         Check for yet another HP-UX cc bug involving *bool |= bool.
14893
14894 2006-01-25  Karl Berry  <karl@gnu.org>
14895
14896         * config/srclist.txt (vasnprintf.c): sync lost.
14897
14898 2006-01-25  Jim Meyering  <jim@meyering.net>
14899
14900         Sync from the stable (b5) branch of coreutils:
14901
14902         * lib/fts.c (fts_children): Don't let close() clobber errno from
14903         failed fchdir().
14904
14905         * lib/fts.c (fts_stat): When following a symlink-to-directory,
14906         don't necessarily interpret stat-fails+lstat-succeeds as indicating
14907         a dangling symlink.  That can also happen at least for ELOOP.
14908         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
14909         FYI, this bug predates the inclusion of fts.c in coreutils.
14910
14911         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
14912         in their own block, so pre-c99 compilers don't object.
14913
14914         Avoid the double-free (first in fts_read, second in fts_close) that
14915         would occur when an `active' directory is made inaccessible (e.g.,
14916         via chmod a-x) during a traversal.
14917         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
14918         before returning.  Reproduce this failure by
14919         mkdir -p a/b; cd a; chmod a-x . b
14920         Reported by Stavros Passas.
14921
14922 2006-01-25  Jim Meyering  <jim@meyering.net>
14923
14924         * lib/fileblocks.c: Remove more useless parentheses.
14925         * lib/readutmp.h: Likewise.
14926
14927 2006-01-25  Bruno Haible  <bruno@clisp.org>
14928
14929         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
14930         warnings.
14931         Reported by Paul Eggert.
14932
14933 2006-01-25  Bruno Haible  <bruno@clisp.org>
14934
14935         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
14936         rid of a trap command. For Solaris sh.
14937         Reported by Mark D. Baushke <mdb@gnu.org>.
14938
14939 2006-01-24  Simon Josefsson  <jas@extundo.com>
14940
14941         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
14942         Bruno.
14943
14944 2006-01-24  Karl Berry  <karl@gnu.org>
14945
14946         * config/srclist.txt (argp-namefrob.h): sync lost.
14947
14948 2006-01-24  Jim Meyering  <jim@meyering.net>
14949
14950         * modules/openat (Files): Add lib/intprops.h.
14951         From Mark D. Baushke.
14952
14953 2006-01-24  Jim Meyering  <jim@meyering.net>
14954
14955         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
14956         Reported by Mark D. Baushke.
14957
14958 2006-01-24  Jim Meyering  <jim@meyering.net>
14959
14960         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
14961
14962 2006-01-24  Bruno Haible  <bruno@clisp.org>
14963
14964         * modules/strnlen (Maintainer): Change from glibc to all.
14965
14966 2006-01-24  Bruno Haible  <bruno@clisp.org>
14967
14968         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
14969         Patch by Paul Eggert.
14970
14971 2006-01-24  Bruno Haible  <bruno@clisp.org>
14972
14973         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
14974         already has it.
14975         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
14976         2005-11-26.
14977
14978         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
14979         'signed char' to avoid problems with the built-in _Bool type.
14980         Reported by Paul Eggert on 2005-11-26.
14981
14982 2006-01-24  Bruno Haible  <bruno@clisp.org>
14983
14984         * gnulib-tool (func_import): Avoid constructing complicated sed
14985         expressions inside backquote.
14986         Report and solution by Mark D. Baushke <mdb@gnu.org>.
14987
14988 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
14989
14990         These changes imported from libc.
14991         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
14992         test and two separate function calls.
14993         * lib/strndup.c (__strndup): Add libc_hidden_def.
14994
14995 2006-01-23  Simon Josefsson  <jas@extundo.com>
14996
14997         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
14998         Remove the test_*_SOURCES variable: automake infers it by default.
14999         * modules/tls-tests: Likewise.
15000
15001 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15002
15003         Work around porting bugs reported by Dieter in
15004         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
15005         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
15006         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
15007         Include "getopt.h" first, to check interface.
15008         (getenv): Declare only if defined HAVE_DECL_GETENV &&
15009         !HAVE_DECL_GETENV.
15010         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
15011         (__strndup): Revert to K&R-style function dfns, the glibc style.
15012         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
15013         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
15014         Include strnlen.h first, to get prototype properly.
15015         (strnlen): Renamed from __strnlen.
15016         Remove weak alias.
15017
15018 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15019
15020         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
15021
15022 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15023
15024         * config/srclist.txt: Adjust to reflect glibc reorganization.
15025         This affects only comments.
15026
15027 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15028
15029          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
15030          Reported by Bruce Korb <bkorb@gnu.org>.
15031
15032 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
15033
15034         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
15035         to pacify gcc -Wswitch-default.
15036
15037 2006-01-22  Bruno Haible  <bruno@clisp.org>
15038
15039         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
15040         temporary buffer for sprintf, take into account the precision also
15041         for 'd', 'i', 'u', 'o', 'x', 'X'.
15042
15043 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15044
15045         * modules/argp-tests: New module
15046         * tests/test-argp.c: New file
15047         * tests/test-argp-2.sh: New file
15048
15049 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15050
15051         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
15052         (__argp_base_name): Removed
15053         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
15054         typo.
15055         (__argp_base_name): Provide macro definition or extern declaration
15056         depending on the configuration
15057
15058 2006-01-20  Simon Josefsson  <jas@extundo.com>
15059
15060         * modules/inet_ntop (Depends-on): Depend on sys_socket.
15061
15062 2006-01-20  Simon Josefsson  <jas@extundo.com>
15063
15064         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
15065
15066 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
15067
15068         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
15069         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
15070         Suggested by Bruno Haible.
15071
15072 2006-01-20  Karl Berry  <karl@gnu.org>
15073
15074         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
15075         until changes propagate, I guess.
15076
15077 2006-01-19  Simon Josefsson  <jas@extundo.com>
15078
15079         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
15080
15081 2006-01-19  Simon Josefsson  <jas@extundo.com>
15082
15083         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
15084
15085 2006-01-19  Simon Josefsson  <jas@extundo.com>
15086
15087         * gnulib-tool: Set check_PROGRAMS.
15088
15089         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15090         modules/des-tests, modules/gc-arcfour-tests,
15091         modules/gc-arctwo-tests, modules/gc-des-tests,
15092         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15093         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15094         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15095         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15096         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15097         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
15098         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
15099         test_*_SOURCES.
15100
15101 2006-01-18  Simon Josefsson  <jas@extundo.com>
15102
15103         * modules/socklen (Depends-on): Depend on sys_socket.
15104
15105 2006-01-18  Simon Josefsson  <jas@extundo.com>
15106
15107         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15108         modules/des-tests, modules/gc-arcfour-tests,
15109         modules/gc-arctwo-tests, modules/gc-des-tests,
15110         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15111         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15112         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15113         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15114         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15115         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
15116         $(EXEEXT) to automake TESTS variable, for mingw32.
15117
15118 2006-01-17  Simon Josefsson  <jas@extundo.com>
15119
15120         * modules/socklen (Include): Need sys/socket.h.
15121
15122 2006-01-17  Bruno Haible  <bruno@clisp.org>
15123
15124         * modules/ssize_t (Include): Add <sys/types.h>.
15125
15126 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
15127
15128         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
15129         it's not portable and it doesn't work with cross-compiles.
15130         Problem reported by Bruno Haible.  Fix missing-$ typo in
15131         'test "gl_cv_ignore_unused_libraries" ...' that prevented
15132         -zignore from being used with Sun's C compiler.
15133
15134 2006-01-12  Simon Josefsson  <jas@extundo.com>
15135
15136         * lib/base64.c: Fix warning, reported by Bruno Haible
15137         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
15138
15139 2006-01-12  Bruno Haible  <bruno@clisp.org>
15140
15141         * modules/ldd: New file.
15142         * build-aux/ldd.sh.in: New file.
15143         * MODULES.html.sh (Support for building libraries and executables): Add
15144         ldd.
15145
15146 2006-01-12  Bruno Haible  <bruno@clisp.org>
15147
15148         * m4/ldd.m4: New file.
15149
15150 2006-01-12  Bruno Haible  <bruno@clisp.org>
15151
15152         * gnulib-tool (func_import, func_create_testdir): Don't go into an
15153         endless loop while replacing $auxdir with build-aux.
15154
15155 2006-01-11  Simon Josefsson  <jas@extundo.com>
15156
15157         * lib/stdint_.h (SIZE_MAX): Add missing (.
15158
15159 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
15160
15161         Sync from coreutils.
15162         * lib/md5.c: Fix commentary typos.
15163         (alignof, UNALIGNED_P): No need for a GCC-specific version.
15164         * lib/md5.h (__attribute__): Remove; unused.
15165         * lib/sha1.c: Fix commentary to match md5 better.
15166         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
15167         so that we don't need to worry about alignment.  All uses changed.
15168         This merges the 2005-10-28 md5 change into sha1.
15169
15170 2006-01-11  Jim Meyering  <jim@meyering.net>
15171
15172         Sync from coreutils.
15173         * lib/md5.c (OP): Fix spacing.
15174
15175 2006-01-11  Bruno Haible  <bruno@clisp.org>
15176
15177         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15178         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
15179         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
15180
15181 2006-01-11  Bruno Haible  <bruno@clisp.org>
15182
15183         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15184         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
15185         the "early" section as well.
15186
15187 2006-01-11  Bruno Haible  <bruno@clisp.org>
15188
15189         Avoid "ar: no archive members specified" error on MacOS X.
15190         * gnulib-tool (func_modules_add_dummy): New function.
15191         (func_import, func_create_testdir): Invoke it.
15192
15193 2006-01-11  Bruno Haible  <bruno@clisp.org>
15194
15195         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
15196         with $auxdir in AC_CONFIG_FILES statements.
15197
15198 2006-01-11  Bruno Haible  <bruno@clisp.org>
15199
15200         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
15201         Initialize also noinst_HEADERS to empty.
15202
15203 2006-01-11  Bruno Haible  <bruno@clisp.org>
15204
15205         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
15206         variables.
15207         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
15208         autoreconf.
15209
15210 2006-01-11  Bruno Haible  <bruno@clisp.org>
15211
15212         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
15213         overridable by the user.
15214         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15215
15216 2006-01-10  Simon Josefsson  <jas@extundo.com>
15217
15218         * modules/sys_socket: New file.
15219
15220 2006-01-10  Simon Josefsson  <jas@extundo.com>
15221
15222         * m4/sys_socket_h.m4: New file.
15223
15224 2006-01-10  Simon Josefsson  <jas@extundo.com>
15225
15226         * lib/socket_.h: New file.
15227
15228 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15229
15230         * modules/readutmp (Maintainer): Add myself.
15231
15232 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15233
15234         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
15235         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
15236         People who are still concerned with buggy memcmp implementations
15237         can invoke gl_FUNC_MEMCMP themselves.
15238
15239 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15240
15241         * lib/regex_internal.h (BITSET_WORD_BITS):
15242         Work around a bug in 64-bit PGC (before version 6.1-2), where the
15243         preprocessor mishandles large unsigned values as if they were signed.
15244         Problem reported by Claudio Fontana in
15245         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
15246
15247 2006-01-10  Jim Meyering  <jim@meyering.net>
15248
15249         Avoid the double-free (first in fts_read, second in fts_close) that
15250         would occur when an `active' directory is made inaccessible (e.g.,
15251         via chmod a-x) during a traversal.
15252         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15253         before returning.  Reproduce this failure by
15254         mkdir -p a/b; cd a; chmod a-x . b
15255         Reported by Stavros Passas.
15256
15257         Sync from coreutils.
15258         * lib/sha1.c: Tweak grammar in a comment.
15259
15260 2006-01-10  Jim Meyering  <jim@meyering.net>
15261
15262         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
15263         Patch by Joerg Sonnenberger.
15264
15265 2006-01-10  Bruno Haible  <bruno@clisp.org>
15266
15267         * modules/readutmp: Depend on module free.
15268         * modules/strtok_r: Depend on module restrict.
15269
15270 2006-01-10  Bruno Haible  <bruno@clisp.org>
15271
15272         * modules/gettext (configure.ac): Add an invocation of
15273         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
15274
15275 2006-01-10  Bruno Haible  <bruno@clisp.org>
15276
15277         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
15278         Reported by Werner Lemberg <wl@gnu.org>.
15279
15280 2006-01-10  Bruno Haible  <bruno@clisp.org>
15281
15282         * lib/localcharset.c: Update from GNU gettext.
15283
15284 2006-01-10  Bruno Haible  <bruno@clisp.org>
15285
15286         * lib/argp.h (__const): Remove macro. Use const instead.
15287         * lib/argp-fmtstream.h (__const): Likewise.
15288         * lib/glob_.h (__const): Remove macro.
15289         * lib/glob-libc.h: Use const instead of __const.
15290
15291 2006-01-10  Bruno Haible  <bruno@clisp.org>
15292
15293         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
15294         variable.
15295         Needed to avoid an automake error regarding the 'gettext' module.
15296
15297 2006-01-09  Simon Josefsson  <jas@extundo.com>
15298
15299         * modules/inet_ntop (Depends-on): Add restrict.
15300
15301 2006-01-09  Simon Josefsson  <jas@extundo.com>
15302
15303         * modules/gc-rijndael-tests (License): Put under LGPL.
15304
15305         * modules/gc-des-tests (License): Likewise.
15306
15307         * modules/gc-arcfour-tests (License): Likewise.
15308
15309         * modules/gc-arctwo-tests (License): Likewise.
15310
15311         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
15312
15313         * modules/gc-hmac-sha1-tests (Files): Likewise.
15314
15315         * modules/gc-hmac-md5-tests (License): Likewise.
15316
15317         * modules/gc-sha1-tests (License): Likewise.
15318
15319         * modules/gc-md5-tests (License): Likewise.
15320
15321         * modules/gc-md4-tests (License): Likewise.
15322
15323         * modules/gc-md2-tests (License): Likewise.
15324
15325         * modules/gc-tests (License): Likewise.
15326
15327         * modules/des-tests (License): Likewise.
15328
15329         * modules/md4-tests (License): Likewise.
15330
15331         * modules/md2-tests (License): Likewise.
15332
15333 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15334
15335         Sync from coreutils:
15336
15337         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
15338         * modules/lib-ignore: New file.
15339         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
15340         chdir-safer.m4, lchmod.m4.
15341         * modules/openat: Add mkdirat.c, openat-priv.h.
15342
15343 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15344
15345         Sync from coreutils.
15346         * m4/lib-ignore.m4: New file.
15347         * m4/lchmod.m4: New file.
15348
15349 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15350
15351         Sync from coreutils.
15352         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
15353         for write access: POSIX says that must fail.
15354         * lib/fts.c (diropen): Likewise.
15355         * lib/save-cwd.c (save_cwd): Likewise.
15356         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
15357         well, for minor improvements on hosts that lack O_DIRECTORY.
15358         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
15359         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
15360         Fall back on chown if open failed with EACCES.
15361
15362         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
15363         Report an error at compile-time if only a 1-second nominal clock
15364         resolution is found.
15365
15366         * lib/lchmod.h: New file.
15367         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
15368         (make_dir_parents): Use lchown rather than chown, and
15369         lchmod rather than chmod.
15370
15371         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
15372         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
15373         "proc" reported by n0dalus.
15374
15375         * lib/mountlist.c: Include <limits.h>.
15376         (dev_from_mount_options)
15377         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
15378         New function.  It no longer assumes "dev=" has the System V meaning
15379         on Linux (since it doesn't).  It also parses "dev=" more carefully.
15380         (read_file_system_list)
15381         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
15382         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
15383         dev= in that case.
15384
15385         * lib/posixtm.h (PDS_PRE_2000): New macro.
15386         * lib/posixtm.c (year): Arg is now syntax_bits rather than
15387         allow_century.  All usages changed.  Reject dates outside the range
15388         1969-1999 if PDS_PRE_2000 is used.
15389
15390 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15391
15392         Sync from coreutils.
15393         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
15394         (Time of day items): Mention the possibility of leap seconds.
15395         Problem reported by Dr. David Alan Gilbert.
15396
15397 2006-01-09  Jim Meyering  <jim@meyering.net>
15398
15399         Sync from coreutils.
15400
15401         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
15402
15403         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
15404
15405         * lib/modechange.c (mode_compile): Reject an invalid mode string
15406         that starts with an octal digit.  From Andreas Gruenbacher.
15407
15408         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
15409         and dup to open_safer and dup_safer, respectively.
15410         (openat_permissive): Fix typo in comment.
15411
15412         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
15413         "gettext.h"; either no longer needed or are guaranteed by openat.h.
15414         (_): Remove; no longer needed.
15415         (openat): Renamed from rpl_openat; no need for rpl_openat
15416         since openat.h renames openat for us.
15417         Replace most of the body with a call to openat_permissive,
15418         to avoid duplicate code.
15419         Port to (probably hypothetical) environments were mode_t is
15420         wider than int.
15421         (openat_permissive): Require mode arg, so that we can check
15422         types better.  Put it just after flags.  Change cwd failure
15423         indicator from pointer-to-bool to pointer-to-errno-value.
15424         All callers changed.
15425         Invoke openat_save_fail and/or openat_restore_fail if
15426         cwd_errno is null, so that openat can call us.
15427         (openat_permissive, fdopendir, fstatat, unlinkat):
15428         Simplify errno handling to avoid some duplicate code,
15429         as it's OK to set errno on success.
15430         * lib/openat.h: Revamp code so that function macros depend on
15431         __OPENAT_PREFIX only, not also on AT_FDCWD.
15432         (openat_ro): Remove.  Caller changed to use openat_permissive.
15433         (openat_permissive): Now a macro, if not a function.
15434         (openat_restore_fail, openat_save_fail): Now always functions,
15435         since mkdirat needs them even if __OPENAT_PREFIX is defined.
15436
15437         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
15438         and openat.c.
15439         * lib/mkdirat.c: Include openat-priv.h.
15440         Remove definitions of macros defined therein.
15441         * lib/openat.c: Likewise.
15442
15443         * lib/mkdirat.c (mkdirat): New file and function.
15444         * lib/openat.h (mkdirat): Declare.
15445
15446         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
15447
15448         * lib/openat.h (openat_permissive): Declare.
15449         (openat_ro): Define.
15450
15451         * lib/openat.c (EXPECTED_ERRNO): New macro.
15452         (openat_permissive): New function -- used in remove.c rewrite.
15453         (all functions): Set errno just before returning, only if there
15454         was an actual failure.
15455         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
15456
15457         Emulate openat-family functions using Linux's procfs, if possible.
15458         Idea and some code based on Ulrich Drepper's glibc changes.
15459
15460         * lib/openat.c: (BUILD_PROC_NAME): New macro.
15461         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
15462         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
15463         before falling back on save_cwd and restore_cwd.
15464         (fdopendir, fstatat, unlinkat): Likewise.
15465
15466         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
15467         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
15468
15469         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
15470         as second argument to va_arg.  Otherwise, some versions of gcc
15471         warn that `if this code is reached, the program will abort'.
15472
15473 2006-01-09  Jim Meyering  <jim@meyering.net>
15474
15475         Sync from coreutils.
15476         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
15477         Require openat-priv.h.
15478
15479 2006-01-09  Bruno Haible  <bruno@clisp.org>
15480
15481         * modules/strnlen (Include): Use strnlen.h.
15482
15483 2006-01-09  Bruno Haible  <bruno@clisp.org>
15484
15485         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
15486
15487 2006-01-09  Bruno Haible  <bruno@clisp.org>
15488
15489         * lib/sysexit_.h (EX_OK): New macro.
15490         Suggested by Martin Lambers <marlam@marlam.de>.
15491
15492 2006-01-09  Bruno Haible  <bruno@clisp.org>
15493
15494         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
15495         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
15496
15497 2006-01-09  Bruno Haible  <bruno@clisp.org>
15498
15499         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
15500         numbers.
15501
15502 2006-01-09  Bruno Haible  <bruno@clisp.org>
15503
15504         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
15505         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
15506         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
15507         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
15508
15509 2006-01-09  Bruno Haible  <bruno@clisp.org>
15510
15511         * build-aux/javacomp.sh.in: New file, moved from lib/.
15512         * modules/javacomp-script (Files): Update.
15513         (configure.ac): Add AC_CONFIG_FILES invocation.
15514         (EXTRA_DIST): Remove variable.
15515
15516         * build-aux/javaexec.sh.in: New file, moved from lib/.
15517         * modules/javaexec (Files): Update.
15518         (configure.ac): Add AC_CONFIG_FILES invocation.
15519         (EXTRA_DIST): Remove javaexec.sh.in.
15520
15521         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
15522         * modules/csharpcomp-script (Files): Update.
15523         (configure.ac): Add AC_CONFIG_FILES invocation.
15524         (EXTRA_DIST): Remove variable.
15525
15526         * build-aux/csharpexec.sh.in: New file, moved from lib/.
15527         * modules/csharpexec (Files): Update.
15528         (configure.ac): Add AC_CONFIG_FILES invocation.
15529         (EXTRA_DIST): Remove csharpexec.sh.in.
15530
15531 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
15532
15533         Sync from coreutils.
15534
15535         Add POSIX ACL support
15536         * lib/acl.h (copy_acl, set_acl): Add declarations.
15537         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
15538         systems other than Linux.
15539         (chmod_or_fchmod): New function: use fchmod when possible,
15540         and chmod otherwise.
15541         (file_has_acl): Add a POSIX ACL implementation, with a
15542         Linux-specific subcase.
15543         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
15544         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
15545         acls are unsupported.
15546         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
15547         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
15548         are unsupported.
15549
15550 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
15551
15552         Sync from coreutils.
15553         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
15554
15555 2006-01-07  Bruno Haible  <bruno@clisp.org>
15556
15557         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
15558         gl_EARLY.
15559
15560 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
15561
15562         * lib/strftime.c (tzname): Don't declare if it is already #defined.
15563         Problem reported for Mingw by Mark Junker.
15564
15565 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
15566
15567         * README: Gnulib normally doesn't generate a tarball.
15568
15569 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
15570
15571         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
15572         long int, not int, for nanosecond counts, so that people who are
15573         used to POSIX struct timespec won't be surprised.  Reported by Jim
15574         Meyering.
15575
15576 2005-12-28  Bruno Haible  <bruno@clisp.org>
15577
15578         * build-aux/config.rpath: Update from GNU gettext.
15579
15580 2005-12-16  Jim Meyering  <jim@meyering.net>
15581
15582         * modules/fprintftime: New module.
15583         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
15584
15585 2005-12-16  Jim Meyering  <jim@meyering.net>
15586
15587         * m4/fprintftime.m4: New file.
15588
15589 2005-12-16  Jim Meyering  <jim@meyering.net>
15590
15591         * lib/fprintftime.c, lib/fprintftime.h: New files.
15592
15593 2005-12-15  Simon Josefsson  <jas@extundo.com>
15594
15595         * modules/socklen (configure.ac): Fix M4 macro name, to align with
15596         new m4/socklen.m4.
15597
15598 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
15599
15600         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
15601         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
15602
15603 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
15604
15605         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
15606         * lib/argp-help.c (fill_in_uparams): Check if the constructed
15607         struct uparams is valid. Fall back to the default values if it is
15608         not.
15609
15610 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15611
15612         * modules/argp (Files): Add argp-pin.c
15613         (Depends-on): dirname
15614         (lib_SOURCES): Add argp-pin.c
15615
15616 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15617
15618         * m4/argp.m4:  Check if program_invocation_name and
15619         program_invocation_short_name are declared and define appropriate
15620         macros if they are not.
15621
15622 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15623
15624         * lib/argp-help.c (__argp_base_name): New function
15625         (__argp_short_program_name): Rewrite using __argp_base_name
15626         * lib/argp-namefrob.h: Define program_invocation_name and
15627         program_invocation_short_name if requested
15628         (__argp_base_name): Add prototype
15629         * lib/argp-parse.c (argp_def): Use gettext wrappers
15630         (argp_default_parser): Use __argp_base_name
15631         * lib/argp-pin.c: New file. Defines program_invocation_name and
15632         program_invocation_short_name on systems that lack them.
15633
15634 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
15635
15636         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
15637         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
15638         porting problem reported by Georg Schwarz in
15639         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
15640
15641 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
15642
15643         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
15644         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
15645         porting problem reported by Georg Schwarz in
15646         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
15647
15648 2005-12-05  Bruno Haible  <bruno@clisp.org>
15649
15650         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
15651         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
15652         Reported by Mark Junker <mjscod@gmx.de>.
15653
15654 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
15655
15656         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
15657         Use implementation from Albert Chin, with some
15658         comments/corrections by Stepan Kasal and myself.
15659
15660 2005-12-02  Bruno Haible  <bruno@clisp.org>
15661
15662         * gnulib-tool (func_import): Accept GPLed build tool modules when
15663         --lgpl is given.
15664         * modules/csharpcomp-script: New file.
15665         * modules/csharpcomp: Depend on it.
15666         * modules/javacomp-script: New file.
15667         * modules/javacomp: Depend on it.
15668         Suggested by Simon Josefsson.
15669
15670 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
15671
15672         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
15673         statement, to work around an HP-UX 10.20 compiler bug reported by
15674         Peter O'Gorman.
15675
15676 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
15677
15678         * modules/savedir (Depends-on): Add openat.
15679
15680 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
15681
15682         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
15683         (uintmax_t) [defined uintmax_t]: Do not declare.
15684         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
15685         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
15686         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
15687         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
15688         sake of portability to weird hosts that C allows (though we don't
15689         know of any practical examples).
15690
15691         * lib/savedir.h (fdsavedir): New decl.
15692         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
15693         contains most of the former guts of savedir.
15694         (savedir): Use savedirstream.
15695         Include "openat.h".
15696
15697 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
15698
15699         * modules/obstack (Files): Add m4/ulonglong.m4.
15700         Problem reported by Davide Angelocola.
15701
15702 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
15703
15704         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
15705         coreutils no longer futzes with rounding modes.
15706
15707 2005-11-14  Jim Meyering  <jim@meyering.net>
15708
15709         * lib/mkstemp-safer.c: Include <config.h>, required for possible
15710         replacement of mkstemp.
15711
15712 2005-11-10  Simon Josefsson  <jas@extundo.com>
15713
15714         * lib/readline.c: Remove EOL.
15715
15716 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15717
15718         * modules/gethrxtime (Depends-on): Add gettime.
15719
15720 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15721
15722         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
15723         or gettimeofday; no longer needed.
15724
15725 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
15726
15727         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
15728         time business.
15729         (gethrxtime) [! (HAVE_NANOUPTIME
15730         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
15731         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
15732         our own approximation.
15733
15734 2005-11-08  Eric Blake  <ebb9@byu.net>
15735
15736         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
15737
15738 2005-11-08  Eric Blake  <ebb9@byu.net>
15739
15740         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
15741
15742 2005-11-04  Bruno Haible  <bruno@clisp.org>
15743
15744         * gnulib-tool: Implement --update mode.
15745
15746 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
15747
15748         Fix porting problem reported by Theodoros V. Kalamatianos.
15749         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
15750         Don't assume that futimes failing means we must fail.
15751
15752 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
15753
15754         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
15755         variables to suggest the intended function of the PATH_MAX check.
15756
15757 2005-10-30  Kean Johnston  <jkj@sco.com>
15758
15759         Trivial changes to support SCO systems.
15760         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
15761         as PATH_MAX.
15762         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
15763         where __ptr is null when no I/O is pending.
15764
15765 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
15766
15767         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
15768         leave errno alone.  Problem reported by Dmitry V. Levin.
15769
15770 2005-10-28  Simon Josefsson  <jas@extundo.com>
15771
15772         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
15773         Test more.
15774
15775         * tests/test-gc-md2.c, tests/test-md2.c: New files.
15776
15777         * modules/md2, modules/md2-tests: New files.
15778
15779 2005-10-28  Simon Josefsson  <jas@extundo.com>
15780
15781         * m4/inet_ntop.m4: More tests.
15782
15783         * m4/gc-md2.m4, md2.m4: New file.
15784
15785 2005-10-28  Simon Josefsson  <jas@extundo.com>
15786
15787         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
15788         "restrict" keywords, as per POSIX.  Protect the function
15789         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
15790         Don't use K&R prototypes.  Check the sprintf return values.
15791         Re-define EAFNOSUPPORT if not present.  Indent.
15792
15793         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
15794         suggested by Bruno Haible <bruno@clisp.org>.
15795
15796         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
15797
15798         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
15799
15800         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
15801         libgcrypt).
15802
15803         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
15804
15805         * lib/md2.h, lib/md2.c: New files.
15806
15807 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
15808
15809         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
15810         errno alone.  Problem reported by Frederic Jolliton.
15811
15812 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
15813
15814         * modules/verify (License): Change from GPL to LGPL.  This is a
15815         tiny module and there are apparently near-equivalents that are
15816         under the BSD license.
15817
15818 2005-10-24  Simon Josefsson  <jas@extundo.com>
15819
15820         * modules/sha1: Relicense to LGPL.
15821
15822 2005-10-24  Simon Josefsson  <jas@extundo.com>
15823
15824         * lib/md4.h: Shrink buffer size, now that we changed the type.
15825
15826 2005-10-23  Simon Josefsson  <jas@extundo.com>
15827
15828         * gnulib-tool (func_import): Fix --tests-base.
15829
15830 2005-10-22  Simon Josefsson  <jas@extundo.com>
15831
15832         * modules/arcfour (Depends-on): Need stdint.
15833
15834 2005-10-22  Simon Josefsson  <jas@extundo.com>
15835
15836         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
15837         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
15838
15839 2005-10-22  Simon Josefsson  <jas@extundo.com>
15840
15841         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
15842         suggested by Bruno Haible <bruno@clisp.org>.
15843
15844 2005-10-22  Simon Josefsson  <jas@extundo.com>
15845
15846         * lib/crc.h: Include stddef.h, for size_t.
15847
15848 2005-10-22  Simon Josefsson  <jas@extundo.com>
15849
15850         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
15851         arcfour_context struct (simplify test vector testing in GNU
15852         Shishi).
15853
15854 2005-10-21  Simon Josefsson  <jas@extundo.com>
15855
15856         * modules/des, modules/des-tests: New files.
15857
15858         * modules/gc-des, modules/gc-des-tests: New files.
15859
15860         * tests/test-des.c, tests/test-gc-des.c: New file.
15861
15862 2005-10-21  Simon Josefsson  <jas@extundo.com>
15863
15864         * modules/arctwo, modules/arctwo-tests: New files.
15865
15866         * tests/test-arctwo.c: New file.
15867
15868         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
15869
15870         * tests/test-gc-arctwo.c: New file.
15871
15872 2005-10-21  Simon Josefsson  <jas@extundo.com>
15873
15874         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
15875         Bruno Haible <bruno@clisp.org>.
15876
15877         * m4/gc-des.m4: New file.
15878
15879 2005-10-21  Simon Josefsson  <jas@extundo.com>
15880
15881         * m4/arctwo.m4: New file.
15882
15883         * m4/gc-arctwo.m4: New file.
15884
15885 2005-10-21  Simon Josefsson  <jas@extundo.com>
15886
15887         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
15888         block.
15889
15890 2005-10-21  Simon Josefsson  <jas@extundo.com>
15891
15892         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
15893         <bruno@clisp.org>.
15894
15895         * lib/hmac-sha1.c (hmac_sha1): Likewise.
15896
15897         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
15898         Bruno Haible <bruno@clisp.org>.
15899
15900         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
15901         <bruno@clisp.org>.
15902
15903 2005-10-21  Simon Josefsson  <jas@extundo.com>
15904
15905         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
15906
15907 2005-10-21  Simon Josefsson  <jas@extundo.com>
15908
15909         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
15910
15911 2005-10-21  Simon Josefsson  <jas@extundo.com>
15912
15913         * lib/des.h, lib/des.c: New files.
15914
15915         * lib/gc-gnulib.c: Support DES.c
15916
15917 2005-10-21  Simon Josefsson  <jas@extundo.com>
15918
15919         * lib/arctwo.h, lib/arctwo.c: New files.
15920
15921         * lib/gc-gnulib.c: Support ARCTWO.
15922
15923 2005-10-21  Simon Josefsson  <jas@extundo.com>
15924
15925         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
15926         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15927
15928 2005-10-21  Simon Josefsson  <jas@extundo.com>
15929
15930         * gnulib-tool (func_import, func_create_testdir): Define automake
15931         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
15932         Makefile.am snippet),
15933         suggested by Bruno Haible <bruno@clisp.org>.
15934
15935         * modules/gc (Makefile.am): Use it.
15936
15937 2005-10-21  Bruno Haible  <bruno@clisp.org>
15938
15939         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
15940         patch.
15941
15942 2005-10-19  Simon Josefsson  <jas@extundo.com>
15943
15944         * tests/test-gc-rijndael.c: New file.
15945
15946         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
15947
15948 2005-10-19  Simon Josefsson  <jas@extundo.com>
15949
15950         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
15951         interface too.
15952
15953 2005-10-19  Simon Josefsson  <jas@extundo.com>
15954
15955         * tests/test-gc-arcfour.c: New file.
15956
15957         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
15958
15959 2005-10-19  Simon Josefsson  <jas@extundo.com>
15960
15961         * modules/gc-md4, modules/gc-md4-tests: New file.
15962
15963         * tests/test-gc-md4.c: New file.
15964
15965 2005-10-19  Simon Josefsson  <jas@extundo.com>
15966
15967         * m4/gc-md4.m4: New file.
15968
15969 2005-10-19  Simon Josefsson  <jas@extundo.com>
15970
15971         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
15972         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
15973         <kasal@ucw.cz>.
15974
15975 2005-10-19  Simon Josefsson  <jas@extundo.com>
15976
15977         * m4/gc-arcfour.m4: New file.
15978
15979         * m4/gc-rijndael.m4: New file.
15980
15981 2005-10-19  Simon Josefsson  <jas@extundo.com>
15982
15983         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
15984
15985 2005-10-19  Simon Josefsson  <jas@extundo.com>
15986
15987         * lib/gc-gnulib.c: Support ARCFOUR.
15988
15989 2005-10-19  Simon Josefsson  <jas@extundo.com>
15990
15991         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
15992         support.
15993
15994         * lib/gc.h: Add ECB enum type.
15995
15996         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
15997
15998 2005-10-18  Simon Josefsson  <jas@extundo.com>
15999
16000         * tests/test-md5.c: New file.
16001
16002         * modules/md5-tests: New file.
16003
16004 2005-10-18  Simon Josefsson  <jas@extundo.com>
16005
16006         * tests/test-md4.c: New file.
16007
16008         * modules/md4, modules/md4-tests: New files.
16009
16010 2005-10-18  Simon Josefsson  <jas@extundo.com>
16011
16012         * m4/md4.m4: New file.
16013
16014 2005-10-18  Simon Josefsson  <jas@extundo.com>
16015
16016         * lib/md4.h, lib/md4.c: New files, based on md5.?.
16017
16018 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
16019
16020         * gnulib-tool (func_create_testdir): Omit the second check whether
16021         BUILT_SOURCES in nonempty.
16022
16023 2005-10-17  Simon Josefsson  <jas@extundo.com>
16024
16025         * tests/test-rijndael.c: New file.
16026
16027 2005-10-17  Simon Josefsson  <jas@extundo.com>
16028
16029         * modules/sha1: Depend on stdint instead of md5.
16030
16031         * modules/md5: Depend on stdint, remove uint32_t.
16032
16033 2005-10-17  Simon Josefsson  <jas@extundo.com>
16034
16035         * modules/gc-sha1-tests: New file.
16036
16037         * tests/test-gc-sha1.c: New file.
16038
16039 2005-10-17  Simon Josefsson  <jas@extundo.com>
16040
16041         * m4/md5.m4: Remove call to uint32_t.m4.
16042
16043 2005-10-17  Simon Josefsson  <jas@extundo.com>
16044
16045         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
16046
16047         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
16048         md5.h.
16049
16050         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
16051
16052         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
16053
16054 2005-10-17  Simon Josefsson  <jas@extundo.com>
16055
16056         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
16057
16058 2005-10-17  Simon Josefsson  <jas@extundo.com>
16059
16060         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
16061
16062 2005-10-17  Simon Josefsson  <jas@extundo.com>
16063
16064         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
16065
16066         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
16067
16068 2005-10-17  Bruno Haible  <bruno@clisp.org>
16069
16070         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
16071         that it can also be used in a test.
16072
16073 2005-10-16  Bruno Haible  <bruno@clisp.org>
16074
16075         * gnulib-tool (func_emit_tests_Makefile_am): Also define
16076         TESTS_ENVIRONMENT, so that individual tests can augment it.
16077
16078         * gnulib-tool (func_create_testdir): Use an intermediate target for
16079         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
16080         macros, like $(ALLOCA_H), which cannot be passed through the command
16081         line.
16082
16083 2005-10-15  Simon Josefsson  <jas@extundo.com>
16084
16085         * modules/rijndael-tests: New file.
16086
16087         * modules/rijndael: New file.
16088
16089 2005-10-15  Simon Josefsson  <jas@extundo.com>
16090
16091         * m4/rijndael.m4: New file.
16092
16093 2005-10-15  Simon Josefsson  <jas@extundo.com>
16094
16095         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
16096
16097         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
16098
16099 2005-10-14  Simon Josefsson  <jas@extundo.com>
16100
16101         * tests/test-arcfour.c: New file.
16102
16103         * modules/arcfour, modules/arcfour-tests: New files.
16104
16105 2005-10-14  Simon Josefsson  <jas@extundo.com>
16106
16107         * m4/arcfour.m4: New file.
16108
16109 2005-10-14  Simon Josefsson  <jas@extundo.com>
16110
16111         * lib/arcfour.h, lib/arcfour.c: New files.
16112
16113 2005-10-14  Roland McGrath  <roland@redhat.com>
16114
16115         Import from libc.  [BZ #1331]
16116         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
16117         macro argument.
16118         Reported by Matej Vela <vela@debian.org>.
16119
16120 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16121
16122         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
16123         include <wchar.h>; no longer needed.
16124
16125 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16126
16127         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
16128
16129 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
16130         and  Ulrich Drepper  <drepper@redhat.com>
16131
16132         Import from libc.
16133         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
16134         instead of inline stream orientation test and two separate
16135         function calls.  Pay no attention to USE_IN_LIBIO.
16136
16137 2005-10-13  Simon Josefsson  <jas@extundo.com>
16138
16139         * modules/gc-hmac-md5-tests: New file.
16140
16141         * tests/test-gc-hmac-sha1.c: New file.
16142
16143         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
16144
16145         * modules/gc-hmac-md5-tests: New file.
16146
16147         * tests/test-gc-md5.c: New file.
16148
16149         * modules/gc-md5-tests: New file.
16150
16151 2005-10-13  Simon Josefsson  <jas@extundo.com>
16152
16153         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
16154         Move memory allocation outside of loop.
16155
16156 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
16157
16158         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
16159         intermediate directory is in a read-only file system.  Problem
16160         reported by Eric Blake.
16161
16162 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
16163
16164         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
16165
16166 2005-10-12  Simon Josefsson  <jas@extundo.com>
16167
16168         * tests/test-hmac-sha1.c: New file.
16169
16170         * modules/hmac-sha1-tests: New file.
16171
16172         * modules/hmac-sha1: New file.
16173
16174 2005-10-12  Simon Josefsson  <jas@extundo.com>
16175
16176         * modules/gc-sha1: New file.
16177
16178 2005-10-12  Simon Josefsson  <jas@extundo.com>
16179
16180         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
16181
16182         * tests/test-gc-pbkdf2-sha1.c: New file.
16183
16184 2005-10-12  Simon Josefsson  <jas@extundo.com>
16185
16186         * modules/gc-md5, modules/gc-hmac-md5: New files.
16187
16188         * modules/gc (Files): Remove md5, memxor and hmac files.
16189
16190 2005-10-12  Simon Josefsson  <jas@extundo.com>
16191
16192         * m4/gc-pbkdf2-sha1.m4: New file.
16193
16194         * m4/gc-hmac-sha1.m4: New file.
16195
16196         * m4/gc-sha1: New file.
16197
16198         * m4/hmac-sha1.m4: New file.
16199
16200 2005-10-12  Simon Josefsson  <jas@extundo.com>
16201
16202         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
16203
16204         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
16205
16206 2005-10-12  Simon Josefsson  <jas@extundo.com>
16207
16208         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
16209         suggested by Bruno Haible <bruno@clisp.org>.
16210
16211 2005-10-12  Simon Josefsson  <jas@extundo.com>
16212
16213         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
16214
16215 2005-10-12  Simon Josefsson  <jas@extundo.com>
16216
16217         * lib/gc-pbkdf2-sha1.c: New file.
16218
16219         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
16220
16221 2005-10-12  Simon Josefsson  <jas@extundo.com>
16222
16223         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
16224
16225         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
16226
16227 2005-10-12  Simon Josefsson  <jas@extundo.com>
16228
16229         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
16230         GC_USE_HMAC_MD5, respectively.
16231
16232         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
16233         (gc_md5): Fix typo.
16234
16235         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
16236
16237         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
16238
16239         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
16240
16241 2005-10-12  Bruno Haible  <bruno@clisp.org>
16242
16243         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
16244         Reported by Stepan Kasal <kasal@ucw.cz>.
16245
16246 2005-10-11  Simon Josefsson  <jas@extundo.com>
16247
16248         * tests/test-crc.c: New file.
16249
16250         * modules/crc, modules/crc-tests: New files.
16251
16252 2005-10-11  Simon Josefsson  <jas@extundo.com>
16253
16254         * m4/crc.m4: New file.
16255
16256 2005-10-11  Simon Josefsson  <jas@extundo.com>
16257
16258         * lib/gc.h: Add gc_hash and gc_hash_buffer.
16259
16260         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
16261
16262         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
16263
16264 2005-10-11  Simon Josefsson  <jas@extundo.com>
16265
16266         * lib/crc.h, lib/crc.c: New files.
16267
16268         * lib/gc.h (gc_hash_buffer): Add doc.
16269
16270 2005-10-11  Bruno Haible  <bruno@clisp.org>
16271
16272         * modules/c-strcasestr: New file.
16273         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
16274
16275 2005-10-11  Bruno Haible  <bruno@clisp.org>
16276
16277         * modules/c-strcase: New file.
16278         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
16279
16280 2005-10-11  Bruno Haible  <bruno@clisp.org>
16281
16282         * lib/strcasecmp.c: Include limits.h.
16283         (strcasecmp): Avoid integer overflow on exotic platforms.
16284         * lib/strncasecmp.c: Include limits.h.
16285         (strncasecmp): Avoid integer overflow on exotic platforms.
16286         Reported by Paul Eggert.
16287
16288 2005-10-11  Bruno Haible  <bruno@clisp.org>
16289
16290         * lib/c-strcasestr.h: New file, from GNU gettext.
16291         * lib/c-strcasestr.c: New file, from GNU gettext.
16292
16293 2005-10-11  Bruno Haible  <bruno@clisp.org>
16294
16295         * lib/c-strcase.h: New file, from GNU gettext.
16296         * lib/c-strcasecmp.c: New file, from GNU gettext.
16297         * lib/c-strncasecmp.c: New file, from GNU gettext.
16298
16299 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
16300
16301         * modules/mempcpy (License): GPL -> LGPL.
16302         * modules/strchrnul (License): Likewise.
16303         * modules/sysexits (License): Likewise.
16304
16305 2005-10-08  Simon Josefsson  <jas@extundo.com>
16306
16307         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
16308
16309 2005-10-07  Simon Josefsson  <jas@extundo.com>
16310
16311         * m4/memxor.m4: Remove gl_C_RESTRICT call.
16312
16313 2005-10-06  Simon Josefsson  <jas@extundo.com>
16314
16315         * tests/test-hmac-md5.c: New file.
16316
16317         * modules/hmac-md5-tests: New file.
16318
16319         * modules/hmac-md5: New file.
16320
16321 2005-10-06  Simon Josefsson  <jas@extundo.com>
16322
16323         * m4/hmac-md5.m4: New file.
16324
16325         * m4/memxor.m4: Require gl_C_RESTRICT.
16326
16327 2005-10-06  Simon Josefsson  <jas@extundo.com>
16328
16329         * lib/memxor.c (memxor): Avoid casts and warnings.
16330
16331 2005-10-06  Simon Josefsson  <jas@extundo.com>
16332
16333         * lib/hmac-md5.c: New file.
16334
16335         * lib/hmac.h: New file.
16336
16337 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
16338
16339         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
16340         promotes to int, not unsigned int, to catch the AIX 5.3
16341         compiler bug.
16342
16343 2005-10-05  Simon Josefsson  <jas@extundo.com>
16344
16345         * modules/memxor: New file.
16346
16347         * modules/iconv (Files): Move config.rpath to havelib, it is used
16348         there.
16349
16350         * modules/havelib (Files): Add config.rpath.
16351
16352 2005-10-05  Simon Josefsson  <jas@extundo.com>
16353
16354         * m4/memxor.m4: New file.
16355
16356 2005-10-05  Simon Josefsson  <jas@extundo.com>
16357
16358         * lib/memxor.c (memxor): Fix compiler error.
16359
16360         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
16361         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
16362
16363         * lib/memxor.h, lib/memxor.c: New files.
16364
16365         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
16366         we assume all systems have it, suggested by Jim Meyering
16367         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
16368         any systems lack sys/socket.h; mingw32 is known to lack it, but we
16369         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
16370         same reasons.
16371
16372 2005-10-05  Simon Josefsson  <jas@extundo.com>
16373
16374         * config/srclist.txt: Add glibc bug 1423 for md5.h.
16375
16376 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
16377
16378         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
16379         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
16380         needed, since the source code now assumes these .h files.
16381
16382 2005-10-05  Derek Price  <derek@ximbiot.com>
16383
16384         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
16385
16386 2005-10-05  Bruno Haible  <bruno@clisp.org>
16387
16388         * modules/stdint (License): Change to LGPL.
16389
16390 2005-10-04  Simon Josefsson  <jas@extundo.com>
16391
16392         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
16393         D. Baushke" <mdb@gnu.org>.
16394
16395 2005-10-04  Bruno Haible  <bruno@clisp.org>
16396
16397         * lib/verify.h (verify_true): Provide alternative definition for C++.
16398
16399 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
16400
16401         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
16402         (SSIZE_MAX): New macro, if not already defined.
16403         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
16404         than 2 GiB.
16405
16406 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16407
16408         Sync from coreutils.
16409         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
16410         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
16411         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
16412         ULLONG_MAX doesn't work with 2.7.2.1.
16413
16414 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16415
16416         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
16417         From Ben Pfaff.
16418
16419         * modules/exclude (Depends-on): Depend on verify.
16420         * modules/strtoimax (Depends-on): Likewise.
16421         * modules/utimecmp (Depends-on): Likewise.
16422
16423 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16424
16425         * lib/exclude.c: Include verify.h.
16426         (verify): Remove.  All callers changed to use verify.h's version.
16427         * lib/strtoimax.c: Likewise.
16428         * lib/utimecmp.c: Likewis.e
16429
16430         Sync from coreutils.
16431         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
16432         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
16433         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
16434         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
16435         bother returning ENOSYS if settimeofday or stime fails; just let
16436         them return whatever errno they want to return.
16437         * lib/utimens.c: Include unistd.h, for dup2.
16438         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
16439         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
16440
16441 2005-10-02  Jim Meyering  <jim@meyering.net>
16442
16443         Sync from coreutils.
16444         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
16445         from glibc-2.2.5 that fails for read-only files.
16446
16447 2005-10-02  Jim Meyering  <jim@meyering.net>
16448
16449         Sync from coreutils.
16450         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
16451         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
16452         `#if HAVE_CONFIG_H'.
16453         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
16454         Remove AT_FDCWD test.
16455         Do not consume the fd unless successful.
16456         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
16457         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
16458         block, so that we don't even try to compile it if settimeofday is
16459         available.  This works around a compilation failure on OSF1 V5.1,
16460         due to stime requiring a `long int*' while tv_sec is `int'.
16461
16462 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
16463
16464         Sync from coreutils.
16465         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
16466         against `yes', rather than just testing for nonempty.
16467
16468 2005-10-01  Simon Josefsson  <jas@extundo.com>
16469
16470         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
16471         and Darwin.
16472
16473         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
16474         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
16475         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
16476         freeaddrinfo and gai_strerror are declared by the POSIX headers.
16477         Check if struct addrinfo is declared.
16478
16479 2005-10-01  Simon Josefsson  <jas@extundo.com>
16480
16481         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
16482         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
16483         AI_* and EAI_* definitions.  Protect function declarations.
16484
16485 2005-10-01  Jim Meyering  <jim@meyering.net>
16486
16487         Sync from coreutils.
16488
16489         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
16490         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
16491         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
16492         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16493         in the inet and nsl libraries.  Required on Solaris 5.7.
16494
16495 2005-10-01  Jim Meyering  <jim@meyering.net>
16496
16497         Sync from coreutils.
16498         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16499         in the inet and nsl libraries.  Required on Solaris 5.7.
16500
16501 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
16502
16503         * lib/getdelim.c (getdelim): Remove unused variables.
16504
16505 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
16506
16507         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
16508         so that the code works even with ancient cpp.  Portability problem
16509         with GCC 2.7.2.1 reported by Thomas M.Ott.
16510
16511 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
16512
16513         * modules/regex (Depends-on): Add strcase.
16514
16515         * modules/gethostname (Licence): Change from GPL to LGPL, since
16516         gethostname.c is a trivial implementation of a standard library
16517         function.
16518         * modules/poll (License): Change from GPL to LGPL, since it's
16519         derived from LGPL code.
16520
16521 2005-09-27  Jim Meyering  <jim@meyering.net>
16522
16523         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
16524         HAVE_CONFIG_H.
16525
16526         * lib/intprops.h (signed_type_or_expr__): Define.
16527         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
16528         for unsigned types.
16529
16530 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
16531
16532         * lib/verify.h (verify_expr): Remove, replacing with:
16533         (verify_true): New macro that returns true instead of void.
16534         (verify_type__): Remove.
16535         (verify): Use verify_true rather than verify_type__.
16536
16537 2005-09-26  Bruno Haible  <bruno@clisp.org>
16538
16539         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
16540         is necessary.
16541         (lib_SOURCES): Remove mbchar.c.
16542         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
16543         (Files): Add m4/mbrtowc.m4.
16544         * modules/mbiter: Likewise.
16545         * modules/mbuiter: Likewise.
16546
16547 2005-09-26  Bruno Haible  <bruno@clisp.org>
16548
16549         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
16550         compile mbchar.c if they are not both present.
16551         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
16552         * m4/mbiter.m4 (gl_MBITER): Likewise.
16553         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
16554         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
16555         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
16556
16557 2005-09-25  Jim Meyering  <jim@meyering.net>
16558
16559         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
16560         also uses socklen_t.
16561
16562 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
16563
16564         * lib/utimens.c (ENOSYS): Define if not already defined.
16565         (futimens): Support having a null PATH if the file descriptor
16566         is nonnegative.
16567
16568         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
16569         Remove.
16570         (__attribute): Define to empty unless GCC 3.1 or later.
16571         This works around a core dump on OpenBSD 3.4, which has GCC
16572         2.95.3, which dumps core when given __attribute__(()).  It also
16573         simplifies other tests, since we really don't want to bother with
16574         worrying about which ancient version of GCC supported what.
16575         Original problem reported by Yoann Vandoorselaere, with part of
16576         the fix suggested by Derek Price.
16577
16578 2005-09-24  Jim Meyering  <jim@meyering.net>
16579
16580         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
16581         so we can once again use a positive bitfield width of 1 -- now we
16582         don't have to explain why we were using a bitfield width of 2.
16583
16584 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
16585
16586         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
16587         and similarly for the other external symbols.  Problem reported
16588         by James Gallager.
16589
16590         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
16591         bug reported by Jim Meyering.
16592
16593         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
16594         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
16595         not needed, since socklen is a prerequisite module.
16596
16597 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
16598
16599         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
16600         Problem reported by Eric Blake.
16601         (getaddrinfo): Initialize se so that it's not garbage.
16602         Redo internal storage allocation so that it doesn't make unportable
16603         assumptions about alignment.
16604         Fix a memory leak.
16605
16606         * lib/utimens.c (futimens): Use futimesat if available.
16607         Prefer it to futimes since it doesn't have the futimes bug.
16608
16609         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
16610         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
16611         Instead, declare a function that returns a pointer to an array,
16612         and use verify_type__ to declare the size of the array.
16613         Problem and germ of a solution reported by Bruno Haible.
16614         (verify_type__): Use 2, not 1, for bitfield size, to avoid
16615         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
16616
16617 2005-09-23  Jim Meyering  <jim@meyering.net>
16618
16619         Sync from coreutils.
16620         Correct build failure (socklen_t not defined) on at least
16621         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
16622         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
16623
16624 2005-09-23  Jim Meyering  <jim@meyering.net>
16625
16626         * modules/getaddrinfo (Depends-on): Add socklen.
16627
16628 2005-09-23  Bruno Haible  <bruno@clisp.org>
16629
16630         * tests/test-verify.c: New file.
16631
16632 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16633
16634         Sync from coreutils.
16635
16636         * modules/argmatch (Depends-on): Add verify.
16637         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
16638         unistd-safer.
16639         * modules/save-cwd (Depends-on): Likewise.
16640
16641         * modules/openat (Files): Add lib/openat-die.c.
16642         (Depends-on): Remove error, exitfail.
16643         Add dirname.
16644
16645         * modules/verify: New file.
16646         * MODULES.html.sh (Diagnostics <assert.h>): New section,
16647         with "verify" module.
16648
16649 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16650
16651         Sync from coreutils.
16652
16653         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
16654         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
16655         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
16656         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
16657         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
16658         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
16659         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
16660         Don't bother checking for string.h, stdlib.h, unistd.h.
16661         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
16662         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
16663         module's job.
16664         * m4/jm-macros.m4 (gl_MACROS): Likewise.
16665         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
16666
16667         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
16668         (gl_GETDATE): Use it.
16669
16670         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
16671
16672 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16673
16674         Sync from coreutils.
16675
16676         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
16677         stat-time.h.
16678         * lib/argmatch.h: Include verify.h
16679         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
16680         (ARGMATCH_ASSERT): Remove; unused.
16681         * lib/canonicalize.c: Assume STDC_HEADERS.
16682         * lib/exclude.c: Include "strcase.h".
16683         * lib/regex_internal.h [!defined _LIBC]: Likewise.
16684         * lib/getusershell.c: Include stdio--.h rather than stdio.h
16685         and stdio-safer.h.
16686         (getusershell): Call fopen, not fopen_safer.
16687         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
16688         Do not include unistd-safer.h.
16689         (save_cwd): Don't call fd_safer; no longer needed
16690         now that we include fcntl--.h.
16691
16692         * lib/getdate.y (relative_time): New type.
16693         (RELATIVE_TIME_0): New constant.
16694         (parser_control): Use relative_time instead of doing it ourselves.
16695         (%union): Add new relative_time rel member.
16696         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
16697         Now typeless.
16698         (relunit, relunit_snumber): Now of type rel.
16699         (zone, rel, relunit, get_date): Adjust to above changes.
16700
16701         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
16702         Do not include unistd-safer.h.
16703         (getloadavg): Don't call fd_safer; no longer needed
16704         now that we include fcntl--.h.
16705
16706         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
16707         (make_dir_parents): Treat ENOSYS like EEXIST.
16708
16709         Improve quality of diagnostics on restore_cwd failure.
16710         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
16711         (make_dir_parents): Last arg is now int * (for errno), not bool *.
16712         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
16713         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
16714         each time through the loop.  Do not diagnose restore_cwd failure;
16715         that is the caller's job (and perhaps the caller does not care).
16716
16717         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
16718         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
16719         If the file already exists but is not a directory, don't bother
16720         to try to make its parents.
16721         Close potential file descriptor leak if we can't chdir("/") (!).
16722         Don't always return true if chdir($PWD) fails; return true only
16723         if the requested action was done successfully (except for the
16724         chdir($PWD)).
16725         Don't log final directory unless we actually made it.
16726         Refactor to avoid duplicate code to fix up permissions.
16727         Don't attempt to fix up parent permissions if chdir($PWD) fails.
16728
16729         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
16730         to make it a bit faster and (I hope) clearer.
16731         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
16732         Fix bug in formats like %2N.
16733
16734         * lib/verify.h: New file.
16735
16736 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
16737
16738         Sync from coreutils.
16739         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
16740
16741 2005-09-22  Jim Meyering  <jim@meyering.net>
16742
16743         Sync from coreutils.
16744
16745         * m4/lstat.m4 (gl_FUNC_LSTAT):
16746         Use AC_LIBSOURCES to require lstat.c and lstat.h.
16747         Remove obsolete comment.
16748         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
16749         * m4/xstrtod.m4: Likewise.
16750
16751         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
16752
16753 2005-09-22  Jim Meyering  <jim@meyering.net>
16754
16755         Sync from coreutils.
16756
16757         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
16758
16759         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
16760         the .tm_year member, since otherwise gcc-4.0 would now warn about
16761         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
16762
16763         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
16764         order to avoid an unsuppressible warning from gcc on 64-bit systems.
16765
16766         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
16767         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
16768         when run in a time zone for which daylight savings time is in effect
16769         for the starting date.
16770
16771         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
16772         stop us from restricting permissions of just-created absolute-named
16773         directories.
16774         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
16775         to restore initial working directory.
16776         * lib/mkdir-p.c (make_dir_parents): New parameter:
16777         different_working_dir, to tell caller if/when we change the working
16778         directory and are unable to return to the initial one.
16779         * lib/mkdir-p.h (make_dir_parents): Update prototype.
16780         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
16781         `return false'.  This fixes a bug introduced on 2004-07-30.
16782
16783         * lib/openat.c (fdopendir): Be sure to close the supplied
16784         file descriptor before returning.  This makes our replacement
16785         implementation a little closer to Solaris's, where fdopendir
16786         ties the file descriptor to the returned DIR* pointer.
16787         * lib/openat.c (unlinkat): New function.
16788         * lib/openat.h (unlinkat): Add prototype.
16789         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
16790         (openat_restore_fail): Rename from openat_restore_die.
16791         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
16792
16793         Provide an alternative to exiting immediately upon save_cwd or
16794         restore_cwd failure.  Now, an application can arrange e.g.,
16795         to perform a longjump in that case.
16796         * lib/openat.c: Include dirname.h.
16797         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
16798         (rpl_openat, fdopendir, fstatat): Call openat_save_die
16799         and openat_restore_die rather than calling error directly.
16800         Don't include "error.h" or "exitfail.h"; they're no longer needed.
16801
16802         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
16803         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
16804         define.
16805
16806         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
16807         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
16808                             int utc, int nanoseconds);
16809         Background:
16810         date should not have to allocate a megabyte of virtual memory to
16811         handle a format argument like +%1048575T.  When implemented with
16812         strftime, it must allocate such a buffer, use strftime to fill it
16813         in, print it, then free it.
16814         With fprintftime, it simply prints everything and exits.
16815         With no need for memory allocation, that's one fewer way to fail.
16816         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
16817         optional field width, not before, so we accept %9:z, not %:9z.
16818         (my_strftime): Be sure to use L_('x') for literals.
16819
16820         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
16821         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
16822         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
16823         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
16824         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
16825         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
16826         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
16827         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
16828         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
16829         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
16830         * lib/xgethostname.c, lib/xreadlink.c:
16831         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
16832
16833         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
16834         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
16835         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
16836         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
16837         and don't include <sys/file.h>).
16838
16839 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
16840
16841         Sync from coreutils.
16842
16843         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
16844         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
16845         [!LDAV_DONE]: Avoid unused variable warning.
16846
16847 2005-09-21  Bruno Haible  <bruno@clisp.org>
16848
16849         * lib/unicodeio.h (unicode_to_mb): New declaration.
16850
16851 2005-09-20  Derek Price  <derek@ximbiot.com>
16852
16853         * lib/getaddrinfo.c: Don't include <netdb.h> included from
16854         getaddrinfo.h.
16855
16856 2005-09-20  Bruno Haible  <bruno@clisp.org>
16857
16858         * gnulib-tool: Remove trailing slashes from the values specified for
16859         --source-base, --m4-base, --tests-base, --aux-dir.
16860         Suggested by Simon Josefsson <jas@extundo.com>.
16861
16862 2005-09-20  Bruno Haible  <bruno@clisp.org>
16863
16864         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
16865         func_modules_to_filelist, func_import, func_create_testdir): Make all
16866         sorting results locale-independent, so that gnulib-cache.m4 doesn't
16867         change when gnulib-tool is invoked in a different locale.
16868
16869 2005-09-19  Simon Josefsson  <jas@extundo.com>
16870
16871         * m4/socklen.m4: Fix typo.
16872
16873 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
16874
16875         Use a consistent style for including <config.h>.
16876         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
16877         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
16878         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
16879         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
16880         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
16881         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
16882         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
16883         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
16884         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
16885         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
16886         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
16887         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
16888         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
16889         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
16890         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
16891         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
16892         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
16893         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
16894         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
16895         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
16896         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
16897         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
16898         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
16899         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
16900         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
16901         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
16902         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
16903         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
16904         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
16905         lib/xstrtoumax.c, lib/yesno.c:
16906         Standardize inclusion of config.h.
16907         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
16908         lib/inttostr.h:  Removed inclusion of config.h from header files.
16909         * lib/inttostr.c:  Adjusted in-tree users.
16910         * lib/timespec.h: Remove superfluous warning to include config.h.
16911         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
16912         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
16913         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
16914         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
16915         config.h with HAVE_CONFIG_H.
16916
16917 2005-09-19  Jim Meyering  <jim@meyering.net>
16918
16919         * modules/pathmax (License): Change to LGPL.
16920
16921 2005-09-19  Derek Price  <derek@ximbiot.com>
16922
16923         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
16924
16925 2005-09-19  Bruno Haible  <bruno@clisp.org>
16926
16927         * gnulib-tool (import): Provide default for --tests-base.
16928
16929 2005-09-19  Bruno Haible  <bruno@clisp.org>
16930
16931         * doc/quote.texi: New file, extracted from gnulib.texi.
16932         * doc/ctime.texi: New file, extracted from gnulib.texi.
16933         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
16934         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
16935         * doc/gnulib.texi: Include them.
16936
16937 2005-09-18  Bruno Haible  <bruno@clisp.org>
16938
16939         Portability fix.
16940         * gnulib-tool (func_readlink): New function.
16941         (func_ln_if_changed): Use it.
16942
16943 2005-09-18  Bruno Haible  <bruno@clisp.org>
16944
16945         * gnulib-tool: Support --with-tests also with --import.
16946         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
16947         (func_import): Use variables $testsbase and $inctests. Emit a
16948         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
16949         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
16950         SUBDIRS += $testsdir.
16951         (func_create_testdir): Update.
16952
16953 2005-09-18  Bruno Haible  <bruno@clisp.org>
16954
16955         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
16956         instead of $dry_run.
16957         (func_cp_if_changed, func_mv_if_changed): Remove functions.
16958         (func_ln_if_changed): Don't handle dry-run here.
16959         (func_import): In dry-run mode, detect more precisely which actions
16960         would be performed, and don't use "...ing" verbs.
16961
16962 2005-09-18  Bruno Haible  <bruno@clisp.org>
16963
16964         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
16965         (func_import): Use join on two temporary files instead of three nested
16966         loops, in order to determine which files are new or old.
16967
16968 2005-09-18  Bruno Haible  <bruno@clisp.org>
16969
16970         * gnulib-tool (func_import): Comment out code that spits out the
16971         new files with --dry-run.
16972
16973 2005-09-18  Bruno Haible  <bruno@clisp.org>
16974
16975         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
16976
16977 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
16978
16979         * lib/stat-time.h: New file.
16980         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
16981         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
16982         in a different way.
16983         (timespec_cmp): New function.
16984         * lib/utimecmp.c: Include stat-time.h.
16985         (SYSCALL_RESOLUTION): Depend on whether various struct stat
16986         members exist, not on the obsolescent ST_MTIM_NSEC.
16987         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
16988
16989 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
16990
16991         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
16992
16993 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
16994
16995         * MODULES.html.sh (File system functions): Add stat-time.
16996         * modules/stat-time: New file.
16997         * modules/timespec (Files): Remove m4/st_mtim.m4; this
16998         is now done in a different way, by the stat-time module.
16999         * modules/utimecmp (Depends-on): Add stat-time.
17000
17001 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
17002
17003         * m4/st_mtim.m4: Remove.  Superseded by...
17004         * m4/stat-time.m4: New file.
17005         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
17006         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
17007
17008 2005-09-15  Derek Price  <derek@ximbiot.com>
17009
17010         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
17011
17012 2005-09-15  Derek Price  <derek@ximbiot.com>
17013
17014         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
17015         * lib/regex_internal.c: Ditto, using this...
17016         (__GNUC_PREREQ): ...new macro.
17017         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
17018         using...
17019         (__GNUC_PREREQ): ...this new macro.
17020
17021         * lib/strstr.h: Include string.h. Define strstr as a macro here.
17022
17023 2005-09-15  Derek Price  <derek@ximbiot.com>
17024             Paul Eggert  <eggert@cs.ucla.edu>
17025
17026         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
17027         changes, consolidating in...
17028         * lib/regex_internal.h: ...this file.
17029
17030 2005-09-13  Jim Meyering  <jim@meyering.net>
17031
17032         * lib/canon-host.c: Filter through gnu indent and reword comments
17033         slightly.
17034         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
17035
17036 2005-09-13  Derek Price  <derek@ximbiot.com>
17037
17038         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
17039         failure.
17040         Reported by Jim Meyering  <jim@meyering.net>.
17041
17042 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
17043
17044         * lib/base64.c: Typo.
17045         (base64_encode): Put b64str in initialized data section.
17046
17047 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
17048
17049         Merge glibc and coreutils changes into gnulib, plus a few
17050         extra fixes.
17051         * lib/md5.c: Use #error rather than a string.
17052         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
17053         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
17054         (__attribute__): Define to empty for non recent-GCC.
17055         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
17056         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
17057         Renamed from their non-__ counterparts, with new macros replacing
17058         them if not _LIBC.  Add __THROW attribute.
17059         (rol): Remove.
17060         (struct md5_ctx): Align buffer if using GCC.
17061         * lib/sha1.h (struct sha1_ctx): Likewise.
17062         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
17063         The old name was backwards.
17064         (NOTSWAP): Remove; not used.
17065         (rol): New macro, moved here from md5.h.
17066         (sha1_process_block): Remove a FIXME that doesn't make sense.
17067
17068 2005-09-12  Derek Price  <derek@ximbiot.com>
17069
17070         Return usable errors from canon-host.
17071         * lib/canon-host.h: New file.
17072         * lib/canon-host.c (canon_host): Wrap...
17073         (canon_host_r): ...this new function, which now relies exclusively on
17074         getaddrinfo.
17075         (ch_strerror): New function.
17076         (last_cherror): New global.
17077         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
17078         interface.
17079         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
17080         void *.
17081         (freeaddrinfo): Free ai->ai_canonname when set.
17082
17083 2005-09-12  Derek Price  <derek@ximbiot.com>
17084
17085         Make canon-host require getaddrinfo.
17086         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
17087         AC_LIBSOURCE canon-host.h.  Call...
17088         (gl_PREREQ_CANON_HOST): ...this new function, which requires
17089         gl_GETADDRINFO.
17090         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
17091
17092 2005-09-12  Derek Price  <derek@ximbiot.com>
17093
17094         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
17095         LGPL.
17096         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
17097
17098 2005-09-12  Derek Price  <derek@ximbiot.com>
17099
17100         * lib/gai_strerror.c: Include config.h when available.  Include
17101         getaddrinfo.h before other headers to test interface.
17102         Reported by Larry Jones <lawrence.jones@ugs.com>.
17103
17104 2005-09-12  Derek Price  <derek@ximbiot.com>
17105             Paul Eggert  <eggert@cs.ucla.edu>
17106
17107         * modules/glob (Files): Add glob-libc.h.
17108
17109 2005-09-12  Derek Price  <derek@ximbiot.com>
17110             Paul Eggert  <eggert@cs.ucla.edu>
17111
17112         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
17113         glob_.h, glob-libc.h.
17114         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
17115
17116 2005-09-12  Derek Price  <derek@ximbiot.com>
17117             Paul Eggert  <eggert@cs.ucla.edu>
17118
17119         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
17120         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
17121         protecting things that should be done only in gnulib contexts.
17122         * lib/glob_.h: New file, containing only the glob things needed for
17123         gnulib.
17124         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
17125         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
17126         (glob, globfree, glob_pattern_p): Now defined simply in terms of
17127         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
17128         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
17129         and to respect the namespace rules better.
17130
17131 2005-09-08  Simon Josefsson  <jas@extundo.com>
17132
17133         * modules/socklen: New file.
17134
17135 2005-09-08  Simon Josefsson  <jas@extundo.com>
17136
17137         * m4/socklen.m4: New file.
17138
17139 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17140
17141         * modules/utimens (Files): Add m4/utimbuf.m4, since
17142         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
17143         Reported by Sergey Poznyakoff.
17144
17145 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17146
17147         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
17148         definitions, since that's the preferred style in glibc.
17149         Fix a minor spacing issue, and update copyright notice to match
17150         glibc's.
17151
17152 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17153
17154         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
17155
17156 2005-09-06  Simon Josefsson  <jas@extundo.com>
17157
17158         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
17159         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
17160
17161 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17162
17163         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
17164         warning.
17165
17166 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17167
17168         * config/srclist.txt: Add glibc bug 1302.
17169
17170 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
17171
17172         Change bitset word type from unsigned int to unsigned long int,
17173         as this has better performance on typical 64-bit hosts.
17174         Port bitset code to hosts with unusual word sizes.
17175         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
17176         (build_collating_symbol):
17177         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
17178         argument is a bitset.  This is merely a style issue, but it makes
17179         it clearer that an entire array is expected.
17180         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
17181         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
17182         Port to the case where bitset_word is not the same as unsigned int.
17183         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17184         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
17185         Likewise.
17186         * lib/regexec.c (check_dst_limits_calc_pos_1,
17187         check_subexp_matching_top):
17188         (build_trtable, group_nodes_into_DFAstates):
17189         Likewise.
17190         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
17191         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
17192         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
17193         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
17194         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
17195         * lib/regcomp.c (optimize_subexps, lower_subexp):
17196         Work even if bitset_word has holes in its bitwise representation.
17197         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
17198         * lib/regexec.c (check_dst_limits_calc_pos_1,
17199         check_subexp_matching_top):
17200         Likewise.
17201         * lib/regex_internal.c (re_string_reconstruct):
17202         Don't assume UCHAR_MAX == 255.
17203         * lib/regex_internal.h (bitset_set_all): Likewise.
17204         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
17205         All uses changed.
17206         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
17207         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
17208         All uses changed.
17209         (BITSET_WORD_MAX): New macro.
17210         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
17211         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
17212         (bitset_empty, bitset_copy):
17213         Prefer sizeof (bitset) to multiplying it out ourselves.
17214         (bitset_not_merge): Remove; unused.
17215         (bitset_contain): Return bool, not unsigned int with one bit on.
17216         All callers changed.
17217         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
17218         alignment than re_node_set; do this by defining a new internal
17219         type struct dests_alloc and using it to allocate memory.
17220
17221 2005-09-05  Bruno Haible  <bruno@clisp.org>
17222
17223         * gnulib-tool (func_import): Fix comparison in handling of symbolic
17224         links.
17225
17226 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
17227
17228         * modules/size_max (Makefile.am): Add size_max.h
17229
17230 2005-09-04  Derek Price  <derek@ximbiot.com>
17231
17232         * gnulib-tool (func_import): Fix reversed $symbolic logic.
17233
17234 2005-09-03  Simon Josefsson  <jas@extundo.com>
17235
17236         * gnulib-tool: Fix typo.
17237
17238 2005-09-03  Simon Josefsson  <jas@extundo.com>
17239
17240         * config/srclist.txt: Add glibc bug 1293.
17241
17242 2005-09-03  Derek Price  <derek@ximbiot.com>
17243
17244         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
17245         From Larry Jones <lawrence.jones@ugs.com>.
17246
17247 2005-09-02  Simon Josefsson  <jas@extundo.com>
17248
17249         * modules/socklen: New file.
17250
17251 2005-09-02  Simon Josefsson  <jas@extundo.com>
17252
17253         * modules/havelib: New module.
17254
17255         * modules/gettext, modules/iconv, modules/lock, modules/readline:
17256         Use havelib.
17257
17258 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17259
17260         Check for arithmetic overflow when calculating sizes, to prevent
17261         some buffer-overflow issues.  These patches are conservative, in the
17262         sense that when I couldn't determine whether an overflow was possible,
17263         I inserted a run-time check.
17264         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
17265         macros.
17266         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
17267         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
17268         (re_xnrealloc, re_x2nrealloc): New inline functions.
17269         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
17270         parse_bracket_exp):
17271         (build_equiv_class, build_charclass): Check for arithmetic overflow
17272         in size expression calculations.
17273         * lib/regex_internal.c (re_string_realloc_buffers):
17274         (build_wcs_upper_buffer, re_node_set_add_intersect):
17275         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
17276         (re_dfa_add_node, register_state): Likewise.
17277         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
17278         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
17279         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
17280         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
17281
17282 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17283
17284         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
17285         m4/ulonglong.m4.  Problem reported by Martin Lambers.
17286
17287 2005-09-02  Bruno Haible  <bruno@clisp.org>
17288
17289         Support for lib vs. lib64 distinction on biarch platforms.
17290         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
17291         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
17292         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
17293
17294 2005-09-02  Bruno Haible  <bruno@clisp.org>
17295
17296         * gnulib-tool (import): In the other first-use case, provide defaults
17297         as well.
17298
17299 2005-09-02  Bruno Haible  <bruno@clisp.org>
17300
17301         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
17302         patches not yet found in the latest gettext release.
17303
17304 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17305
17306         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
17307         to avoid a collision with bits/local_lim.h in glibc.
17308         All uses changed.  Problem reported by Dmitry V. Levin in
17309         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
17310
17311         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
17312         bugs in int versus size_t comparisons.
17313         (re_string_context_at): Fix bug where the code assumed that
17314         Idx is signed.
17315
17316         Use bool where appropriate.
17317         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
17318         All callers changed.
17319         (calc_eclosure_iter): Likewise, for ROOT arg.
17320         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
17321         (build_charclass_op): Likewise, for NON_MATCH arg.
17322         * lib/regex_internal.c (re_string_allocate, re_string_construct):
17323         (re_string_construct_common): Likewise, for ICASE arg.
17324         * lib/regexec.c (re_search_2_stub, re_search_stub):
17325         Likewise, for RET_LEN arg.
17326         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
17327         (set_regs): Likewise, for FL_BACKTRACK arg.
17328         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
17329         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
17330         (calc_eclosure_iter, parse_bracket_exp):
17331         Use bool for internal variables that are booleans.
17332         * lib/regexec.c (re_search_internal, check_matching,
17333         proceed_next_node):
17334         (set_regs, build_sifted_states, sift_states_bkref):
17335         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
17336         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
17337         (find_collation_sequence_value):
17338         Likewise.
17339         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
17340         (re_node_set_compare):
17341         Return bool, not int. All callers changed.
17342         * lib/regexec.c (check_halt_node_context, check_dst_limits):
17343         (build_trtable, check_node_accept): Likewise.
17344         * lib/regex_internal.h: Include stdbool.h.
17345
17346         Fix bugs uncovered when converting to bool.
17347         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
17348         failure instead of charging ahead blindly.
17349         * lib/regex_internal.c (register_state): Likewise.
17350         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
17351         for freeing internal storage.
17352         (group_nodes_into_DFA_states): Use unsigned int, not int, for
17353         bitset pieces used as boolean, to avoid undefined behavior
17354         on hosts that do int overflow checking.
17355
17356 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17357
17358         * config/srclist.txt: Add glibc bugs 1285-1287.
17359
17360 2005-09-01  Jim Meyering  <jim@meyering.net>
17361
17362         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
17363         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
17364         Require gl_STAT_MACROS, too.
17365
17366 2005-09-01  Bruno Haible  <bruno@clisp.org>
17367
17368         * gnulib-tool (import): In the first-use case, provide defaults.
17369
17370 2005-09-01  Bruno Haible  <bruno@clisp.org>
17371
17372         * gnulib-tool (func_import): Remove the .tmp files.
17373
17374 2005-09-01  Bruno Haible  <bruno@clisp.org>
17375
17376         * gnulib-tool (func_import): Fix handling of symbolic links.
17377
17378 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17379
17380         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
17381         old glibc regex code mishandles strings longer than 2**31 bytes.
17382         This patch fixes this when the regex code is used in gnulib
17383         (i.e., outside glibc).
17384
17385         This patch should not affect the use of the regex code inside
17386         glibc.  No doubt this problem also needs to be handled for glibc
17387         as well, but the result will be an incompatible change to the
17388         glibc ABI, and the old ABI will have to be supported too.  That
17389         can be the the subject for another patch.
17390
17391         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
17392         governing whether the rest of this patch is active.  By default,
17393         the macro is disabled and the patch has no effect.
17394         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
17395         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
17396         (struct re_pattern_buffer, re_search, re_search_2, re_match):
17397         (re_match_2, re_set_registers): Use the new types.
17398         * lib/regex_internal.h (Idx, re_hashval_t): New types.
17399         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
17400         New macros.
17401         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
17402         (re_string_context_at, bin_tree_t, re_dfastate_t):
17403         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
17404         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
17405         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
17406         (re_string_char_size_at, re_string_wchar_at):
17407         (re_string_elem_size_at):
17408         Use the new types and macros to port to 64-bit hosts.
17409         Use unsigned types for internal values, so that the code
17410         mostly works even for arrays larger than SSIZE_MAX.
17411         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
17412         (search_duplicated_node, calc_eclosure_iter, fetch_number):
17413         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
17414         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
17415         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
17416         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
17417         (calc_inveclosure, parse_dup_op, build_range_exp):
17418         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
17419         (fetch_number, create_token_tree, mark_opt_subexp):
17420         Likewise.
17421         * lib/regex_internal.c (re_string_construct_common,
17422         create_ci_newstate):
17423         (create_cd_newstate, re_string_allocate, re_string_construct):
17424         (re_string_realloc_buffers, build_wcs_upper_buffer):
17425         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
17426         (re_string_reconstruct, re_string_peek_byte_case):
17427         (re_string_fetch_byte_case, re_string_context_at):
17428         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
17429         (re_node_set_init_copy, re_node_set_add_intersect):
17430         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
17431         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
17432         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
17433         (re_acquire_state, re_acquire_state_context, register_state):
17434         Likewise.
17435         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
17436         search_cur_bkref_entry):
17437         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
17438         (re_search_internal, re_search_2_stub, re_search_stub)
17439         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
17440         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
17441         (update_cur_sifted_state, check_dst_limits):
17442         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
17443         (check_subexp_limits, sift_states_bkref, merge_state_array):
17444         (check_subexp_matching_top, get_subexp, get_subexp_sub):
17445         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
17446         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
17447         (expand_bkref_cache, check_node_accept_bytes):
17448         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
17449         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
17450         (acquire_init_state_context, check_halt_node_context):
17451         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
17452         (sift_states_backward, clean_state_log_if_needed):
17453         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
17454         (find_recover_state, transit_state_sb, transit_state_mb):
17455         (transit_state_bkref, build_trtable, match_ctx_clean):
17456         Likewise.
17457         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
17458         to work around an assumption that REG_MISSING is negative.
17459
17460         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
17461         (seek_collating_symbol_entry) [defined _LIBC]:
17462         (lookup_collation_sequence_value) [defined _LIBC]:
17463         (build_range_exp, build_collating_symbol) [defined _LIBC]:
17464         Use prototypes rather than old-style function definitions.
17465         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
17466         (transit_state_sb) [0]:
17467         (find_collation_sequence_value) [defined _LIBC]: Likewise.
17468
17469         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
17470         rm_eo.
17471
17472         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
17473         (optimize_subexps, lower_subexp):
17474         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
17475         since the signed shift might overflow.  Use 1u<<31 instead.
17476         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17477         Likewise.
17478         * lib/regexec.c (check_dst_limits_calc_pos_1,
17479         check_subexp_matching_top): Likewise.
17480
17481         * lib/regcomp.c (optimize_subexps, lower_subexp):
17482         Use CHAR_BIT rather than 8, for clarity.
17483         * lib/regexec.c (check_dst_limits_calc_pos_1):
17484         (check_subexp_matching_top): Likewise.
17485         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
17486         have to worry about portability issues when shifting it left.
17487         Remove no-longer-needed test for table_size > 0.
17488         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
17489         in a word, as the resulting behavior is undefined.
17490         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
17491         in one case, a <= should have been an <, and in another case the
17492         whole test was missing.
17493         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
17494         the standard name CHAR_BIT.
17495         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
17496         this is not true on one's complement and signed-magnitude hosts.
17497
17498         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
17499         next_last_offset.
17500         (struct re_dfa_t): Remove unused member states_alloc.
17501         * lib/regcomp.c (init_dfa): Don't initialize unused members.
17502
17503 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17504
17505         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
17506         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
17507         and large-file glibc and in 32-bit large-file Solaris.
17508
17509 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17510
17511         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
17512         lengths fit in regoff_t; this isn't true if regoff_t is the same
17513         width as size_t.
17514         * lib/regex.c (re_search_internal): 5th arg is LAST_START
17515         (= START + RANGE) instead of RANGE.  This avoids overflow
17516         problems when regoff_t is the same width as size_t.
17517         All callers changed.
17518         (re_search_2_stub): Check for overflow when adding the
17519         sizes of the two strings.
17520         (re_search_stub): Check for overflow when adding START
17521         to RANGE; if it occurs, substitute the extreme value.
17522
17523 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17524
17525         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
17526
17527 2005-08-31  Jim Meyering  <jim@meyering.net>
17528
17529         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
17530         a pointer-to-const.
17531         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
17532         (register_state): Likewise.
17533         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
17534         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
17535         (group_nodes_into_DFAstates): Likewise.
17536
17537 2005-08-31  Jim Meyering  <jim@meyering.net>
17538
17539         * check-module: Add a FIXME comment.
17540
17541 2005-08-31  Eric Blake  <ebb9@byu.net>
17542
17543         * modules/unistd-safer (Files): Add unistd--.h.
17544         * modules/stdio-safer (Files): Add stdio--.h.
17545
17546 2005-08-31  Derek Price  <derek@ximbiot.com>
17547
17548         * lib/getdelim.c (getdelim): Return EOF on EOF.
17549         Reported by Larry Jones <lawrence.jones@ugs.com>.
17550
17551 2005-08-31  Bruno Haible  <bruno@clisp.org>
17552
17553         Avoid unnecessary diffs in the generated lib/Makefile.am.
17554         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
17555         the generated files.
17556         (func_import): Don't set cmd.
17557
17558 2005-08-31  Bruno Haible  <bruno@clisp.org>
17559
17560         * lib/strstr.c: Include <stddef.h>, for NULL.
17561         * lib/strcasestr.c: Likewise.
17562         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
17563
17564 2005-08-31  Bruno Haible  <bruno@clisp.org>
17565
17566         * gnulib-tool: New option --macro-prefix.
17567         (func_import): Use macro_prefix.
17568         (import): Handle option --macro-prefix.
17569
17570 2005-08-31  Bruno Haible  <bruno@clisp.org>
17571
17572         * gnulib-tool (import): Rename most ac_* variables to cached_*.
17573         Also use new variables cached_lgpl, cached_libtool.
17574
17575 2005-08-31  Bruno Haible  <bruno@clisp.org>
17576
17577         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
17578         always instantiating them.
17579
17580 2005-08-31  Bruno Haible  <bruno@clisp.org>
17581
17582         * gnulib-tool (func_import): Read the previous cached settings
17583         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
17584         earlier added by gnulib but are now dropped. Warn when a gnulib file
17585         overwrites a non-gnulib file.
17586
17587 2005-08-31  Bruno Haible  <bruno@clisp.org>
17588
17589         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
17590         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
17591         projects that don't keep autogenerated files in CVS. Put into
17592         actioncmd only the specified modules, not the transitive closure.
17593
17594 2005-08-31  Bruno Haible  <bruno@clisp.org>
17595
17596         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
17597         Create directories that shall be filled.
17598         (import): Don't look for gl_* macros in configure.ac. Recurse across
17599         all directories containing a gnulib-cache.m4 files, if meaningful.
17600
17601 2005-08-31  Bruno Haible  <bruno@clisp.org>
17602
17603         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
17604         (import): Set seen_libtool when we see gl_LIBTOOL.
17605
17606 2005-08-31  Bruno Haible  <bruno@clisp.org>
17607
17608         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
17609         declaration macro definitions from generated gnulib.m4.
17610
17611 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
17612
17613         * lib/iconvme.h: Add prototype for iconv_alloc.
17614
17615 2005-08-29  Simon Josefsson  <jas@extundo.com>
17616
17617         * lib/iconvme.c: Fix errno.
17618
17619 2005-08-29  Bruno Haible  <bruno@clisp.org>
17620
17621         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
17622         that it works when the directory contains spaces.
17623
17624 2005-08-29  Bruno Haible  <bruno@clisp.org>
17625
17626         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
17627
17628 2005-08-29  Bruno Haible  <bruno@clisp.org>
17629
17630         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
17631         Emit more advice.
17632
17633 2005-08-29  Bruno Haible  <bruno@clisp.org>
17634         and Stepan Kasal  <kasal@ucw.cz>
17635
17636         * check-module: If more parameters are given, check each of them
17637         separately; add more exceptions, as noted by Jim Meyering.
17638         (check_module): New procedure.
17639         (%exempt_header): Now contains all exceptions.
17640
17641 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
17642
17643         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
17644
17645 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
17646
17647         * lib/iconvme.c: Split iconv_string into iconv_alloc.
17648
17649 2005-08-28  Bruno Haible  <bruno@clisp.org>
17650
17651         * m4/gnulib-tool.m4: New file.
17652
17653 2005-08-27  Jim Meyering  <jim@meyering.net>
17654
17655         * modules/unistd-safer (Files): Add pipe-safer.c.
17656         * modules/fcntl-safer (Files): Add creat-safer.c.
17657
17658 2005-08-27  Jim Meyering  <jim@meyering.net>
17659
17660         * m4/stdlib-safer.m4: New file.  From coreutils.
17661         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
17662         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
17663         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
17664         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
17665         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
17666
17667 2005-08-27  Jim Meyering  <jim@meyering.net>
17668
17669         * lib/fopen-safer.c: Merge minor changes from coreutils.
17670         * lib/dup-safer.c: Likewise.
17671         * lib/fd-safer.c: Likewise.
17672
17673         Merge from coreutils.
17674         * lib/stdio--.h: New file.
17675         * lib/stdlib--.h: New file.
17676         * lib/mkstemp-safer.c: New file.
17677
17678         GNU tar needs these.
17679         * lib/pipe-safer.c: New file.
17680         * lib/creat-safer.c: New file.
17681         * lib/fcntl--.h (creat): Define to creat_safer.
17682         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
17683         * lib/unistd--.h (pipe): Define to pipe_safer.
17684         * lib/unistd-safer.h: Declare pipe_safer.
17685
17686 2005-08-26  Simon Josefsson  <jas@extundo.com>
17687
17688         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
17689         Haible <bruno@clisp.org>.
17690
17691 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
17692
17693         * lib/regex_internal.h: Remove all references to
17694         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
17695         or better.
17696         (bitset_not, bitset_merge, bitset_not_merge):
17697         (bitset_mask, re_string_allocate, re_string_construct):
17698         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
17699         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
17700         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
17701         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
17702         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
17703         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
17704         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
17705         (re_acquire_state_context):
17706         Remove unnecessary forward decls.
17707         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
17708         Put __attribute at function definition,
17709         now that the function decl has been removed.
17710         * lib/regex_internal.c (re_string_peek_byte_case):
17711         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
17712         Likewise.
17713
17714 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
17715
17716         * m4/regex.m4: Add AC_PREREQ(2.50).
17717         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
17718
17719 2005-08-25  Simon Josefsson  <jas@extundo.com>
17720
17721         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
17722         __fsetlocking.
17723
17724 2005-08-25  Simon Josefsson  <jas@extundo.com>
17725
17726         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
17727         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
17728         GLIBC specific code.
17729
17730 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17731
17732         Make regex safe for g++.  This fixes one real bug (an "err"
17733         that should have been "*err").  g++ problem reported by
17734         Sam Steingold.
17735         * lib/regex_internal.h (re_calloc): New macro, consistent with
17736         re_malloc etc.  All callers of calloc changed to use re_calloc.
17737         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
17738         not int.  All callers changed.
17739         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
17740         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
17741         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
17742         (find_recover_state): Change "err" to "*err"; this fixes what
17743         appears to be a real bug.
17744         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
17745         versus int.
17746
17747 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17748
17749         * modules/regex (Depends-on): Add malloc, since the code
17750         assumes that !malloc(0) means failure.
17751
17752 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17753
17754         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
17755
17756         alloca modernization/simplification for regex.
17757         * lib/regex.c: Remove portability cruft for alloca.  This no longer
17758         needs to be at the start of the file, and can be moved into
17759         regex_internal.h and simplified.
17760         * lib/regex_internal.h: Include <alloca.h>.
17761         (__libc_use_alloca) [!defined _LIBC]: New macro.
17762         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
17763         now works outside glibc.
17764
17765 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
17766
17767         * config/srclist.txt: Add glibc bugs 1241, 1245.
17768
17769 2005-08-25  Jim Meyering  <jim@meyering.net>
17770
17771         * lib/open-safer.c: Include <config.h>.
17772         Otherwise, we'd lose LARGEFILE support in any file using
17773         e.g. "fcntl--.h"
17774
17775 2005-08-25  Bruno Haible  <bruno@clisp.org>
17776
17777         * m4/minmax.m4: Require autoconf 2.52.
17778         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
17779         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
17780         alternatives of translit over the alphabet.
17781         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
17782
17783 2005-08-24  Simon Josefsson  <jas@extundo.com>
17784
17785         * tests/test-getpass.c: New file.
17786
17787 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
17788
17789         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
17790         for GNU regex features.
17791
17792 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
17793
17794         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
17795         * lib/regex.h (regerror): Likewise.
17796
17797         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
17798         requires this.  (The code never needed it.)
17799
17800         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
17801         All uses of recently-renamed identifiers changed to use the new,
17802         POSIX-compliant names.  The code will build and run just fine
17803         without these changes, but it's better to eat our own dog food
17804         and use the standard-conforming names.
17805
17806         * lib/regex.h: Fix a multitude of POSIX name space violations.
17807         These changes have an effect only for programs that define
17808         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
17809         do not change anything for programs compiled in the normal way.
17810         Also, there is no effect on the ABI.
17811
17812         (_REGEX_SOURCE): New macro.
17813         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
17814         defined and _GNU_SOURCE is not; this fixes a name space violation.
17815
17816         Rename the following macros to obey POSIX requirements.
17817         The old names are still visible as macros if _REGEX_SOURCE is defined.
17818         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
17819         RE_BACKSLASH_ESCAPE_IN_LISTS.
17820         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
17821         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
17822         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
17823         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
17824         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
17825         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
17826         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
17827         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
17828         (REG_INTERVALS): renamed from RE_INTERVALS.
17829         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
17830         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
17831         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
17832         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
17833         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
17834         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
17835         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
17836         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
17837         RE_UNMATCHED_RIGHT_PAREN_ORD.
17838         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
17839         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
17840         (REG_DEBUG): renamed from RE_DEBUG.
17841         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
17842         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
17843         unusual, since we can't clash with the POSIX REG_ICASE.
17844         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
17845         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
17846         (REG_NO_SUB): renamed from RE_NO_SUB.
17847         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
17848         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
17849         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
17850         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
17851         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
17852         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
17853         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
17854         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
17855         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
17856         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
17857         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
17858         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
17859         RE_SYNTAX_POSIX_MINIMAL_BASIC.
17860         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
17861         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
17862         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
17863         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
17864         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
17865         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
17866         (REG_FIXED): Renamed from REGS_FIXED.
17867         (REG_NREGS): Renamed from RE_NREGS.
17868
17869         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
17870         of other REG_* macros, since POSIX says the user is allowed to
17871         #undef these macros selectively.
17872
17873         (reg_errcode_t): Update comment stating what other tables need
17874         to be consistent.
17875
17876         Rename the following enum values to obey POSIX requirements.
17877         The old names are still visible as macros.
17878         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
17879         is not defined, since GNU is supposed to be a superset of POSIX as
17880         much as possible, and since we want reg_errcode_t to be a signed
17881         type for implementation consistency.
17882         (_REG_NOERROR): Renamed from REG_NOERROR.
17883         (_REG_NOMATCH): Renamed from REG_NOMATCH.
17884         (_REG_BADPAT): Renamed from REG_BADPAT.
17885         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
17886         (_REG_ECTYPE): Renamed from REG_ECTYPE.
17887         (_REG_EESCAPE): Renamed from REG_EESCAPE.
17888         (_REG_ESUBREG): Renamed from REG_ESUBREG.
17889         (_REG_EBRACK): Renamed from REG_EBRACK.
17890         (_REG_EPAREN): Renamed from REG_EPAREN.
17891         (_REG_EBRACE): Renamed from REG_EBRACE.
17892         (_REG_BADBR): Renamed from REG_BADBR.
17893         (_REG_ERANGE): Renamed from REG_ERANGE.
17894         (_REG_ESPACE): Renamed from REG_ESPACE.
17895         (_REG_BADRPT): Renamed from REG_BADRPT.
17896         (_REG_EEND): Renamed from REG_EEND.
17897         (_REG_ESIZE): Renamed from REG_ESIZE.
17898         (_REG_ERPAREN): Renamed from REG_ERPAREN.
17899         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
17900         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
17901         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
17902         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
17903
17904         (_REG_RE_NAME, _REG_RM_NAME): New macros.
17905         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
17906         changed.  But support the old name if the new one is not defined
17907         and if _REGEX_SOURCE.
17908
17909         Change the following member names in struct re_pattern_buffer.
17910         The old names are still supported if !_REGEX_SOURCE.
17911         The new names are always supported, regardless of _REGEX_SOURCE.
17912         (re_buffer): Renamed from buffer.
17913         (re_allocated): Renamed from allocated.
17914         (re_used): Renamed from used.
17915         (re_syntax): Renamed from syntax.
17916         (re_fastmap): Renamed from fastmap.
17917         (re_translate): Renamed from translate.
17918         (re_can_be_null): Renamed from can_be_null.
17919         (re_regs_allocated): Renamed from regs_allocated.
17920         (re_fastmap_accurate): Renamed from fastmap_accurate.
17921         (re_no_sub): Renamed from no_sub.
17922         (re_not_bol): Renamed from not_bol.
17923         (re_not_eol): Renamed from not_eol.
17924         (re_newline_anchor): Renamed from newline_anchor.
17925
17926         Change the following member names in struct re_registers.
17927         The old names are still supported if !_REGEX_SOURCE.
17928         The new names are always supported, regardless of _REGEX_SOURCE.
17929         (rm_num_regs): Renamed from num_regs.
17930         (rm_start): Renamed from start.
17931         (rm_end): Renamed from end.
17932
17933         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
17934         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
17935         Prepend __ to parameter names.
17936
17937         Undo yesterday's changes.
17938
17939 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
17940
17941         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
17942         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
17943         lib/regex.c.
17944
17945 2005-08-24  Jim Meyering  <jim@meyering.net>
17946
17947         Sync from coreutils.
17948         * m4/fcntl-safer.m4: New file.
17949
17950         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
17951         and object files for this module.
17952
17953 2005-08-24  Jim Meyering  <jim@meyering.net>
17954
17955         Sync from coreutils.
17956         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
17957
17958 2005-08-24  Jim Meyering  <jim@meyering.net>
17959
17960         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
17961         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
17962
17963 2005-08-24  Jim Meyering  <jim@meyering.net>
17964
17965         * modules/fcntl-safer: New module.
17966         * modules/fts (Depends-on): Add fcntl-safer.
17967         * MODULES.html.sh (File descriptor based Input/Output):
17968         Add fcntl-safer.
17969
17970 2005-08-24  Bruno Haible  <bruno@clisp.org>
17971
17972         Support for unit test modules.
17973         * modules/README: Mention tests modules.
17974         * modules/TEMPLATE-TESTS: New file.
17975         * gnulib-tool: New options --extract-tests-module, --with-tests and
17976         --tests-base (unused for the moment).
17977         (testsbase, inctests): New variables.
17978         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
17979         (func_verify_module): Exclude TEMPLATE-TESTS.
17980         (func_verify_nontests_module, func_verify_tests_module): New functions.
17981         (func_get_dependencies): Add implicit dependency for tests modules.
17982         (func_get_tests_module): New function.
17983         (func_modules_transitive_closure): When --with-tests was specified,
17984         include the unit tests as well, unless explicitly avoided.
17985         (func_emit_lib_Makefile_am): Ignore the tests modules here.
17986         (func_emit_tests_Makefile_am): New function.
17987         (func_create_testdir): When --with-tests was specified, emit a
17988         tests/ directory.
17989         * MODULES.html.sh (Future developments): Update.
17990
17991 2005-08-24  Bruno Haible  <bruno@clisp.org>
17992
17993         * modules/tls-tests: New file.
17994         * tests/test-tls.c: New file, from GNU gettext.
17995
17996 2005-08-24  Bruno Haible  <bruno@clisp.org>
17997
17998         * modules/lock-tests: New file.
17999         * tests/test-lock.c: New file, from GNU gettext.
18000
18001 2005-08-24  Bruno Haible  <bruno@clisp.org>
18002
18003         * lib/lock.h: Add multiple inclusion guard.
18004         * lib/tls.h: Add multiple inclusion guard.
18005
18006 2005-08-24  Bruno Haible  <bruno@clisp.org>
18007
18008         * gnulib-tool: Add support for the --aux-dir option to
18009         --create-testdir, --create-megatestdir, --test, --megatest.
18010         (func_create_testdir, func_create_megatestdir): Optionally emit a
18011         AC_CONFIG_AUX_DIR directive.
18012         (create-testdir, create-megatestdir, test, megatest): Provide a
18013         default value for $auxdir.
18014
18015 2005-08-24  Bruno Haible  <bruno@clisp.org>
18016
18017         * gnulib-tool (import): Use compound statement instead of subshell
18018         where possible.
18019
18020 2005-08-24  Bruno Haible  <bruno@clisp.org>
18021
18022         * gnulib-tool (import): Change --aux-dir default to "build-aux".
18023
18024 2005-08-24  Bruno Haible  <bruno@clisp.org>
18025
18026         * gnulib-tool (func_version): Update.
18027
18028 2005-08-24  Bruno Haible  <bruno@clisp.org>
18029
18030         * gnulib-tool (func_import, func_create_testdir,
18031         func_create_megatestdir): Quote all autoconf macro arguments.
18032
18033 2005-08-24  Bruno Haible  <bruno@clisp.org>
18034
18035         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
18036         option --force, because --force causes the aclocal.m4 of each
18037         subdirectory to be newer than the corresponding config.h.in.
18038
18039 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18040
18041         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
18042         All contents moved to gl_REGEX.
18043         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
18044         assume that it does.
18045
18046 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18047
18048         * lib/regex.h (REG_NOSYS)
18049         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
18050         Define, since POSIX requires it as of 2001.
18051         (_REG_ENOSYS)
18052         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
18053         New private symbol, used to keep the enum signed in all cases.
18054         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
18055         Youngman in
18056         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
18057
18058         * lib/regex_internal.c (re_string_skip_chars, register_state):
18059         (calc_state_hash):
18060         Remove forward decls; no longer needed now that we use prototypes.
18061         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
18062         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
18063         (clean_state_log_if_needed): Likewise.
18064
18065 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18066
18067         * config/srclist.txt: Add glibc bugs 1231-1233.
18068
18069 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18070
18071         Fix problems reported by Sam Steingold in
18072         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
18073         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
18074         assumed that reg_errcode_t is a signed type, which is not
18075         necessarily true if _XOPEN_SOURCE is not defined.
18076         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
18077         since some compilers warn about it otherwise.
18078
18079 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18080
18081         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
18082         (init_word_char, create_initial_state, duplicate_node_closure):
18083         (fetch_token, peek_token_bracket, build_range_exp):
18084         (build_collating_symbol): Remove forward decls; no longer needed
18085         now that we use prototypes.
18086
18087         * lib/regcomp.c:
18088         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
18089         (re_compile_fastmap_iter, regcomp, regerror, regfree):
18090         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
18091         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
18092         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
18093         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
18094         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
18095         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
18096         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
18097         (build_range_exp, build_collating_symbol, parse_bracket_exp):
18098         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
18099         (build_charclass, build_charclass_op, fetch_number, create_tree):
18100         (create_token_tree, mark_opt_subexp, duplicate_tree):
18101         Use prototypes rather than old-style definitions.
18102
18103         * lib/regex_internal.c:
18104         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
18105         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
18106         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18107         (re_string_reconstruct, re_string_peek_byte_case):
18108         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
18109         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18110         (re_node_set_init_copy, re_node_set_add_intersect):
18111         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18112         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18113         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18114         (re_acquire_state, re_acquire_state_context, register_state):
18115         (create_ci_newstate, create_cd_newstate, free_state):
18116         Likewise.
18117         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
18118         re_search_2):
18119         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
18120         (re_search_internal, prune_impossible_nodes):
18121         (acquire_init_state_context, check_matching, static):
18122         (check_halt_node_context, check_halt_state_context, proceed_next_node):
18123         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
18124         (update_regs, sift_states_backward, build_sifted_states):
18125         (clean_state_log_if_needed, merge_state_array):
18126         (update_cur_sifted_state, add_epsilon_src_nodes):
18127         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
18128         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
18129         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
18130         (find_recover_state, check_subexp_matching_top, transit_state_mb):
18131         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
18132         (check_arrival, check_arrival_add_next_nodes):
18133         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18134         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18135         (check_node_accept_bytes, check_node_accept, extend_buffers):
18136         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
18137         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
18138         (sift_ctx_init):
18139         Likewise.
18140
18141         * lib/regex_internal.h:
18142         (re_string_allocate, re_string_construct, re_string_reconstruct):
18143         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
18144         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
18145         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
18146         (re_string_context_at, re_string_peek_byte_case):
18147         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
18148         is defined, since we now use prototypes always.
18149
18150         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
18151         C89 or better.  All uses removed.
18152
18153 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18154
18155         * config/srclist.txt: Add glibc bugs 1220-1227.
18156
18157 2005-08-20  Jim Meyering  <jim@meyering.net>
18158
18159         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
18160         of unused local, dfa.
18161
18162 2005-08-20  Bruno Haible  <bruno@clisp.org>
18163
18164         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
18165
18166 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18167
18168         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
18169         (re_node_set_insert_last, re_dfa_add_node):
18170         Rename local variables to avoid GCC shadowing warnings.
18171
18172 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18173
18174         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
18175         [defined lint]: Suppress bogus uninitialized-variable warnings.
18176
18177         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
18178         and let the caller return REG_ESPACE if out of space.  This
18179         removes an uninitialied-variable warning with GCC 4.0.1, and also
18180         avoids taking the address of a local variable.  All callers
18181         changed.
18182
18183 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18184
18185         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
18186         $LIBCSRC/posix/regexec.c.
18187         Add glibc bug 1217 for regcomp.c.
18188
18189 2005-08-19  Jim Meyering  <jim@meyering.net>
18190
18191         * lib/regexec.c (proceed_next_node): Redo local variables to
18192         avoid GCC shadowing warnings.
18193
18194 2005-08-18  Bruno Haible  <bruno@clisp.org>
18195
18196         * lib/strstr.c (strstr): Fix return value in multibyte case.
18197         * lib/strcasestr.c (strcasestr): Likewise.
18198
18199 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18200
18201         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
18202
18203 2005-08-17  Jim Meyering  <jim@meyering.net>
18204
18205         Make the %s format (seconds since the epoch) work for a negative
18206         number and when used with a zero-padded field width, e.g. %015s.
18207
18208         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
18209         label so that it precedes the code to set `digits'.  Otherwise,
18210         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
18211         print `00-22'.  Now, it prints `-0022', as it should.
18212
18213 2005-08-17  Bruno Haible  <bruno@clisp.org>
18214
18215         * modules/strstr (Files): Add m4/mbrtowc.m4.
18216         (Depends-on): Add mbuiter.
18217
18218 2005-08-17  Bruno Haible  <bruno@clisp.org>
18219
18220         * modules/strcasestr: New file.
18221         * MODULES.html.sh (String handling, based on ANSI C 89): Add
18222         strcasestr.
18223
18224 2005-08-17  Bruno Haible  <bruno@clisp.org>
18225
18226         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
18227
18228 2005-08-17  Bruno Haible  <bruno@clisp.org>
18229
18230         * modules/mbuiter: New file.
18231         * MODULES.html.sh (Extended multibyte and wide character utilities):
18232         Add mbuiter.
18233
18234 2005-08-17  Bruno Haible  <bruno@clisp.org>
18235
18236         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
18237         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
18238
18239 2005-08-17  Bruno Haible  <bruno@clisp.org>
18240
18241         * m4/strcasestr.m4: New file.
18242
18243 2005-08-17  Bruno Haible  <bruno@clisp.org>
18244
18245         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
18246         * lib/strstr.c: Completely rewritten, with multibyte locale support.
18247
18248 2005-08-17  Bruno Haible  <bruno@clisp.org>
18249
18250         * lib/strcasestr.h: New file.
18251         * lib/strcasestr.c: New file.
18252
18253 2005-08-17  Bruno Haible  <bruno@clisp.org>
18254
18255         * lib/strcasecmp.c: Use mbuiter.h.
18256
18257 2005-08-17  Bruno Haible  <bruno@clisp.org>
18258
18259         * lib/mbuiter.h: New file.
18260
18261 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
18262
18263         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
18264         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
18265         and gl_GETOPT are both invoked via different paths (as happens
18266         with GNU tar CVS because it uses both argp and getopt), the former
18267         wins.
18268
18269 2005-08-16  Bruno Haible  <bruno@clisp.org>
18270
18271         * modules/tls: New file.
18272         * MODULES.html.sh (Multithreading): Add tls.
18273
18274 2005-08-16  Bruno Haible  <bruno@clisp.org>
18275
18276         * modules/strnlen1: New file.
18277         * MODULES.html.sh (String handling): Add strnlen1.
18278
18279 2005-08-16  Bruno Haible  <bruno@clisp.org>
18280
18281         * modules/strcase (Files): Add m4/mbrtowc.m4.
18282         (Depends-on): Add strnlen1, mbchar.
18283
18284 2005-08-16  Bruno Haible  <bruno@clisp.org>
18285
18286         * modules/mbiter: New file.
18287         * MODULES.html.sh (Extended multibyte and wide character utilities):
18288         Add mbiter.
18289
18290 2005-08-16  Bruno Haible  <bruno@clisp.org>
18291
18292         * modules/mbfile: New file.
18293         * MODULES.html.sh (Extended multibyte and wide character utilities):
18294         Add mbfile.
18295
18296 2005-08-16  Bruno Haible  <bruno@clisp.org>
18297
18298         * modules/mbchar: New file.
18299         * MODULES.html.sh (Extended multibyte and wide character utilities):
18300         New section.
18301
18302 2005-08-16  Bruno Haible  <bruno@clisp.org>
18303
18304         * m4/tls.m4: New file, from GNU gettext.
18305
18306 2005-08-16  Bruno Haible  <bruno@clisp.org>
18307
18308         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
18309         always.
18310         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
18311
18312 2005-08-16  Bruno Haible  <bruno@clisp.org>
18313
18314         * m4/mbiter.m4: New file.
18315
18316 2005-08-16  Bruno Haible  <bruno@clisp.org>
18317
18318         * m4/mbfile.m4: New file.
18319
18320 2005-08-16  Bruno Haible  <bruno@clisp.org>
18321
18322         * m4/mbchar.m4: New file.
18323
18324 2005-08-16  Bruno Haible  <bruno@clisp.org>
18325
18326         * lib/tls.h: New file, from GNU gettext.
18327         * lib/tls.c: New file, from GNU gettext.
18328
18329 2005-08-16  Bruno Haible  <bruno@clisp.org>
18330
18331         * lib/strnlen1.h: New file.
18332         * lib/strnlen1.c: New file.
18333
18334 2005-08-16  Bruno Haible  <bruno@clisp.org>
18335
18336         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
18337         (mbi_init): Update.
18338         (mbi_avail, mbi_advance): Let the iteration end before the terminating
18339         NUL byte, not after it.
18340
18341 2005-08-16  Bruno Haible  <bruno@clisp.org>
18342
18343         * lib/strcase.h (strcasecmp): Add note in comments.
18344         * lib/strncasecmp.c: Use code from strcasecmp.c.
18345         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
18346         (strcasecmp): Work correctly in multibyte locales.
18347
18348 2005-08-16  Bruno Haible  <bruno@clisp.org>
18349
18350         * lib/mbiter.h: New file.
18351
18352 2005-08-16  Bruno Haible  <bruno@clisp.org>
18353
18354         * lib/mbfile.h: New file.
18355
18356 2005-08-16  Bruno Haible  <bruno@clisp.org>
18357
18358         * lib/mbchar.h: New file.
18359         * lib/mbchar.c: New file.
18360
18361 2005-08-16  Bruno Haible  <bruno@clisp.org>
18362
18363         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
18364         the valid ones. Makes the comparison operations transitive:
18365         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
18366         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
18367
18368 2005-08-15  Simon Josefsson  <jas@extundo.com>
18369
18370         * modules/ssize_t (License): Change to 'unlimited'.
18371
18372         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
18373
18374 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
18375
18376         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
18377         Add comments for each pending glibc patch.
18378
18379 2005-08-15  Bruno Haible  <bruno@clisp.org>
18380
18381         * lib/regex.h (__restrict_arr): Don't define to __restrict if
18382         __cplusplus is defined.
18383
18384 2005-08-14  Jim Meyering  <jim@meyering.net>
18385
18386         Sync from coreutils.
18387
18388         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
18389         Use the hash-table-based cycle-detection code not just when
18390         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
18391         Reported by James Youngman in
18392         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
18393         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
18394         FTS_TIGHT_CYCLE_CHECK.
18395         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
18396         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
18397         once again.
18398         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
18399         * lib/fts.c (fd_safer): Remove decl.
18400         Include fcntl--.h rather than unistd-safer.h
18401         (fts_safe_changedir): Don't call fd_safer; no longer needed
18402         now that we include fcntl--.h.
18403
18404 2005-08-12  Simon Josefsson  <jas@extundo.com>
18405
18406         * modules/getndelim2: Use ssize_t module.
18407         * modules/getnline: Likewise.
18408         * modules/safe-read: Likewise.
18409         * modules/xreadlink: Likewise.
18410
18411         * modules/ssize_t: New file.
18412
18413 2005-08-12  Simon Josefsson  <jas@extundo.com>
18414
18415         * m4/readline.m4: Look for termcap, curses or ncurses if required.
18416
18417 2005-08-12  Simon Josefsson  <jas@extundo.com>
18418
18419         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18420         ssize_t.
18421
18422 2005-08-12  Simon Josefsson  <jas@extundo.com>
18423
18424         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
18425         readline, getdelim and check_version.
18426         (Support for systems lacking ISO C 99: Sizes of integer types):
18427         Add size_max.
18428
18429 2005-08-12  Bruno Haible  <bruno@clisp.org>
18430
18431         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
18432
18433 2005-08-11  Simon Josefsson  <jas@extundo.com>
18434
18435         * modules/readline: New file.
18436
18437         * modules/strnlen (Files): Add strnlen.h.
18438
18439 2005-08-11  Simon Josefsson  <jas@extundo.com>
18440
18441         * m4/readline.m4: New file.
18442
18443 2005-08-11  Simon Josefsson  <jas@extundo.com>
18444
18445         * lib/readline.h, readline.c: New file.
18446
18447 2005-08-11  Simon Josefsson  <jas@extundo.com>
18448
18449         * doc/gnulib.texi (Initial import, Finishing touches): Mention
18450         gl_AVOID.
18451
18452 2005-08-11  Bruno Haible  <bruno@clisp.org>
18453
18454         * lib/strnlen.h (strnlen): Change parameter name to match comment.
18455
18456 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
18457
18458         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
18459
18460 2005-08-10  Simon Josefsson  <jas@extundo.com>
18461
18462         * tests/test-iconvme.c: New file.
18463
18464 2005-08-10  Simon Josefsson  <jas@extundo.com>
18465
18466         * m4/strnlen.m4: New file.
18467
18468         * m4/strndup.m4: Don't check for strnlen declaration, done in
18469         strnlen.m4.
18470
18471 2005-08-10  Simon Josefsson  <jas@extundo.com>
18472
18473         * lib/strndup.c: Use strnlen.h.
18474
18475         * lib/strnlen.h: New file.
18476
18477 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
18478
18479         * README: Typos.
18480
18481 2005-08-02  Simon Josefsson  <jas@extundo.com>
18482
18483         * modules/readline: New file.
18484
18485 2005-08-02  Simon Josefsson  <jas@extundo.com>
18486
18487         * modules/getdelim: New file.
18488
18489         * modules/getline: Rewrite, don't use getndelim2.
18490
18491 2005-08-02  Simon Josefsson  <jas@extundo.com>
18492
18493         * m4/getline.m4: Separate out getdelim stuff into separate module.
18494
18495         * m4/getdelim.m4: New file.
18496
18497 2005-08-02  Simon Josefsson  <jas@extundo.com>
18498
18499         * lib/getline.h, getline.c: Rewrite.
18500
18501         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
18502
18503 2005-07-31  Bruno Haible  <bruno@clisp.org>
18504
18505         * lib/lock.h (gl_lock_initializer): New macro.
18506         (gl_lock_define_initialized): Use it.
18507         (gl_rwlock_initializer): New macro.
18508         (gl_rwlock_define_initialized): Use it.
18509         (gl_recursive_lock_initializer): New macro.
18510         (gl_recursive_lock_define_initialized): Use it.
18511
18512 2005-07-30  Karl Berry  <karl@gnu.org>
18513
18514         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
18515         Report from Ben Pfaff, regarding getopt.
18516
18517 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
18518
18519         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
18520         normal way.
18521         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
18522         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
18523         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
18524         (gl_GETOPT): Use the new macros.  Most of the implementation
18525         is moved to the new macros.  This is for programs like Emacs
18526         that don't want all the functionality of gl_GETOPT.
18527
18528 2005-07-26  Bruno Haible  <bruno@clisp.org>
18529
18530         * m4/lock.m4: Update from GNU gettext.
18531
18532 2005-07-26  Bruno Haible  <bruno@clisp.org>
18533
18534         * lib/lock.h: Update from GNU gettext.
18535         * lib/lock.c: Update from GNU gettext.
18536
18537 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
18538
18539         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
18540         obsolescent AC_TRY_RUN.  Include the default includes files, for
18541         'exit'.
18542
18543 2005-07-24  Bruno Haible  <bruno@clisp.org>
18544
18545         * modules/visibility: New file.
18546         * MODULES.html.sh (Misc): Add visibility.
18547
18548 2005-07-24  Bruno Haible  <bruno@clisp.org>
18549
18550         * m4/visibility.m4: New file.
18551
18552 2005-07-24  Bruno Haible  <bruno@clisp.org>
18553
18554         * doc/visibility.texi: New file.
18555
18556 2005-07-22  Bruno Haible  <bruno@clisp.org>
18557
18558         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
18559         $(ALLOCA_H), redundant through BUILT_SOURCES.
18560         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
18561         redundant through BUILT_SOURCES.
18562         * modules/byteswap (Makefile.am): Remove explicit dependency on
18563         $(BYTESWAP_H), redundant through BUILT_SOURCES.
18564         * modules/fnmatch (Makefile.am): Remove explicit dependency on
18565         $(FNMATCH_H), redundant through BUILT_SOURCES.
18566         * modules/getopt (Makefile.am): Remove explicit dependency on
18567         $(GETOPT_H), redundant through BUILT_SOURCES.
18568         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
18569         redundant through BUILT_SOURCES.
18570         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
18571         redundant through BUILT_SOURCES.
18572         * modules/stdbool (Makefile.am): Remove explicit dependency on
18573         $(STDBOOL_H), redundant through BUILT_SOURCES.
18574         * modules/stdint (Makefile.am): Remove explicit dependency on
18575         $(STDINT_H), redundant through BUILT_SOURCES.
18576         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
18577         Remove explicit dependency on $(SYSEXITS_H).
18578         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
18579
18580 2005-07-18  Simon Josefsson  <jas@extundo.com>
18581
18582         * lib/check-version.c (check_version): Accept identical versions too.
18583
18584 2005-07-18  Bruno Haible  <bruno@clisp.org>
18585
18586         * modules/lock: New file.
18587         * MODULES.html.sh (Multithreading): New section.
18588
18589 2005-07-18  Bruno Haible  <bruno@clisp.org>
18590
18591         * m4/lock.m4: New file, from GNU gettext.
18592
18593 2005-07-18  Bruno Haible  <bruno@clisp.org>
18594
18595         * lib/lock.h: New file, from GNU gettext.
18596         * lib/lock.c: New file, from GNU gettext.
18597
18598 2005-07-18  Bruno Haible  <bruno@clisp.org>
18599
18600         * lib/lock.h (gl_once_t): New type.
18601         (gl_once_define, gl_once): New macros.
18602         * lib/lock.c (fresh_once): New variable.
18603         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
18604         functions.
18605
18606 2005-07-16  Simon Josefsson  <jas@extundo.com>
18607
18608         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
18609         workaround, suggested by Bruno.
18610
18611 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
18612
18613         * modules/xalloc (Depends-on): Add xalloc-die.
18614         * modules/xvasprintf (Depends-on): Add xalloc-die.
18615
18616 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
18617
18618         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
18619         with a minor change.
18620
18621 2005-07-15  Bruno Haible  <bruno@clisp.org>
18622
18623         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
18624         When using lib/poll.c, define poll as rpl_poll.
18625
18626 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
18627
18628         * modules/argp (Depends-on): Remove unlocked-io.
18629
18630 2005-07-14  Derek Price  <derek@ximbiot.com>
18631
18632         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
18633         for glob symlink bug.
18634
18635 2005-07-14  Bruno Haible  <bruno@clisp.org>
18636
18637         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
18638         Instead, test for *_unlocked function declarations directly.
18639
18640 2005-07-11  Simon Josefsson  <jas@extundo.com>
18641
18642         * modules/size_max: New file.
18643
18644         * modules/xsize: Depend on size_max module for size_max.m4.
18645
18646 2005-07-11  Simon Josefsson  <jas@extundo.com>
18647
18648         * lib/size_max.h: New file.
18649
18650 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
18651
18652         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
18653         copyright symbol and the year.
18654         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
18655         (version_etc_va): Use parameterized copyright notice.
18656         Reword to conform to the current GNU coding standards.
18657
18658 2005-07-11  Karl Berry  <karl@gnu.org>
18659
18660         * doc/gnulib.texi (Quoting): new node.
18661         (Initial import): more info, from Patrice.
18662
18663 2005-07-11  Bruno Haible  <bruno@clisp.org>
18664
18665         * gnulib-tool (func_usage): Document option --avoid.
18666         (Command line options): Handle --avoid.
18667         (func_acceptable): New function.
18668         (func_modules_transitive_closure): Use it.
18669
18670 2005-07-11  Bruno Haible  <bruno@clisp.org>
18671
18672         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
18673         Reported by Jim Meyering.
18674
18675 2005-07-10  Bruno Haible  <bruno@clisp.org>
18676
18677         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
18678         Needed when size_t is smaller than 'unsigned int'.
18679         Reported by Paul Eggert.
18680
18681 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
18682
18683         * modules/argp (Depends-on): Add unlocked-io
18684
18685 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
18686
18687         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
18688         block of defines.
18689
18690 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
18691
18692         * config/srclist.txt: Comment out regcomp.c, since we have a porting
18693         fix now.
18694
18695 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
18696         and Paul Eggert  <eggert@cs.ucla.edu>
18697
18698         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
18699         in wint_t, not wchar_t.  Remove now-unnecessary cast.
18700
18701 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18702
18703         * modules/regex (Files): Add lib/regex_internal.c,
18704         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
18705         (Depends-on): Add extensions.
18706         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
18707
18708 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18709
18710         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
18711         pathconf.
18712         * m4/same.m4 (gl_SAME): Likewise.
18713         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
18714
18715         * m4/regex.m4: Adjust to new libc regex implementation.
18716         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
18717         all the .c and .h parts of (the new) regex.
18718         Quote the m4 stuff better.
18719         Check for RE_ICASE bug of old gnulib.
18720         Check for REG_STARTEND of recent libc.
18721         Rename local variables from jm_* to gl_*.
18722         Quote operand of "test -f".
18723         Say "recent enough" version of libc, not "version 2".
18724         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
18725         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
18726         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
18727         Remove check for btowc, isascii.
18728         Require AM_LANGINFO_CODESET.
18729
18730 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18731
18732         * lib/regex.c, regex.h: Sync from libc.
18733         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
18734         * lib/regexec.c:
18735         New files, synced from libc, except that regex_internal.h
18736         currently has a small porting fix.
18737
18738 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
18739
18740         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
18741         regex_internal.c, regexec.c.
18742         Add regex_internal.h too, but as a comment, since the libc version
18743         is currently broken in gnulib mode.
18744
18745 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
18746
18747         Support programs like Emacs that use gnulib but not gettext.
18748         * MODULES.html.sh (Internationalization functions): Add gettext-h.
18749         * modules/gettext-h: New file.
18750         * modules/gettext (Files): Remove lib/gettext.h.
18751         (Depends-on): Add gettext-h.
18752         (Makefile.am): Remove lib_SOURCES.
18753         * modules/argmatch, modules/c-stack, modules/closeout:
18754         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
18755         * modules/execute, modules/file-type, modules/getaddrinfo:
18756         * modules/getopt, modules/human, modules/javacomp:
18757         * modules/javaexec, modules/mkdir-p, modules/obstack:
18758         * modules/openat, modules/pagealign_alloc, modules/pipe:
18759         * modules/quotearg, modules/regex, modules/rpmatch:
18760         * modules/unicodeio, modules/userspec, modules/version-etc:
18761         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
18762         * modules/xsetenv:
18763         Depend on gettext-h, not gettext.
18764
18765 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
18766
18767         * gnulib-tool (func_import): Add support for 'public domain' license.
18768         * modules/alloca, modules/atexit, modules/memmove:
18769         Now public domain, not GPL.
18770         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
18771         * modules/realloc, modules/strerror, modules/strtod:
18772         Now LGPL, not GPL.
18773
18774 2005-07-05  Bruno Haible  <bruno@clisp.org>
18775
18776         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
18777         autoconf CVS. Needed for mingw.
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         * modules/strftime (Depends-on): Remove dependency on tzset.
18783
18784 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
18785
18786         Remove the dependency of the strftime module on the tzset module.
18787         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
18788         gl_FUNC_TZSET_CLOBBER.
18789
18790 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
18791
18792         Remove the dependency of the strftime module on the tzset module.
18793         * lib/strftime.c (my_strftime)
18794         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
18795         Copy the input structure, to work around some of the bug with
18796         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
18797         Solaris releases, you should also use the tzset module, but we won't
18798         require it as a dependency any more since we don't want LGPLed code
18799         to depend on GPLed code.
18800
18801 2005-07-02  Jim Meyering  <jim@meyering.net>
18802
18803         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
18804         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
18805         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
18806         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
18807
18808 2005-07-02  Jim Meyering  <jim@meyering.net>
18809
18810         * lib/backupfile.c (backup_args): Change a `0' to NULL.
18811
18812 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
18813
18814         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
18815         declares only 'struct timespec;' (!).
18816
18817 2005-07-01  Jim Meyering  <jim@meyering.net>
18818
18819         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
18820         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
18821         * lib/save-cwd.c, tempname.c:
18822         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
18823         and don't include <sys/file.h>).
18824
18825 2005-06-29  Jim Meyering  <jim@meyering.net>
18826
18827         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
18828         type name.  Use the variable name instead.
18829         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
18830         Likewise.
18831
18832 2005-06-28  Simon Josefsson  <jas@extundo.com>
18833
18834         * modules/check-version (Files): Add check-version.m4.
18835
18836 2005-06-28  Simon Josefsson  <jas@extundo.com>
18837
18838         * m4/check-version.m4: New file, suggested by Jim Meyering
18839         <jim@meyering.net>.
18840
18841 2005-06-28  Simon Josefsson  <jas@extundo.com>
18842
18843         * lib/check-version.h, lib/check-version.c: New files.
18844
18845 2005-06-28  Simon Josefsson  <jas@extundo.com>
18846
18847         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
18848         collision with global variable.  Better indentation.  Don't
18849         increment buffer pointer beyond buffer end.  Based on comments
18850         from Paul Eggert <eggert@cs.ucla.edu>.
18851
18852         * lib/base64.h: Indent.
18853
18854 2005-06-28  Simon Josefsson  <jas@extundo.com>
18855
18856         * doc/gnulib.texi (Library version handling): New section.
18857
18858 2005-06-28  Jim Meyering  <jim@meyering.net>
18859
18860         * check-module (find_included_lib_files): Hard-code another
18861         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
18862         but modules/fts-lgpl (correctly) does not list those files.
18863
18864         * modules/canonicalize (Files): Add lib/pathmax.h.
18865
18866 2005-06-25  Simon Josefsson  <jas@extundo.com>
18867
18868         * modules/check-version: New file.
18869
18870 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
18871
18872         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
18873         initializer of struct addrinfo, as an indication that we don't
18874         care how many members the structure has.
18875
18876 2005-06-24  Derek Price  <derek@ximbiot.com>
18877         and Bruno Haible  <bruno@clisp.org>
18878
18879         Remove stat module & update lstat.
18880         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
18881         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
18882         * m4/stat.m4: Remove this file.
18883
18884 2005-06-24  Derek Price  <derek@ximbiot.com>
18885         and Bruno Haible  <bruno@clisp.org>
18886
18887         Remove stat module & update lstat.
18888         * lib/stat.c: Remove this file...
18889         (slash_aware_lstat): ...moving this content and its support...
18890         * lib/lstat.c (rpl_lstat): ...into here.
18891         * lib/lstat.h: New file.
18892
18893 2005-06-24  Derek Price  <derek@ximbiot.com>
18894         and Bruno Haible  <bruno@clisp.org>
18895
18896         Remove stat module & update lstat.
18897         * config/srclist.txt (libc sources): Remove stat.
18898
18899 2005-06-24  Derek Price  <derek@ximbiot.com>
18900         and Bruno Haible  <bruno@clisp.org>
18901
18902         Remove stat module & update lstat.
18903         * MODULES.html.sh (stat): Remove.
18904         * MODULES.html: Regenerated.
18905         * modules/lstat (Description): Correct function name.
18906         (Files): Add "lstat.h".
18907         (Depends-on): Remove stat, add xalloc, stat-macros.
18908         * modules/stat: Remove this file.
18909         (Include): Add "lstat.h", remove <sys/stat.h>.
18910
18911 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
18912
18913         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
18914         (ranged_convert): Don't save conversion in a temporary struct.
18915         This causes a warning with GCC 4.0.0, and anyway in the typical
18916         case it's not worth the extra 100 bytes or so of code.
18917         (ranged_convert, __mktime_internal): When calling a function via a
18918         pointer P, use P () rather than (*P) (), as we now assume C89 or
18919         better.
18920
18921 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
18922
18923         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
18924         "who -r" failed to give output.  Problem reported by Tim Waugh.
18925
18926         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
18927         (xcalloc): Use it to avoid needless tests.
18928         Problem reported by Jim Meyering.
18929
18930 2005-06-20  Derek Price  <derek@ximbiot.com>
18931
18932         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
18933         unnecessary for Autoconfs > 2.59c.
18934
18935 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18936
18937         * lib/argp.h (__option_is_short): Check upper limit of
18938         __key. Isprint() requires its argument to have the value
18939         of an unsigned char or EOF.
18940
18941 2005-06-16  Jim Meyering  <jim@meyering.net>
18942
18943         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
18944         when either N or S is zero.
18945
18946 2005-06-16  Derek Price  <derek@ximbiot.com>
18947
18948         * m4/bison.m4: Declare YACC & YFLAGS precious.
18949
18950 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
18951
18952         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
18953         multibyte string or pattern, fall back on unibyte matching.
18954         Problem reported by James Youngman.
18955
18956 2005-06-08  Bruno Haible  <bruno@clisp.org>
18957
18958         * modules/csharpcomp: New file.
18959         * MODULES.html.sh (C#): Add csharpcomp.
18960
18961 2005-06-08  Bruno Haible  <bruno@clisp.org>
18962
18963         * m4/csharpcomp.m4: New file, from GNU gettext.
18964
18965 2005-06-08  Bruno Haible  <bruno@clisp.org>
18966
18967         * lib/csharpcomp.h: New file, from GNU gettext.
18968         * lib/csharpcomp.c: New file, from GNU gettext.
18969         * lib/csharpcomp.sh.in: New file, from GNU gettext.
18970
18971 2005-06-08  Bruno Haible  <bruno@clisp.org>
18972
18973         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
18974         warning on mingw.
18975
18976 2005-06-07  Derek Price  <derek@ximbiot.com>
18977
18978         Sync from CVS.
18979         * lib/glob_.h: Indent nested #ifdef.
18980
18981 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
18982
18983         Sync from coreutils.
18984         Use "file name" when talking about file names, instead of "filename"
18985         or "path", as per the GNU coding standards.
18986         * lib/mkdir-p.c: Renamed from makepath.c.
18987         (make_dir_parents): Renamed from make_path.  All callers changed.
18988         * lib/mkdir-p.h: Likewise.  All includers changed.
18989         * lib/filenamecat.c: Renamed from path-concat.c.
18990         (file_name_concat): Renamed from path_concat.  All callers changed.
18991         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
18992         * lib/filenamecat.h: Likewise.  All includers changed.
18993         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
18994         in comments or local variable names.
18995         * lib/basename.c: Likewise.
18996         * lib/canonicalize.c, canonicalize.h: Likewise.
18997         * lib/dirname.c, dirname.h: Likewise.
18998         * lib/euidaccess.c: Likewise.
18999         * lib/exclude.c: Likewise
19000         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
19001         * lib/fsusage.c, fsuage.h: Likewise.
19002         * lib/fts.c, fts_.h: Likewise.
19003         * lib/getcwd.c: Likewise.
19004         * lib/getloadavg.c: Likewise.
19005         * lib/mkstemp.c: Likewise.
19006         * lib/mountlist.c, mountlist.h: Likewise.
19007         * lib/openat.c, openat.h: Likewise.
19008         * lib/readlink-stub.c: Likewise.
19009         * lib/readutmp.c, readutmp.h: Likewise.
19010         * lib/rename.c: Likewise.
19011         * lib/rmdir.c: Likewise.
19012         * lib/same.c: Likewise.
19013         * lib/savedir.c: Likewise.
19014         * lib/stripslash.c: Likewise.
19015         * lib/tempname.c: Likewise.
19016         * lib/xreadlink.c: Likewise.
19017         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
19018         All uses changed.
19019         * lib/exclude.h: Likewise.
19020
19021         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
19022         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19023         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
19024         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19025         * lib/pathmax.h: Include <limits.h> unconditionally, since other
19026         files have been getting away with it for years (MORE/BSD 4.3
19027         is extinct now).
19028         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
19029         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19030
19031         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
19032         Define to 256, not 255, as per modern POSIX.
19033
19034 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19035
19036         Sync from coreutils.
19037         Use "file name" when talking about file names, instead of "filename"
19038         or "path", as per the GNU coding standards.
19039         * MODULES.html.sh: mkdir-p renamed from makepath.
19040         filenamecat renamed from path-concat.
19041         * modules/filenamecat: Renamed from modules/path-concat.
19042         (Files): filenamecat.h and filenamecat.c renamed from
19043         path-concat.h and path-concat.c.
19044         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
19045         (Include): filenamecat.h, not path-concat.h.
19046         * modules/mkdir-p: Renamed from modules/makepath.
19047         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
19048         makepath.c.
19049         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
19050         (Include): mkdir-p.h, not makepath.h.
19051
19052 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19053
19054         Sync from coreutils.
19055         * m4/mkdir-p.m4: Renamed from makepath.m4.
19056         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
19057         Rename files from makepath.c to mkdir-p.c, and from
19058         makepath.h to mkdir-p.h.
19059         * m4/filenamecat.m4: Renamed from path-concat.m4.
19060         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
19061         Rename files from path-concat.c to filenamecat.c,
19062         and from path-concat.h to filenamecat.h.
19063         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
19064         "file name" in local variables or comments.
19065         * m4/rename.m4: Likewise.
19066
19067 2005-06-01  Bruno Haible  <bruno@clisp.org>
19068
19069         * modules/csharpexec: New file.
19070         * MODULES.html.sh (C#): New section.
19071
19072 2005-06-01  Bruno Haible  <bruno@clisp.org>
19073
19074         * m4/csharp.m4: New file, from GNU gettext.
19075         * m4/csharpexec.m4: New file, from GNU gettext.
19076
19077 2005-06-01  Bruno Haible  <bruno@clisp.org>
19078
19079         * lib/csharpexec.h: New file, from GNU gettext.
19080         * lib/csharpexec.c: New file, from GNU gettext.
19081         * lib/csharpexec.sh.in: New file, from GNU gettext.
19082
19083 2005-05-31  Derek Price  <derek@ximbiot.com>
19084             Paul Eggert  <eggert@cs.ucla.edu>
19085
19086         Sync from cvs.
19087         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19088
19089 2005-05-31  Derek Price  <derek@ximbiot.com>
19090             Paul Eggert  <eggert@cs.ucla.edu>
19091
19092         Sync from cvs.
19093         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19094
19095 2005-05-29  Derek Price  <derek@ximbiot.com>
19096
19097         * config/srclist.txt (glob_.h, glob.c): Add these files.
19098
19099 2005-05-29  Derek Price  <derek@ximbiot.com>
19100
19101         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
19102         * modules/glob: New file.
19103         * modules/getlogin_r: Add link to POSIX spec in description.
19104
19105 2005-05-29  Derek Price  <derek@ximbiot.com>
19106             Paul Eggert  <eggert@cs.ucla.edu>
19107
19108         * m4/glob.m4: New file.
19109
19110 2005-05-29  Derek Price  <derek@ximbiot.com>
19111             Paul Eggert  <eggert@cs.ucla.edu>
19112
19113         * lib/glob_.h, lib/glob.c: New files.
19114
19115 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19116
19117         * modules/fts (Files): Remove m4/inttypes-pri.m4.
19118         * modules/fts-lgpl (Depends-on): Remove gettext.
19119
19120 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19121
19122         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
19123         and don't require gt_INTTYPES_PRI.
19124
19125 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19126
19127         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
19128
19129         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
19130         the configuration hassle isn't worth it.
19131         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
19132         (LONGEST_MODIFIER, PRIuMAX): Remove.
19133
19134 2005-05-27  Bruno Haible  <bruno@clisp.org>
19135
19136         * lib/getlogin_r.h: Remove second include of <stddef.h>.
19137
19138 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
19139
19140         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
19141         _POSIX_PTHREAD_SEMANTICS for Solaris.
19142
19143 2005-05-25  Derek Price  <derek@ximbiot.com>
19144
19145         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
19146
19147 2005-05-25  Derek Price  <derek@ximbiot.com>
19148             Paul Eggert  <eggert@cs.ucla.edu>
19149
19150         * modules/getlogin_r, m4/getlogin_r.m4: New files.
19151         * lib/getlogin_r.c, getlogin_r.h: New files.
19152
19153 2005-05-25  Bruno Haible  <bruno@clisp.org>
19154             Derek Price  <derek@ximbiot.com>
19155
19156         * lib/getlogin_r.h: Simplify API documentation.
19157
19158 2005-05-23  Derek Price  <derek@ximbiot.com>
19159
19160         * modules/minmax (Files): Add m4/minmax.m4.
19161         (configure.ac): Add gl_MINMAX.
19162
19163 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
19164
19165         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
19166         so that unistd-safer.h (GPL'ed code) need not be included.
19167
19168 2005-05-22  Bruno Haible  <bruno@clisp.org>
19169
19170         * m4/minmax.m4: New file.
19171         Based on a patch by Derek Price <derek@ximbiot.com>.
19172
19173 2005-05-22  Bruno Haible  <bruno@clisp.org>
19174
19175         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
19176         (INT64_MIN): Fix definition.
19177         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
19178
19179         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
19180         NEED_SIGNED_INT_TYPES.
19181
19182         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
19183         HAVE_SYSTEM_INTTYPES.
19184
19185 2005-05-22  Bruno Haible  <bruno@clisp.org>
19186
19187         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
19188         Also include <sys/param.h> if it defines MIN, MAX.
19189         Based on a patch by Derek Price <derek@ximbiot.com>.
19190
19191 2005-05-21  Jim Meyering  <jim@meyering.net>
19192
19193         * modules/fts (Files): Add m4/inttypes-pri.m4.
19194         (Depends-on): Add lstat and remove gettext.  Alphabetize.
19195
19196 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19197
19198         New fts module.
19199         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
19200         (setup_dir, free_dir): New functions.
19201         (enter_dir, leave_dir): Define trivial
19202         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
19203         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
19204         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
19205         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
19206         Move to fts-cycle.c.
19207         (fts_open): Use setup_dir.
19208         (fts_close): Use free_dir.
19209         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
19210         This adds a label and some gotos, but the alternatives were messier.
19211         Check for memory allocation failure when entering a dir.
19212         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
19213         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
19214         (FTS): New member fts_cycle, that is a union that contains the
19215         old active_dir_ht and cycle_state.  All uses changed to mention
19216         fts_cycle.ht and fts_cycle.state.
19217         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
19218         fts.c, with the following changes:
19219         (setup_dir, free_dir): New functions.
19220         (enter_dir): Now returns bool.  Return true if successful, false
19221         if memory exhausted.  All callers changed.
19222         Do not bother partly cleaning up on
19223         memory allocation failure; that is free_dir's job.
19224         However, free ad if hash_insert fails, to avoid memory leak.
19225         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
19226         fts->fts_options to see which union member to use.
19227
19228 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19229
19230         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
19231         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
19232
19233 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19234
19235         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
19236
19237 2005-05-20  Jim Meyering  <jim@meyering.net>
19238
19239         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
19240         Now a macro, to pacify GCC.
19241
19242 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19243
19244         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
19245         of -1.
19246
19247 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19248
19249         * lib/chown.c (rpl_chown): Return -1 on failure.
19250
19251 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19252
19253         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
19254         Don't check for stddef.h.
19255         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
19256         don't use its results.
19257         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
19258         since we include them unconditionally.  Don't require
19259         AM_STDBOOL_H, since stdbool is a prerequisite.
19260         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
19261         since we assume C89 or better.
19262         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
19263         as we don't use their results.
19264         Don't check for fchdir, memmove, memset, strrchr, as we use
19265         them unconditionally.
19266         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
19267         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
19268
19269 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19270
19271         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
19272         Include <stddef.h> unconditionally, since we assume C89 now.
19273         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
19274         * lib/fts.c: Include fts_.h first, to check interface.
19275         Do not include intprops.h; no longer needed.
19276         Include cycle-check.h and hash.h, since fts_.h no longer does.
19277         Remove unnecessary casts of closedir to void.
19278         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
19279         decide whether to decrement nlinks.
19280         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
19281         (FTS): Use struct hash_table * instead of Hash_table, so that
19282         we no longer need to include hash.h here.
19283
19284 2005-05-18  Jim Meyering  <jim@meyering.net>
19285
19286         * modules/dirfd (License): Change to LGPL.  Most of the code
19287         is already in the public domain.
19288
19289 2005-05-18  Jim Meyering  <jim@meyering.net>
19290
19291         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
19292         Reported by Yoann Vandoorselaere.
19293
19294 2005-05-17  Jim Meyering  <jim@meyering.net>
19295
19296         * m4/fts.m4: New file, from coreutils.
19297
19298 2005-05-17  Jim Meyering  <jim@meyering.net>
19299
19300         * lib/fts.c, lib/fts_.h: New files, from coreutils.
19301
19302 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19303
19304         Sync from coreutils.
19305         * m4/unlinkdir.m4: New file.
19306
19307 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19308
19309         Sync from coreutils.
19310         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
19311         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
19312         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
19313         White space changes only.
19314         * lib/makepath.c (make_path): Port to hosts where leading "//" is
19315         special.
19316         * lib/yesno.c: Include getline.h, not ctype.h.
19317         (yesno): Don't remove leading white space; POSIX doesn't allow it.
19318         Use getline to remove arbitrary restriction on response length.
19319
19320 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19321
19322         * config/srclist-update: Spell out "Street" in FSF postal
19323         mail address; this is the style the FSF seems to prefer.
19324
19325         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
19326         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
19327         this updates FSF postal mail address.
19328
19329         Sync from coreutils.
19330         * modules/unlinkdir: New file.
19331         * modules/yesno (Depends-on): Add getline.
19332         * MODULES.html.sh (File system functions): Add unlinkdir.
19333
19334 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19335
19336         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
19337         lib/strsep.h:
19338         Change the initial comment to refer to GPL, not LGPL.
19339         gnulib-tool will change it to LGPL as needed.
19340
19341         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
19342         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
19343         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
19344         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
19345         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
19346         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
19347         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
19348         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
19349         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
19350         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
19351         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
19352         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
19353         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
19354         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
19355         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
19356         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
19357         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
19358         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
19359         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
19360         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
19361         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
19362         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
19363         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
19364         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
19365         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
19366         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
19367         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
19368         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
19369         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
19370         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
19371         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
19372         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
19373         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
19374         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
19375         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
19376         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
19377         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
19378         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
19379         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
19380         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
19381         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
19382         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
19383         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
19384         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
19385         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
19386         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
19387         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
19388         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
19389         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
19390         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
19391         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
19392         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
19393         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
19394         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
19395         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
19396         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
19397         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
19398         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
19399         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
19400         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
19401         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
19402         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
19403         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
19404         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
19405         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
19406         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
19407         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
19408         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
19409         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
19410         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
19411         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
19412         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
19413         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
19414         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
19415         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
19416         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
19417         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
19418         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
19419         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
19420         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
19421         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
19422         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
19423         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
19424         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
19425         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
19426         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
19427         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
19428         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
19429         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
19430         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
19431         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
19432         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
19433         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
19434         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
19435         lib/yesno.c, lib/yesno.h:
19436         Update FSF postal mail address.
19437
19438 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19439
19440         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
19441         tests/test-memmem.c, tests/test-stpncpy.c:
19442         Update FSF postal mail address.
19443
19444 2005-05-13  Bruno Haible  <bruno@clisp.org>
19445
19446         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
19447         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
19448         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
19449         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
19450         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
19451         Add support for 64-bit integers in the MSVC compiler.
19452
19453 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19454
19455         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
19456
19457 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
19458
19459         * gnulib-tool (func_import): Sort and uniquify recommended includes.
19460
19461 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
19462
19463         * doc/getdate.texi (General date syntax): Don't say that date
19464         date --iso-8601=ns generates acceptable dates; it doesn't yet.
19465         Problem reported by Nic Ferrier.
19466
19467 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19468
19469         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
19470         specified in ai_socktype. Fix invalid ai_protocol
19471         check. ai_protocol is usually set to 0 or depending on
19472         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
19473         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
19474         ai_socktype / ai_protocol in the returned addrinfo structure.
19475
19476 2005-05-10  Simon Josefsson  <jas@extundo.com>
19477
19478         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
19479         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
19480
19481 2005-05-10  Karl Berry  <karl@gnu.org>
19482
19483         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
19484         (from http://www.gnu.org/licenses).
19485         * doc/COPYING.LIB: also rename to COPYING.LESSER.
19486         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
19487         fdl.texi suffices.
19488
19489 2005-05-10  Karl Berry  <karl@gnu.org>
19490
19491         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
19492         (COPYING.DOC): remove.
19493
19494         * config/srclist-update: new FSF address.
19495
19496 2005-05-10  Derek Price  <derek@ximbiot.com>
19497
19498         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
19499         possible.
19500
19501 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19502             Bruno Haible  <bruno@clisp.org>
19503
19504         * modules/inet_ntop: New file.
19505         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19506         inet_ntop.
19507
19508 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19509             Bruno Haible  <bruno@clisp.org>
19510
19511         * m4/inet_ntop.m4: New file.
19512
19513 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19514             Bruno Haible  <bruno@clisp.org>
19515
19516         * lib/inet_ntop.h: New file.
19517         * lib/inet_ntop.c: New file, from glibc with modifications.
19518
19519 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
19520
19521         * modules/time_r (License): Change to LGPL.
19522         * modules/extensions (License): Change to LGPL.  Actually,
19523         the license is more permissive than that, but currently gnulib-tool
19524         doesn't know how to handle more-permissive licenses.
19525
19526         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
19527         Problem reported by Dave Love.
19528
19529 2005-05-08  Jim Meyering  <jim@meyering.net>
19530
19531         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
19532         blank.
19533
19534 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
19535
19536         * modules/argmatch (Depends-on): Add stdbool.
19537         * modules/backupfile (Depends-on): Likewise.
19538         * modules/chdir-long (Depends-on): Likewise.
19539         * modules/closeout (Depends-on): Likewise.
19540         * modules/cycle-check (Depends-on): Likewise.
19541         * modules/dirname (Depends-on): Likewise.
19542         * modules/fnmatch (Depends-on): Likewise.
19543         * modules/fsusage (Depends-on): Likewise.
19544         * modules/fwriteerror (Depends-on): Likewise.
19545         * modules/getcwd (Depends-on): Likewise.
19546         * modules/getloadavg (Depends-on): Likewise.
19547         * modules/hard-locale (Depends-on): Likewise.
19548         * modules/makepath (Depends-on): Likewise.
19549         * modules/mountlist (Depends-on): Likewise.
19550         * modules/nanosleep (Depends-on): Likewise.
19551         * modules/posixtm (Depends-on): Likewise.
19552         * modules/quotearg (Depends-on): Likewise.
19553         * modules/readtokens (Depends-on): Likewise.
19554         * modules/readtokens0 (Depends-on): Likewise.
19555         * modules/readutmp (Depends-on): Likewise.
19556         * modules/save-cwd (Depends-on): Likewise.
19557         * modules/strftime (Depends-on): Likewise.
19558         * modules/userspec (Depends-on): Likewise.
19559         * modules/utimecmp (Depends-on): Likewise.
19560         * modules/xgetcwd (Depends-on): Likewise.
19561         * modules/xnanosleep (Depends-on): Likewise.
19562         * modules/xstrtod (Depends-on): Likewise.
19563         * modules/yesno (Depends-on): Likewise.
19564
19565 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
19566
19567         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
19568         needless checks.
19569
19570 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19571
19572         Merge from coreutils.  Among other things,
19573         add bulletproofing for cases where stdin, stdout, or stderr are closed.
19574         * lib/fd-safer.c: New file.
19575         * lib/fcntl-safer.h, open-safer.c: Remove.
19576         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
19577         * lib/dup-safer.c: Include unistd-safer.h first.
19578         Don't include errno.h.
19579         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
19580         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
19581         * lib/file-type.c: Rely on file-type.h change.
19582         * lib/getloadavg.c: Include unistd-safer.h.
19583         (getloadavg): Use safer open.
19584         * lib/getusershell.c: Include "stdio-safer.h".
19585         (getusershell): Use safer fopen.
19586         * lib/long-options.c (long_options): Use NULL rather than 0.
19587         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
19588         'free'.
19589         * lib/modechange.c: Likewise.
19590         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
19591         (MODE_DONE): New constant.
19592         (struct mode_change): Remove 'next' member.
19593         (make_node_op_equals): New function; like the old one of the
19594         same name, except it allocates an array.
19595         (mode_compile, mode_create_from_ref): Use it.
19596         (mode_compile): Allocate result as an array, not a linked list.
19597         Parse octal string ourself, so that we catch mistakes like "+0".
19598         (mode_adjust): Arg is an array, not a linked list.
19599         * lib/modechange.c: Include stat-macros.h, xalloc.h.
19600         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
19601         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
19602         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
19603         Remove.  This is now stat-macros.h's job.
19604         (talloc): Remove.  All callers replaced by xalloc, so that
19605         our invokers don't have to worry about reporting memory failures.
19606         (make_node_op_equals): Remove.
19607         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
19608         New constants.
19609         (struct mode_change): Moved here from modechange.h.
19610         (mode_append_entry): Remove.
19611         (mode_compile): Remove MASKED_OPS arg, since it encouraged
19612         apps to have incorrect behavior.  Use simpler algorithm for head
19613         and tail.  Don't futz with umask; that's now the job of mode_adjust.
19614         Detect more invalid usages rather than having somewhat-random behavior.
19615         Don't insert an "a=" action, as that leads to incorrect behavior.
19616         (mode_compile, mode_create_from_ref): Return NULL on error instead
19617         of an enum, since now there's only one way to have an error.  All
19618         callers changed.
19619         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
19620         at the correct time.  Simplify calculation of "+u" and its ilk.
19621         Don't mishandle "+X".
19622         (mode_free): Remove "register" and localize decls.
19623         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
19624         (struct mode_change): Move to modechange.c; callers don't
19625         need to see this stuff.
19626         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
19627         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
19628         (mode_change, mode_adjust): Reflect the new signatures noted above.
19629         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
19630         that might redefine system include files.
19631         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
19632         (my_usleep): Use NULL rather than (void *) 0.
19633         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
19634         Use siginterrupt to specify that system calls should be interrupted.
19635         (rpl_nanosleep): Move initialization of suspended closer to call of
19636         my_usleep.
19637         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
19638         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
19639         (desirable_utmp_entry): New function.
19640         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
19641         using x2nrealloc, to simplify logic.
19642         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
19643         size calculation.  Do not assume utmp file is a regular file.
19644         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
19645         (READ_UTMP_CHECK_PIDS): New constant.
19646         * lib/save-cwd.c: Include unistd-safer.h.
19647         (save_cwd): Use fd_safer.
19648         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
19649         [!_LIBC] Include "stat-macros.h" instead.
19650         * lib/unistd-safer.h (fd_safer): New decl.
19651
19652 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19653
19654         * modules/getloadavg (Depends-on): Add unistd-safer.
19655         * modules/getusershell (Depends-on): Add stdio-safer.
19656         * modules/lstat (Depends-on): Remove xalloc.
19657         * modules/mkstemp (Depends-on): Add stat-macros.
19658         * modules/modechange (Depends-on): Remove xstrtol.
19659         Add stat-macros, xalloc.
19660         * modules/save-cwd (Depends-on): Add unistd-safer.
19661         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
19662         * modules/unistd-safer (Files): Add lib/fd-safer.c
19663         (Makefile.am): Remove lib_SOURCES.
19664
19665         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
19666         Remove fcntl-safer; unistd-safer supersedes it.
19667
19668 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19669
19670         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
19671         AC_HEADER_STAT.
19672         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
19673         (gl_PREREQ_CHOWN): Remove.
19674         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
19675         it.  Don't require AC_HEADER_STAT.
19676         (gl_PREREQ_LSTAT): Remove.
19677         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
19678         Don't require AC_HEADER_STAT.
19679         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
19680         (gl_PREREQ_RMDIR): Remove.
19681         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
19682         mention stat-macros.h or AC_HEADER_STAT, since we'll make
19683         the stat-macros module a prerequisite.
19684         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
19685         * m4/filemode.m4 (gl_FILEMODE): Likewise.
19686         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
19687         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
19688         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
19689         variable names.
19690         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
19691         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
19692         variable prefixes.
19693         * m4/fcntl-safer.m4: Remove.
19694         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
19695         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
19696         Invoke gl_PREREQ_FD_SAFER.
19697         (gl_PREREQ_FD_SAFER): New macro.
19698         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
19699         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
19700         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
19701         Remove duplicate call to AC_LIBOBJ(readutmp).
19702         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
19703
19704         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
19705         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
19706
19707 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
19708
19709         * MODULES.html.sh (Misc): Add byteswap.
19710
19711 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19712
19713         * modules/getcwd (Depends-on): Add extensions.
19714         * modules/openat (Depends-on): Likewise.
19715
19716 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19717
19718         * modules/byteswap: New file.
19719
19720 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19721
19722         * m4/byteswap.m4: New file.
19723
19724 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
19725
19726         * lib/byteswap_.h: New file.
19727
19728 2005-04-25  Karl Berry  <karl@gnu.org>
19729
19730         * m4/gettext.m4: Update from GNU gettext 0.14.4.
19731
19732 2005-04-25  Albert Chin  <china@thewrittenword.com>
19733
19734         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
19735         Toolkit C bug.
19736
19737 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
19738
19739         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
19740         (func_ln_if_changed) Remove forcibly for no error message
19741         in case file does not exist.
19742
19743 2005-04-19  Simon Josefsson  <jas@extundo.com>
19744
19745         * gnulib-tool (Options): Make --symlink mean --symbolic.
19746
19747 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
19748
19749         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
19750
19751 2005-04-16  Simon Josefsson  <jas@extundo.com>
19752
19753         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
19754
19755 2005-04-15  Simon Josefsson  <jas@extundo.com>
19756
19757         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
19758
19759 2005-04-15  Simon Josefsson  <jas@extundo.com>
19760
19761         * gnulib-tool: Rename --symlink to --symbolic.
19762
19763 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
19764
19765         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
19766         symbolic links to files instead of copying/moving.  Add --aux-dir,
19767         specifying directory relative --dir where auxiliary build tools
19768         are placed.
19769
19770 2005-04-14  Bruno Haible  <bruno@clisp.org>
19771
19772         * modules/allocsa (License): Change to LGPL.
19773         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
19774
19775 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
19776
19777         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
19778         that "UTC +1 second" continues to work.  Problem reported
19779         by Dmitry V. Levin.
19780         (relunit_snumber): New rule.
19781         (relunit): Use it.
19782
19783 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
19784
19785         * lib/getdate.y (universal_time_zone_table): New constant.
19786         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
19787         universal_time_zone_table.
19788         (lookup_zone): Prefer universal_time_zone_table to
19789         local_time_zone_table, so that "GMT" time stamps are allowed in
19790         London during the summer.  Problem reported by Ian Abbott.
19791
19792 2005-04-12  Jim Meyering  <jim@meyering.net>
19793
19794         * lib/human.c (humblock): Set *options even when returning due to
19795         xstrtoumax conversion failure.  Thanks to a used-uninitialized
19796         warning from gcc-4.
19797
19798 2005-04-09  Jim Meyering  <jim@meyering.net>
19799
19800         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
19801         -Wuninitialized: initialize tm0.tm_year.
19802
19803 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
19804
19805         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
19806         count, since there's no maximum.  All uses changed.
19807         Add member dsts_seen.
19808         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
19809         not being INT_MAX.
19810         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
19811         Use pc_rels_seen to decide whther a date is absolute.
19812
19813         * lib/getdate.y (number): Don't overwrite year.
19814         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
19815         check.
19816
19817 2005-04-02  Simon Josefsson  <jas@extundo.com>
19818
19819         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
19820         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
19821
19822 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
19823
19824         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
19825         where no absolute path name can be longer than PATH_MAX.
19826
19827 2005-03-27  Jim Meyering  <jim@meyering.net>
19828
19829         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
19830
19831 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
19832
19833         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
19834         "one's complement" -> "ones' complement" in comment, as per Knuth.
19835         "value of type" -> "type or expression" in comment.
19836         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
19837
19838 2005-03-26  Jim Meyering  <jim@meyering.net>
19839
19840         Comment nits.
19841         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
19842         Correct typos: s/or/of/.
19843
19844 2005-03-26  Jim Meyering  <jim@meyering.net>
19845
19846         * modules/check-include-files: Move to ../ and rename to...
19847         * check-module: ...this.
19848
19849 2005-03-25  Jim Meyering  <jim@meyering.net>
19850
19851         * modules/xvasprintf (Files): Add xalloc.h.
19852
19853 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
19854
19855         * modules/gettext (Files): config/config.rpath ->
19856         build-aux/config.rpath
19857         * modules/iconv (Files): Likewise.
19858         Problem reported by Oskar Liljeblad.
19859
19860 2005-03-23  Jim Meyering  <jim@meyering.net>
19861
19862         * modules/check-include-files: New script to check for
19863         missing dependencies, multiple includes, etc.
19864
19865         * modules/c-strtold (Depends-on): Add xalloc.
19866         * modules/c-strtod (Depends-on): Add xalloc.
19867         * modules/hash (Depends-on): Add xalloc.
19868         (Files): Remove lib/xalloc.h.
19869
19870         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
19871         * modules/userspec (Files): Add lib/inttostr.h.
19872
19873 2005-03-23  Jim Meyering  <jim@meyering.net>
19874
19875         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
19876
19877 2005-03-22  Jim Meyering  <jim@meyering.net>
19878
19879         * modules/stat-macros: New module.
19880         * modules/canonicalize, modules/euidaccess, modules/file-type,
19881         * modules/filemode, modules/lchown, modules/makepath,
19882         * modules/rmdir, modules/stat: Depend on new stat-macros module
19883         rather than listing lib/stat-macros.h manually.
19884         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
19885
19886 2005-03-22  Jim Meyering  <jim@meyering.net>
19887
19888         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
19889
19890 2005-03-22  Bruno Haible  <bruno@clisp.org>
19891
19892         * config/srclist.txt: Replace target directory 'config' with
19893         'build-aux'.
19894         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
19895         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
19896         ../build-aux/.
19897
19898 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
19899
19900         * modules/chdir-long (Depends-on): Add mempcpy.
19901
19902         * modules/acl, modules/backupfile, modules/c-strtod,
19903         modules/c-strtold, modules/canon-host, modules/canonicalize,
19904         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
19905         modules/exclude, modules/exitfail, modules/file-type,
19906         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
19907         modules/getdate, modules/getline, modules/getpagesize,
19908         modules/getpass, modules/getugroups, modules/group-member,
19909         modules/hard-locale, modules/hash, modules/human, modules/idcache,
19910         modules/inttostr, modules/long-options, modules/makepath,
19911         modules/md5, modules/memcasecmp, modules/memcoll,
19912         modules/modechange, modules/mountlist, modules/path-concat,
19913         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
19914         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
19915         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
19916         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
19917         modules/strftime, modules/strndup, modules/strverscmp,
19918         modules/timespec, modules/unlocked-io, modules/userspec,
19919         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
19920         modules/yesno:
19921         Remove lib_SOURCES line from Makefile.am section, as this is now
19922         done automatically by the corresponding Autoconf macro.
19923
19924 2005-03-21  Jim Meyering  <jim@meyering.net>
19925
19926         Changes imported from coreutils.
19927
19928         * lib/cycle-check.c: Don't include xalloc.h.
19929
19930         * lib/path-concat.c: Don't include assert.h.
19931         (path_concat): Remove assertion that would have triggered
19932         for ABASE starting with more than one slash.
19933         Reported by Andreas Schwab.
19934
19935         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
19936         properly when ABASE is an absolute file name.
19937         Correct the description of this function.
19938         Include <assert.h>.
19939         Add an assertion and a test driver.
19940         This fixes a bug introduced on 2004-07-02.
19941         Andreas Schwab reported the resulting failure of cp --parents:
19942         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
19943
19944 2005-03-21  Jim Meyering  <jim@meyering.net>
19945
19946         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
19947         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
19948
19949 2005-03-21  Jim Meyering  <jim@meyering.net>
19950         and  Paul Eggert  <eggert@cs.ucla.edu>
19951
19952         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
19953         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
19954         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
19955         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
19956         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
19957         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
19958         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
19959         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
19960         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
19961         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
19962         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
19963         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
19964         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
19965         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
19966         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
19967         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
19968         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
19969         for these modules.
19970
19971 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
19972
19973         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
19974         (which shouldn't happen), generate nothing instead of returning 0
19975         immediately, so that nstrftime (NULL, ...) doesn't return 0.
19976
19977 2005-03-16  Bruno Haible  <bruno@clisp.org>
19978
19979         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
19980         HAVE_LONGLONG_64BIT.
19981
19982 2005-03-16  Bruno Haible  <bruno@clisp.org>
19983
19984         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
19985         HAVE_LONGLONG_64BIT.
19986
19987 2005-03-16  Bruno Haible  <bruno@clisp.org>
19988
19989         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
19990         HAVE_LONGLONG_64BIT.
19991
19992 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
19993
19994         * lib/strftime.c (my_strftime): Prepend space to format so that we can
19995         reliably distinguish strftime failure from empty output on POSIX
19996         hosts.
19997
19998 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
19999
20000         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
20001         (iconv_string): Don't guess a size-zero buffer, as that might cause
20002         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
20003         result would be 'too large', where 'too large' is (heuristically)
20004         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
20005         overflow concerns.  This will prevent some unwanted malloc failures
20006         when the inputs are very large.
20007
20008 2005-03-15  Karl Berry  <karl@gnu.org>
20009
20010         * config/srclist.txt (config.rpath): from gettext.
20011         * config/config.rpath: update.
20012
20013 2005-03-15  Bruno Haible  <bruno@clisp.org>
20014
20015         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
20016         to 'negate'.
20017
20018         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
20019         variable.
20020
20021         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
20022         results.
20023
20024 2005-03-14  Simon Josefsson  <jas@extundo.com>
20025
20026         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
20027         <fx@gnu.org>.
20028
20029 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
20030
20031         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
20032         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
20033         intprops.h.
20034         * lib/strtol.c: Likewise.
20035
20036 2005-03-14  Jim Meyering  <jim@meyering.net>
20037
20038         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
20039         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
20040         to be nonzero so that we (and caller) can detect the difference
20041         between a valid zero-length expansion and an error return, even
20042         when the underlying strftime fails before writing anything into
20043         that location.
20044
20045 2005-03-14  Bruno Haible  <bruno@clisp.org>
20046
20047         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
20048         Update from GNU gettext 0.14.3.
20049
20050 2005-03-10  Jim Meyering  <jim@meyering.net>
20051
20052         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
20053
20054 2005-03-10  Jim Meyering  <jim@meyering.net>
20055
20056         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
20057         so that this module works on systems without fchdir.
20058
20059 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
20060
20061         Factor int-properties macros into a single file, except for
20062         glibc-related files.
20063         * lib/intprops.h: New file.
20064         * lib/getloadavg.c: Include it instead of limits.h.
20065         (INT_STRLEN_BOUND): Remove.
20066         * lib/human.c: Include intprops.h.
20067         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
20068         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
20069         302/1000.
20070         * lib/inttostr.h: Include intprops.h instead of limits.h.
20071         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
20072         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
20073         for consistency with intprops.h.
20074         (time_t_is_integer, twos_complement_arithmetic): Use them.
20075         * lib/sig2str.h: Include <signal.h>, intprops.h.
20076         (INT_STRLEN_BOUND): Remove.
20077         * lib/strftime.c (TYPE_SIGNED): Remove.
20078         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
20079         * lib/strtol.c: Adjust comments to match intprops.h.
20080         * lib/userspec.c: Include intprops.h.
20081         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
20082         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
20083         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
20084         instead of rolling our own expressions.
20085         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
20086
20087         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
20088         instead of int.
20089         (my_strftime): Do not mishandle years close to INT_MAX, by doing
20090         the right thing even if adding 1900 would overflow.  Similarly
20091         for tm_mon + 1 and tm_yday + 1.
20092         Make %Y always equivalent to %C%y, and similarly for %G and %g.
20093         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
20094         (DO_SIGNED_NUMBER): New macro.
20095         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
20096
20097 2005-03-07  Bruno Haible  <bruno@clisp.org>
20098
20099         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
20100
20101 2005-03-07  Bruno Haible  <bruno@clisp.org>
20102
20103         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
20104
20105 2005-03-04  Derek R. Price  <derek@ximbiot.com>
20106
20107         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
20108         (func_import): Only replace files via --import when they have actually
20109         changed.
20110
20111 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20112
20113         * m4/mmap-anon.m4: New file.
20114         * m4/pagealign_alloc.m4: New file.
20115
20116 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20117             Bruno Haible  <bruno@clisp.org>
20118
20119         * modules/pagealign_alloc: New file.
20120         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
20121
20122 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20123             Bruno Haible  <bruno@clisp.org>
20124
20125         * lib/pagealign_alloc.h: New file.
20126         * lib/pagealign_alloc.c: New file.
20127
20128 2005-03-03  Bruno Haible  <bruno@clisp.org>
20129
20130         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
20131         Use an all-permissive copyright notice, recommended by RMS.
20132
20133 2005-03-02  Bruno Haible  <bruno@clisp.org>
20134
20135         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
20136         of AIX, the replacement has to be done only after <string.h> is
20137         included, therefore not in config.h. stpncpy.h does the replacement,
20138         and stpncpy.c uses it.
20139
20140 2005-03-02  Bruno Haible  <bruno@clisp.org>
20141
20142         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
20143         stpncpy.c uses it.
20144
20145 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20146
20147         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
20148         The workaround isn't strictly needed for POSIX conformance, and
20149         it's too much of a pain to configure and maintain.  We'll ask
20150         people to fix their kernels instead.
20151         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
20152         (NANOSLEEP_BUG_WORKAROUND): Remove.
20153         (xnanosleep): Remove the workaround.
20154
20155 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20156
20157         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
20158         Reported by Derek Price.
20159         (Include): Add "timespec.h".
20160
20161         * modules/xnanosleep (Depends-on): Remove gethrxtime.
20162
20163 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20164
20165         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
20166         to detect nanosleep bug.
20167
20168 2005-03-01  Bruno Haible  <bruno@clisp.org>
20169
20170         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
20171
20172 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
20173
20174         * modules/gethrxtime: New file.
20175         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
20176         (Depends-on): Add gethrxtime.
20177         (configure.ac): Add gl_XNANOSLEEP.
20178         (Makefile.am): Remove lib_SOURCES line.
20179
20180 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20181
20182         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
20183         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
20184
20185 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20186
20187         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
20188         * lib/timespec.h (gettime): Return void, since it always
20189         succeeds now.  All uses changed.
20190         * lib/gettime.c (gettime) Likewise.
20191         [HAVE_NANOTIME]: Prefer nanotime.
20192         Assume gettimeofday succeeds, as POSIX requires.
20193         Assime time () succeeds, since other code already does.
20194         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
20195         (timespec_subtract): Remove.
20196         (NANOSLEEP_BUG_WORKAROUND): New constant.
20197         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
20198         things considerably.  Use it only on GNU/Linux hosts, since the
20199         workaround shouldn't be needed elsewhere.
20200
20201 2005-02-24  Bruno Haible  <bruno@clisp.org>
20202
20203         * modules/gettext (Files): Add m4/glibc2.m4.
20204
20205 2005-02-24  Bruno Haible  <bruno@clisp.org>
20206
20207         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
20208         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
20209         * m4/progtest.m4:
20210         Update from GNU gettext 0.14.2.
20211         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
20212
20213 2005-02-24  Bruno Haible  <bruno@clisp.org>
20214
20215         * lib/localcharset.c: Update from GNU gettext 0.14.2.
20216         * lib/config.charset: Update from GNU gettext 0.14.2.
20217
20218 2005-02-24  Bruno Haible  <bruno@clisp.org>
20219
20220         * lib/gettext.h: Update from GNU gettext 0.14.2.
20221
20222 2005-02-23  Simon Josefsson  <jas@extundo.com>
20223
20224         * m4/iconvme.m4: New file.
20225
20226 2005-02-23  Jim Meyering  <jim@meyering.net>
20227
20228         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
20229         change.
20230         Thanks to Bruno Haible for catching it.
20231
20232 2005-02-22  Simon Josefsson  <jas@extundo.com>
20233
20234         * modules/iconvme: New file.
20235
20236         * MODULES.html.sh: Add iconvme.
20237
20238 2005-02-22  Simon Josefsson  <jas@extundo.com>
20239
20240         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
20241
20242 2005-02-22  Simon Josefsson  <jas@extundo.com>
20243
20244         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
20245
20246 2005-02-22  Jim Meyering  <jim@meyering.net>
20247
20248         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
20249         s/ifndef/ifdef/.
20250
20251 2005-02-20  Neil Conway  <neilc@samurai.com>
20252
20253         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
20254         returned by OSX/Darwin if the specified buffer is not large
20255         enough for the hostname.
20256
20257 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20258
20259         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
20260         pass it to _help, otherwise the latter coredumps trying to
20261         dereference state.root_argp.
20262
20263 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20264
20265         * modules/chdir-long (Depends-on): Add memrchr.
20266         * modules/memrchr (Files): Add lib/memrchr.h.
20267         (Include): "memrchr.h".
20268
20269 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20270
20271         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
20272
20273 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20274
20275         * lib/memrchr.h: New file.
20276         * lib/chdir-long.c: Include it.
20277         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
20278         Don't bother including stddef.h.
20279
20280 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
20281
20282         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
20283         inclusion.
20284         Include <sys/types.h>, for dev_t.
20285         (ME_DUMMY, ME_REMOTE): Move from here....
20286         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
20287         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
20288         Dmitry V. Levin.
20289         Include mountlist.h first, to test the interface.
20290
20291 2005-01-29  Bruno Haible  <bruno@clisp.org>
20292
20293         * lib/progname.c (program_name): Initialize.
20294         Needed when linking statically on MacOS X.
20295
20296 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20297
20298         Sync from coreutils.
20299         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
20300         (Depends-on): Add c-strtod.
20301         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
20302
20303 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20304
20305         Sync from coreutils.
20306         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
20307
20308         Remove files that are specific to coreutils.
20309         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
20310
20311 2005-01-28  Bruno Haible  <bruno@clisp.org>
20312
20313         * modules/javacomp: New file.
20314         * MODULES.html.sh (Java): Add javacomp.
20315
20316 2005-01-28  Bruno Haible  <bruno@clisp.org>
20317
20318         * m4/javacomp.m4: New file, from GNU gettext.
20319
20320 2005-01-28  Bruno Haible  <bruno@clisp.org>
20321
20322         * lib/javacomp.sh.in: New file, from GNU gettext.
20323         * lib/javacomp.h: New file, from GNU gettext.
20324         * lib/javacomp.c: New file, from GNU gettext.
20325
20326 2005-01-26  Simon Josefsson  <jas@extundo.com>
20327
20328         * lib/gai_strerror.c: Use GPL in header.
20329
20330 2005-01-26  Bruno Haible  <bruno@clisp.org>
20331
20332         * modules/javaexec: New file.
20333         * MODULES.html.sh (Java): Add javaexec.
20334
20335 2005-01-26  Bruno Haible  <bruno@clisp.org>
20336
20337         * m4/javaexec.m4: New file, from GNU gettext.
20338
20339 2005-01-26  Bruno Haible  <bruno@clisp.org>
20340
20341         * lib/javaexec.sh.in: New file, from GNU gettext.
20342         * lib/javaexec.h: New file, from GNU gettext.
20343         * lib/javaexec.c: New file, from GNU gettext.
20344
20345 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20346
20347         * modules/lchown (Depends-on): Remove lchown.h
20348
20349 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20350
20351         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
20352         must be defined if the header file was not found, in order
20353         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
20354
20355 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20356
20357         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
20358         initializers for struct pentry_state.
20359         (__argp_error): Check return value of __asprintf
20360         (__argp_failure): Translate error message
20361
20362         * lib/argp-parse.c: Removed braces around the expansion of N_()
20363
20364 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
20365
20366         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
20367         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
20368         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
20369         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
20370         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
20371         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
20372         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
20373         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
20374         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
20375         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
20376         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
20377         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
20378         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
20379         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
20380         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
20381         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
20382         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
20383         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
20384         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
20385         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
20386         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
20387         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
20388         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
20389         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
20390         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
20391         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
20392         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
20393         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
20394         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
20395         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
20396         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
20397         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
20398         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
20399         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
20400         xstrtol.m4, xstrtoumax.m4, yesno.m4:
20401         Use an all-permissive copyright notice, recommended by RMS.
20402
20403 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
20404
20405         * modules/chdir-long (Depends-on): Remove mempcpy.
20406
20407 2005-01-21  Jim Meyering  <jim@meyering.net>
20408
20409         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
20410         same value as for Solaris 9.
20411
20412         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
20413         component length.  This included changing the parameter to be
20414         of type `char *' rather than `char const *'.
20415         * lib/chdir-long.h (chdir_long): Update prototype.
20416
20417         * lib/openat.c (fdopendir, fstatat): New functions.
20418         * lib/openat.h: Include headers required for use of DIR and struct
20419         stat.
20420         [AT_SYMLINK_NOFOLLOW]: Define.
20421         (fdopendir, fstatat): Add prototypes.
20422
20423 2005-01-21  Bruno Haible  <bruno@clisp.org>
20424
20425         * modules/classpath: New file.
20426         * MODULES.html.sh (Java): Add classpath.
20427
20428 2005-01-21  Bruno Haible  <bruno@clisp.org>
20429
20430         * lib/classpath.h: New file, from GNU gettext.
20431         * lib/classpath.c: New file, from GNU gettext.
20432
20433 2005-01-20  Simon Josefsson  <jas@extundo.com>
20434
20435         * modules/version-etc-fsf: New file.
20436
20437 2005-01-20  Simon Josefsson  <jas@extundo.com>
20438
20439         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
20440         * lib/version-etc.c: Remove version_etc_copyright.
20441         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
20442         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
20443
20444 2005-01-20  Simon Josefsson  <jas@extundo.com>
20445
20446         * lib/base64.h (isbase64): Add.
20447
20448         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
20449         using a unsigned prototype, don't inline.
20450         (base64_decode): Use it.
20451
20452 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20453
20454         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
20455         it.
20456
20457 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20458
20459         * lib/save-cwd.c (save_cwd): Remove code to support the case
20460         where fchdir is missing or flaky.
20461
20462 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20463
20464         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
20465
20466 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
20467
20468         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
20469         AC_LIBSOURCES now does this.
20470         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
20471         with new ullong_max module.
20472
20473 2005-01-19  Bruno Haible  <bruno@clisp.org>
20474
20475         * modules/sh-quote: New file.
20476         * MODULES.html.sh (Executing programs): Add sh-quote.
20477
20478 2005-01-19  Bruno Haible  <bruno@clisp.org>
20479
20480         * lib/sh-quote.h: New file, from GNU gettext.
20481         * lib/sh-quote.c: New file, from GNU gettext.
20482
20483 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20484
20485         Merge from coreutils.
20486         * m4/ullong_max.m4: New file.
20487         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
20488         (gl_MACROS): Assume localeconv exists.
20489
20490 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20491
20492         Merge changes from coreutils, as described below in several
20493         changelogs dated today.
20494
20495         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
20496         (O_DIRECTORY): Remove; not needed here, since "." must be
20497         a directory.  All uses removed.
20498         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
20499         universal on Suns, and we also need to test for IRIX.
20500         Revamp code to use 'if' rather than '#if'.
20501         Avoid unnecessary comparison of cwd->desc to 0.
20502
20503         * lib/utimens.c (futimens): Robustify the previous patch, by checking
20504         for known valid error numbers rather than observed invalid ones.
20505
20506 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20507
20508         * modules/ullong_max: New file.
20509
20510         * modules/chdir-long, modules/openat: New files.
20511         * modules/save-cwd (Depends-on): Depend on chdir-long.
20512         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
20513
20514 2005-01-18  Jim Meyering  <jim@meyering.net>
20515
20516         Merge from coreutils.
20517         * m4/chdir-long.m4, m4/openat.m4: New files.
20518         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
20519         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
20520         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
20521         is sane and DOES follow symlinks.  Besides, testing 20 different
20522         systems found no broken chown implementations.
20523         Prompted by a change in rsync's copy of this macro.
20524         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
20525
20526         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
20527
20528         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
20529         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
20530         NULL-means-set-to-current-time semantics.
20531         Remove temporary file immediately, rather than waiting
20532         for configure's at-exit trap code to do it.
20533
20534 2005-01-18  Jim Meyering  <jim@meyering.net>
20535
20536         * lib/version-etc.c (version_etc_copyright): Update copyright date.
20537
20538         * lib/utimens.c (futimens): Account for the fact that futimes
20539         can also fail with errno == ENOSYS or errno == ENOENT.
20540         Patch from Dmitry V. Levin.
20541
20542         Change the name of the robust chdir function from chdir to chdir_long.
20543         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
20544         (restore_cwd): Use chdir_long, not chdir.
20545         * lib/chdir-long.c: Renamed from chdir.c.
20546         * lib/chdir-long.h: Renamed from chdir.h.
20547         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
20548         Hurd.
20549
20550 2005-01-18  Bruno Haible  <bruno@clisp.org>
20551
20552         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
20553         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
20554         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
20555         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
20556         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
20557         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
20558         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
20559         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
20560         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
20561         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
20562         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
20563         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
20564         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
20565         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
20566         Use an all-permissive copyright notice, recommended by RMS.
20567
20568 2005-01-18  Bob Proulx  <bob@proulx.com>
20569
20570         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
20571         simplify offsetof() macro construct to avoid compile failure with
20572         native HP-UX 11.0 ANSI C compiler.
20573
20574 2005-01-17  Bruno Haible  <bruno@clisp.org>
20575
20576         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
20577         redundant because stpncpy.m4 takes care of it.
20578
20579 2005-01-17  Bruno Haible  <bruno@clisp.org>
20580
20581         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
20582
20583 2005-01-17  Bruno Haible  <bruno@clisp.org>
20584
20585         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
20586         used.
20587
20588 2005-01-17  Bruno Haible  <bruno@clisp.org>
20589
20590         * lib/fwriteerror.h (fwriteerror): Change specification to include
20591         fclose.
20592         * lib/fwriteerror.c: Include <stdbool.h>.
20593         (fwriteerror): At the end, close the file stream. Record whether
20594         stdout was already closed.
20595
20596 2005-01-17  Bruno Haible  <bruno@clisp.org>
20597
20598         * lib/execute.c (environ): Declare if needed.
20599         * lib/pipe.c (environ): Likewise.
20600         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
20601
20602 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20603
20604         * modules/argp: Depend on vsnprintf
20605
20606 2005-01-10  Jim Meyering  <jim@meyering.net>
20607
20608         * modules/closeout (Depends-on): Add atexit.
20609
20610 2005-01-06  Bruno Haible  <bruno@clisp.org>
20611
20612         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
20613
20614 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
20615
20616         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
20617         definitions to be after all include files, to avoid collisions.
20618         Problem reported by Bob Proulx.
20619
20620 2005-01-04  Jim Meyering  <jim@meyering.net>
20621
20622         Changes imported from coreutils.
20623         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
20624         as the mkstemp template, use a temporary directory and an
20625         8.3-friendly template to avoid trouble on systems like DJGPP.
20626         Reported by Juan M. Guerrero via Stepan Kasal.
20627         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
20628         close. Remove the temporary directory right away, rather than waiting
20629         for configure's at-exit trap code to do it.
20630         Suggestion from Stepan Kasal.
20631
20632 2005-01-01  Simon Josefsson  <jas@extundo.com>
20633
20634         * gnulib-tool: Print #include directives when --import'ing.
20635
20636 2004-12-28  Simon Josefsson  <jas@extundo.com>
20637
20638         * tests/test-base64.c: Include required header files.  Remove
20639         unused variables.
20640
20641 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
20642
20643         * modules/error (Depends-on): Remove gettext.
20644
20645 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
20646
20647         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
20648         not needed.  This removes a dependency on the gettext module.
20649         [defined _LIBC]: Do not include <libintl.h>; not needed.
20650
20651 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
20652
20653         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
20654         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
20655
20656 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
20657
20658         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
20659         HAVE_DECL_STRTOLD.
20660
20661 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
20662
20663         * modules/getdate (Depends-on): Remove alloca-opt.
20664
20665 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
20666
20667         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
20668
20669 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
20670
20671         * lib/argp-parse.c: Include <stddef.h>.
20672         (alignof, alignto): New macros.
20673         (parser_init): Don't assume that void * is aligned sufficiently
20674         for struct option.
20675
20676         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
20677         need to extend the stack.
20678         (YYINITDEPTH): New macro, so that the initial stack isn't overly
20679         large.
20680
20681 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20682
20683         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
20684
20685 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
20686
20687         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
20688         (2004-10-24) change.  Apparently this was a false alarm.
20689
20690         * modules/getdate: Depend on alloca-opt, not alloca.
20691
20692 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
20693
20694         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
20695         Remove now-obsolete comment about AIX.
20696         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
20697         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
20698         (YYMAXDEPTH): New macro.
20699
20700 2004-12-18  Simon Josefsson  <jas@extundo.com>
20701
20702         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
20703
20704 2004-12-18  Bruno Haible  <bruno@clisp.org>
20705
20706         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
20707
20708 2004-12-18  Bruno Haible  <bruno@clisp.org>
20709
20710         * lib/fatal-signal.c (fatal_signals): Make non-const.
20711         (init_fatal_signals): New function.
20712         (uninstall_handlers, install_handlers): Ignore signals that were set to
20713         SIG_IGN.
20714         (at_fatal_signal): Call init_fatal_signals.
20715         (init_fatal_signal_set): Likewise. Ignore signals that were set to
20716         SIG_IGN.
20717         Reported by Paul Eggert.
20718
20719 2004-12-18  Bruno Haible  <bruno@clisp.org>
20720
20721         * doc/alloca.texi: New file.
20722         * doc/alloca-opt.texi: New file.
20723
20724 2004-12-17  Jim Meyering  <jim@meyering.net>
20725
20726         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
20727         Otherwise, install-sh could exit with improper exit status when
20728         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
20729
20730 2004-12-16  Simon Josefsson  <jas@extundo.com>
20731
20732         * tests/test-base64.c: Add license.
20733
20734 2004-12-15  Stepan Kasal  <address@hidden>
20735
20736         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
20737
20738 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
20739
20740         * modules/getcwd (Files): Add m4/d-ino.m4.
20741         Suggested by Mark D. Baushke.
20742
20743 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
20744
20745         * lib/getdate.y (textint): New member "negative".
20746         (time_zone_hhmm): New function.
20747         Expect 14 shift-reduce conflicts, not 13.
20748         (o_colon_minutes): New rule.
20749         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
20750         (yylex): Set the "negative" member of signed numbers.
20751
20752 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
20753
20754         * doc/getdate.texi (Time of day items, Time zone items):
20755         Describe new formats +00:00, UTC+00:00.
20756
20757 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
20758
20759         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
20760         spurious "-l"s.  Problem reported by Stepan Kasal.
20761
20762 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
20763
20764         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
20765         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
20766
20767 2004-12-04  Simon Josefsson  <jas@extundo.com>
20768
20769         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
20770         Vandoorselaere <yoann@prelude-ids.org>.
20771
20772 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
20773
20774         Changes imported from coreutils.
20775         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
20776         exist.
20777         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
20778
20779 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
20780
20781         Changes imported from coreutils.
20782         * lib/hard-locale.c: Assume <locale.h> exists.
20783         Include "strdup.h".
20784         (GLIBC_VERSION): New macro.
20785         (hard_locale): Assume setlocale exists.
20786         Rewrite to avoid #ifdef.
20787         Use strdup rather than malloc + strcpy.
20788         * lib/human.c: Assume <locale.h> exists.
20789         (human_readable): Assume localeconv exists.
20790
20791 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
20792
20793         * modules/hard-locale (Depends-on): Add strdup.
20794
20795 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
20796
20797         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
20798         convert T2, not T.  (Imported from libc.)
20799
20800 2004-11-30  Simon Josefsson  <jas@extundo.com>
20801
20802         * modules/restrict (License): Change to LGPL.
20803
20804 2004-11-30  Simon Josefsson  <jas@extundo.com>
20805
20806         * m4/restrict.m4: Add copyright and copying conditions.
20807
20808 2004-11-30  Simon Josefsson  <jas@extundo.com>
20809
20810         * m4/base64.m4: New file.
20811
20812 2004-11-30  Simon Josefsson  <jas@extundo.com>
20813
20814         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
20815         base64.
20816
20817         * tests/test-base64.c: New file.
20818
20819         * modules/base64: New file.
20820
20821 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
20822
20823         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
20824         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
20825
20826         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
20827
20828 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
20829
20830         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
20831         (__getcwd.c): Don't restore errno; glibc doesn't.
20832         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
20833         first, falling back to our code only if its results look suspicious.
20834         Ensure that the resulting buffer is only as large as necessary.
20835
20836         * lib/readutmp.c: Include readutmp.h first.
20837         Include <errno.h>, since readutmp.h no longer does that.
20838         * lib/readutmp.h: Don't include <errno.h>,
20839         <sys/param.h>, <time.h>; not needed to establish interface.
20840         (errno): Remove decl.
20841         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
20842         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
20843         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
20844
20845 2004-11-28  Simon Josefsson  <jas@extundo.com>
20846
20847         * lib/base64.h, base64.c: New file.
20848
20849 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
20850
20851         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
20852
20853 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
20854
20855         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
20856         (Depends-on): Remove pathmax, same.  Add mempcpy.
20857         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
20858         (Makefile.am): Append getcwd.h to lib_SOURCES.
20859         (Include): Add getcwd.h.
20860         (Maintainer): Change from Jim Meyering to "all, glibc",
20861         since getdate now uses intended-for-glibc code.
20862         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
20863         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
20864
20865 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
20866
20867         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
20868         HP's ANSI C compiler.
20869         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
20870         Declaring int functions causes warnings on some modern systems and
20871         shouldn't be needed to compile on ancient ones.
20872         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
20873         defined.
20874
20875         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
20876         with the following changes.
20877         (__set_errno): Parenthesize properly.
20878         Include <stdbool.h>.
20879         (MIN, MAX, MATCHING_INO): New macros.
20880         (__getcwd): Define with prototype, not K&R form.
20881         Use heuristics to allocate default buffer on stack if possible.
20882         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
20883         behavior, and to avoid the PATH_MAX limit when computing
20884         ../../../../...
20885         Use MATCHING_INO to compare inode number to file.
20886         Check for arithmetic overflow in size calculations.
20887         Fix bug in reallocation of dot array that caused getcwd to fail
20888         on directories nested deeper than 75.
20889         Be more careful about saving errno on error.
20890         Do not use realloc; use only free+malloc, as this is a bit
20891         more flexible and avoids a needless copy operation.
20892         Do not inspect st_dev and st_ino for symbolic links; POSIX
20893         doesn't specify the latter.
20894         Check for closedir errors.
20895         Avoid needless casts.
20896         Use "#ifdef weak_alias" around weak_alias, to be like other
20897         glibc code.
20898         The following changes to getcwd.c have effect only when used in
20899         gnulib; they have no effect inside glibc proper.
20900         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
20901         as alloca isn't used.
20902         (alloca, __alloca): Likewise.
20903         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
20904         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
20905         unconditionally, as gnulib assumes C89 or better.
20906         Do not include <sys/param.h>.
20907         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
20908         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
20909         better.
20910         (NULL) [!defined NULL]: Remove; we assume C89 or better.
20911         Include <dirent.h> in a way that is compatible with modern Autoconf.
20912         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
20913         New macros, if not already defined.
20914         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
20915         Use "_LIBC", not "defined _LIBC", for consistency.
20916         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
20917         a mempcpy module.
20918         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
20919         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
20920         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
20921         credit only to Jim Meyering and adjust the copyright dates.
20922         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
20923         <stdlib.h>, <unistd.h>, "pathmax.h".
20924         Instead, include "xgetcwd.h" (first) and "getcwd.h".
20925         (INITIAL_BUFFER_SIZE): Remove.
20926         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
20927
20928 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
20929
20930         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
20931         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
20932         Use the _ONCE methods, for efficiency.
20933         Check for fcntl.h.  In test program, include <errno.h>
20934         and <fcntl.h> if available.  Remove old K&R cruft from
20935         test program.  Check for common errors in GNU/Linux,
20936         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
20937         don't do AC_LIBOBJ, as that's getcwd.m4's job.
20938         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
20939         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
20940         name accordingly.
20941         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
20942         accommodate new getcwd.c.
20943         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
20944         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
20945         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
20946         that's all we need now.
20947
20948 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20949
20950         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
20951         argp-parse.c depends on getopt internals, that means we should
20952         always use our getopt, to be on the safe side.
20953         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
20954         order not to spoil the result of an eventual previous invocation
20955         of gl_GETOPT_SUBSTITUTE.
20956
20957 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20958
20959         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
20960         redefinition warnings. To avoid them, include the defines
20961         in `#if !defined __need_getopt ... #endif'. The only place
20962         where __getopt_argv_const is used is in definitions
20963         of getopt_long and getopt_long_only below, which are as well
20964         protected by `#ifndef __need_getopt'.
20965         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
20966         __need_getopt after including <stdio.h> and <unistd.h> These
20967         headers might have defined it.
20968
20969 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
20970
20971         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
20972
20973 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
20974
20975         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
20976         (futimens): New function, which uses futimes if available.
20977         (futimens, utimens): Support timespec==NULL, with same semantics
20978         as utime and utimens.
20979         * lib/utimens.h (futimens): New decl.
20980
20981 2004-11-23  Jim Meyering  <jim@meyering.net>
20982
20983         * lib/getopt_.h: Remove trailing blanks.
20984
20985 2004-11-23  Jim Meyering  <jim@meyering.net>
20986
20987         * lib/__fpending.c: Add comment.
20988
20989 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
20990
20991         * modules/canonicalize (Depends-on): Add xreadlink.
20992         Problem reported by James Youngman.
20993
20994 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
20995
20996         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
20997         New macros.
20998         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
20999         optopt): Use them instead of invoking ## directly; otherwise, the
21000         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
21001
21002 2004-11-19  Bruno Haible  <bruno@clisp.org>
21003
21004         * lib/strtok_r.c: Move comments from here...
21005         * lib/strtok_r.h: ... to here.
21006
21007 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21008
21009         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
21010         implementations that mishandle size_t overflow.
21011
21012 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21013
21014         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
21015         might fail.  Problem reported by Yoann Vandoorselaere.
21016         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
21017         implementations that mishandle size_t overflow.
21018
21019 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21020
21021         * modules/canon-host (Depends-on): Add strdup.
21022
21023 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21024
21025         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
21026
21027 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21028
21029         * lib/canon-host.c: Include "strdup.h".
21030         (canon_host): Use getaddrinfo if available, so that IPv6 works.
21031         Use strdup instead of malloc/strcpy to duplicate strings.
21032
21033         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
21034         (human_space_before_unit): New constant.
21035         * lib/human.c (human_readable): Support it.
21036
21037         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
21038         (xgetcwd): Set errno correctly when failing.
21039         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
21040         the failure is actually due to a PATH_MAX problem.
21041
21042         Further getopt changes to make it more likely that glibc will
21043         buy the changes back.
21044         * lib/getopt.c (POSIXLY_CORRECT): New constant.
21045         (getopt): Use it, so to preserve glibc semantic
21046         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
21047         when compiling for libc.
21048         * lib/getopt_.h (__getopt_argv_const): Bring it back.
21049         (getopt_long, getopt_long_only): Use it.
21050
21051         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21052         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
21053         (getopt): Argv is now char * const *, as per standard.
21054         (_getopt_internal_r, _getopt_internal): Argv is now char **,
21055         not char *__getopt_argv_const *.
21056         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21057         _getopt_long_only_r): Likewise.
21058         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
21059         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21060         _getopt_long_r, _getopt_long_only_r): Likewise.
21061         * lib/getopt_.h (__getopt_argv_const): Remove.
21062         (getopt): Argv is now char * const *, as per standard.
21063
21064         * lib/getdate.y (tORDINAL): New token.
21065         (day, relunit): Allow it for relative times.
21066         (relative_time_table): Use tORDINAL for ordinals.
21067
21068 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21069
21070         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
21071         Document that "second" isn't allowed as an ordinal number.
21072
21073 2004-11-16  Jim Meyering  <jim@meyering.net>
21074
21075         * modules/closeout (Depends-on): Add fpending.
21076
21077 2004-11-15  Jim Meyering  <jim@meyering.net>
21078
21079         * lib/closeout.c: Include "__fpending.h" once again.
21080         Include <stdbool.h>.
21081         (close_stdout): Don't fail just because stdout was closed initially,
21082         since some programs don't write to stdout in the normal course of
21083         operation (other than --version and --help), and we don't want this
21084         function to make e.g. `touch file >&-' fail.
21085         But do fail if it was closed and someone has tried to write to it.
21086         E.g., `printf foo >&-' must fail.
21087
21088 2004-11-13  Jim Meyering  <jim@meyering.net>
21089
21090         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
21091
21092 2004-11-12  Simon Josefsson  <jas@extundo.com>
21093
21094         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
21095         small doc fix is still pending.
21096
21097 2004-11-11  Simon Josefsson  <jas@extundo.com>
21098
21099         * modules/strtok_r: New file.
21100
21101         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21102         strtok_r.
21103
21104 2004-11-11  Simon Josefsson  <jas@extundo.com>
21105
21106         * m4/strtok_r.m4: New file.
21107
21108         * m4/getopt.m4: Replace opterr.
21109
21110 2004-11-11  Simon Josefsson  <jas@extundo.com>
21111
21112         * lib/strtok_r.h, strtok_r.c: New file.
21113
21114 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21115
21116         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
21117         of replacing opterr, getopt, etc.  This should handle the
21118         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
21119
21120 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21121
21122         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
21123         we can stop lying to compilers about the constness of argv when we
21124         are compiled outside glibc.
21125         (getopt, getopt_long, getopt_long_only): Use it.
21126         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21127         _getopt_internal, getopt): Likewise.
21128         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21129         _getopt_long_only_r): Likewise.
21130         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21131         _getopt_long_r, _getopt_long_only_r): Likewise.
21132
21133         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
21134         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
21135         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
21136         the other external symbols.
21137         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
21138         declaration, since the above renaming now works around collisions.
21139
21140 2004-11-11  Jim Meyering  <jim@meyering.net>
21141
21142         * lib/linebreak.c: Remove trailing blanks.
21143         * lib/alloca_.h: Likewise.
21144         * lib/acosl.c: Likewise.
21145         * lib/euidaccess.c: Likewise.
21146         * lib/allocsa.h: Likewise.
21147
21148 2004-11-10  Simon Josefsson  <jas@extundo.com>
21149
21150         * m4/getaddrinfo.m4: New file.
21151
21152 2004-11-10  Simon Josefsson  <jas@extundo.com>
21153
21154         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
21155
21156 2004-11-10  Simon Josefsson  <jas@extundo.com>
21157
21158         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21159         getaddrinfo.
21160
21161         * modules/getaddrinfo: New file.
21162
21163 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21164
21165         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
21166
21167 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21168
21169         * lib/mktime.c (SHR): New macro, which is a portable
21170         substitute for >> that should work even on Crays.
21171         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
21172         Problem reported by Mark D. Baushke in
21173         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
21174         * lib/getdate.y (SHR): Likewise.
21175         (tm_diff): Use it.
21176         * lib/strftime.c (SHR): Likewise.
21177         (tm_diff): Use it.
21178         * lib/quotearg.c (struct quoting_options): Use unsigned int for
21179         quote_these_too, so that right shifts are well defined.  All uses
21180         changed.
21181
21182 2004-11-10  Jim Meyering  <jim@meyering.net>
21183
21184         Ensure that no close failure goes unreported.
21185         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
21186         return early when it seems there's nothing to flush.
21187         Don't include __fpending.h.
21188
21189 2004-11-10  Jim Meyering  <jim@meyering.net>
21190
21191         * modules/closeout (Depends-on): Remove fpending.
21192
21193 2004-11-10  Jim Meyering  <jim@meyering.net>
21194
21195         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
21196
21197 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21198
21199         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
21200         gl_FUNC_STRFTIME.
21201         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
21202         and AC_REQUIRE when possible, to avoid duplicate checks.
21203         Check for <wchar.h>.
21204
21205 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21206
21207         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
21208
21209 2004-11-09  Bruno Haible  <bruno@clisp.org>
21210
21211         * m4/sockpfaf.m4: New file.
21212
21213 2004-11-05  Bruno Haible  <bruno@clisp.org>
21214
21215         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
21216         Reported by Mark D. Baushke <mdb@cvshome.org>.
21217
21218 2004-11-04  Bruno Haible  <bruno@clisp.org>
21219
21220         2004-09-11  Bruno Haible  <bruno@clisp.org>
21221                 * allocsa.valgrind: New file.
21222         2004-02-06  Bruno Haible  <bruno@clisp.org>
21223                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
21224                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
21225                 Reported by Christopher Seip <chris.seip@hp.com>.
21226
21227 2004-11-04  Bruno Haible  <bruno@clisp.org>
21228
21229         * modules/allocsa (Files): Add lib/allocsa.valgrind.
21230         (Makefile.am): Distribute it.
21231
21232 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
21233
21234         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
21235         with errno == ERANGE if the buffer is too small.
21236         Problem reported by Mark D. Baushke.
21237
21238 2004-11-03  Albert Chin  <china@thewrittenword.com>
21239             Paul Eggert  <eggert@cs.ucla.edu>
21240
21241         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
21242         equivalent, substitute $ac_type for equivalent type rather than
21243         blindly using uint32_t *always* which won't work if uint32_t is not
21244         available.  Define _UINT32_T to work around typedef of uint32_t if
21245         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
21246         2.5.1.
21247
21248 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21249
21250         * m4/jm-macros.m4: Sync from coreutils.
21251         (gl_MACROS): Check for mbrlen, for pathchk.
21252         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
21253
21254 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21255
21256         * lib/xreadlink.c (MAXSIZE): New macro.
21257         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
21258         size does not exceed MAXSIZE.  Avoid cast.
21259         As suggested by Mark D. Baushke in
21260         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
21261         if readlink fails with buffer size just under MAXSIZE, try again
21262         with MAXSIZE.
21263
21264 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21265
21266         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
21267
21268 2004-11-02  Derek R. Price  <derek@ximbiot.com>
21269         and  Paul Eggert  <eggert@cs.ucla.edu>
21270
21271         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
21272         (get_date): Overparenthesize to avoid GCC warning.
21273
21274 2004-11-02  Bruno Haible  <bruno@clisp.org>
21275
21276         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
21277         returns void.
21278
21279 2004-11-02  Bruno Haible  <bruno@clisp.org>
21280
21281         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
21282         function returns void.
21283
21284 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21285
21286         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
21287         fflush_unlocked, flockfile, funlockfile, funlockfile,
21288         fputs_unlocked, putc_unlocked.
21289
21290 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21291
21292         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21293         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
21294         already declared.
21295
21296 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21297
21298         * modules/getdate (Files): Add doc/getdate.texi.
21299         (Depends-on): Add setenv, xalloc.
21300
21301 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21302
21303         * lib/getdate.y: Add support for TZ="foo" within a date string.
21304         Fix some bugs near time_t boundaries.  Reject dates with
21305         out-of-range components, e.g., "Sept 31".
21306         Include <stdlib.h>, "setenv.h", "xalloc.h".
21307         (ISDIGIT_LOCALE): Remove; unused.
21308         Note that the TZ and time functions used here are not reentrant.
21309         (mktime_ok, get_tz): New functions.
21310         (TZBUFSIZE): New constant.
21311         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
21312         This requires that we sometimes generate our own TZ="XXX..." setting.
21313
21314 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21315
21316         * doc/getdate.texi: New file, from coreutils with modifications for
21317         the new TZ parsing.
21318
21319 2004-10-27  Derek R. Price  <derek@ximbiot.com>
21320
21321         * lib/mktime.c (not_equal_tm): Remove redundant check.
21322
21323 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21324
21325         * modules/regex (lib_SOURCES): Add regex.c.
21326         Reported by James Youngman in
21327         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
21328
21329 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21330
21331         * lib/getdate.y: Use Bison 1.875 features, and some minor
21332         code cleanups.  This change does not affect semantics.
21333         Don't include <stdlib.h>; no longer needed.
21334         Don't include unlocked-io.h; only the "#if TEST" code uses
21335         stdio, and performance isn't crucial there.
21336         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
21337         Bison 1.875 features as described below.
21338         All uses of "PC." replaced by "pc->".
21339         (YYSTYPE): Add a forward declaration.
21340         (yylex, yyerror): Use full prototypes in forward decls.
21341         Use "%pure-parser" rather than obsolescent "%pure_parser".
21342         Use %parse-param and %lex-param instead of obsolescent
21343         YYPARSE_PARAM and YYLEX_PARAM.
21344         (meridian_table, month_and_day_table, time_units_table,
21345         relative_time_table, time_zone_table, military_table,
21346         lookup_zone, lookup_word, get_date):
21347         Use NULL instead of 0 where appropriate.
21348         (to_hour): Avoid abort (), to avoid a dependency on
21349         stdlib.h.
21350         (yyerror, yylex): Now accepts parser_control * arg.
21351         (main) [TEST]: Use '\0' rather than 0 for char.
21352
21353 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21354
21355         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
21356
21357 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21358
21359         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
21360         It's now the caller's responsibility to handle the case where
21361         !HAVE_GETPAGESIZE && !defined getpagesize.
21362
21363         * lib/mktime.c (leapyear): Arg is long int, not int.
21364
21365 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
21366
21367         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
21368
21369 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
21370
21371         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
21372         missing.  Problem reported by James Youngman.
21373
21374 2004-10-16  Simon Josefsson  <jas@extundo.com>
21375
21376         * gnulib-tool: Fix comments.  Fix parse problem.
21377         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
21378
21379 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
21380
21381         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
21382         implementation of getopt_long.  Problem reported by Alexander Taler in:
21383         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
21384
21385 2004-10-15  Bruno Haible  <bruno@clisp.org>
21386
21387         * gnulib-tool: Untabify. Initialize supplied_libname.
21388         (func_usage): More homogenous output.
21389         (func_modules_transitive_closure, func_modules_to_filelist,
21390         func_emit_lib_Makefile_am): New functions.
21391         (func_import): New function, extracted from big case statement. Use
21392         func_get_license, func_modules_transitive_closure,
21393         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
21394         opt_lgpl. Don't use test -a, as it's not portable.
21395         (func_create_testdir): Use func_modules_transitive_closure,
21396         func_modules_to_filelist, func_emit_lib_Makefile_am.
21397
21398 2004-10-15  Bruno Haible  <bruno@clisp.org>
21399
21400         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
21401
21402 2004-10-15  Bruno Haible  <bruno@clisp.org>
21403
21404         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
21405         the portions belonging to each module.
21406         Suggested by Derek Robert Price <derek@ximbiot.com>.
21407
21408 2004-10-12  Simon Josefsson  <jas@extundo.com>
21409
21410         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21411         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
21412         to real functions.
21413
21414 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21415
21416         * modules/vsnprintf: New file.
21417
21418 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21419
21420         * m4/vsnprintf.m4: New file.
21421
21422 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21423
21424         * lib/vsnprintf.h: New file.
21425         * lib/vsnprintf.c: New file.
21426
21427 2004-10-11  Bruno Haible  <bruno@clisp.org>
21428
21429         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
21430         vsnprintf.
21431
21432 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
21433
21434         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
21435
21436 2004-10-07  Bruno Haible  <bruno@clisp.org>
21437
21438         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
21439         fits into the provided buffer.
21440
21441 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
21442
21443         * lib/diacrit.c, diacrit.h: Add GPL notice.
21444
21445         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
21446         notice.
21447         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
21448         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
21449         This avoids a potential constant-folding bug.
21450
21451 2004-10-05  Bruno Haible  <bruno@clisp.org>
21452
21453         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
21454         for the declaration of strsep.
21455
21456 2004-10-05  Bruno Haible  <bruno@clisp.org>
21457
21458         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
21459
21460 2004-10-04  Simon Josefsson  <jas@extundo.com>
21461
21462         * modules/memmem: New file.
21463         * tests/test-memmem.c: New file.
21464         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
21465
21466 2004-10-04  Simon Josefsson  <jas@extundo.com>
21467
21468         * m4/memmem.m4: New file.
21469
21470 2004-10-04  Simon Josefsson  <jas@extundo.com>
21471
21472         * lib/memmem.h: New file.
21473         * lib/memmem.c: New file, taken from glibc.
21474
21475 2004-10-04  Simon Josefsson  <jas@extundo.com>
21476
21477         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
21478         '#ifdef USE_UNLOCKED_IO'.
21479
21480 2004-10-04  Simon Josefsson  <jas@extundo.com>
21481
21482         * config/srclist.txt: Add memmem from glibc.
21483
21484 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21485
21486         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
21487
21488         * modules/argmatch, modules/argp, modules/closeout, modules/error,
21489         modules/exclude, modules/getdate, modules/getline,
21490         modules/getndelim2, modules/getpass, modules/getpass-gnu,
21491         modules/getusershell, modules/linebuffer, modules/md5,
21492         modules/mountlist, modules/posixtm, modules/readtokens,
21493         modules/readutmp, modules/regex, modules/sha1,
21494         modules/version-etc, modules/yesno:
21495         Remove dependency on unlocked-io.
21496
21497 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21498
21499         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
21500
21501         * m4/unlocked-io.m4: Add copyright notice.
21502         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
21503
21504 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21505
21506         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
21507         * lib/xmalloc.c (xmemdup): Likewise.
21508         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
21509         XFREE): Remove these long-obsolescent macros.
21510         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
21511         * lib/xstrdup.c: Remove.
21512
21513         * lib/regex.c (re_comp): Cast gettext return value to char *,
21514         Problem reported by Martin Neitzel via Mark D. Baushke.
21515
21516 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21517
21518         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
21519         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
21520         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
21521         regex.c, sha1.c, version-etc.c, yesno.c:
21522         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
21523         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
21524         the includer's responsibility.
21525
21526         Sync from coreutils.
21527
21528         * lib/modechange.c (mode_compile): Don't decrement a pointer that
21529         points to the start of a string, as the C Standard says the
21530         resulting behavior is undefined.
21531
21532         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
21533         simple -> simple_backups, numbered_existing ->
21534         numbered_existing_backups, numbered -> numbered_backups
21535         to avoid shadowing problems.  All uses changed.
21536         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
21537         * lib/backupfile.c (check_extension, numbered_backup):
21538         Rename locals to avoid shadowing 'basename'.
21539         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
21540         once.
21541
21542         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
21543         * lib/.cvsignore: Add getopt.h.
21544
21545 2004-10-04  Bruno Haible  <bruno@clisp.org>
21546
21547         * modules/README: New file.
21548         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
21549         not a module.
21550
21551 2004-10-02  Jim Meyering  <jim@meyering.net>
21552
21553         * lib/dirfd.h, getpagesize.h: Add copyright notice.
21554
21555 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21556
21557         * modules/strsep: New file.
21558
21559 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21560
21561         * m4/strsep.m4: New file.
21562
21563 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21564
21565         * lib/strsep.h: New file.
21566         * lib/strsep.c: New file.
21567
21568 2004-10-01  Simon Josefsson  <jas@extundo.com>
21569
21570         * lib/snprintf.c (snprintf): Handle size==0.
21571
21572 2004-10-01  Simon Josefsson  <jas@extundo.com>
21573             Bruno Haible  <bruno@clisp.org>
21574
21575         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
21576         (snprintf): Declare 'args'.
21577
21578 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
21579
21580         * lib/snprintf.c: Remove comments as to why each header is needed.
21581
21582 2004-10-01  Bruno Haible  <bruno@clisp.org>
21583
21584         * MODULES.html.sh: Add strsep.
21585
21586 2004-09-30  Simon Josefsson  <jas@extundo.com>
21587
21588         * modules/snprintf: New file.
21589
21590 2004-09-30  Simon Josefsson  <jas@extundo.com>
21591
21592         * m4/snprintf.m4: New file.
21593
21594 2004-09-30  Simon Josefsson  <jas@extundo.com>
21595
21596         * lib/snprintf.h, lib/snprintf.c: New files.
21597
21598 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21599
21600         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
21601         (hol_entry_help): Never translate an empty string.
21602         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
21603         * lib/argp.h (OPTION_NO_TRANS): New option.
21604
21605 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
21606
21607         * modules/argp (Maintainer): Replace Simon Josefsson
21608         by Sergey Poznyakoff.
21609
21610 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
21611
21612         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
21613         changes merged back into glibc.
21614
21615 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
21616
21617         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
21618
21619 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
21620
21621         * lib/xvasprintf.c: Include xalloc.h.
21622         (xvasprintf): Use xalloc_die, not xmalloc_die.
21623
21624 2004-09-29  Bruno Haible  <bruno@clisp.org>
21625
21626         * modules/alloca-opt: New file, derived from modules/alloca.
21627         * modules/allocsa: Depend on alloca-opt instead of alloca.
21628         * modules/setenv: Likewise.
21629         * modules/vasnprintf: Likewise.
21630         * MODULES.html.sh: Add alloca-opt.
21631
21632 2004-09-28  Simon Josefsson  <jas@extundo.com>
21633
21634         * gnulib-tool: New parameter --lgpl, to asseert that modules are
21635         LGPL, and to replace license template from GPL to LGPL.
21636
21637 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
21638
21639         * modules/dummy: Change license to LGPL.
21640
21641 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
21642
21643         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
21644
21645 2004-09-24  Simon Josefsson  <jas@extundo.com>
21646
21647         * modules/minmax (License): Change from GPL to LGPL.
21648
21649 2004-09-23  Simon Josefsson  <jas@extundo.com>
21650
21651         * gnulib-tool (--import): Typo.
21652
21653 2004-09-23  Simon Josefsson  <jas@extundo.com>
21654
21655         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
21656
21657 2004-09-22  Bruno Haible  <bruno@clisp.org>
21658
21659         * modules/*: Add 'License' field.
21660         * gnulib-tool: Accept --extract-license option.
21661         (func_get_license): New function.
21662
21663 2004-09-21  Bruno Haible  <bruno@clisp.org>
21664
21665         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
21666         Reported by Simon Josefsson.
21667
21668 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
21669
21670         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
21671         gl_AC_TYPE_LONG_LONG.
21672
21673 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
21674
21675         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
21676
21677 2004-09-18  Simon Josefsson  <jas@extundo.com>
21678         and  Paul Eggert  <eggert@cs.ucla.edu>
21679
21680         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
21681         calls with autoreconf.  Define GL_LIB.
21682
21683 2004-09-14  Karl Berry  <karl@gnu.org>
21684
21685         * config/srclist.txt: unsync setenv.c, sigh.
21686
21687 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
21688
21689         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
21690         Problem reported by Bruno Haible in:
21691         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
21692
21693 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
21694
21695         * config/srclist.txt: Comment out argp-pvh.c.
21696
21697 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
21698
21699         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
21700         in case some system header has #define'd it.  Problem reported by
21701         Soeren D. Schulze in
21702         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
21703
21704 2004-09-09  Karl Berry  <karl@gnu.org>
21705
21706         * regex.[ch]: delete from the root.  These were supposed to be
21707                 synced with emacs cvs, but this has not happened for about
21708                 a year, and anyway nothing else uses emacs regex.[ch].
21709                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
21710                 lib/regex[.ch] is untouched.
21711
21712 2004-09-09  Bruno Haible  <bruno@clisp.org>
21713
21714         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
21715
21716 2004-09-09  Bruno Haible  <bruno@clisp.org>
21717
21718         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
21719         modifications.
21720         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
21721
21722 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
21723
21724         * modules/xvasprintf: New file.
21725         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
21726
21727 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
21728
21729         * lib/xvasprintf.h: New file.
21730         * lib/xvasprintf.c: New file.
21731         * lib/xasprintf.c: New file.
21732
21733 2004-09-08  Bruno Haible  <bruno@clisp.org>
21734
21735         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
21736
21737 2004-09-08  Bruno Haible  <bruno@clisp.org>
21738
21739         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
21740         length is > INT_MAX.
21741         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
21742         more.
21743
21744 2004-09-08  Bruno Haible  <bruno@clisp.org>
21745
21746         * lib/stdint_.h: New file, taken from GNU clisp.
21747
21748 2004-09-08  Bruno Haible  <bruno@clisp.org>
21749             Oskar Liljeblad  <oskar@osk.mine.nu>
21750
21751         * modules/stdint: New file.
21752         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
21753
21754 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
21755
21756         Import from coreutils.
21757         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
21758         strings on unbounded length.  alloca's performance benefits aren't
21759         that important here.
21760         (V_STRDUP): Remove.
21761         (parse_with_separator): New function, with most of the internals
21762         of the old parse_user_spec.  Allow user to omit both user and group,
21763         for compatibility with FreeBSD.
21764         Clone only the user name, not the entire spec.
21765         Do not set *uid, *gid unless entirely successful.
21766         Avoid memory leak in some failing cases.
21767         Fix regression for USER.GROUP reported by Dmitry V. Levin in
21768         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
21769         (parse_user_spec): Rewrite to use parse_with_separator.
21770
21771 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
21772
21773         * modules/userspec: Don't depend on alloca.
21774
21775 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
21776
21777         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
21778
21779 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
21780
21781         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
21782         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
21783         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
21784
21785 2004-08-16  Simon Josefsson  <jas@extundo.com>
21786
21787         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
21788         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
21789         Add --dry-run for --import.
21790         Let user provided command line parameters override configure.ac
21791         settings.
21792
21793 2004-08-12  Simon Josefsson  <jas@extundo.com>
21794
21795         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
21796         as discussed with Paul Eggert in threads rooted at
21797         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
21798         and
21799         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
21800         Before, the test was empty, and relied on ELIDE_CODE in source
21801         code.)
21802         (gl_PREREQ_GETOPT): New macro.
21803         (gl_GETOPT): Use them.
21804
21805 2004-08-12  Simon Josefsson  <jas@extundo.com>
21806
21807         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
21808         * lib/getopt_.h: Renamed from getopt.h.
21809
21810 2004-08-12  Simon Josefsson  <jas@extundo.com>
21811
21812         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
21813         Change default library name from libfoo to libgnu.
21814         Now, if you have a configure.ac that says:
21815                 gl_SOURCE_BASE(gl)
21816                 gl_M4_BASE(gl/m4)
21817                 gl_MODULES(error getopt etcetera)
21818                 gl_INIT
21819         you can import all you need by running:
21820                 ../gnulib/gnulib-tool --import
21821
21822         * modules/getopt (Files): Rename getopt.h to getopt_.h.
21823         (Makefile.am): Rewrite, use logic from argz.
21824         (Include): Use <getopt.h> instead of "getopt.h".
21825
21826 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21827
21828         * modules/argp (Files): Add m4/unlocked-io.m4.
21829         (Depends-on): Add extensions.
21830
21831 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21832
21833         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
21834         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
21835         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
21836         Check for program_invocation_name, program_invocation_short_name,
21837         flockfile, funlockfile, features.h, _getopt_long_only_r.
21838
21839 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21840
21841         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
21842         its complicated substitute.
21843         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
21844         and program_invocation_name.
21845         (__argp_basename) [!_LIBC]: Remove; the only use was
21846         replaced by its body.
21847         (__argp_short_program_name): Change condition from
21848         !defined __argp_short_program_name to
21849         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
21850         to match argp-namefrob.h.
21851         (__argp_failure): Don't assume strerror_r returns char *.
21852         * lib/argp-parse.c (N_): Define unconditionally.
21853         (argp_default_options): Fill out initializers with 0 to avoid
21854         gcc warnings.
21855
21856 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
21857
21858         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
21859         getopt1.c.
21860
21861 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
21862
21863         Merge from coreutils.
21864
21865         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
21866
21867         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
21868         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
21869
21870 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
21871
21872         Merge from coreutils.
21873
21874         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
21875         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
21876         for Reliant Unix 5.43.
21877
21878         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
21879         (union fooround): Use uintmax_t, not long int.
21880         The rest is a merge from libc:
21881         [defined _LIBC]: Include <shlib-compat.h>.
21882         (_obstack) [defined _LIBC]: Remove after 2.3.4.
21883
21884         * lib/settime.c (settime): Recode to avoid warning with
21885         Sun Forte C 6U2.
21886
21887         * lib/strverscmp.c: Convert to UTF-8.
21888
21889 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
21890
21891         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
21892         m4/uintmax_t.m4.
21893
21894 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
21895
21896         * modules/xalloc-die: New file.
21897         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
21898
21899         * modules/md5 (Files): Add m4/uint32_t.m4.
21900         * modules/sha1: Renamed from modules/sha.
21901         (Files):
21902         Rename lib/sha.h to lib/sha1.h.
21903         Rename lib/sha.c to lib/sha1.c.
21904         Rename m4/sha.m4 to m4/sha1.m4.
21905         (lib_SOURCES): Likewise.
21906         (configure.ac): Rename gl_SHA to gl_SHA1.
21907         (Include): sha.h -> sha1.h.
21908
21909 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
21910
21911         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
21912         * m4/sha1.m4: Renamed from sha.m4.
21913         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
21914
21915 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
21916
21917         * lib/obstack.h (obstack_empty_p):
21918         Don't assume that chunk->contents is suitably aligned.
21919         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
21920         Likewise. Problem reported by Benno in
21921         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
21922
21923         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
21924         readable.  This could be improved further but it'd take some work.
21925
21926 2004-08-08  Simon Josefsson  <jas@extundo.com>
21927
21928         * modules/xgethostname (Depends-on): Remove exit and error (not
21929         used).
21930
21931         * modules/getpass-gnu: Add getpass.h.
21932         (Depends-on): Add stdbool.
21933         * modules/getpass: Add getpass.h.
21934
21935 2004-08-08  Simon Josefsson  <jas@extundo.com>
21936
21937         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
21938         Check getpass declaration.
21939
21940 2004-08-08  Simon Josefsson  <jas@extundo.com>
21941
21942         * lib/xgethostname.c: Don't include error.h (not used).
21943
21944         * lib/getpass.h: Add.
21945         * lib/getpass.c: Include getpass.h first.
21946
21947 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
21948
21949         * lib/xalloc-die.c: New file.
21950         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
21951         All uses removed.
21952         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
21953         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
21954         xalloc-die.c.
21955         (_, N_, xalloc_die): Move to xalloc-die.c.
21956         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
21957         so that we needn't mess with xalloc_msg_memory_exhausted.
21958
21959         * lib/sha1.h: Renamed from sha.h.
21960         (SHA1_H): Renamed from _SHA_H.
21961         (sha1_ctx): Renamed from sha_ctx.
21962         (sha1_init_ctx): Renamed from sha_init_ctx.
21963         (sha1_process_block): Renamed from sha_process_block.
21964         (sha1_process_bytes): Renamed from sha_process_bytes.
21965         (sha1_finish_ctx): Renamed from sha_finish_ctx.
21966         (sha1_read_ctx): Renamed from sha_read_ctx.
21967         (sha1_stream): Renamed from sha_stream.
21968         (sha1_buffer): Renamed from sha_buffer.
21969         * lib/sha1.c: Likewise; renamed from sha.c.
21970         Do not include <sys/types.h>.
21971         Include <stddef.h> rather than <stdlib.h>.
21972
21973 2004-08-08  Bruno Haible  <bruno@clisp.org>
21974
21975         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
21976         FILESYSTEM_PREFIX_LEN.
21977         * lib/progreloc.c: Likewise.
21978         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
21979
21980 2004-08-06  Simon Josefsson  <jas@extundo.com>
21981
21982         * modules/progname (Depends-on): Don't depend on stdbool.
21983
21984 2004-08-06  Simon Josefsson  <jas@extundo.com>
21985
21986         * modules/getsubopt: New file.
21987         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21988         getsubopt.
21989
21990 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
21991
21992         More merge from coreutils.
21993
21994         * m4/utimens.m4, m4/utimecmp.m4: New files.
21995         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
21996         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
21997         prereq.m4, sha.m4: Import changes from coreutils.
21998
21999 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22000
22001         More merge from coreutils.
22002         * modules/raise, modules/readtokens0, modules/utimens:
22003         * modules/utimecmp, module/xnanosleep: New files.
22004         * modules/strftime: Add lib/strftime.h.
22005         Change include from <time.h> to "strftime.h".
22006         * modules/yesno: Add lib/yesno.h.
22007         * modules/backupfile: Remove lib/addext.c.
22008         * modules/euidaccess: Add stat-macros.h.
22009         * modules/canonicalize, modules/euidaccess,
22010         modules/filemode, modules/lchown, modules/makepath,
22011         modules/rmdir, modules/stat: Likewise.
22012
22013 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22014
22015         Merge from tar.
22016         * lib/argp-help.c (make_hol, hol_append): Don't assume that
22017         SIZE_MAX is a valid preprocessor constant.
22018         (__argp_basename): Change from "#ifndef _LIBC"
22019         to "#ifndef __argp_short_program_name", so that
22020         we don't compile these functions for tar.
22021
22022         More merges from coreutils.
22023         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
22024         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
22025         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
22026         * lib/addext.c: Remove; no longer needed.
22027         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
22028         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
22029         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
22030         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
22031         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
22032         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
22033         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
22034         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
22035         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
22036         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
22037         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
22038         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
22039         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
22040         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
22041         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
22042         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
22043         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
22044         Import changes from coreutils.
22045
22046 2004-08-05  Simon Josefsson  <jas@extundo.com>
22047
22048         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
22049
22050 2004-08-05  Simon Josefsson  <jas@extundo.com>
22051
22052         * m4/getsubopt.m4: New file.
22053
22054 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22055
22056         Merge from coreutils.
22057
22058         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
22059         * m4/getcwd-path-max.m4: New files.
22060
22061         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
22062         FILESYSTEM_PREFIX_LEN ->
22063         FILE_SYSTEM_PREFIX_LEN.
22064         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
22065         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
22066         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
22067         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
22068
22069         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
22070         prerequisite modules now handle the DOS stuff.
22071         Don't check for unistd.h.
22072
22073 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22074
22075         Merge from coreutils.
22076
22077         * lib/.gdb-history: Remove; this doesn't belong here.
22078
22079         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
22080         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
22081         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
22082         * lib/getcwd.c: New files.
22083
22084         * lib/dirname.h: Include <stdbool.h>.
22085         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
22086         for consistency with POSIX terminology.  All uses changed.
22087         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
22088         (strip_trailing_slashes): Use bool for booleans.
22089         * lib/stripslash.c (strip_trailing_slashes): Likewise.
22090
22091         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
22092         sometimes returns a positive errno value even when it succeeds.
22093         (print_errno_message) [!LIBC]: Fall back on strerror if
22094         __strerror_r fails.
22095
22096         * lib/path-concat.c (mempcpy): Don't define if a system header defines
22097         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
22098         (longest_relative_suffix): New function.
22099         (path_concat): Use it.  Assume first argument is not NULL.
22100         Port to DOS.  Omit redundant separators.
22101         Report an error instead of returning NULL.
22102         Use mempcpy instead of memcpy.
22103         (xpath_concat): Remove: not declared or used.
22104
22105         * lib/same.h: Include <stdbool.h>
22106         (same_name): Return bool, not int.
22107         * lib/same.c (same_name): Likewise.
22108         (errno): Don't declare; we assume C89 or better now.
22109
22110         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
22111         if not already defined.
22112
22113         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
22114         * lib/dup-safer.c (errno): Likewise.
22115
22116 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22117
22118         Merge from coreutils.
22119         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
22120         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
22121         * modules/path-concat: Don't depend on strdup.
22122
22123 2004-08-03  Simon Josefsson  <jas@extundo.com>
22124
22125         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
22126         * lib/progname.h: Don't include stdbool.h.
22127
22128 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22129
22130         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
22131         * MODULES.html.sh (func_all_modules): Remove fatal.
22132
22133 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22134
22135         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
22136
22137 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22138
22139         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
22140         working.
22141
22142 2004-08-02  Simon Josefsson  <jas@extundo.com>
22143
22144         * lib/getsubopt.h: New file, with comments from Bruno Haible.
22145         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
22146         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
22147
22148 2004-08-01  Simon Josefsson  <jas@extundo.com>
22149
22150         * lib/xgetdomainname.c: Include stdlib.h, for free().
22151
22152 2004-07-19  Bruno Haible  <bruno@clisp.org>
22153
22154         * MODULES.html.sh (func_all_modules): Add dummy.
22155
22156 2004-07-16  Simon Josefsson  <jas@extundo.com>
22157
22158         * modules/dummy: New file.
22159
22160 2004-07-16  Simon Josefsson  <jas@extundo.com>
22161
22162         * lib/dummy.c: New file.
22163
22164 2004-07-16  Bruno Haible  <bruno@clisp.org>
22165
22166         * lib/backupfile.h: Add extern "C" for C++.
22167         * lib/closeout.h: Likewise.
22168         * lib/copy-file.h: Likewise.
22169         * lib/findprog.h: Likewise.
22170         * lib/full-write.h: Likewise.
22171         * lib/pathname.h: Likewise.
22172         * lib/progname.h: Likewise.
22173         * lib/stpcpy.h: Likewise.
22174         * lib/stpncpy.h: Likewise.
22175         * lib/strcase.h: Likewise.
22176         * lib/strstr.h: Likewise.
22177         * lib/xalloc.h: Likewise.
22178
22179         * lib/mbswidth.h: Add extern "C" for C++.
22180         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
22181
22182 2004-07-13  Robert Millan  <robertmh@gnu.org>
22183
22184         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
22185
22186 2004-07-09  Simon Josefsson  <jas@extundo.com>
22187
22188         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
22189         failed without this.)
22190
22191 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22192
22193         * modules/chown (Files): Add lib/fchown-stub.c, since
22194         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
22195
22196 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22197
22198         * lib/fchown-stub.c: New file.
22199
22200 2004-06-24  Jim Meyering  <jim@meyering.net>
22201
22202         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
22203
22204 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22205
22206         * modules/argz: Omit "#include".
22207
22208         * MODULES.html.sh (func_all_modules): Add calloc, to match
22209         2004-06-01 addition of calloc module.
22210
22211 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22212
22213         * m4/argz.m4: New file, which is autoupdated from libtool.
22214
22215 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22216
22217         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
22218         libtool.
22219
22220 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22221
22222         * config/srclist-update: Don't insist on "USA." before the
22223         close-comment, as libtool omits the period and puts the */ on a
22224         separate line.
22225         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
22226         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
22227
22228 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
22229
22230         * modules/argz: New file.
22231         * MODULES.html.sh (func_all_modules): Add argz.
22232
22233 2004-06-12  Jim Meyering  <jim@meyering.net>
22234         and  Paul Eggert  <eggert@cs.ucla.edu>
22235
22236         * modules/hash (Files): Add lib/xalloc.h.
22237         * modules/pipe (Depends-on): Add wait-process.
22238         * modules/stat (Depends-on): Add xalloc.
22239         * modules/userspec (Files): Add lib/userspec.h.
22240         * modules/xstrto
22241
22242         Upgrade from gettext-0.13.
22243         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
22244         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
22245         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
22246
22247 2004-06-10  Jim Meyering  <jim@meyering.net>
22248
22249         * lib/calloc.c: New file.
22250
22251 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
22252
22253         * lib/getdate.y (yylex): Allow space between sign and number.
22254         Problem reported by Dan Jacobson.
22255
22256 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22257
22258         Merge from coreutils CVS.
22259
22260         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
22261         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
22262         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
22263         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
22264         xstrtol.m4: Fix copyright date and/or serial number.
22265
22266         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
22267         See if we need an fchown replacement.
22268         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
22269         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
22270         and use the replacement function if we detect either defect.
22271
22272         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
22273         gl_UTIMECMP.
22274
22275 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22276         and  Jim Meyering  <jim@meyering.net>
22277
22278         Merge from coreutils CVS.
22279
22280         * lib/stat-macros.h: New file, with contents from file-type.h
22281         and coreutils' system.h.
22282         * lib/file-type.c: Include "stat-macros.h".
22283         * lib/file-type.h (file_type): Move all macro definitions to new file,
22284         stat-macros.h.
22285
22286         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
22287         Wrap old code with this conditional.
22288         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
22289         function that does not dereference symlinks.
22290         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
22291
22292         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
22293         dependency problems.
22294         (xreadlink): Accept new arg SIZE, for efficiency.
22295         All decls and uses changed.
22296         * lib/xreadlink.h: Include <stddef.h>, for size_t.
22297
22298         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
22299         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
22300
22301         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
22302         sysexits.h.
22303
22304 2004-06-01  Jim Meyering  <jim@meyering.net>
22305
22306         * m4/calloc.m4: New file.
22307
22308 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
22309
22310         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
22311         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
22312         Also, fix a typo in a diagnostic.
22313
22314 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22315
22316         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
22317         or AC_FUNC_REALLOC.
22318
22319 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22320
22321         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
22322         macros to be defined.
22323         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
22324         the allocator returns NULL because the requested size is zero.
22325
22326 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
22327
22328         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
22329         var.  Add comment explaining why libc still defines it.  This
22330         merges the following patch from glibc:
22331         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
22332
22333 2004-05-20  Andreas Schwab  <schwab@suse.de>
22334
22335         * m4/free.m4: Replace free if it not known to work, not the other
22336         way round.
22337
22338 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
22339
22340         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
22341         present in glibc since revision 1.1 of this file.
22342         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
22343         obstack_alignment_mask, obstack_alloc, obstack_base,
22344         obstack_blank, obstack_blank_fast, obstack_chunk_size,
22345         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
22346         obstack_grow0, obstack_init, obstack_int_grow,
22347         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
22348         obstack_next_free, obstack_object_size, obstack_ptr_grow,
22349         obstack_ptr_grow_fast, obstack_room): Remove declarations of
22350         nonexistent functions.
22351
22352 2004-05-18  Karl Berry  <karl@gnu.org>
22353
22354         * config/srclist.txt: break link for vasnprintf.c.
22355
22356 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22357
22358         Port obstack to the AS/400, where pointers are 16 bytes wide and
22359         you cannot cast an integer to a valid pointer.  This patch is
22360         currently waiting to be integrated into glibc; see
22361         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
22362
22363         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
22364         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
22365         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
22366         (struct obstack): temp member is now a union of a pointer and
22367         an integer, instead of an integer.  All integer uses changed.
22368         This does not affect the physical layout of struct obstack,
22369         except on hosts (like the AS/400) where the size or alignment of
22370         void * is greater than that of ptrdiff_t.
22371         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
22372         __STDC__)]: Store temporary in pointer member of union, not
22373         integer member.
22374         * lib/obstack.c: Include <stddef.h>, for offsetof.
22375         (struct fooalign): Remove; it doesn't need a name.
22376         (union fooround): Change double to long double, and add void *.
22377         (DEFAULT_ALIGNMENT): Use offsetof to compute.
22378         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
22379         not a macro.  Hence the values are always int; so remove all
22380         casts-to-int in uses.
22381
22382 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22383
22384         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
22385         we can get this patch merged into glibc.
22386
22387 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22388             Paul Eggert  <eggert@cs.ucla.edu>
22389
22390         * m4/argp: Depend on alloca.
22391
22392 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22393             Paul Eggert  <eggert@cs.ucla.edu>
22394
22395         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
22396         freecoding.
22397
22398 2004-05-17  Bruno Haible  <bruno@clisp.org>
22399
22400         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
22401         precision that consists of a '.' followed by an empty digit string.
22402         Patch by Tor Lillqvist <tml@iki.fi>.
22403
22404 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22405
22406         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
22407         for backward compatibility with older code.  We need our own
22408         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
22409         it under some other name, and our alloca.h will define it.
22410
22411 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22412             Derek Price  <derek@ximbiot.com>
22413
22414         * lib/alloca.c: Include <alloca.h>, to get our interface.
22415         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
22416         include <alloca.h> first.  Use C89 prototype for alloca; this
22417         requires including <stddef.h> for size_t.  Use extern "C" if C++.
22418         Use #elif for simplicity, since we can assume C89 now.
22419         Don't try to source the system alloca.h since it will not be found
22420         and to prevent recursively including its replacement.
22421         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
22422         * lib/regex.c: Likewise.
22423
22424 2004-05-16  Derek Price  <derek@ximbiot.com>
22425             Paul Eggert  <eggert@cs.ucla.edu>
22426
22427         getline cleanup.  This changes the getndelim2 API: both order of
22428         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
22429         no delimiter).
22430
22431         * lib/getline.c: Don't include stddef.h or stdio.h, since our
22432         interface does that.
22433         (getline): Always use getdelim, so that we don't have two
22434         copies of this code.
22435         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
22436         if available.
22437         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
22438         (GETNDELIM2_MAXIMUM): New macro.
22439         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
22440         instead of the old practice of delim2==0.  All callers changed.
22441         Return -1 on overflow, instead of returning junk.
22442         Do not set *linesize unless allocation succeeds.
22443         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
22444         that we include sys/types.h.
22445         * lib/getnline.h: Likewise.
22446         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
22447         (getndelim2): Reorder arguments.
22448         * lib/getnline.c (getnline, getndelim):
22449         Don't discard the NMAX argument.
22450         (getnline): Invoke getndelim, to avoid code duplication.
22451         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
22452         of (size_t) -1 by callers of the getnline family.
22453
22454 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22455
22456         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
22457         Check for gettimeofday.
22458         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
22459         Check for settimeofday, stime.
22460
22461 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22462
22463         * lib/nanosleep.c (suspended): Change its type from int to
22464         sig_atomic_t volatile.
22465         (first_call): Make it private to rpl_nanosleep, and have it
22466         be zero initially as that's a bit faster.
22467         (my_usleep): Round up fractional times instead of truncating them,
22468         as this is the usual meaning for 'sleep'.
22469
22470         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
22471         doesn't work.
22472         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
22473         (ENOSYS): Define if not defined.
22474         (settime): Fall back on stime if it exists and settimeofday fails.
22475         But don't bother with fallbacks if a method fails with errno == EPERM.
22476
22477 2004-05-11  Jim Meyering  <jim@meyering.net>
22478
22479         Prior to this change, the save_cwd caller required read access to the
22480         current directory on most systems (ones with the fchdir function).
22481
22482         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
22483         fails, try write-only, and finally, resort to using xgetcwd.
22484
22485 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
22486
22487         * lib/obstack.c, obstack.h: Import changes from libc.
22488
22489 2004-04-28  Bruno Haible  <bruno@clisp.org>
22490
22491         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
22492         also implicitly appends .exe to executables.
22493         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
22494         accepts Windows pathnames.
22495         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22496         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22497         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22498         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22499         Reported by Derek Robert Price <derek@ximbiot.com>.
22500
22501 2004-04-21  Karl Berry  <karl@gnu.org>
22502
22503         * config/srclist.txt (localcharset.c): break sync.
22504
22505 2004-04-20  Paul Eggert  <eggert@twinsun.com>
22506
22507         * m4/host-os.m4: Add a copyright notice.
22508
22509 2004-04-20  Jim Meyering  <jim@meyering.net>
22510
22511         Change UTILS_ to gl_ in AC_DEFINE'd names.
22512         Change utils_- and jm_-prefixed variables, too.
22513         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
22514         UTILS_FUNC_MKDIR_TRAILING_SLASH.
22515         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
22516
22517         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
22518         Don't emit trailing blanks.
22519         Also rename jm_-prefixed variables to have gl_ prefix.
22520
22521         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
22522         Also rename jm_-prefixed variables to have gl_ prefix.
22523
22524         * m4/jm-macros.m4: Reflect the renamings.
22525         * m4/prereq.m4: Likewise.
22526
22527 2004-04-20  Jim Meyering  <jim@meyering.net>
22528
22529         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
22530         memory.
22531
22532 2004-04-20  Jim Meyering  <jim@meyering.net>
22533             Bruno Haible  <bruno@clisp.org>
22534
22535         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
22536         memory when realloc fails.
22537
22538 2004-04-19  Jim Meyering  <jim@meyering.net>
22539
22540         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
22541         now that readutmp.c may call `free (0)'.
22542
22543 2004-04-19  Bruno Haible  <bruno@clisp.org>
22544
22545         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
22546         * m4/inttypes_h.m4: Likewise.
22547         * m4/stdint_h.m4: Likewise.
22548         * m4/intmax_t.m4: Likewise.
22549         * m4/uintmax_t.m4: Likewise.
22550
22551 2004-04-18  Jim Meyering  <jim@meyering.net>
22552
22553         * m4/prereq.m4: Don't forbid jm_ prefix.
22554
22555         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
22556         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
22557         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
22558         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
22559         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
22560         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
22561         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
22562         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
22563         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
22564         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
22565         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
22566         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
22567         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
22568         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
22569         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
22570         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
22571         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
22572         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
22573         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
22574
22575 2004-04-18  Jim Meyering  <jim@meyering.net>
22576
22577         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
22578         failure, don't leak memory and do call END_UTMP_ENT.
22579
22580 2004-04-16  Jim Meyering  <jim@meyering.net>
22581
22582         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
22583         coreutils' stat program.
22584         (gl_PREREQ): Don't require jm_PREREQ_STAT.
22585
22586 2004-04-11  Paul Eggert  <eggert@twinsun.com>
22587
22588         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
22589         C89.
22590         (CHAR_BIT): Remove, since we assume C89.
22591         Include <stdint.h> if available, as per current Autoconf CVS advice.
22592
22593 2004-03-31  Jim Meyering  <jim@meyering.net>
22594
22595         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
22596         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
22597         * m4/xalloc.m4: Likewise.
22598
22599 2004-03-30  Paul Eggert  <eggert@twinsun.com>
22600
22601         Merge from coreutils.
22602
22603         * m4/inttostr.m4: New file.
22604         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
22605         Require AM_STDBOOL_H and gl_TIMESPEC instead.
22606         Require gl_CLOCK_TIME.
22607         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
22608
22609 2004-03-30  Paul Eggert  <eggert@twinsun.com>
22610
22611         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
22612         not bool, to be more consistent with Unix conventions.
22613         Suggested by Bruno Haible.
22614
22615         Merge from coreutils.
22616
22617         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
22618         * lib/umaxtostr.c: New files.
22619
22620         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
22621         the usual <time.h> dance.
22622         (get_date): Change signature to support fractional time stamps.
22623         All callers changed.
22624         * lib/getdate.y: Include "getdate.h" first, as we can now
22625         assume C89 and don't need to worry about 'const'.
22626         Similarly, include "unlocked-io.h" near start, not in middle.
22627         Include <limits.h>.
22628         (textint.value): Use long int rather than int.
22629         (textint.digits): Use size_t rather than int.
22630         (BILLION, LOG10_BILLION): New constants.
22631         (parser_control): New member rel_ns.  Members day_ordinal,
22632         time_zone, month, day, hour, minutes, rel_year, rel_month,
22633         rel_day, rel_hour, rel_minutes, rel_seconds
22634         are now long int, not int.  Member seconds is now struct timespec,
22635         not int.  New member timespec_seen.  Members dates_seen, days_seen,
22636         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
22637         not int.
22638         (%union.intval): Now long int, not int.
22639         New member timespec.
22640         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
22641         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
22642         (spec): Now is a timespec or an item list.
22643         (timespec, items): New nonterminals.
22644         (time, rel, relunit, number, get_date):
22645         Add support for fractional seconds.
22646         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
22647         (gmtime, localtime, mktime): Remove decls; not needed with C89.
22648         (to_hour): First arg is now long int, not int.
22649         (to_year): Returns long int, not int.
22650         Don't treat year -70 like 70.
22651         (tm_diff): Returns long int, not int.
22652         (lookup_word): Use bool instead of int when appropriate.
22653         (yylex): Use size_t for count, not int.
22654         Detect overflow when parsing large integer constants.
22655         Add support for fractions.
22656         (get_date): Make pointers 'const' if possible.
22657         Use more-portable code to detect integer overflow.
22658         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
22659         Don't use ctime; it's not reliable if the year has >4 digits.
22660
22661         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
22662         This is for compatibility with BSD.
22663
22664         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
22665         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
22666         From coreutils' system.h.
22667
22668         * lib/userspec.c: Don't include "posixver.h".
22669         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
22670         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
22671         compatible extension.  Simplify code by removing a boolean int
22672         that was always nonzero if a string was nonnull.
22673
22674 2004-03-30  Jim Meyering  <jim@meyering.net>
22675
22676         Merge from coreutils.
22677
22678         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
22679         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
22680         on some systems one must include <grp.h> before it.
22681         Reported by Christian Krackowizer.
22682
22683 2004-03-30  Jim Meyering  <jim@meyering.net>
22684
22685         Merge from coreutils.
22686
22687         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
22688
22689         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
22690         an empty input stream.
22691
22692         * lib/readtokens.c: Include <stdbool.h>.
22693         (readtoken): Use `size_t' rather than int/long.
22694         All callers adjusted.
22695         Use `bool' rather than `int' where appropriate.
22696         Use memset rather than an explicit loop.
22697         Use x2nrealloc rather than xrealloc.
22698         Allow the use of `\0' as a delimiter.
22699         (readtokens): Likewise.
22700         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
22701
22702 2004-03-30  Jim Meyering  <jim@meyering.net>
22703
22704         * m4/realloc.m4: Remove file, since now it does no more than
22705         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
22706         the `configure.ac' section of module/realloc.
22707         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
22708
22709 2004-03-30  Bruno Haible  <bruno@clisp.org>
22710
22711         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
22712         nonnull.
22713
22714 2004-03-29  Paul Eggert  <eggert@twinsun.com>
22715
22716         Merge changes to getloadavg.c from coreutils and Emacs.
22717
22718         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
22719         Define to an expression, not to the empty string.
22720         Include cloexec.h and xalloc.h.
22721         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
22722         Use set_cloexec_flag rather than rolling our own.
22723         * lib/cloexec.c, lib/cloexec.h: New files.
22724
22725 2004-03-29  Paul Eggert  <eggert@twinsun.com>
22726
22727         * m4/cloexec.m4: New file.
22728
22729 2004-03-18  Paul Eggert  <eggert@twinsun.com>
22730
22731         * lib/getopt.h: Sync with libc CVS.
22732
22733 2004-03-18  Paul Eggert  <eggert@twinsun.com>
22734             Bruno Haible  <bruno@clisp.org>
22735
22736         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
22737         mbswidth.
22738
22739 2004-03-18  Paul Eggert  <eggert@twinsun.com>
22740             Bruno Haible  <bruno@clisp.org>
22741
22742         * lib/mbswidth.h: Include <wchar.h> only if
22743         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
22744         <wchar.h>.
22745         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
22746
22747 2004-03-09  Paul Eggert  <eggert@twinsun.com>
22748
22749         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
22750         Sync with libc CVS.
22751         * lib/getopt_int.h: New file, also synced from libc.
22752
22753 2004-03-09  Paul Eggert  <eggert@twinsun.com>
22754
22755         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
22756         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
22757         Bring back getopt.c, getopt.h, getopt1.c.
22758
22759 2004-03-07  Paul Eggert  <eggert@twinsun.com>
22760
22761         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
22762         All uses changed.  Check for sa_sigaction member; this fixes
22763         a bug first reported by Jason Andrade in
22764         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
22765
22766 2004-03-07  Paul Eggert  <eggert@twinsun.com>
22767
22768         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
22769         '#if' expressions.  Unlike the code it replaces, it does not
22770         depend on (defined _SC_PAGESIZE).  However, it does depend on
22771         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
22772         first reported by Jason Andrade in
22773         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
22774
22775 2004-02-25  Simon Josefsson  <jas@extundo.com>
22776
22777         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
22778
22779 2004-02-25  Simon Josefsson  <jas@extundo.com>
22780
22781         * lib/strdup.h: New file.
22782         * lib/strdup.c: Include it.
22783         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
22784         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
22785
22786 2004-02-23  Karl Berry  <karl@gnu.org>
22787
22788         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
22789         (from fencepost.gnu.org:/gd/gnuorg).
22790
22791 2004-02-23  Karl Berry  <karl@gnu.org>
22792
22793         * config/srclistvars.sh (GNUORG) [karl]: redefine.
22794         * config/srclist.txt: add maintain/standards documents.
22795
22796 2004-02-18  Bruno Haible  <bruno@clisp.org>
22797
22798         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
22799         Reported by Derek Robert Price <derek@ximbiot.com>.
22800
22801 2004-02-16  Karl Berry  <karl@gnu.org>
22802
22803         * config/mkinstalldirs, install-sh: update from automake.
22804
22805 2004-02-06  Karl Berry  <karl@gnu.org>
22806
22807         * m4/po.m4: update from gettext 0.14.1.
22808
22809 2004-02-06  Karl Berry  <karl@gnu.org>
22810
22811         * lib/config.charset: update from gettext 0.14.1.
22812
22813 2004-02-05  Paul Eggert  <eggert@twinsun.com>
22814
22815         Add comments and code, prompted by suggestions from Bruno Haible
22816         for sh-quote.
22817         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
22818         describing the enum quoting_style values.
22819         * lib/quotearg.c (quotearg_alloc): New function.
22820         (quotearg_buffer_restyled): Treat lone { and } as special.
22821         Treat = as special.  Work around bug with older shells
22822         that "see" a '\' that is really the 2nd byte of a multibyte char.
22823         Quote empty string with shell_quoting_style.
22824
22825 2004-02-03  Bruno Haible  <bruno@clisp.org>
22826
22827         * m4/pipe.m4: New file, from GNU gettext.
22828
22829 2004-02-03  Bruno Haible  <bruno@clisp.org>
22830
22831         * lib/pipe.h: New file, from GNU gettext.
22832         * lib/pipe.c: New file, from GNU gettext.
22833
22834 2004-01-27  Bruno Haible  <bruno@clisp.org>
22835
22836         * m4/execute.m4: New file, from GNU gettext.
22837
22838 2004-01-27  Bruno Haible  <bruno@clisp.org>
22839
22840         * lib/execute.h: New file, from GNU gettext.
22841         * lib/execute.c: New file, from GNU gettext.
22842         * lib/w32spawn.h: New file, from GNU gettext.
22843
22844 2004-01-24  Paul Eggert  <eggert@twinsun.com>
22845
22846         Merge from diffutils.
22847
22848         * lib/file-type.c (file_type): Add typed memory objects.
22849         * lib/file-type.h (S_TYPEISTMO): New macro.
22850
22851         * lib/c-stack.h (c_stack_action): Remove argv argument.
22852         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
22853         (die): Don't calculate message unless segv_action returns.
22854         (get_stack_location, min_address_from_argv, max_address_from_argv,
22855         volatile stack_base, volatile_stack_size): Remove.
22856         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
22857         that every segmentation violation is a stack overflow.  (Ouch!)
22858         See Debian bug 136249 (still outstanding) for more info about why
22859         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
22860
22861 2004-01-24  Paul Eggert  <eggert@twinsun.com>
22862
22863         Exit-status fix from coreutils.
22864
22865         Use exit_failure consistently in place of EXIT_FAILURE,
22866         so that program exit statuses are consistent on failure.
22867
22868         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
22869         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
22870         * lib/argmatch.h: Comment fix to match the above.
22871         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
22872         Now a macro referring to exit_failure, instead of a separate
22873         variable.  Include "exitfail.h" to get it.
22874         * lib/xstrtol.h: Include "exitfail.h".
22875         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
22876
22877         * lib/long-options.c (parse_long_options): Use prototype
22878         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
22879         for clarity.
22880
22881 2004-01-21  Jim Meyering  <jim@meyering.net>
22882
22883         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
22884         so as not to conflict with a different-sized __mktime_internal
22885         function in GNU libc.
22886         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
22887         Problem building statically-linked `ls' reported by Michael Brunnbauer.
22888
22889 2004-01-20  Karl Berry  <karl@gnu.org>
22890
22891         * config/config.guess: update from config.
22892
22893         * config/srclistvars.sh: GNUWWWLICENSES for karl.
22894
22895 2004-01-20  Bruno Haible  <bruno@clisp.org>
22896
22897         Safer stack allocation.
22898         * lib/setenv.c: Include allocsa.h.
22899         (alloca): Remove fallback definition.
22900         (freea): Remove macro.
22901         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
22902         instead of freea.
22903
22904 2004-01-20  Bruno Haible  <bruno@clisp.org>
22905
22906         * m4/eealloc.m4: New file, from GNU gettext.
22907
22908 2004-01-20  Bruno Haible  <bruno@clisp.org>
22909
22910         * m4/allocsa.m4: New file, from GNU gettext.
22911
22912 2004-01-20  Bruno Haible  <bruno@clisp.org>
22913
22914         * lib/xallocsa.h: New file, from GNU gettext.
22915         * lib/xallocsa.c: New file, from GNU gettext.
22916
22917 2004-01-20  Bruno Haible  <bruno@clisp.org>
22918
22919         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
22920
22921 2004-01-20  Bruno Haible  <bruno@clisp.org>
22922
22923         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
22924         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
22925         specially.
22926
22927 2004-01-20  Bruno Haible  <bruno@clisp.org>
22928
22929         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
22930         patch.
22931
22932 2004-01-20  Bruno Haible  <bruno@clisp.org>
22933
22934         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
22935
22936 2004-01-20  Bruno Haible  <bruno@clisp.org>
22937
22938         * lib/eealloc.h: New file.
22939
22940 2004-01-20  Bruno Haible  <bruno@clisp.org>
22941
22942         * lib/binary-io.h: Avoid warnings on Cygwin.
22943
22944 2004-01-20  Bruno Haible  <bruno@clisp.org>
22945
22946         * lib/allocsa.h: New file, from GNU gettext.
22947         * lib/allocsa.c: New file, from GNU gettext.
22948
22949 2004-01-18  Karl Berry  <karl@gnu.org>
22950
22951         * doc/gpl.texi, doc/lgpl.texi: new files.
22952
22953 2004-01-18  Karl Berry  <karl@gnu.org>
22954
22955         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
22956         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
22957
22958 2004-01-15  Paul Eggert  <eggert@twinsun.com>
22959
22960         Merge from coreutils.
22961
22962         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
22963         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
22964         (gl_DEFAULT_POSIX2_VERSION): Move
22965         the documentation from 'configure' into 'config.hin',
22966         so that 'configure --help' isn't burdened by it and
22967         we don't have to worry about its formatting there.
22968         Reword the documentation so that it's more succinct
22969         and can be run together into a single paragraph.
22970         * m4/same.m4 (gl_SAME): Check for pathconf.
22971
22972 2004-01-15  Paul Eggert  <eggert@twinsun.com>
22973
22974         Merge from coreutils.
22975
22976         * lib/posixver.c: Include posixver.h.
22977
22978         * lib/same.c: Include <stdbool.h>, <limits.h>.
22979         (_POSIX_NAME_MAX): Define if not defined.
22980         (MIN): New macro.
22981         (same_name): If file names are silently truncated, report
22982         that the file names are the same if they are the same after
22983         the silent truncation.
22984
22985         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
22986         conversion function.
22987         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
22988         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
22989         longer needed.
22990
22991 2004-01-15  Jim Meyering  <jim@meyering.net>
22992
22993         Merge from coreutils.
22994
22995         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
22996         if no library is required.
22997         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
22998         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
22999         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
23000         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
23001         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
23002         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
23003         value, $ac_cv_search_crypt, if it's "none required".
23004         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
23005         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
23006         not gl_FUNC_GETLOADAVG.
23007         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
23008         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
23009
23010 2004-01-15  Jim Meyering  <jim@meyering.net>
23011
23012         Merge from coreutils.
23013
23014         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
23015         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
23016         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
23017
23018         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
23019         optional configure-time default.
23020
23021         * lib/version-etc.c (version_etc_copyright): Update copyright date.
23022
23023         * lib/xreadlink.c (xreadlink): Correct outdated comment.
23024
23025 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
23026
23027         Merge from coreutils.
23028
23029         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
23030         value, $ac_cv_search_nanosleep, if it's "none required".
23031
23032 2004-01-14  Paul Eggert  <eggert@twinsun.com>
23033
23034         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
23035         with like-named macro in fnmatch.c.
23036         (EXT): Use an internal constant instead.
23037
23038         Merge fnmatch patches from glibc.
23039         * lib/fnmatch.c (mbsinit): Remove define.
23040         Add libc_hidden_ver (__fnmatch, fnmatch).
23041         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
23042         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
23043
23044 2004-01-14  Karl Berry  <karl@gnu.org>
23045
23046         * config/install-sh: update from automake.
23047
23048 2004-01-13  Karl Berry  <karl@gnu.org>
23049
23050         * config/install-sh: update from automake.
23051
23052 2004-01-09  Karl Berry  <karl@gnu.org>
23053
23054         * config/install-sh: update from automake.
23055
23056 2004-01-05  Karl Berry  <karl@gnu.org>
23057
23058         * config/config.{sub,guess}: update from config.
23059
23060 2003-12-31  Karl Berry  <karl@gnu.org>
23061
23062         * config/depcomp: update from automake.
23063
23064 2003-12-14  Karl Berry  <karl@gnu.org>
23065
23066         * lib/config.charset: update from gettext-runtime.
23067
23068 2003-12-03  Paul Eggert  <eggert@twinsun.com>
23069
23070         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
23071         Bug reported by Alfred M. Szmidt.
23072
23073 2003-12-03  Bruno Haible  <bruno@clisp.org>
23074
23075         * m4/gettext.m4: Upgrade from gettext-0.13.
23076         * m4/po.m4: Upgrade from gettext-0.13.
23077         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
23078         * m4/intmax.m4: New file, from gettext-0.13.
23079         * m4/printf-posix.m4: New file, from gettext-0.13.
23080
23081 2003-11-29  Karl Berry  <karl@gnu.org>
23082
23083         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
23084
23085 2003-11-25  Paul Eggert  <eggert@twinsun.com>
23086             Bruno Haible  <bruno@clisp.org>
23087
23088         * lib/printf-parse.h: Don't include sys/types.h.
23089         (ARG_NONE): New macro.
23090         (char_directive): Change type of *arg_index fields to size_t.
23091         * lib/printf-parse.c: Don't include sys/types.h.
23092         (SSIZE_MAX): Remove macro.
23093         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
23094         Remove unnecessary overflow check.
23095         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
23096         fields.
23097
23098 2003-11-25  Bruno Haible  <bruno@clisp.org>
23099
23100         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
23101
23102 2003-11-25  Bruno Haible  <bruno@clisp.org>
23103
23104         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
23105         gt_TYPE_SSIZE_T.
23106
23107 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23108
23109         * modules/alloca: Remove dependency on xalloc.
23110
23111 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23112
23113         * lib/alloca.c: Remove dependency on xalloc module.
23114         (xalloc_die): Remove.
23115         (memory_full) [!defined emacs]: New macro.
23116         [!defined emacs]: Don't include xalloc.h.
23117         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
23118         address arithmetic overflows.  Change datatypes a bit to avoid
23119         unnecessary casts.
23120
23121 2003-11-22  Jim Meyering  <jim@meyering.net>
23122
23123         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
23124         s/size/size_t/.
23125
23126 2003-11-21  Karl Berry  <karl@gnu.org>
23127
23128         * config/config.{sub,guess}: update from config.
23129
23130 2003-11-18  Karl Berry  <karl@gnu.org>
23131
23132         * config/config.{sub,guess}: update from config.
23133
23134         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
23135
23136 2003-11-17  Paul Eggert  <eggert@twinsun.com>
23137
23138         * README: Mention that S+T cannot overflow if S is the size of
23139         an existing object and T is sufficiently small.
23140
23141 2003-11-17  Jim Meyering  <jim@meyering.net>
23142
23143         On systems without utime and without a utimes function capable of
23144         dealing with a NULL struct utimbuf* argument, this utime replacement
23145         could -- in unusual circumstances -- leak a file descriptor.
23146         * lib/utime.c: Include <unistd.h> and <errno.h>.
23147         (utime_null): Be sure to close `fd' and to preserve errno.
23148         Reported by Geoff Collyer via Arnold Robbins.
23149
23150 2003-11-17  Bruno Haible  <bruno@clisp.org>
23151
23152         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
23153         (Depends-on): Add xsize.
23154
23155 2003-11-17  Bruno Haible  <bruno@clisp.org>
23156
23157         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
23158
23159 2003-11-17  Bruno Haible  <bruno@clisp.org>
23160
23161         * lib/vasnprintf.c (alloca): Remove fallback definition.
23162         (freea): Remove definition.
23163         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
23164         Reported by Paul Eggert.
23165
23166 2003-11-16  Paul Eggert  <eggert@twinsun.com>
23167             Bruno Haible  <bruno@clisp.org>
23168
23169         Protect against address arithmetic overflow.
23170         * lib/printf-args.h: Include stddef.h.
23171         (arguments): Change type of field 'count' to size_t.
23172         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
23173         'unsigned int' where appropriate.
23174         * lib/printf-parse.h: Include sys/types.h.
23175         (char_directive): Change type of *arg_index fields to ssize_t.
23176         (char_directives): Change type of fields 'count', max_*_length to
23177         size_t.
23178         * lib/printf-parse.c: Include sys/types.h and xsize.h.
23179         (SSIZE_MAX): Define fallback value.
23180         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
23181         instead of 'int' where appropriate. Check a_allocated, d_allocated
23182         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
23183         * lib/vasnprintf.c: Include xsize.h.
23184         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
23185         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
23186         overflow. Avoid wraparound when converting a width or precision from
23187         decimal to binary.
23188
23189 2003-11-16  Bruno Haible  <bruno@clisp.org>
23190
23191         Update from GNU gettext.
23192         * lib/printf-parse.c: Generalize to it can be compiled for wide
23193         strings.
23194         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
23195         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
23196         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
23197         SNPRINTF): New macros.
23198         Don't include <alloca.h> if the file is used inside libintl.
23199         (local_wcslen): New function, for Solaris 2.5.1.
23200         (VASNPRINTF): Use it instead of wcslen.
23201
23202 2003-11-16  Bruno Haible  <bruno@clisp.org>
23203
23204         * lib/xsize.h (xmax): New function.
23205         (xsum, xsum3, xsum4): Declare as "pure" functions.
23206
23207 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23208
23209         * modules/xalloc (Files): Undo latest change, since xalloc.h
23210         no longer needs SIZE_MAX or PTRDIFF_MAX.
23211
23212 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23213
23214         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
23215         gl_PTRDIFF_MAX.
23216
23217 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23218
23219         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
23220         "return", to pacify some unknown compiler.  Problem reported
23221         by Joerg Schilling.
23222
23223 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23224
23225         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
23226         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
23227         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
23228         heuristic is just as accurate as far as we know, and it removes a
23229         dependency on size_max.m4 and ptrdiff_max.m4.
23230
23231 2003-11-11  Bruno Haible  <bruno@clisp.org>
23232
23233         * modules/xsize (Files): Add m4/size_max.m4.
23234         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
23235
23236 2003-11-11  Bruno Haible  <bruno@clisp.org>
23237
23238         * m4/size_max.m4: New file.
23239         * m4/ptrdiff_max.m4: New file.
23240         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
23241         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
23242         (gl_XALLOC): Invoke it.
23243
23244 2003-11-11  Bruno Haible  <bruno@clisp.org>
23245
23246         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
23247         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
23248         defined.
23249
23250 2003-11-10  Paul Eggert  <eggert@twinsun.com>
23251
23252         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
23253         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
23254         rejected some allocations of exactly SIZE_MAX - 2 bytes.
23255         From Bruno Haible.
23256         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
23257         not (size_t) -1, since it's defined here.
23258
23259 2003-11-09  Karl Berry  <karl@gnu.org>
23260
23261         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
23262
23263 2003-11-06  Paul Eggert  <eggert@twinsun.com>
23264
23265         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
23266         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
23267         Reject sizes of exactly SIZE_MAX bytes.
23268         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
23269         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
23270
23271 2003-11-05  Bruno Haible  <bruno@clisp.org>
23272
23273         * lib/xsize.h: Include limits.h, to avoid a possible collision with
23274         SIZE_MAX defined in <limits.h> on Solaris.
23275
23276 2003-11-04  Jim Meyering  <jim@meyering.net>
23277
23278         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
23279         variable names, rather than @VAR@.
23280         * modules/poll: Likewise.
23281
23282 2003-11-04  Bruno Haible  <bruno@clisp.org>
23283
23284         * modules/xsize: New file.
23285         * modules/linebreak: Depend on xsize.
23286         * MODULES.html.sh (func_all_modules): Add xsize.
23287
23288 2003-11-04  Bruno Haible  <bruno@clisp.org>
23289
23290         * m4/xsize.m4: New file.
23291
23292 2003-11-04  Bruno Haible  <bruno@clisp.org>
23293
23294         * lib/xsize.h: New file.
23295         * lib/linebreak.c: Include xsize.h.
23296         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
23297         argument for overflow.
23298         Suggested by Paul Eggert.
23299
23300 2003-11-03  Karl Berry  <karl@gnu.org>
23301
23302         * config/config.{guess,sub}: update from config.
23303
23304 2003-11-03  Jim Meyering  <jim@meyering.net>
23305
23306         * modules/userspec (lib_SOURCES): Add userspec.h.
23307         (Include): Add "userspec.h".
23308         Improve description.
23309
23310 2003-11-03  Jim Meyering  <jim@meyering.net>
23311
23312         * lib/userspec.c: Include "userspec.h".
23313         * lib/userspec.h: New file.
23314
23315 2003-11-03  Bruno Haible  <bruno@clisp.org>
23316
23317         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
23318
23319 2003-11-03  Bruno Haible  <bruno@clisp.org>
23320
23321         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
23322         available, to avoid (extremely rare) race condition.
23323         Suggested by Paul Eggert.
23324
23325 2003-11-02  Karl Berry  <karl@gnu.org>
23326
23327         * config/srclist.txt (vasprintf.c): sync broken, sigh.
23328
23329 2003-10-31  Paul Eggert  <eggert@twinsun.com>
23330
23331         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
23332         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
23333         (read_filesystem_list): Set and use me_type_malloced.
23334         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
23335         whatever the type happens to be), for brevity and consistency.
23336         Check for size calculation overflow on Alphas running OSF/1.
23337
23338 2003-10-31  Jim Meyering  <jim@meyering.net>
23339
23340         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
23341
23342         * lib/linebuffer.c: Include <string.h> for declaration of memset.
23343
23344 2003-10-30  Paul Eggert  <eggert@twinsun.com>
23345             Bruno Haible  <bruno@clisp.org>
23346
23347         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
23348         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
23349
23350 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
23351
23352         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
23353         netbsd*-gnu*.  Suggested by Robert Millan.
23354
23355 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23356
23357         * modules/group-member: Depend on stdbool.
23358
23359 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23360
23361         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
23362
23363 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23364
23365         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
23366         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
23367         after the 'gnu' in these cases.  This fixes some bugs in the
23368         previous change, and is based on suggestions by Robert Millan.
23369
23370 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23371
23372         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
23373         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
23374         no longer needed.
23375         * lib/quotearg.c (quotearg_n_options): Use it.
23376         * lib/group-member.c: Include <stdbool.h>.
23377         (free_group_info): Arg is now const *; don't free arg.
23378         (get_group_info): Now returns bool and accepts struct group_info *,
23379         rather than returning a malloc'ed struct group_info *.
23380         All uses changed.  Check for overflow in internal size calculation.
23381
23382         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
23383         rather than xmalloc/xrealloc.
23384         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
23385         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
23386         conformance bug: the old code used a pointer after freeing the
23387         storage that it addressed.
23388         * lib/hash.c (hash_initialize): Simplify the code by using
23389         xalloc_oversized rather than doing it by hand.
23390         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
23391         the buffer preserved.  Use free and xmalloc instead.
23392         * lib/quotearg.c (quotearg_n_options): Likewise.
23393         Use a simpler test for size overflow.  Don't use xalloc_oversized
23394         because unsigned int might be wider than size_t (!); this suggests
23395         that we should switch from unsigned int to size_t for slot numbers.
23396
23397 2003-10-28  Paul Eggert  <eggert@twinsun.com>
23398
23399         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
23400         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
23401         NetBSD kernels.  Requested by Richard Stallman.
23402
23403 2003-10-27  Paul Eggert  <eggert@twinsun.com>
23404
23405         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
23406         to allocate the returned structure.  Do not allocate a subarray,
23407         as x2nrealloc will do that.
23408         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
23409         instead of xnrealloc.
23410         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
23411
23412 2003-10-27  Bruno Haible  <bruno@clisp.org>
23413
23414         * lib/stdbool_.h: Better support for BeOS.
23415
23416 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23417
23418         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
23419         now uses inline.
23420
23421 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23422
23423         * lib/xalloc.h (xalloc_oversized): New static inline function, for
23424         callers that want to do their own size-overflow checking.  Include
23425         <stdbool.h>, since xalloc_oversized returns bool.
23426         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
23427         to use xalloc_oversized.
23428
23429         Add two functions x2realloc, x2nrealloc, for programs that grow
23430         arrays dynamically by doubling their sizes.
23431         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
23432         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
23433         New functions.
23434
23435         Port to C99 semantics for 'inline' of external functions.
23436         Bug reported by Bruno Haible.
23437         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
23438         with the old contents of xnmalloc.
23439         (xnmalloc, xmalloc): Use it.
23440         (xnrealloc_inline): New static inline function,
23441         with the old contents of xnrealloc.
23442         (xnrealloc, xrealloc): Use it.
23443
23444         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
23445         that.
23446
23447 2003-10-26  Karl Berry  <karl@gnu.org>
23448
23449         * config/srclist.txt (COPYING.DOC): no longer available from
23450         /gd/gnuorg; don't know where the ultimate source is.
23451
23452 2003-10-25  Paul Eggert  <eggert@twinsun.com>
23453
23454         Fix several address-calculation bugs in the hash modules,
23455         plus some minor code cleanup.
23456
23457         * lib/hash.h: Include <stdbool.h>, for bool.
23458         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
23459         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
23460         hash_get_n_entries, hash_get_max_bucket_length,
23461         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
23462         hash_rehash): Use size_t rather than unsigned.
23463         * lib/hash.c (struct hash_table, hash_get_n_buckets,
23464         hash_get_n_buckets_used, hash_get_n_entries,
23465         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
23466         hash_get_entries, hash_do_for_each, hash_string, is_prime,
23467         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
23468         Likewise.
23469         (SIZE_MAX): Define if not defined.
23470         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
23471         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
23472         hash_print):
23473         Use const * when possible.
23474         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
23475         (check_tuning): Fix bug: if tuning parameters were very close to
23476         0 or 1, rounding errors could have caused subscript violations.
23477         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
23478         (hash_initialize): Add 'fail:' label
23479         to free table and return NULL, and use it to simplify code.
23480         Use calloc rather than clearing the storage ourself.
23481         (hash_initialize, hash_rehash): Check for arithmetic overflow in
23482         buffer size calculations.
23483         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
23484         Include <stddef.h>, for size_t.
23485         * lib/hash-pjw.c (hash_pjw): Likewise.
23486         Switch to method described by Bruno Haible.
23487         Include <limits.h>, for CHAR_BIT.
23488         (SIZE_BITS): New macro.
23489
23490 2003-10-23  Paul Eggert  <eggert@twinsun.com>
23491
23492         * m4/getline.m4 (AM_FUNC_GETLINE):
23493         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
23494         hosts.  Problem reported by Derek Robert Price in
23495         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
23496         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
23497         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
23498
23499 2003-10-21  Paul Eggert  <eggert@twinsun.com>
23500
23501         * lib/getndelim2.c (getndelim2): When size calculation overflows,
23502         ceiling the allocation at NMAX bytes rather than silently
23503         discarding input bytes before NMAX is reached.  This makes
23504         a difference only if NMAX exceeds SIZE_MAX / 2.
23505
23506         * lib/obstack.c: Merge from glibc.
23507         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
23508         Add libc_hidden_def (_obstack_newchunk).
23509         (_obstack_free) [! defined _LIBC]: Remove.
23510         [defined _LIBC]: Make a strong alias from obstack_free, rather than
23511         a clone of the function body.
23512         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
23513         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
23514
23515         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
23516         glibc.
23517         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
23518         arg to memcpy.
23519
23520         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
23521         (obstack_ptr_grow_fast, obstack_int_grow_fast):
23522         Don't use lvalue casts, as GCC plans to remove support for them
23523         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
23524         was also present in the non-GCC version, indicating that this
23525         code had always been buggy and had never been widely used.
23526         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
23527         Use the fast variant of each macro, rather than copying the
23528         definiens of the fast variant; that way, we'll be more likely to
23529         catch future bugs in the fast variants.
23530
23531 2003-10-20  Bruno Haible  <bruno@clisp.org>
23532
23533         * modules/wait-process: New file.
23534         * MODULES.html.sh (func_all_modules): Add wait-process.
23535
23536 2003-10-20  Bruno Haible  <bruno@clisp.org>
23537
23538         * m4/wait-process.m4: New file.
23539
23540 2003-10-20  Bruno Haible  <bruno@clisp.org>
23541
23542         * lib/wait-process.h: New file, from GNU gettext.
23543         * lib/wait-process.c: New file, from GNU gettext.
23544
23545 2003-10-19  Jim Meyering  <jim@meyering.net>
23546
23547         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
23548         HPUX 10.20.
23549
23550 2003-10-18  Karl Berry  <karl@gnu.org>
23551
23552         * config/config.guess: update from config.
23553
23554 2003-10-16  Paul Eggert  <eggert@twinsun.com>
23555
23556         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
23557         (getgroups): First arg is int, not size_t.
23558         Don't let 'free' mangle errno.
23559
23560 2003-10-16  Paul Eggert  <eggert@twinsun.com>
23561
23562         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
23563
23564 2003-10-16  Karl Berry  <karl@gnu.org>
23565
23566         * config/config.{guess,sub}: update from config.
23567
23568 2003-10-16  Jim Meyering  <jim@meyering.net>
23569
23570         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
23571         memcpy.
23572
23573 2003-10-15  Paul Eggert  <eggert@twinsun.com>
23574
23575         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
23576         (SIZE_MAX): Remove.
23577         (new_exclude, add_exclude_file): Initial size no longer needs to
23578         be a power of 2.
23579         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
23580         our own address arithmetic overflow checking.
23581
23582         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
23583         (fnmatch): Do not alloca more than 2000 wide characters;
23584         instead, use malloc for large buffers.
23585         Check for address arithmetic overflow, and return -1
23586         with errno set to ENOMEM in that case.
23587         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
23588         (NEW_PATTERN): Do not alloca more than 8000 bytes;
23589         instead, return -1.  Check for address arithmetic overflow.
23590
23591 2003-10-14  Paul Eggert  <eggert@twinsun.com>
23592
23593         Handle invalid suffixes and overflow independently, so that
23594         callers can treat them independently as needed.  Fix some bugs in
23595         suffix handling, e.g., "100k@" was not diagnosed as an invalid
23596         suffix for a human-readable blocksize.  The major caller-visible
23597         change is the addition of a new
23598         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
23599         that both overflow and suffix chars were found.
23600
23601         * lib/human.c (humblock): Don't check separately for invalid suffix
23602         char; that is xstrtoumax's job (now that its bug is fixed).
23603         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
23604         INTMAX_MAX]: New macros.
23605         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
23606         TYPE_MAXIMUM): New macros.
23607         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
23608         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
23609         if overflow occurs, as it's what __strtol does and it's more useful
23610         in practice.
23611         (__xstrtol): If __strtol reports some error other than ERANGE,
23612         reflect it to the caller as LONGINT_INVALID.  If it reports
23613         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
23614         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
23615         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
23616         value.
23617         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
23618         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
23619         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
23620         [defined UINTMAX_MAX]: New macros.
23621
23622 2003-10-14  Bruno Haible  <bruno@clisp.org>
23623
23624         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
23625
23626 2003-10-14  Bruno Haible  <bruno@clisp.org>
23627
23628         * m4/sig_atomic_t: New file, from GNU gettext.
23629         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
23630
23631 2003-10-14  Bruno Haible  <bruno@clisp.org>
23632
23633         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
23634         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
23635         Also use volatile where needed.
23636
23637 2003-10-12  Paul Eggert  <eggert@twinsun.com>
23638
23639         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
23640         Change maintainer from Bruno Haible to 'all'.
23641
23642 2003-10-12  Paul Eggert  <eggert@twinsun.com>
23643
23644         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
23645
23646 2003-10-12  Paul Eggert  <eggert@twinsun.com>
23647
23648         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
23649         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
23650         and define in terms of the other primitives.
23651         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
23652         (SIZE_MAX): Define if not already defined.
23653         (array_size_overflow): New function.
23654         (xalloc_die): Abort instead of exiting if 'error' returns.
23655         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
23656         (xmalloc, xrealloc): Use them.
23657         (xcalloc): Check for address arithmetic overflow.
23658         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
23659         a bit faster than strcpy.
23660
23661 2003-10-10  Simon Josefsson  <jas@extundo.com>
23662
23663         * modules/argp (Depends-on): Add restrict and strcase.
23664
23665 2003-10-10  Simon Josefsson  <jas@extundo.com>
23666
23667         * m4/argp.m4: Add AC_C_INLINE.
23668
23669 2003-10-08  Paul Eggert  <eggert@twinsun.com>
23670
23671         Merge getpass from libc, plus a few fixes.
23672
23673         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
23674         Include <stdbool.h>.
23675         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
23676         __fsetlocking to empty.
23677         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
23678         do include <bits/libc-lock.h>.
23679         Do not include <fcntl.h>; not needed.
23680         [_LIBC]: Include <wchar.h>.
23681         (NOTCANCEL_MODE): New macro.
23682         (flockfile, funlockfile) [_LIBC]: New macros.
23683         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
23684         [!_LIBC]: New macros.
23685         (call_fclose): New function.
23686         (getpass): Use it.  Save tty stream separately; this simplifies the
23687         code and makes it more reliable if stdin happens to equal stdout.
23688         Invoke __fsetlocking on tty.
23689         Handle thread cancellation if needed.
23690         Namespace cleanup (use __tcgetattr, __getline).
23691         Use bool for Booleans.
23692         [USE_IN_LIBIO]: Handle wide streams.
23693         [!_LIBC]: Unconditionally do the fseek, since we don't know what
23694         stream might go where.
23695
23696         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
23697         doesn't have to include <stdio.h> before us.
23698         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
23699         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
23700         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
23701         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
23702         if not declared, so that we can use getpass.c code from libc without
23703         rewriting it.
23704         (flockfile, ftrylockfile, funlockfile): New macros.
23705
23706 2003-10-08  Paul Eggert  <eggert@twinsun.com>
23707
23708         * modules/getpass: Depend on stdbool.
23709
23710 2003-10-08  Paul Eggert  <eggert@twinsun.com>
23711
23712         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
23713
23714 2003-10-07  Karl Berry  <karl@gnu.org>
23715
23716         * config/config.{guess,sub}: update from config.
23717
23718 2003-10-06  Jim Meyering  <jim@meyering.net>
23719             Bruno Haible  <bruno@clisp.org>
23720
23721         This lets translators provide better translations for the
23722         "Written by ..." part of --version output.
23723         * lib/version-etc.h: Include stdarg.h.
23724         (version_etc_copyright): Declare as readonly.
23725         (version_etc): Make this function variadic with a NULL-terminated list
23726         of author name strings.
23727         (version_etc_va): New declaration.
23728         * lib/version-etc.c: Include stdarg.h, stdlib.h.
23729         (version_etc_copyright): Declare as readonly.
23730         (version_etc_va): New function. Provide a different translatable string
23731         for each possible number of authors < 10. Abbreviate when there are 10
23732         authors or more.
23733         (version_etc): Make this function variadic. Call version_etc_va.
23734         Suggestion from Gary V. Vaughan.
23735
23736         * lib/long-options.h (parse_long_options): Change prototype: the
23737         authors string is moved to the end and becomes variadic.
23738         * lib/long-options.c: Include stdarg.h.
23739         (parse_long_options): Make this function variadic, too.
23740         Call version_etc_va, not version_etc.
23741
23742 2003-10-06  Bruno Haible  <bruno@clisp.org>
23743
23744         * modules/version-etc-2: Remove file.
23745         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
23746
23747 2003-10-06  Bruno Haible  <bruno@clisp.org>
23748
23749         * modules/fatal-signal: New file.
23750         * MODULES.html.sh (func_all_modules): Add fatal-signal.
23751
23752 2003-10-06  Bruno Haible  <bruno@clisp.org>
23753
23754         * m4/fatal-signal.m4: New file.
23755         * m4/signalblocking.m4: New file, from GNU gettext.
23756
23757 2003-10-06  Bruno Haible  <bruno@clisp.org>
23758
23759         * lib/version-etc-2.h: Remove file.
23760         * lib/version-etc-2.c: Remove file.
23761
23762 2003-10-06  Bruno Haible  <bruno@clisp.org>
23763
23764         * lib/fatal-signal.h: New file, from GNU gettext.
23765         * lib/fatal-signal.c: New file, from GNU gettext.
23766
23767 2003-10-05  Paul Eggert  <eggert@twinsun.com>
23768
23769         * README: Rework advice for preventing empty .o files.
23770         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
23771         not <sys/types.h>.
23772
23773 2003-10-04  Karl Berry  <karl@gnu.org>
23774
23775         * lib/argp*: update from libc.
23776
23777 2003-10-04  Karl Berry  <karl@gnu.org>
23778
23779         * config/config.{guess,sub}: update from config.
23780
23781 2003-10-02  Bruno Haible  <bruno@clisp.org>
23782
23783         * modules/lchown (Include): Add lchown.h.
23784         * modules/time_r (Include): Use "..." syntax.
23785         * modules/xgetdomainname (Include): Add xgetdomainname.h.
23786
23787 2003-10-01  Simon Josefsson  <jas@extundo.com>
23788
23789         * MODULES.html.sh (func_all_modules): Move gethostname from section
23790         'based on' to section 'lacking' POSIX:2001.
23791
23792 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
23793
23794         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
23795         to output mode on the same stream.
23796
23797 2003-09-29  Paul Eggert  <eggert@twinsun.com>
23798
23799         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
23800         Fix arg typo in previous patch.
23801
23802 2003-09-28  Jim Meyering  <jim@meyering.net>
23803
23804         * lib/error.c: Correct cpp indentation.
23805
23806 2003-09-27  Paul Eggert  <eggert@twinsun.com>
23807
23808         * modules/free: New file.
23809
23810 2003-09-27  Paul Eggert  <eggert@twinsun.com>
23811
23812         * m4/free.m4: New file.
23813
23814 2003-09-27  Paul Eggert  <eggert@twinsun.com>
23815
23816         * lib/minmax.h (MIN, MAX)
23817         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
23818         Omit the special code that used __typeof__, since we worry that
23819         it could be more trouble than it's worth.  See:
23820         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
23821         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
23822
23823         * lib/free.c: New file.
23824
23825 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
23826
23827         Trivial fixes to Makefile.am parts of module listings.
23828         * modules/strstr: Append strstr.h to lib_SOURCES.
23829         * modules/strcase: Likewise, for strcase.h.
23830
23831 2003-09-27  Karl Berry  <karl@gnu.org>
23832
23833         * config/mkinstalldirs: update from automake.
23834
23835 2003-09-26  Paul Eggert  <eggert@twinsun.com>
23836
23837         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
23838         (error_tail): Do not loop, reallocating temporary buffer, since
23839         the output cannot contain more wide characters than the input
23840         contains bytes, the size must be big enough already.  This avoids
23841         one potential size overflow calculation.  Check for size overflow
23842         when calculating temporary buffer size.  Free temporary buffer
23843         when done, if it was allocated with malloc; this plugs a memory
23844         leak.  Remove casts from void * to pointers, that are no longer
23845         needed now that we're assuming C89 or better.
23846
23847         Merge error changes from glibc.
23848
23849         * lib/error.c, error.h: Update copyright notice header to match glibc.
23850         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
23851         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
23852         Disable cancellation while printing error.
23853         * lib/error.h: Prepend __ to parameter names.
23854
23855 2003-09-26  Jim Meyering  <jim@meyering.net>
23856
23857         * lib/error.c (error_tail): Move some declarations
23858         into inner scope where the local variables are used.
23859
23860 2003-09-26  Bruno Haible  <bruno@clisp.org>
23861
23862         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
23863         stpncpy().
23864         Don't define stpncpy through config.h; it's now done through stpncpy.h.
23865
23866 2003-09-26  Bruno Haible  <bruno@clisp.org>
23867
23868         * lib/stpncpy.h (gnu_stpncpy): New declaration.
23869         (stpncpy): Define as alias for gnu_stpncpy.
23870         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
23871
23872 2003-09-25  Simon Josefsson  <jas@extundo.com>
23873
23874         * lib/xgetdomainname.h: New file.
23875         * lib/xgetdomainname.c: New file.
23876
23877 2003-09-25  Simon Josefsson  <jas@extundo.com>
23878             Bruno Haible  <bruno@clisp.org>
23879
23880         * modules/getdomainname: New file.
23881         * modules/xgetdomainname: New file.
23882         * MODULES.html.sh (func_all_modules): Add getdomainname,
23883         xgetdomainname.
23884
23885 2003-09-25  Simon Josefsson  <jas@extundo.com>
23886             Bruno Haible  <bruno@clisp.org>
23887
23888         * m4/getdomainname.m4: New file.
23889
23890 2003-09-25  Simon Josefsson  <jas@extundo.com>
23891             Bruno Haible  <bruno@clisp.org>
23892
23893         * lib/getdomainname.h: New file.
23894         * lib/getdomainname.c: New file.
23895
23896 2003-09-25  Karl Berry  <karl@gnu.org>
23897
23898         * lib/argp-fmtstream.c, argp-help.c: update from libc.
23899
23900 2003-09-25  Karl Berry  <karl@gnu.org>
23901
23902         * config/install-sh: update from automake.
23903
23904 2003-09-25  Bruno Haible  <bruno@clisp.org>
23905
23906         * modules/version-etc-2: New file, from modules/version-etc with
23907         modifications.
23908         * MODULES.html.sh (func_all_modules): Add version-etc-2.
23909
23910 2003-09-25  Bruno Haible  <bruno@clisp.org>
23911
23912         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
23913         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
23914
23915 2003-09-24  Simon Josefsson  <jas@extundo.com>
23916
23917         * modules/xgethostname: Add xgethostname.h.
23918
23919 2003-09-24  Paul Eggert  <eggert@twinsun.com>
23920
23921         * lib/linebuffer.c (freebuffer): Don't free the argument, just
23922         the buffer associated with the argument.  Bug reported by
23923         Simon Josefsson.
23924
23925 2003-09-24  Paul Eggert  <eggert@twinsun.com>
23926
23927         * README: Document assumptions that 'int' is at least 32 bits
23928         wide, that integer arithmetic is 2's complement without overflow,
23929         that there are no holes in integer values, that adding sizes of
23930         two nonoverlapping objects can't overflow, and that all-bits-zero
23931         yields scalar zero.  Fix spelling and capitalization typos.
23932
23933 2003-09-19  Karl Berry  <karl@gnu.org>
23934
23935         * lib/argp.h: update from libc.
23936
23937 2003-09-17  Paul Eggert  <eggert@twinsun.com>
23938
23939         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
23940         to avoid spurious warnings like "AC_RUN_IFELSE was called before
23941         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
23942
23943 2003-09-17  Paul Eggert  <eggert@twinsun.com>
23944
23945         * gnulib-tool: Use "test -h", not "test -L", for portability
23946         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
23947         (tags_regexp): Remove, since \| doesn't conform to POSIX.
23948         (sed_extract_prog): Issue s commands one-by-one, rather than
23949         using \| in one s command.
23950
23951 2003-09-16  Paul Eggert  <eggert@twinsun.com>
23952
23953         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
23954         input error, instead of returning NULL the next time we are called
23955         (and therefore losing track of errno).
23956
23957 2003-09-16  Bruno Haible  <bruno@clisp.org>
23958
23959         * gnulib-tool (func_create_testdir): Warn about duplicated
23960         dependencies.
23961
23962 2003-09-15  Paul Eggert  <eggert@twinsun.com>
23963
23964         * modules/argmatch, modules/fatal, modules/obstack,
23965         modules/xalloc, modules/xgethostname: Sort dependencies by
23966         importance, not alphabetically.
23967
23968 2003-09-15  Paul Eggert  <eggert@twinsun.com>
23969
23970         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
23971         fails, so that the caller gets the proper errno.
23972
23973         * lib/readutmp.c (read_utmp): Likewise.
23974         Check for fstat error.  Close stream and free storage
23975         when failing.
23976
23977 2003-09-14  Karl Berry  <karl@gnu.org>
23978
23979         * config/srclist.txt (strdup.c): disable for c89 changes.
23980
23981 2003-09-14  Jim Meyering  <jim@meyering.net>
23982
23983         * lib/getloadavg.c: Correct cpp indentation.
23984         * lib/strdup.c: Likewise.
23985         * lib/vasnprintf.c: Likewise.
23986
23987 2003-09-14  Bruno Haible  <bruno@clisp.org>
23988
23989         * modules/fwriteerror: New file.
23990         * MODULES.html.sh (func_all_modules): Add fwriteerror.
23991
23992 2003-09-14  Bruno Haible  <bruno@clisp.org>
23993
23994         * lib/fwriteerror.h: New file.
23995         * lib/fwriteerror.c: New file.
23996
23997 2003-09-12  Paul Eggert  <eggert@twinsun.com>
23998
23999         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
24000         modules/xgethostname, modules/xalloc: Depend on exit.
24001
24002 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24003
24004         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
24005
24006         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
24007         and AC_MINIX, too, so that their extensions are available.
24008
24009         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
24010         This macro has been superseded by gl_BACKUPFILE.
24011
24012         More patches to assume C89 or better.
24013
24014         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
24015
24016         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
24017         unconditionally.
24018         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
24019         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
24020         Include <string.h>, <stdlib.h> unconditionally.
24021         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
24022         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
24023         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
24024         headers or for string.h.
24025         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
24026         or strtoul.
24027
24028         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
24029         headers.
24030         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
24031         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24032         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
24033         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
24034         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24035         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
24036         memcpy, memset.
24037         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
24038         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
24039         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
24040         strtol.
24041         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
24042         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
24043         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
24044         strtoul.
24045
24046 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24047
24048         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
24049         * lib/obstack.c [!defined _LIBC]: Likewise.
24050         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
24051         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
24052         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
24053
24054         More changes to assume C89 or better.
24055
24056         * lib/error.c (error_tail): Assume vprintf.
24057
24058         * lib/argmatch.c (getenv): Remove decl.
24059         * lib/progreloc.c (get_full_program_name): Define via prototype.
24060         * lib/setenv.c (clearenv): Likewise.
24061         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
24062         needed.
24063         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
24064         (malloc, memcpy): Remove decls.
24065         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
24066         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
24067         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24068         (memcpy): Remove macro.
24069         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
24070         (__P): Remove.  All uses removed.
24071         (PTR): Remove.  All uses changed to void *.
24072         (CHAR_BIT, NULL): Remove.
24073         (spaces, zeros, memset_space, memset_zero)
24074         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
24075         Remove.
24076         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
24077         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
24078         Define with prototype.
24079         Remove now-unnecessary prototype decl.
24080         (extra_args_spec): Assume ANSI C.  All uses changed.
24081         (extra_args_spec_iso): Remove.
24082         (my_strftime, emacs_strftimeu): Define via prototype.
24083         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
24084         unconditionally.
24085         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
24086         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
24087         (strtoul, strtol): Remove decls.
24088         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
24089         LONG_MAX): Remove.
24090         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24091         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
24092         (LOCALE_PARAM_PROTO): New macro.
24093         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
24094         (INTERNAL (strtol), strtol): Define with a prototype.
24095         (PARAMS): Remove.  All uses removed.
24096         * lib/tempname.c: Include <string.h> unconditionally.
24097         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
24098         * lib/xgethostname.c (main): Define with a prototype.
24099         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
24100         Include <stdlib.h> unconditionally.
24101         (calloc, malloc, realloc, free): Remove decls.
24102         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
24103         Include <stdlib.h> unconditionally.  Sort include file names.
24104         (strtod): Remove.
24105         (xstrtod): Define with a prototype.
24106         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
24107         (strtol, strtoul): Remove decls.
24108
24109 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24110
24111         More patches to assume C89 or better.
24112         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
24113         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
24114         string.h, memchr, STDC_HEADERS.
24115
24116 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24117
24118         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
24119         Include <stdlib.h>, <string.h> unconditionally.
24120         Remove now-unnecessary cast to char *.
24121         * lib/strnlen.c: Include <string.h> unconditionally.
24122         * lib/yesno.c (yesno): Define with a prototype.
24123
24124 2003-09-11  Bruno Haible  <bruno@clisp.org>
24125
24126         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
24127
24128 2003-09-10  Jim Meyering  <jim@meyering.net>
24129
24130         * lib/error.c: Correct indentation of cpp directives.
24131
24132 2003-09-10  Bruno Haible  <bruno@clisp.org>
24133
24134         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
24135         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
24136         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
24137         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
24138         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
24139         <stdlib.h> and <string.h> checks.
24140         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
24141         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
24142
24143 2003-09-10  Bruno Haible  <bruno@clisp.org>
24144
24145         * lib/strcspn.c: Include <string.h> unconditionally.
24146         * lib/strpbrk.c: Include <string.h> unconditionally.
24147         * lib/strstr.c: Include <string.h> unconditionally.
24148         * lib/unicodeio.c: Include <string.h> unconditionally.
24149         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
24150         * lib/unsetenv.c: Likewise.
24151         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
24152         * lib/yesno.c: Include <stdlib.h> unconditionally.
24153         (rpmatch): Add prototype.
24154
24155 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24156
24157         More patches to assume C89 or better.
24158         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
24159         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
24160         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
24161         or for string.h.
24162         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
24163         stdlib.h.
24164         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
24165         C headers.
24166         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
24167         string.h.
24168         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
24169         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
24170         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
24171         or for string.h.
24172         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
24173         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
24174         C headers.
24175         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
24176         memcpy.
24177         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
24178         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
24179         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
24180         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
24181         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
24182         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
24183         string.h, free.
24184         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
24185         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
24186         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
24187         C headers, or for string.h.
24188         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
24189         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
24190         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
24191         headers, memory.h, stdlib.h, string.h, strings.h.
24192         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
24193         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
24194         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
24195         strchr.
24196         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
24197         headers, memory.h, string.h.
24198         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
24199         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
24200         free.
24201         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
24202         headers.
24203         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
24204         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
24205         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
24206         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
24207         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
24208
24209 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24210
24211         More K&R removal.
24212
24213         * lib/acosl.c (main): Use a prototype.
24214         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
24215         tanl.c: Likewise.
24216
24217         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
24218
24219         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
24220         (getopt, etopt_long, getopt_long_only, _getopt_internal)
24221         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
24222         with a prototype.
24223         * lib/getopt.c (const): Remove macro.
24224         Include <string.h> unconditionally.
24225         (my_index): Remove; all uses changed to strchr.
24226         (strlen): Remove decl.
24227         (exchange): Remove forward decl; no longer needed.
24228         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
24229         Define with prototype.
24230         * lib/getopt1.c (const): Remove macro.
24231         (getopt_long, getopt_long_only, main): Define with prototype.
24232
24233         * lib/getugroups.c: Include <string.h> unconditionally.
24234
24235         * lib/getusershell.c: Include <stdlib.h> unconditionally.
24236         (getusershell, setusershell, endusershell, readname, main):
24237         Define with prototypes.
24238
24239         * lib/group-member.c: Include group-member.h first.
24240         Include <stdlib.h> unconditionally.
24241
24242         * lib/hard-locale.c: Include hard-locale.h first.
24243         Include <stdlib.h>, <string.h> unconditionally.
24244
24245         * lib/hash.c (free, malloc): Remove decls.
24246         Include <stdlib.h> unconditionally.
24247
24248         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
24249         (getenv): Do not declare.
24250
24251         * lib/idcache.c: Include <string.h> unconditionally.
24252
24253         * lib/long-options.c: Include long-options.h first, to test interface.
24254         Include <stdlib.h> unconditionally.
24255
24256         * lib/makepath.c: Include makepath.h first, to test interface.
24257         Include <stdlib.h> and <string.h> unconditionally.
24258
24259         * lib/linebuffer.c: Include <stdlib.h>.
24260         (free): Remove decl.
24261
24262         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
24263         stddef.h. rpl_malloc returns void *, not char *.
24264         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
24265         prototype.
24266
24267         * lib/md5.h: Include <limits.h> unconditionally.
24268         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
24269         (__P): Remove; all uses removed.
24270         * lib/md5.c: Include "md5.h" first.
24271         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
24272         md5_buffer, md5_process_bytes, md5_process_block):
24273         Define with prototypes.
24274         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
24275         * lib/sha.c: Include "sha.h" first.
24276         Include <stdlib.h>, <string.h> unconditionally.
24277
24278         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
24279         * lib/memcmp.c (__ptr_t): Likewise.
24280         * lib/memrchr.c (__ptr_t): Likewise.
24281         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
24282         Include <string.h> unconditionally.
24283         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
24284         * lib/memchr.c: Include <stdlib.h> unconditionally.
24285         * lib/memchr.c (LONG_MAX): Remove.
24286         * lib/memrchr.c (LONG_MAX): Likewise.
24287         * lib/memchr.c (__memchr): Define via a prototype.
24288         * lib/memrchr.c (__memrchr): Likewise.
24289         * lib/memcmp.c (__P): Remove, and remove all uses.
24290         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
24291         Remove forward decls; no longer needed.
24292         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
24293         Use types required by C89 in prototype.
24294
24295         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
24296         * lib/savedir.c: Likewise.
24297         * lib/mkdir.c (free): Remove decl.
24298         * lib/rmdir.c (rmdir): Define with a prototype.
24299         * lib/savedir.c: Include savedir.h first, to test interface.
24300
24301         * lib/mktime.c (STDC_HEADERS): Remove.
24302         Include <stdlib.h>, <string.h> unconditionally.
24303
24304         * lib/modechange.c: Include <stdlib.h> unconditionally.
24305         (malloc): Remove decl.
24306
24307         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
24308         (free): Remove decl.
24309
24310         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
24311         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
24312         (This type really should be intptr_t, but that's a C99ism.)
24313         (_obstack_memcpy): Remove: all uses changed to memcpy.
24314         Include <string.h> unconditionally.
24315         (struct obstack): Assume __STDC__ for types of members
24316         chunkfun, freefun, extra_arg.
24317         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
24318         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
24319         obstack_begin, obstack_specify_allocation,
24320         obstack_specify_allocation_with_arg, obstack_chunkfun,
24321         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
24322         Remove unprototyped decls and the macros that use them.
24323         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
24324         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
24325         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
24326         (defined __STDC__ && __STDC__)]:
24327         Remove nonprototyped code.
24328         Include <stdlib.h> unconditionally.
24329         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
24330         _obstack_allocated_p, _obstack_free, obstack_free,
24331         _obstack_memory_used, print_and_abort):
24332         Define using prototypes.
24333         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
24334         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
24335         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
24336         obstack_next_free, obstack_object_size, obstack_room) [0]:
24337         Remove unused, unprototyped code.
24338
24339         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
24340
24341         * lib/physmem.c (physmem_total, physmem_available, main): Define
24342         with prototypes.
24343
24344         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
24345         (main): Define with a prototype.
24346
24347         * lib/posixver.c (getenv): Remove decl.
24348
24349         * lib/putenv.c (malloc): Returns void *, not char *.
24350         Include <string.h> unconditionally.
24351         (strchr, memcpy, NULL): Do not define.
24352
24353         * lib/readtokens.c: Include readtokens.h first, to test interface.
24354         Include <stdlib.h>, <string.h> unconditionally.
24355         (init_tokenbuffer): Define with a prototype.
24356
24357         * lib/regex.c (PARAMS): Remove.  All uses removed.
24358         All uses of _RE_ARGS removed, too.
24359         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
24360         unconditionally.
24361         (bzero): Assume memset exists.
24362         (memcmp, memcpy, NULL): Remove.
24363         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
24364         char, or assignments to local vars of type signed char.
24365         (init_syntax_once, PREFIX(extract_number_and_incr),
24366         PREFIX(print_partial_compiled_pattern),
24367         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
24368         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
24369         PREFIX(regex_grow_registers), PREFIX(regex_compile),
24370         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
24371         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
24372         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
24373         wcs_compile_range, byte_compile_range, truncate_wchar,
24374         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
24375         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
24376         count_mbs_length, wcs_re_match_2_internal,
24377         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
24378         PREFIX(alt_match_null_string_p),
24379         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
24380         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
24381         regfree, PREFIX(extract_number)): Define with prototype.  Remove
24382         now-unnecessary declaration, if any.
24383         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
24384         regcomp, regexec):
24385         Remove now-unnecessary casts among pointer types.
24386         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
24387
24388         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
24389         (free): Remove decl.
24390
24391         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
24392
24393         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
24394         (free): Remove decl.
24395
24396         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
24397         * lib/xgetcwd.c: Likewise.
24398
24399         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
24400         (free): Remove decl.
24401
24402         * lib/strchrnul.c (strchrnul): Define with a prototype.
24403         Fix bug: c_in was not converted to char before searching.
24404
24405         The following changes are not K&R related:
24406
24407         * lib/group-member.h: Include <sys/types.h>, so that this file is
24408         self-contained.
24409         * lib/makepath.h: Likewise.
24410
24411         * lib/getusershell.c (readname, default_index, line_size, readname):
24412         Use size_t, not int, for sizes.
24413         (readname): If the size overflows, report an error instead of
24414         looping forever.
24415
24416 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24417
24418         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
24419         libc.
24420
24421 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24422
24423         * README: New section: portability guidelines.
24424
24425 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24426
24427         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
24428         C89 spec.
24429
24430 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24431
24432         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
24433
24434 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24435
24436         Assume C89 or better; remove K&R cruft.
24437         A few of these changes were first proposed by Derek Robert Price
24438         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
24439
24440         * lib/addext.c: Include <string.h> unconditionally.
24441         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
24442         Don't declare getenv or malloc.
24443
24444         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
24445         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
24446         (NULL): Remove.
24447         (find_stack_direction, alloca): Use prototypes.
24448
24449         * lib/atexit.c (atexit): Define using a prototype.
24450
24451         * lib/basename.c, dirname.c, stripslash.c:
24452         Include <string.h> unconditionally.
24453
24454         * lib/bcopy.c: Include <stddef.h>.
24455         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
24456
24457         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
24458
24459         * lib/error.h (error, error_at_line, error_print_progname)
24460         [! (defined (__STDC__) && __STDC__)]: Remove decls.
24461         * lib/error.c: Include error.h first, to check interface.
24462         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24463         (VA_START): Remove; all uses changeed to va_start.
24464         (exit, strerror): Remove decls.
24465         (error_print_progname): Prototype uncondionally.
24466         Don't include <errno.h>; no longer needed.
24467         (private_strerror): Remove.
24468         (error_tail): Always define.
24469         (error, error_at_line): Assume C89 or better; always use prototypes.
24470         * lib/fatal.c: Include "fatal.h" first, to test interface.
24471         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24472         (VA_START): Remove; all uses changed to va_start.
24473         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
24474         this case.
24475         (exit): Remove decl.
24476         (fatal): Prototype unconditionally.  Assume va_start works.
24477         Abort at end, to pacify gcc.
24478
24479         * lib/euidaccess.c (main): Define with a prototype.
24480
24481         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
24482
24483         * lib/exitfail.c: Include <stdlib.h> unconditionally.
24484
24485         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
24486         prototypes.
24487         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
24488         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
24489         (getenv): Remove decl.
24490         (fnmatch): Define using a prototype.
24491         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
24492         (FCT): Define using a prototype.
24493
24494         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
24495
24496         * lib/gethostname.c: Include <stddef.h>.
24497         (gethostname): Define with prototype.  Length is size_t, not int.
24498
24499 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24500
24501         Assume C89 or better; remove K&R cruft.
24502         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
24503         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
24504         string.h, getenv, malloc.
24505         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
24506         headers.
24507         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
24508         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
24509         do not check for strerror.
24510         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
24511         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
24512         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
24513         do not check for doprnt or vprintf.
24514         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
24515         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
24516
24517 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24518
24519         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
24520         getversion.c should have been removed then, but was accidentally
24521         preserved.
24522
24523         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
24524         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
24525
24526 2003-09-08  Karl Berry  <karl@gnu.org>
24527
24528         * config/config.sub, config.guess, srclistvars.sh: update from savannah
24529                 config, forget about prep.
24530
24531         * config/depcomp, missing: update from automake.
24532
24533 2003-09-07  Paul Eggert  <eggert@twinsun.com>
24534
24535         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
24536         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
24537
24538 2003-09-07  Paul Eggert  <eggert@twinsun.com>
24539
24540         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
24541         copy_tm_result.  Bug reported by Simon Josefsson in
24542         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
24543
24544 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24545
24546         * m4/time_r.m4: New file.
24547         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
24548         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
24549         is. Check for timegm declaration.
24550         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
24551         Do not check for gmtime_r.
24552         Replace mktime if __mktime_internal does not exist and if mktime
24553         hasn't been replaced already.
24554
24555 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24556
24557         * lib/time_r.c, lib/time_r.h: New files.
24558
24559         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
24560         __localtime_r.
24561         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
24562         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
24563
24564         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
24565         __gmtime_r.
24566         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
24567         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
24568         Include <time_r.h>.
24569
24570         * lib/timegm.c: Switch to glibc implementation, with the following
24571         changes:
24572         [defined HAVE_CONFIG_H]: Include <config.h>.
24573         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
24574         (__mktime_internal) [!defined _LIBC]: New decl.
24575         (__gmtime_r) [!defined _LIBC]: New macro and function.
24576         (timegm): Use a prototype, since gnulib assumes C89.
24577         Do not bother declaring tmp to be const, as it's not really usefu.
24578         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
24579         (timegm): Declare only if HAVE_DECL_TIMEGM.
24580
24581 2003-09-06  Paul Eggert  <eggert@twinsun.com>
24582
24583         * MODULES.html.sh (func_all_modules): Add time_r.
24584         * modules/time_r: New file.
24585         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
24586         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
24587
24588 2003-09-03  Paul Eggert  <eggert@twinsun.com>
24589
24590         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
24591         Bug reported by Lute Kamstra in
24592         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
24593
24594         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
24595         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
24596         course with correspondingly smaller numbers for tomorrow and
24597         yesterday.  From Tadayoshi Funaba.  Originally installed into
24598         sh-utils on 1999-08-07, but the patch got lost (I guess during the
24599         coreutils merge?).
24600
24601 2003-08-31  Simon Josefsson  <jas@extundo.com>
24602
24603         * modules/timegm: New file.
24604         * MODULES.html.sh (func_all_modules): Add timegm.
24605
24606 2003-08-31  Simon Josefsson  <jas@extundo.com>
24607
24608         * m4/timegm.m4: New file.
24609
24610 2003-08-31  Simon Josefsson  <jas@extundo.com>
24611
24612         * lib/timegm.h: New file.
24613         * lib/timegm.c: New file.  Based on
24614         wget-1.8.2/src/http.c:mktime_from_utc.
24615
24616 2003-08-31  Karl Berry  <karl@gnu.org>
24617
24618         * lib/argp.h: update from libc.
24619
24620 2003-08-28  Bruno Haible  <bruno@clisp.org>
24621
24622         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
24623         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
24624         followed by '#define fnmatch fnmatch_posix' gives an error.
24625
24626 2003-08-28  Bruno Haible  <bruno@clisp.org>
24627
24628         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
24629         warning on QNX, which defines O_BINARY to 000000.
24630
24631 2003-08-27  Jim Meyering  <jim@meyering.net>
24632
24633         * m4/mkstemp.m4: Require that the system mkstemp be able to create
24634         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
24635         would fail after 32.  Reported by Danny Levinson.  Details here:
24636         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
24637
24638 2003-08-24  Bruno Haible  <bruno@clisp.org>
24639
24640         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
24641         MSVC7 <stdio.h> is included later.
24642
24643 2003-08-22  Simon Josefsson  <jas@extundo.com>
24644
24645         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
24646
24647 2003-08-20  Karl Berry  <karl@gnu.org>
24648
24649         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
24650
24651 2003-08-20  Bruno Haible  <bruno@clisp.org>
24652
24653         * modules/progname: New file.
24654         * MODULES.html.sh (func_all_modules): Add progname.
24655
24656 2003-08-20  Bruno Haible  <bruno@clisp.org>
24657
24658         * lib/progname.h: New file, from GNU gettext.
24659         * lib/progname.c: New file, from GNU gettext.
24660         * lib/progreloc.c: New file, from GNU gettext.
24661
24662 2003-08-19  Jim Meyering  <jim@meyering.net>
24663
24664         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
24665         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
24666
24667 2003-08-19  Bruno Haible  <bruno@clisp.org>
24668
24669         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
24670         more.
24671
24672 2003-08-19  Bruno Haible  <bruno@clisp.org>
24673
24674         * lib/xstrdup.c: Assume <string.h> exists.
24675
24676 2003-08-18  Paul Eggert  <eggert@twinsun.com>
24677
24678         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
24679         in makefile rules.
24680
24681 2003-08-18  Jim Meyering  <jim@meyering.net>
24682
24683         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
24684         * m4/lib-ld.m4: Likewise.
24685
24686 2003-08-18  Jim Meyering  <jim@meyering.net>
24687
24688         * lib/setenv.h: Indent nested cpp directive.
24689         * lib/vasnprintf.c: Remove trailing blanks.
24690
24691 2003-08-17  Simon Josefsson  <jas@extundo.com>
24692
24693         * modules/xstrndup: New file.
24694         * MODULES.html.sh (func_all_modules): Add xstrndup.
24695
24696 2003-08-17  Simon Josefsson  <jas@extundo.com>
24697
24698         * modules/argp: Fix autoconf macro name. Add more dependencies.
24699
24700 2003-08-17  Simon Josefsson  <jas@extundo.com>
24701
24702         * m4/xstrndup.m4: New file.
24703
24704 2003-08-17  Simon Josefsson  <jas@extundo.com>
24705
24706         * m4/argp.m4: New file.
24707
24708 2003-08-17  Simon Josefsson  <jas@extundo.com>
24709             Bruno Haible  <bruno@clisp.org>
24710
24711         * lib/xstrndup.h: New file.
24712         * lib/xstrndup.c: New file.
24713
24714 2003-08-17  Bruno Haible  <bruno@clisp.org>
24715
24716         * modules/strndup (Files, Include): Add lib/strndup.h.
24717
24718 2003-08-17  Bruno Haible  <bruno@clisp.org>
24719
24720         * modules/euidaccess (Files): Add lib/euidaccess.h.
24721
24722 2003-08-17  Bruno Haible  <bruno@clisp.org>
24723
24724         * lib/strndup.h: New file.
24725
24726 2003-08-17  Bruno Haible  <bruno@clisp.org>
24727
24728         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
24729         like AC_GNU_SOURCE.
24730         * modules/extensions (configure.ac): Comment out the invocation of
24731         gl_USE_SYSTEM_EXTENSIONS.
24732
24733 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24734
24735         Merges from coreutils, etc.
24736         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
24737         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
24738         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
24739         fixing a typo.
24740         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
24741         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
24742
24743 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24744
24745         Document merge from coreutils.
24746         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
24747         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
24748         * modules/utime: Add m4/utimes-null.m4.
24749
24750 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24751
24752         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
24753         space, undoing this 2003-08-12 change:
24754         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
24755
24756 2003-08-16  Paul Eggert  <eggert@twinsun.com>
24757
24758         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
24759         strtoul.c from libc, undoing this 2003-08-12 change:
24760         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
24761
24762 2003-08-16  Jim Meyering  <jim@meyering.net>
24763
24764         Merges from coreutils.
24765         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
24766         prefix.  Adjust cache variables similarly.  Create 500 rather than
24767         just 300 files, to exercise bug on Darwin6.5, too.
24768         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
24769         $missing_dir.
24770         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
24771         AM_SYS_POSIX_TERMIOS.
24772         Reported by mkc@mathdogs.com.
24773         Also change use of $am_cv_sys_posix_termios
24774         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
24775         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
24776         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
24777         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
24778         in /proc/mounts until it finds one with matching device number.  This
24779         is unnecessary when the FILE argument *is* a mount point.  No stat call
24780         is necessary in that case.  So, disable the statvfs-testing code on
24781         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
24782         as RedHat bug# 84846.
24783         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
24784         to 1MB, so as not to render systems with no stack size limit (e.g.,
24785         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
24786         Include <unistd.h>.  On some systems,
24787         it is required for the definition of _SC_PAGESIZE.
24788
24789 2003-08-16  Jim Meyering  <jim@meyering.net>
24790
24791         Merge from coreutils.
24792         * lib/xstrtoimax.c: #else #if -> #elif.
24793         * lib/xstrtoumax.c: Likewise.
24794
24795 2003-08-16  Jim Meyering  <jim@meyering.net>
24796
24797         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
24798         * m4/utimes.m4: Removed.
24799         * m4/utimes-null.m4: Renamed from utimes.m4.
24800
24801         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
24802         to 1MB, so as not to render systems with no stack size limit (e.g.,
24803         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
24804         Include <unistd.h>.  On some systems,
24805         it is required for the definition of _SC_PAGESIZE.
24806
24807 2003-08-16  Jim Meyering  <jim@meyering.net>
24808         and Paul Eggert  <eggert@cs.ucla.edu>
24809
24810         Merges from coreutils, etc.
24811
24812         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
24813         using the latest version from cvs.  This avoids problems with #line
24814         directives using a vendor (Sun) compiler.
24815         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
24816         Don't set GETGROUPS_LIB here; now it's
24817         done via getgroups.m4's wrapper function.
24818         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
24819         rather than just in sh-util/configure.in, so that the
24820         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
24821         same.
24822         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
24823         AC_FUNC_GETLOADAVG where to find getloadavg.c.
24824         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
24825         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
24826         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
24827         Remove code that is now done by the newly-required macros.
24828         Append $(EXEEXT) to DF_PROG.
24829         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
24830         Do not invoke or require the following here,
24831         since prereq.m4 or some gnulib .m4 now does this for us:
24832         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
24833         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
24834         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
24835         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
24836         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
24837         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
24838         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
24839         AC_FUNC_OBSTACK.
24840         Do not replace the following functions, as this is now the job
24841         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
24842         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
24843         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
24844         atexit getpass, strdup, getpagesize.
24845         Replace 'raise'.
24846         Do not check for the following functions, as this is now the job
24847         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
24848         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
24849         setregid.
24850         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
24851         Check for sys/sysctl.h.
24852         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
24853         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
24854         of checking for ssize_t ourselves.
24855
24856         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
24857         Require every macro that gnulib/modules/* suggests for us.
24858         (jm_PREREQ_ADDEXT): New macro.
24859         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
24860         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
24861
24862         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
24863         (gl_PHYSMEM): Use it.
24864         Also check for `table' function.
24865         Check for new headers and functions.
24866         Add check for sys/sysmp.h.
24867         With suggestions from Kaveh Ghazi.
24868         Ignore headers that are present but cannot be compiled.  This
24869         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
24870         C 5.4.
24871
24872 2003-08-15  Paul Eggert  <eggert@twinsun.com>
24873
24874         Document merge from coreutils.
24875         * modules/userspec: Depend on posixver.
24876         * modules/strftime: Depend on tzset.
24877
24878 2003-08-15  Paul Eggert  <eggert@twinsun.com>
24879
24880         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
24881         rather than tab, after '#' in shell-script copyright notices.
24882         Suggested by Bruno Haible.
24883
24884 2003-08-15  Paul Eggert  <eggert@twinsun.com>
24885
24886         * config/srclist-update: Use three spaces, rather than tab, after '#'
24887         in shell-script copyright notices.  Suggested by Bruno Haible.
24888         Remove unnecessary parenthesization in regular expression.
24889
24890 2003-08-15  Jim Meyering  <jim@meyering.net>
24891
24892         Merge from coreutils.
24893         * lib/xgethostname.c: Include <stdlib.h>.
24894         (xghostname): Don't exit for anything other than memory-related
24895         failure; just return NULL.
24896         * lib/userspec.c: Include "posixver.h".
24897         (parse_user_spec): Accept `.' as a separator only
24898         in pre-POSIX-200112 mode.
24899         * lib/strtoimax.c: Use #elif rather than #else #if.
24900         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
24901         Remove function, now that we can rely on a working tzset function.
24902         [!_LIBC]: Ensure that the required autoconf test has been run.
24903         [!defined _NL_CURRENT && HAVE_STRFTIME]:
24904         Use underlying_strftime for %r.
24905         * lib/sha.c: Merge in some clean-up and optimization changes from
24906         glibc.
24907         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
24908         Ensure that it is a multiple of 64.
24909         Rearrange loop exit tests so as to avoid performing an
24910         additional fread after encountering an error or EOF.
24911         * lib/realloc.c: Update copyright date.
24912
24913 2003-08-15  Jim Meyering  <jim@meyering.net>
24914         and Paul Eggert  <eggert@twinsun.com>
24915
24916         Merge from coreutils.
24917         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
24918         member but strut utmpx does not.  Needed for AIX 4.3.3.
24919         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
24920
24921 2003-08-15  Jim Meyering  <jim@meyering.net>
24922         and Paul Eggert  <eggert@cs.ucla.edu>
24923
24924         Merges from coreutils, etc.
24925         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
24926         Require gl_FUNC_TZSET_CLOBBER.
24927         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
24928         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
24929         members.
24930
24931 2003-08-14  Paul Eggert  <eggert@twinsun.com>
24932
24933         Help the merge from coreutils.
24934         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
24935         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
24936         * m4/tzset.m4: Use it too.
24937
24938 2003-08-14  Paul Eggert  <eggert@twinsun.com>
24939
24940         * modules/tzset: New file.
24941
24942 2003-08-14  Jim Meyering  <jim@meyering.net>
24943
24944         Merges from coreutils.
24945         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
24946         variable names, rather than @FNMATCH_H@.
24947         * modules/alloca: Likewise for $(ALLOCA_H).
24948
24949         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
24950         the three copies of the literal target, `fnmatch.h'.
24951         * modules/alloca (alloca.h): Likewise.
24952
24953 2003-08-14  Jim Meyering  <jim@meyering.net>
24954
24955         Merge from coreutils.
24956         * m4/tzset.m4: New file.
24957         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
24958         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
24959         otherwise, AIX 5.1 systems would end up using the latter.
24960         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
24961         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
24962         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
24963         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
24964
24965 2003-08-14  Jim Meyering  <jim@meyering.net>
24966
24967         Merge from coreutils.
24968         * lib/obstack.h: Whitespace changes.
24969         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
24970         and xcalloc return values.
24971         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
24972         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
24973         hang on OSF/1 5.1 for DIR on both local and remote file systems.
24974         Reported by (and fix confirmed by) Nelson H. F. Beebe.
24975         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
24976         error from mntctl.
24977         Use mntctl's return value to drive the entry-processing loop, since
24978         we can't rely on the value of the vmt_length member in the last
24979         entry.  On some systems doing so could result in exhausting
24980         virtual memory.  Based in part on a patch from Mike Jetzer.
24981
24982 2003-08-14  Jim Meyering  <jim@meyering.net>
24983         and Paul Eggert  <eggert@twinsun.com>
24984
24985         Merges from coreutils, plus other fixes.
24986         * lib/physmem.c: Merge in portability changes from gcc/libiberty
24987         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
24988         for credits and details.  Thanks to Kaveh Ghazi for helping
24989         to keep these files in sync.
24990         (ARRAY_SIZE): Define it.
24991         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
24992         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
24993         (memcasecmp): Don't assume size_t fits in unsigned int.
24994         Remove casts and duplicate code.
24995         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
24996         (memcpy): Remove definition.
24997         Merge in some clean-up and optimization changes from glibc.
24998         [BLOCKSIZE]: Move definition to top of file.
24999         Ensure that it is a multiple of 64.
25000         Rearrange loop exit tests so as to avoid performing an
25001         additional fread after encountering an error or EOF.
25002         * lib/md5.h (md5_uintptr): Define.
25003         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
25004         return to the initial working directory.  Preserve errno
25005         for caller.
25006         * lib/idcache.c: Include "xalloc.h".
25007         (xmalloc, xrealloc): Remove decls.
25008         (getuser): Remove casts no longer required in C89.
25009         * lib/human.c: Include stdio.h, for sprintf.
25010         * lib/group-member.c: Include "xalloc.h".
25011         (xmalloc, xrealloc): Remove decls.
25012         (get_group_info): Remove casts no longer required in C89.
25013         * lib/getusershell.c (readname): Remove casts no longer required in
25014         C89.
25015         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
25016         * lib/getline.c: Whitespace fix, from coreutils.
25017
25018 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25019
25020         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
25021         Check for isascii.
25022
25023         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25024         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25025         Undo previous (whitespace-only) change.
25026
25027 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25028
25029         * lib/exclude.c: Include <ctype.h>
25030         (IN_CTYPE_DOMAIN): New macro.
25031         (is_space): New fn.
25032         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
25033         and empty lines.
25034
25035         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25036         Undo previous (whitespace-only) change.
25037
25038 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25039
25040         * config/srclist-update: Change update back to the old behavior,
25041         leaving whitespace alone.  Use one 'sed' command rather than a
25042         pipeline.
25043         (fixlicense): Now a variable, not a function.
25044         (remove_trailing_blanks): Remove.
25045         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
25046         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25047         Undo previous (whitespace-only) change.
25048
25049 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25050
25051         Merge from coreutils.
25052         * modules/euidaccess: Add lib_SOURCES, include for new
25053         file euidaccess.h
25054
25055 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25056
25057         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25058         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25059         Normalize leading white space and remove trailing white space.
25060
25061         Merge from coreutils
25062         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
25063
25064         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
25065         0.12.1.  These files are now being upgraded automatically by
25066         ../config/srclist-update.
25067
25068 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25069
25070         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25071         Normalize leading white space and remove trailing white space.
25072         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
25073         notice, as per ../config/srclist-update.
25074
25075         Merge from coreutils.
25076         * lib/euidaccess.h: New file.
25077         * lib/euidaccess.c: Include it.
25078         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
25079         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
25080         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
25081
25082 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25083
25084         * config/srclist-update: Add copyright notice.
25085         (remove_id_lines, remove_trailing_blanks): New constants.
25086         (fixfile): Use them to normalize spacing a bit in copied files.
25087         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25088         Normalize leading white space and remove trailing white space.
25089
25090         * config/texinfo.tex: Sync with texinfo.
25091
25092         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
25093         strtoul.c from libc, to merge coreutils whitespace changes.
25094
25095         * config/srclist.txt: Get the following m4 files from gettext:
25096         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
25097         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
25098         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
25099         wint_t.m4.
25100
25101 2003-08-12  Karl Berry  <karl@gnu.org>
25102
25103         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
25104         been made.
25105
25106 2003-08-11  Paul Eggert  <eggert@twinsun.com>
25107
25108         * modules/gnu-source, m4/gnu-source.m4:
25109         Remove; we're assuming Autoconf 2.54 or later now.
25110         Suggested by Bruno Haible.
25111         * MODULES.html.sh (func_all_modules): Remove gnu-source.
25112
25113 2003-08-11  Bruno Haible  <bruno@clisp.org>
25114
25115         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
25116
25117 2003-08-11  Bruno Haible  <bruno@clisp.org>
25118
25119         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
25120         (vasnprintf): Use it instead of wcslen.
25121
25122 2003-08-11  Bruno Haible  <bruno@clisp.org>
25123
25124         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
25125         value to ensure that _Bool promotes to int. Use #define for _Bool when
25126         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
25127
25128 2003-08-10  Karl Berry  <karl@gnu.org>
25129
25130         * lib/regex.h: update from libc (whitespace fix).
25131
25132 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25133
25134         Merge some files from coreutils.  These changes were
25135         originally made by Jim Meyering.
25136         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
25137         many older Unixes require this.
25138         * lib/alloca.c (alloca): Remove cast to argument of free;
25139         no longer needed in C89.
25140         * lib/alloca_.h, regex.h: Fix white space to match
25141         what GNU indent does.
25142
25143 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25144
25145         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
25146         apparently Emacs's Unicode mode got confused before my 2003-08-05
25147         checkin.
25148
25149 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25150
25151         * m4/extensions.m4: New file.
25152         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
25153         Require gl_USE_SYSTEM_EXTENSIONS.
25154         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
25155         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
25156
25157 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25158
25159         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
25160         * modules/extensions, modules/gnu-source: New files.
25161         * modules/timespec, modules/unlocked-io: Depend on extensions.
25162
25163 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25164
25165         * modules/restrict: New file.
25166         * MODULES.html.sh (func_all_modules): Add restrict.
25167         * modules/regex: Depend on restrict.
25168
25169 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25170
25171         * m4/restrict.m4: New file.
25172         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
25173
25174 2003-08-07  Bruno Haible  <bruno@clisp.org>
25175
25176         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
25177         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
25178
25179 2003-08-07  Bruno Haible  <bruno@clisp.org>
25180
25181         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
25182         makes the module 'getndelim2' compatible with the module 'getline'.
25183
25184 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25185
25186         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
25187         byte with "\201" to avoid glitches when editing that source file
25188         with multi-gnome-terminal.
25189
25190 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25191
25192         * lib/bumpalloc.h: Remove.
25193
25194 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25195
25196         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
25197         * modules/bumpalloc: Remove.
25198
25199 2003-08-04  Paul Eggert  <eggert@twinsun.com>
25200
25201         * lib/getloadavg.c: Change copyright notice and spacing to conform to
25202         GNU coding style.
25203
25204         Merge from coreutils.
25205         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
25206         1. From glibc.
25207         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
25208         from Karl Berry, implemented by Jim Meyering.
25209         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
25210         from Dmitry V. Levin.
25211         Remove anachronistic cast of xrealloc.
25212         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
25213         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
25214         type. Otherwise, it wouldn't compile with at least /bin/cc on
25215         ymp-cray-unicos9.0.2.X.
25216         Combine two mostly-identical uses of alloca into one.
25217         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
25218
25219 2003-08-04  Dave Love  <d.love@dl.ac.uk>
25220
25221         [From Emacs.]
25222
25223         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
25224         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
25225         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
25226         obsolete NLIST_NAME_UNION.
25227         [__GNU__]: Undef BSD and FSCALE.
25228         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
25229
25230 2003-08-03  Paul Eggert  <eggert@twinsun.com>
25231
25232         * lib/stdbool_.h (_Bool): Make it signed char, instead of
25233         an enum type, so that it's guaranteed to promote to int.  See:
25234         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
25235
25236 2003-08-03  Karl Berry  <karl@gnu.org>
25237
25238         * config/depcomp: update from automake.
25239
25240 2003-07-31  Paul Eggert  <eggert@twinsun.com>
25241
25242         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
25243         (strerror): Don't assume that a printable int fits in 14 bytes.
25244
25245 2003-07-31  Bruno Haible  <bruno@clisp.org>
25246
25247         * modules/getpass-gnu: New file.
25248         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
25249
25250 2003-07-31  Bruno Haible  <bruno@clisp.org>
25251
25252         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
25253
25254 2003-07-24  Karl Berry  <karl@gnu.org>
25255
25256         * config/missing: update from automake.
25257
25258 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
25259             Bruno Haible  <bruno@clisp.org>
25260
25261         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
25262         * lib/getline.c (getline, getdelim): Likewise.
25263         Remove _GNU_SOURCE define; now it's defined in config.h through
25264         m4/getline.m4.
25265
25266 2003-07-23  Karl Berry  <karl@gnu.org>
25267
25268         * config/config.sub: update from prep.
25269
25270 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25271
25272         * modules/xalloc (Depends-on): Add exitfail.
25273         * modules/xmemcoll: Likewise.
25274
25275 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25276
25277         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
25278         over-parenthesization in macros.
25279
25280         Sync with coreutils.
25281
25282         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
25283         required by C99.
25284
25285         Use `exit_failure' for xalloc and xmemcoll instead of their own
25286         private exit-failure variables.
25287         * lib/xalloc.h (xalloc_exit_failure): Remove.
25288         * lib/xmalloc.c: Likewise.  Include exitfail.h.
25289         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
25290         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
25291         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
25292         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
25293
25294 2003-07-20  Jim Meyering  <jim@meyering.net>
25295
25296         * modules/closeout (Depends-on): Add exitfail.
25297         Suggestion from Bruno Haible.
25298
25299 2003-07-19  Karl Berry  <karl@gnu.org>
25300
25301         * config/config.sub: update from prep.
25302
25303 2003-07-18  Paul Eggert  <eggert@twinsun.com>
25304
25305         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
25306         Remove.
25307         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
25308         to test that it can stand by itself.  Include "exitfail.h".
25309         Clients should set exit_failure instead.
25310         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
25311
25312 2003-07-18  Bruno Haible  <bruno@clisp.org>
25313
25314         * modules/getndelim2: New file.
25315         * modules/getline: Share files with module getndelim2.
25316         * modules/getnline: Depend on getndelim2 instead of sharing files with
25317         it. Add getnline.c to lib_SOURCES.
25318         * MODULES.html.sh (func_all_modules): Add getndelim2.
25319
25320 2003-07-18  Bruno Haible  <bruno@clisp.org>
25321
25322         * m4/getndelim2.m4: New file.
25323         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
25324         invoke gl_PREREQ_GETNDELIM2.
25325         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
25326         gl_PREREQ_GETNDELIM2.
25327         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
25328         gl_GETNDELIM2.
25329
25330 2003-07-18  Bruno Haible  <bruno@clisp.org>
25331
25332         * lib/getndelim2.h: New file.
25333         * lib/getndelim2.c: Make into a module of its own. Include config.h,
25334         getndelim2.h.
25335         (getndelim2): Make non-static. Change return type to ssize_t.
25336         * lib/getline.h: Change argument names.
25337         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
25338         * lib/getnline.c: Include getndelim2.h.
25339
25340 2003-07-18  Andreas Schwab  <schwab@suse.de>
25341
25342         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
25343
25344 2003-07-17  Karl Berry  <karl@gnu.org>
25345
25346         * config/config.sub: update from prep.
25347
25348 2003-07-17  Bruno Haible  <bruno@clisp.org>
25349
25350         * modules/getnline: New file.
25351         * modules/getline: Add lib/getndelim2.c to source file list.
25352         * MODULES.html.sh (func_all_modules): Add getnline.
25353
25354 2003-07-17  Bruno Haible  <bruno@clisp.org>
25355
25356         * m4/getnline.m4: New file.
25357
25358 2003-07-17  Bruno Haible  <bruno@clisp.org>
25359
25360         * m4/Makefile.am.in: Remove file.
25361         * m4/Makefile.am: Remove file.
25362         * m4/Makefile.in: Remove file.
25363
25364 2003-07-17  Bruno Haible  <bruno@clisp.org>
25365
25366         * lib/getnline.h: New file.
25367         * lib/getnline.c: New file.
25368         * lib/getndelim2.c: New file, extracted from getline.c.
25369         (getndelim2): Renamed from getdelim2, with added nmax argument.
25370         * lib/getline.c: Include getndelim2.c.
25371         (getdelim2): Moved out to getndelim2.c.
25372         (getline, getdelim): Update.
25373
25374 2003-07-17  Bruno Haible  <bruno@clisp.org>
25375
25376         * lib/Makefile.am: Remove file.
25377         * lib/Makefile.in: Remove file.
25378
25379 2003-07-17  Bruno Haible  <bruno@clisp.org>
25380
25381         * configure.in: Remove file.
25382         * Makefile.in: Remove file.
25383
25384 2003-07-17  Bruno Haible  <bruno@clisp.org>
25385
25386         * MODULES.html.sh: Put the </BODY> right before </HTML>.
25387
25388 2003-07-16  Karl Berry  <karl@gnu.org>
25389
25390         * config/srclist-update: was running fixlicense twice, which caused
25391                 texinfo.tex to be nullified for some reason.  Simplify,
25392                 $gplsrc is no longer needed as far as I can see?
25393
25394 2003-07-16  Jim Meyering  <jim@meyering.net>
25395
25396         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
25397
25398 2003-07-15  Paul Eggert  <eggert@twinsun.com>
25399
25400         * config/srclist.txt: Get the following files from gettext-runtime/intl
25401         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
25402         ref-del.sin.  From Bruno Haible.
25403         * config/srclist-update (fixfile): Change grep pattern again, since the
25404         previous fix didn't work (there was another trailing $).  Use
25405         '[$]' to escape the $s.
25406
25407 2003-07-15  Karl Berry  <karl@gnu.org>
25408
25409         * lib/vasnprintf.c: update from gettext.
25410
25411 2003-07-15  Karl Berry  <karl@gnu.org>
25412
25413         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
25414         gets expanded when surrounded by '$'.
25415
25416 2003-07-15  Jim Meyering  <jim@meyering.net>
25417
25418         * modules/save-cwd: Don't depend on error.  From Derek Price.
25419
25420 2003-07-15  Jim Meyering  <jim@meyering.net>
25421
25422         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
25423
25424 2003-07-14  Simon Josefsson  <jas@extundo.com>
25425
25426         * modules/mempcpy: New file.
25427         * MODULES.html.sh (func_all_modules): Add mempcpy.
25428
25429 2003-07-14  Simon Josefsson  <jas@extundo.com>
25430
25431         * m4/mempcpy.m4: New file.
25432
25433 2003-07-14  Simon Josefsson  <jas@extundo.com>
25434
25435         * lib/mempcpy.h: New file.
25436         * lib/mempcpy.c: New file.
25437
25438 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25439
25440         * modules/getdate, modules/posixtm: Depend on mktime.
25441
25442 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25443
25444         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
25445         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
25446         unicodeio.c, unicodeio.h, unlocked-io.h:
25447         Switch from LGPL to GPL.
25448
25449 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25450
25451         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
25452         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
25453         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
25454         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
25455         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
25456         updated automatically by ../config/srclist-update.  This changes
25457         their license from LPGL to GPL.
25458
25459 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25460
25461         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
25462         assumed to refer to the root of the most recent stable gettext version.
25463         * config/srclistvars.sh: Add defaults for eggert.
25464         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
25465         Match "This program" as well as "The program".  This is needed
25466         for gettext.
25467
25468 2003-07-14  Jim Meyering  <jim@meyering.net>
25469
25470         Don't emit diagnostics.  Let callers do that.
25471         * lib/save-cwd.c: Don't include "error.h".
25472         (save_cwd): Don't call error.  Ensure that errno is valid
25473         when returning nonzero.
25474
25475         * lib/save-cwd.h (restore_cwd): Update prototype.
25476         * lib/save-cwd.c (restore_cwd): Remove two parameters.
25477         Simplify.  Don't call error upon failure.  Let callers do that.
25478         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
25479         when auditing is enabled.  But don't bother updating the #if.
25480
25481 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
25482
25483         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
25484         it breaks C++ compilation.
25485         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
25486
25487 2003-07-10  Simon Josefsson  <jas@extundo.com>
25488
25489         * modules/strchrnul (Makefile.am): Add strchrnul.h.
25490
25491 2003-07-10  Jim Meyering  <jim@meyering.net>
25492
25493         * m4/clock_time.m4: Remove trailing blank.
25494         * m4/intmax_t.m4: Likewise.
25495
25496 2003-07-10  Jim Meyering  <jim@meyering.net>
25497
25498         * lib/vasnprintf.c: Remove trailing blanks.
25499         Make cpp indentation consistent.
25500
25501 2003-07-09  Paul Eggert  <eggert@twinsun.com>
25502
25503         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
25504         posixver.c, strftime.c, strnlen.c, strverscmp.c:
25505         Switch from LGPL to GPL.
25506
25507 2003-07-09  Paul Eggert  <eggert@twinsun.com>
25508
25509         * config/srclist.txt: Sort sublists.  Add
25510         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
25511         that differ from gnulib for one reason or another; we'd like this list
25512         to be smaller but for now let's document what we have.
25513
25514 2003-07-08  Paul Eggert  <eggert@twinsun.com>
25515
25516         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
25517         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
25518         and sweeter "eval x=$x".
25519         * config/srclist.txt: Get lib/argp* from glibc.
25520
25521 2003-07-07  Paul Eggert  <eggert@twinsun.com>
25522
25523         * lib/mktime.c: Fix some boundary cases and remove need for floating
25524         point.
25525
25526         Issue a compile-time diagnostic if time_t is floating point, or if
25527         two's complement arithmetic is not in effect, or if arithmetic
25528         right shift does not propagate the sign.  These assumptions were
25529         all in the original code but they weren't checked.
25530
25531         (TIME_T_MIDPOINT, verify): New macros.
25532         (__isleap): Remove; it has integer overflow problems.
25533         (leapyear): New function, without those problems.
25534         (ydhms_tm_diff): Remove; splitting into two parts.
25535         (ydhms_diff): New function, containing the arithmetic part of
25536         the old ydhms_tm_diff function.  Issue a compile-time
25537         diagnostic if we are not using C99 integer division.
25538         Avoid casts when possible.
25539         (guess_time_tm): New function, containing the checking part of
25540         the old ydhms_tm_diff function.  Return the new value, rather than
25541         the difference between it and the old.  Accept a new argument T
25542         so that *T specifies the old value.  Check for overflow in the result.
25543
25544         (__mktime_internal): Use a time_t offset, not a long int offset.
25545         This undoes the 2003-06-04 change, which is no longer needed now
25546         that we have better overflow checking.
25547         (localtime_offset): Likewise.
25548
25549         (__mktime_internal): Avoid harmful overflow on hosts where time_t
25550         and long are 64-bit but int is only 32-bit.
25551         (ydhms_diff): Use long int to store year1 and yday1.
25552         Issue a compile-time diagnostic if long int is not wide enough.
25553
25554         (__mktime_internal): Use long int to store adjusted year and yday.
25555         Use plain C rather than preprocessor commands, if that doesn't
25556         affect efficiency.
25557         Check for overflow (and try to repair) after each probe
25558         rather than checking only at the very end.  This avoids some bugs
25559         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
25560         does not equal GMT offset at maximum time).
25561         Use integer to check for overflow rather than floating point; this
25562         is more portable to non-IEEE hosts, and is a tad faster.
25563         When we detect that we are oscillating between two values,
25564         don't check whether tm_isdst has the requested value, since
25565         we already know the answer.  When tm_isdst has the wrong value,
25566         use a different heuristic to find the right one, based on the
25567         extreme values actually observed in practice in tz2003a,
25568         rather than the (overly optimistic) "previous 3 calendar quarters".
25569
25570         (not_equal_tm, print_tm, check_result): Use "const T" rather than
25571         "T const" to accommodate glibc style.
25572         (check_result): Use less-confusing report format.  "long" -> "long int.
25573         (main): Likewise.
25574         Don't loop if the iteration overflows time_t.
25575         Allow a negative step in the iteration.
25576
25577 2003-07-06  Karl Berry  <karl@gnu.org>
25578
25579         * config/depcomp: update from automake.
25580         * config/config.sub: update from prep.
25581
25582 2003-07-03  Karl Berry  <karl@gnu.org>
25583
25584         * config/config.guess: update from prep.
25585
25586 2003-07-01  Paul Eggert  <eggert@twinsun.com>
25587
25588         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
25589         xreadlink.c now includes it unconditionally.
25590
25591 2003-07-01  Paul Eggert  <eggert@twinsun.com>
25592
25593         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
25594         having it depend on HAVE_SYS_TYPES_H.
25595
25596 2003-07-01  Bruno Haible  <bruno@clisp.org>
25597
25598         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
25599         <sys/types.h> should be sufficient.
25600         Reported by Paul Eggert.
25601
25602 2003-06-26  Karl Berry  <karl@gnu.org>
25603
25604         * config/depcomp: update from automake.
25605
25606 2003-06-26  Bruno Haible  <bruno@clisp.org>
25607
25608         * modules/human: Depend on module stdbool.
25609
25610 2003-06-25  Bruno Haible  <bruno@clisp.org>
25611
25612         * modules/readlink: New file.
25613         * modules/xreadlink: Depend on it.
25614         * MODULES.html.sh (func_all_modules): Add readlink.
25615
25616 2003-06-25  Bruno Haible  <bruno@clisp.org>
25617
25618         * m4/readlink.m4: New file.
25619
25620 2003-06-25  Bruno Haible  <bruno@clisp.org>
25621
25622         * lib/readlink.c: New file.
25623
25624 2003-06-22  Karl Berry  <karl@gnu.org>
25625
25626         * config/srclist.txt: update mkinstalldirs from automake.
25627         * config/mkinstalldirs: update.
25628
25629 2003-06-22  Bruno Haible  <bruno@clisp.org>
25630
25631         Portability to mingw32.
25632         * m4/ssize_t.m4: New file, from GNU gettext.
25633         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
25634         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
25635
25636 2003-06-22  Bruno Haible  <bruno@clisp.org>
25637
25638         * modules/safe-read: Add m4/ssize_t.m4.
25639         * modules/xreadlink: Add m4/ssize_t.m4.
25640
25641 2003-06-20  Bruno Haible  <bruno@clisp.org>
25642
25643         Assume C89, so PARAMS isn't needed.
25644         * lib/unicodeio.h (PARAMS): Remove.
25645         * lib/unicodeio.c: Don't use PARAMS.
25646
25647 2003-06-18  Karl Berry  <karl@gnu.org>
25648
25649         * config/config.{guess,sub}: update from prep.
25650
25651 2003-06-18  Jim Meyering  <jim@meyering.net>
25652
25653         Merge changes from coreutils.
25654         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
25655         Remove explicit declarations of xmalloc and realloc.
25656         Include xalloc.h.
25657         (read_utmp): Remove anachronistic cast of xmalloc.
25658
25659 2003-06-17  Paul Eggert  <eggert@twinsun.com>
25660
25661         Assume C89, so PARAMS isn't needed.
25662         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
25663         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
25664         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
25665         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
25666         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
25667         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
25668         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
25669         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
25670         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
25671         lib/xstrtod.h, lib/xstrtol.h: Likewise.
25672         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
25673         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
25674         no longer needed. Anyway, config.h should always be included before any
25675         other file.
25676
25677 2003-06-11  Simon Josefsson  <jas@extundo.com>
25678
25679         * modules/sysexits: New file.
25680         * MODULES.html.sh (func_all_modules): Add sysexits.
25681
25682 2003-06-11  Simon Josefsson  <jas@extundo.com>
25683
25684         * lib/sysexit_.h: New file.
25685
25686 2003-06-11  Derek Price  <derek@ximbiot.com>
25687
25688         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
25689         necessary.
25690
25691 2003-06-11  Bruno Haible  <bruno@clisp.org>
25692
25693         * m4/sysexits.m4: New file.
25694
25695 2003-06-10  Simon Josefsson  <jas@extundo.com>
25696
25697         * lib/argp.h: New file, from glibc.
25698         * lib/argp-ba.c: New file, from glibc.
25699         * lib/argp-eexst.c: New file, from glibc.
25700         * lib/argp-fmtstream.c: New file, from glibc.
25701         * lib/argp-fmtstream.h: New file, from glibc.
25702         * lib/argp-fs-xinl.c: New file, from glibc.
25703         * lib/argp-help.c: New file, from glibc.
25704         * lib/argp-namefrob.h: New file, from glibc.
25705         * lib/argp-parse.c: New file, from glibc.
25706         * lib/argp-pv.c: New file, from glibc.
25707         * lib/argp-pvh.c: New file, from glibc.
25708         * lib/argp-xinl.c: New file, from glibc.
25709
25710 2003-06-10  Simon Josefsson  <jas@extundo.com>
25711
25712         * modules/strchrnul: New file.
25713
25714 2003-06-10  Simon Josefsson  <jas@extundo.com>
25715
25716         * modules/argp: New file.
25717
25718 2003-06-10  Simon Josefsson  <jas@extundo.com>
25719
25720         * m4/strchrnul.m4: New file.
25721
25722 2003-06-10  Simon Josefsson  <jas@extundo.com>
25723
25724         * lib/strchrnul.h: New file.
25725         * lib/strchrnul.c: New file.
25726
25727 2003-06-10  Bruno Haible  <bruno@clisp.org>
25728
25729         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
25730
25731 2003-06-07  Karl Berry  <karl@gnu.org>
25732
25733         * config/config.{guess,sub}: update from prep.
25734
25735 2003-06-07  Jim Meyering  <jim@meyering.net>
25736
25737         * modules/strtod: Use $(...) notation, not @...@ for
25738         AC_REPLACE'd variables.
25739         * modules/localcharset: Likewise.
25740
25741 2003-06-07  Jim Meyering  <jim@meyering.net>
25742
25743         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
25744         in place of my name in the copyright comment.
25745         Remove definition and uses of __P.
25746
25747         From coreutils.
25748         * lib/stat.c: Don't declare xmalloc explicitly.
25749         Instead, include "xalloc.h".
25750         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
25751         xrealloc, and xcalloc return values.
25752         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
25753         Improve comment.
25754         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
25755
25756 2003-06-07  Bruno Haible  <bruno@clisp.org>
25757
25758         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
25759         avoid AC_CONFIG_LINKS.
25760         * modules/fnmatch (Makefile.am): Use explicit creation rule for
25761         fnmatch.h, to avoid AC_CONFIG_LINKS.
25762         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
25763
25764 2003-06-07  Bruno Haible  <bruno@clisp.org>
25765
25766         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
25767         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
25768         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
25769         directory.
25770         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
25771         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
25772         directory.
25773
25774 2003-06-06  Jim Meyering  <jim@meyering.net>
25775
25776         Merge from coreutils.
25777         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
25778         Consolidate declarations and initializations of *_base* locals.
25779
25780         Merge from coreutils.
25781         This avoids a core dump on systems without GNU putenv,
25782         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
25783         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
25784         (unsetenv): New static function, from GNU libc.
25785         (rpl_putenv): Use it.
25786
25787         * lib/modechange.c: Remove trailing blanks.
25788
25789         Merge from coreutils.
25790         * lib/fsusage.c: Remove declaration of statfs.
25791         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
25792
25793         * lib/posixtm.c: Include <stdbool.h> unconditionally.
25794
25795 2003-06-06  Jim Meyering  <jim@meyering.net>
25796
25797         * lib/stdbool_.h: Renamed from stdbool.h.in.
25798
25799 2003-06-06  Jim Meyering  <jim@meyering.net>
25800             Bruno Haible  <bruno@clisp.org>
25801
25802         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
25803         Adjust Makefile.am snippet not to redirect directly to target.
25804         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
25805
25806 2003-06-05  Paul Eggert  <eggert@twinsun.com>
25807
25808         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
25809         mismatch, look in future quarters as well as past.  This fixes a
25810         bug when processing fall-backwards gaps immediately after a long
25811         period of daylight-saving time.
25812
25813         * lib/mktime.c: Assume freestanding C89 or better.
25814         (HAVE_LIMITS_H): Remove.  Assume it's 1.
25815         (__P): Remove; not used.
25816         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
25817         (mktime, not_equal_tm, print_tm, check_result,
25818         main): Use prototypes.  Use const * where appropriate.
25819         (main): Fix typo in testing code that uncovered by above changes.
25820         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
25821
25822 2003-06-04  Paul Eggert  <eggert@twinsun.com>
25823
25824         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
25825         locale.h, localeconv.  This merges changes from coreutils.
25826
25827         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
25828         It can be removed after the next Autoconf is released.
25829         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
25830         needed.
25831
25832 2003-06-04  Paul Eggert  <eggert@twinsun.com>
25833
25834         * lib/mktime.c: Fix Debian bug 177940
25835         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
25836         (localtime_offset): Now long int, not time_t, because we want it
25837         to be guaranteed to be signed.  All uses changed.
25838         (__mktime_internal): If overflow would occur when adding offset,
25839         don't add it.
25840
25841         Merge 'human' changes from coreutils.  Rewrite to support
25842         locale-specific notations like thousands separators.
25843         * lib/human.c: Simplify authorship notice.
25844         Include human.h immediately after config.h.
25845         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
25846         <limits.h>: Do not include, since human.h does.
25847         (SIZE_MAX, UINTMAX_MAX): New macros.
25848         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
25849         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
25850         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
25851         (power_letter): Renamed from suffixes.
25852         (generate_suffix_backwards): Remove.
25853         (adjust_value): Now takes int style (because of human.h changes)
25854         and long double value (for greater precision on some platforms).
25855         (group_number): New function.
25856         (human_readable): Use it.  Use integer options, not enum.
25857         Put the options before the sizes in the arg list.
25858         Support all the new options.
25859         The old human_readable function has been removed;
25860         use inttostr.h instead.
25861         (human_readable, default_block_size, humblock):
25862         Use uintmax_t, not int, for block sizes.
25863         (human_readable_inexact, block_size_types): Remove.
25864         (block_size_opts): New constant.
25865         (human_options): Renamed from human_block_size, with new signature
25866         that allows block sizes up to UINTMAX_MAX.  All callers changed.
25867         * lib/human.h: Add copyright and authorship notice.
25868         Include <limits.h> and <stdbool.h> unconditionally.
25869         (PARAMS): Remove.  All uses removed.
25870         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
25871         (enum human_inexact_style): Remove tag; now a nameless enum.
25872         (human_floor, human_ceiling, human_round_to_even): Now have
25873         values 2, 0, 1 rather than -1, 1, 0.
25874         (human_group_digits, human_suppress_point_zero, human_autoscale,
25875         human_base_1024, human_SI, human_B): New constants.
25876         (human_readable_inexact, human_block_size): Remove.
25877         (human_readable): Size args are now uintmax_t, not int.
25878         (human_options): New decl.
25879
25880         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
25881         unnecessary now that we assume C89 or better.  This change
25882         imported from coreutils.
25883
25884         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
25885         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
25886         in the 2003-05-30 sync from glibc.
25887
25888         .h files should stand alone, but we shouldn't include <sys/types.h>
25889         if we can get away with just <stddef.h>.
25890
25891         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
25892         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
25893         rather than <sys/types.h>, as we merely need size_t.
25894         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
25895         to get size_t.
25896         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
25897         Include <stdio.h>, to get FILE.
25898         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
25899         memcasecmp.h has included <stddef.h> and all we need is size_t.
25900         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
25901         our interface, instead of including <sys/types.h>
25902
25903 2003-06-04  Paul Eggert  <eggert@twinsun.com>
25904
25905         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
25906         now, as glibc mktime is buggy on non-glibc systems.
25907
25908 2003-06-03  Karl Berry  <karl@gnu.org>
25909
25910         * config/config.sub: update from prep.
25911
25912 2003-06-02  Paul Eggert  <eggert@twinsun.com>
25913
25914         [from coreutils]
25915         Fix some minor time-related bugs with POSIX time arguments.
25916         Some valid time stamps were being rejected (notably -1, and
25917         time stamps before 1900 on 64-bit hosts).  And some invalid
25918         time stamps were being accepted, e.g. September 31.
25919
25920         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
25921         that we can return (time_t) -1 successfully.
25922         * lib/posixtm.c: Likewise.
25923         [HAVE_STDBOOL_H]: Include <stdbool.h>.
25924         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
25925         (t): Remove static var.
25926         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
25927         of static var.  All uses changed.
25928         (year): Do not reject years before 1900; they can occur with
25929         64-bit time_t.
25930         (posix_time_parse): Do not check for out-of-range components;
25931         that is now the caller's responsibility, since our checks were
25932         only approximations.
25933         (posixtime): Use mktime to check for out-of-range components,
25934         since it knows them exactly.
25935         If mktime returns (time_t) -1, check whether an error actually occurred
25936         by invoking localtime on -1.
25937         (main) [TEST_POSIXTIME]: Check for input data errors, and report
25938         posixtime failures better.
25939         Improve the test data (in comments only).
25940
25941 2003-06-02  Karl Berry  <karl@gnu.org>
25942
25943         * config/mkinstalldirs (version): new variable.
25944         (--version): new option.
25945         (usage): improve message.
25946
25947 2003-05-30  Karl Berry  <karl@gnu.org>
25948
25949         * lib/mktime.c: update from libc.
25950
25951 2003-05-30  Bruno Haible  <bruno@clisp.org>
25952
25953         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
25954         * config/config.rpath: Upgrade to gettext-0.12.1.
25955
25956 2003-05-30  Bruno Haible  <bruno@clisp.org>
25957
25958         * m4/gettext.m4: Upgrade to gettext-0.12.1.
25959         * m4/nls.m4: New file, from gettext-0.12.1.
25960         * m4/po.m4: New file, from gettext-0.12.1.
25961         * m4/progtest.m4: Upgrade to gettext-0.12.1.
25962
25963 2003-05-30  Bruno Haible  <bruno@clisp.org>
25964
25965         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
25966         * lib/localcharset.h: Likewise.
25967         * lib/localcharset.c: Likewise.
25968
25969 2003-05-29  Karl Berry  <karl@gnu.org>
25970
25971         * config/config.rpath: update from gettext.
25972
25973 2003-05-28  Paul Eggert  <eggert@twinsun.com>
25974
25975         Assume the headers required for C89 freestanding compilers.
25976         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
25977         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
25978         * m4/human.m4 (gl_HUMAN): Likewise.
25979         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
25980         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
25981         * m4/userspec.m4 (gl_USERSPEC): Likewise.
25982         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
25983         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
25984         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
25985
25986 2003-05-28  Paul Eggert  <eggert@twinsun.com>
25987
25988         Assume the headers required for C89 freestanding compilers.
25989         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
25990         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
25991         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
25992         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
25993         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
25994         define, since <limits.h> is guaranteed to do that.
25995         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
25996         * lib/exclude.c: Include <stdbool.h> unconditionally.
25997         * lib/tempname.c: Include <stddef.h> unconditionally.
25998         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
25999         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
26000         <stddef.h> does that.
26001         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
26002         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
26003         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
26004         needed.
26005         * lib/xstrtol.c: Likewise.
26006         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
26007         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
26008
26009         * lib/addext.c (addext): Use assignment rather than cast, to avoid
26010         warnings on some platforms.
26011
26012         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26013         arbitrarily.
26014
26015 2003-05-26  Jim Meyering  <jim@meyering.net>
26016
26017         Merge in a change from coreutils:
26018         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
26019         that is guaranteed to be `no'.  Use `no_such_member' to indicate
26020         that condition, rather than `-1' which is slightly misleading.
26021         Change the name of the cache variable to have the gl_ prefix.
26022         Prompted by a patch from Richard Dawe for DJGPP.
26023
26024 2003-05-24  Karl Berry  <karl@gnu.org>
26025
26026         * config/config.guess: update from prep.
26027
26028 2003-05-22  Karl Berry  <karl@gnu.org>
26029
26030         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
26031
26032 2003-05-20  Karl Berry  <karl@gnu.org>
26033
26034         * config/config.guess: update from prep.
26035
26036 2003-05-18  Karl Berry  <karl@gnu.org>
26037
26038         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
26039         might actually be set by the user.
26040
26041         * config/depcomp, install-sh, mdate-sh: update from automake.
26042
26043 2003-05-17  Bruno Haible  <bruno@clisp.org>
26044
26045         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
26046         invalid expansion for AC_EGREP_CPP.
26047         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
26048         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
26049         Suggested by Akim Demaille <akim@epita.fr> in
26050         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
26051
26052 2003-05-12  Jim Meyering  <jim@meyering.net>
26053
26054         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
26055         the space-padded-by-default conversion specifiers, %e, %k, %l.
26056
26057 2003-05-12  Bruno Haible  <bruno@clisp.org>
26058
26059         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
26060         the string is longer than 4 KB.
26061
26062 2003-05-11  Karl Berry  <karl@gnu.org>
26063
26064         * config/config.{guess,sub}: update from prep.
26065
26066 2003-05-09  Bruno Haible  <bruno@clisp.org>
26067
26068         * modules/error: Add m4/strerror_r.m4 to file list.
26069
26070 2003-05-03  Bruno Haible  <bruno@clisp.org>
26071
26072         Upgrade to Unicode-4.0.
26073         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
26074         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
26075         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
26076         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
26077         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
26078         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
26079         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
26080         Change width of U+E0100..U+E01EF from 1 to 0.
26081
26082 2003-04-25  Jim Meyering  <jim@meyering.net>
26083
26084         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
26085         of type size_t, not int.
26086
26087 2003-04-25  Bruno Haible  <bruno@clisp.org>
26088
26089         * lib/copy-file.c: Include <stddef.h>, for size_t.
26090
26091 2003-04-21  Paul Eggert  <eggert@twinsun.com>
26092
26093         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
26094         code which expansion is under static control.  Patch imported from
26095         Akim Demaille's patch to Bison; see
26096         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
26097
26098 2003-04-14  Bruno Haible  <bruno@clisp.org>
26099
26100         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
26101
26102 2003-04-11  Jim Meyering  <jim@meyering.net>
26103
26104         Merge changes from Coreutils.
26105
26106         2003-03-22  Jim Meyering  <jim@meyering.net>
26107
26108         * lib/strftime.c (widen): Cast alloca return value to proper type.
26109
26110         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
26111
26112         From GNU libc.
26113         * lib/strftime.c (my_strftime): Handle very large width
26114         specifications for numeric values correctly.  Improve checks for
26115         overflow.
26116
26117         2003-01-19  Jim Meyering  <jim@meyering.net>
26118
26119         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
26120         definitions.
26121         (nl_get_alt_digit) [! defined my_strftime]: Define.
26122         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
26123         _nl_get_alt_digit and _nl_get_walt_digit.
26124
26125         * lib/strftime.c (my_strftime): Merge in locale-related changes from
26126         libc. These changes have no effect outside of _LIBC.
26127
26128 2003-04-10  Bruno Haible  <bruno@clisp.org>
26129
26130         * modules/findprog: New file.
26131         * MODULES.html.sh (func_all_modules): Add it.
26132
26133 2003-04-10  Bruno Haible  <bruno@clisp.org>
26134
26135         * m4/findprog.m4: New file.
26136         * m4/eaccess.m4: New file.
26137
26138 2003-04-10  Bruno Haible  <bruno@clisp.org>
26139
26140         * lib/findprog.h: New file, from GNU gettext.
26141         * lib/findprog.c: New file, from GNU gettext.
26142
26143 2003-04-05  Jim Meyering  <jim@meyering.net>
26144
26145         Merge changes from Coreutils.
26146
26147         * lib/exclude.h (PARAMS): Remove definition and uses.
26148         * lib/exclude.c: Remove uses of `PARAMS'.
26149
26150         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
26151         Add test-cases for DOS filenames. Declare program_name.
26152         (main): Set up program_name.  Patch by Rich Dawe.
26153
26154         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
26155         error from mntctl.
26156         Use mntctl's return value to drive the entry-processing loop, since
26157         we can't rely on the value of the vmt_length member in the last
26158         entry.  On some systems doing so could result in exhausting
26159         virtual memory.  Based in part on a patch from Mike Jetzer.
26160
26161 2003-04-04  Bruno Haible  <bruno@clisp.org>
26162
26163         * modules/linebreak: New file.
26164         * MODULES.html.sh (func_all_modules): Add it.
26165
26166 2003-04-04  Bruno Haible  <bruno@clisp.org>
26167
26168         * m4/linebreak.m4: New file.
26169
26170 2003-04-04  Bruno Haible  <bruno@clisp.org>
26171
26172         * lib/linebreak.h: New file, from GNU gettext.
26173         * lib/linebreak.c: New file, from GNU gettext with slight
26174         modifications.
26175         * lib/lbrkprop.h: New file, from GNU gettext.
26176
26177 2003-04-03  Bruno Haible  <bruno@clisp.org>
26178
26179         * modules/utf8-ucs4: New file.
26180         * modules/utf16-ucs4: New file.
26181         * modules/ucs4-utf8: New file.
26182         * modules/ucs4-utf16: New file.
26183         * MODULES.html.sh (func_all_modules): Add them.
26184
26185 2003-04-03  Bruno Haible  <bruno@clisp.org>
26186
26187         * m4/utf-ucs4.m4: New file.
26188         * m4/ucs4-utf.m4: New file.
26189
26190 2003-04-03  Bruno Haible  <bruno@clisp.org>
26191
26192         * lib/utf8-ucs4.h: New file, from GNU gettext.
26193         * lib/utf16-ucs4.h: New file, from GNU gettext.
26194         * lib/ucs4-utf8.h: New file, from GNU gettext.
26195         * lib/ucs4-utf16.h: New file, from GNU gettext.
26196
26197 2003-04-02  Bruno Haible  <bruno@clisp.org>
26198
26199         * modules/binary-io: New file.
26200         * MODULES.html.sh (func_all_modules): Add it.
26201
26202 2003-04-02  Bruno Haible  <bruno@clisp.org>
26203
26204         * lib/binary-io.h: New file, from GNU gettext.
26205
26206 2003-04-01  Bruno Haible  <bruno@clisp.org>
26207
26208         * modules/pathname: New file.
26209         * MODULES.html.sh (func_all_modules): Add it.
26210
26211 2003-04-01  Bruno Haible  <bruno@clisp.org>
26212
26213         * lib/pathname.h: New file, from GNU gettext.
26214         * lib/concatpath.c: New file, from GNU gettext.
26215
26216 2003-03-30  Bruno Haible  <bruno@clisp.org>
26217
26218         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
26219
26220 2003-03-30  Bruno Haible  <bruno@clisp.org>
26221
26222         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
26223         function chown() doesn't exist.
26224
26225 2003-03-28  Bruno Haible  <bruno@clisp.org>
26226
26227         * modules/copy-file: New file.
26228         * MODULES.html.sh (func_all_modules): Add it.
26229
26230 2003-03-28  Bruno Haible  <bruno@clisp.org>
26231
26232         * m4/copy-file.m4: New file.
26233
26234 2003-03-28  Bruno Haible  <bruno@clisp.org>
26235
26236         * lib/copy-file.h: New file, from GNU gettext.
26237         * lib/copy-file.c: New file, from GNU gettext.
26238
26239 2003-03-18  Jim Meyering  <jim@meyering.net>
26240
26241         * lib/quote.c (quote_n): Fix typo in comment.
26242
26243 2003-03-18  Bruno Haible  <bruno@clisp.org>
26244
26245         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
26246         checking.
26247         * m4/onceonly_2_57.m4: Likewise.
26248
26249 2003-03-17  Bruno Haible  <bruno@clisp.org>
26250
26251         * m4/onceonly.m4: Require autoconf 2.54 or newer.
26252         (m4_quote): Remove macro.
26253         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
26254
26255 2003-03-14  Jim Meyering  <jim@meyering.net>
26256
26257         Merge changes from Coreutils.
26258         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
26259         to be const, in order to avoid warnings.
26260         (obstack_room): Likewise.
26261         (obstack_empty_p): Likewise.
26262
26263 2003-03-14  Bruno Haible  <bruno@clisp.org>
26264
26265         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
26266         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
26267
26268 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26269
26270         Merge changes from Bison.
26271         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
26272         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
26273         when compiling Bison 1.875's `bitset bset = obstack_alloc
26274         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
26275         * lib/hash.c: Include <stdbool.h> unconditionally.
26276
26277 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26278
26279         * m4/onceonly.m4 (m4_quote): New macro.
26280         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
26281         Quote AC_FOREACH variable-expansions properly.
26282
26283 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26284
26285         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
26286
26287 2003-03-09  Paul Eggert  <eggert@twinsun.com>
26288
26289         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
26290         Reported by Bruce Becker; see:
26291         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
26292
26293 2003-03-03  Paul Eggert  <eggert@twinsun.com>
26294             Bruno Haible  <bruno@clisp.org>
26295
26296         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
26297         Reported by John Hughes, see
26298         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
26299
26300 2003-02-20  Bruno Haible  <bruno@clisp.org>
26301
26302         * MODULES.html.sh (func_all_modules): Add poll.
26303
26304 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26305
26306         * modules/poll: New file.
26307
26308 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26309
26310         * lib/poll_.h: New file.
26311         * lib/poll.c: New file.
26312
26313 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26314
26315         * m4/poll.m4: New file.
26316
26317 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26318
26319         * modules/mathl: New file.
26320
26321 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26322
26323         * lib/mathl.h: New file.
26324         * lib/acosl.c: New file.
26325         * lib/asinl.c: New file.
26326         * lib/atanl.c: New file.
26327         * lib/ceill.c: New file.
26328         * lib/cosl.c: New file.
26329         * lib/expl.c: New file.
26330         * lib/floorl.c: New file.
26331         * lib/frexpl.c: New file.
26332         * lib/ldexpl.c: New file.
26333         * lib/logl.c: New file.
26334         * lib/sincosl.c: New file.
26335         * lib/sinl.c: New file.
26336         * lib/sqrtl.c: New file.
26337         * lib/tanl.c: New file.
26338         * lib/trigl.c: New file.
26339         * lib/trigl.h: New file.
26340
26341 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26342
26343         * m4/mathl.m4: New file.
26344
26345 2003-02-18  Bruno Haible  <bruno@clisp.org>
26346
26347         * MODULES.html.sh (func_all_modules): Add mathl.
26348
26349 2003-02-17  Bruno Haible  <bruno@clisp.org>
26350
26351         * modules/mkdtemp: New module.
26352         * MODULES.html.sh (func_all_modules): Add it.
26353
26354 2003-02-17  Bruno Haible  <bruno@clisp.org>
26355
26356         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
26357
26358 2003-02-17  Bruno Haible  <bruno@clisp.org>
26359
26360         * lib/mkdtemp.h: New file, from GNU gettext.
26361         * lib/mkdtemp.c: New file, from GNU gettext.
26362
26363 2003-02-02  Jim Meyering  <jim@meyering.net>
26364
26365         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
26366         e.g. glibc-2.2.93.
26367
26368 2003-01-31  Bruno Haible  <bruno@clisp.org>
26369
26370         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
26371         'rpl_rename'.
26372         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
26373         'rpl_strnlen'.
26374         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
26375         'rpl_strtod'.
26376         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
26377         'rpl_utime'.
26378
26379 2003-01-31  Bruno Haible  <bruno@clisp.org>
26380
26381         * lib/rename.c: #undef rename before defining rpl_rename.
26382         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
26383
26384 2003-01-30  Bruno Haible  <bruno@clisp.org>
26385
26386         * modules/vasnprintf, modules/vasprintf: New modules.
26387         * MODULES.html.sh (func_all_modules): Add them.
26388
26389 2003-01-30  Bruno Haible  <bruno@clisp.org>
26390
26391         * m4/signed.m4: New file, from GNU gettext.
26392         * m4/longdouble.m4: New file, from GNU gettext.
26393         * m4/wchar_t.m4: New file, from GNU gettext.
26394         * m4/wint_t.m4: New file, from GNU gettext.
26395         * m4/vasnprintf.m4: New file.
26396         * m4/vasprintf.m4: New file.
26397
26398 2003-01-30  Bruno Haible  <bruno@clisp.org>
26399
26400         * lib/printf-args.h: New file, from GNU gettext.
26401         * lib/printf-args.c: New file, from GNU gettext.
26402         * lib/printf-parse.h: New file, from GNU gettext.
26403         * lib/printf-parse.c: New file, from GNU gettext.
26404         * lib/vasnprintf.h: New file, from GNU gettext.
26405         * lib/vasnprintf.c: New file, from GNU gettext.
26406         * lib/asnprintf.c: New file, from GNU gettext.
26407         * lib/vasprintf.h: New file, from GNU gettext with modifications.
26408         * lib/vasprintf.c: New file, from GNU gettext.
26409         * lib/asprintf.c: New file, from GNU gettext.
26410
26411 2003-01-29  Bruno Haible  <bruno@clisp.org>
26412
26413         * modules/stpncpy: New module.
26414         * MODULES.html.sh (func_all_modules): Add it.
26415
26416 2003-01-29  Bruno Haible  <bruno@clisp.org>
26417
26418         * m4/stpncpy.m4: New file.
26419
26420 2003-01-29  Bruno Haible  <bruno@clisp.org>
26421
26422         * lib/stpncpy.h: New file, from GNU gettext with modifications.
26423         * lib/stpncpy.c: New file, from GNU gettext with modifications.
26424
26425 2003-01-28  Bruno Haible  <bruno@clisp.org>
26426
26427         * modules/c-ctype: New module.
26428         * MODULES.html.sh (func_all_modules): Add it.
26429
26430 2003-01-28  Bruno Haible  <bruno@clisp.org>
26431
26432         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
26433         Paul Eggert.
26434         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
26435         Paul Eggert.
26436
26437 2003-01-27  Bruno Haible  <bruno@clisp.org>
26438
26439         * modules/xsetenv: New module.
26440         * MODULES.html.sh (func_all_modules): Add it.
26441
26442 2003-01-27  Bruno Haible  <bruno@clisp.org>
26443
26444         * lib/xsetenv.h: New file, from GNU gettext.
26445         * lib/xsetenv.c: New file, from GNU gettext.
26446
26447 2003-01-23  Jim Meyering  <jim@meyering.net>
26448
26449         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
26450         from working on systems without dirfd (at least Irix and OSF1/Tru64).
26451
26452 2003-01-23  Bruno Haible  <bruno@clisp.org>
26453
26454         * modules/minmax: New module.
26455         * MODULES.html.sh (func_all_modules): Add it.
26456
26457 2003-01-23  Bruno Haible  <bruno@clisp.org>
26458
26459         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
26460         Eggert.
26461
26462 2003-01-22  Bruno Haible  <bruno@clisp.org>
26463
26464         * modules/exit: New module.
26465         * MODULES.html.sh (func_all_modules): Add it.
26466
26467 2003-01-22  Bruno Haible  <bruno@clisp.org>
26468
26469         * lib/exit.h: New file, from GNU gettext.
26470
26471 2003-01-19  Bruno Haible  <bruno@clisp.org>
26472
26473         * gnulib-tool: Recognize option --extract-maintainer.
26474         (func_get_maintainer): New function.
26475         * modules/*: Add Maintainer entry.
26476
26477 2003-01-16  Jim Meyering  <jim@meyering.net>
26478
26479         * m4/regex.m4: The `regex' struct is both input and output.
26480         Initialize it before each use.  Patch by Tim Waugh.
26481
26482 2003-01-16  Bruno Haible  <bruno@clisp.org>
26483
26484         * MODULES.html.sh: Add a table of contents. Add the module name as
26485         leftmost column. Add hyperlinks.
26486
26487 2003-01-15  Bruno Haible  <bruno@clisp.org>
26488
26489         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
26490
26491 2003-01-15  Bruno Haible  <bruno@clisp.org>
26492
26493         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
26494         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
26495         suffix.
26496
26497 2003-01-15  Bruno Haible  <bruno@clisp.org>
26498
26499         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
26500
26501 2003-01-15  Bruno Haible  <bruno@clisp.org>
26502
26503         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
26504         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
26505
26506 2003-01-14  Jim Meyering  <jim@meyering.net>
26507
26508         * lib/same.c (same_name): Tweak a comment.
26509
26510 2003-01-14  Bruno Haible  <bruno@clisp.org>
26511
26512         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
26513         when a string comparison is sufficient.
26514
26515 2003-01-14  Bruno Haible  <bruno@clisp.org>
26516
26517         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
26518         'unsigned int'.
26519
26520 2003-01-14  Bruno Haible  <bruno@clisp.org>
26521
26522         * lib/hash-pjw.c: Add comment about low quality of this function.
26523
26524 2003-01-13  Bruno Haible  <bruno@clisp.org>
26525
26526         * modules/stpcpy: Distribute lib/stpcpy.h.
26527         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
26528
26529 2003-01-13  Bruno Haible  <bruno@clisp.org>
26530
26531         * modules/*: Add a description.
26532         * modules/strpbrk: Fix Makefile.am snippet.
26533         * modules/strtoimax: Fix dependencies.
26534         * modules/strtoumax: Likewise.
26535
26536 2003-01-13  Bruno Haible  <bruno@clisp.org>
26537
26538         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
26539         * modules/alloca (Makefile.am): All object files depend on alloca.h.
26540         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
26541
26542 2003-01-13  Bruno Haible  <bruno@clisp.org>
26543
26544         * gnulib-tool (func_create_testdir): Store config/* files in the main
26545         directory.
26546         * config.rpath: Move to ...
26547         * config/config.rpath: ... here.
26548         * modules/gettext: Contains config/config.rpath, not config.rpath.
26549         * modules/iconv: Likewise.
26550
26551 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26552
26553         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26554         to avoid collisions with libcurses and libreadline.
26555
26556         * m4/getstr.m4: Remove.
26557         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
26558
26559 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26560
26561         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26562         to avoid collisions with libcurses and libreadline.
26563
26564         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
26565         * lib/getstr.h, getstr.c: Remove.
26566         * lib/getline.c: Include "getline.h", to check interface.
26567         Move body of old getstr.c here: this defines MIN_CHUNK and
26568         declares getdelim2, which is renamed from getstr.
26569         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
26570
26571         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
26572         All uses changed.
26573         * lib/linebuffer.h: Likewise.
26574         (readline): Remove backward-compatibility macro.
26575
26576 2003-01-12  Paul Eggert  <eggert@twinsun.com>
26577
26578         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
26579         to avoid collisions with libcurses and libreadline.
26580         * getstr: Remove.
26581         * MODULES.html.sh: Remove getstr.
26582         * modules/getline: Depend on unlocked-io, not getstr.
26583
26584 2003-01-12  Jim Meyering  <jim@meyering.net>
26585
26586         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
26587
26588 2003-01-10  Bruno Haible  <bruno@clisp.org>
26589
26590         * modules/alloca: Change Makefile.am requirements. Simplify Include
26591         requirements. Add lib/alloca_.h to file list.
26592
26593 2003-01-10  Bruno Haible  <bruno@clisp.org>
26594
26595         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
26596
26597 2003-01-10  Bruno Haible  <bruno@clisp.org>
26598
26599         * lib/alloca_.h: New file.
26600         * lib/getdate.y: Unconditionally include alloca.h.
26601         * lib/makepath.c: Likewise.
26602         * lib/setenv.c: Likewise.
26603         * lib/userspec.c: Likewise.
26604
26605 2003-01-09  Karl Berry  <karl@gnu.org>
26606
26607         * MODULES.html.sh: include `dirname $0` in PATH, to find
26608         gnulib-tool.
26609
26610 2003-01-09  Bruno Haible  <bruno@clisp.org>
26611
26612         * modules/stdbool: Change configure.ac, Makefile.am requirements.
26613         Simplify Include requirements. Add lib/stdbool.h.in to file list.
26614
26615 2003-01-09  Bruno Haible  <bruno@clisp.org>
26616
26617         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
26618
26619 2003-01-09  Bruno Haible  <bruno@clisp.org>
26620
26621         * lib/stdbool.h.in: New file.
26622
26623 2003-01-09  Bruno Haible  <bruno@clisp.org>
26624
26625         * gnulib-tool (func_all_modules): Ignore files ending in ~.
26626         * MODULES.html.sh: Likewise.
26627
26628 2003-01-08  Jim Meyering  <jim@meyering.net>
26629
26630         * lib/full-write.c: Undefine and define-away `const' after inclusion
26631         of errno.h, not before.  Suggestion from Bruno Haible.
26632
26633 2003-01-08  Bruno Haible  <bruno@clisp.org>
26634
26635         * modules/full-read: Depend on full-write.
26636
26637 2003-01-08  Bruno Haible  <bruno@clisp.org>
26638
26639         * lib/safe-read.c: Include specification header first, to ensure its
26640         selfcontainedness.
26641         * lib/full-write.c: Likewise.
26642
26643 2003-01-07  Jim Meyering  <jim@meyering.net>
26644
26645         * lib/full-write.c: Rework so that it may serve to define full_read,
26646         too.
26647         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
26648
26649 2003-01-07  Bruno Haible  <bruno@clisp.org>
26650
26651         * lib/strtoimax.c: Include <stdint.h> as an alternative to
26652         <inttypes.h>.
26653         * lib/xstrtol.h: Likewise.
26654         * lib/xstrtoimax.c: Likewise.
26655         * lib/xstrtoumax.c: Likewise.
26656         * lib/human.h: Likewise.
26657
26658         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
26659         on systems that have <inttypes.h> but not <stdint.h>.
26660
26661 2003-01-07  Bruno Haible  <bruno@clisp.org>
26662
26663         * MODULES.html.sh: Add copyright notice.
26664         (missed_files): Omit CVS directory entries.
26665         (func_module): Make it work with sed-3.02.
26666         * MODULES.txt: Remove file.
26667
26668 2003-01-06  Jim Meyering  <jim@meyering.net>
26669
26670         * lib/version-etc.c: Update year in translatable copyright string.
26671
26672 2003-01-03  Karl Berry  <karl@gnu.org>
26673
26674         * config/config.{guess,sub}: update from prep.
26675
26676 2003-01-02  Karl Berry  <karl@gnu.org>
26677
26678         * doc/COPYING.DOC: belatedly updated to 1.2.
26679
26680 2003-01-01  Karl Berry  <karl@gnu.org>
26681
26682         * gnulib-tool (func_verify_module): report module name $module in
26683         error message, not $1.
26684         * gnulib-tool (create-testdir): don't complain if destdir couldn't
26685         be created, only if it doesn't exist.
26686         * gnulib-tool (last_checkin_date): don't expand the $Date here.
26687
26688 2002-12-31  Paul Eggert  <eggert@twinsun.com>
26689
26690         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
26691
26692 2002-12-31  Paul Eggert  <eggert@twinsun.com>
26693
26694         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
26695         memcmp if strcoll doesn't work.
26696
26697 2002-12-31  Bruno Haible  <bruno@clisp.org>
26698
26699         * lib/utime.c (utime_null): No need to call ftruncate if the file was
26700         nonempty.
26701
26702 2002-12-31  Bruno Haible  <bruno@clisp.org>
26703
26704         * lib/memcoll.c (STRCOLL): New macro.
26705         (memcoll): Use it.
26706
26707 2002-12-31  Bruno Haible  <bruno@clisp.org>
26708
26709         * lib/localcharset.h: New file.
26710         * lib/localcharset.c: Include it.
26711         * lib/unicodeio.c: Likewise.
26712
26713 2002-12-31  Bruno Haible  <bruno@clisp.org>
26714
26715         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
26716         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
26717
26718 2002-12-31  Bruno Haible  <bruno@clisp.org>
26719
26720         * lib/getline.h: Include <stddef.h>, for size_t.
26721
26722         * lib/unicodeio.h: Include <stddef.h>, for size_t.
26723         * lib/unicodeio.c: Don't include <stddef.h>.
26724
26725 2002-12-31  Bruno Haible  <bruno@clisp.org>
26726
26727         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
26728         HAVE_TM_ZONE.
26729
26730 2002-12-24  Karl Berry  <karl@gnu.org>
26731
26732         * config/config.guess: update from prep.
26733
26734 2002-12-24  Bruno Haible  <bruno@clisp.org>
26735
26736         General infrasructure.
26737         * m4/README: Rewritten.
26738         * m4/onceonly.m4: New file.
26739         * m4/onceonly_2_57.m4: New file.
26740
26741         Module atexit.
26742         * m4/atexit.m4: New file.
26743
26744         Module strtod.
26745         * m4/strtod.m4: New file.
26746
26747         Module strtol.
26748         * m4/strtol.m4: New file.
26749
26750         Module strtoul.
26751         * m4/strtoul.m4: New file.
26752
26753         Module memchr.
26754         * m4/memchr.m4: New file.
26755
26756         Module memcmp.
26757         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
26758         (jm_FUNC_MEMCMP): Invoke it.
26759
26760         Module memcpy.
26761         * m4/memcpy.m4: New file.
26762
26763         Module memmove.
26764         * m4/memmove.m4: New file.
26765
26766         Module memset.
26767         * m4/memset.m4: New file.
26768
26769         Module strcspn.
26770         * m4/strcspn.m4: New file.
26771
26772         Module strpbrk.
26773         * m4/strpbrk.m4: New file.
26774
26775         Module strstr.
26776         * m4/strstr.m4: New file.
26777
26778         Module strerror.
26779         * m4/strerror.m4: New file.
26780
26781         Module mktime.
26782         * m4/mktime.m4: Renamed from jm-mktime.m4.
26783         (gl_PREREQ_MKTIME): New macro.
26784         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
26785
26786         Module malloc.
26787         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
26788         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
26789         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
26790
26791         Module realloc.
26792         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
26793         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
26794         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
26795
26796         Module strftime.
26797         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
26798         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
26799         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
26800         gl_TM_GMTOFF.
26801         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
26802
26803         Module xalloc.
26804         * m4/xalloc.m4: New file.
26805
26806         Module alloca.
26807         * m4/alloca.m4: New file.
26808
26809         Module putenv.
26810         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
26811         (jm_FUNC_PUTENV): Invoke it.
26812
26813         Module setenv.
26814         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
26815         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
26816         when invoked twice.
26817         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
26818         gt_FUNC_SETENV.
26819
26820         Module memrchr.
26821         * m4/memrchr.m4: New file.
26822
26823         Module stpcpy.
26824         * m4/stpcpy.m4: New file.
26825
26826         Module strcase.
26827         * m4/strcase.m4: New file.
26828
26829         Module strdup.
26830         * m4/strdup.m4: New file.
26831
26832         Module strnlen.
26833         * m4/strnlen.m4: New file.
26834
26835         Module strndup.
26836         * m4/strndup.m4: New file.
26837
26838         Module xstrtod.
26839         * m4/xstrtod.m4: New file.
26840
26841         Module xstrtol.
26842         * m4/xstrtol.m4: New file.
26843
26844         Module getdate.
26845         * m4/getdate.m4: New file.
26846
26847         Module unlocked-io.
26848         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
26849         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
26850         * m4/jm-glibc-io.m4n: Remove file.
26851
26852         Module long-options.
26853         * m4/long-options.m4: New file.
26854
26855         Module md5.
26856         * m4/md5.m4: New file.
26857
26858         Module sha.
26859         * m4/sha.m4: New file.
26860
26861         Module getstr.
26862         * m4/getstr.m4: New file.
26863
26864         Module getline.
26865         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
26866         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
26867         <sys/types.h>, for size_t. Use the function name gnu_getline, not
26868         simply getline. Infoke gl_PREREQ_GETLINE.
26869
26870         Module obstack.
26871         * m4/obstack.m4: New file.
26872
26873         Module hash.
26874         * m4/hash.m4: New file.
26875
26876         Module readtokens.
26877         * m4/readtokens.m4: New file.
26878
26879         Module strverscmp.
26880         * m4/strverscmp.m4: New file.
26881
26882         Module stdbool.
26883         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
26884         OSF/1.
26885
26886         Module strtoll.
26887         * m4/strtoll.m4: New file.
26888
26889         Module strtoull.
26890         * m4/strtoull.m4: New file.
26891
26892         Module strtoimax.
26893         * m4/strtoimax.m4: New file.
26894
26895         Module strtoumax.
26896         * m4/strtoumax.m4: New file.
26897
26898         Module xstrtoimax.
26899         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
26900         jm_AC_PREREQ_XSTRTOIMAX.
26901         Moved the strtol prerequisites to strtol.m4.
26902         Moved the strtoll prerequisites to strtoll.m4.
26903         Moved the strtoimax prerequisites to strtoimax.m4.
26904
26905         Module xstrtoumax.
26906         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
26907         jm_AC_PREREQ_XSTRTOUMAX.
26908         Moved the strtoul prerequisites to strtoul.m4.
26909         Moved the strtoull prerequisites to strtoull.m4.
26910         Moved the strtoumax prerequisites to strtoumax.m4.
26911
26912         Module chown.
26913         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
26914         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
26915
26916         Module dup2.
26917         * m4/dup2.m4: New file.
26918
26919         Module ftruncate.
26920         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
26921         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
26922
26923         Module getgroups.
26924         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
26925         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
26926
26927         Module gettimeofday.
26928         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
26929         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
26930         gl_PREREQ_GETTIMEOFDAY.
26931
26932         Module mkdir.
26933         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
26934         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
26935
26936         Module mkstemp.
26937         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
26938         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
26939         jm_AC_TYPE_UINTMAX_T.
26940         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
26941
26942         Module stat.
26943         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
26944         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
26945
26946         Module lstat.
26947         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
26948         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
26949
26950         Module timespec.
26951         * m4/timespec.m4 (gl_TIMESPEC): New macro.
26952         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
26953         * m4/st_mtim.m4: Indentation.
26954
26955         Module nanosleep.
26956         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
26957         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
26958         gl_PREREQ_NANOSLEEP.
26959
26960         Module regex.
26961         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
26962         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
26963         (gl_REGEX): New macro.
26964
26965         Module rename.
26966         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
26967         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
26968
26969         Module rmdir.
26970         * m4/rmdir.m4: New file.
26971
26972         Module utime.
26973         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
26974         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
26975         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
26976
26977         Module dirname.
26978         * m4/dirname.m4: New file.
26979
26980         Module getopt.
26981         * m4/getopt.m4: New file.
26982
26983         Module unistd-safer.
26984         * m4/unistd-safer.m4: New file.
26985
26986         Module fnmatch.
26987         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
26988         declaration.
26989         (gl_PREREQ_FNMATCH_EXTRA): New macro.
26990         (gl_FUNC_FNMATCH_POSIX): New macro.
26991         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
26992         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
26993         simply fnmatch.
26994
26995         Module exclude.
26996         * m4/exclude.m4: New file.
26997
26998         Module human.
26999         * m4/human.m4: New file.
27000
27001         Module acl.
27002         * m4/acl.m4: Nop.
27003
27004         Module backupfile.
27005         * m4/backupfile.m4: New file.
27006         * m4/d-ino.m4: Indentation.
27007
27008         Module fsusage.
27009         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
27010         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
27011         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
27012
27013         Module dirfd.
27014         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
27015         requirements.
27016
27017         Module euidaccess.
27018         * m4/euidaccess.m4: New file.
27019
27020         Module file-type.
27021         * m4/file-type.m4: New file.
27022
27023         Module fileblocks.
27024         * m4/fileblocks.m4: New file.
27025
27026         Module filemode.
27027         * m4/filemode.m4: New file.
27028
27029         Module isdir.
27030         * m4/isdir.m4: New file.
27031
27032         Module lchown.
27033         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
27034         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
27035
27036         Module makepath.
27037         * m4/makepath.m4: New file.
27038
27039         Module modechange.
27040         * m4/modechange.m4: New file.
27041
27042         Module mountlist.
27043         * m4/mountlist.m4: New file.
27044         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
27045         Indentation.
27046
27047         Module path-concat.
27048         * m4/path-concat.m4: New file.
27049
27050         Module pathmax.
27051         * m4/pathmax.m4: New file.
27052
27053         Module same.
27054         * m4/same.m4: New file.
27055
27056         Module save-cwd.
27057         * m4/save-cwd.m4: New file.
27058
27059         Module savedir.
27060         * m4/savedir.m4: New file.
27061
27062         Module xgetcwd.
27063         * m4/xgetcwd.m4: New file.
27064         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
27065
27066         Module xreadlink.
27067         * m4/xreadlink.m4: New file.
27068
27069         Module safe-read.
27070         * m4/safe-read.m4: New file.
27071
27072         Module safe-write.
27073         * m4/safe-write.m4: New file.
27074
27075         Module closeout.
27076         * m4/closeout.m4: New file.
27077
27078         Module stdio-safer.
27079         * m4/stdio-safer.m4: New file.
27080
27081         Module getpass.
27082         * m4/getpass.m4: New file.
27083
27084         Module getugroups.
27085         * m4/getugroups.m4: New file.
27086
27087         Module group-member.
27088         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
27089         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
27090
27091         Module idcache.
27092         * m4/idcache.m4: New file.
27093
27094         Module userspec.
27095         * m4/userspec.m4: New file.
27096
27097         Module gettime.
27098         * m4/clock_time.m4: New file.
27099         * m4/gettime.m4: New file.
27100
27101         Module settime.
27102         * m4/settime.m4: New file.
27103
27104         Module posixtm.
27105         * m4/posixtm.m4: New file.
27106
27107         Module gethostname.
27108         * m4/gethostname.m4: New file.
27109
27110         Module canon-host.
27111         * m4/canon-host.m4: New file.
27112
27113         Module gettext.
27114         * m4/codeset.m4: New file, from gettext-0.11.5.
27115         * m4/gettext.m4: New file, from gettext-0.11.5.
27116         * m4/glibc21.m4: New file, from gettext-0.11.5.
27117         * m4/iconv.m4: New file, from gettext-0.11.5.
27118         * m4/intdiv0.m4: New file, from gettext-0.11.5.
27119         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
27120         * m4/inttypes.m4: New file, from gettext-0.11.5.
27121         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
27122         * m4/isc-posix.m4: New file, from gettext-0.11.5.
27123         * m4/lcmessage.m4: New file, from gettext-0.11.5.
27124         * m4/lib-ld.m4: New file, from gettext-0.11.5.
27125         * m4/lib-link.m4: New file, from gettext-0.11.5.
27126         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
27127         * m4/progtest.m4: New file, from gettext-0.11.5.
27128         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
27129         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
27130         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
27131
27132         Module localcharset.
27133         * m4/localcharset.m4: New file.
27134
27135         Module hard-locale.
27136         * m4/hard-locale.m4: New file.
27137
27138         Module mbswidth.
27139         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
27140         onceonly macros.
27141         * m4/mbrtowc.m4: Add comment.
27142
27143         Module memcasecmp.
27144         * m4/memcasecmp.m4: New file.
27145
27146         Module memcoll.
27147         * m4/memcoll.m4: New file.
27148
27149         Module unicodeio.
27150         * m4/unicodeio.m4: New file.
27151
27152         Module rpmatch.
27153         * m4/rpmatch.m4: New file.
27154
27155         Module yesno.
27156         * m4/yesno.m4: New file.
27157
27158         Module exitfail.
27159         * m4/exitfail.m4: New file.
27160
27161         Module c-stack.
27162         * m4/c-stack.m4 (gl_C_STACK): New macro.
27163         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
27164
27165         Module error.
27166         * m4/error.m4 (gl_ERROR): New macro.
27167         (jm_PREREQ_ERROR): Use onceonly macros.
27168
27169         Module fatal.
27170         * m4/fatal.m4: New file.
27171
27172         Module getloadavg.
27173         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
27174         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
27175
27176         Module getpagesize.
27177         * m4/getpagesize.m4: New file.
27178
27179         Module getusershell.
27180         * m4/getusershell.m4: New file.
27181
27182         Module physmem.
27183         * m4/physmem.m4: New file.
27184
27185         Module posixver.
27186         * m4/posixver.m4: New file.
27187
27188         Module quotearg.
27189         * m4/quotearg.m4: New file.
27190
27191         Module quote.
27192         * m4/quote.m4: New file.
27193
27194         Module readutmp.
27195         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
27196
27197         Module sig2str.
27198         * m4/sig2str.m4: New file.
27199
27200         Other.
27201         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
27202         ulonglong.m4.
27203         * m4/intmax_t.m4: New file.
27204         * m4/d-type.m4: Indentation.
27205         * m4/jm-macros.m4: Update.
27206         * m4/prereq.m4 (jm_PREREQ): Update.
27207         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
27208         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
27209         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
27210         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
27211         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
27212         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
27213         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
27214         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
27215         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
27216         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
27217         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
27218         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
27219         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
27220         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
27221         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
27222         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
27223         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
27224         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
27225         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
27226
27227 2002-12-24  Bruno Haible  <bruno@clisp.org>
27228
27229         * MODULES.txt: Update according to m4/ changes.
27230
27231         Module gettext.
27232         * config.rpath: New file, from gettext-0.11.5.
27233
27234         * modules/*: New module descriptions.
27235         * gnulib-tool: New file.
27236         * MODULES.html.sh: New file.
27237
27238 2002-12-21  Karl Berry  <karl@gnu.org>
27239
27240         * doc/fdl.texi: update to version 1.2.
27241
27242 2002-12-19  Karl Berry  <karl@gnu.org>
27243
27244         * config/config.guess: update from prep.
27245
27246 2002-12-18  Bruno Haible  <bruno@clisp.org>
27247
27248         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
27249         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
27250
27251 2002-12-17  Bruno Haible  <bruno@clisp.org>
27252
27253         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
27254         stdlib.h, string.h.
27255
27256 2002-12-17  Bruno Haible  <bruno@clisp.org>
27257
27258         * lib/canon-host.c (strdup): Remove unused declaration.
27259
27260         * lib/fsusage.c: Include full_read.h.
27261         (get_fs_usage): Use full_read instead of safe_read.
27262
27263         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
27264
27265 2002-12-12  Karl Berry  <karl@gnu.org>
27266
27267         * config/config.guess: update from prep.
27268
27269 2002-12-11  Bruno Haible  <bruno@clisp.org>
27270
27271         * m4/setenv.m4: New file, from gettext-0.11.5.
27272
27273 2002-12-11  Bruno Haible  <bruno@clisp.org>
27274
27275         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
27276         not unsetenv().
27277         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
27278         modifications:
27279
27280         2002-12-11  Bruno Haible  <bruno@clisp.org>
27281
27282                 * setenv.c (alloca): Fall back to malloc.
27283                 (freea): New macro.
27284                 (setenv): Use freea() to free memory allocated with alloca().
27285
27286         2002-11-13  Bruno Haible  <bruno@clisp.org>
27287
27288                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
27289                 function declarations.
27290                 * unsetenv.c (unsetenv): Likewise.
27291
27292         2002-03-04  Bruno Haible  <bruno@clisp.org>
27293
27294                 Portability to AIX 4.3.3.
27295                 * unsetenv.c: New file, extracted from setenv.c.
27296                 * setenv.c: Move the unsetenv() function to unsetenv.c.
27297
27298         2001-12-20  Bruno Haible  <bruno@clisp.org>
27299
27300                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
27301                 use malloc instead. For SunOS 4.
27302
27303         2001-12-11  Bruno Haible  <bruno@clisp.org>
27304
27305                 * setenv.c: Declare alloca.
27306                 (compar_fn_t): New typedef.
27307                 (KNOWN_VALUE, STORE_VALUE): Use it.
27308
27309         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
27310         setenv.h.
27311
27312 2002-12-10  Paul Eggert  <eggert@twinsun.com>
27313
27314         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
27315         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
27316         Choose values that are less likely to collide with system fnmatch
27317         options.
27318         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
27319         defined (e.g., a pure POSIX system).
27320         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
27321         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
27322
27323 2002-12-06  Paul Eggert  <eggert@twinsun.com>
27324
27325         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
27326         a pain in practice to deal with generated m4 files.  This change
27327         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
27328
27329         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
27330         and jm-glibc-io.m4, as they are no longer a special case.
27331         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
27332         kludge and the auto-generation stuff.  Check only whether the
27333         functions are declared, not whether they exist, since older hosts
27334         that don't declare the functions can't use the optimization anyway.
27335
27336 2002-12-06  Jim Meyering  <jim@meyering.net>
27337
27338         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
27339
27340         Merge in changes from libc's misc/error.c, in preparation
27341         for the merge of gnulib's changes back into libc.
27342
27343         * lib/error.c (_): Define only if not already defined.
27344         Move definition to follow all #include directives.
27345         Include unlocked-io.h only if !_LIBC.
27346         [_LIBC]: Include <libio/libioP.h>.
27347         [USE_IN_LIBIO]: Include <libio/iolibio.h>
27348         (fflush): Tweak definition to use INTUSE.
27349         (putc): Define.
27350
27351 2002-12-05  Paul Eggert  <eggert@twinsun.com>
27352
27353         * lib/alloca.c [defined emacs]: Include "lisp.h".
27354         (xalloc_die) [defined emacs]: New macro.
27355         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
27356         [! defined emacs]: Include <xalloc.h>.
27357         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
27358         (pointer): Typedef to POINTER_TYPE *.
27359         (malloc): Remove decl; we now always use xmalloc.
27360         (alloca): Use old-style definition, since Emacs needs this.
27361         Check for arithmetic overflow when computing combined size.
27362
27363 2002-12-04  Paul Eggert  <eggert@twinsun.com>
27364
27365         Do not generate unlocked-io.h automatically, since it's easier to
27366         maintain it by hand.
27367
27368         * lib/unlocked-io.h: New file, from GNU diffutils,
27369         but with proper copyright notice and attribution.
27370         * lib/gen-uio: Remove.
27371         * lib/Makefile.am: Add copyright notice.
27372         (libfetish_a_SOURCES): Add unlocked-io.h.
27373         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
27374         (DISTCLEANFILES, io_functions): Remove macros.
27375         (EXTRA_DIST): Remove gen_uio.
27376         (unlocked-io.h): Remove rule.
27377
27378 2002-12-04  Jim Meyering  <jim@meyering.net>
27379
27380         Reflect the fact that stat.c and lstat.c are no longer generated.
27381         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
27382         (DISTCLEANFILES): Likewise.
27383         (EXTRA_DIST): Likewise.
27384         (all_local): Don't depend on stat.c or lstat.c.
27385         (stat.c, lstat.c): Remove rules.
27386         (EXTRA_DIST): Remove xstat.in.
27387
27388         * lib/xstat.in: Remove file.  Contents moved into stat.c.
27389         * lib/stat.c: New file.  Contents mostly from xstat.in.
27390         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
27391         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
27392
27393         * lib/safe-read.c: Rework so that it may serve to define safe_write,
27394         too.
27395         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
27396
27397 2002-12-03  Jim Meyering  <jim@meyering.net>
27398
27399         * lib/safe-read.c, safe-write.c: Change variable names and comments,
27400         but not semantics, to minimize the differences between these two files.
27401         (safe_read): Change comment to mention SAFE_READ_ERROR.
27402
27403         * lib/safe-read.c (IS_EINTR): Define.
27404         (safe_read): Use IS_EINTR in place of in-function cpp directives.
27405
27406 2002-12-02  Jim Meyering  <jim@meyering.net>
27407
27408         * lib/safe-read.c (EINTR): Define.
27409         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
27410         (INT_MAX): Provide fallback.
27411         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
27412
27413         * lib/safe-read.h (SAFE_READ_ERROR): Define.
27414
27415 2002-12-02  Bruno Haible  <bruno@clisp.org>
27416
27417         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
27418         Define, taken from safe-read.c.
27419         (INT_MAX): Provide fallback.
27420         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
27421         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
27422
27423         * lib/safe-read.c (EINTR): Remove definition.
27424         (safe_read): Don't use EINTR if it is absent.
27425
27426 2002-12-01  Jim Meyering  <jim@meyering.net>
27427
27428         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
27429         zero.
27430         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
27431
27432 2002-11-27  Paul Eggert  <eggert@twinsun.com>
27433
27434         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
27435         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
27436         with `if (! (value < limit)) abort ();', for readability.
27437
27438 2002-11-26  Karl Berry  <karl@gnu.org>
27439
27440         * lib/strdup.c: copy from libc again, with jim's ok.
27441         * lib/.cppi-disable: re-add strdup.c
27442
27443 2002-11-25  Karl Berry  <karl@gnu.org>
27444
27445         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
27446         instead of "strtol.c".
27447
27448 2002-11-25  Karl Berry  <karl@gnu.org>
27449
27450         * config/install-sh: update from automake for variable quoting, $0 in
27451         error msgs, etc.
27452
27453         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
27454         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
27455         entry.
27456
27457 2002-11-25  Jim Meyering  <jim@meyering.net>
27458
27459         * lib/mktime.c: Sync from libc, now that it has the latest fix.
27460
27461 2002-11-24  Karl Berry  <karl@gnu.org>
27462
27463         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
27464         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
27465
27466 2002-11-24  Jim Meyering  <jim@meyering.net>
27467
27468         Update from coreutils:
27469
27470         * lib/mktime.c: Merge in changes from libc.
27471
27472         Avoid a link-time failure on some Linux systems.
27473         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
27474         (otherwise).
27475         (__mon_yday): Declare with the STATIC attribute.
27476         (__mktime_internal): Likewise.
27477         Based on a report from Greg Schafer.
27478
27479 2002-11-23  Jim Meyering  <jim@meyering.net>
27480
27481         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
27482         Use `unsigned', not `int', as type of index.
27483
27484         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
27485
27486         * lib/fsusage.c: Remove unneeded parentheses around operands of
27487         `defined'.
27488
27489 2002-11-22  Paul Eggert  <eggert@twinsun.com>
27490
27491         * lib/quotearg.h: Allow multiple inclusion by surrounding with
27492         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
27493         so that we can be included first.
27494         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
27495         * lib/quotearg.c: Include quotearg.h immediately after config.h.
27496         No need to include stddef.h or sys/types.h any more.
27497         Surround local include files with "", not "<>".
27498         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
27499         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
27500         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
27501         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
27502         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
27503         (ISPRINT): Remove; no longer needed now that we assume C89.
27504
27505         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
27506         Preserve errno.
27507
27508         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
27509         quotearg_char): Use SIZE_MAX rather than
27510         (size_t) -1 when we are talking about "infinity".
27511
27512         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
27513
27514 2002-11-22  Paul Eggert  <eggert@twinsun.com>
27515
27516         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
27517         hint that one should use `if (! x) abort ();' rather than `assert
27518         (x);', and anyway it's one less thing to worry about configuring.
27519         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
27520         hash_rehash, hash_insert): Use abort rather than assert.
27521
27522 2002-11-22  Bruno Haible  <bruno@clisp.org>
27523
27524         * lib/safe-read.h: Assume C89. Add comments.
27525         (safe_read): Change return type to size_t.
27526         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
27527         byte counts > SSIZE_MAX correctly.
27528         * lib/safe-write.h: New file.
27529         * lib/safe-write.c: New file.
27530         * lib/full-read.h: New file.
27531         * lib/full-read.c: New file.
27532         * lib/full-write.h: Assume C89. Add comments.
27533         * lib/full-write.c: Include safe-write.h.
27534         (full_write): Rewritten to use safe_write.
27535         Suggested by Jim Meyering and Paul Eggert.
27536
27537 2002-11-21  Jim Meyering  <jim@meyering.net>
27538
27539         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
27540
27541         Merge in changes from the coreutils.
27542
27543         2002-09-25  Paul Eggert  <eggert@twinsun.com>
27544         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
27545         <stdint.h>.
27546         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
27547         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
27548         int.  Work more efficiently if X is the same width as uintmax_t.
27549         Do not compare X to -1, to avoid bogus compiler warning.
27550         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
27551         Don't assume that f_frsize and f_bsize are the same type.
27552
27553         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
27554         warning on FreeBSD.
27555
27556         * lib/makepath.c (make_path): Restore umask *before* creating the final
27557         component.
27558         (make_path): Minor reformatting.
27559
27560         * lib/xmalloc.c: Adjust to work with new autoconf macros,
27561         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
27562         HAVE_MALLOC/HAVE_REALLOC.
27563
27564         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
27565         dummy ones.  At least on GNU/Linux systems, `auto' means something
27566         else.
27567         From Michael Stone.
27568
27569 2002-11-21  Bruno Haible  <bruno@clisp.org>
27570
27571         Remove case insensitive option matching.
27572         * lib/argmatch.h (argcasematch): Remove declaration.
27573         (ARGCASEMATCH): Remove macro.
27574         (__xargmatch_internal): Remove case_sensitive argument.
27575         (XARGMATCH): Update.
27576         (XARGCASEMATCH): Remove macro.
27577         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
27578         case_sensitive argument.
27579         (argcasematch): Remove function.
27580         (__xargmatch_internal): Remove case_sensitive argument.
27581         (main): Use XARGMATCH instead of XARGCASEMATCH.
27582
27583         * lib/xmalloc.c: Change compile-time error message. Add comment about
27584         required autoconf version.
27585
27586 2002-11-20  Paul Eggert  <eggert@twinsun.com>
27587
27588         Merge argmatch cleanups from Bison.  Assume C89.
27589
27590         * lib/argmatch.c: Include config.h here, not in argmatch.h.
27591         Include stdlib.h, for EXIT_FAILURE.
27592         Always include <string.h>, since we assume C89.
27593         (EXIT_FAILURE): Remove pre-C89 bug workaround.
27594         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
27595         Include <stddef.h> instead, since it's all we need for size_t.
27596         (PARAMS): Remove.  All uses removed.
27597         (ARRAY_CARDINALITY): Do not bother to #undef.
27598         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
27599         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
27600         Remove unnecessary parentheses.
27601         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
27602         Insert necessary parentheses.
27603         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
27604         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
27605
27606 2002-11-19  Bruno Haible  <bruno@clisp.org>
27607
27608         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
27609         * lib/mbswidth.h: Include <stddef.h>, for size_t.
27610
27611         * lib/mbswidth.h (PARAMS): Remove macro.
27612         (mbswidth, mbsnwidth): Use ANSI C function declarations.
27613         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
27614
27615         * lib/gcd.h (PARAMS): Remove macro.
27616         (gcd): Use ANSI C function declarations.
27617         * lib/gcd.c (gcd): Likewise.
27618
27619 2002-11-15  Bruno Haible  <bruno@clisp.org>
27620
27621         * lib/strcspn.c: Include <stddef.h>.
27622         (strcspn): Use ANSI C function declaration. Change return type to
27623         size_t. Use NULL.
27624         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
27625         (strpbrk): Use NULL.
27626         * lib/strpbrk.h (PARAMS): Remove macro.
27627         (strpbrk): Use ANSI C function declaration.
27628         * lib/strstr.c: Don't include <sys/types.h>.
27629         * lib/strstr.h (PARAMS): Remove macro.
27630         (strstr): Use ANSI C function declarations.
27631
27632 2002-11-14  Karl Berry  <karl@gnu.org>
27633
27634         * config/mkinstalldirs: `do' on separate line, instead of
27635         `for var; do'.
27636
27637 2002-11-06  Bruno Haible  <bruno@clisp.org>
27638
27639         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
27640         * lib/gcd.c (gcd): Likewise.
27641
27642 2002-11-05  Bruno Haible  <bruno@clisp.org>
27643
27644         * lib/gcd.h: New file, from gettext-0.11.5.
27645         * lib/gcd.c: New file, from gettext-0.11.5.
27646
27647 2002-11-05  Bruno Haible  <bruno@clisp.org>
27648
27649         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27650         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27651         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27652         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
27653
27654         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
27655         <libintl.h>.
27656         * lib/makepath.c: Include gettext.h instead of <locale.h> and
27657         <libintl.h>.
27658
27659         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
27660         * lib/human.c: Include gettext.h instead of <libintl.h>.
27661         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
27662         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
27663         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
27664         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
27665         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
27666         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
27667         (textdomain): Remove definition.
27668         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
27669
27670         * lib/long-options.c: Remove include of <libintl.h> and definition of
27671         _.
27672         * lib/same.c: Remove include of <libintl.h> and definition of _.
27673
27674 2002-11-04  Owen Taylor  <otaylor@redhat.com>
27675
27676         * lib/config.charset: A few additions for Solaris.
27677
27678 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
27679
27680         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
27681         * lib/localcharset.c (locale_charset): Declare as extern "C".
27682
27683 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
27684
27685         * lib/config.charset: msdos in uk_UA uses CP1125.
27686
27687 2002-11-04  Bruno Haible  <bruno@clisp.org>
27688
27689         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
27690         * lib/strcase.h: New file, from GNU gettext-0.11.5.
27691         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
27692         * lib/strstr.h: New file, from GNU gettext-0.11.5.
27693         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
27694
27695 2002-11-04  Bruno Haible  <bruno@clisp.org>
27696
27697         * lib/localcharset.c (locale_charset): Don't return an empty string.
27698
27699 2002-11-04  Bruno Haible  <bruno@clisp.org>
27700
27701         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
27702         aliases.
27703
27704 2002-11-04  Bruno Haible  <bruno@clisp.org>
27705
27706         * lib/config.charset: Update for newest glibc. Add canonical names
27707         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
27708
27709 2002-11-04  Bruno Haible  <bruno@clisp.org>
27710
27711         * lib/config.charset: Add support for NetBSD.
27712
27713 2002-11-04  Bruno Haible  <bruno@clisp.org>
27714
27715         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
27716
27717 2002-11-01  Bruno Haible  <bruno@clisp.org>
27718
27719         * configure.in: Add AC_CONFIG_AUX_DIR call.
27720         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
27721         test/Makefile.
27722         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
27723
27724 2002-09-28  Karl Berry  <karl@gnu.org>
27725
27726         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
27727         installed automake until the next release, since changes have been
27728         made.
27729
27730 2002-09-25  Karl Berry  <karl@gnu.org>
27731
27732         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
27733         * lib/getopt*: copy from libc/posix.
27734         * lib/gettext.h: copy from gettext.
27735         * lib/.cppi-disable: add strdup.c, gettext.h.
27736
27737 2002-09-25  Karl Berry  <karl@gnu.org>
27738
27739         * config/srclist.txt: enable gettext.h check.
27740         * config/config.{guess,sub}: update from prep.
27741         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
27742                 from automake 1.6.3.
27743         See srclist*.
27744
27745 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
27746
27747         * regex.c (PATFETCH): Remove the translating fetch.
27748         (PATFETCH_RAW): Rename to PATFETCH.
27749         (set_image_of_range): New fun.
27750         (SET_RANGE_TABLE_WORK_AREA): Use it.
27751         (regex_compile): Don't translate the pattern chars so eagerly.
27752         Only do it when inserting an `exactn' bytecode or when handling
27753         a char-range.
27754         (mutually_exclusive_p): Avoid empty statement.
27755
27756 2002-07-06  Jim Meyering  <meyering@lucent.com>
27757
27758         * m4/README: Don't mention Makefile.am.in.
27759         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
27760
27761 2002-07-01  Jim Meyering  <meyering@lucent.com>
27762
27763         * lib/c-stack.c: Include sys/time.h.
27764         From Volker Borchert.
27765
27766 2002-06-26  Paul Eggert  <eggert@twinsun.com>
27767
27768         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
27769
27770 2002-06-26  Paul Eggert  <eggert@twinsun.com>
27771
27772         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
27773         New macro.  Use it uniformly instead of
27774         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
27775         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
27776         reported by Vin Shelton.
27777
27778 2002-06-22  Paul Eggert  <eggert@twinsun.com>
27779
27780         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
27781         Do not assume SA_SIGINFO behavior.
27782         Bug reported by Jim Meyering on NetBSD 1.5.2.
27783
27784 2002-06-22  Jim Meyering  <meyering@lucent.com>
27785
27786         * m4/c-stack.m4: New file, from diffutils-2.8.2.
27787         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
27788
27789         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
27790         now that configure.ac uses AC_GNU_SOURCE.
27791         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
27792         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
27793
27794         Update to latest tools.  Suggestions from Paul Eggert.
27795         * m4/stdbool.m4: New file, from diffutils-2.8.2.
27796         * m4/gnu-source.m4: Update from diffutils-2.8.2.
27797         * m4/fnmatch.m4: Likewise.
27798         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
27799         to AC_HEADER_STDBOOL
27800
27801 2002-06-22  Jim Meyering  <meyering@lucent.com>
27802
27803         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
27804         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
27805
27806 2002-06-22  Jim Meyering  <meyering@lucent.com>
27807
27808         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
27809
27810         * lib/exitfail.c, exitfail.h: Likewise.
27811         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
27812
27813         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
27814         of fnmatch.h.
27815         (EXTRA_DIST): Add fnmatch_loop.c.
27816         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
27817
27818         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
27819         * lib/fnmatch.c: Update from diffutils-2.8.2.
27820         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
27821         * lib/fnmatch.h: Remove file.
27822
27823 2002-06-21  Jim Meyering  <meyering@lucent.com>
27824
27825         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
27826         * m4/mbrtowc.m4: Likewise.
27827
27828         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
27829         * m4/mbswidth.m4: Reflect name change:
27830         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
27831         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
27832
27833         * m4/lib-link.m4: Update from gettext-0.11.2.
27834         * m4/gettext.m4: Likewise.
27835
27836         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
27837         From Alfred M. Szmidt.
27838
27839 2002-06-18  Paul Eggert  <eggert@twinsun.com>
27840
27841         * lib/file-type.h: Report an error if neither S_ISREG nor
27842         S_IFREG is defined, instead of using a test specific to glibc
27843         2.2.  This should be safe, since POSIX requires S_ISREG and
27844         Unix Version 7 had S_IFREG.  We don't need to check for
27845         <sys/types.h> since we don't use any symbols that it defines.
27846
27847 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
27848
27849         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
27850         $@-t, so that each temporary file name is unique and valid in the first
27851         8 characters, for operation under DOS.
27852
27853 2002-06-15  Paul Eggert  <eggert@twinsun.com>
27854
27855         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
27856
27857 2002-06-15  Jim Meyering  <meyering@lucent.com>
27858
27859         Work even with DJGPP 2.03, which lacks support for symlinks.
27860         From Richard Dawe.
27861         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
27862         is defined.
27863         * lib/lchown.c (S_ISLNK): Likewise.
27864
27865 2002-06-15  Jim Meyering  <meyering@lucent.com>
27866
27867         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
27868         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
27869         have been included before this file.
27870
27871 2002-06-14  Jim Meyering  <meyering@lucent.com>
27872
27873         * lib/file-type.h: Use the version from diffutils-2.8.2.
27874         * lib/file-type.c: Likewise.
27875
27876 2002-06-07  Jim Meyering  <meyering@lucent.com>
27877
27878         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
27879         They're needed at least for NetBSD 1.5.2.
27880         ($statxfs_includes): Include those same headers.
27881         ($statxfs_includes): Include sys/vfs.h if available.
27882         ($statxfs_includes): Likewise for sys/statvfs.h.
27883         Check for the following members in both structs statfs and statvfs:
27884         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
27885
27886 2002-06-01  Jim Meyering  <meyering@lucent.com>
27887
27888         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
27889         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
27890
27891 2002-05-28  Jim Meyering  <meyering@lucent.com>
27892
27893         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
27894         Reported by Volker Borchert.
27895
27896 2002-05-27  Jim Meyering  <meyering@lucent.com>
27897
27898         Fix a problem seen only on nonconforming systems whereby ls.c's
27899         use of localtime, and then of gettimeofday would cause trouble:
27900         the localtime call used to initialize rpl_gettimeofday's save
27901         mechanism would clobber ls's current local time information so
27902         that in any long listing the first file would always be listed
27903         with date 1970-01-01.  Analysis by Volker Borchert.
27904
27905         * lib/gettimeofday.c (localtime): Undefine.
27906         (rpl_localtime): New function.
27907
27908 2002-05-27  Jim Meyering  <meyering@lucent.com>
27909
27910         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
27911         localtime.
27912
27913         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
27914         use the replacement function; it wouldn't resolve at link time.
27915         Reported by Volker Borchert.
27916
27917 2002-05-22  Jim Meyering  <meyering@lucent.com>
27918
27919         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
27920         file-type.h.
27921         * lib/file-type.h: New file.
27922         * lib/file-type.c (file_type): New file/function.  Extracted from
27923         diffutils.
27924
27925 2002-04-30  Jim Meyering  <meyering@lucent.com>
27926
27927         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
27928
27929 2002-04-29  Paul Eggert  <eggert@twinsun.com>
27930
27931         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
27932
27933 2002-04-29  Paul Eggert  <eggert@twinsun.com>
27934
27935         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
27936         Do not check for alloca.h (no longer used) or stdbool.h (was never
27937         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
27938
27939 2002-04-29  Paul Eggert  <eggert@twinsun.com>
27940
27941         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
27942
27943 2002-04-29  Jim Meyering  <meyering@lucent.com>
27944
27945         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
27946         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
27947         Use AC_FUNC_STRNLEN here instead.
27948
27949         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
27950         With autoconf-2.53a, it's part of AC_PROG_CC.
27951
27952 2002-04-28  Paul Eggert  <eggert@twinsun.com>
27953
27954         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
27955         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
27956
27957 2002-04-28  Paul Eggert  <eggert@twinsun.com>
27958
27959         * lib/sig2str.h, lib/sig2str.c: New files.
27960         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
27961
27962 2002-04-28  Paul Eggert  <eggert@twinsun.com>
27963
27964         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
27965         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
27966         of 127, since 64 is the largest conceivable number for ancient
27967         nonstandard hosts.
27968         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
27969
27970 2002-04-28  Jim Meyering  <meyering@lucent.com>
27971
27972         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
27973
27974 2002-04-24  Jim Meyering  <meyering@lucent.com>
27975
27976         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
27977         (jm_PREREQ): Use it.
27978
27979         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
27980         mach/mach.h fcntl.h.
27981         Check for this function: setlocale.
27982
27983 2002-04-24  Jim Meyering  <meyering@lucent.com>
27984
27985         * lib/gettext.h: New file, from Gettext.
27986         * lib/Makefile.am (INCLUDES): Remove -I../intl.
27987         (libfetish_a_SOURCES): Add gettext.h.
27988
27989 2002-04-16  Jim Meyering  <meyering@lucent.com>
27990
27991         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
27992         ut_pid, ut_id, ut_exit.
27993
27994 2002-04-16  Jim Meyering  <meyering@lucent.com>
27995
27996         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
27997         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
27998         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
27999
28000 2002-04-12  Jim Meyering  <meyering@lucent.com>
28001
28002         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
28003         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
28004         existence of the getmntinfo function.  Needed for Darwin 5.3.
28005
28006         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
28007         This is necessary at least on Darwin 5.3.
28008
28009         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
28010         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
28011         strnlen.o in the library, and that makes some versions of ranlib
28012         object.
28013
28014 2002-04-12  Jim Meyering  <meyering@lucent.com>
28015
28016         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
28017
28018 2002-04-09  Jim Meyering  <meyering@lucent.com>
28019
28020         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
28021         to be more precise.  Rather than saying we're checking whether the
28022         function `works', say what we're testing.
28023         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
28024         Reported by Bruno Haible.
28025
28026 2002-03-10  Jim Meyering  <meyering@lucent.com>
28027
28028         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
28029         Suggestion from Santiago Vila.
28030
28031 2002-03-08  Jim Meyering  <meyering@lucent.com>
28032
28033         * lib/rename.c: Mention that this wrapper is needed also on
28034         mips-dec-ultrix4.4 systems.
28035
28036 2002-03-02  Jim Meyering  <meyering@lucent.com>
28037
28038         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
28039         not HAVE_CLOCK_SETTIME.
28040
28041 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28042
28043         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
28044         Check for clock_settime.
28045
28046 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28047
28048         * lib/nanosleep.h: Rename to....
28049         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
28050
28051         * lib/gettime.c: New file.
28052         * lib/settime.c: New file.
28053         * lib/stime.c: Remove.
28054
28055         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
28056         timespec.h.  Remove nanosleep.h.
28057
28058 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28059
28060         * m4/acl.m4: New file.
28061         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
28062         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
28063
28064 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28065
28066         * lib/acl.c, lib/acl.h: New files.
28067         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
28068
28069 2002-02-24  Jim Meyering  <meyering@lucent.com>
28070
28071         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
28072         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
28073         cause trouble.  Reported by Nelson Beebe.
28074
28075 2002-02-23  Paul Eggert  <eggert@twinsun.com>
28076
28077         * lib/path-concat.c (xpath_concat): Reorder code to pacify
28078         compilers that don't know that xalloc_die never returns.
28079
28080 2002-02-20  Jim Meyering  <meyering@lucent.com>
28081
28082         * lib/getdate.c: Regenerate using bison-1.33.
28083
28084 2002-02-17  Jim Meyering  <meyering@lucent.com>
28085
28086         * config/config.guess (main): Don't use `head -1'; it's no longer
28087         portable. Use `sed 1q' instead.
28088
28089 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
28090
28091         * m4/codeset.m4: Upgrade to gettext-0.11.
28092         * m4/gettext.m4: Upgrade to gettext-0.11.
28093         * m4/glibc21.m4: Upgrade to gettext-0.11.
28094         * m4/iconv.m4: Upgrade to gettext-0.11.
28095         * m4/isc-posix.m4: Upgrade to gettext-0.11.
28096         * m4/lcmessage.m4: Upgrade to gettext-0.11.
28097         * m4/lib-ld.m4: New file, from gettext-0.11.
28098         * m4/lib-link.m4: New file, from gettext-0.11.
28099         * m4/lib-prefix.m4: New file, from gettext-0.11.
28100         * m4/progtest.m4: Upgrade to gettext-0.11.
28101
28102 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28103
28104         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
28105         (jm_PREREQ): Use it.
28106
28107 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28108
28109         * lib/posixver.c, lib/posixver.h: New files.
28110         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28111
28112 2002-02-02  Paul Eggert  <eggert@twinsun.com>
28113             Bruno Haible  <bruno@clisp.org>
28114
28115         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
28116         (fwrite_success_callback): New declaration.
28117         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
28118         print_unicode_char. Call failure callback instead of error.
28119         (fwrite_success_callback): New function.
28120         (exit_failure_callback): New function.
28121         (fallback_failure_callback): New function.
28122         (print_unicode_char): Call unicode_to_mb.
28123
28124 2002-01-26  Jim Meyering  <meyering@lucent.com>
28125
28126         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
28127         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
28128
28129 2002-01-26  Jim Meyering  <meyering@lucent.com>
28130
28131         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
28132
28133 2002-01-22  Paul Eggert  <eggert@twinsun.com>
28134
28135         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
28136
28137 2002-01-22  Jim Meyering  <meyering@lucent.com>
28138
28139         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
28140         Otherwise, some versions of automake would omit the rule that makes
28141         Makefile from Makefile.in.
28142
28143 2002-01-21  Paul Eggert  <eggert@twinsun.com>
28144
28145         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
28146         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28147         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
28148         (memcoll): Set errno to zero if there is no error.
28149
28150         * lib/quotearg.c (quotearg_buffer_restyled):
28151         Fix bug with quoting buffers containing NUL when backslashing escapes.
28152         This bug was exposed by the other changes in this patch.
28153         (quotearg_n_options): New arg ARGSIZE.
28154         All callers changed.
28155         (quoting_options_from_style): New function.
28156         (quotearg_n_style): Use it.
28157         (quotearg_n_style_mem): New function.
28158
28159         * lib/quotearg.h (quotearg_n_style_mem): New function.
28160
28161 2002-01-19  Jim Meyering  <meyering@lucent.com>
28162
28163         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
28164         Remove useless quotes: DF_PROG="df".
28165         * m4/strnlen.m4: New file.
28166
28167 2002-01-16  Paul Eggert  <eggert@twinsun.com>
28168
28169         * lib/backupfile.c (ISDIGIT): Comment fix.
28170         * lib/getdate.y (ISDIGIT): Likewise.
28171         * lib/posixtm.c (ISDIGIT, year): Likewise.
28172         * lib/strverscmp.c (ISDIGIT): Likewise.
28173         * lib/userspec.c (ISDIGIT): Likewise.
28174
28175 2002-01-16  Jim Meyering  <meyering@lucent.com>
28176
28177         * lib/getdate.y: Add three semicolons, each just before a closing
28178         brace. Bison (as of version 1.31) no longer papers over that mistake.
28179
28180 2002-01-05  Jim Meyering  <meyering@lucent.com>
28181
28182         * lib/version-etc.c (version_etc_copyright): Update copyright year.
28183
28184 2001-12-19  Paul Eggert  <eggert@twinsun.com>
28185
28186         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
28187         not silently exit merely because the output buffer happens to
28188         have nothing pending.
28189
28190 2001-12-18  Paul Eggert  <eggert@twinsun.com>
28191
28192         See the big note in ../ChangeLog.
28193         * lib/human.c (suffixes): Prefer K to k for 1024.
28194         (generate_suffix_backwards): New function.
28195         (human_readable_inexact): Use it.
28196         * lib/xstrtol.c (__xstrtol): If there is no number but there
28197         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
28198         Accept 'K' as well as 'k'.
28199
28200 2001-12-15  Jim Meyering  <meyering@lucent.com>
28201
28202         * lib/regex.h (__restrict_arr): Update from libc.
28203
28204         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
28205         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
28206         (STREQ): Define.
28207
28208 2001-12-14  Jim Meyering  <meyering@lucent.com>
28209
28210         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
28211         Suggestion from Bruno Haible.
28212
28213 2001-12-10  Jim Meyering  <meyering@lucent.com>
28214
28215         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
28216         xrealloc, Instead, include "xalloc.h".
28217         (initbuffer): Don't cast xmalloc return value to char*.
28218         (readline): Reword comment.
28219         Don't cast xrealloc return value to char*
28220         Return NULL, not 0.
28221
28222 2001-12-09  Jim Meyering  <meyering@lucent.com>
28223
28224         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
28225         about `signed and unsigned type in conditional expression'.
28226         * lib/posixtm.c (posix_time_parse): Likewise.
28227
28228         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
28229
28230         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
28231         to avoid a pedantic warning.
28232
28233         * lib/getstr.c: Don't include assert.h.
28234         (getstr): Remove warning-evoking assertions.
28235         Return -1 if offset parameter is out of bounds.
28236         Change the type of a local from int to size_t.
28237
28238         * lib/strftime.c (my_strftime_localtime_r): Include this function
28239         definition in the `#if ! HAVE_TM_GMTOFF' block.
28240
28241         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
28242         Include xalloc.h instead.
28243
28244 2001-12-02  Jim Meyering  <meyering@lucent.com>
28245
28246         * lib/tempname.c: Don't declare getenv, thus reverting the change of
28247         2001-11-18.  It's no longer necessary, now that stdlib.h is always
28248         included.
28249
28250         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
28251         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
28252
28253 2001-11-30  Akim Demaille  <akim@epita.fr>
28254
28255         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
28256         before being defined.
28257
28258 2001-11-27  Paul Eggert  <eggert@twinsun.com>
28259
28260         * lib/quotearg.h (quotearg_n, quotearg_n_style):
28261         First arg is int, not unsigned.
28262         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
28263         (SIZE_MAX, UINT_MAX): New macros.
28264         (quotearg_n_options): Abort if N is negative.
28265         Avoid overflow check on hosts where size_t is 64 bits and int
28266         is 32 bits, as overflow is impossible there.
28267         Fix off-by-one typo that caused unnecessary reallocation.
28268
28269 2001-11-27  Jim Meyering  <meyering@lucent.com>
28270
28271         * lib/tempname.c: Merge with version from libc.
28272         * lib/regex.c: Likewise.
28273
28274         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
28275         systems for which STDC_HEADERS is 0, it was not included, resulting in
28276         a warning about an integer-to-pointer conversion problem with getenv.
28277         Reported by Volker Borchert.
28278
28279 2001-11-26  Jim Meyering  <meyering@lucent.com>
28280
28281         * lib/gtod.h: Remove file.
28282         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
28283         * lib/gettimeofday.c: Don't include gtod.h.
28284         (GTOD_init): Remove function.
28285         (rpl_gettimeofday): Do its job here instead, rather than aborting.
28286         Suggestion from Volker Borchert.
28287
28288 2001-11-23  Jim Meyering  <meyering@lucent.com>
28289
28290         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
28291         it.
28292         * lib/hash.c (struct hash_table): Define it here instead.
28293
28294 2001-11-22  Jim Meyering  <meyering@lucent.com>
28295
28296         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
28297
28298 2001-11-20  Jim Meyering  <meyering@lucent.com>
28299
28300         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
28301         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
28302
28303 2001-11-19  Jim Meyering  <meyering@lucent.com>
28304
28305         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
28306         directory.  Use "conftestXXXXXX" as the template.
28307         Suggestion from Paul Eggert.
28308
28309         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
28310         immediately, so the test doesn't mistakenly hit the max-open-files
28311         limit.
28312
28313 2001-11-18  Paul Eggert  <eggert@twinsun.com>
28314
28315         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
28316         (TEMPORARIES): New macro.
28317         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
28318         removes an artificial limitation (e.g. HP-UX 10.20, where
28319         TMP_MAX is 17576).
28320
28321 2001-11-18  Jim Meyering  <meyering@lucent.com>
28322
28323         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
28324
28325 2001-11-18  Jim Meyering  <meyering@lucent.com>
28326
28327         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
28328         on SunOS 4.
28329
28330         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
28331         files will be created before anything else.
28332
28333 2001-11-17  Paul Eggert  <eggert@twinsun.com>
28334
28335         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
28336         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
28337
28338 2001-11-17  Jim Meyering  <meyering@lucent.com>
28339
28340         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
28341         Prompted by a report from Bob Proulx.
28342
28343         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
28344         Instead, require UTILS_FUNC_MKSTEMP.
28345
28346 2001-11-17  Jim Meyering  <meyering@lucent.com>
28347
28348         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
28349         Now, that's done as part of AC_FUNC_STRTOD.
28350
28351 2001-11-17  Jim Meyering  <meyering@lucent.com>
28352
28353         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
28354         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
28355         rather than group writable.  Patch by Juan F. Codagnone.
28356
28357         * lib/readtokens.c: Remove explicit declarations of xmalloc and
28358         xrealloc, Instead, include "xalloc.h".
28359
28360         * lib/mountlist.c: Include unlocked-io.h after all system headers.
28361         Remove explicit declarations of xmalloc, xrealloc,
28362         and xstrdup.  Instead, include "xalloc.h".
28363
28364         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
28365         unlocked-io.h.
28366         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
28367         Likewise.
28368         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
28369
28370         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
28371         Reported by Padraig Brady.
28372
28373         * lib/mkstemp.c: #undef mkstemp.
28374         Include config.h.
28375         (rpl_mkstemp): Rename from mkstemp.
28376         Protoize.
28377
28378 2001-11-16  Jim Meyering  <meyering@lucent.com>
28379
28380         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
28381         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
28382         determine the amount of total physical memory, use pstat_getstatic.
28383         HPUX-11 doesn't define _SC_PHYS_PAGES.
28384         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
28385         If sysconf couldn't be used to determine the amount of available
28386         physical memory, use both pstat_getstatic and pstat_getdynamic.
28387         Based on a patch from Bob Proulx.
28388
28389 2001-11-10  Jim Meyering  <meyering@lucent.com>
28390
28391         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
28392         (jm_PREREQ): Use it.
28393
28394 2001-11-09  Jim Meyering  <meyering@lucent.com>
28395
28396         * m4/jm-macros.m4: Require autoconf-2.52f.
28397         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
28398         Use these AC_-prefixed names, not the AM_-prefixed ones.
28399
28400         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
28401
28402 2001-11-05  Jim Meyering  <meyering@lucent.com>
28403
28404         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
28405
28406 2001-11-04  Jim Meyering  <meyering@lucent.com>
28407
28408         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
28409         $DEFS.
28410
28411 2001-11-03  Jim Meyering  <meyering@lucent.com>
28412
28413         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
28414         of AC_DEFUN.
28415
28416         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
28417         know the name of the variable in the macro definition.
28418
28419 2001-11-03  Jim Meyering  <meyering@lucent.com>
28420
28421         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
28422         in argmatch_to_argument call.
28423
28424         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
28425         argument.
28426
28427         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
28428         e.g., a fault due to an attempt to free a NULL pointer.
28429
28430 2001-11-01  Jim Meyering  <meyering@lucent.com>
28431
28432         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
28433         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
28434
28435 2001-11-01  Jim Meyering  <meyering@lucent.com>
28436
28437         * lib/dirfd.c, lib/dirfd.h: New files.
28438         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
28439
28440         * lib/hash.c (hash_print) [TESTING]: Clean up.
28441
28442 2001-10-22  Paul Eggert  <eggert@twinsun.com>
28443
28444         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
28445         to avoid a warning if -Wall.
28446
28447 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
28448
28449         * README: New file
28450         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
28451         (per RMS's instructions, this is now the canonical source)
28452         * lgpl/, gpl/: New directories.
28453
28454 2001-10-21  Paul Eggert  <eggert@twinsun.com>
28455
28456         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
28457
28458 2001-10-21  Jim Meyering  <meyering@lucent.com>
28459
28460         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
28461         this code would end up calling gettext even in packages built
28462         with --disable-nls.
28463         * lib/getopt.c (_): Likewise.
28464         * lib/regex.c (_): Likewise.
28465
28466 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28467
28468         * m4/error.m4 (jm_PREREQ_ERROR):
28469         Do not invoke AC_CHECK_FUNCS with strerror_r, as
28470         AC_FUNC_STRERROR_R does that.
28471         Check for strerror declaration.
28472
28473         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
28474         are supposed to have them these days.
28475         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
28476         Merge changes from latest Autoconf CVS.
28477         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
28478         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
28479         POSIX decided to standardize on the int flavor of strerror_r.
28480
28481 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28482
28483         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
28484         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
28485         Use strerror_r that is only a macro, even if it is not a function.
28486         (strerror): Check for HAVE_DECL_STRERROR before declaring.
28487         (private_strerror): Use prototypes, not old-style function definition.
28488         (print_errno_message): New function.
28489         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
28490         char*-flavored one.
28491         (error_tail, error, error_at_line): Use it.
28492
28493 2001-10-11  Jim Meyering  <meyering@lucent.com>
28494
28495         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
28496         and quote_n (1, ... to avoid clobbering a buffer.
28497
28498 2001-10-05  Jim Meyering  <meyering@lucent.com>
28499
28500         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
28501         hash-pjw.h.
28502         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
28503         * lib/hash-pjw.h: New file.
28504
28505 2001-09-30  Jim Meyering  <meyering@lucent.com>
28506
28507         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
28508         `struct fsstat' has the `f_fstypename' member.
28509         Use that to define FS_TYPE, which is now used to make
28510         the getfsstat link test tighter.
28511
28512 2001-09-30  Jim Meyering  <meyering@lucent.com>
28513
28514         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
28515         Include <sys/ucred.h>, for Apple Darwin.
28516         Include sys/mount.h and sys/fs_types.h only if available.
28517         (FS_TYPE): Define.
28518         (read_filesystem_list): Use FS_TYPE.
28519
28520 2001-09-29  Paul Eggert  <eggert@twinsun.com>
28521
28522         * lib/exclude.c (excluded_filename): 0 -> false, since it's
28523         a boolean context.
28524
28525 2001-09-29  Jim Meyering  <meyering@lucent.com>
28526
28527         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
28528         [one-argument getmntent function]): Include stdio.h before mntent.h.
28529         SunOS 4.1.x needs it for the declaration of `FILE'.
28530         Patch by Volker Borchert.
28531
28532         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
28533         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
28534         sys/fs_types.h, and make the link-test for getfsstat guard #include
28535         directives with appropriate #if HAVE_*_H tests so that we can
28536         detect getfsstat on Apple Darwin1.3.7 systems.
28537         Reported by Nelson Beebe.
28538         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
28539
28540 2001-09-28  Paul Eggert  <eggert@twinsun.com>
28541
28542         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
28543         #defines strtoimax.  Also treat the other strto* functions
28544         like strtoimax.
28545
28546         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
28547         Check for strtoul and strtoumax,
28548         as those declarations are made even in the signed case.
28549         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
28550         Likewise, for strtol and strtoimax.
28551
28552 2001-09-28  Paul Eggert  <eggert@twinsun.com>
28553
28554         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
28555         #defines strtoimax.  Also treat the other strto* functions
28556         like strtoimax.
28557
28558         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
28559         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
28560         (strtoimax, strtoumax): Do not declare if already defined as a macro.
28561
28562 2001-09-26  Jim Meyering  <meyering@lucent.com>
28563
28564         Most macros in unlocked-io.h had the wrong number of arguments.
28565         * lib/gen-uio: New script.
28566         (USE_UNLOCKED_IO): Define to 1 if not already defined.
28567         * lib/unlocked-io.hin: Remove file.
28568         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
28569         rather than trying to embed it here.
28570         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
28571         Reported by Padraig Brady.
28572
28573 2001-09-25  Volker Borchert  <bt@teknon.de>
28574
28575         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
28576         `result'.
28577
28578 2001-09-24  Jim Meyering  <meyering@lucent.com>
28579
28580         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
28581
28582 2001-09-23  Jim Meyering  <meyering@lucent.com>
28583
28584         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
28585         instead of the mere test for existence of mntent.h.  The latter
28586         would get a false-positive on AIX 3.4 systems.
28587         In the outer getmntent if-block, don't die if neither of the getmntent
28588         tests succeeds.  Instead, just fall through and continue with the
28589         remaining tests.
28590
28591 2001-09-23  Jim Meyering  <meyering@lucent.com>
28592
28593         * lib/mountlist.c: Remove useless parentheses in #if directives.
28594         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
28595         the deprecated MOUNTED symbol is no longer defined in mntent.h.
28596
28597 2001-09-22  Jim Meyering  <meyering@lucent.com>
28598
28599         * m4/gettext.m4: New file.  From gettext.
28600         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
28601         * m4/progtest.m4: Likewise
28602         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
28603         * m4/glibc21.m4: Likewise.
28604
28605         * m4/libintl.m4: Remove.  No longer used.
28606
28607 2001-09-22  Jim Meyering  <meyering@lucent.com>
28608
28609         * lib/localcharset.c: Update from latest gettext.
28610         * lib/config.charset: Likewise.
28611
28612 2001-09-20  Jim Meyering  <meyering@lucent.com>
28613
28614         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
28615         strtoimax.
28616         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
28617         strtoumax.
28618
28619 2001-09-20  Jim Meyering  <meyering@lucent.com>
28620
28621         * lib/xstrtol.c (strtoimax): Guard declaration with
28622         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
28623         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
28624         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
28625         (strtoumax): Likewise, for completeness (it wasn't necessary).
28626
28627 2001-09-17  Paul Eggert  <eggert@twinsun.com>
28628
28629         * lib/strtoimax.c (HAVE_LONG_LONG):
28630         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
28631         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
28632         to work around bug in IBM C compiler.
28633
28634 2001-09-17  Jim Meyering  <meyering@lucent.com>
28635
28636         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
28637         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
28638         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
28639         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
28640         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
28641         whenever the right hand side need not be expanded by the shell.
28642
28643 2001-09-16  Paul Eggert  <eggert@twinsun.com>
28644
28645         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
28646         library.  It's not correct, as some older glibcs are buggy.
28647         fnmatch wasn't fixed until glibc 2.2.
28648
28649         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
28650         special shell magic here.
28651
28652 2001-09-16  Jim Meyering  <meyering@lucent.com>
28653
28654         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
28655         * m4/jm-macros.m4: Require it.
28656
28657 2001-09-16  Jim Meyering  <meyering@lucent.com>
28658
28659         * lib/mkdir.c: New file.
28660
28661 2001-09-15  Jim Meyering  <meyering@lucent.com>
28662
28663         * m4/jm-macros.m4: Check for help2man.
28664
28665 2001-09-11  Jim Meyering  <meyering@lucent.com>
28666
28667         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
28668         The body, by Paul Eggert, was moved here from configure.in.
28669         * m4/jm-macros.m4: Require UTILS_HOST_OS.
28670
28671 2001-09-04  Paul Eggert  <eggert@twinsun.com>
28672
28673         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
28674         (jm_PREREQ): Use it.
28675
28676 2001-09-04  Paul Eggert  <eggert@twinsun.com>
28677
28678         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
28679         Use ssize_t, not int, to store result of readlink.
28680         Check for ssize_t overflow as well as size_t overflow,
28681         as POSIX says the result of readlink is implementation-defined
28682         when ssize_t overflows.
28683         Remove unnecessary cast to char*.
28684         Use free+malloc instead of realloc, as the storage doesn't need
28685         to be preserved and it's clearer and can be more efficient that way.
28686         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
28687         * lib/xreadlink.h (xreadlink): Update prototype.
28688
28689 2001-09-04  Paul Eggert  <eggert@twinsun.com>
28690
28691         * lib/xgetcwd.c: Revert some of the previous change; intead,
28692         fix the HAVE_GETCWD_NULL code to behave more like the
28693         !HAVE_GETCWD_NULL code used to.
28694
28695         Include "xalloc.h".
28696         (xgetcwd): Do not return NULL when memory is exhausted; instead,
28697         invoke xalloc_die.
28698
28699 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28700
28701         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
28702         sys/param.h, as pathmax.h includes them.
28703
28704 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28705
28706         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
28707         (jm_PREREQ_XGETCWD): New macro.
28708
28709         * m4/getcwd.m4: New file.
28710
28711 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28712
28713         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
28714         like the HAVE_GETCWD_NULL code.
28715         Include pathmax.h if not HAVE_GETCWD.
28716         Do not include xalloc.h.
28717         (INITIAL_BUFFER_SIZE): New symbol.
28718         Do not use xmalloc / xrealloc, since the caller is responsible for
28719         handling errors.  Preserve errno around `free' during failure.
28720         Do not overrun buffer when using getwd.
28721
28722 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28723
28724         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
28725         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
28726         getcwd (NULL, 0).
28727
28728 2001-09-03  Paul Eggert  <eggert@twinsun.com>
28729
28730         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
28731         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
28732         spotted by Jim Meyering.
28733
28734 2001-09-03  Jim Meyering  <meyering@lucent.com>
28735
28736         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
28737         failure.
28738
28739 2001-09-02  Jim Meyering  <meyering@lucent.com>
28740
28741         * lib/error.c: Update from GNU libc.
28742
28743 2001-09-01  Jim Meyering  <meyering@lucent.com>
28744
28745         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
28746         Used by df.
28747
28748 2001-09-01  Jim Meyering  <meyering@lucent.com>
28749
28750         * lib/xreadlink.c: New file.
28751         * lib/xreadlink.h: New file.
28752         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
28753         xreadlink.h.
28754
28755         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
28756         doesn't conflict with sparc Solaris 7's definition in
28757         /usr/include/sys/int_types.h.
28758
28759         * lib/exclude.c: Use `""', not `<>' to #include non-system header
28760         files.
28761         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
28762         and strncasecmp as r-values.  Unixware didn't have declarations.
28763
28764 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28765
28766         * lib/xstrtol.h: Add copyright notice.
28767         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
28768         LONGINT_INVALID_SUFFIX_CHAR.
28769
28770 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28771
28772         * lib/xstrtol.c (strtoimax): New decl.
28773
28774 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28775
28776         * lib/xgetcwd.c: Don't include pathmax.h.
28777         Include stdlib.h and unistd.h if available.
28778         Include xalloc.h.
28779         (xmalloc, xstrdup, free): Remove decls.
28780         (xgetcwd): Don't assume sizes fit in unsigned.
28781         Check for overflow when computing sizes.
28782         Simplify reallocation code.
28783
28784 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28785
28786         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
28787         a directory's st_size can have an arbitrary value, so the old
28788         usage could waste an arbitrary amount of memory.  All uses
28789         changed.
28790         * lib/savedir.h: Update prototype.
28791
28792 2001-08-31  Paul Eggert  <eggert@twinsun.com>
28793
28794         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
28795
28796         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
28797         old strtoimax.c.
28798
28799         Also, make the following further changes to make this file's
28800         configuration more similar to that of strtol.c:
28801         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
28802         (strtoumax, uintmax_t, strtoull, strtol): Remove.
28803         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
28804         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
28805         changed to signed values.
28806
28807         And make the following changes as well:
28808         Fix copyright notice, as 1999 was missing.
28809         (verify): New macro.
28810         (strtoimax): Check sizes at compile-time, not run-time.
28811         Prefer strtol to strtoll if both work.
28812         (main): Remove; it was not that useful and was a pain to maintain.
28813
28814         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
28815
28816 2001-08-31  Jim Meyering  <meyering@lucent.com>
28817
28818         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
28819         Use an initial, malloc'd, buffer of length 128 rather than
28820         a statically allocated one of length 1024.
28821
28822 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28823
28824         Simplify code, partly by assuming autoconf 2.52 semantics.
28825
28826         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
28827
28828         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
28829         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
28830         All uses removed.
28831         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
28832         Move AC_REQUIRE to next-to-top level, to avoid confusion.
28833         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
28834         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
28835         jm_AC_HEADER_INTTYPES_H.
28836         * m4/jm-macros.m4 (jm_MACROS): Likewise.
28837
28838         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
28839
28840         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
28841         Quote first arg of AC_DEFUN.
28842         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
28843         since they are needed to parse the include file even if we need
28844         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
28845         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
28846         but with opposite signedness.
28847
28848 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28849
28850         Merge 'exclude' changes from tar 1.13.22.
28851         This fixes one or two unlikely storage allocation overflow bugs,
28852         but doesn't change user-visible behavior otherwise.
28853
28854 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28855
28856         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
28857         (jm_PREREQ_EXCLUDE): New macro.
28858
28859 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28860
28861         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
28862         tm to be declared.
28863
28864 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28865
28866         * lib/hash.c: Remove '2001' from copyright notice.
28867
28868 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28869
28870         * lib/full-write.h: New file.
28871         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
28872         * lib/full-write.c: Correct credits, as cccp.c no longer
28873         exists and anyway it was so heavily changed from the old cccp
28874         code as to be unrecognizable.  Include full-write.h.
28875         (full_write) Return size_t, with short writes meaning failure.
28876         All callers changed.  This fixes a bug with large buffers
28877         on 64-bit hosts.
28878         * lib/utime.c: Include full-write.h.
28879
28880 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28881
28882         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
28883         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
28884         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
28885         Include if available.
28886         (<xalloc.h>): Include
28887         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
28888         (verify): New macro.  Use it to verify that EXCLUDE macros do not
28889         collide with FNM macros.
28890         (struct patopts): New struct.
28891         (struct exclude): Use it, as exclude patterns now come with options.
28892         (new_exclude): Support above changes.
28893         (new_exclude, add_exclude_file):
28894         Initial size must now be a power of two to simplify overflow checking.
28895         (free_exclude, fnmatch_no_wildcards): New function.
28896         (excluded_filename): No longer requires options arg, as the options
28897         are determined by add_exclude.  Now returns bool, not int.
28898         (excluded_filename, add_exclude):
28899         Add support for the fancy new exclusion options.
28900         (add_exclude, add_exclude_file): Now takes int options arg.
28901         Check for arithmetic overflow when computing sizes.
28902         (add_exclude_file): xrealloc might modify errno, so don't
28903         realloc until after errno might be used.
28904
28905         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
28906         New macros.
28907         (free_exclude): New decl.
28908         (add_exclude, add_exclude_file): Now takes int options arg.
28909         (excluded_filename): No longer requires options arg, as the options
28910         are determined by add_exclude.  Now returns bool, not int.
28911
28912 2001-08-30  Paul Eggert  <eggert@twinsun.com>
28913
28914         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
28915
28916 2001-08-27  Jim Meyering  <meyering@lucent.com>
28917
28918         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
28919
28920         * lib/version-etc.c (N_): Remove definition.
28921         Revert most of last change.
28922         Instead, simply don't mark the `Copyright...' string for translation.
28923         Based on advice from Paul Eggert.
28924
28925         * lib/strtoxmax.c: Tweak comment.
28926
28927 2001-08-26  Jim Meyering  <meyering@lucent.com>
28928
28929         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
28930
28931         * m4/xstrtoimax.m4: New file.
28932         * m4/xstrtoumax.m4: Add comments explaining why we
28933         AC_REPLACE_FUNCS(strtol).
28934
28935 2001-08-26  Jim Meyering  <meyering@lucent.com>
28936
28937         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
28938         of copyright with `%s' so translators don't get an untranslated
28939         message in 2002.
28940         (COPYRIGHT_YEAR): Define.
28941         (version_etc): Use fprintf rather than fputs.
28942         Suggestion from Ulrich Drepper.
28943
28944         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
28945
28946         * lib/strtoll.c: New file, from GNU libc.
28947         * lib/xstrtoimax.c: New file.
28948
28949         * lib/xstrtol.h: Add xstrtoimax.
28950         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
28951         * lib/strtoimax.c: New file.  Likewise, but first define
28952         STRTOUXMAX_SIGNED.
28953
28954         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
28955         ...
28956         * lib/strtoxmax.c: ... then renamed to this.
28957
28958 2001-08-18  Paul Eggert  <eggert@twinsun.com>
28959
28960         * m4/inttypes.m4: Add AC_PREREQ(2.13).
28961         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
28962         (jm_AC_TYPE_INTMAX_T): New macro.
28963         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
28964
28965         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
28966
28967         * m4/longlong.m4: Renamed from ulonglong.m4.
28968         * m4/inttypes.m4: Renamed from inttypes_h.m4.
28969         * m4/uintmax_t.m4: Removed.
28970
28971 2001-08-13  Paul Eggert  <eggert@twinsun.com>
28972
28973         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
28974         Port to Solaris 8, where 'sed' requires a space after the 'r'
28975         command, and where sh dislikes "$/".  Clean up the spacing a bit.
28976         Redirect output to $tmp just once.
28977
28978 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
28979
28980         * lib/addext.c (<errno.h>): Include.
28981         (errno): Declare if not defined.
28982         (addext): Work correctly when pathconf returns -1 and leaves
28983         errno alone because there is no limit.  Also, work even if
28984         pathconf returns a value greater than SIZE_MAX.
28985
28986 2001-08-12  Jim Meyering  <meyering@lucent.com>
28987
28988         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
28989         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
28990         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
28991         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
28992         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
28993         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
28994         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
28995         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
28996         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
28997         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
28998         utime.m4, utimes.m4, xstrtoumax.m4:
28999         Quote the first argument in each use of AC_DEFUN.
29000
29001 2001-08-12  Jim Meyering  <meyering@lucent.com>
29002
29003         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
29004         Simply `return getcwd (NULL, 0);'.
29005         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
29006         Use 1300 as initial value for length, not PATH_MAX.
29007
29008         * lib/pathmax.h: Clean up cpp syntax.
29009
29010 2001-08-12  Jim Meyering  <meyering@lucent.com>
29011
29012         * lib/gettimeofday.c: New file.
29013         * lib/gtod.h: New file.
29014         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
29015
29016 2001-08-05  Jim Meyering  <meyering@lucent.com>
29017
29018         * m4/jm-macros.m4: Require autoconf-2.52.
29019
29020 2001-08-04  Jim Meyering  <meyering@lucent.com>
29021
29022         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
29023         stmt, to get in sync with glibc.
29024
29025 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29026
29027         The following changes are from gettext 0.10.39 as maintained by
29028         Bruno Haible.
29029
29030         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
29031         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
29032         with inverted sense.  All uses changed.
29033
29034         * lib/mbswidth.c: Don't include <limits.h>.
29035         Include <stdlib.h> and <string.h> unconditionally.
29036         (iswcntrl, mbsinit, ISCNTRL): New macros.
29037         (mbsnwidth): Use K&R style function declarations.
29038         Don't bother checking for MB_LEN_MAX == 1, since the compiler
29039         can optimize it when MB_CUR_MAX == 1.
29040         The width of control characters is zero, not 1.
29041
29042 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29043
29044         The following changes are from gettext 0.10.39 as maintained by
29045         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
29046
29047         * m4/codeset.m4: Upgrade to serial AM1.
29048         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
29049         all uses changed.  Quote first arg of AC_DEFUN.
29050         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
29051
29052         * m4/iconv.m4: Upgrade to serial AM2.
29053         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
29054         Add --with-libconv-prefix.
29055         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
29056         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
29057         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
29058         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
29059         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
29060
29061         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
29062         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
29063         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
29064         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
29065         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
29066         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
29067         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
29068         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
29069         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
29070
29071         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
29072         string.h any more.
29073
29074         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
29075         not the default value.
29076
29077         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
29078         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
29079         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
29080         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
29081         Also check for iswcntrl, used for wcwidth fallback.
29082         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
29083         to Autoconf 2.13.
29084
29085 2001-08-03  Jim Meyering  <meyering@lucent.com>
29086
29087         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
29088         as it was in the original.  Reported by Paul Eggert.
29089
29090 2001-07-16  Jim Meyering  <meyering@lucent.com>
29091
29092         * m4/gettimeofday.m4: New file.
29093         Prompted by a report from Bernhard Baehr.
29094
29095 2001-07-15  Jim Meyering  <meyering@lucent.com>
29096
29097         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
29098         stuff. Now it's in ../Makefile.cfg.
29099
29100 2001-07-15  Jim Meyering  <meyering@lucent.com>
29101
29102         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
29103         (BUILT_SOURCES): Add unlocked-io.h.
29104         (io_functions): Define.
29105         (unlocked-io.h): New rule.
29106         (DISTCLEANFILES): Add unlocked-io.h.
29107         (all-local): Depend on unlocked-io.h, to ensure it is created.
29108
29109         * lib/unlocked-io.hin: New file
29110
29111         * lib/regex.c: Update from glibc.
29112
29113 2001-07-05  Jim Meyering  <meyering@lucent.com>
29114
29115         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
29116         recommendation.
29117         (libfetish_a_SOURCES): Put all .h files here instead.
29118         Remove a thus-exposed (better checks in automake) duplicate and
29119         two unnecessary .h files.
29120
29121 2001-07-04  Jim Meyering  <meyering@lucent.com>
29122
29123         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
29124         that generates jm-glibc-io.m4 so that it doesn't trigger any make
29125         distcheck failure.
29126
29127 2001-07-02  Jim Meyering  <meyering@lucent.com>
29128
29129         The following changes were prompted by suggestions from Bruno Haible.
29130
29131         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
29132         is now generated.
29133         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
29134         definition of EXTRA_DIST.
29135         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
29136         ensure that the generated file is created/updated whenever the list
29137         of $(unlocked_functions) is changed.
29138         (jm-glibc-io.m4): New rule.
29139         (unlocked-io.h): New rule -- currently unused.
29140
29141 2001-06-24  Jim Meyering  <meyering@lucent.com>
29142
29143         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
29144         unmatched right bracket, rather than kludging it with an extra,
29145         falsely-matching quote in a comment.  Patch by Akim Demaille.
29146
29147 2001-06-11  Jim Meyering  <meyering@lucent.com>
29148
29149         * lib/regex.c: Update from GNU libc.
29150
29151 2001-05-27  Jim Meyering  <meyering@lucent.com>
29152
29153         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
29154         Check for ut_type in struct utmp.
29155
29156 2001-05-27  Jim Meyering  <meyering@lucent.com>
29157
29158         * lib/readutmp.h (UT_TYPE): Define.
29159
29160 2001-05-24  Jim Meyering  <meyering@lucent.com>
29161
29162         * lib/argmatch.c: Include "quote.h".
29163         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
29164         quote function.  Reported by Göran Uddeborg.
29165
29166 2001-05-22  Jim Meyering  <meyering@lucent.com>
29167
29168         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
29169         now that we use the package-supplied version unconditionally.
29170         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
29171
29172 2001-05-21  Jim Meyering  <meyering@lucent.com>
29173
29174         * m4/regex.m4: Change a couple backticks to single quotes to avoid
29175         shell syntax errors.
29176
29177 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29178
29179         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
29180
29181 2001-05-20  Paul Eggert  <eggert@twinsun.com>
29182
29183         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
29184         Don't bother to check library strftime, since
29185         we'll be using our own my_strftime function anyway.
29186         Define my_strftime instead of strftime.
29187
29188 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
29189
29190         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
29191         which is not yet declared.
29192
29193 2001-05-15  Jim Meyering  <meyering@lucent.com>
29194
29195         * m4/regex.m4: Use proper quoting so brackets appear in the test
29196         program.
29197         Reported by, and with help from, Bruno Haible.
29198
29199 2001-05-13  Jim Meyering  <meyering@lucent.com>
29200
29201         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
29202         undefined.
29203
29204 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29205
29206         dirname code cleanup.  base_name now behaves more compatibly
29207         with POSIX basename when given file names that have trailing
29208         slashes, and similarly for dir_name.  Add new primitives
29209         base_len and dir_len.  Put the directory-name-related decls
29210         into dirname.h.
29211
29212         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
29213         * lib/backupfile.c (base_name): Likewise.
29214         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
29215         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
29216         * lib/makepath.c (strip_trailing_slashes): Likewise.
29217         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
29218         ISSLASH): Likewise.
29219         * lib/rename.c (strip_trailing_slashes): Likewise.
29220         * lib/same.c (base_name): Likewise.
29221         * lib/stripslash.c (ISSLASH): Likewise.
29222
29223         * lib/addext.c: Include <dirname.h> after size_t is defined.
29224         * lib/backupfile.c: Likewise.
29225
29226         * lib/addext.c (addext): Use base_len to trim redundant
29227         trailing slashes instead of doing it ourselves.
29228         But do not trim the last slash if it is not redundant.
29229
29230         * lib/backupfile.c (find_backup_file_name,
29231         max_backup_version): Use base_len instead of rolling it ourselves.
29232         Handle the case of "" and (on DOS) "C:" correctly.
29233
29234         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
29235         needed. Include <string.h>, <dirname.h>.
29236         (base_name): Allow file names ending in slashes, other than names
29237         that are all slashes.  In this case, return the basename followed
29238         by the slashes.  This is more general, and can be used in places
29239         where the original base_name purposely had an assertion failure.
29240         (base_len): New function.
29241
29242         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
29243         Do not include <assert.h>; no longer needed.
29244         Include xalloc.h.
29245         (memrchr): Remove decl.
29246         (dir_name_r): Remove.
29247         (dir_len): Renamed from dirlen.  All callers changed.
29248         Rewrite in terms of base_name, for simplicity and consistency.
29249         (dir_name): Never return NULL.  All callers changed.
29250         Do not include <stdlib.h> in test program; no longer needed.
29251         return 0; is fine for test program.
29252
29253         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
29254         New macros.
29255         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
29256
29257         * lib/path-concat.c (path_concat): Use base_len to compute
29258         base length, not strlen; this means we cannot rely on memcpy
29259         to null-terminate.
29260
29261         * lib/same.c (STREQ): Remove.
29262         (same_name): Handle the case where the basename ends in trailing '/'.
29263
29264         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
29265         a slash was stripped.  Do not strip the last slash after a
29266         file system prefix.
29267
29268 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29269
29270         * lib/Makefile.am (libfetish_a_SOURCES):
29271         Add strftime.c, since we now compile it on all hosts.
29272
29273         * lib/strftime.c (my_strftime):
29274         Define to nstrftime if emacs, but only if my_strftime is not defined.
29275         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
29276         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
29277         Add one more extra argument: a nanoseconds value.
29278         All uses changed.
29279         (ns): New macro.
29280         (my_strftime function): Add %N format.
29281         (emacs_strftimeu): Renamed from emacs_strftime,
29282         with extra ut argument.
29283
29284 2001-05-09  Paul Eggert  <eggert@twinsun.com>
29285
29286         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
29287
29288 2001-04-21  Jim Meyering  <meyering@lucent.com>
29289
29290         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
29291         doesn't interfere.
29292
29293 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29294
29295         * m4/ftruncate.m4: Check for chsize.
29296         Link with ftruncate.o unconditionally if ftruncate is missing.
29297         This was required when cross-compiling to i586-mingw32msvc.
29298
29299 2001-04-08  Jim Meyering  <meyering@lucent.com>
29300
29301         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
29302         recomputed; that's necessary when the offset spans a DST transition.
29303         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
29304
29305 2001-04-02  Jim Meyering  <meyering@lucent.com>
29306
29307         * lib/regex.h, regex.c: Update from GNU libc.
29308
29309 2001-03-24  Jim Meyering  <meyering@lucent.com>
29310
29311         * m4/jm-macros.m4: Require autoconf-2.49d.
29312
29313 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
29314
29315         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
29316
29317 2001-03-19  Paul Eggert  <eggert@twinsun.com>
29318
29319         * lib/version-etc.c (version_etc_copyright): Update to 2001.
29320
29321 2001-03-17  Jim Meyering  <meyering@lucent.com>
29322
29323         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
29324         now that the version in autoconf is equivalent.
29325         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
29326
29327         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
29328         Suggestion from Akim Demaille.
29329
29330         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
29331         (jm_PREREQ_TEMPNAME): New function.
29332
29333 2001-03-16  Paul Eggert  <eggert@twinsun.com>
29334
29335         * lib/tempname.c (uint64_t): Define to uintmax_t if
29336         not defined, and if UINT64_MAX is not defined.
29337         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
29338         Reported by John David Anglin.
29339
29340 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
29341
29342         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
29343         resolve alias if codeset is empty.
29344         * lib/config.charset (BeOS): Use wildcard syntax.
29345
29346 2001-03-13  Jim Meyering  <meyering@lucent.com>
29347
29348         * lib/path-concat.c (path_concat)
29349         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
29350         concatenating e.g., `C:' and `foo'.
29351         From Bruno Haible.
29352
29353 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29354
29355         * lib/localcharset.c (locale_charset): Don't use
29356         setlocale(LC_CTYPE,NULL). Don't return NULL.
29357         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
29358
29359 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29360
29361         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
29362         support for DOS/DJGPP.
29363
29364 2001-03-01  Paul Eggert  <eggert@twinsun.com>
29365
29366         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
29367         lacks mkstemp.  Compile our own tempname.c if we compile our own
29368         mkstemp.c, as mkstemp relies on tempname.
29369
29370 2001-03-01  Jim Meyering  <meyering@lucent.com>
29371
29372         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
29373         AH_VERBATIM really does output its argument verbatim.
29374
29375 2001-02-28  Paul Eggert  <eggert@twinsun.com>
29376
29377         * lib/Makefile.am (libfetish_a_SOURCES):
29378         Add dup-safer.c, fopen-safer.c.
29379         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
29380
29381         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
29382         * lib/unistd-safer.h: New files.
29383
29384 2001-02-25  Paul Eggert  <eggert@twinsun.com>
29385
29386         The mkstemp replacement is taken from glibc 2.2.2, with some
29387         portability fixes for use outside glibc, as follows:
29388
29389         * lib/tempname.c (struct_stat64): New macro.
29390         (direxists, __gen_tempname): Use it.
29391         This avoids a portability problem with Solaris 8.
29392
29393         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
29394         (<stddef.h>, <stdint.h>, <string.h>):
29395         Include only if STDC_HEADERS || _LIBC.
29396         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
29397         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
29398         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
29399         (__set_errno): Define this macro if <errno.h> doesn't.
29400         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
29401         Define these macros if <stdio.h> doesn't.
29402         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
29403         Define these macros if <sys/stat.h>
29404         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
29405         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
29406         __xstat64): Define if not _LIBC.
29407         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
29408         (__gen_tempname): Invoke gettimeofday only if
29409         HAVE_GETTIMEOFDAY || _LIBC;
29410         otherwise, fall back on plain "time".
29411         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
29412
29413         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
29414
29415         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
29416
29417 2001-02-18  Paul Eggert  <eggert@twinsun.com>
29418
29419         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
29420
29421 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29422
29423         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
29424         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
29425         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
29426         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
29427
29428 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29429
29430         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
29431         Remove workaround macros for hosts that have mbrtowc but not
29432         mbstate_t, as we now insist on proper declarations for both
29433         before using mbrtowc.
29434
29435 2001-02-17  Jim Meyering  <meyering@lucent.com>
29436
29437         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
29438         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
29439         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
29440         UnixWare 7.1.1.
29441
29442         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
29443         rather than AC_CACHE_VAL.
29444
29445 2001-02-17  Jim Meyering  <meyering@lucent.com>
29446
29447         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
29448         around included file name.
29449
29450         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
29451
29452         * lib/strftime.c: Update from GNU libc (the only changes were to
29453         comments).
29454
29455 2001-02-17  Jim Meyering  <meyering@lucent.com>
29456
29457         * lib/regex.c: Update from libc.
29458
29459 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
29460
29461         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
29462         clash.
29463
29464 2001-02-16  Paul Eggert  <eggert@twinsun.com>
29465
29466         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
29467         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
29468         Reported by Mark Hounschell via Paul Eggert.
29469
29470 2001-02-07  Jim Meyering  <meyering@lucent.com>
29471
29472         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
29473
29474 2001-02-05  Jim Meyering  <meyering@lucent.com>
29475
29476         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
29477         it includes the patch required for `large file' support with at least
29478         HP-UX's 10.20 /bin/cc.
29479
29480 2001-02-03  Jim Meyering  <meyering@lucent.com>
29481
29482         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
29483         AS_IF, now that it works once again (mysteriously).
29484         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29485
29486 2001-01-30  Jim Meyering  <meyering@lucent.com>
29487
29488         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
29489         * m4/chown.m4: Rename conftestchown to conftest.chown.
29490         * m4/rename.m4: s/conftestdir/conftest.d1/ and
29491         s/conftestdir2/conftest.d2/.
29492         * m4/utimes.m4: s/conftestdata/conftest.data/
29493         Inspired by Pavel Roskin's change in autoconf.
29494
29495 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
29496
29497         * lib/config.charset: Update for FreeBSD 4.2.
29498
29499 2001-01-27  Jim Meyering  <meyering@lucent.com>
29500
29501         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
29502         a use of AS_IF.
29503         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29504
29505 2001-01-26  Jim Meyering  <meyering@lucent.com>
29506
29507         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
29508         quotearg.c includes it.
29509
29510 2001-01-26  Jim Meyering  <meyering@lucent.com>
29511
29512         * lib/quotearg.c: Include stddef.h.
29513         * lib/quote.c: Include stddef.h.
29514         Reported by Axel Kittenberger.
29515
29516         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
29517         line in double quotes so that it evokes a better diagnostic.
29518         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
29519         Reported by Axel Kittenberger.
29520
29521 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
29522
29523         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
29524         as if it was a `charset'.
29525
29526 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
29527
29528         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
29529         has const.
29530
29531 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
29532
29533         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
29534         to avoid a warning.  Add back 'const' to inptr.
29535
29536 2001-01-20  Jim Meyering  <meyering@lucent.com>
29537
29538         Be sure that headers are checked before used in code compiled
29539         for the type checks.
29540         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
29541         In place of that, invoke jm_CHECK_ALL_TYPES.
29542         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
29543         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
29544         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
29545         The check for ssize_t was mistakenly run before the test for unistd.h.
29546
29547         The configure-time check for stdbool.h was missing.
29548         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
29549         (jm_PREREQ_HASH): New function.
29550
29551 2001-01-17  Jim Meyering  <meyering@lucent.com>
29552
29553         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
29554         for autoconf-2.49c.
29555         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
29556
29557 2001-01-16  Jim Meyering  <meyering@lucent.com>
29558
29559         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
29560         From Bruno Haible.
29561
29562 2001-01-14  Jim Meyering  <meyering@lucent.com>
29563
29564         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
29565         foo and bar.  Create conftestdir/ in the script, not in the C code.
29566         Remove directories in the script, not in the C code.
29567         Remove conftestdir{,2} before trying to create the directory.
29568         Make the entire configure script fail if the mkdir fails.
29569
29570 2001-01-14  Jim Meyering  <meyering@lucent.com>
29571
29572         * lib/rename.c: New file.  From Volker Borchert.
29573         Include stdlib.h, string.h or strings.h, and xalloc.h.
29574         Use strip_trailing_slashes rather than open-coding it.
29575
29576 2001-01-03  Paul Eggert  <eggert@twinsun.com>
29577
29578         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
29579
29580 2001-01-03  Jim Meyering  <meyering@lucent.com>
29581
29582         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
29583         of local `inptr' to avoid warning with some system declarations of
29584         iconv.
29585
29586 2001-01-02  Volker Borchert  <bt@teknon.de>
29587
29588         * m4/rename.m4: New file.
29589         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
29590
29591 2001-01-01  Jim Meyering  <meyering@lucent.com>
29592
29593         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
29594         even on systems with utmpx.h.  It's necessary for the declaration of
29595         utmp's ut_user member.  Reported by Andreas Jaeger.
29596
29597         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
29598         available. They are required for the declarations of getgrgid and
29599         getpwuid resp.
29600         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
29601         Reported by Andreas Jaeger.
29602
29603 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
29604
29605         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
29606         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
29607         so `make install' also works in VPATH builds.
29608
29609 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
29610
29611         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
29612         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
29613         can be used in subdirectories.
29614
29615 2000-12-29  Paul Eggert  <eggert@twinsun.com>
29616
29617         * lib/modechange.c: Do not assume that mode_t uses the
29618         traditional octal encoding.  E.g. "chmod 1 FOO" should set
29619         the other-execute bit of FOO even if S_IXOTH != 1.
29620
29621         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
29622         WOTH, XOTH, ALLM): New macros.
29623         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
29624          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
29625         Use them.
29626         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
29627         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
29628         (mode_compile):
29629         No need to use uintmax_t; unsigned long is long enough.
29630         Don't bother to get suffix since we don't use it.
29631
29632 2000-12-26  Jim Meyering  <meyering@lucent.com>
29633
29634         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
29635         better with autoheader.
29636
29637 2000-12-24  Jim Meyering  <meyering@lucent.com>
29638
29639         * lib/hash.c (is_prime): Return explicit boolean values.
29640         (hash_get_first): Return NULL to appease Irix5.6's 89.
29641         Reported by Nelson Beebe.
29642
29643 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
29644
29645         * lib/localcharset.c (locale_charset): Add support for Win32.
29646
29647 2000-12-18  Paul Eggert  <eggert@twinsun.com>
29648
29649         * lib/physmem.h, lib/physmem.c: New files.
29650
29651         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
29652         (noinst_HEADERS): Add physmem.h.
29653
29654         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
29655         't' for compatibility with Solaris 8 sort.
29656
29657 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
29658
29659         * lib/config.charset: Add support for BeOS.
29660
29661 2000-12-17  Jim Meyering  <meyering@lucent.com>
29662
29663         * m4/dos.m4 (jm_AC_DOS): New file and macro.
29664         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
29665
29666 2000-12-16  Jim Meyering  <meyering@lucent.com>
29667
29668         This bug had a serious impact on chown: `chown N:M FILE' (for integer
29669         N and M) would have treated it like `chown N:N FILE'.
29670
29671         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
29672
29673 2000-12-16  Jim Meyering  <meyering@lucent.com>
29674
29675         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
29676         SHELLS_FILE to a file name that's useful on djgpp systems.
29677         Include stdlib.h.
29678         (ADDITIONAL_DEFAULT_SHELLS): Define.
29679         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
29680         Based mostly on a patch from Prashant TR.
29681
29682 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
29683
29684         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
29685         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
29686         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
29687
29688 2000-12-08  Andreas Schwab  <schwab@suse.de>
29689
29690         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
29691         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
29692
29693 2000-12-07  Jim Meyering  <meyering@lucent.com>
29694
29695         * lib/stripslash.c (ISSLASH): Define.
29696         (strip_trailing_slashes): Use ISSLASH rather than comparing against
29697         `/'.
29698         From Prashant TR.
29699
29700         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
29701         (dir_name_r): Declare this function as static.
29702         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
29703         manifest itself on a name containing a mix of slashes and
29704         backslashes.
29705         Make this function work with names starting with a DOS-style
29706         drive letter and colon prefix.
29707         (dir_name): Append `.' if necessary.
29708         Based mostly on patches from Prashant TR and Eli Zaretskii.
29709
29710         * lib/dirname.h (dir_name_r): Remove prototype.
29711
29712 2000-12-06  Paul Eggert  <eggert@twinsun.com>
29713
29714         * m4/off_t-format.m4: Remove this file.
29715         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
29716
29717 2000-12-06  Jim Meyering  <meyering@lucent.com>
29718
29719         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
29720         replacement strtoull, we may well need the replacement strtoul, too.
29721         Check for declarations of strtoul and strtoull.
29722         Check for strtol.  Mainly as a cue to cause automake to include
29723         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
29724         Check for limits.h -- strtol.c needs it.
29725
29726 2000-12-05  Jim Meyering  <meyering@lucent.com>
29727
29728         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
29729
29730 2000-12-04  Jim Meyering  <meyering@lucent.com>
29731
29732         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
29733         Also include memory.h, stdlib.h, unistd.h if appropriate.
29734         Reported by Andreas Jaeger (conflicting declaration of malloc).
29735
29736 2000-12-02  Jim Meyering  <meyering@lucent.com>
29737
29738         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
29739         * m4/jm-macros.m4 (jm_MACROS): require it.
29740
29741 2000-12-02  Jim Meyering  <meyering@lucent.com>
29742
29743         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
29744
29745 2000-12-01  Paul Eggert  <eggert@twinsun.com>
29746
29747         * lib/memrchr.c: Include <config.h> before any system include file.
29748
29749 2000-11-30  Jim Meyering  <meyering@lucent.com>
29750
29751         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
29752
29753 2000-11-30  Jim Meyering  <meyering@lucent.com>
29754
29755         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
29756
29757 2000-11-29  Paul Eggert  <eggert@twinsun.com>
29758
29759         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
29760
29761 2000-11-26  Jim Meyering  <meyering@lucent.com>
29762
29763         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
29764
29765 2000-11-22  Paul Eggert  <eggert@twinsun.com>
29766
29767         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
29768         size of (size_t) -1; it's not portable.
29769
29770 2000-11-17  Jim Meyering  <meyering@lucent.com>
29771
29772         * lib/strstr.c: Update from GNU libc.
29773
29774 2000-11-17  Akim Demaille  <akim@epita.fr>
29775
29776         * lib/obstack.h: Formatting changes.
29777         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
29778         prevent type checking.
29779         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
29780         cast the value to (void *): assigning a `foo *' to a `void *'
29781         variable is valid.
29782         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
29783
29784 2000-11-16  Jim Meyering  <meyering@lucent.com>
29785
29786         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
29787
29788 2000-11-11  Jim Meyering  <meyering@lucent.com>
29789
29790         * lib/error.c: Add a couple #includes, merging from GNU libc version.
29791
29792 2000-11-10  Jim Meyering  <meyering@lucent.com>
29793
29794         * lib/obstack.h: Update from GNU libc.
29795         * lib/obstack.c: Likewise.
29796
29797 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
29798
29799         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
29800
29801 2000-11-06  Paul Eggert  <eggert@twinsun.com>
29802
29803         * lib/getusershell.c (setusershell): Use rewind rather than
29804         fseek/fseeko, to avoid configuration hassles with fseeko.
29805         Don't bother opening SHELLS_FILE if shellstream is NULL;
29806         it's not necessary.
29807
29808 2000-11-05  Jim Meyering  <meyering@lucent.com>
29809
29810         * lib/makepath.h (make_dir): Declare.
29811         * lib/makepath.c (make_dir): Remove `static' attribute.
29812         Tweak a comment.
29813
29814 2000-11-04  Jim Meyering  <meyering@lucent.com>
29815
29816         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
29817
29818 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
29819
29820         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
29821         last one in a bucket, advance to the next bucket.
29822
29823 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
29824
29825         * lib/fnmatch.c: Do not comment out all the code if we are using
29826         the GNU C library, because in some cases we are replacing buggy
29827         code in the GNU C library itself.
29828
29829 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
29830
29831         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
29832         (regex_compile): Catch bogus \(\1\).
29833
29834 2000-10-30  Paul Eggert  <eggert@twinsun.com>
29835
29836         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
29837         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
29838         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
29839
29840 2000-10-30  Paul Eggert  <eggert@twinsun.com>
29841
29842         * lib/error.h, getline.h, modechange.h:
29843         Remove "2000" from Copyright line, as the file hasn't been
29844         changed this year other than in the copyright notice.
29845
29846         * lib/xalloc.h: Add "2000" to Copyright line, as this file
29847         was changed this year.
29848
29849 2000-10-29  Jim Meyering  <meyering@lucent.com>
29850
29851         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
29852         renaming.
29853         * m4/ls-mntd-fs.m4: Likewise
29854
29855 2000-10-29  Jim Meyering  <meyering@lucent.com>
29856
29857         * lib/xstat.in: Fix grammar in comment.
29858
29859 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
29860
29861         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
29862         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
29863         doesn't define __restrict_arr.
29864
29865 2000-10-28  Jim Meyering  <meyering@lucent.com>
29866
29867         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
29868         (jm_PREREQ_MEMCHR): New function.
29869
29870 2000-10-28  Jim Meyering  <meyering@lucent.com>
29871
29872         * lib/memchr.c: Update from libc.
29873         Adjust for portability:
29874         [HAVE_STDLIB_H]: Include stdlib.h.
29875         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
29876         Undef __memchr, too.
29877         [!weak_alias]: Define __memchr to memchr.
29878
29879         * lib/regex.c: Update from libc.
29880         * lib/regex.h: Likewise.
29881         * lib/getopt1.c: Likewise.
29882         * lib/memcmp.c: Likewise.
29883
29884         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
29885         Avoid using fseek, when possible -- it's broken by design.
29886         Patch by Ulrich Drepper.
29887
29888 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
29889
29890         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
29891         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
29892         Giving in to popular pressure to shut up the compiler with casts.
29893
29894 2000-10-26  Jim Meyering  <meyering@lucent.com>
29895
29896         * lib/strftime.c: Update from libc.
29897
29898 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
29899
29900         * regex.c: More `unsigned char' -> `re_char' changes.
29901         Also change several `int' into `re_wchar_t'.
29902         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
29903         (PUSH_FAILURE_POINTER): Don't cast any more.
29904         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
29905         We want GCC to complain, since this piece of code makes
29906         re_match non-reentrant, which *should* be fixed.
29907         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
29908         (EXTEND_BUFFER): Use RETALLOC.
29909         (SET_LIST_BIT): Don't cast.
29910         (re_wchar_t): New type.
29911         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
29912         that those two functions will always properly return.
29913         (IMMEDIATE_QUIT_CHECK): Cast to void.
29914         (analyse_first): Use recursion rather than an explicit stack.
29915         (re_compile_fastmap): Can't fail anymore.
29916         (re_search_2): Don't check re_compile_fastmap for failure.
29917         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
29918         Now also sets the new value (passed in a new argument).
29919         (re_match_2_internal): Use it.
29920         Also, use a new var `reg' of type size_t when looping through regs
29921         rather than reuse the inappropriate `mcnt'.
29922
29923 2000-10-25  Jim Meyering  <meyering@lucent.com>
29924
29925         * lib/obstack.c: Update from libc.
29926
29927 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
29928
29929         * regex.c (regex_compile): Change the way of handling a range from
29930         a char less than 256 to a char not less than 256.
29931
29932 2000-10-24  Andrew Innes  <andrewi@gnu.org>
29933
29934         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
29935         NT-Emacs only.
29936         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
29937         so that re_search functions only quit when callers expect them to.
29938
29939 2000-10-23  Jim Meyering  <meyering@lucent.com>
29940
29941         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
29942         wrong.  That set_locale call must not have any side effects.
29943         From Paul Eggert.
29944
29945 2000-10-22  Jim Meyering  <meyering@lucent.com>
29946
29947         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
29948         [CYCLIC]: Remove now-unused definition.
29949
29950         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
29951         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
29952         Suggestion from Ulrich Drepper.
29953
29954 2000-10-21  Jim Meyering  <meyering@lucent.com>
29955
29956         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
29957         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
29958         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
29959
29960 2000-10-21  Jim Meyering  <meyering@lucent.com>
29961
29962         * lib/dirname.c (memrchr): Declare if necessary.
29963         (dir_name): Remove the restriction that there be no
29964         trailing slashes.  Now, this code skips past them, effectively
29965         ignoring them.
29966         [TEST_DIRNAME] (main): New unit tests.
29967
29968         * lib/memrchr.c: New file from GNU libc.
29969         Undef __memrchr, too.
29970         [!weak_alias]: Define __memrchr to memrchr.
29971         Guard weak_alias use with `#ifdef weak_alias'.
29972
29973 2000-10-21  Jim Meyering  <meyering@lucent.com>
29974
29975         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
29976         (dir_name): Use dir_name_r.
29977         * lib/dirname.h (dir_name_r): Declare it.
29978
29979 2000-10-17  Jim Meyering  <meyering@lucent.com>
29980
29981         * lib/quote.h (PARAMS): Define and use.
29982         Reported by Akim Demaille.
29983
29984         * lib/getopt.c: Update from libc.
29985
29986 2000-10-16  Jim Meyering  <meyering@lucent.com>
29987
29988         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
29989         setlocale.
29990         From Jan Fedak.
29991
29992 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
29993
29994         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
29995
29996 2000-09-25  Jim Meyering  <meyering@lucent.com>
29997
29998         * lib/md5.h (rol): Define (from GnuPG).
29999
30000         * lib/sha.c: Give credit (GnuPG) where due.
30001         (M): Use rol rather than open-coding it.
30002         Add a FIXME comment.
30003
30004 2000-09-21  Jim Meyering  <meyering@lucent.com>
30005
30006         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
30007         Reported by Michael Stone.
30008
30009 2000-09-20  Jim Meyering  <meyering@lucent.com>
30010
30011         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
30012         (noinst_HEADERS): Add sha.h.
30013         Based on code from Scott G. Miller and from GnuPG.
30014
30015 2000-09-18  Jim Meyering  <meyering@lucent.com>
30016
30017         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
30018         LIBS. Otherwise, everyone ends up linking with -lelf for some
30019         configurations.
30020         Reported by Mike Stone.
30021
30022 2000-09-15  Jim Meyering  <meyering@lucent.com>
30023
30024         * lib/regex.c: Update from libc.
30025
30026 2000-09-10  Jim Meyering  <meyering@lucent.com>
30027
30028         * lib/getopt.c (_getopt_internal): Update from glibc.
30029
30030 2000-09-09  Jim Meyering  <meyering@lucent.com>
30031
30032         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
30033         think it should be used as a general replacement for isascii.
30034         * lib/fnmatch.c: Likewise.
30035         * lib/mbswidth.c: Likewise
30036         * lib/regex.c: Likewise.
30037
30038         Don't use atoi.
30039         * lib/userspec.c: Include sys/param.h and limits.h.
30040         Include xstrtol.h.
30041         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
30042         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
30043         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
30044         UID, GID.  Check range.
30045
30046 2000-09-06  Jim Meyering  <meyering@lucent.com>
30047
30048         * lib/getopt.c (_getopt_internal): Update from glibc.
30049
30050 2000-08-30  Jim Meyering  <meyering@lucent.com>
30051
30052         * lib/strftime.c: Merge in changes from GNU libc.
30053
30054 2000-08-26  Jim Meyering  <meyering@lucent.com>
30055
30056         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
30057         * m4/fpending.m4: New file.
30058
30059 2000-08-26  Jim Meyering  <meyering@lucent.com>
30060
30061         * lib/closeout.c: Include "__fpending.h".
30062         (close_stdout_status): Return right away if there's nothing to flush.
30063
30064         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
30065         * lib/__fpending.c: New file.
30066         * lib/__fpending.h: New file.
30067
30068 2000-08-20  Jim Meyering  <meyering@lucent.com>
30069
30070         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
30071         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
30072         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
30073
30074 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
30075
30076         Improve fileutils installation on systems where running
30077         programs (like install) can't be unlinked.
30078         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
30079         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
30080
30081 2000-08-07  Paul Eggert  <eggert@twinsun.com>
30082
30083         Standardize on "memory exhausted" instead of "Memory exhausted"
30084         or "virtual memory exhausted".
30085         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
30086         "virtual memory exhausted".
30087         * lib/same.c (same_name): Invoke xalloc_die instead of printing
30088         our own message.
30089         * lib/userspec.c (parse_user_spec): Likewise.
30090         * lib/bumpalloc.h: comment fix
30091         * lib/same.c, userspec.c: Include xalloc.h.
30092
30093         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
30094         not char *const and pointing to a constant array.
30095         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
30096         (xrealloc): Comment fix.
30097
30098         * lib/userspec.c (parse_user_spec):
30099         Don't translate a message until just before returning,
30100         to avoid unnecessary translation.
30101
30102 2000-08-07  Jim Meyering  <meyering@lucent.com>
30103
30104         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
30105         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
30106         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
30107         getgroups.c, gethostname.c, getopt.h, group-member.c,
30108         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
30109         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
30110         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
30111         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
30112         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
30113         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
30114         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
30115         yesno.c: Back out Copyright date changes for each file with no change
30116         this year.  This eases coordination with other programs using the same
30117         source code modules.  From Paul Eggert.
30118
30119 2000-08-06  Paul Eggert  <eggert@twinsun.com>
30120
30121         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
30122         not char, for compatibility with glibc 2.1.3 strftime.c.
30123
30124 2000-08-03  Greg McGary  <greg@mcgary.org>
30125
30126         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
30127         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
30128         (EXTEND_BUFFER): Use them.
30129
30130 2000-08-01  Jim Meyering  <meyering@lucent.com>
30131
30132         * lib/dirname.c (ISSLASH): Define.
30133         (BACKSLASH_IS_PATH_SEPARATOR): Define.
30134         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
30135         both `\' and `/' may be use as path separators.
30136         Based on a patch from Prashant TR.
30137
30138 2000-07-31  Paul Eggert  <eggert@twinsun.com>
30139
30140         * lib/quotearg.c (quotearg_n_options): Don't make the initial
30141         slot vector a constant, since it might get modified.
30142
30143 2000-07-31  Jim Meyering  <meyering@lucent.com>
30144
30145         * lib/xmalloc.c: Use `virtual memory exhausted', not
30146         `Memory exhausted'.
30147         * lib/obstack.c (print_and_abort): Likewise.
30148
30149 2000-07-30  Paul Eggert  <eggert@twinsun.com>
30150
30151         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
30152         buffer, so that the caller can always quote one small
30153         component of a "memory exhausted" message in slot 0.
30154         From a suggestion by Jim Meyering.
30155
30156 2000-07-30  Jim Meyering  <meyering@lucent.com>
30157
30158         * lib/makepath.c (make_path): Quote the other instance, too.
30159
30160         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
30161         (STATIC_BUF_SIZE): Define.
30162         (quotearg_n_options): Use only statically allocated storage when
30163         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
30164         than STATIC_BUF_SIZE.
30165
30166 2000-07-29  Jim Meyering  <meyering@lucent.com>
30167
30168         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
30169         * lib/dirname.c (dir_name): Likewise.
30170
30171         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
30172         `/'.
30173
30174         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
30175         (dir_name): Assert that there are no trailing slashes.
30176
30177 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
30178
30179         * lib/mbswidth.h (mbswidth): Add a flags argument.
30180         (mbswidth): New declaration.
30181         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
30182         * lib/mbswidth.c (mbswidth): Add a flags argument.
30183         (mbsnwidth): New function.
30184
30185 2000-07-24  Jim Meyering  <meyering@lucent.com>
30186
30187         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
30188
30189 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30190
30191         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
30192
30193 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30194
30195         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
30196         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
30197         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
30198         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
30199         invoke multibyte primitives.
30200
30201 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30202
30203         * lib/quotearg.c:
30204         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
30205         so that mbstate_t is always defined.
30206
30207         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
30208         be 1 in at least one GCC installation, and this configuration
30209         error is likely to be common.  Ignoring MB_LEN_MAX hurts
30210         performance on hosts that have mbrtowc but have only unibyte
30211         locales, but I assume these hosts are rare.
30212
30213 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30214
30215         * lib/mbswidth.c (_XOPEN_SOURCE):
30216         Don't define; this causes problems on Solaris 7.
30217         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
30218
30219 2000-07-23  Jim Meyering  <meyering@lucent.com>
30220
30221         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
30222         too: getgrgid, getpwuid, getuid.
30223
30224 2000-07-23  Jim Meyering  <meyering@lucent.com>
30225
30226         * lib/basename.c (base_name): Add an assertion.
30227
30228 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
30229
30230         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
30231         shadow its mbsinit function.
30232
30233 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30234
30235         * lib/mbswidth.h: New file.
30236         * lib/mbswidth.c: New file.
30237         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
30238         (noinst_HEADERS): Add mbswidth.h.
30239
30240 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30241
30242         * lib/config.charset: Add support for FreeBSD. Improve support for
30243         HP-UX and IRIX 6.
30244
30245 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
30246
30247         * m4/mbswidth.m4: New file.
30248         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
30249
30250 2000-07-15  Jim Meyering  <meyering@lucent.com>
30251
30252         * lib/makepath.c: Include quote.h.
30253         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
30254         corresponding argument in a `quote (...)' call.
30255         Give better diagnostics.
30256
30257         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
30258         (noinst_HEADERS): Add quote.h.
30259
30260         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
30261         from tar's src/misc.c.
30262         * lib/quote.h: New file.  Prototypes for same.
30263
30264 2000-07-14  Paul Eggert  <eggert@twinsun.com>
30265
30266         From a suggestion by Bruno Haible.
30267         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
30268         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
30269         to decide whether to define the BeOS workaround macro;
30270         this adjusts to the change to AC_MBSTATE_T.
30271
30272 2000-07-14  Jim Meyering  <meyering@lucent.com>
30273
30274         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
30275         jm_AC_TYPE_UINTMAX_T.
30276
30277 2000-07-13  Paul Eggert  <eggert@twinsun.com>
30278
30279         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
30280
30281         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
30282         quotearg_buffer_restyled): Add support for
30283         clocale_quoting_style.  Undo previous change to
30284         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
30285         and "{RIGHT QUOTATION MARK}" msgids.
30286
30287 2000-07-10  Paul Eggert  <eggert@twinsun.com>
30288
30289         From a suggestion by Bruno Haible.
30290         * m4/mbstate_t.m4 (AC_MBSTATE_T):
30291         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
30292         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
30293         and mbstate_t, to a single-part test that simply defines mbstate_t.
30294         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
30295         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
30296
30297 2000-07-10  Jim Meyering  <meyering@lucent.com>
30298
30299         * m4/strerror_r.m4: Mirror the correction made in autoconf.
30300
30301         * m4/gnu-source.m4: Output to confdefs.h directly.
30302         Suggestion from Akim Demaille.
30303
30304 2000-07-09  Paul Eggert  <eggert@twinsun.com>
30305
30306         The old behavior of quoting `like this' doesn't look good with
30307         newer, ISO-style fonts.  See:
30308         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
30309
30310         Instead, quote "like this" by default.  Let the translator
30311         tailor the locale-specific quoting behavior by providing
30312         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
30313
30314         * lib/quotearg.c (N_): New macro.
30315         (gettext_default): New function.
30316         (quotearg_buffer_restyled): Use
30317         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
30318         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
30319
30320 2000-07-09  Jim Meyering  <meyering@lucent.com>
30321
30322         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
30323         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
30324
30325         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
30326         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
30327
30328 2000-07-09  Jim Meyering  <meyering@lucent.com>
30329
30330         * lib/Most files: Update copyright dates to include 2000.
30331
30332 2000-07-08  Jim Meyering  <meyering@lucent.com>
30333
30334         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
30335         if not defined.
30336         (xgethostname): Remove now-unnecessary #ifdef.
30337         Move declaration of `err' into loop where it's used.
30338
30339 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30340         and Bruno Haible  <haible@clisp.cons.org>
30341
30342         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
30343         only if the test for an object-type mbstate_t fails.  This
30344         prevents us from mistakenly reporting that mbstate_t is a
30345         system object type after we "#define mbstate_t int" to work
30346         around its lack.
30347
30348 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30349         and Bruno Haible  <haible@clisp.cons.org>
30350
30351         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
30352
30353 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30354
30355         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
30356         to strerror_r.
30357         Include <ctype.h> for use of isalpha.
30358
30359 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30360
30361         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
30362         by allocating a larger buffer. Test the gethostname return value for
30363         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
30364         returns an error and ENAMETOOLONG isn't defined.
30365
30366 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30367
30368         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
30369         dimension.
30370
30371 2000-07-04  Jim Meyering  <meyering@lucent.com>
30372
30373         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
30374         of the deprecated AC_CHECKING.
30375
30376 2000-07-04  Jim Meyering  <meyering@lucent.com>
30377
30378         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
30379         Reported by Bruno Haible.
30380
30381 2000-07-04  Jim Meyering  <meyering@lucent.com>
30382
30383         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
30384         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
30385         lacks mbrtowc.
30386
30387 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30388
30389         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
30390         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
30391
30392 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30393         and Bruno Haible  <haible@clisp.cons.org>
30394
30395         * lib/quotearg.c (mbrtowc):
30396         Assign to *pwc, and return 1 only if result is nonzero.
30397         (iswprint): Use ISPRINT when substituting our own mbrtowc.
30398
30399 2000-07-03  Jim Meyering  <meyering@lucent.com>
30400
30401         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
30402
30403 2000-07-03  Jim Meyering  <meyering@lucent.com>
30404
30405         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
30406         This is necessary to get a definition of e.g., UTMP_FILE on
30407         HP-UX 10.20.
30408         From Bob Proulx.
30409
30410 2000-07-02  Jim Meyering  <meyering@lucent.com>
30411
30412         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
30413
30414         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
30415         AC_LIBOBJ(function_name).
30416         * m4/chown.m4: Likewise.
30417         * m4/fnmatch.m4: Likewise.
30418         * m4/ftruncate.m4: Likewise.
30419         * m4/getgroups.m4: Likewise.
30420         * m4/getline.m4: Likewise.
30421         * m4/group-member.m4: Likewise.
30422         * m4/jm-macros.m4: Likewise.
30423         * m4/lstat.m4: Likewise.
30424         * m4/malloc.m4: Likewise.
30425         * m4/memcmp.m4: Likewise.
30426         * m4/nanosleep.m4: Likewise.
30427         * m4/putenv.m4: Likewise.
30428         * m4/realloc.m4: Likewise.
30429         * m4/regex.m4: Likewise.
30430         * m4/stat.m4: Likewise.
30431         * m4/strftime.m4: Likewise.
30432
30433 2000-07-02  Jim Meyering  <meyering@lucent.com>
30434
30435         * lib/quotearg.c (mbstate_t): Don't define here.
30436
30437 2000-07-02  Jim Meyering  <meyering@lucent.com>
30438
30439         * lib/nanosleep.c (SIGCONT): Define if not already defined.
30440
30441 2000-07-01  Jim Meyering  <meyering@lucent.com>
30442
30443         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
30444
30445 2000-07-01  Jim Meyering  <meyering@lucent.com>
30446
30447         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
30448         problem.
30449
30450 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30451
30452         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
30453         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
30454
30455 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30456
30457         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
30458         per change in ../m4/ls-mntd-fs.m4.
30459         (read_filesystem_list): Ignore symbolic links.
30460
30461 2000-06-29  Jim Meyering  <meyering@lucent.com>
30462
30463         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
30464         for declaration of strcmp.
30465
30466         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
30467
30468         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
30469         Avoid warning by casting result to `char *' to remove `const'.
30470
30471 2000-06-28  Jim Meyering  <meyering@lucent.com>
30472
30473         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
30474         included by quotearg.c, for which we perform this test.  From
30475         Bruno Haible.
30476
30477 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30478
30479         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
30480         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
30481         <utmpx.h> exists, put readutmp.o into LIBOBJS.
30482
30483 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30484
30485         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
30486
30487 2000-06-26  Paul Eggert  <eggert@twinsun.com>
30488
30489         savedir now sets errno on failure and invokes xmalloc to get memory.
30490         Fix a couple of other minor bugs while we're at it.
30491
30492         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
30493         (NAMLEN): Remove macro.
30494         (malloc, realloc): Remove decls.
30495         (stpcpy): Likewise.
30496         ("xalloc.h"): Include.
30497         (NAME_SIZE_DEFAULT): New macro.
30498         (savedir): Use xmalloc / xrealloc to allocate memory.
30499         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
30500         Skip "" directory entries.
30501         Use strlen to calculate directory entry length, since the old method
30502         is rarely used these days and isn't worth supporting.
30503         Don't use a pointer after freeing it.
30504         Check for integer overflow when calculating allocation size.
30505         Use memcpy to copy entries, instead of stpcpy.
30506         Set errno properly when returning NULL.
30507         Check for readdir error.
30508
30509 2000-06-26  Jim Meyering  <meyering@lucent.com>
30510
30511         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
30512
30513 2000-06-25  Jim Meyering  <meyering@lucent.com>
30514
30515         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
30516         Linux header bug when _XOPEN_SOURCE is defined to 500.
30517
30518 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
30519
30520         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
30521         deficiency.
30522
30523 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
30524
30525         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
30526         Include xalloc.h.
30527         Don't include <stdlib.h>.  Don't declare malloc, realloc.
30528
30529 2000-06-24  Jim Meyering  <meyering@lucent.com>
30530
30531         * m4/strerror_r.m4: Revive this file -- to try out an experimental
30532         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
30533         for which strerror does return char*, but which lacks a conveniently
30534         accessible declaration of the function.  If the compile-test says
30535         strerror_r doesn't work, then resort to a `run'-test that works on
30536         BeOS and segfaults on DEC Unix.
30537
30538 2000-06-24  Jim Meyering  <meyering@lucent.com>
30539
30540         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
30541
30542 2000-06-23  Paul Eggert  <eggert@twinsun.com>
30543
30544         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
30545         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
30546
30547 2000-06-23  Paul Eggert  <eggert@twinsun.com>
30548
30549         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
30550         (mbrtowc, mbstate_t): Define substitutes if
30551         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
30552         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
30553         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
30554
30555 2000-06-23  Jim Meyering  <meyering@lucent.com>
30556
30557         * m4/afs.m4: Add missing AC_MSG_RESULT.
30558         Reported by Bruno Haible.
30559
30560         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
30561         Suggestion from Bruno Haible.
30562
30563 2000-06-23  Jim Meyering  <meyering@lucent.com>
30564
30565         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
30566
30567 2000-06-21  Jim Meyering  <meyering@lucent.com>
30568
30569         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
30570
30571 2000-06-21  Jim Meyering  <meyering@lucent.com>
30572
30573         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
30574         (noinst_HEADERS): Add getstr.h.
30575
30576         * lib/getline.c (getstr): Move into a separate file.
30577         * lib/getstr.c (getstr): New file, extracted from getline.c, with
30578         the following changes: new parameter, delim2; both delim[12]
30579         parameters have type `int', not `char'.  The latter would lose
30580         with 8-bit delimiters.
30581         * lib/getstr.h: New file.
30582
30583 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30584
30585         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
30586         than 1024, return a memory chunk of least possible size, instead
30587         of size PATH_MAX + 2. In the loop, increment the size proportionally.
30588         Use free/xmalloc instead of xrealloc to avoid copying for very long
30589         paths.
30590
30591 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30592
30593         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
30594         the empty string.
30595
30596 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
30597
30598         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
30599         address, not strdup.  Include <stdlib.h> and don't declare free().
30600
30601 2000-06-19  Jim Meyering  <meyering@lucent.com>
30602
30603         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
30604
30605 2000-06-18  Jim Meyering  <meyering@lucent.com>
30606
30607         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
30608
30609         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
30610         `checking whether...' message to be consistent with that of the
30611         lstat test.
30612
30613 2000-06-18  Jim Meyering  <meyering@lucent.com>
30614
30615         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
30616         Besides, these days every porting target provides a mkdir function.
30617
30618         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
30619         needed. (this snippet comes from src/system.h).
30620
30621 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
30622
30623         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
30624
30625 2000-06-15  Paul Eggert  <eggert@twinsun.com>
30626
30627         * lib/human.c (adjust_value): New function.
30628         (human_readable_inexact): Apply rounding style even when
30629         printing approximate values.
30630
30631 2000-06-14  Paul Eggert  <eggert@twinsun.com>
30632
30633         * lib/human.c (human_readable_inexact): Allow an input block
30634         size that is not a multiple of the output block size, and vice versa.
30635         Reported by Piergiorgio Sartor.
30636
30637 2000-06-14  Paul Eggert  <eggert@twinsun.com>
30638
30639         * lib/getdate.y (get_date): Apply relative times after time
30640         zone indicator, not before.  Reported by Todd A. Jacobs.
30641
30642 2000-06-13  Jim Meyering  <meyering@lucent.com>
30643
30644         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
30645
30646         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
30647
30648 2000-06-12  Paul Eggert  <eggert@twinsun.com>
30649
30650         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
30651
30652 2000-06-12  Jim Meyering  <meyering@lucent.com>
30653
30654         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
30655         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
30656         optional argument.
30657         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
30658         the optional argument, `lib'.
30659
30660 2000-06-08  Jim Meyering  <meyering@lucent.com>
30661
30662         * m4/largefile.m4: Remove file (now that it's part of autoconf).
30663
30664 2000-06-04  Paul Eggert  <eggert@twinsun.com>
30665
30666         Rewrite largefile configuration so that we don't need to run
30667         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
30668         AC_CANONICAL_HOST in configure.in -- jmm]
30669
30670         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
30671         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
30672         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
30673         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
30674         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
30675         All uses changed.
30676         Instead of inspecting the output of getconf, try to compile the
30677         test program without and with the macro definition.
30678         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
30679         for getconf.  Instead, check for the needed flags by compiling
30680         test programs.
30681
30682 2000-06-04  Paul Eggert  <eggert@twinsun.com>
30683
30684         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
30685
30686 2000-06-04  Jim Meyering  <meyering@lucent.com>
30687
30688         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
30689         SunOS 4.1.4 for which gid_t is an unsigned type.
30690
30691 2000-06-03  Jim Meyering  <meyering@lucent.com>
30692
30693         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
30694         now that autoconf requires that.
30695
30696         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
30697         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
30698         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
30699
30700 2000-06-03  Jim Meyering  <meyering@lucent.com>
30701
30702         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
30703
30704 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
30705
30706         * m4/glibc21.m4: New file.
30707         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
30708
30709 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
30710
30711         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
30712         newer, don't install charset.alias.
30713         * lib/config.charset: Change the Linux/glibc rules so they become empty
30714         on glibc-2.1 or newer.
30715
30716 2000-06-02  Jim Meyering  <meyering@lucent.com>
30717
30718         * lib/mountlist.c: Back out last change.  Instead, do this...
30719         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
30720         me_dummy member using the same `ignore'-testing code.
30721         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
30722         fs_type strings.
30723         From Mark D. Roth.
30724
30725 2000-05-29  Jim Meyering  <meyering@lucent.com>
30726
30727         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
30728         mounts with the `ignore' attribute.  Based on a patch from
30729         Mark D. Roth.
30730
30731 2000-05-28  Jim Meyering  <meyering@lucent.com>
30732
30733         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
30734         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
30735         * m4/stat.m4: Likewise.
30736         * m4/lstat.m4: Likewise.
30737         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
30738
30739         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
30740         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
30741
30742 2000-05-26  Jim Meyering  <meyering@lucent.com>
30743
30744         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
30745
30746 2000-05-24  Jim Meyering  <meyering@lucent.com>
30747
30748         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
30749         autoconf requires that.
30750         * m4/lib-check.m4: Likewise.
30751         * m4/jm-macros.m4: Likewise.
30752         * m4/strftime.m4: Likewise.
30753
30754         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
30755         AC_CHECK_DECLS, now that autoconf requires that.
30756
30757 2000-05-22  Jim Meyering  <meyering@lucent.com>
30758
30759         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
30760         * m4/lstat.m4: Likewise.
30761
30762 2000-05-22  Jim Meyering  <meyering@lucent.com>
30763
30764         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
30765
30766 2000-05-20  Jim Meyering  <meyering@lucent.com>
30767
30768         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
30769         (jm_PREREQ): Use it.
30770
30771 2000-05-18  Jim Meyering  <meyering@lucent.com>
30772
30773         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
30774         back, too, since it may have been modified by allocate_entry.
30775         (hash_delete): Rewrite to use neither the assignment operator
30776         nor the comma operator in an if-expression.
30777
30778 2000-05-15  Paul Eggert  <eggert@twinsun.com>
30779
30780         * lib/closeout.c:
30781         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
30782         Remove; no longer needed.
30783         "quotearg.h": Add include.
30784         (file_name): Do not bother to explicitly initialize to NULL; it's less
30785         efficient on some hosts.
30786         (close_stdout_status): Remove test as to whether stdout was already
30787         closed; it breaks for the case "echo x | sort >&-".
30788         Quote file name colons.
30789         Do not assume that _("write error") lacks format strings.
30790
30791 2000-05-15  Jim Meyering  <meyering@lucent.com>
30792
30793         * lib/version-etc.c (version_etc_copyright): Update the copyright
30794         string used in all --version output.
30795
30796 2000-05-14  Jim Meyering  <meyering@lucent.com>
30797
30798         * lib/closeout.c (close_stdout_set_file_name): New function.
30799         (close_stdout_status): Use new file-scoped global.
30800         Return right away if fstat says the stdout file descriptor is invalid.
30801         * lib/closeout.h (close_stdout_set_file_name): Declare.
30802
30803 2000-05-10  Jim Meyering  <meyering@lucent.com>
30804
30805         * lib/closeout.c [default_exit_status]: New file-scoped variable.
30806         (close_stdout_set_status): New function.
30807         * lib/closeout.h (close_stdout_set_status): Declare.
30808
30809 2000-05-09  Jim Meyering  <meyering@lucent.com>
30810
30811         * m4/gettext.m4: Rename this...
30812         * m4/libintl.m4: ...to this.
30813
30814 2000-05-08  Jim Meyering  <meyering@lucent.com>
30815
30816         * lib/long-options.c: Don't include closeout.h.
30817         (parse_long_options): Don't call close_stdout for --version.
30818
30819 2000-05-06  Paul Eggert  <eggert@twinsun.com>
30820
30821         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
30822         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
30823         2.1.3 bug.  This avoids a clash when files like regex.c define
30824         _GNU_SOURCE.
30825
30826 2000-05-06  Jim Meyering  <meyering@lucent.com>
30827
30828         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
30829         (AC_REPLACE_FUNCS): Add strnlen.
30830
30831         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
30832         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
30833
30834         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
30835         AC_SEARCH_LIBS call for nanosleep.
30836         (LIB_NANOSLEEP): Set and AC_SUBST.
30837
30838 2000-05-06  Jim Meyering  <meyering@lucent.com>
30839
30840         * lib/strnlen.c: Undefine __strnlen and strnlen.
30841         [!weak_alias]: Define __strnlen to strnlen.
30842
30843         * lib/atexit.c: New file, from libiberty.
30844
30845 2000-05-06  Jim Meyering  <meyering@lucent.com>
30846
30847         * lib/closeout.c (close_stdout_status): Also check for errors on the
30848         stderr stream.
30849
30850 2000-05-05  Jim Meyering  <meyering@lucent.com>
30851
30852         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
30853         AC_SEARCH_LIBS call for clock_gettime.
30854         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
30855
30856         * m4/search-libs.m4: Update from autoconf.
30857
30858         su doesn't work on Solaris 2.6.
30859         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
30860         <shadow.h>.  Reported by Dragos Harabor.
30861
30862 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
30863
30864         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
30865         memcpy instead of xmalloc, xrealloc, path_concat.
30866         (locale_charset): Treat empty environment variables as absent.
30867         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
30868
30869 2000-05-04  Jim Meyering  <meyering@lucent.com>
30870
30871         * lib/getopt.c: Update from glibc.
30872         * lib/obstack.c: Likewise.
30873         * lib/obstack.h: Likewise.
30874         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
30875         file
30876
30877         * lib/regex.h: Likewise.
30878         * lib/strndup.c: Likewise.
30879         * lib/strnlen.c: New file, from glibc.
30880
30881 2000-05-03  Jim Meyering  <meyering@lucent.com>
30882
30883         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
30884
30885 2000-05-02  Paul Eggert  <eggert@twinsun.com>
30886
30887         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
30888         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
30889         compile-time test, rather than inspecting host and OS, to
30890         decide whether to define _LARGEFILE_SOURCE.
30891
30892 2000-05-01  Jim Meyering  <meyering@lucent.com>
30893
30894         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
30895
30896         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
30897         Based on a patch from Bruno Haible.
30898
30899 2000-05-01  Jim Meyering  <meyering@lucent.com>
30900
30901         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
30902
30903 2000-04-29  Jim Meyering  <meyering@lucent.com>
30904
30905         * lib/path-concat.c: Declare strdup only if it's not defined.
30906         * lib/canon-host.c: Likewise.
30907
30908 2000-04-28  Jim Meyering  <meyering@lucent.com>
30909
30910         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
30911         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
30912         is included first, then limits.h is included by locale.h by libintl.h.
30913         From John David Anglin.
30914
30915 2000-04-25  Jim Meyering  <meyering@lucent.com>
30916
30917         * lib/makepath.c (S_IRWXUGO): Define.
30918         (make_path): Always perform explicit chmod if MODE specifies any
30919         of the `special' permission bits.  Prompted by a bug report against
30920         install from Mate Wierdl and Joost van Baal.
30921
30922 2000-04-18  Jim Meyering  <meyering@lucent.com>
30923
30924         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
30925         (jm_PREREQ): Use it.
30926
30927 2000-04-18  Jim Meyering  <meyering@lucent.com>
30928
30929         * lib/README: New file.
30930
30931         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
30932         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
30933
30934 2000-04-17  Jim Meyering  <meyering@lucent.com>
30935
30936         Get it right :-)
30937         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
30938         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
30939         Suggestion from Akim Demaille.
30940
30941 2000-04-17  Jim Meyering  <meyering@lucent.com>
30942
30943         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
30944         the definition of it to rpl_strftime also defined-away the system's
30945         declaration.
30946
30947 2000-04-15  Jim Meyering  <meyering@lucent.com>
30948
30949         Use `C' to denote so-called `contiguous' files, the same way
30950         that tar does.
30951         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
30952         (ftypelet): Use S_ISCTG.
30953         From Michael Deutschmann.
30954
30955 2000-04-14  Jim Meyering  <meyering@lucent.com>
30956
30957         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
30958         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
30959         clobbered.
30960
30961 2000-04-14  Jim Meyering  <meyering@lucent.com>
30962
30963         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
30964
30965 2000-04-13  Jim Meyering  <meyering@lucent.com>
30966
30967         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
30968         AH_VERBATIM to insert required #ifndef into config.h.in.
30969         Suggestion from Akim Demaille.
30970
30971 2000-04-12  Jim Meyering  <meyering@lucent.com>
30972
30973         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
30974         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
30975         Christian Krackowizer.
30976
30977         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
30978         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
30979         (AC_SYS_LARGEFILE): Require.
30980         (AM_C_PROTOTYPES): Require.
30981
30982 2000-04-08  Jim Meyering  <meyering@lucent.com>
30983
30984         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
30985         names don't conflict.  Reported by Eli Zaretskii.
30986
30987 2000-04-07  Jim Meyering  <meyering@lucent.com>
30988
30989         * lib/putenv.c: Move inclusion of errno.h so it follows that of
30990         sys/types.h, to work around system header problems on AIX 3.2.5.
30991         From Bruno Haible.
30992
30993 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
30994
30995         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
30996         bug.  Deal with the different error behavior of Irix iconv.
30997
30998 2000-04-05  Paul Eggert  <eggert@twinsun.com>
30999
31000         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
31001         IRIX if the installer said otherwise.
31002
31003 2000-04-05  Jim Meyering  <meyering@lucent.com>
31004
31005         Portability tweaks required for ultrix4.3.
31006         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
31007         (jm_CHECK_DECLS): Add getutent to the list of functions.
31008         (_jm_DECL_HEADERS): Add utmpx.h.
31009         From John David Anglin.
31010
31011         * m4/strftime.m4: Back out the 2000-04-02 change.
31012         Instead of that change, simply undefine putenv in the test program.
31013
31014 2000-04-05  Jim Meyering  <meyering@lucent.com>
31015
31016         Portability tweaks required for ultrix4.3.
31017         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
31018         getutent.
31019         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
31020         * lib/canon-host.c: Declare strdup.
31021         * lib/path-concat.c: Likewise.
31022         From John David Anglin.
31023
31024 2000-04-04  Jim Meyering  <meyering@lucent.com>
31025
31026         Be more DOS 8.3-friendly.
31027         * lib/ref-add.sin: Renamed from ref-add.sed.in.
31028         * lib/ref-del.sin: Renamed from ref-del.sed.in.
31029         * lib/Makefile.am: Reflect renaming.
31030         Reported by Eli Zaretskii.
31031
31032         Use a temporary file name that won't clash with `charset.alias'
31033         in the DOS 8.3 name space.
31034         * lib/Makefile.am (charset_tmp): Define.
31035         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
31036         (uninstall-local): Likewise.
31037         Reported by Eli Zaretskii.
31038
31039 2000-04-03  Jim Meyering  <meyering@lucent.com>
31040
31041         * m4/gettext.m4: Fix typo in comment.
31042
31043         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
31044         textutils/configure.in).  Suggestion from Paul Eggert.
31045         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
31046
31047 2000-04-02  Paul Eggert  <eggert@twinsun.com>
31048
31049         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
31050         variable in the shell rather than using putenv, which isn't
31051         portable.  This avoids the configure-time inter-test dependency
31052         on the potentially-renamed putenv function.
31053
31054 2000-03-30  Paul Eggert  <eggert@twinsun.com>
31055
31056         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
31057         before checking struct stat.st_blksize, so that
31058         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
31059
31060 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31061
31062         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
31063         since strftime.c uses HAVE_STRFTIME to decide whether to use
31064         the underlying strftime.
31065
31066 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31067
31068         * lib/time/strftime.c (my_strftime): Make sure we call the system
31069         strftime, not ourselves, when invoking the underlying strftime.
31070
31071 2000-03-24  Jim Meyering  <meyering@lucent.com>
31072
31073         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
31074         (charset_alias): Define.
31075         (install-exec-local): Factor out common code.
31076         (uninstall-local): Split lines longer than 80.
31077         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
31078         (SUFFIXES): Define.
31079         (.sed.in.sed): New rule.  Don't redirect directly to $@.
31080         (CLEANFILES): Add ref-add.sed and ref-del.sed.
31081
31082 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
31083
31084         * lib/config.charset: Output a line containing "Packages using this
31085         file".
31086         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
31087         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
31088         ref-del.sed): New rules.
31089
31090 2000-03-17  Jim Meyering  <meyering@lucent.com>
31091
31092         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
31093         Otherwise, include <strings.h>
31094
31095 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
31096
31097         * lib/unicodeio.c (utf8_wctomb): New function.
31098         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
31099         format instead of in UCS-4 with platform dependent endianness.
31100
31101 2000-03-10  Jim Meyering  <meyering@lucent.com>
31102
31103         * m4/lib-check.m4: Look for getspnam in -lgen, too.
31104         From Marco Franzen.
31105
31106 2000-03-07  Paul Eggert  <eggert@twinsun.com>
31107
31108         * lib/savedir.c (savedir): Work even if directory size is
31109         negative; this can happen with some screwy NFS configurations.
31110
31111 2000-03-06  Jim Meyering  <meyering@lucent.com>
31112
31113         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
31114         if it's NULL (because we ran out of memory).  From Bruno Haible.
31115
31116 2000-03-05  Jim Meyering  <meyering@lucent.com>
31117
31118         * lib/localcharset.c ("path-concat.h"): Include.
31119         (get_charset_aliases): Use path_concat instead of ANSI string
31120         concatenation.
31121
31122         * lib/unicodeio.h (PARAMS): Define.
31123         Use it to guard prototype.
31124
31125 2000-03-04  Jim Meyering  <meyering@lucent.com>
31126
31127         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
31128         for lib/localcharset.c.
31129
31130 2000-03-04  Jim Meyering  <meyering@lucent.com>
31131
31132         * lib/Makefile.am (install-exec-local): Create $(libdir) before
31133         installing into it.
31134         (uninstall-local): Uncomment this rule so `make distcheck' works
31135         once again.
31136
31137         * lib/unicodeio.c (<errno.h>): Include it.
31138         (errno): Declare if not defined.
31139
31140         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
31141
31142         * lib/config.charset: New version, incorporating remarks from a linux
31143         i18n mailing list.  From Bruno Haible.
31144
31145 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
31146
31147         * m4/codeset.m4: New file.
31148         * m4/iconv.m4: New file.
31149         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
31150
31151 2000-03-03  Jim Meyering  <meyering@lucent.com>
31152
31153         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
31154
31155 2000-03-02  Jim Meyering  <meyering@lucent.com>
31156
31157         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
31158         the messages come out on separate lines.
31159
31160         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
31161         rather than jm_CHECK_DECLARATIONS.
31162         * m4/decl.m4: Remove now-unused file.
31163
31164         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
31165         geteuid.
31166
31167 2000-03-02  Jim Meyering  <meyering@lucent.com>
31168
31169         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
31170
31171 2000-03-01  Jim Meyering  <meyering@lucent.com>
31172
31173         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
31174         * lib/unicodeio.c: Likewise.
31175
31176 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
31177
31178         * lib/config.charset: New file.
31179         * lib/localcharset.c: New file.
31180         * lib/unicodeio.h, lib/unicodeio.c: New files.
31181         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
31182         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
31183         (noinst_HEADERS): Add unicodeio.h.
31184         (all-local, install-exec-local, charset.alias): New targets.
31185
31186 2000-02-28  Paul Eggert  <eggert@twinsun.com>
31187
31188         * lib/quotearg.c (ALERT_CHAR): New macro.
31189         (quotearg_buffer_restyled): Use it.
31190
31191 2000-02-27  Jim Meyering  <meyering@lucent.com>
31192
31193         * m4/check-decl.m4: Add getenv to the list.
31194
31195 2000-02-27  Jim Meyering  <meyering@lucent.com>
31196
31197         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
31198         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
31199
31200         * lib/backupfile.c: Guard inclusion of stdlib.h with
31201         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
31202         Declare malloc if needed.
31203
31204         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
31205         `#ifndef HAVE_DECL..'
31206         now that autoconf always defines the HAVE_DECL_ symbols.
31207         * lib/human.c: Likewise.
31208         * lib/same.c: Likewise.
31209         * lib/strtoumax.c: Likewise.
31210
31211         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
31212         declaration check was not run.
31213         * lib/hash.c: Likewise.
31214         * lib/human.c: Likewise.
31215         * lib/same.c: Likewise.
31216         * lib/strtoumax.c: Likewise.
31217
31218         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
31219         `.', then first look up the entire `.'-containing string as a login
31220         name.
31221
31222 2000-02-23  Jim Meyering  <meyering@lucent.com>
31223
31224         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
31225         in place of my hack.
31226
31227 2000-02-18  Paul Eggert  <eggert@twinsun.com>
31228
31229         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
31230         (textint): New typedef.
31231         (parser_control): Member year changed from int to textint.
31232         All uses changed.
31233         (YYSTYPE): Removed; replaced by %union with int and textint members.
31234         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
31235         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
31236         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
31237         (tSNUMBER, tUNUMBER): Now of type <textintval>.
31238         (date, number, to_year): Use width of number in digits, not its value,
31239         to determine whether it's a 2-digit year, or a 2-digit time.
31240         (yylex): Store number of digits of numeric tokens.
31241         Reported by John Kendall.
31242
31243         (parser_control): Changed from struct parser_control to typedef (for
31244         consistency).  All uses changed.
31245
31246         (tID): Removed; not used.
31247         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
31248
31249 2000-02-14  Paul Eggert  <eggert@twinsun.com>
31250
31251         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
31252         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
31253
31254 2000-02-12  Jim Meyering  <meyering@lucent.com>
31255
31256         * lib/userspec.c (ISDIGIT): Define it.
31257         (isdigit): Remove definition.
31258         (is_number): Use ISDIGIT, not isdigit.
31259         <libintl.h>: Include.
31260         (_ and N_): Define.
31261         (parse_user_spec): Mark translatable strings.
31262
31263 2000-02-10  Jim Meyering  <meyering@lucent.com>
31264
31265         With these changes, nanosleep.[ch] are finally enough like the other
31266         lib/* replacement files to compile on a few more losing systems.
31267
31268         * lib/nanosleep.h: Don't include config.h.
31269         Remove prototype from declaration of nanosleep.
31270         (PARAMS): Remove now-unneeded definition.
31271         * lib/nanosleep.c: #undef nanosleep.
31272         (rpl_nanosleep): Rename from nanosleep.
31273
31274 2000-02-10  Jim Meyering  <meyering@lucent.com>
31275
31276         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
31277         gnu_nanosleep to rpl_nanosleep.
31278
31279 2000-02-09  Jim Meyering  <meyering@lucent.com>
31280
31281         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
31282         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
31283
31284 2000-02-08  Akim Demaille  <akim@epita.fr>
31285
31286         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
31287         `[' and `]' and remove uses of `changequote'.
31288         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
31289         (AC_SYS_LARGEFILE): Likewise.
31290         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
31291         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
31292         of changequote.
31293         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
31294         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
31295         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
31296         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
31297
31298 2000-02-05  Jim Meyering  <meyering@lucent.com>
31299
31300         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
31301         Remove explicit use of AC_HEADER_TIME.  It is required by
31302         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
31303         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
31304         in autoconf whereby the expansion of the latter ended up preceding
31305         the expansion of its prerequisite, AC_HEADER_TIME.
31306         Reported by Volker Borchert.
31307
31308 2000-02-03  Jim Meyering  <meyering@lucent.com>
31309
31310         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
31311
31312 2000-02-03  Jim Meyering  <meyering@lucent.com>
31313
31314         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
31315         rather than with `#if HAVE_UTMPNAME'.
31316
31317 2000-02-02  Jim Meyering  <meyering@lucent.com>
31318
31319         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
31320         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
31321         Reported by Eli Zaretskii.
31322
31323 2000-02-01  Jim Meyering  <meyering@lucent.com>
31324
31325         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
31326
31327 2000-01-31  Jim Meyering  <meyering@lucent.com>
31328
31329         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
31330         functions.  Add the time.h and sys/time.h headers along with the
31331         AC_REQUIRE'ment of AC_HEADER_TIME.
31332
31333 2000-01-31  Jim Meyering  <meyering@lucent.com>
31334
31335         * lib/nanosleep.h (nanosleep): Guard declaration with
31336         `#if ! HAVE_DECL_NANOSLEEP'.
31337         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
31338         the declaration in that vendor's sys/timers.h.
31339         Reported by Christian Krackowizer.
31340
31341         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
31342         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
31343         (ISPRINT): Likewise.
31344         Reported by Tom Tromey.
31345
31346 2000-01-30  Jim Meyering  <meyering@lucent.com>
31347
31348         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
31349
31350         * m4/prereq.m4 (utmp_includes): Define.
31351         Check for ut_user and ut_name members in both struct utmpx
31352         and struct utmp.
31353
31354 2000-01-30  Jim Meyering  <meyering@lucent.com>
31355
31356         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
31357         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
31358         header files where only utmpx.ut_user is declared.
31359
31360         * lib/readutmp.h (UT_USER): Define.
31361
31362 2000-01-29  Jim Meyering  <meyering@lucent.com>
31363
31364         * m4/lib-check.m4: New file containing library-related checks from
31365         fileutils and sh-utils (textutils had none).
31366
31367 2000-01-28  Jim Meyering  <meyering@lucent.com>
31368
31369         * m4/perl.m4: Change format of warning message to look more like that
31370         from the missing script.  Suggestion from François Pinard.
31371
31372 2000-01-25  Jim Meyering  <meyering@lucent.com>
31373
31374         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
31375         well as time.h in the compile check.
31376         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
31377         Fix typo in cross-compiling case: s/yes/no/.
31378
31379 2000-01-23  Jim Meyering  <meyering@lucent.com>
31380
31381         * m4/jm-macros.m4: Move df-related tests here from
31382         fileutils/configure.in
31383
31384         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
31385         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
31386
31387         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
31388         s/space/ac_fsusage_space/.
31389         (jm_FILE_SYSTEM_USAGE): Take two parameters.
31390
31391         * m4/ftruncate.m4: New file (derived from part of
31392         fileutils/configure.in).
31393         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
31394         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
31395
31396         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
31397         AC_SUBST these here, rather than just in sh-util/configure.in, so
31398         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
31399         all the same.
31400         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
31401         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
31402         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
31403         (AC_SUBST(POW_LIBM)): Likewise.
31404         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
31405
31406 2000-01-23  Jim Meyering  <meyering@lucent.com>
31407
31408         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
31409         obstack.c.
31410
31411 2000-01-22  Jim Meyering  <meyering@lucent.com>
31412
31413         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
31414
31415         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
31416
31417         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
31418         configure.in
31419         (AC_CHECK_HEADERS): Likewise for sh-utils.
31420         (AC_CHECK_HEADERS): Likewise for textutils.
31421         Merge the three lists of headers.
31422
31423         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
31424         from fileutils' configure.in.
31425
31426         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
31427         code. Moved tests into their own function (_jm_DECL_HEADERS) in
31428         check-decl.m4.
31429
31430         * m4/check-decl.m4: Use #if rather than #ifdef.
31431         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
31432         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
31433         (_jm_DECL_HEADERS): Define new function.
31434         (jm_CHECK_DECLARATIONS): Require it.
31435
31436 2000-01-22  Jim Meyering  <meyering@lucent.com>
31437
31438         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
31439         [! HAVE_DECL_STRTOULL]: Declare strtoull.
31440         Required for some AIX systems.  Reported by Christian Krackowizer.
31441         [TESTING] (main): New function.
31442
31443         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
31444         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
31445         letters.
31446
31447         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
31448         iswprint.
31449
31450         * lib/strverscmp.c (ISDIGIT): Define.
31451         (strverscmp): Use ISDIGIT, not isdigit.
31452
31453 2000-01-19  Jim Meyering  <meyering@lucent.com>
31454
31455         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
31456         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
31457         defines `struct timespec' in <sys/time.h>
31458
31459         * m4/c-bs-a.m4: Remove uses of changequote altogether.
31460         Thanks to Akim for explaining.
31461
31462 2000-01-17  Paul Eggert  <eggert@twinsun.com>
31463
31464         * lib/nanosleep.c (nanosleep):
31465         Don't use SA_INTERRUPT to decide whether to call sigaction, as
31466         POSIX.1 doesn't require SA_INTERRUPT and some systems
31467         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
31468         it's been part of POSIX.1 since day 1 (in 1988).
31469
31470 2000-01-17  Jim Meyering  <meyering@lucent.com>
31471
31472         * lib/interlock: Remove unused file.  Reported by François Pinard.
31473
31474 2000-01-16  Paul Eggert  <eggert@twinsun.com>
31475
31476         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
31477         alert, backslash, formfeed, and vertical tab unnecessarily in
31478         shell quoting style.
31479
31480 2000-01-16  Jim Meyering  <meyering@lucent.com>
31481
31482         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
31483         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
31484         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
31485         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
31486
31487 2000-01-16  Jim Meyering  <meyering@lucent.com>
31488
31489         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
31490         because the latter didn't work.
31491
31492 2000-01-15  Jim Meyering  <meyering@lucent.com>
31493
31494         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
31495         (AC_REPLACE_FUNCS): Add memcpy and memset.
31496         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
31497         Add strpbrk.
31498         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
31499
31500 2000-01-12  Jim Meyering  <meyering@lucent.com>
31501
31502         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
31503         (jm_PREREQ): Use it.
31504         (jm_PREREQ_READUTMP): New macro.
31505         (jm_PREREQ): Use it.
31506
31507 2000-01-11  Paul Eggert  <eggert@twinsun.com>
31508
31509         Quote multibyte characters correctly.
31510         * m4/c-bs-a.m4: New file.
31511         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
31512         (jm_PREREQ): Use it.
31513
31514 2000-01-11  Paul Eggert  <eggert@twinsun.com>
31515
31516         * m4/uintmax_t.m4: Port to autoconf 2.13.
31517
31518 2000-01-08  Jim Meyering  <meyering@ascend.com>
31519
31520         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
31521         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
31522
31523 2000-01-04  Jim Meyering  <meyering@ascend.com>
31524
31525         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
31526         jm_STRUCT_DIRENT_D_TYPE.
31527         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
31528         jm_STRUCT_DIRENT_D_INO.
31529         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
31530         jm_STRUCT_UTIMBUF.
31531         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
31532         renamings.
31533         * m4/utime.m4: Likewise.
31534
31535         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
31536         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
31537
31538 2000-01-03  Paul Eggert  <eggert@twinsun.com>
31539
31540         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
31541         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
31542
31543 2000-01-02  Jim Meyering  <meyering@ascend.com>
31544
31545         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
31546         remember if this is necessary.
31547
31548 1999-12-26  Jim Meyering  <meyering@ascend.com>
31549
31550         * m4/jm-macros.m4: Use it here.
31551         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
31552
31553 1999-12-23  Jim Meyering  <meyering@ascend.com>
31554
31555         * m4/jm-macros.m4: Check for clock_gettime (moved from
31556         fileutils/configure.in)
31557         Check for gettimeofday.
31558
31559 1999-12-20  Jim Meyering  <meyering@ascend.com>
31560
31561         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
31562         autoconf-2.14a-1999-12-20.
31563
31564 1999-12-19  Jim Meyering  <meyering@ascend.com>
31565
31566         * m4/lstat-slash.m4: New file.
31567         * m4/jm-macros.m4: Use the new macro:
31568         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31569
31570 1999-12-07  Jim Meyering  <meyering@ascend.com>
31571
31572         * m4/perl.m4: Require that File::Compare be available, too.
31573         Too many systems seem to lack it.
31574
31575         * m4/strftime.m4: Add checks for most of the cpp macros tested in
31576         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
31577
31578 1999-11-18  Paul Eggert  <eggert@twinsun.com>
31579
31580         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
31581         problem with the QNX 4.25 shell, which doesn't propagate exit
31582         status of failed commands inside shell assignments.
31583
31584 1999-11-17  Jim Meyering  <meyering@ascend.com>
31585
31586         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
31587
31588 1999-11-07  Jim Meyering  <meyering@ascend.com>
31589
31590         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
31591
31592 1999-11-06  Jim Meyering  <meyering@ascend.com>
31593
31594         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
31595         * m4/jm-macros.m4 (jm_MACROS): Use it here.
31596
31597 1999-11-05  Jim Meyering  <meyering@ascend.com>
31598
31599         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
31600         configure.in of textutils, fileutils, and sh-utils into this one
31601         (shared between those packages) file.
31602         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
31603         AC_STRUCT_ST_BLKSIZE.
31604
31605 1999-11-03  Jim Meyering  <meyering@ascend.com>
31606
31607         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
31608         of AC_CHECK_TYPE checks includes unistd.h.
31609         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
31610         Suggestion from Akim Demaille.
31611
31612 1999-10-30  Jim Meyering  <meyering@ascend.com>
31613
31614         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
31615         m4-quoted string.
31616         * m4/ls-mntd-fs.m4: Likewise.
31617         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
31618         * m4/jm-winsz1.m4: Likewise.
31619
31620         * m4/const.m4: Remove file, since the fix made it into the experimental
31621         version of autoconf.
31622         * m4/mktime.m4: Likewise.
31623
31624         * m4/check-type.m4: Remove file, now that the latest version of
31625         AC_CHECK_TYPE takes a third arg to specify additional #includes.
31626
31627         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
31628         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
31629         AC_CHECK_TYPE.
31630
31631 1999-10-04  Jim Meyering  <meyering@ascend.com>
31632
31633         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
31634
31635 1999-09-22  Paul Eggert  <eggert@twinsun.com>
31636
31637         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
31638         2.95.1 bug with HP-UX 10.20.
31639
31640 1999-09-17  Jim Meyering  <meyering@ascend.com>
31641
31642         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
31643         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
31644         due to missing strdup (against sh-utils-2.0).
31645
31646 1999-08-29  Jim Meyering  <meyering@ascend.com>
31647
31648         * m4/jm-macros.m4: Require jm_BISON.
31649         * m4/bison.m4: New file.
31650
31651 1999-08-17  Paul Eggert  <eggert@twinsun.com>
31652
31653         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
31654         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
31655
31656 1999-08-05  Jim Meyering  <meyering@ascend.com>
31657
31658         * m4/getline.m4: Rename test file from conftestdata to conftest.data
31659         to avoid conflicts with `conftest' on 8+3 filesystems.
31660         Suggestion from Eli Zaretskii.
31661
31662 1999-08-04  Jim Meyering  <meyering@ascend.com>
31663
31664         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
31665         fileutils and sh-utils (textutils's getline test was inadequate).
31666         (AM_FUNC_GETLINE): Run this test.
31667         (AC_CHECK_FUNCS): Check for getdelim.
31668         Reported by Bob Proulx.
31669
31670 1999-08-02  Jim Meyering  <meyering@ascend.com>
31671
31672         * m4/jm-macros.m4: Add a comment.
31673
31674 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31675
31676         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
31677         <inttypes.h> defines strtoumax as a macro (and not as a
31678         function).
31679
31680 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31681
31682         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
31683         that we can shift, multiply and divide unsigned long long
31684         values; Ultrix cc can't do it.
31685
31686 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31687
31688         * m4/mktime.m4: New file, which is a preview of what should appear
31689         in the next public autoconf release.
31690
31691 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31692
31693         * m4/lfs.m4: Remove this file.
31694         * m4/largefile.m4: New file.  It contains the old contents of
31695         lfs.m4, except that all names with prefix AC_LFS have been
31696         changed to use the prefix AC_SYS_LARGEFILE instead, to be
31697         compatible with future autoconf versions.  Also, some minor m4
31698         quoting problems have been fixed.
31699
31700 1999-08-01  Paul Eggert  <eggert@twinsun.com>
31701
31702         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
31703         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
31704         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
31705         and simplify the shell code.
31706
31707 1999-08-01  Jim Meyering  <meyering@ascend.com>
31708
31709         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
31710         m4.
31711
31712 1999-07-20  Jim Meyering  <meyering@ascend.com>
31713
31714         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
31715
31716 1999-07-15  Jim Meyering  <meyering@ascend.com>
31717
31718         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
31719
31720 1999-05-22  Jim Meyering  <meyering@ascend.com>
31721
31722         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
31723
31724 1999-05-20  Jim Meyering  <meyering@ascend.com>
31725
31726         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
31727         Add a colon after each `then' in case $4 is empty.
31728
31729 1999-05-16  Jim Meyering  <meyering@ascend.com>
31730
31731         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
31732
31733 1999-05-10  Jim Meyering  <meyering@ascend.com>
31734
31735         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
31736
31737         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
31738         AC_FUNC_MKTIME.
31739
31740 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
31741
31742         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
31743
31744 1999-05-04  Paul Eggert  <eggert@twinsun.com>
31745
31746         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
31747         not CPPFLAGS, so that linking works correctly in IRIX.
31748
31749 1999-04-30  Paul Eggert  <eggert@twinsun.com>
31750
31751         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
31752
31753 1999-04-20  Paul Eggert  <eggert@twinsun.com>
31754
31755         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
31756         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
31757         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
31758         jm_AC_TYPE_UNSIGNED_LONG_LONG.
31759         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
31760
31761         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
31762
31763 1999-04-20  Jim Meyering  <meyering@ascend.com>
31764
31765         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
31766         AC_REPLACE xstroull if necessary.  From Paul Eggert.
31767         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
31768
31769 1999-04-18  Jim Meyering  <meyering@ascend.com>
31770
31771         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
31772         * m4/jm-macros.m4: Use it.
31773
31774 1999-04-06  Jim Meyering  <meyering@ascend.com>
31775
31776         * m4/strftime.m4: Remove test for %f.
31777
31778 1999-03-29  Jim Meyering  <meyering@ascend.com>
31779
31780         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
31781         superset of the AC_TYPE_* checks in the textutils, fileutils,
31782         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
31783         AC_TYPE_PID_T.
31784
31785 1999-03-28  Jim Meyering  <meyering@ascend.com>
31786
31787         * m4/jm-macros.m4: Define GNU_PACKAGE here.
31788         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
31789         replaced e.g., in the *.sh files of the sh-utils.
31790
31791 1999-03-20  Jim Meyering  <meyering@ascend.com>
31792
31793         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
31794         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
31795         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
31796
31797 1999-03-19  Jim Meyering  <meyering@ascend.com>
31798
31799         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
31800
31801 1999-03-12  Jim Meyering  <meyering@ascend.com>
31802
31803         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
31804
31805 1999-03-07  Jim Meyering  <meyering@ascend.com>
31806
31807         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
31808         declared.
31809
31810 1999-02-17  Jim Meyering  <meyering@ascend.com>
31811
31812         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
31813         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
31814
31815 1999-02-07  Jim Meyering  <meyering@ascend.com>
31816
31817         * m4/group-member.m4: New file -- extracted from sh-utils'
31818         configure.in.
31819
31820         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
31821         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
31822
31823 1999-02-06  Jim Meyering  <meyering@ascend.com>
31824
31825         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
31826         * m4/fnmatch.m4: Likewise.
31827         * m4/getgroups.m4: Likewise.
31828         * m4/lstat.m4: Likewise.
31829         * m4/malloc.m4: Likewise.
31830         * m4/putenv.m4: Likewise.
31831         * m4/realloc.m4: Likewise.
31832         * m4/regex.m4: Likewise.
31833         * m4/stat.m4: Likewise.
31834         * m4/strftime.m4: Likewise.
31835         Suggestion from Alain Magloire.
31836
31837         * m4/chown.m4: Use `.$ac_objext', not `.o'.
31838         * m4/fnmatch.m4: Likewise.
31839         * m4/getgroups.m4: Likewise.
31840         * m4/getline.m4: Likewise.
31841         * m4/lstat.m4: Likewise.
31842         * m4/malloc.m4: Likewise.
31843         * m4/memcmp.m4: Likewise.
31844         * m4/putenv.m4: Likewise.
31845         * m4/realloc.m4: Likewise.
31846         * m4/regex.m4: Likewise.
31847         * m4/stat.m4: Likewise.
31848         * m4/strftime.m4: Likewise.
31849         Suggestion from Alain Magloire.
31850
31851         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
31852         an argument.
31853
31854         * m4/regex.m4: Add a run-time Test for proper operation of
31855         re_compile_pattern.
31856
31857 1999-01-31  Jim Meyering  <meyering@ascend.com>
31858
31859         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
31860
31861 1999-01-30  Jim Meyering  <meyering@ascend.com>
31862
31863         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
31864
31865         * m4/jm-mktime.m4: Make this a wrapper around the official
31866         AM_FUNC_MKTIME rather than my private copy, now that the official one
31867         is up to date.
31868         * m4/mktime.m4: Remove file.
31869
31870         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
31871         * m4/uptime.m4: Likewise.
31872         * m4/uintmax_t.m4: Likewise.
31873
31874 1999-01-28  Jim Meyering  <meyering@ascend.com>
31875
31876         * m4/jm-macros.m4: Use jm_AFS.
31877         * m4/afs.m4: New file (from fileutils' configure.in).
31878
31879         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
31880         * m4/chown.m4: Likewise.
31881         * m4/d-ino.m4: Likewise.
31882         * m4/d-type.m4: Likewise.
31883         * m4/fnmatch.m4: Likewise.
31884         * m4/getgroups.m4: Likewise.
31885         * m4/gettext.m4: Likewise.
31886         * m4/jm-mktime.m4: Likewise.
31887         * m4/jm-winsz2.m4: Likewise.
31888         * m4/lcmessage.m4: Likewise.
31889         * m4/ls-mntd-fs.m4: Likewise.
31890         * m4/malloc.m4: Likewise.
31891         * m4/memcmp.m4: Likewise.
31892         * m4/putenv.m4: Likewise.
31893         * m4/realloc.m4: Likewise.
31894         * m4/st_mtim.m4: Likewise.
31895         * m4/strftime.m4: Likewise.
31896
31897 1999-01-16  Jim Meyering  <meyering@ascend.com>
31898
31899         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
31900         (ARGMATCH_DIE_DECL): Define.
31901
31902 1999-01-12  Jim Meyering  <meyering@ascend.com>
31903
31904         * m4/Makefile.am.in: Rewrite to avoid using fmt.
31905         Reported by Lars Hecking.
31906
31907 1999-01-10  Jim Meyering  <meyering@ascend.com>
31908
31909         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
31910         gross kludge.
31911         * m4/inttypes_h.m4: Likewise.
31912         * m4/lstat.m4: Likewise.
31913         * m4/malloc.m4: Likewise.
31914         * m4/readdir.m4: Likewise.
31915         * m4/realloc.m4: Likewise.
31916         * m4/st_dm_mode.m4: Likewise.
31917         * m4/stat.m4: Likewise.
31918         * m4/utimbuf.m4: Likewise.
31919         * m4/utimes.m4: Likewise.
31920
31921         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
31922         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
31923         comments in config.h.in are meaningful.
31924
31925         * m4/jm-macros.m4: Require autoconf-2.13 here.
31926
31927         * m4/regex.m4: By default, don't use the included regex.c on systems
31928         with glibc 2.  Suggestion from Uli Drepper.
31929
31930 1999-01-02  Jim Meyering  <meyering@ascend.com>
31931
31932         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
31933
31934 1998-12-18  Jim Meyering  <meyering@ascend.com>
31935
31936         * m4/Makefile.am.in (Makefile.am): Simplify rule.
31937         Based on a suggestion from Lars Hecking.
31938
31939 1998-11-16  Paul Eggert  <eggert@twinsun.com>
31940
31941         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
31942
31943 1998-11-16  Jim Meyering  <meyering@ascend.com>
31944
31945         * m4/lfs.m4: Double-quote the `uname...` expression.
31946
31947 1998-11-14  Jim Meyering  <meyering@ascend.com>
31948
31949         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
31950         * m4/stat.m4: Likewise.
31951
31952 1998-11-03  Jim Meyering  <meyering@ascend.com>
31953
31954         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
31955         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
31956
31957 1998-10-18  Jim Meyering  <meyering@ascend.com>
31958
31959         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
31960
31961 1998-10-17  Jim Meyering  <meyering@ascend.com>
31962
31963         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
31964         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
31965         calls for those previously hard-coded headers.  Instead, take a new
31966         parameter.
31967         (jm_CHECK_DECLARATIONS): Reflect interface change.
31968         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
31969         (jm_CHECK_DECL_LOCALTIME_R): New macro.
31970
31971         * m4/mktime.m4: Test for spring-forward gap before long-running test.
31972
31973 1998-10-14  Jim Meyering  <meyering@ascend.com>
31974
31975         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
31976         instead of "TZ=America/Vancouver".  From Paul Eggert.
31977
31978 1998-10-11  Jim Meyering  <meyering@ascend.com>
31979
31980         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
31981         This adds a test for a recently added compatibility fix for mktime.c.
31982         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
31983
31984 1998-09-27  Jim Meyering  <meyering@ascend.com>
31985
31986         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
31987
31988         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
31989         ../configure.in, including a change from Gordon Matzigkeit to allow
31990         cross-compiling for the Hurd.
31991
31992         * m4/glibc.m4: New file/macro to test for the GNU C Library
31993         versions 1 and 2.  From Gordon Matzigkeit.
31994         Indent.
31995
31996 1998-09-21  Jim Meyering  <meyering@ascend.com>
31997
31998         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
31999
32000 1998-08-18  Paul Eggert  <eggert@twinsun.com>
32001
32002         Port nanosecond-resolution times to UnixWare 2.1.2 and
32003         pedantic Solaris 2.6.
32004
32005         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
32006         AC_STRUCT_ST_MTIM.
32007         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
32008         Generate name of ns member, instead of just 1 or undef.
32009         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
32010
32011 1998-08-15  Jim Meyering  <meyering@ascend.com>
32012
32013         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
32014         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
32015         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
32016         instead of jm_TYPE_SSIZE_T.
32017
32018 1998-08-12  Jim Meyering  <meyering@ascend.com>
32019
32020         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
32021
32022 1998-08-02  Jim Meyering  <meyering@ascend.com>
32023
32024         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
32025         in acconfig.h manually.
32026
32027 1998-07-31  Paul Eggert  <eggert@twinsun.com>
32028
32029         * m4/st_mtim.m4: New file.
32030
32031 1998-07-28  Jim Meyering  <meyering@ascend.com>
32032
32033         * m4/utimes.m4: Undef stat.
32034
32035 1998-07-25  Jim Meyering  <meyering@ascend.com>
32036
32037         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
32038         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
32039
32040 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
32041
32042         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
32043         uid and gid actually remain unchanged.
32044
32045 1998-07-07  Jim Meyering  <meyering@ascend.com>
32046
32047         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
32048
32049 1998-07-04  Jim Meyering  <meyering@ascend.com>
32050
32051         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
32052         to prove that this macro can be used in packages without regex.c.
32053
32054 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
32055
32056         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
32057         is to be used.
32058
32059 1998-07-03  Jim Meyering  <meyering@ascend.com>
32060
32061         * m4/gettext.m4: Add -lintl if it's found to be necessary.
32062
32063         * m4/gettext.m4: New file -- from gettext-0.10.35.
32064         * m4/lcmessage.m4: Likewise.
32065         * m4/progtest.m4: Likewise.
32066
32067         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
32068         * m4/jm-macros.m4: Require the new macro.
32069
32070 1998-06-29  Jim Meyering  <meyering@ascend.com>
32071
32072         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
32073         for the definition of NGROUPS (used in a system header included
32074         by sys/mount.h).
32075
32076 1998-06-28  Jim Meyering  <meyering@ascend.com>
32077
32078         * m4/ls-mntd-fs.m4: New file.
32079         * m4/fstypename.m4: New file.
32080
32081         * m4/jm-macros.m4: Require the new macro.
32082         * m4/jm-glibc-io.m4: New file.
32083
32084 1998-05-19  Jim Meyering  <meyering@ascend.com>
32085
32086         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
32087         * m4/lchown.m4: New file.
32088
32089         * m4/Makefile.am.in: New file.
32090         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
32091
32092 1998-05-14  Jim Meyering  <meyering@ascend.com>
32093
32094         * m4/Makefile.am (EXTRA_DIST): Add them.
32095         * m4/jm-macros.m4: New file.
32096         * m4/utimbuf.m4: New file.
32097
32098 1998-05-12  Jim Meyering  <meyering@ascend.com>
32099
32100         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
32101
32102 1998-05-11  Jim Meyering  <meyering@ascend.com>
32103
32104         * m4/isc-posix.m4: New file.
32105
32106 1998-05-10  Jim Meyering  <meyering@ascend.com>