Take care of IN_LIBINTL situation.
[gnulib.git] / ChangeLog
1 2007-03-29  Bruno Haible  <bruno@clisp.org>
2
3         * lib/vasprintf.c [IN_LIBINTL]: Include different specification file.
4         * lib/asprintf.c [IN_LIBINTL]: Likewise.
5
6 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
7
8         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
9         try to remove a parent directory if the child couldn't be removed
10         (except for the first rmdir, which could fail because the child
11         doesn't exist).  Problem reported by Jeff Blaine in
12         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
13
14 2007-03-28  Bruno Haible  <bruno@clisp.org>
15
16         * lib/striconveh.c (utf8conv_carefully): New function.
17         (mem_cd_iconveh_internal): Invoke it.
18
19 2007-03-28  Bruno Haible  <bruno@clisp.org>
20
21         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
22         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
23         input.
24         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
25         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
26         unistr/u8-uctomb.
27
28 2007-03-28  Bruno Haible  <bruno@clisp.org>
29
30         * modules/unistr/u8-mbtoucr: New file.
31         * lib/unistr/u8-mbtoucr.c: New file.
32         * modules/unistr/u16-mbtoucr: New file.
33         * lib/unistr/u16-mbtoucr.c: New file.
34         * modules/unistr/u16-mbtoucr: New file.
35         * lib/unistr/u16-mbtoucr.c: New file.
36         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
37
38 2007-03-27  Simon Josefsson  <simon@josefsson.org>
39             Bruno Haible  <bruno@clisp.org>
40
41         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
42         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
43         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
44
45         * m4/stdio_h.m4: Add stubs for vasprintf too.
46
47         * modules/stdio: Support vasprintf in sed command.
48
49         * modules/vasprintf: Depend on stdio for prototypes.  Remove
50         vasprintf.h.  Add stdio module indicator.
51
52         * lib/stdio_.h: Declare asprintf and vasprintf, based on
53         vasprintf.h.
54
55         * lib/vasprintf.h: File removed.
56
57         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
58         * lib/vasprintf.c: Ditto.
59         * lib/xvasprintf.c: Ditto.
60         * tests/test-vasprintf-posix.c: Ditto.
61         * tests/test-vasprintf.c: Ditto.
62
63 2007-03-27  Bruno Haible  <bruno@clisp.org>
64
65         Make vasnprintf multithread-safe.
66         * lib/vasnprintf.c (decimal_point_char): New function.
67         (VASNPRINTF): Use it.
68         Suggested by Simon Josefsson.
69
70 2007-03-27  Eric Blake  <ebb9@byu.net>
71
72         Support sub-second birthtime on cygwin.
73         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
74         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
75         (get_stat_birthtime): Also work with st_birthtim.
76
77 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
78
79         * lib/stat-time.h (USE_BIRTHTIME): Remove.
80         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
81         (get_stat_birthtime_ns): Do not try to use "spare" fields.
82         (get_stat_birthtime_ns): Simplify compile-time tests.
83         (get_stat_birthtime): Change the API to look like
84         get_stat_mtime etc., except return a negative tv_nsec on error.
85         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
86         Don't check for "spare" fields.
87         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
88         or for struct stat.st_birthtime, as these tests aren't used.
89         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
90
91 2007-03-27  Bruno Haible  <bruno@clisp.org>
92
93         * lib/stat-time.h: Include <sys/stat.h>.
94
95 2007-03-27  James Youngman  <jay@gnu.org>
96
97         * lib/stat-time.h (get_stat_birthtime): New function for
98           retrieving st_birthtime as provided by UFS2 (hence *BSD).
99         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
100           and its variants.
101         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
102         * modules/stat-time-test: New file.
103         * tests/test-stat-time.c: New test, devised by Bruno Haible.
104
105 2007-03-26  Bruno Haible  <bruno@clisp.org>
106
107         Better support of signalling NaNs.
108         * lib/atanl.c: Include isnanl.h.
109         (atanl): Perform test for NaN at the beginning of the function and
110         through a call to isnanl.
111         * lib/cosl.c: Include isnanl.h.
112         (cosl): Perform test for NaN at the beginning of the function and
113         through a call to isnanl.
114         * lib/ldexpl.c: Include isnanl.h.
115         (ldexpl): Perform test for NaN through a call to isnanl.
116         * lib/logl.c: Include isnanl.h.
117         (logl): Perform test for NaN at the beginning of the function and
118         through a call to isnanl.
119         * lib/sinl.c: Include isnanl.h.
120         (sinl): Perform test for NaN at the beginning of the function and
121         through a call to isnanl.
122         * lib/sqrtl.c: Include isnanl.h.
123         (sqrtl): Perform test for NaN at the beginning of the function and
124         through a call to isnanl.
125         * lib/tanl.c: Include isnanl.h.
126         (tanl): Perform test for NaN at the beginning of the function and
127         through a call to isnanl.
128         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
129         * modules/mathl (Depends-on): Add isnanl.
130
131 2007-03-26  Eric Blake  <ebb9@byu.net>
132
133         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
134         regression in logic sense of previous patch.
135
136 2007-03-26  Bruno Haible  <bruno@clisp.org>
137
138         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
139         unportable shell command "if ! ...".
140         Reported by Ralf Wildenhues.
141
142 2007-03-25  Bruno Haible  <bruno@clisp.org>
143
144         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
145         <sysexits.h> file, and only add EX_CONFIG.
146         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
147         absolute file name and whether it is sufficient. Substitute also
148         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
149         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
150         ABSOLUTE_SYSEXITS_H into sysexits.h.
151
152 2007-03-25  Bruno Haible  <bruno@clisp.org>
153
154         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
155         hints is NULL.
156
157 2007-03-25  Bruno Haible  <bruno@clisp.org>
158
159         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
160         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
161
162 2007-03-25  Bruno Haible  <bruno@clisp.org>
163
164         * lib/vasnprintf.c: Include langinfo.h.
165         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
166         multithread-safe.
167         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
168         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
169         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
170         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
171         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
172         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
173         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
174         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
175         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
176         Reported by Simon Josefsson.
177
178 2007-03-25  Bruno Haible  <bruno@clisp.org>
179
180         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
181         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
182         * modules/vasnprintf (Depends-on): Add stdint.
183
184 2007-03-25  Bruno Haible  <bruno@clisp.org>
185
186         * modules/fpieee: New file.
187         * m4/fpieee.m4: New file.
188         * modules/isnan-nolibm (Depends-on): Add fpieee.
189         * modules/isnanl-nolibm (Depends-on): Add fpieee.
190         * modules/isnanl (Depends-on): Add fpieee.
191
192 2007-03-25  Bruno Haible  <bruno@clisp.org>
193
194         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
195
196 2007-03-25  Bruno Haible  <bruno@clisp.org>
197
198         Avoid test failures on IRIX 6.5.
199         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
200         (main): Use it.
201         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
202         macros.
203         (main): Use them.
204
205 2007-03-25  Bruno Haible  <bruno@clisp.org>
206
207         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
208         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
209         exists but doesn't work.
210         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
211         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
212         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
213         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
214
215 2007-03-25  Bruno Haible  <bruno@clisp.org>
216
217         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
218         returns inf. Needed on IRIX 6.5.
219
220 2007-03-25  Bruno Haible  <bruno@clisp.org>
221
222         * tests/test-frexpl.c: Include isnanl-nolibm.h.
223         (main): Use isnanl instead of x != x idiom.
224         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
225
226         * tests/test-frexp.c: Include isnan.h.
227         (main): Use isnan instead of x != x idiom.
228         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
229
230 2007-03-25  Bruno Haible  <bruno@clisp.org>
231
232         * tests/test-frexp.c (NaN): New function/macro.
233         (main): Use it instead of 0.0 / 0.0.
234         * tests/test-isnan.c (NaN): New function/macro.
235         (main): Use it instead of 0.0 / 0.0.
236         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
237         (test_function): Use it instead of 0.0 / 0.0.
238         * tests/test-vasprintf-posix.c (NaN): New function/macro.
239         (test_function): Use it instead of 0.0 / 0.0.
240         * tests/test-snprintf-posix.h (NaN): New function/macro.
241         (test_function): Use it instead of 0.0 / 0.0.
242         * tests/test-sprintf-posix.h (NaN): New function/macro.
243         (test_function): Use it instead of 0.0 / 0.0.
244         * tests/test-fprintf-posix.h (NaN): New function/macro.
245         (test_function): Use it instead of 0.0 / 0.0.
246         * tests/test-printf-posix.h (NaN): New function/macro.
247         (test_function): Use it instead of 0.0 / 0.0.
248
249         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
250
251 2007-03-25  Bruno Haible  <bruno@clisp.org>
252
253         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
254
255 2007-03-25  Bruno Haible  <bruno@clisp.org>
256
257         * lib/regexec.c (merge_state_with_log): Make static.
258
259 2007-03-25  Bruno Haible  <bruno@clisp.org>
260
261         * lib/trigl.c (kernel_rem_pio2): Make static.
262
263 2007-03-25  Bruno Haible  <bruno@clisp.org>
264
265         * lib/sincosl.c (sincosl_table): Make static.
266
267 2007-03-25  Bruno Haible  <bruno@clisp.org>
268
269         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
270         if the compiler does not support C99.
271
272 2007-03-25  Bruno Haible  <bruno@clisp.org>
273
274         * modules/time (Makefile.am): Ensure all rule action lines start with a
275         tab.
276
277 2007-03-24  Bruno Haible  <bruno@clisp.org>
278
279         * modules/tsearch-tests: New file.
280         * tests/test-tsearch.sh: New file.
281         * tests/test-tsearch.c: New file, mostly copied from glibc.
282
283         * modules/search-tests: New file.
284         * tests/test-search.c: New file.
285
286         * modules/search: New file.
287         * lib/search_.h: New file, incorporating lib/tsearch.h.
288         * m4/search_h.m4: New file.
289         * lib/tsearch.h: Remove file.
290         * lib/tsearch.c: Include search.h instead of tsearch.h.
291         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
292         HAVE_TSEARCH.
293         * modules/tsearch (Files): Remove lib/tsearch.h.
294         (Depends-on): Add search.
295         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
296         (Include): Change tsearch.h into search.h.
297
298 2007-03-24  Bruno Haible  <bruno@clisp.org>
299
300         * modules/fpucw: New file.
301         * lib/fpucw.h: New file.
302         * lib/frexp.c: Include fpucw.h.
303         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
304         (FUNC): Use them.
305         * lib/printf-frexp.c: Include fpucw.h.
306         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
307         (FUNC): Use them.
308         * lib/vasnprintf.c: Include fpucw.h.
309         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
310         'long double' calculations.
311         * tests/test-frexpl.c: Include fpucw.h.
312         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
313         * tests/test-printf-frexpl.c: Include fpucw.h.
314         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
315         * modules/frexpl (Depends-on): Add fpucw.
316         * modules/printf-frexpl (Depends-on): Likewise.
317         * modules/fprintf-posix (Depends-on): Likewise.
318         * modules/snprintf-posix (Depends-on): Likewise.
319         * modules/sprintf-posix (Depends-on): Likewise.
320         * modules/vasnprintf-posix (Depends-on): Likewise.
321         * modules/vasprintf-posix (Depends-on): Likewise.
322         * modules/vfprintf-posix (Depends-on): Likewise.
323         * modules/vsnprintf-posix (Depends-on): Likewise.
324         * modules/vsprintf-posix (Depends-on): Likewise.
325         * modules/frexpl-tests (Depends-on): Likewise.
326         * modules/printf-frexpl-tests (Depends-on): Likewise.
327
328 2007-03-24  Bruno Haible  <bruno@clisp.org>
329
330         * lib/float+.h: New file.
331         * lib/isnan.c: Include float+.h.
332         (SIZE): New macro.
333         (FUNC): Compare only SIZE bytes of the value.
334         * lib/vasnprintf.c: Include float+.h.
335         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
336         SIZEOF_LDBL or SIZEOF_DBL bytes.
337         * modules/isnan-nolibm (Files): Add lib/float+.h.
338         * modules/isnanl-nolibm (Files): Add lib/float+.h.
339         * modules/isnanl (Files): Add lib/float+.h.
340         * modules/vasnprintf (Files): Add lib/float+.h.
341
342 2007-03-24  Bruno Haible  <bruno@clisp.org>
343
344         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
345         include isnanl-nolibm.h.
346
347 2007-03-24  Bruno Haible  <bruno@clisp.org>
348
349         * tests/test-read-file.c (main): Don't produce spurious output for
350         expected situations. Make the test fail if it encountered unexpected
351         results.
352
353 2007-03-24  Bruno Haible  <bruno@clisp.org>
354
355         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
356         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
357
358 2007-03-24  Bruno Haible  <bruno@clisp.org>
359
360         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
361
362 2007-03-24  Bruno Haible  <bruno@clisp.org>
363
364         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
365         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
366
367         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
368         * modules/utf8-ucs4: Turn into a symbolic link to module
369         unistr/u8-mbtouc.
370
371         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
372         utf8-ucs4-unsafe.
373         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
374         unistr/u8-mbtouc-unsafe.
375
376         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
377         * modules/utf16-ucs4: Turn into a symbolic link to module
378         unistr/u16-mbtouc.
379
380         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
381         utf16-ucs4-unsafe.
382         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
383         unistr/u16-mbtouc-unsafe.
384
385         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
386         * modules/ucs4-utf8: Turn into a symbolic link to module
387         unistr/u8-ubtomb.
388
389         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
390         * modules/ucs4-utf16: Turn into a symbolic link to module
391         unistr/u16-ubtomb.
392
393 2007-03-24  Bruno Haible  <bruno@clisp.org>
394
395         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
396         Enable the function only if HAVE_INLINE.
397         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
398         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
399         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
400         Enable the function only if HAVE_INLINE.
401         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
402         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
403         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
404         Enable the function only if HAVE_INLINE.
405         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
406         Enable the function only if HAVE_INLINE.
407         * modules/utf8-ucs4: Update.
408         * modules/utf8-ucs4-unsafe: Update.
409         * modules/utf16-ucs4: Update.
410         * modules/utf16-ucs4-unsafe: Update.
411         * modules/ucs4-utf8: Update.
412         * modules/ucs4-utf16: Update.
413
414 2007-03-24  Bruno Haible  <bruno@clisp.org>
415
416         * lib/utf8-ucs4.h: Remove file.
417         * lib/utf8-ucs4-unsafe.h: Remove file.
418         * lib/utf16-ucs4.h: Remove file.
419         * lib/utf16-ucs4-unsafe.h: Remove file.
420         * lib/ucs4-utf8.h: Remove file.
421         * lib/ucs4-utf16.h: Remove file.
422         * lib/unistr.h: Include their previous contents.
423         * m4/utf-ucs4.m4: Remove file.
424         * m4/ucs4-utf.m4: Remove file.
425         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
426         (Depends-on): Add unistr/base.
427         (configure.ac): Remove gl_UTF_UCS4.
428         (Makefile.am): Update.
429         (Include): Change to unistr.h.
430         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
431         (Depends-on): Add unistr/base.
432         (configure.ac): Remove gl_UTF_UCS4.
433         (Makefile.am): Update.
434         (Include): Change to unistr.h.
435         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
436         (Depends-on): Add unistr/base.
437         (configure.ac): Remove gl_UTF_UCS4.
438         (Makefile.am): Update.
439         (Include): Change to unistr.h.
440         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
441         (Depends-on): Add unistr/base.
442         (configure.ac): Remove gl_UTF_UCS4.
443         (Makefile.am): Update.
444         (Include): Change to unistr.h.
445         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
446         (Depends-on): Add unistr/base.
447         (configure.ac): Remove gl_UCS4_UTF.
448         (Makefile.am): Update.
449         (Include): Change to unistr.h.
450         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
451         (Depends-on): Add unistr/base.
452         (configure.ac): Remove gl_UCS4_UTF.
453         (Makefile.am): Update.
454         (Include): Change to unistr.h.
455         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
456         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
457         utf8-ucs4-unsafe.h.
458         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
459         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
460         utf16-ucs4-unsafe.h.
461         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
462         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
463         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
464         * lib/unistr/u8-strchr.c: Likewise.
465         * lib/unistr/u8-strrchr.c: Likewise.
466         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
467         * lib/unistr/u16-strchr.c: Likewise.
468         * lib/unistr/u16-strrchr.c: Likewise.
469         * lib/striconveh.c: Update.
470         * lib/linebreak.c: Update.
471
472 2007-03-24  Bruno Haible  <bruno@clisp.org>
473
474         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
475         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
476
477 2007-03-22  Bruno Haible  <bruno@clisp.org>
478
479         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
480
481 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
482
483         * MODULES.html.sh (File system functions): New module write-any-file.
484         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
485         * m4/write-any-file.m4: New files.
486
487 2007-03-23  Eric Blake  <ebb9@byu.net>
488
489         * gnulib-tool: Rearrange space-tab sequences, since some editors
490         like to eat them.
491
492 2007-03-23  Eric Blake  <ebb9@byu.net>
493
494         * lib/version-etc.c (version_etc_va): Update license wording to
495         be more concise.  Recommended by Richard Stallman.
496
497 2007-03-22  Bruno Haible  <bruno@clisp.org>
498
499         * lib/poll.c (MSG_PEEK): New fallback definition.
500
501 2007-03-22  Bruno Haible  <bruno@clisp.org>
502
503         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
504         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
505         (main): Update.
506         Fixes a compilation error on BeOS.
507
508 2007-03-22  Bruno Haible  <bruno@clisp.org>
509
510         * modules/frexpl-tests: New file.
511         * tests/test-frexpl.c: New file.
512
513         * modules/frexpl: New file.
514         * m4/frexpl.m4: New file.
515         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
516         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
517         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
518         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
519         (Depends-on): Add frexpl. Remove isnanl-nolibm.
520         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
521
522 2007-03-22  Bruno Haible  <bruno@clisp.org>
523
524         * lib/frexpl.c: Share code with lib/frexp.c.
525         * modules/mathl (Files): Add lib/frexp.c.
526         (Depends-on): Add isnanl-nolibm.
527
528 2007-03-22  Bruno Haible  <bruno@clisp.org>
529
530         * modules/printf-frexp (Files): Add m4/frexp.m4.
531         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
532         only if the found frexp function actually works.
533
534 2007-03-22  Bruno Haible  <bruno@clisp.org>
535
536         * lib/frexp.c: Remove older implementation that uses divisions.
537
538 2007-03-21  Bruno Haible  <bruno@clisp.org>
539
540         * modules/frexp-tests: New file.
541         * tests/test-frexp.c: New file.
542
543         * modules/frexp: New file.
544         * lib/frexp.c: New file.
545         * m4/frexp.m4: New file.
546         * lib/math_.h (frexp): New declaration.
547         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
548         REPLACE_FREXP.
549         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
550
551 2007-03-21  Bruno Haible  <bruno@clisp.org>
552
553         * modules/isnanl-tests: New file.
554         * tests/test-isnanl.c: New file.
555
556         * modules/isnanl: New file.
557         * lib/isnanl.h: New file.
558         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
559         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
560         gl_FUNC_ISNANL_WORKS.
561         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
562         New macros.
563
564 2007-03-21  Bruno Haible  <bruno@clisp.org>
565
566         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
567         lib/isnanl.h.
568         (Include): Update.
569         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
570         * lib/vasnprintf.c: Update.
571         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
572         tests/test-isnanl.h, remove tests/test-isnanl.c.
573         (Makefile.am): Update.
574         * tests/test-isnanl-nolibm.c: New file.
575         * tests/test-isnanl.h: New file.
576         * tests/test-isnanl.c: Remove file.
577
578 2007-03-21  Jim Meyering  <jim@meyering.net>
579
580         When trying to open ".", treat ESTALE like EACCES.
581         * lib/savewd.c (savewd_save): Resort to forking not just upon
582         failure with EACCES, but also when errno is ESTALE.
583
584 2007-03-20  Bruno Haible  <bruno@clisp.org>
585
586         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
587         Needed on AIX 5.1. Reported by Matthew Woehlke.
588
589 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
590
591         Suggestions by Bruno Haible:
592         * lib/acl-internal.h: Include "gettext.h" rather than rolling
593         our own.
594         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
595         * modules/acl (Depends-on): Add gettext.
596
597 2007-03-19  Bruno Haible  <bruno@clisp.org>
598
599         * modules/iconvme: Remove file.
600         * lib/iconvme.h: Remove file.
601         * lib/iconvme.c: Remove file.
602         * m4/iconvme.m4: Remove file.
603
604 2007-03-19  Bruno Haible  <bruno@clisp.org>
605
606         * doc/relocatable-maint.texi: Break long shell script line.
607         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
608
609 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
610
611         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
612         handle file_has_acl.
613         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
614         * lib/acl.c: Move header inclusions and related macro defns into
615         lib/acl-internal.h.
616         (S_ISLNK): Remove defn, since that's now done for us.
617         (file_has_acl): Move to lib/file-has-acl.c.
618         Call acl_trivial if available.  This is the crucial part of the fix.
619         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
620         shared within the library.  Rewrite a bit, partly to make it compatible
621         with the GNU coding style.
622         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
623         Remove unnecessary double-quotes.
624         Don't test for acl_to_text; the build will catch that.
625         Replace acl_entries if it doesn't exist and it is needed.
626         Check for -lsec and acl_trivial (as used on Solaris 10).
627         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
628         lib/file-has-acl.c.
629         (Depends-on): Add sys_stat, for S_ISLNK.
630
631 2007-03-19  Ben Pfaff  <blp@gnu.org>
632
633         * doc/gnulib.texi: Fix typos.
634         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
635
636 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
637
638         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
639         If size is zero here, buf must be zero.
640
641 2007-03-19  Simon Josefsson  <simon@josefsson.org>
642
643         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
644         <bruno@clisp.org>.
645
646 2007-03-18  Bruno Haible  <bruno@clisp.org>
647
648         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
649         Suggested by Eric Blake.
650
651 2007-03-18  Ben Pfaff  <blp@gnu.org>
652
653         * doc/relocatable.texi: Recommend using as prefix a directory
654         that does not exist and will never be created.  Based on
655         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
656         and others.
657
658 2007-03-17  Bruno Haible  <bruno@clisp.org>
659
660         * lib/fchownat.c: Include lchown.h.
661
662 2007-03-17  Bruno Haible  <bruno@clisp.org>
663
664         Fix endless loop when the given allocated size was > INT_MAX.
665         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
666         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
667         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
668         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
669         * lib/sprintf.c (sprintf): Likewise.
670
671 2007-03-17  Bruno Haible  <bruno@clisp.org>
672
673         * tests/test-argp-2.sh (func_compare): Output a context diff.
674
675 2007-03-17  Bruno Haible  <bruno@clisp.org>
676
677         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
678         locale's decimal-point character.
679
680 2007-03-17  Bruno Haible  <bruno@clisp.org>
681
682         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
683         before comparing it. Needed because on some platforms (e.g. x86) a
684         'long double' occupies less bytes than sizeof (long double).
685
686 2007-03-17  Bruno Haible  <bruno@clisp.org>
687
688         * tests/test-crc.c (main): Make printf statements 64-bit clean.
689         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
690         * tests/test-getaddrinfo.c (simple): Likewise.
691         * tests/test-read-file.c (main): Likewise.
692
693 2007-03-17  Bruno Haible  <bruno@clisp.org>
694
695         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
696
697 2007-03-17  Bruno Haible  <bruno@clisp.org>
698
699         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
700         unused variable.
701
702 2007-03-17  Bruno Haible  <bruno@clisp.org>
703
704         * tests/test-c-strcasecmp.c: Include c-strcase.h.
705         * tests/test-c-strncasecmp.c: Likewise.
706
707 2007-03-17  Bruno Haible  <bruno@clisp.org>
708
709         * modules/stdlib (Depends-on): Add unistd.
710         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
711         Needed for MacOS X 10.3.
712
713 2007-03-17  Bruno Haible  <bruno@clisp.org>
714
715         * lib/unistr/u-strdup.h: Include <stdlib.h>.
716
717 2007-03-17  Bruno Haible  <bruno@clisp.org>
718
719         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
720
721 2007-03-17  Bruno Haible  <bruno@clisp.org>
722
723         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
724         to reflect files copied from gnulib (with or without modifications).
725         Suggested by Jim Meyering.
726
727 2007-03-17  Eric Blake  <ebb9@byu.net>
728
729         * NEWS: Document stdlib change from 2007-02-18.
730
731 2007-03-17  Jim Meyering  <jim@meyering.net>
732
733         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
734         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
735         someone uses a name containing shell meta-characters.
736         Reported by Alfred M. Szmidt.
737
738         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
739
740 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
741
742         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
743         and copy gettext configuration files only if configure.ac contains
744         a use of AM_GNU_GETTEXT_VERSION.
745
746 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
747
748         * build-aux/bootstrap (gnulib_name): New variable.
749         (gnulib_tool_options): Use it.
750
751 2007-03-13  Simon Josefsson  <simon@josefsson.org>
752
753         * tests/test-des.c: Use new namespace.
754
755 2007-03-15  Bruno Haible  <bruno@clisp.org>
756
757         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
758         Reported by James Youngman <jay@gnu.org>.
759
760 2007-03-15  Bruno Haible  <bruno@clisp.org>
761
762         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
763         declared prototype. Needed with cc on OSF/1 5.1.
764
765 2007-03-15  Bruno Haible  <bruno@clisp.org>
766
767         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
768         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
769         (struct gl_list_implementation): Add dispose_fn argument to the
770         'create_empty', 'create' methods.
771         (struct gl_list_impl_base): Add field 'dispose_fn'.
772         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
773         argument.
774         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
775         dispose_fn argument.
776         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
777         dispose_fn on the dropped values.
778         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
779         dispose_fn argument.
780         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
781         dropped values.
782         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
783         (gl_tree_remove_node): Call dispose_fn on the dropped value.
784         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
785         (gl_tree_remove_node): Call dispose_fn on the dropped value.
786         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
787         argument.
788         (gl_tree_list_free): Call dispose_fn on the dropped values.
789         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
790         the dropped values.
791         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
792         Add dispose_fn argument.
793         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
794         Call dispose_fn on the dropped values.
795         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
796         Add dispose_fn argument.
797         (gl_sublist_create): Initialize the 'dispose_fn' field.
798         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
799         * tests/test-array_list.c (main): Update.
800         * tests/test-carray_list.c (main): Update.
801         * tests/test-avltree_list.c (main): Update.
802         * tests/test-rbtree_list.c (main): Update.
803         * tests/test-avltreehash_list.c (main): Update.
804         * tests/test-rbtreehash_list.c (main): Update.
805         * tests/test-linked_list.c (main): Update.
806         * tests/test-linkedhash_list.c (main): Update.
807         * tests/test-array_oset.c (main): Update.
808
809 2007-03-15  Bruno Haible  <bruno@clisp.org>
810
811         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
812         (gl_oset_create_empty): Add dispose_fn argument.
813         (struct gl_oset_implementation): Add dispose_fn argument to
814         'create_empty' method.
815         (struct gl_oset_impl_base): Add dispose_fn field.
816         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
817         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
818         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
819         values.
820         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
821         (gl_tree_oset_free): Call dispose_fn on the dropped values.
822         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
823         dropped value.
824         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
825         dropped value.
826         * tests/test-array_oset.c (main): Update.
827         * tests/test-avltree_oset.c (main): Update.
828         * tests/test-rbtree_oset.c (main): Update.
829         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
830
831 2007-03-13  Bruno Haible  <bruno@clisp.org>
832
833         * tests/test-stdbool.c (i): Update after last patch.
834
835 2007-03-12  Bruno Haible  <bruno@clisp.org>
836
837         * lib/quotearg.c: Include <wctype.h> early, before the definition of
838         the iswprint macro. Needed on Solaris 2.5.1.
839
840 2007-03-12  Bruno Haible  <bruno@clisp.org>
841
842         * tests/test-printf-frexp.c (main): Declare x as volatile.
843
844 2007-03-12  Simon Josefsson  <simon@josefsson.org>
845
846         * doc/gnulib.texi (Build robot for gnulib): New section.
847
848 2007-03-12  Jim Meyering  <jim@meyering.net>
849
850         * build-aux/bootstrap: New file.
851         * build-aux/bootstrap.conf: New file, from coreutils.
852
853 2007-03-11  Bruno Haible  <bruno@clisp.org>
854
855         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
856
857 2007-03-12  Simon Josefsson  <simon@josefsson.org>
858
859         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
860         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
861         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
862
863 2007-03-11  Bruno Haible  <bruno@clisp.org>
864
865         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
866         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
867
868 2007-03-11  Bruno Haible  <bruno@clisp.org>
869
870         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
871         formula. Needed for SunPRO C 5.0.
872
873 2007-03-11  Bruno Haible  <bruno@clisp.org>
874
875         * modules/long-options (Depends-on): Add getopt.
876
877 2007-03-11  Bruno Haible  <bruno@clisp.org>
878
879         * modules/modechange (Depends-on): Add stdbool.
880
881 2007-03-11  Bruno Haible  <bruno@clisp.org>
882
883         * modules/i-ring (Depends-on): Add stdbool.
884
885 2007-03-11  Bruno Haible  <bruno@clisp.org>
886
887         * modules/gc-des (Depends-on): Add stdbool.
888
889 2007-03-11  Bruno Haible  <bruno@clisp.org>
890
891         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
892
893 2007-03-11  Bruno Haible  <bruno@clisp.org>
894
895         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
896
897 2007-03-11  Bruno Haible  <bruno@clisp.org>
898
899         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
900
901 2007-03-11  Bruno Haible  <bruno@clisp.org>
902
903         * lib/vasnprintf.c (sprintf): Undefine.
904
905 2007-03-11  Bruno Haible  <bruno@clisp.org>
906
907         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
908         initializers in SunPRO C and Compaq C compilers.
909
910 2007-03-11  Bruno Haible  <bruno@clisp.org>
911
912         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
913         decrementing code ANSI C compliant.
914
915 2007-03-11  Bruno Haible  <bruno@clisp.org>
916
917         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
918         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
919
920 2007-03-11  Bruno Haible  <bruno@clisp.org>
921
922         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
923         <stdbool.h> substitute doesn't pass.
924
925 2007-03-11  Bruno Haible  <bruno@clisp.org>
926
927         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
928
929 2007-03-11  Bruno Haible  <bruno@clisp.org>
930
931         * gnulib-tool (func_create_megatestdir): Create also an autobuild
932         script, for submission to autobuild.josefsson.org.
933
934 2007-03-10  Bruno Haible  <bruno@clisp.org>
935
936         * modules/canonicalize-lgpl-tests: New file.
937         * tests/test-canonicalize-lgpl.sh: New file.
938         * tests/test-canonicalize-lgpl.c: New file.
939
940         * modules/c-strcase-tests: New file.
941         * tests/test-c-strcase.sh: New file.
942         * tests/test-c-strcasecmp.c: New file.
943         * tests/test-c-strncasecmp.c: New file.
944
945         * modules/atexit-tests: New file.
946         * tests/test-atexit.sh: New file.
947         * tests/test-atexit.c: New file.
948
949 2007-03-10  Bruno Haible  <bruno@clisp.org>
950
951         * tests/test-binary-io.sh: Use temporary filenames that are not so
952         likely to clash with those of other tests (in a parallel make).
953         * tests/test-binary-io.c: Likewise.
954
955 2007-03-10  Bruno Haible  <bruno@clisp.org>
956
957         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
958         fallback; use #error instead.
959         Suggested by Simon Josefsson.
960
961 2007-03-10  Bruno Haible  <bruno@clisp.org>
962
963         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
964         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
965         first and the last.
966
967 2007-03-10  Bruno Haible  <bruno@clisp.org>
968
969         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
970
971 2007-03-10  Bruno Haible  <bruno@clisp.org>
972
973         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
974         "make distcheck".
975         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
976         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
977         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
978
979 2007-03-10  Bruno Haible  <bruno@clisp.org>
980
981         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
982         variable.
983         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
984         variable.
985
986 2007-03-09  Eric Blake  <ebb9@byu.net>
987         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
988
989         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
990         types are not being provided by gnulib.
991         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
992         types are supported.
993
994 2007-03-10  Bruno Haible  <bruno@clisp.org>
995
996         * lib/stdio_.h (__attribute__): New macro.
997         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
998         vsprintf): Specify __attribute__ __format__ for GCC.
999         Suggested by Eric Blake.
1000
1001 2007-03-09  Bruno Haible  <bruno@clisp.org>
1002
1003         * modules/printf-posix-tests: New file.
1004         * tests/test-printf-posix.sh: New file.
1005         * tests/test-printf-posix.c: New file.
1006
1007         * modules/printf-posix: New file.
1008         * lib/printf.c: New file.
1009         * m4/printf-posix-rpl.m4: New file.
1010         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
1011         REPLACE_PRINTF.
1012         * lib/stdio_.h (printf): New declaration.
1013         (format, __format__, ____printf____, ____scanf____, ____strftime____,
1014         ____strfmon____): New macros.
1015         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
1016         REPLACE_PRINTF.
1017
1018 2007-03-09  Bruno Haible  <bruno@clisp.org>
1019
1020         * tests/test-vasnprintf-posix2.sh: New file.
1021         * tests/test-vasnprintf-posix2.c: New file.
1022         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
1023         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
1024         (Makefile.am): Activate test-vasnprintf-posix2.sh.
1025
1026         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
1027         a locale dependent decimal point, rather than always '.'.
1028
1029 2007-03-09  Eric Blake  <ebb9@byu.net>
1030
1031         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
1032         spite of platforms like Tandem/NSK that define it to -1.
1033
1034 2007-03-08  Bruno Haible  <bruno@clisp.org>
1035
1036         * modules/vprintf-posix-tests: New file.
1037         * tests/test-vprintf-posix.sh: New file.
1038         * tests/test-vprintf-posix.c: New file.
1039         * tests/test-printf-posix.h: New file.
1040
1041         * modules/vprintf-posix: New file.
1042         * lib/vprintf.c: New file.
1043         * m4/vprintf-posix.m4: New file.
1044         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
1045         REPLACE_VPRINTF.
1046         * lib/stdio_.h (vprintf): New declaration.
1047         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
1048         REPLACE_VPRINTF.
1049
1050 2007-03-08  Bruno Haible  <bruno@clisp.org>
1051
1052         * modules/fprintf-posix-tests: New file.
1053         * tests/test-fprintf-posix.sh: New file.
1054         * tests/test-fprintf-posix.c: New file.
1055
1056         * modules/fprintf-posix: New file.
1057         * lib/fprintf.c: New file.
1058         * m4/fprintf-posix.m4: New file.
1059         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
1060         REPLACE_FPRINTF.
1061         * lib/stdio_.h (fprintf): New declaration.
1062         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
1063         REPLACE_FPRINTF.
1064
1065 2007-03-08  Bruno Haible  <bruno@clisp.org>
1066
1067         * modules/vfprintf-posix-tests: New file.
1068         * tests/test-vfprintf-posix.sh: New file.
1069         * tests/test-vfprintf-posix.c: New file.
1070         * tests/test-fprintf-posix.h: New file.
1071         * tests/test-fprintf-posix.out: New file.
1072
1073         * modules/vfprintf-posix: New file.
1074         * lib/vfprintf.c: New file.
1075         * m4/vfprintf-posix.m4: New file.
1076         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
1077         REPLACE_VFPRINTF.
1078         * lib/stdio_.h (vfprintf): New declaration.
1079         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
1080         REPLACE_VFPRINTF.
1081
1082 2007-03-08  Bruno Haible  <bruno@clisp.org>
1083
1084         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
1085
1086 2007-03-08  Bruno Haible  <bruno@clisp.org>
1087
1088         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
1089         instead of 'expr' invocations.
1090         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1091         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1092         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1093         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1094         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1095         Suggested by Paul Eggert.
1096
1097 2007-03-08  Bruno Haible  <bruno@clisp.org>
1098
1099         * modules/fseterr-tests: New file.
1100         * tests/test-fseterr.c: New file.
1101
1102         * modules/fseterr: New file.
1103         * lib/fseterr.h: New file.
1104         * lib/fseterr.c: New file.
1105
1106 2007-03-08  Bruno Haible  <bruno@clisp.org>
1107
1108         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
1109         * lib/getopt_.h: Likewise.
1110         * lib/mbswidth.h: Likewise.
1111         * lib/setenv.h: Likewise.
1112         * lib/vasnprintf.h: Likewise.
1113         * lib/vasprintf.h: Likewise.
1114         * lib/verror.h: Likewise.
1115         * lib/xsetenv.h: Likewise.
1116         * lib/xvasprintf.h: Likewise.
1117
1118 2007-03-08  Jim Meyering  <jim@meyering.net>
1119
1120         * users.txt: Add parted.
1121
1122         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
1123
1124 2007-03-07  Bruno Haible  <bruno@clisp.org>
1125
1126         * m4/printf.m4: Make the shell script snippets copy&pastable.
1127
1128 2007-03-02  Bruno Haible  <bruno@clisp.org>
1129
1130         * lib/netinet_in_.h: New file.
1131         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
1132         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
1133         * modules/netinet_in (Files): Add lib/netinet_in_.h.
1134         (Depends-on): Add absolute-header.
1135         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
1136         into netinet/in.h.
1137
1138 2007-03-03  Bruno Haible  <bruno@clisp.org>
1139
1140         * lib/sys_select_.h: New file.
1141         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
1142         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
1143         * modules/sys_select (Files): Add lib/sys_select_.h.
1144         (Depends-on): Add absolute-header.
1145         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
1146         into sys/select.h.
1147
1148 2007-03-02  Bruno Haible  <bruno@clisp.org>
1149
1150         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
1151         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
1152         values.
1153         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
1154         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
1155         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
1156         * modules/sys_socket (Depends-on): Add absolute-header.
1157         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
1158         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
1159         (Include): Remove requirement of inclusion of <sys/types.h>.
1160
1161 2007-03-02  Bruno Haible  <bruno@clisp.org>
1162
1163         * lib/byteswap_.h (bswap_32): Fix formula.
1164
1165 2007-03-06  Bruno Haible  <bruno@clisp.org>
1166
1167         * modules/sprintf-posix-tests: New file.
1168         * tests/test-sprintf-posix.c: New file.
1169
1170         * modules/sprintf-posix: New file.
1171         * lib/sprintf.c: New file.
1172         * m4/sprintf-posix.m4: New file.
1173         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
1174         REPLACE_SPRINTF.
1175         * lib/stdio_.h (sprintf): New declaration.
1176         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
1177         REPLACE_SPRINTF.
1178
1179 2007-03-06  Bruno Haible  <bruno@clisp.org>
1180
1181         * modules/vsprintf-posix-tests: New file.
1182         * tests/test-vsprintf-posix.c: New file.
1183         * tests/test-sprintf-posix.h: New file.
1184
1185         * modules/vsprintf-posix: New file.
1186         * lib/vsprintf.c: New file.
1187         * m4/vsprintf-posix.m4: New file.
1188         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
1189         REPLACE_VSPRINTF.
1190         * lib/stdio_.h (vsprintf): New declaration.
1191         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
1192         REPLACE_VSPRINTF.
1193
1194 2007-03-06  Bruno Haible  <bruno@clisp.org>
1195
1196         * modules/vsnprintf (Depend-on): Remove minmax.
1197
1198 2007-03-06  Bruno Haible  <bruno@clisp.org>
1199
1200         * modules/snprintf-posix-tests: New file.
1201         * tests/test-snprintf-posix.c: New file.
1202
1203         * modules/snprintf-posix: New file.
1204         * m4/snprintf-posix.m4: New file.
1205         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
1206         gl_FUNC_SNPRINTF.
1207         (gl_FUNC_SNPRINTF): Invoke it.
1208         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
1209         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
1210         is set.
1211         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
1212
1213 2007-03-06  Bruno Haible  <bruno@clisp.org>
1214
1215         * modules/vsnprintf-posix-tests: New file.
1216         * tests/test-vsnprintf-posix.c: New file.
1217         * tests/test-snprintf-posix.h: New file.
1218
1219         * modules/vsnprintf-posix: New file.
1220         * m4/vsnprintf-posix.m4: New file.
1221         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
1222         gl_FUNC_VSNPRINTF.
1223         (gl_FUNC_VSNPRINTF): Invoke it.
1224         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
1225         * lib/stdio_.h (vsnprintf): Define as a replacement if
1226         REPLACE_VSNPRINTF is set.
1227         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
1228
1229 2007-03-06  Bruno Haible  <bruno@clisp.org>
1230
1231         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
1232         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
1233
1234 2007-03-06  Bruno Haible  <bruno@clisp.org>
1235
1236         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
1237         (asinl): Declare also if HAVE_DECL_ASINL is set.
1238         (atanl): Declare also if HAVE_DECL_ATANL is set.
1239         (ceill): Declare also if HAVE_DECL_CEILL is set.
1240         (cosl): Declare also if HAVE_DECL_COSL is set.
1241         (expl): Declare also if HAVE_DECL_EXPL is set.
1242         (floorl): Declare also if HAVE_DECL_FLOORL is set.
1243         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
1244         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
1245         (logl): Declare also if HAVE_DECL_LOGL is set.
1246         (sinl): Declare also if HAVE_DECL_SINL is set.
1247         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
1248         (tanl): Declare also if HAVE_DECL_TANL is set.
1249         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
1250         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
1251         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
1252         declaration of frexpl, ldexpl.
1253         * modules/printf-frexpl (Depends-on): Add math.
1254         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
1255
1256 2007-03-05  Bruno Haible  <bruno@clisp.org>
1257
1258         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
1259         frexpl and ldexpl are declared.
1260         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
1261
1262 2007-03-05  Bruno Haible  <bruno@clisp.org>
1263
1264         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
1265         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
1266
1267 2007-03-05  Bruno Haible  <bruno@clisp.org>
1268
1269         * lib/stdio_.h: Include <stddef.h>.
1270
1271 2007-03-05  Bruno Haible  <bruno@clisp.org>
1272
1273         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
1274
1275 2007-03-05  Bruno Haible  <bruno@clisp.org>
1276
1277         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
1278         NetBSD 4, from Ralf Wildenhues.
1279
1280 2007-03-04  Bruno Haible  <bruno@clisp.org>
1281
1282         * lib/vasprintf.h: Update #if logic for the case when the functions
1283         exist but are overridden.
1284
1285 2007-03-04  Bruno Haible  <bruno@clisp.org>
1286
1287         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
1288         implementations: glibc-2.4 and MacOS X 10.3.
1289         * tests/test-vasnprintf-posix.c (test_function): Test also the case
1290         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
1291         * tests/test-vasprintf-posix.c (test_function): Likewise.
1292
1293 2007-03-04  Bruno Haible  <bruno@clisp.org>
1294
1295         * modules/vasprintf-posix-tests: New file.
1296         * tests/test-vasprintf-posix.c: New file.
1297
1298         * modules/vasprintf-posix: New file.
1299         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
1300         defined.
1301         * m4/vasprintf-posix.m4: New file.
1302         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
1303         gl_FUNC_VASPRINTF.
1304         (gl_FUNC_VASPRINTF): Invoke it.
1305         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
1306         here.
1307         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
1308
1309 2007-03-04  Bruno Haible  <bruno@clisp.org>
1310
1311         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
1312         REPLACE_GETTIMEOFDAY.
1313         * modules/sys_time (Makefile.am): Likewise.
1314         * m4/sys_time_h.m4: Likewise.
1315         * m4/gettimeofday.m4: Likewise.
1316
1317 2007-03-04  Bruno Haible  <bruno@clisp.org>
1318
1319         * modules/vasnprintf-posix-tests: New file.
1320         * tests/test-vasnprintf-posix.c: New file.
1321
1322         * modules/vasnprintf-posix: New file.
1323         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
1324         printf-frexpl.h.
1325         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
1326         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
1327         REPLACE_VASNPRINTF is defined.
1328         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
1329         gl_FUNC_VASNPRINTF.
1330         (gl_FUNC_VASNPRINTF): Invoke it.
1331         * m4/vasnprintf-posix.m4: New file.
1332         * m4/printf.m4: New file.
1333
1334 2007-03-04  Bruno Haible  <bruno@clisp.org>
1335
1336         Compile progreloc.c only if --enable-relocatable is specified.
1337         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
1338         if --enable-relocatable was specified.
1339         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
1340         lib_SOURCES.
1341
1342 2007-03-04  Jim Meyering  <jim@meyering.net>
1343
1344         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
1345         Use it consistently, rather than enumerating errno constants.
1346
1347 2007-03-04  Bruno Haible  <bruno@clisp.org>
1348
1349         * modules/xvasprintf-tests: New file.
1350         * tests/test-xvasprintf.c: New file.
1351
1352         * modules/vasprintf-tests: New file.
1353         * tests/test-vasprintf.c: New file.
1354
1355         * modules/vasnprintf-tests: New file.
1356         * tests/test-vasnprintf.c: New file.
1357
1358         * modules/vsnprintf-tests: New file.
1359         * tests/test-vsnprintf.c: New file.
1360
1361         * modules/snprintf-tests: New file.
1362         * tests/test-snprintf.c: New file.
1363
1364 2007-03-04  Bruno Haible  <bruno@clisp.org>
1365
1366         Compile relocatable.c only if --enable-relocatable is specified.
1367         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
1368         gl_RELOCATABLE_LIBRARY.
1369         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
1370         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
1371         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
1372         gl_RELOCATABLE_LIBRARY.
1373         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
1374         (Makefile.am): Remove lib_SOURCES.
1375         * modules/relocatable-lib-lgpl (configure.ac): Invoke
1376         gl_RELOCATABLE_LIBRARY.
1377         (Makefile.am): Remove lib_SOURCES.
1378         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
1379         always.
1380         * modules/relocatable-prog-wrapper (configure.ac): Invoke
1381         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
1382
1383 2007-03-04  Bruno Haible  <bruno@clisp.org>
1384
1385         * modules/argmatch-tests: New file.
1386         * tests/test-argmatch.c: New file.
1387
1388         * tests/test-allocsa.c (main): Halve the number of loop runs.
1389
1390         * modules/alloca-opt-tests: New file.
1391         * tests/test-alloca-opt.c: New file.
1392
1393 2007-03-04  Jim Meyering  <jim@meyering.net>
1394
1395         Work around difference between Linux ACLs and Solaris 10 ZFS.
1396         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
1397         for EINVAL.
1398
1399 2007-03-03  Bruno Haible  <bruno@clisp.org>
1400
1401         * modules/relocatable-prog (Depends-on): Add back progreloc's
1402         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
1403
1404 2007-03-03  Bruno Haible  <bruno@clisp.org>
1405
1406         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
1407         * modules/relocatable-lib: New file.
1408
1409 2007-03-03  Bruno Haible  <bruno@clisp.org>
1410
1411         * modules/relocatable-prog: Renamed from modules/relocatable.
1412         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
1413
1414 2007-03-03  Bruno Haible  <bruno@clisp.org>
1415
1416         * modules/relocatable-script (Files): Add doc/relocatable.texi,
1417         m4/relocatable-lib.m4.
1418         (Depends-on): Remove 'relocatable'.
1419         (configure.ac): Add gl_RELOCATABLE_NOP.
1420
1421 2007-03-03  Bruno Haible  <bruno@clisp.org>
1422
1423         * modules/relocatable-prog-wrapper: New file.
1424         * modules/relocatable (Depends-on): Add it. Remove all other
1425         dependencies except progname.
1426         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
1427
1428         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
1429         (gl_FUNC_STRERROR): Nop.
1430         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
1431
1432         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
1433         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
1434
1435         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
1436         (gl_FUNC_READLINK): Update.
1437
1438         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
1439
1440 2007-03-03  Bruno Haible  <bruno@clisp.org>
1441
1442         * lib/xreadlink.c: Include <unistd.h> unconditionally.
1443         * modules/xreadlink (Depends-on): Add unistd.
1444         * modules/xreadlink-with-size (Depends-on): Likewise.
1445
1446 2007-03-03  Bruno Haible  <bruno@clisp.org>
1447
1448         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
1449         extracted from gt_FUNC_SETENV.
1450         (gt_FUNC_SETENV): Remove macro.
1451         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
1452         remove gt_FUNC_SETENV.
1453
1454 2007-03-03  Bruno Haible  <bruno@clisp.org>
1455
1456         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
1457         ENABLE_RELOCATABLE here.
1458         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
1459
1460 2007-03-03  Bruno Haible  <bruno@clisp.org>
1461
1462         * modules/rbtreehash-list-tests (Depends-on): Add progname.
1463         * tests/test-rbtreehash_list.c: Include progname.h.
1464         (main): Call set_program_name.
1465
1466         * modules/rbtree-oset-tests (Depends-on): Add progname.
1467         * tests/test-rbtree_oset.c: Include progname.h.
1468         (main): Call set_program_name.
1469
1470         * modules/rbtree-list-tests (Depends-on): Add progname.
1471         * tests/test-rbtree_list.c: Include progname.h.
1472         (main): Call set_program_name.
1473
1474         * modules/linked-list-tests (Depends-on): Add progname.
1475         * tests/test-linked_list.c: Include progname.h.
1476         (main): Call set_program_name.
1477
1478 2007-03-03  Bruno Haible  <bruno@clisp.org>
1479
1480         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
1481         All uses of __restrict changed to _Restrict_.
1482         * lib/glob_.h (__restrict): Remove macro.
1483
1484 2007-03-02  Bruno Haible  <bruno@clisp.org>
1485
1486         * modules/gettext (configure.ac): Require gettext infrastructure
1487         from version 0.16.1.
1488
1489 2007-03-02  Bruno Haible  <bruno@clisp.org>
1490
1491         * modules/linkedhash-list-tests (Depends-on): Add progname.
1492         * tests/test-linkedhash_list.c: Include progname.h.
1493         (main): Call set_program_name.
1494
1495         * modules/carray-list-tests (Depends-on): Add progname.
1496         * tests/test-carray_list.c: Include progname.h.
1497         (main): Call set_program_name.
1498
1499         * modules/avltreehash-list-tests (Depends-on): Add progname.
1500         * tests/test-avltreehash_list.c: Include progname.h.
1501         (main): Call set_program_name.
1502
1503         * modules/avltree-oset-tests (Depends-on): Add progname.
1504         * tests/test-avltree_oset.c: Include progname.h.
1505         (main): Call set_program_name.
1506
1507         * modules/avltree-list-tests (Depends-on): Add progname.
1508         * tests/test-avltree_list.c: Include progname.h.
1509         (main): Call set_program_name.
1510
1511         * modules/array-oset-tests (Depends-on): Add progname.
1512         * tests/test-array_oset.c: Include progname.h.
1513         (main): Call set_program_name.
1514
1515         * modules/array-list-tests (Depends-on): Add progname.
1516         * tests/test-array_list.c: Include progname.h.
1517         (main): Call set_program_name.
1518
1519         * modules/argp-tests (Depends-on): Add progname.
1520         * tests/test-argp.c: Include argp.h first. Include progname.h.
1521         (main): Call set_program_name.
1522
1523 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
1524
1525         * doc/gnulib-tool.texi (Initial import): Reword description of
1526         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
1527         limited effect even if defined after the first system include.
1528
1529 2007-03-01  Bruno Haible  <bruno@clisp.org>
1530
1531         * build-aux/config.libpath: Update to libtool-1.5.22.
1532         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
1533
1534 2007-03-01  Bruno Haible  <bruno@clisp.org>
1535
1536         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
1537         foo_CFLAGS.
1538         Reported by Ralf Wildenhues.
1539
1540 2007-03-01  Bruno Haible  <bruno@clisp.org>
1541
1542         * build-aux/install-reloc: Remove object files left over by some
1543         compilers.
1544         Reported by Ralf Wildenhues.
1545
1546 2007-03-01  Bruno Haible  <bruno@clisp.org>
1547
1548         * build-aux/install-reloc: Break long lines.
1549
1550 2007-03-01  Bruno Haible  <bruno@clisp.org>
1551
1552         * doc/relocatable.texi: Document that it may not work on OpenBSD.
1553         Reported by Ralf Wildenhues.
1554
1555 2007-03-01  Bruno Haible  <bruno@clisp.org>
1556
1557         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
1558         include ordering constraints.
1559
1560 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
1561
1562         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
1563         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
1564         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
1565         as another example.
1566         * lib/time_.h: Fix misspelling.
1567         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
1568         Require gl_HEADER_TIME_H_DEFAULTS.
1569         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
1570         * m4/time_r.m4 (gl_TIME_R): Likewise.
1571         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
1572
1573 2007-03-01  Bruno Haible  <bruno@clisp.org>
1574
1575         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
1576         * m4/utimens.m4 (gl_UTIMENS): Likewise.
1577
1578 2007-03-01  Jim Meyering  <jim@meyering.net>
1579
1580         * modules/xreadlink (Maintainer): Add my name.
1581         * modules/xreadlink-with-size (Depends-on): Alphabetize.
1582
1583 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
1584             Bruno Haible  <bruno@clisp.org>
1585
1586         * build-aux/install-reloc: Compile also c-ctype.c.
1587         * build-aux/relocatable.sh.in: New file.
1588         * doc/relocatable.texi: New file.
1589         * doc/relocatable-maint.texi: New file.
1590         * doc/gnulib.texi: Include relocatable-maint.texi.
1591         * lib/progreloc.c: Include unistd.h unconditionally.
1592         * lib/relocwrapper.c: Include unistd.h unconditionally.
1593         Include c-ctype.h.
1594         (add_dotbin): Use c_tolower.
1595         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
1596         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
1597         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
1598         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
1599         to m4/relocatable-lib.m4.
1600         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
1601         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
1602         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
1603         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
1604         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
1605         * modules/relocatable: New file.
1606         * modules/relocatable-lib: New file.
1607         * modules/relocatable-script: New file.
1608
1609 2007-02-28  Bruno Haible  <bruno@clisp.org>
1610
1611         Import --enable-relocatable infrastructure.
1612         * build-aux/config.libpath: New file, from GNU gettext.
1613         * build-aux/install-reloc: New file, from GNU gettext.
1614         * build-aux/reloc-ldflags: New file, from GNU gettext.
1615         * lib/relocatable.h: New file, from GNU gettext.
1616         * lib/relocatable.c: New file, from GNU gettext.
1617         * lib/relocwrapper.c: New file, from GNU gettext.
1618         * m4/relocatable.m4: New file, from GNU gettext.
1619
1620 2007-02-28  Bruno Haible  <bruno@clisp.org>
1621
1622         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
1623
1624         * modules/xreadlink: New file, from GNU gettext with modifications.
1625         * lib/xreadlink.c: New file, from GNU gettext.
1626         * lib/xreadlink.h: Add comments.
1627         (xreadlink): New declaration.
1628
1629         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
1630         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
1631         lib/xreadlink-with-size.c.
1632         (configure.ac): Remove gl_XREADLINK invocation.
1633         (Makefile.am): Augment lib_SOURCES.
1634         * m4/xreadlink.m4: Remove file.
1635         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
1636         (xreadlink_with_size): Renamed from xreadink.
1637         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
1638         * modules/canonicalize (Depends-on): Replace xreadlink with
1639         xreadlink-with-size.
1640         * lib/canonicalize.c (canonicalize_filename_mode): Update.
1641
1642 2007-02-25  Jim Meyering  <jim@meyering.net>
1643
1644         * build-aux/announce-gen: When complaining about excess arguments,
1645         list them.
1646
1647 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
1648
1649         * README: Document signed integer overflow situation more
1650         accurately.
1651
1652 2007-02-25  Bruno Haible  <bruno@clisp.org>
1653
1654         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
1655         'a' or 'A' conversion.
1656
1657 2007-02-25  Bruno Haible  <bruno@clisp.org>
1658
1659         * modules/filename: Renamed from modules/pathname.
1660         (Files): Replace lib/pathname.h with lib/filename.h. Replace
1661         lib/concatpath.c with lib/concat-filename.c.
1662         (Makefile.am): Update.
1663         (Include): Replace pathname.h with filename.h.
1664         * lib/filename.h: Renamed from lib/pathname.h.
1665         (concatenated_filename): Renamed from concatenated_pathname.
1666         * lib/concat-filename.c: Renamed from lib/concatpath.c.
1667         (concatenated_filename): Renamed from concatenated_pathname.
1668         * lib/findprog.c: Include filename.h instead of pathname.h.
1669         (find_in_path): Update.
1670         * lib/javacomp.c: Include filename.h instead of pathname.h.
1671         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
1672         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
1673         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
1674         is_oldgcj_14_13_usable, is_javac_usable): Update.
1675         * lib/javaexec.c: Include filename.h instead of pathname.h.
1676         (execute_java_class): Update.
1677         * modules/findprog: Update.
1678         * modules/javacomp: Update.
1679         * modules/javaexec: Update.
1680         * MODULES.html.sh (File system functions): Add 'filename', remove
1681         'pathname'.
1682
1683 2007-02-25  Bruno Haible  <bruno@clisp.org>
1684
1685         * modules/printf-frexpl-tests: New file.
1686         * tests/test-printf-frexpl.c: New file.
1687
1688         * modules/printf-frexpl: New file.
1689         * lib/printf-frexpl.h: New file.
1690         * lib/printf-frexpl.c: New file.
1691         * m4/printf-frexpl.m4: New file.
1692
1693 2007-02-25  Bruno Haible  <bruno@clisp.org>
1694
1695         * modules/printf-frexp-tests: New file.
1696         * tests/test-printf-frexp.c: New file.
1697
1698         * modules/printf-frexp: New file.
1699         * lib/printf-frexp.h: New file.
1700         * lib/printf-frexp.c: New file.
1701         * m4/printf-frexp.m4: New file.
1702
1703 2007-02-25  Bruno Haible  <bruno@clisp.org>
1704
1705         Assume automake >= 1.10 for the tests.
1706         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
1707         * modules/arctwo-tests: Likewise.
1708         * modules/argp-tests: Likewise.
1709         * modules/avltree-list-tests: Likewise.
1710         * modules/avltree-oset-tests: Likewise.
1711         * modules/avltreehash-list-tests: Likewise.
1712         * modules/carray-list-tests: Likewise.
1713         * modules/crc-tests: Likewise.
1714         * modules/des-tests: Likewise.
1715         * modules/gc-arcfour-tests: Likewise.
1716         * modules/gc-arctwo-tests: Likewise.
1717         * modules/gc-des-tests: Likewise.
1718         * modules/gc-hmac-md5-tests: Likewise.
1719         * modules/gc-hmac-sha1-tests: Likewise.
1720         * modules/gc-md2-tests: Likewise.
1721         * modules/gc-md4-tests: Likewise.
1722         * modules/gc-md5-tests: Likewise.
1723         * modules/gc-pbkdf2-sha1-tests: Likewise.
1724         * modules/gc-rijndael-tests: Likewise.
1725         * modules/gc-sha1-tests: Likewise.
1726         * modules/gc-tests: Likewise.
1727         * modules/getaddrinfo-tests: Likewise.
1728         * modules/hmac-md5-tests: Likewise.
1729         * modules/hmac-sha1-tests: Likewise.
1730         * modules/linked-list-tests: Likewise.
1731         * modules/linkedhash-list-tests: Likewise.
1732         * modules/lock-tests: Likewise.
1733         * modules/md2-tests: Likewise.
1734         * modules/md4-tests: Likewise.
1735         * modules/md5-tests: Likewise.
1736         * modules/rbtree-list-tests: Likewise.
1737         * modules/rbtree-oset-tests: Likewise.
1738         * modules/rbtreehash-list-tests: Likewise.
1739         * modules/read-file-tests: Likewise.
1740         * modules/rijndael-tests: Likewise.
1741         * modules/stdint-tests: Likewise.
1742         * modules/tls-tests: Likewise.
1743
1744 2007-02-24  Bruno Haible  <bruno@clisp.org>
1745
1746         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
1747         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
1748         function; instead check whether isnan with a double argument links.
1749         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
1750         function; instead check whether isnan with a 'long double' argument
1751         links.
1752         Reported by Eric Blake <ebb9@byu.net>.
1753
1754 2007-02-24  Bruno Haible  <bruno@clisp.org>
1755
1756         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
1757         defined.
1758         * lib/isnanl.c: Remove all code. Just include isnan.c.
1759         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
1760
1761 2007-02-25  Jim Meyering  <jim@meyering.net>
1762
1763         Avoid conflicting types for 'unsetenv' on FreeBSD.
1764         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
1765         conflicting with FreeBSD's (5.0 and 6.1) function declaration
1766         in stdlib.h.
1767
1768 2007-02-24  Bruno Haible  <bruno@clisp.org>
1769
1770         * modules/isnanl-nolibm-tests: New file.
1771         * tests/test-isnanl.c: New file.
1772
1773         * modules/isnanl-nolibm: New file.
1774         * lib/isnanl.h: New file.
1775         * lib/isnanl.c: New file.
1776         * m4/isnanl.m4: New file.
1777
1778 2007-02-24  Bruno Haible  <bruno@clisp.org>
1779
1780         * modules/isnan-nolibm-tests: New file.
1781         * tests/test-isnan.c: New file.
1782
1783         * modules/isnan-nolibm: New file.
1784         * lib/isnan.h: New file.
1785         * lib/isnan.c: New file.
1786         * m4/isnan.m4: New file.
1787
1788 2007-02-24  Bruno Haible  <bruno@clisp.org>
1789
1790         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
1791         assume that an exponent fits in 20 bits.
1792
1793 2007-02-24  Jim Meyering  <jim@meyering.net>
1794
1795         * m4/regex.m4: Update the description of the configure-time option,
1796         --without-included-regex, to state accurately what the defaults are,
1797         and perhaps to give people an idea why using this option is risky.
1798
1799 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
1800
1801         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
1802         loops on small arguments.  This attempts to avoid the problem
1803         Bruno Haible reported for AIX 4.3.2 in
1804         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
1805
1806 2007-02-23  Bruno Haible  <bruno@clisp.org>
1807
1808         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
1809         Needed for help2man.
1810
1811 2007-02-23  Karl Berry  <karl@gnu.org>
1812
1813         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
1814         exists, foo.h should be cvs-ignored, not committed.
1815
1816 2007-02-23  Eric Blake  <ebb9@byu.net>
1817
1818         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
1819         * lib/stat-time.h (includes): Likewise.
1820         * lib/utimecmp.c (includes): Likewise.
1821         * lib/utimens.h (includes): Likewise.
1822         * lib/getdate.y (includes): Also include "timespec.h" for use
1823         internal to the module.
1824         * modules/utimens (Depends-on): Revert yesterday's patch.
1825         * modules/nanosleep (Depends-on): Add missing dependency.
1826
1827 2007-02-22  Bruno Haible  <bruno@clisp.org>
1828
1829         * lib/glob.c: Don't include getlogin_r.h.
1830
1831 2007-02-22  Jim Meyering  <jim@meyering.net>
1832
1833         * modules/utimens (Depends-on): Add timespec, required for
1834         utimens.h's inclusion of timespec.h.
1835
1836 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
1837
1838         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
1839         long unreadable paths in GNU/Linux.  Problem reported by Andreas
1840         Schwab in
1841         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
1842         I'll try to think of a better way to fix the Solaris problem.
1843
1844         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
1845         like glibc; on Solaris 10, it fails with errno == EINVAL.
1846         POSIX says the behavior is unspecified if the first argument is NULL,
1847         so play it safe and never pass NULL to the system getcwd.
1848
1849 2007-02-21  Jim Meyering  <jim@meyering.net>
1850
1851         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
1852         of gettimeofday.  It would conflict with the one now always
1853         provided via sys_time_.h.  Reported by Matthew Woehlke, as
1854         an IRIX 6.5 build failure.
1855
1856 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
1857
1858         Minor fixups to port to Solaris 10 with Sun C 5.8.
1859         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
1860         * modules/getcwd (Depends-on): Add dirfd.
1861         * lib/putenv.c (putenv): #undef it.
1862         (rpl_putenv): New decl.
1863         (malloc, free): Include <stdlib.h> rather than prototyping separately.
1864
1865 2007-02-20  Bruno Haible  <bruno@clisp.org>
1866
1867         * modules/stdio-tests: New file.
1868         * tests/test-stdio.c: New file.
1869
1870         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
1871         (Depends-on): Add stdio.
1872         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
1873         (Include): Use <stdio.h> instead of vsnprintf.h.
1874         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
1875         HAVE_DECL_VSNPRINTF.
1876         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
1877
1878         * modules/snprintf (Files): Remove lib/snprintf.h.
1879         (Depends-on): Add stdio.
1880         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
1881         (Include): Use <stdio.h> instead of snprintf.h.
1882         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
1883         HAVE_DECL_SNPRINTF.
1884         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
1885         * lib/getaddrinfo.c: Likewise.
1886
1887         * modules/stdio: New file.
1888         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
1889         * lib/snprintf.h: Remove file.
1890         * lib/vsnprintf.h: Remove file.
1891         * lib/.cppi-disable: Remove snprintf.h.
1892         * m4/stdio_h.m4: New file.
1893         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
1894
1895 2007-02-20  Jim Meyering  <jim@meyering.net>
1896
1897         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
1898         used by e.g., mingw.  From Bruno Haible.
1899
1900 2007-02-19  Bruno Haible  <bruno@clisp.org>
1901
1902         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
1903         warnings.
1904         Reported by Ben Pfaff <blp@cs.stanford.edu>.
1905
1906 2007-02-19  Bruno Haible  <bruno@clisp.org>
1907
1908         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
1909         from mingw users.
1910
1911 2007-02-19  Bruno Haible  <bruno@clisp.org>
1912
1913         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
1914         warnings.
1915         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
1916
1917 2007-02-19  Jim Meyering  <jim@meyering.net>
1918
1919         Don't use FD after a successful "fdopendir (fd)".
1920         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
1921         Reset it by calling dirfd on the just-obtained DIR*.
1922
1923         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
1924         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
1925
1926 2007-02-18  Bruno Haible  <bruno@clisp.org>
1927
1928         * lib/readlink.c: Include <unistd.h>.
1929         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
1930         HAVE_READLINK.
1931         * modules/readlink (Depends-on): Add unistd.
1932         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1933         (Include): Add <unistd.h>.
1934
1935         * lib/getlogin_r.h: Remove file.
1936         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
1937         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
1938         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
1939         HAVE_DECL_GETLOGIN_R.
1940         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
1941         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1942         (Include): Use <unistd.h> instead of getlogin_r.h.
1943
1944         * lib/getcwd.h: Remove file.
1945         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
1946         * lib/xgetcwd.c: Likewise.
1947         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
1948         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
1949         * modules/getcwd (Files): Remove lib/getcwd.h.
1950         (Depends-on): Add unistd.
1951         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1952         (Include): Use <unistd.h> instad of getcwd.h.
1953
1954         * lib/ftruncate.c: Include <unistd.h> first.
1955         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
1956         Set HAVE_FTRUNCATE.
1957         * modules/ftruncate (Depends-on): Add unistd.
1958         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1959
1960         * lib/fchdir.c: Include <unistd.h> first.
1961         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
1962         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
1963         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
1964         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1965         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
1966
1967         * lib/dup2.c: Include <unistd.h> first.
1968         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
1969         HAVE_DUP2.
1970         * modules/dup2 (Depends-on): Add unistd.
1971         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1972
1973         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
1974         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
1975         REPLACE_CHOWN. Don't define chown as a macro here.
1976         * modules/chown (Depends-on): Add unistd.
1977         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1978
1979         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
1980         Add definition for GL_LINK_WARNING.
1981         (chown, dup2): New declarations.
1982         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
1983         link warning.
1984         (ftruncate): New declaration.
1985         (getcwd): New declaration, taken from old getcwd.h.
1986         (getlogin_r): New declaration, taken from old getlogin_r.h.
1987         (readlink): New declaration.
1988         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
1989         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
1990         (gl_PREREQ_UNISTD): Remove macro.
1991         (gl_UNISTD_MODULE_INDICATOR): New macro.
1992         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
1993         many new variables. Don't set UNISTD_H.
1994         * modules/unistd (Description): Change.
1995         (Depends-on): Add link-warning.
1996         (configure.ac): Update.
1997         (Makefile.am): Create unistd.h always. Substitute many new variables
1998         into it.
1999
2000 2007-02-18  Bruno Haible  <bruno@clisp.org>
2001
2002         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
2003         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
2004         HAVE_GETSUBOPT.
2005         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
2006         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
2007         * lib/getsubopt.h: Remove file.
2008         * modules/getsubopt (Files): Remove lib/getsubopt.h.
2009         (Depends-on): Add stdlib.
2010         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2011         (Includes): Use <stdlib.h> instead of getsubopt.h.
2012         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
2013         Set HAVE_GETSUBOPT.
2014         * lib/getsubopt.c: Don't include getsubopt.h.
2015
2016 2007-02-18  Bruno Haible  <bruno@clisp.org>
2017
2018         * modules/fchdir (Depends-on): Add dup2.
2019
2020 2007-02-18  Bruno Haible  <bruno@clisp.org>
2021
2022         * lib/stdlib_.h: Handle glibc's special invocation convention
2023         specially.
2024
2025 2007-02-18  Bruno Haible  <bruno@clisp.org>
2026
2027         * modules/stdlib-tests: New file.
2028         * tests/test-stdlib.c: New file.
2029
2030         * modules/mkstemp (Files): Remove lib/mkstemp.h.
2031         (Depends-on): Add stdlib.
2032         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2033         (Includes): Use <stdlib.h> instead of mkstemp.h.
2034         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
2035         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
2036         * lib/mkstemp.c: Don't include mkstemp.h.
2037         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
2038         * lib/stdlib--.h: Don't include mkstemp.h.
2039
2040         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
2041         (Depends-on): Add stdlib.
2042         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2043         (Includes): Use <stdlib.h> instead of mkdtemp.h.
2044         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
2045         HAVE_MKDTEMP.
2046         * lib/mkdtemp.c: Don't include mkdtemp.h.
2047         * lib/clean-temp.c: Don't include mkdtemp.h.
2048
2049         * modules/exit (Files): Remove lib/exit.h.
2050         (Depends-on): Add stdlib.
2051         (Makefile.am): Remove lib_SOURCES.
2052         (Include): Use <stdlib.h> instead of exit.h.
2053         * lib/argmatch.c: Don't include exit.h.
2054         * lib/execute.c: Likewise.
2055         * lib/pagealign_alloc.c: Likewise.
2056         * lib/pipe.c: Likewise.
2057         * lib/wait-process.c: Likewise.
2058         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
2059         * lib/exitfail.c: Likewise.
2060         * lib/savewd.c: Likewise.
2061         * lib/xsetenv.c: Likewise.
2062
2063         * modules/stdlib: New file.
2064         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
2065         and extra comments about mkstemp().
2066         * lib/exit.h: Remove file.
2067         * lib/mkdtemp.h: Remove file.
2068         * lib/mkstemp.h: Remove file.
2069         * m4/stdlib_h.m4: New file.
2070         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
2071
2072 2007-02-18  Bruno Haible  <bruno@clisp.org>
2073
2074         * modules/math-tests: New file.
2075         * tests/test-math.c: New file.
2076
2077         * modules/math: New file.
2078         * modules/mathl (Files): Remove lib/mathl.h.
2079         (Depends-on): Add math.
2080         (Makefile.am): Don't mention mathl.h.
2081         (Include): Use <math.h> instead of mathl.h.
2082         * lib/math_.h: New file.
2083         * lib/mathl.h: Remove file.
2084         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
2085         mathl.h.
2086         * lib/asinl.c: Likewise.
2087         * lib/atanl.c: Likewise.
2088         * lib/ceill.c: Likewise.
2089         * lib/cosl.c: Likewise.
2090         * lib/expl.c: Likewise.
2091         * lib/floorl.c: Likewise.
2092         * lib/frexpl.c: Likewise.
2093         * lib/ldexpl.c: Likewise.
2094         * lib/logl.c: Likewise.
2095         * lib/sincosl.c: Likewise.
2096         * lib/sinl.c: Likewise.
2097         * lib/sqrtl.c: Likewise.
2098         * lib/tanl.c: Likewise.
2099         * lib/trigl.c: Likewise.
2100         * m4/math_h.m4: New file.
2101         * MODULES.html.sh (Mathematics): Add math.
2102
2103 2007-02-17  Bruno Haible  <bruno@clisp.org>
2104
2105         * modules/wctype-tests: New file.
2106         * tests/test-wctype.c: New file.
2107
2108         * modules/wchar-tests: New file.
2109         * tests/test-wchar.c: New file.
2110
2111         * modules/unistd-tests: New file.
2112         * tests/test-unistd.c: New file.
2113
2114         * modules/time-tests: New file.
2115         * tests/test-time.c: New file.
2116
2117         * modules/sysexits-tests: New file.
2118         * tests/test-sysexits.c: New file.
2119
2120         * modules/sys_time-tests: New file.
2121         * tests/test-sys_time.c: New file.
2122
2123         * modules/sys_stat-tests: New file.
2124         * tests/test-sys_stat.c: New file.
2125
2126         * modules/sys_socket-tests: New file.
2127         * tests/test-sys_socket.c: New file.
2128
2129         * modules/sys_select-tests: New file.
2130         * tests/test-sys_select.c: New file.
2131
2132         * modules/string-tests: New file.
2133         * tests/test-string.c: New file.
2134
2135         * modules/stdbool-tests: New file.
2136         * tests/test-stdbool.c: New file.
2137
2138         * modules/netinet_in-tests: New file.
2139         * tests/test-netinet_in.c: New file.
2140
2141         * modules/inttypes-tests: New file.
2142         * tests/test-inttypes.c: New file.
2143
2144         * modules/fcntl-tests: New file.
2145         * tests/test-fcntl.c: New file.
2146
2147         * modules/byteswap-tests: New file.
2148         * tests/test-byteswap.c: New file.
2149
2150         * modules/arpa_inet-tests: New file.
2151         * tests/test-arpa_inet.c: New file.
2152
2153 2007-02-17  Bruno Haible  <bruno@clisp.org>
2154
2155         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
2156         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
2157         if the corresponding module is not enabled. Emit link warnings if
2158         the function is used nevertheless.
2159         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
2160         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
2161         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
2162         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
2163         * modules/inttypes (Depends-on): Add link-warning.
2164         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2165         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
2166         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
2167         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
2168         * modules/imaxdiv (configure.ac): Likewise.
2169         * modules/strtoimax (configure.ac): Likewise.
2170         * modules/strtoumax (configure.ac): Likewise.
2171
2172 2007-02-17  Bruno Haible  <bruno@clisp.org>
2173
2174         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
2175         gl_STRING_MODULE_INDICATOR_DEFAULTS.
2176         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
2177         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
2178
2179 2007-02-17  Bruno Haible  <bruno@clisp.org>
2180
2181         * modules/link-warning: New file.
2182         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
2183         * lib/string_.h (GL_LINK_WARNING): Remove definition.
2184         * modules/string (Depends-on): Add link-warning.
2185         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2186         string.h.
2187         * MODULES.html.sh (Support for building libraries and executables): Add
2188         link-warning.
2189
2190 2007-02-17  Bruno Haible  <bruno@clisp.org>
2191
2192         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
2193         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
2194         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
2195         long lines.
2196
2197 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
2198             Bruno Haible  <bruno@clisp.org>
2199
2200         * modules/tmpfile: New file.
2201         * lib/tmpfile.c: New file.
2202         * m4/tmpfile.m4: New file.
2203         * MODULES.html.sh (func_all_modules): New section "Input/output".
2204
2205 2007-02-15  Bruno Haible  <bruno@clisp.org>
2206
2207         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
2208         (supports_delete_on_close): New function.
2209         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
2210
2211 2007-02-14  Bruno Haible  <bruno@clisp.org>
2212
2213         * modules/mbspcasecmp-tests: New file.
2214         * tests/test-mbspcasecmp.sh: New file.
2215         * tests/test-mbspcasecmp.c: New file.
2216
2217         New module mbspcasecmp.
2218         * modules/mbspcasecmp: New file.
2219         * lib/mbspcasecmp.c: New file.
2220         * lib/string_.h (strncasecmp): Change warning message.
2221         (mbspcasecmp): New declaration.
2222         * m4/mbspcasecmp.m4: New file.
2223         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2224         GNULIB_MBSPCASECMP.
2225         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
2226         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
2227
2228 2007-02-14  Bruno Haible  <bruno@clisp.org>
2229
2230         * modules/mbsncasecmp-tests: New file.
2231         * tests/test-mbsncasecmp.sh: New file.
2232         * tests/test-mbsncasecmp.c: New file.
2233
2234         New module mbsncasecmp.
2235         * modules/mbsncasecmp: New file.
2236         * lib/mbsncasecmp.c: New file.
2237         * lib/string_.h (mbsncasecmp): New declaration.
2238         * m4/mbsncasecmp.m4: New file.
2239         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2240         GNULIB_MBSNCASECMP.
2241         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
2242         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
2243
2244 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
2245
2246         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
2247         Verify that it doesn't overlap with our flags.
2248         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
2249         do not have the desired effect in multibyte locales; instead, use
2250         mbscasecmp.
2251         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
2252         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
2253         we don't require GNU fnmatch ourselves (if our users require it, they
2254         should do so explicitly).
2255
2256         Fix regex code so it doesn't rely on strcasecmp.
2257         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
2258         Otherwise, include gnulib's langinfo.h.
2259         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
2260         undesirable behavior in non-C locales.  Instead, rely on localecharset.
2261         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
2262         * modules/regex (FILES): Remove m4/codeset.m4.
2263         (Depends-on): Add localcharset.  Remove strcase.
2264
2265 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2266
2267         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
2268         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
2269
2270 2007-02-13  Bruno Haible  <bruno@clisp.org>
2271
2272         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
2273         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
2274
2275 2007-02-12  Bruno Haible  <bruno@clisp.org>
2276
2277         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
2278         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
2279         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
2280         time warning rather than a link error.
2281
2282 2007-02-12  Bruno Haible  <bruno@clisp.org>
2283
2284         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
2285         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
2286         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
2287
2288 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
2289
2290         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
2291         args, not 2.
2292
2293 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
2294
2295         New module 'time', so that apps can include <time.h> as per
2296         POSIX and GNU instead of separate include files like time_r.h
2297         and timegm.h.  This implementation tries out a simpler approach
2298         for replacing decls in standard include files (as compared to
2299         the string module), somewhat as an experiment.
2300
2301         * config/srclist.txt: Comment out mktime.c for now.
2302         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
2303         since it doesn't apply any more.  Use generic wording instead.
2304         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
2305         'time'.
2306         * lib/time_.h, m4/time_h.m4, modules/time: New files.
2307         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
2308         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
2309         Don't include <sys/types.h>; no longer needed since we assume C89.
2310         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
2311         * lib/strftime.c: Likewise.
2312         * lib/time_r.c: Likewise.
2313         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
2314         * lib/nanosleep.c: Include <time.h> first, to check interface.
2315         * lib/strptime.c: Likewise.
2316         * lib/time_r.c: Likewise.
2317         * lib/timegm.c: Likewise.
2318         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
2319         needed.
2320         * lib/timegm.c: Don't include timegm.h; no longer needed.
2321         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
2322         time.h now handles any problems in that area.
2323         (struct timespec, nanosleep): Remove; time.h now arranges for these.
2324         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
2325         that time.h defines struct timespec.
2326         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
2327         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
2328         handles that.
2329         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
2330         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
2331         needed.  Set REPLACE_LOCALTIME.
2332         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
2333         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
2334         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
2335         nanosleep; time_h.m4 now does that.  Don't require
2336         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
2337         module handles this now.
2338         * modules/getdate (Depends-on): Remove timespec.  Add time.
2339         * modules/nanosleep (Depends-on): Likewise.
2340         * modules/stat-time (Depends-on): Likewise.
2341         * modules/nanosleep (Include): Include time.h, not timespec.h.
2342         * modules/strptime (Files): Remove lib/strptime.h.
2343         (Depends-on): Add extensions, time.
2344         (Include): Include time.h, not strptime.h.
2345         * modules/time_r (Files): Remove lib/time_r.h.
2346         (Depends-on): Add time.
2347         (Include): Include time.h, not time_r.h.
2348         * modules/timegm: Likewise.
2349         * modules/timespec (Description): Now does timespec-related decls
2350         of our own, instead of struct timespec itself.
2351         (Depends-on): Add time; remove extensions.
2352         (Maintainer): Add self.
2353         * modules/utimecmp (Depends-on): Add time; remove timespec.
2354         * modules/utimens (Depends-on): Likewise.
2355         * modules/xnanosleep (Depends-on): Likewise.
2356
2357 2007-02-11  Bruno Haible  <bruno@clisp.org>
2358
2359         * lib/c-strstr.c: Include allocsa.h.
2360         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2361         * lib/c-strcasestr.c: Include allocsa.h.
2362         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2363         * lib/strcasestr.c: Include allocsa.h.
2364         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2365         * lib/mbsstr.c: Include allocsa.h.
2366         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
2367         allocsa/freesa instead of malloc/free.
2368         * lib/mbscasestr.c: Include allocsa.h.
2369         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
2370         allocsa/freesa instead of malloc/free.
2371         * modules/c-strstr (Depends-on): Add allocsa.
2372         * modules/c-strcasestr (Depends-on): Likewise.
2373         * modules/strcasestr (Depends-on): Likewise.
2374         * modules/mbsstr (Depends-on): Likewise.
2375         * modules/mbscasestr (Depends-on): Likewise.
2376
2377 2007-02-11  Bruno Haible  <bruno@clisp.org>
2378
2379         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
2380
2381         * modules/mbsspn-tests: New file.
2382         * tests/test-mbsspn.sh: New file.
2383         * tests/test-mbsspn.c: New file.
2384
2385 2007-02-11  Bruno Haible  <bruno@clisp.org>
2386
2387         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
2388
2389         * modules/mbspbrk-tests: New file.
2390         * tests/test-mbspbrk.sh: New file.
2391         * tests/test-mbspbrk.c: New file.
2392
2393 2007-02-11  Bruno Haible  <bruno@clisp.org>
2394
2395         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
2396         unneeded cast.
2397
2398         * modules/mbscspn-tests: New file.
2399         * tests/test-mbscspn.sh: New file.
2400         * tests/test-mbscspn.c: New file.
2401
2402 2007-02-11  Bruno Haible  <bruno@clisp.org>
2403
2404         * modules/mbscasecmp-tests: New file.
2405         * tests/test-mbscasecmp.sh: New file.
2406         * tests/test-mbscasecmp.c: New file.
2407
2408 2007-02-11  Bruno Haible  <bruno@clisp.org>
2409
2410         Ensure O(n) worst-case complexity of mbscasestr.
2411         * lib/mbscasestr.c: Include stdbool.h.
2412         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
2413         functions.
2414         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
2415         the bookkeeping indicates that it's worth it.
2416         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
2417
2418         * modules/mbscasestr-tests: New file.
2419         * tests/test-mbscasestr1.c: New file.
2420         * tests/test-mbscasestr2.sh: New file.
2421         * tests/test-mbscasestr2.c: New file.
2422         * tests/test-mbscasestr3.sh: New file.
2423         * tests/test-mbscasestr3.c: New file.
2424         * tests/test-mbscasestr4.sh: New file.
2425         * tests/test-mbscasestr4.c: New file.
2426         * m4/locale-tr.m4: New file.
2427
2428 2007-02-11  Bruno Haible  <bruno@clisp.org>
2429
2430         Ensure O(n) worst-case complexity of mbsstr.
2431         * lib/mbsstr.c: Include stdbool.h.
2432         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
2433         functions.
2434         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
2435         bookkeeping indicates that it's worth it.
2436         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
2437
2438         * modules/mbsstr-tests: New file.
2439         * tests/test-mbsstr1.c: New file.
2440         * tests/test-mbsstr2.sh: New file.
2441         * tests/test-mbsstr2.c: New file.
2442         * tests/test-mbsstr3.sh: New file.
2443         * tests/test-mbsstr3.c: New file.
2444         * m4/locale-fr.m4: New file.
2445
2446 2007-02-11  Bruno Haible  <bruno@clisp.org>
2447
2448         * lib/mbsrchr.c (mbsrchr): Fix bug.
2449
2450         * modules/mbsrchr-tests: New file.
2451         * tests/test-mbsrchr.sh: New file.
2452         * tests/test-mbsrchr.c: New file.
2453
2454 2007-02-11  Bruno Haible  <bruno@clisp.org>
2455
2456         * lib/mbschr.c (mbschr): Fix bug.
2457
2458         * modules/mbschr-tests: New file.
2459         * tests/test-mbschr.sh: New file.
2460         * tests/test-mbschr.c: New file.
2461         * m4/locale-zh.m4: New file.
2462
2463 2007-02-11  Bruno Haible  <bruno@clisp.org>
2464
2465         Support for copying multibyte string iterators.
2466         * lib/mbiter.h: Include <string.h>.
2467         (mbiter_multi_copy): New function.
2468         (mbi_copy): New macro.
2469         * lib/mbuiter.h: Include <string.h>.
2470         (mbuiter_multi_copy): New function.
2471         (mbui_copy): New macro.
2472
2473 2007-02-11  Bruno Haible  <bruno@clisp.org>
2474
2475         New module mbslen.
2476         * modules/mbslen: New file.
2477         * lib/mbslen.c: New file.
2478         * lib/string_.h (mbslen): New declaration.
2479         * m4/mbslen.m4: New file.
2480         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2481         GNULIB_MBSLEN.
2482         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
2483         * MODULES.html.sh (Internationalization functions): Add mbslen.
2484
2485 2007-02-11  Bruno Haible  <bruno@clisp.org>
2486
2487         Ensure O(n) worst-case complexity of strcasestr substitute.
2488         * lib/strcasestr.c: Include stdbool.h.
2489         (knuth_morris_pratt): New function.
2490         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
2491         bookkeeping indicates that it's worth it.
2492         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
2493
2494         * modules/strcasestr-tests: New file.
2495         * tests/test-strcasestr.c: New file.
2496
2497 2007-02-11  Bruno Haible  <bruno@clisp.org>
2498
2499         Ensure O(n) worst-case complexity of c_strcasestr.
2500         * lib/c-strcasestr.c: Include stdbool.h, string.h.
2501         (knuth_morris_pratt): New function.
2502         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
2503         the bookkeeping indicates that it's worth it.
2504         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
2505
2506         * modules/c-strcasestr-tests: New file.
2507         * tests/test-c-strcasestr.c: New file.
2508
2509 2007-02-11  Bruno Haible  <bruno@clisp.org>
2510
2511         Ensure O(n) worst-case complexity of c_strstr.
2512         * lib/c-strstr.c: Include stdbool.h, string.h.
2513         (knuth_morris_pratt): New function.
2514         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
2515         bookkeeping indicates that it's worth it.
2516         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
2517
2518         * lib/c-strstr.c: Complete rewrite for maintainability.
2519
2520         * modules/c-strstr-tests: New file.
2521         * tests/test-c-strstr.c: New file.
2522
2523 2007-02-11  Bruno Haible  <bruno@clisp.org>
2524
2525         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
2526         5.2.1 and earlier, whereby \055 was treated just like the range
2527         delimiter '-'.
2528         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
2529
2530 2007-02-08  Bruno Haible  <bruno@clisp.org>
2531
2532         * modules/regex (Depends-on): Add stdbool.
2533         Reported by Dalibor Topic <robilad@kaffe.org>.
2534
2535 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
2536
2537         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
2538         Prefer returning from main to exiting from it.
2539         Remove unnecessary parens after sizeof.
2540
2541 2007-02-05  Bruno Haible  <bruno@clisp.org>
2542
2543         New module mbssep.
2544         * modules/mbssep: New file.
2545         * lib/mbssep.c: New file.
2546         * lib/string_.h (strsep): Add a conditional link warning.
2547         (mbssep): New declaration.
2548         * m4/mbssep.m4: New file.
2549         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2550         GNULIB_MBSSEP.
2551         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
2552         * MODULES.html.sh (Internationalization functions): Add mbssep.
2553
2554 2007-02-05  Bruno Haible  <bruno@clisp.org>
2555
2556         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
2557         Optimize search in case of 1 delimiter.
2558
2559 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
2560
2561         * lib/acl.h: Include sys/types.h before sys/acl.h.
2562
2563 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
2564
2565         Merge upstream fix for glibc bugzilla #3957:
2566
2567         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
2568
2569         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
2570         bit for RE_HAT_LISTS_NOT_NEWLINE.
2571         (build_charclass_op): Remove bogus comment.
2572
2573 2007-02-05  Simon Josefsson  <simon@josefsson.org>
2574
2575         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
2576
2577 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
2578
2579         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
2580         * lib/memmem.c [!defined _LIBC]: Include config.h.
2581
2582 2007-02-04  Bruno Haible  <bruno@clisp.org>
2583
2584         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
2585         warning message.
2586
2587 2007-02-04  Bruno Haible  <bruno@clisp.org>
2588
2589         New module mbstok_r.
2590         * modules/mbstok_r: New file.
2591         * lib/mbstok_r.c: New file.
2592         * lib/string_.h (strtok_r): Change argument names to match the
2593         comments. Add a conditional link warning.
2594         (mbstok_r): New declaration.
2595         * m4/mbstok_r.m4: New file.
2596         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2597         GNULIB_MBSTOK_R.
2598         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
2599         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
2600
2601 2007-02-04  Bruno Haible  <bruno@clisp.org>
2602
2603         New module mbsspn.
2604         * modules/mbsspn: New file.
2605         * lib/mbsspn.c: New file.
2606         * lib/string_.h (strspn): Add a conditional link warning.
2607         (mbsspn): New declaration.
2608         * m4/mbsspn.m4: New file.
2609         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2610         GNULIB_MBSSPN.
2611         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
2612         * MODULES.html.sh (Internationalization functions): Add mbsspn.
2613
2614 2007-02-04  Bruno Haible  <bruno@clisp.org>
2615
2616         New module mbspbrk.
2617         * modules/mbspbrk: New file.
2618         * lib/mbspbrk.c: New file.
2619         * lib/string_.h (strpbrk): Add a conditional link warning.
2620         (mbspbrk): New declaration.
2621         * m4/mbspbrk.m4: New file.
2622         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2623         GNULIB_MBSPBRK.
2624         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
2625         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
2626
2627 2007-02-04  Bruno Haible  <bruno@clisp.org>
2628
2629         New module mbscspn.
2630         * modules/mbscspn: New file.
2631         * lib/mbscspn.c: New file.
2632         * lib/string_.h (strcspn): Add a conditional link warning.
2633         (mbscspn): New declaration.
2634         * m4/mbscspn.m4: New file.
2635         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2636         GNULIB_MBSCSPN.
2637         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
2638         * MODULES.html.sh (Internationalization functions): Add mbscspn.
2639
2640 2007-02-04  Bruno Haible  <bruno@clisp.org>
2641
2642         New module mbscasestr, reduced goal of strcasestr.
2643         * modules/mbscasestr: New file.
2644         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
2645         (mbscasestr): Renamed from strcasestr.
2646         * lib/strcasestr.c: Don't include mbuiter.h.
2647         (strcasestr): Remove support for multibyte locales.
2648         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
2649         Change the conditional link warning.
2650         (mbscasestr): New declaration.
2651         * m4/mbscasestr.m4: New file.
2652         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
2653         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
2654         REPLACE_STRCASESTR.
2655         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
2656         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
2657         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
2658         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
2659         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
2660         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
2661         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
2662         (Depends-on): Remove mbuiter.
2663         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
2664
2665 2007-02-04  Bruno Haible  <bruno@clisp.org>
2666
2667         Simplify handling of strncasecmp.
2668         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
2669         the conditional link warning.
2670         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
2671         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
2672         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
2673         * modules/strcase (configure.ac): Don't invoke
2674         gl_STRING_MODULE_INDICATOR.
2675         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
2676
2677 2007-02-04  Bruno Haible  <bruno@clisp.org>
2678
2679         New module mbscasecmp, reduced goal of strcasecmp.
2680         * modules/mbscasecmp: New file.
2681         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
2682         (mbscasecmp): Renamed from strcasecmp.
2683         * lib/strcasecmp.c: Don't include mbuiter.h.
2684         (strcasecmp): Remove support for multibyte locales.
2685         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
2686         Change the conditional link warning.
2687         (mbscasecmp): New declaration.
2688         * m4/mbscasecmp.m4: New file.
2689         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
2690         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
2691         REPLACE_STRCASECMP.
2692         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
2693         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2694         GNULIB_MBSCASECMP.
2695         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
2696         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
2697         * modules/strcase (Files): Remove m4/mbrtowc.m4.
2698         (Depends-on): Remove mbuiter.
2699         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
2700
2701 2007-02-04  Bruno Haible  <bruno@clisp.org>
2702
2703         New module mbsstr. Remove module strstr.
2704         * modules/mbsstr: New file.
2705         * modules/strstr: Remove file.
2706         * lib/mbsstr.c: Renamed from lib/strstr.c.
2707         (mbsstr): Renamed from strstr.
2708         * lib/string_.h (strstr): Remove declaration. Change the conditional
2709         link warning.
2710         (mbsstr): New declaration.
2711         * m4/mbsstr.m4: New file.
2712         * m4/strstr.m4: Remove file.
2713         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
2714         REPLACE_STRSTR.
2715         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
2716         Don't initialize GNULIB_STRSTR.
2717         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
2718         substitute GNULIB_STRSTR and REPLACE_STRSTR.
2719         * MODULES.html.sh (Internationalization functions): Add mbsstr.
2720         (Support for systems lacking ANSI C 89): Remove strstr.
2721
2722 2007-02-04  Bruno Haible  <bruno@clisp.org>
2723
2724         New module mbsrchr.
2725         * modules/mbsrchr: New file.
2726         * lib/mbsrchr.c: New file.
2727         * lib/string_.h (strrchr): Add a conditional link warning.
2728         (mbsrchr): New declaration.
2729         * m4/mbsrchr.m4: New file.
2730         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2731         GNULIB_MBSRCHR.
2732         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
2733         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
2734
2735 2007-02-04  Bruno Haible  <bruno@clisp.org>
2736
2737         New module mbschr.
2738         * modules/mbschr: New file.
2739         * lib/mbschr.c: New file.
2740         * lib/string_.h (strchr): Add a conditional link warning.
2741         (mbschr): New declaration.
2742         * m4/mbschr.m4: New file.
2743         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2744         GNULIB_MBSCHR.
2745         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
2746         * MODULES.html.sh (Internationalization functions): Add mbschr.
2747
2748 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
2749
2750         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
2751
2752         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
2753
2754 2007-02-04  Bruno Haible  <bruno@clisp.org>
2755
2756         New module description section 'configure.ac-early'.
2757         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
2758         (func_get_autoconf_early_snippet): New function.
2759         (func_import, func_create_testdir): Use it. Remove special cases for
2760         modules 'extensions' and 'lock'.
2761         * modules/extensions (configure.ac-early): Require
2762         gl_USE_SYSTEM_EXTENSIONS.
2763         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
2764
2765 2007-02-04  Bruno Haible  <bruno@clisp.org>
2766
2767         Make use of gcj-4.3's -fsource and -ftarget option.
2768         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
2769         and if so try the options -fsource and -ftarget.
2770         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
2771         source_version, ftarget_option, target_version arguments.
2772         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
2773         (is_envjavac_oldgcj_14_14_usable): Renamed from
2774         is_envjavac_gcj_14_14_usable.
2775         (is_envjavac_oldgcj_14_13_usable): Renamed from
2776         is_envjavac_gcj_14_13_usable.
2777         (is_gcj_present): Update.
2778         (is_gcj_43, is_gcj43_usable): New functions.
2779         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
2780         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
2781         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
2782         try the options -fsource and -ftarget.
2783
2784 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
2785
2786         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
2787         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
2788         larger value.
2789
2790 2007-02-03  Jim Meyering  <jim@meyering.net>
2791
2792         Give tools a better chance to allocate space for very large buffers.
2793         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
2794
2795         Make pwd and readlink work also when run with an unreadable parent dir
2796         on systems with openat support.
2797         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
2798         provided getcwd function, even when we have openat support.
2799         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
2800
2801 2007-02-02  Bruno Haible  <bruno@clisp.org>
2802
2803         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
2804         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
2805         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
2806         portability problems if one of these functions is only used on specific
2807         platforms.
2808         Reported by Paul Eggert.
2809
2810 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
2811
2812         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
2813         is causing more trouble than it's curing.
2814         * lib/regex_internal.h (__mempcpy): Remove.
2815         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
2816         (and make the code a tad smaller to boot).
2817         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
2818
2819 2007-02-02  Jim Meyering  <jim@meyering.net>
2820
2821         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
2822         section, not in the Makefile.am: one.
2823
2824 2007-02-02  Eric Blake  <ebb9@byu.net>
2825
2826         * lib/strchrnul.c: Always include config.h first.
2827
2828         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
2829         gnulib strstr is not necessary here.
2830
2831 2007-02-02  Simon Josefsson  <simon@josefsson.org>
2832
2833         * m4/socklen.m4: Fix typo.
2834
2835 2007-02-02  Eric Blake  <ebb9@byu.net>
2836
2837         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
2838         * modules/netinet_in (Makefile.am): Likewise.
2839
2840 2007-02-01  Bruno Haible  <bruno@clisp.org>
2841
2842         * lib/string_.h (GL_LINK_WARNING): New macro.
2843         (strcasecmp, strstr, strcasestr): If provided by the system,
2844         conditionally define as a macro that leads to a warning instead of to
2845         an error.
2846         (strncasecmp): Conditionally define as a macro that leads to a warning.
2847
2848 2007-02-01  Karl Berry  <karl@gnu.org>
2849
2850         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
2851
2852 2007-02-01  Bruno Haible  <bruno@clisp.org>
2853
2854         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
2855         renamings.
2856
2857 2007-02-01  Eric Blake  <ebb9@byu.net>
2858
2859         * modules/regex (Depends-on): Revert dependence on mempcpy.
2860         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
2861         module's definition of mempcpy.
2862         Reported by Paul Eggert.
2863
2864 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
2865
2866         * lib/string_.h: If the gnulib module XYZ is not present, undefine
2867         the symbol XYZ before redefining it.  This fixes a problem with
2868         programs that don't use XYZ, when compiled on systems that define
2869         XYZ to something else.
2870
2871 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
2872
2873         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
2874         occurs when "mkdir -m foo" creates a setgid directory that is (1)
2875         writeable to group or other and (2) is intended to have a special
2876         mode bit that is set or cleared.  In such a case, the directory
2877         should be neither group- nor other-writeable until the special
2878         mode bits are right.
2879
2880 2007-01-31  Eric Blake  <ebb9@byu.net>
2881
2882         * modules/mountlist (Depends-on): Add strstr.
2883
2884         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
2885         bug.
2886         * modules/string (Makefile.am): Remove redundant replacement.
2887         * modules/regex (Depends-on): Add mempcpy.
2888
2889 2007-01-31  Bruno Haible  <bruno@clisp.org>
2890
2891         New module description field 'Link'.
2892         * gnulib-tool (func_usage): Document --extract-link-directive.
2893         (sed_extract_prog): Recognize 'Link' directive.
2894         (func_get_link_directive): New function.
2895         (func_import): Show summary of link directives.
2896         Handle --extract-link-directive option.
2897         * modules/acl (Link): New section.
2898         * modules/clock-time (Link): New section.
2899         * modules/euidaccess (Link): New section.
2900         * modules/gettext (Link): New section.
2901         * modules/iconv (Link): New section.
2902         * modules/lock (Link): New section.
2903         * modules/nanosleep (Link): New section.
2904         * modules/readline (Link): New section.
2905
2906 2007-01-27  Bruno Haible  <bruno@clisp.org>
2907
2908         Enforce the use of gnulib modules for unportable <string.h> functions.
2909         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
2910         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
2911         (gl_HEADER_STRING_H_BODY): Require it.
2912         * lib/string_.h: If the gnulib module XYZ is not present, redefine
2913         the symbol XYZ to one that gives a link error.
2914         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
2915         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
2916         * modules/mempcpy (configure.ac): Likewise.
2917         * modules/memrchr (configure.ac): Likewise.
2918         * modules/stpcpy (configure.ac): Likewise.
2919         * modules/stpncpy (configure.ac): Likewise.
2920         * modules/strcase (configure.ac): Likewise.
2921         * modules/strcasestr (configure.ac): Likewise.
2922         * modules/strchrnul (configure.ac): Likewise.
2923         * modules/strdup (configure.ac): Likewise.
2924         * modules/strndup (configure.ac): Likewise.
2925         * modules/strnlen (configure.ac): Likewise.
2926         * modules/strpbrk (configure.ac): Likewise.
2927         * modules/strsep (configure.ac): Likewise.
2928         * modules/strstr (configure.ac): Likewise.
2929         * modules/strtok_r (configure.ac): Likewise.
2930
2931 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
2932
2933         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
2934
2935 2007-01-30  Jim Meyering  <jim@meyering.net>
2936
2937         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
2938
2939 2007-01-29  Bruno Haible  <bruno@clisp.org>
2940
2941         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
2942         * lib/execute.c: Likewise.
2943         * lib/pipe.c: Likewise.
2944         * lib/printf-args.h: Likewise.
2945         * lib/printf-args.c: Likewise.
2946         * lib/printf-parse.c: Likewise.
2947         * lib/vasnprintf.c: Likewise.
2948
2949 2007-01-29  Eric Blake  <ebb9@byu.net>
2950
2951         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
2952         declaration.
2953
2954 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
2955
2956         * lib/strptime.h (strptime): Use 'restrict' for args where
2957         POSIX requires this.
2958         * lib/strptime.c (strptime): Likewise.
2959         Change license notice from LGPL to GPL, since gnulib-tool will
2960         change this as needed.
2961         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
2962         defined.
2963         Include "strptime.h" first, to check interface.
2964         Do not #undef _LIBC and _NL_CURRENT.
2965         Do not include <stdlib.h>; no longer needed.
2966         Include "time_r.h" and declare ptime_locale_status
2967         only if _LIBC is not defined.
2968         (__P): Remove unused macro.
2969         (match_string): Bring back glibc version, but use it only if _LIBC
2970         is defined.
2971         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
2972         Remove unnecessary assertion and abort() call.
2973         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
2974         * m4/strptime.m4: Fix serial number comment.
2975         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
2976         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
2977         (Depends-on): Add time_r.
2978
2979 2007-01-29  Bruno Haible  <bruno@clisp.org>
2980
2981         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
2982         strptime.
2983         * modules/strptime (Depends-on): Add stdbool.
2984         * lib/strptime.h: Include <time.h> always. Add comments.
2985
2986 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
2987
2988         * modules/strptime: New file.
2989         * lib/strptime.h: New file.
2990         * lib/strptime.c: New file.
2991         * m4/strptime.m4: New file.
2992
2993 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
2994
2995         * MODULES.html.sh: New module mpsort.
2996         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
2997
2998         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
2999         a circularity problem with HP-UX ia64 reported by Bob Proulx in
3000         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
3001         All uses changed.
3002         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
3003         All uses changed.
3004         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
3005         to _Restrict_.
3006         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
3007         the parameter matches the prototype.
3008
3009 2007-01-28  Jim Meyering  <jim@meyering.net>
3010
3011         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
3012         sys/time.h here, reverting that part of the previous patch:
3013         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
3014
3015 2007-01-28  Bruno Haible  <bruno@clisp.org>
3016
3017         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
3018         value of $(SYS_TIME_H).
3019         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
3020         remove it conditionally, too. [added by Jim Meyering]
3021         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
3022         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
3023         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
3024         GETTIMEOFDAY_REPLACEMENT to 1.
3025
3026 2007-01-28  Bruno Haible  <bruno@clisp.org>
3027
3028         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
3029         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
3030         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
3031         Set UNISTD_H instead of UNISTD_H2.
3032         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
3033
3034 2007-01-28  Bruno Haible  <bruno@clisp.org>
3035
3036         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
3037         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
3038
3039 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3040
3041         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
3042         (func_create_testdir): Ensure C locale for `grep' and `tr'
3043         character ranges.
3044         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
3045         ACLOCAL_AMFLAGS parsing state machine.
3046
3047 2007-01-27  Bruno Haible  <bruno@clisp.org>
3048
3049         * modules/unistr/base: Update.
3050
3051 2007-01-27  Bruno Haible  <bruno@clisp.org>
3052
3053         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
3054         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
3055         * modules/unistr/u32-mbtouc-unsafe: Renamed from
3056         modules/unistr/u32-mbtouc.
3057         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
3058         * lib/unistr.h: Update.
3059         * lib/linebreak.c: Update.
3060         * modules/unistr/u32-mbtouc: Renamed from
3061         modules/unistr/u32-mbtouc-safe.
3062         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
3063         * lib/unistr.h: Update.
3064         * lib/unistr/u32-to-u8.c: Update.
3065         * lib/unistr/u32-to-u16.c: Update.
3066
3067 2007-01-27  Bruno Haible  <bruno@clisp.org>
3068
3069         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
3070         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
3071         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
3072         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
3073         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
3074         * modules/unistr/u16-mbtouc-unsafe: Renamed from
3075         modules/unistr/u16-mbtouc.
3076         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
3077         * lib/unistr.h: Update.
3078         * lib/linebreak.c: Update.
3079         * modules/linebreak: Update.
3080         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
3081         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
3082         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
3083         * modules/unistr/u16-mbtouc: Renamed from
3084         modules/unistr/u16-mbtouc-safe.
3085         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
3086         * lib/unistr.h: Update.
3087         * lib/unistr/u16-to-u8.c: Update.
3088         * modules/unistr/u16-to-u8: Update.
3089         * lib/unistr/u16-to-u32.c: Update.
3090         * modules/unistr/u16-to-u32: Update.
3091
3092 2007-01-27  Bruno Haible  <bruno@clisp.org>
3093
3094         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
3095         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
3096         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
3097         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
3098         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
3099         * modules/unistr/u8-mbtouc-unsafe: Renamed from
3100         modules/unistr/u8-mbtouc.
3101         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
3102         * lib/unistr.h: Update.
3103         * lib/striconveh.c: Update.
3104         * modules/striconveh: Update.
3105         * lib/linebreak.c: Update.
3106         * modules/linebreak: Update.
3107         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
3108         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
3109         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
3110         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
3111         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
3112         * lib/unistr.h: Update.
3113         * lib/striconveh.c: Update.
3114         * modules/striconveh: Update.
3115         * lib/unistr/u8-to-u16.c: Update.
3116         * modules/unistr/u8-to-u16: Update.
3117         * lib/unistr/u8-to-u32.c: Update.
3118         * modules/unistr/u8-to-u32: Update.
3119
3120 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3121
3122         Sync from Libtool.
3123         * lib/argz.c: Do not include strings.h nor memory.h, include
3124         string.h unconditionally.  Patch by Simon Josefsson.
3125
3126 2007-01-27  Bruno Haible  <bruno@clisp.org>
3127
3128         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
3129         from gl_HEADER_STRING_H_BODY.
3130         (gl_HEADER_STRING_H_BODY): Require it.
3131         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
3132         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
3133         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
3134         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
3135         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
3136         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
3137         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
3138         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
3139         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
3140         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
3141         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
3142         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
3143         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
3144         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
3145         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
3146
3147 2007-01-27  Bruno Haible  <bruno@clisp.org>
3148
3149         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
3150         check_PROGRAMS into noinst_PROGRAMS.
3151         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
3152         check_PROGRAMS in this case.
3153         (func_import): Set for_test to false.
3154         (func_create_testdir): Set for_test to true.
3155
3156 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
3157             Bruno Haible  <bruno@clisp.org>
3158
3159         * modules/strcasestr (Files): Remove lib/strcasestr.h.
3160         (Depends-on): Add string.
3161         (Includes): Use <string.h> instead of strcasestr.h.
3162         * modules/string (Makefile.am): Also substitute the value of
3163         REPLACE_STRCASESTR.
3164         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
3165         assume strcasestr is declared in <string.h> not <strings.h>. Also
3166         set REPLACE_STRCASESTR.
3167         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
3168         REPLACE_STRCASESTR.
3169         * lib/strcasestr.h: Remove file.
3170         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
3171         * lib/string_.h (strcasestr): New declaration.
3172
3173 2007-01-27  Bruno Haible  <bruno@clisp.org>
3174
3175         * lib/string_.h: Use 'extern'.
3176
3177 2007-01-27  Jim Meyering  <jim@meyering.net>
3178
3179         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
3180         of set-but-not-used local, "q".
3181
3182         * lib/mempcpy.c: Include <config.h> before <string.h>.
3183         This fixes a compilation error on HP-UX, due to the system's
3184         "restrict"-using mempcpy prototype.
3185
3186 2007-01-26  Bruno Haible  <bruno@clisp.org>
3187
3188         Small optimization.
3189         * lib/javacomp.c: Include c-strstr.h.
3190          (is_envjavac_gcj): Use c_strstr instead of strstr.
3191         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
3192
3193 2007-01-26  Bruno Haible  <bruno@clisp.org>
3194
3195         * MODULES.html.sh (Unicode string functions): Add the new modules.
3196
3197         * modules/uniconv/u32-strconv-to-locale: New file.
3198         * lib/uniconv/u32-strconv-to-locale.c: New file.
3199
3200         * modules/uniconv/u16-strconv-to-locale: New file.
3201         * lib/uniconv/u16-strconv-to-locale.c: New file.
3202
3203         * modules/uniconv/u8-strconv-to-locale: New file.
3204         * lib/uniconv/u8-strconv-to-locale.c: New file.
3205
3206         * modules/uniconv/u32-strconv-from-locale: New file.
3207         * lib/uniconv/u32-strconv-from-locale.c: New file.
3208
3209         * modules/uniconv/u16-strconv-from-locale: New file.
3210         * lib/uniconv/u16-strconv-from-locale.c: New file.
3211
3212         * modules/uniconv/u8-strconv-from-locale: New file.
3213         * lib/uniconv/u8-strconv-from-locale.c: New file.
3214
3215         * modules/uniconv/u32-strconv-to-enc: New file.
3216         * lib/uniconv/u32-strconv-to-enc.c: New file.
3217         * modules/uniconv/u32-strconv-to-enc-tests: New file.
3218         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
3219
3220         * modules/uniconv/u16-strconv-to-enc: New file.
3221         * lib/uniconv/u16-strconv-to-enc.c: New file.
3222         * lib/uniconv/u-strconv-to-enc.h: New file.
3223         * modules/uniconv/u16-strconv-to-enc-tests: New file.
3224         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
3225
3226         * modules/uniconv/u8-strconv-to-enc: New file.
3227         * lib/uniconv/u8-strconv-to-enc.c: New file.
3228         * modules/uniconv/u8-strconv-to-enc-tests: New file.
3229         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
3230
3231         * modules/uniconv/u32-strconv-from-enc: New file.
3232         * lib/uniconv/u32-strconv-from-enc.c: New file.
3233         * modules/uniconv/u32-strconv-from-enc-tests: New file.
3234         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
3235
3236         * modules/uniconv/u16-strconv-from-enc: New file.
3237         * lib/uniconv/u16-strconv-from-enc.c: New file.
3238         * modules/uniconv/u16-strconv-from-enc-tests: New file.
3239         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
3240
3241         * modules/uniconv/u8-strconv-from-enc: New file.
3242         * lib/uniconv/u8-strconv-from-enc.c: New file.
3243         * lib/uniconv/u-strconv-from-enc.h: New file.
3244         * modules/uniconv/u8-strconv-from-enc-tests: New file.
3245         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
3246
3247         * modules/uniconv/u32-conv-from-enc: New file.
3248         * lib/uniconv/u32-conv-from-enc.c: New file.
3249         * modules/uniconv/u32-conv-from-enc-tests: New file.
3250         * tests/uniconv/test-u32-conv-from-enc.c: New file.
3251
3252         * modules/uniconv/u16-conv-from-enc: New file.
3253         * lib/uniconv/u16-conv-from-enc.c: New file.
3254         * lib/uniconv/u-conv-from-enc.h: New file.
3255         * modules/uniconv/u16-conv-from-enc-tests: New file.
3256         * tests/uniconv/test-u16-conv-from-enc.c: New file.
3257
3258         * modules/uniconv/u8-conv-from-enc: New file.
3259         * lib/uniconv/u8-conv-from-enc.c: New file.
3260         * modules/uniconv/u8-conv-from-enc-tests: New file.
3261         * tests/uniconv/test-u8-conv-from-enc.c: New file.
3262
3263         * modules/uniconv/base: New file.
3264         * lib/uniconv.h: New file.
3265
3266 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
3267
3268         * doc/gnulib-tool.texi (Initial import): Update to match current
3269         behavior with strdup module.
3270         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
3271         * lib/memmem.h: Remove; all uses removed.  This is now done
3272         by <string.h>.
3273         * lib/mempcpy.h: Likewise.
3274         * lib/memrchr.h: Likewise.
3275         * lib/stpcpy.h: Likewise.
3276         * lib/stpncpy.h: Likewise.
3277         * lib/strcase.h: Likewise.
3278         * lib/strchrnul.h: Likewise.
3279         * lib/strdup.h: Likewise.
3280         * lib/strndup.h: Likewise.
3281         * lib/strnlen.h: Likewise.
3282         * lib/strpbrk.h: Likewise.
3283         * lib/strsep.h: Likewise.
3284         * lib/strstr.h: Likewise.
3285         * lib/strtok_r.h: Likewise.
3286         * lib/string_.h: New file.
3287         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
3288         Rely on <string.h> instead.
3289         * lib/canon-host.c: Likewise.
3290         * lib/chdir-long.c: Likewise.
3291         * lib/concatpath.c: Likewise.
3292         * lib/exclude.c: Likewise.
3293         * lib/fchdir.c: Likewise.
3294         * lib/getaddrinfo.c: Likewise.
3295         * lib/getcwd.c: Likewise.
3296         * lib/getsubopt.c: Likewise.
3297         * lib/glob.c: Likewise.
3298         * lib/hard-locale.c: Likewise.
3299         * lib/iconvme.c: Likewise.
3300         * lib/javacomp.c: Likewise.
3301         * lib/mempcpy.c: Likewise.
3302         * lib/memrchr.c: Likewise.
3303         * lib/regex_internal.h: Likewise.
3304         * lib/stpncpy.c: Likewise.
3305         * lib/strcasecmp.c: Likewise.
3306         * lib/strchrnul.c: Likewise.
3307         * lib/strdup.c: Likewise.
3308         * lib/striconv.c: Likewise.
3309         * lib/striconveh.c: Likewise.
3310         * lib/striconveha.c: Likewise.
3311         * lib/strncasecmp.c: Likewise.
3312         * lib/strndup.c: Likewise.
3313         * lib/strnlen.c: Likewise.
3314         * lib/strsep.c: Likewise.
3315         * lib/strstr.c: Likewise.
3316         * lib/strtok_r.c: Likewise.
3317         * lib/userspec.c: Likewise.
3318         * lib/w32spawn.h: Likewise.
3319         * lib/xstrndup.c: Likewise.
3320         * lib/mountlist.c (strstr): Remove decl.
3321         * m4/string_h.m4: New file.
3322         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
3323         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
3324         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
3325         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
3326         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
3327         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
3328         Set REPLACE_STRCASECMP if necessary.
3329         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
3330         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
3331         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
3332         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
3333         HAVE_DECL_STRDUP if necessary.
3334         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
3335         since gl_FUNC_STRNDUP does that now.
3336         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
3337         Check for decl here...
3338         (gl_PREREQ_STRNLEN): ... not here.
3339         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
3340         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
3341         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
3342         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
3343         necessary.
3344         * modules/string: New file.
3345         * modules/memmem (Files): Remove special-purpose include file.
3346         (Depends-on): Add string.
3347         (Include): Include <string.h>, not the removed file.
3348         * modules/mempcpy: Likewise.
3349         * modules/memrchr: Likewise.
3350         * modules/stpcpy: Likewise.
3351         * modules/stpncpy: Likewise.
3352         * modules/strcase: Likewise.
3353         * modules/strchrnul: Likewise.
3354         * modules/strdup: Likewise.
3355         * modules/strndup: Likewise.
3356         * modules/strnlen: Likewise.
3357         * modules/strpbrk: Likewise.
3358         * modules/strsep: Likewise.
3359         * modules/strstr: Likewise.
3360         * modules/strtok_r: Likewise.
3361         * tests/test-dirname.c: Don't include "strdup.h", since
3362         <string.h> now suffices.
3363         * tests/test-memmem.c: Don't include "memmem.h", since
3364         <string.h> now suffices.
3365
3366 2007-01-25  Bruno Haible  <bruno@clisp.org>
3367
3368         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
3369         *resultp is 0.
3370
3371         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
3372         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
3373         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
3374         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
3375
3376         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
3377         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
3378         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
3379         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
3380         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
3381         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
3382
3383 2007-01-24  Bruno Haible  <bruno@clisp.org>
3384
3385         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
3386         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
3387         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
3388         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
3389         gl_FUNC_FTS_CORE.
3390         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
3391         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
3392         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
3393         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
3394         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
3395         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
3396         gl_FUNC_FCHOWNAT.
3397         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
3398         gl_FUNC_STRFTIME.
3399         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
3400         Reported by Ralf Wildenhues.
3401
3402 2007-01-24  Bruno Haible  <bruno@clisp.org>
3403
3404         Drop AC_REQUIRE calls that are redundant with the module dependencies.
3405         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
3406         gl_GETADDRINFO.
3407         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
3408         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
3409         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
3410
3411 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
3412
3413         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
3414         Don't use 'exit'; just return from 'main'.
3415         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
3416
3417         * lib/fnmatch_.h: Readjust white space and comments to match
3418         glibc, to avoid spurious diffs.
3419
3420 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
3421
3422         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
3423         2004-12-01 change by Jakub Jelinek, since this code won't compile
3424         if !LIBC.  Problem reported by Bob Proulx.
3425
3426 2007-01-23  Bruno Haible  <bruno@clisp.org>
3427
3428         * lib/striconveh.c: Include c-strcaseeq.h.
3429         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
3430         * modules/striconveh (Depends-on): Add c-strcaseeq.
3431
3432 2007-01-23  Bruno Haible  <bruno@clisp.org>
3433
3434         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
3435
3436         * modules/c-strcaseeq: New file.
3437         * lib/c-strcaseeq.h: New file.
3438
3439         * modules/streq: New file.
3440         * lib/streq.h: New file.
3441
3442 2007-01-23  Bruno Haible  <bruno@clisp.org>
3443
3444         * modules/striconveha-tests: New file.
3445         * tests/test-striconveha.c: New file.
3446
3447         * lib/striconveha.h: Include <stdbool.h>.
3448         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
3449         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
3450         (mem_iconveha_notranslit): Renamed from mem_iconveha.
3451         (mem_iconveha): New function.
3452         (str_iconveha_notranslit): Renamed from str_iconveha.
3453         (str_iconveha): New function.
3454         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
3455         c-strcase.
3456
3457 2007-01-23  Bruno Haible  <bruno@clisp.org>
3458
3459         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
3460         encodings without forgiving before trying any encoding with handler.
3461         (str_iconveha): Try all encodings without forgiving before trying any
3462         encoding with handler.
3463
3464 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
3465
3466         Import the following changes from libc.
3467
3468         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
3469
3470         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
3471
3472         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
3473
3474         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
3475         normal_bracket label.
3476
3477         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
3478
3479         [BZ #361]
3480         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
3481         to normal_bracket after fetching the next character.
3482
3483 2007-01-22  Bruno Haible  <bruno@clisp.org>
3484
3485         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
3486         argument.
3487         * lib/striconveh.c (iconv_carefully_1): New function.
3488         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
3489         argument.
3490         (str_cd_iconveh): Update.
3491         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
3492         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
3493         * tests/test-striconveh.c (MAGIC): New macro.
3494         (new_offsets): New function.
3495         (main): Test call with and without offsets.
3496
3497 2007-01-22  Bruno Haible  <bruno@clisp.org>
3498
3499         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
3500         * modules/sys_select (Makefile.am): Likewise.
3501         * modules/sys_socket (Makefile.am): Likewise.
3502         * modules/sys_time (Makefile.am): Likewise.
3503
3504 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
3505
3506         * modules/gettimeofday (License): Change from GPL to LGPL, since
3507         gettimeofday is a library function.
3508
3509 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
3510
3511         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
3512
3513 2007-01-21  Bruno Haible  <bruno@clisp.org>
3514
3515         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
3516
3517 2007-01-21  Bruno Haible  <bruno@clisp.org>
3518
3519         * modules/striconveha: New file.
3520         * lib/striconveha.h: New file.
3521         * lib/striconveha.c: New file.
3522         * MODULES.html.sh (Internationalization functions): Add striconveha.
3523         * lib/striconv.c (str_iconv): Optimize the case of an empty input
3524         string.
3525         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
3526
3527 2007-01-21  Bruno Haible  <bruno@clisp.org>
3528
3529         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
3530         * lib/striconveh.c (str_iconveh): Likewise.
3531
3532 2007-01-21  Bruno Haible  <bruno@clisp.org>
3533
3534         * lib/striconveh.h (mem_iconveh): New declaration.
3535         * lib/striconveh.c (mem_iconveh): New function.
3536         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
3537
3538 2007-01-21  Bruno Haible  <bruno@clisp.org>
3539
3540         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
3541
3542         * lib/striconveh.h (mem_cd_iconveh): Change specification.
3543         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
3544         original result buffer.
3545         (str_cd_iconveh): Update.
3546         * tests/test-striconveh.c (main): Update.
3547
3548         * lib/striconv.h (mem_cd_iconv): Change specification.
3549         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
3550         result buffer.
3551         (str_cd_iconv): Update.
3552         * tests/test-striconv.c (main): Update.
3553
3554 2007-01-21  Bruno Haible  <bruno@clisp.org>
3555
3556         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
3557
3558 2007-01-20  Jim Meyering  <jim@meyering.net>
3559
3560         * lib/userspec.c (parse_with_separator): If a user or group string
3561         starts with "+", skip the corresponding name-to-ID look-up, since
3562         such a look-up must fail: user and group names may not include "+".
3563
3564 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
3565
3566         * lib/poll.c: Include sys/time.h and time.h unconditionally,
3567         since we now assume the sys_time module.
3568         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
3569         check for sys/time.h; no longer needed.
3570         * modules/poll (Depends-on): Depend on sys_time.
3571
3572 2007-01-18  Bruno Haible  <bruno@clisp.org>
3573
3574         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
3575         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
3576
3577         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
3578         gettimeofday.
3579
3580         * tests/test-gettimeofday.c: Include <time.h>.
3581         (dummy): Remove variable.
3582
3583         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
3584         gl_HEADER_SYS_TIME_H.
3585         (gl_HEADER_SYS_TIME_H): New macro.
3586
3587         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
3588         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3589         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
3590         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
3591         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3592         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
3593         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
3594         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3595         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
3596         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
3597         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3598
3599         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
3600         last change; it caused a compilation error when cross-compiling to
3601         Cygwin.
3602
3603 2007-01-18  Jim Meyering  <jim@meyering.net>
3604
3605         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
3606         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
3607         than the race-prone "test -d sys || mkdir sys".
3608         (configure.ac): Use AC_PROG_MKDIR_P.
3609         * modules/sys_select: Likewise.
3610         * modules/sys_socket: Likewise.
3611         * modules/sys_time: Likewise.
3612
3613 2007-01-18  Eric Blake  <ebb9@byu.net>
3614
3615         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
3616         replace gettimeofday.
3617         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
3618         name, to avoid infinite recursion.
3619
3620 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
3621
3622         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
3623         module sys_time.
3624         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
3625         assume timespec.h defines struct timeval.
3626         * lib/settime.c: Likewise.
3627         * lib/utimens.c: Likewise.
3628         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
3629         since we now assume the gettimeofday module.
3630         * lib/tempname.c (__gen_tempname): Likewise.
3631         * lib/gettimeofday.h: Remove.
3632         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
3633         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
3634         Include <time.h>, for 'time()'.
3635         (localtime_buffer_addr): Also use this workaround if
3636         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
3637         to simplify the uses.  All uses changed.
3638         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
3639         that #undef is inside {}, and 'const' follows type name consistently.
3640         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
3641         (gettimeofday): Do not use the maximum possible value for
3642         tv->tv_usec, since that might break usages other than ls.c.
3643         Instead, we'll leave ls.c alone.  This undoes today's patch
3644         by Bruno.  Add a compile-time warning for 1s-clock resolution;
3645         we've never observed the problem but might as well keep the
3646         canary.
3647         * lib/nanosleep.c: Include timespec.h first, for interface check.
3648         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
3649         now assume the sys_time module.
3650         * lib/tempname.c: Likewise.
3651         * lib/timespec.h: Likewise.
3652         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
3653         needed.
3654         * lib/strftime.c: Likewise.
3655         * lib/timespec.h: Likewise.
3656         * lib/posixtm.c: Include posixtm.h first, for interface check.
3657         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
3658         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
3659         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
3660         * lib/sys_time_.h: New file.
3661         * lib/timespec.h (struct timespec): Use long int, not long.
3662         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
3663         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
3664         Remove obsolescent call to AC_HEADER_TIME.
3665         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
3666         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
3667         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
3668         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
3669         Likewise.
3670         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
3671         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
3672         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
3673         into the sys_time module.  Check for gettimeofday just once.
3674         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
3675         for gettimeofday signature to just check the signature.  Merely
3676         compile it, since linking doesn't test signature.  Improve test for
3677         whether gettimeofday.o is actually needed.
3678         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
3679         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
3680         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
3681         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3682         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
3683         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
3684         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
3685         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
3686         than worrying about sys/time.h.
3687         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
3688         Don't bother worrying about TIME_WITH_SYS_TIME.
3689         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
3690         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
3691         * m4/sys_time_h.m4: New file.
3692         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
3693         Don't include sys/time.h.  Return from main rather than exiting.
3694         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
3695         all uses changed.
3696         * modules/gethrxtime (Depends-on): Add sys_time.
3697         * modules/gettime (Depends-on): Likewise.
3698         * modules/gettimeofday (Depends-on): Likewise.
3699         * modules/nanosleep (Depends-on): Likewise.
3700         * modules/settime (Depends-on): Likewise.
3701         * modules/tempname (Depends-on): Likewise.
3702         * modules/utimens (Depends-on): Likewise.
3703         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
3704         (Include:) Change back to <sys/time.h>.
3705         (Maintainer:) Add self.
3706         * modules/sys_time: New file.
3707         * modules/tempname (Depends-on): Add gettimeofday.
3708         * tests/test-gettimeofday.c: Include <sys/time.h>
3709         rather than gettimeofday.h.
3710
3711 2007-01-17  Bruno Haible  <bruno@clisp.org>
3712
3713         * gnulib-tool (func_get_license): Revert last patch. Instead, let
3714         the license default to GPL.
3715         (func_create_testdir): Don't complain if a module is LGPL and its
3716         tests module depends on GPLed modules.
3717
3718 2007-01-17  Bruno Haible  <bruno@clisp.org>
3719
3720         * lib/gettimeofday.c (gettimeofday): Add code for the case
3721         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
3722         maximum possible value for tv->tv_usec, rather than the minimum one.
3723
3724 2005-10-08  Martin Lambers  <marlam@marlam.de>
3725 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
3726 2007-01-16  Bruno Haible  <bruno@clisp.org>
3727
3728         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
3729         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
3730         gl_FUNC_GETTIMEOFDAY.
3731         (Include): Add gettimeofday.h.
3732         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
3733         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
3734         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
3735         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
3736         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
3737         * lib/gettimeofday.h: New file.
3738         * lib/gettimeofday.c: Include <sys/timeb.h>.
3739         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
3740         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3741         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
3742         fall back on time().
3743
3744         * tests/test-gettimeofday.c: New file.
3745         * modules/gettimeofday-tests: New file.
3746
3747 2007-01-16  Eric Blake  <ebb9@byu.net>
3748
3749         * modules/fnmatch (Depends-on): Depend on wchar.
3750         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
3751         * m4/fnmatch.m4: Likewise.
3752         * modules/mbchar (Makefile.am): Assume <wchar.h>.
3753         * m4/mbchar.m4: Likewise.
3754         * modules/mbswidth (Depends-on): Depend on wchar.
3755         * lib/mbswidth.c: Assume <wchar.h>.
3756         * m4/mbswidth.m4: Likewise.
3757         * modules/quotearg (Depends-on): Depend on wchar.
3758         * lib/quotearg.c: Assume <wchar.h>.
3759         * m4/quotearg.m4: Likewise.
3760         * modules/regex (Depends-on): Depend on wchar.
3761         * lib/regex_internal.h: Assume <wchar.h>.
3762         * m4/regex.m4: Likewise.
3763         * modules/stdint (Depends-on): Depend on wchar.
3764         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
3765         * m4/stdint.m4: Likewise.
3766         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
3767         * modules/strftime (Depends-on): Depend on wchar.
3768         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
3769         * modules/strtol (Depends-on): Depend on wchar.
3770         * lib/strtol.c: Assume <wchar.h>.
3771         * modules/wcwidth (Depends-on): Depend on wchar.
3772         * lib/wcwidth.h: Assume <wchar.h>.
3773         * m4/wcwidth.m4: Likewise.
3774
3775 2007-01-16  Bruno Haible  <bruno@clisp.org>
3776
3777         * modules/csharpexec-script: New, created from...
3778         * modules/csharpexec: ... this.
3779
3780 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
3781
3782         * modules/javaexec-script: New, created from...
3783         * modules/javaexec: ... this.
3784
3785 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
3786
3787         * modules/poll (Dependencies): Add sys_select.
3788
3789 2007-01-15  Jim Meyering  <jim@meyering.net>
3790
3791         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
3792         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
3793         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
3794         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
3795
3796 2007-01-15  Bruno Haible  <bruno@clisp.org>
3797
3798         * modules/striconveh: New file.
3799         * lib/striconveh.h: New file.
3800         * lib/striconveh.c: New file.
3801         * MODULES.html.sh (Internationalization functions): Add striconveh.
3802
3803         * modules/striconveh-tests: New file.
3804         * tests/test-striconveh.c: New file.
3805
3806 2007-01-15  Bruno Haible  <bruno@clisp.org>
3807
3808         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
3809         not from GNU libiconv or GNU libc.
3810
3811 2007-01-15  Bruno Haible  <bruno@clisp.org>
3812
3813         * doc/gnulib-intro.texi (Copyright): Explain the different license
3814         terms for module descriptions, autoconf macros, tests, documentation.
3815
3816 2007-01-14  Bruno Haible  <bruno@clisp.org>
3817
3818         * modules/striconv-tests: New file.
3819         * tests/test-striconv.c: New file.
3820
3821 2007-01-14  Bruno Haible  <bruno@clisp.org>
3822
3823         * modules/iconv-tests: New file.
3824         * tests/test-iconv.c: New file.
3825
3826 2007-01-14  Bruno Haible  <bruno@clisp.org>
3827
3828         * gnulib-tool (func_get_license): For test modules, use the license of
3829         the main module.
3830
3831 2007-01-14  Bruno Haible  <bruno@clisp.org>
3832
3833         * modules/iconv (Include): Clarify that <iconv.h> can only be included
3834         if iconv is found to exist.
3835
3836 2007-01-14  Bruno Haible  <bruno@clisp.org>
3837
3838         * modules/c-ctype-tests: New file.
3839         * tests/test-c-ctype.c: New file.
3840
3841 2007-01-14  Bruno Haible  <bruno@clisp.org>
3842
3843         * modules/binary-io-tests: New file.
3844         * tests/test-binary-io.sh: New file.
3845         * tests/test-binary-io.c: New file.
3846
3847 2007-01-14  Bruno Haible  <bruno@clisp.org>
3848
3849         * modules/array-oset-tests: New file.
3850         * tests/test-array_oset.c: New file.
3851
3852 2007-01-14  Bruno Haible  <bruno@clisp.org>
3853
3854         * modules/array-list-tests: New file.
3855         * tests/test-array_list.c: New file.
3856
3857 2007-01-14  Bruno Haible  <bruno@clisp.org>
3858
3859         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
3860         and make.
3861         Reported by Simon Josefsson in
3862         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
3863
3864 2007-01-14  Bruno Haible  <bruno@clisp.org>
3865
3866         * modules/allocsa-tests: New file.
3867         * tests/test-allocsa.c: New file.
3868
3869 2007-01-14  Bruno Haible  <bruno@clisp.org>
3870
3871         * modules/fchdir (Depends-on): Add absolute-header.
3872         * modules/unistd (Depends-on): Likewise.
3873
3874 2006-12-30  Bruno Haible  <bruno@clisp.org>
3875
3876         * modules/fchdir: New file.
3877         * modules/unistd (Files): Add lib/unistd_.h.
3878         (Makefile.am): Generate unistd.h from unistd_.h.
3879         * lib/fchdir.c: New file.
3880         * lib/dirent_.h: New file.
3881         * lib/unistd_.h: New file.
3882         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
3883         * m4/fchdir.m4: New file.
3884         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
3885         (gl_HEADER_UNISTD): Invoke it.
3886         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
3887         function.
3888         * lib/backupfile.c (opendir, closedir): Undefine.
3889         * lib/chown.c (open, close): Undefine.
3890         * lib/clean-temp.c (open, close): Undefine.
3891         * lib/copy-file.c (open, close): Undefine.
3892         * lib/execute.c (open, close): Undefine.
3893         * lib/fsusage.c (open, close): Undefine.
3894         * lib/gc-gnulib.c (open, close): Undefine.
3895         * lib/getcwd.c (opendir, closedir): Undefine.
3896         * lib/glob.c (opendir, closedir): Undefine.
3897         * lib/javacomp.c (open, close): Undefine.
3898         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
3899         * lib/openat-proc.c (open, close): Undefine.
3900         * lib/pagealign_alloc.c (open, close): Undefine.
3901         * lib/pipe.c (open, close): Undefine.
3902         * lib/progreloc.c (open, close): Undefine.
3903         * lib/savedir.c (opendir, closedir): Undefine.
3904         * lib/utime.c (open, close): Undefine.
3905         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
3906
3907 2007-01-10  Bruno Haible  <bruno@clisp.org>
3908
3909         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
3910
3911 2007-01-12  Eric Blake  <ebb9@byu.net>
3912
3913         Provide a robust <wchar.h>.  Further simplifications are now
3914         possible in other modules, but not included here.
3915         * modules/wchar: New module.
3916         * m4/wchar.m4: New file.
3917         * lib/wchar_.h: Likewise.
3918         * modules/mbchar (Depends-on): Depend on wchar, as the first use
3919         of the new module.
3920         * MODULES.html.sh (Extended multibyte and wide character utilities):
3921         New section.
3922
3923 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
3924
3925         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
3926         to a reasonable default for memory allocation.
3927         (xreadlink): Don't allocate a huge buffer, to work around a buggy
3928         file system that reports garbage st_size values for symlinks.
3929         Problem reported by Liyang Hu.
3930
3931 2007-01-11  Simon Josefsson  <simon@josefsson.org>
3932
3933         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
3934         Emacs .#* auto-save files).
3935
3936 2007-01-11  Bruno Haible  <bruno@clisp.org>
3937
3938         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
3939         directory.
3940
3941 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
3942
3943         Use @...@ consistently in lib/wctype_.h.
3944         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
3945         on it being set to 1 or 0.
3946         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
3947         go back to AC_SUBSTing it.
3948         * modules/wctype (Makefile.am): Undo previous change.
3949
3950 2007-01-10  Eric Blake  <ebb9@byu.net>
3951
3952         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
3953         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
3954         * modules/wctype (Makefile.am): Likewise.
3955         Reported by Chris McGuire.
3956
3957 2007-01-10  Jim Meyering  <jim@meyering.net>
3958
3959         fts.c: a small readability/maintainability improvement
3960         * lib/fts.c (fts_read): Make this code slightly more readable and
3961         maintainable by hoisting the "sp->fts_cur = p" assignments to
3962         immediately follow the statements that set P.  Derived from
3963         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
3964
3965 2007-01-10  Eric Blake  <ebb9@byu.net>
3966
3967         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
3968         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
3969         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
3970         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
3971         Reported by Chris McGuire.
3972
3973 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3974
3975         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
3976         in sed script.
3977
3978 2007-01-09  Bruno Haible  <bruno@clisp.org>
3979
3980         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
3981         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
3982         variables.
3983         (func_module): Use them.
3984
3985 2007-01-09  Bruno Haible  <bruno@clisp.org>
3986
3987         * modules/unistr/base: New file.
3988         * lib/unistr.h: New file.
3989
3990         * modules/unistr/u8-to-u16: New file.
3991         * lib/unistr/u8-to-u16.c: New file.
3992
3993         * modules/unistr/u8-to-u32: New file.
3994         * lib/unistr/u8-to-u32.c: New file.
3995
3996         * modules/unistr/u16-to-u8: New file.
3997         * lib/unistr/u16-to-u8.c: New file.
3998
3999         * modules/unistr/u16-to-u32: New file.
4000         * lib/unistr/u16-to-u32.c: New file.
4001
4002         * modules/unistr/u32-to-u8: New file.
4003         * lib/unistr/u32-to-u8.c: New file.
4004
4005         * modules/unistr/u32-to-u16: New file.
4006         * lib/unistr/u32-to-u16.c: New file.
4007
4008         * modules/unistr/u8-check: New file.
4009         * modules/unistr/u16-check: New file.
4010         * modules/unistr/u32-check: New file.
4011         * lib/unistr/u8-check.c: New file.
4012         * lib/unistr/u16-check.c: New file.
4013         * lib/unistr/u32-check.c: New file.
4014
4015         * modules/unistr/u8-chr: New file.
4016         * modules/unistr/u16-chr: New file.
4017         * modules/unistr/u32-chr: New file.
4018         * lib/unistr/u8-chr.c: New file.
4019         * lib/unistr/u16-chr.c: New file.
4020         * lib/unistr/u32-chr.c: New file.
4021
4022         * modules/unistr/u8-cmp: New file.
4023         * modules/unistr/u16-cmp: New file.
4024         * modules/unistr/u32-cmp: New file.
4025         * lib/unistr/u8-cmp.c: New file.
4026         * lib/unistr/u16-cmp.c: New file.
4027         * lib/unistr/u32-cmp.c: New file.
4028
4029         * modules/unistr/u8-cpy: New file.
4030         * modules/unistr/u16-cpy: New file.
4031         * modules/unistr/u32-cpy: New file.
4032         * lib/unistr/u8-cpy.c: New file.
4033         * lib/unistr/u16-cpy.c: New file.
4034         * lib/unistr/u32-cpy.c: New file.
4035         * lib/unistr/u-cpy.h: New file.
4036
4037         * modules/unistr/u8-cpy-alloc: New file.
4038         * modules/unistr/u16-cpy-alloc: New file.
4039         * modules/unistr/u32-cpy-alloc: New file.
4040         * lib/unistr/u8-cpy-alloc.c: New file.
4041         * lib/unistr/u16-cpy-alloc.c: New file.
4042         * lib/unistr/u32-cpy-alloc.c: New file.
4043         * lib/unistr/u-cpy-alloc.h: New file.
4044
4045         * modules/unistr/u8-endswith: New file.
4046         * modules/unistr/u16-endswith: New file.
4047         * modules/unistr/u32-endswith: New file.
4048         * lib/unistr/u8-endswith.c: New file.
4049         * lib/unistr/u16-endswith.c: New file.
4050         * lib/unistr/u32-endswith.c: New file.
4051         * lib/unistr/u-endswith.h: New file.
4052
4053         * modules/unistr/u8-mblen: New file.
4054         * modules/unistr/u16-mblen: New file.
4055         * modules/unistr/u32-mblen: New file.
4056         * lib/unistr/u8-mblen.c: New file.
4057         * lib/unistr/u16-mblen.c: New file.
4058         * lib/unistr/u32-mblen.c: New file.
4059
4060         * modules/unistr/u8-mbtouc: New file.
4061         * modules/unistr/u16-mbtouc: New file.
4062         * modules/unistr/u32-mbtouc: New file.
4063         * lib/unistr/u8-mbtouc.c: New file.
4064         * lib/unistr/u16-mbtouc.c: New file.
4065         * lib/unistr/u32-mbtouc.c: New file.
4066
4067         * modules/unistr/u8-mbtouc-safe: New file.
4068         * modules/unistr/u16-mbtouc-safe: New file.
4069         * modules/unistr/u32-mbtouc-safe: New file.
4070         * lib/unistr/u8-mbtouc-safe.c: New file.
4071         * lib/unistr/u16-mbtouc-safe.c: New file.
4072         * lib/unistr/u32-mbtouc-safe.c: New file.
4073
4074         * modules/unistr/u8-move: New file.
4075         * modules/unistr/u16-move: New file.
4076         * modules/unistr/u32-move: New file.
4077         * lib/unistr/u8-move.c: New file.
4078         * lib/unistr/u16-move.c: New file.
4079         * lib/unistr/u32-move.c: New file.
4080         * lib/unistr/u-move.h: New file.
4081
4082         * modules/unistr/u8-next: New file.
4083         * modules/unistr/u16-next: New file.
4084         * modules/unistr/u32-next: New file.
4085         * lib/unistr/u8-next.c: New file.
4086         * lib/unistr/u16-next.c: New file.
4087         * lib/unistr/u32-next.c: New file.
4088
4089         * modules/unistr/u8-prev: New file.
4090         * modules/unistr/u16-prev: New file.
4091         * modules/unistr/u32-prev: New file.
4092         * lib/unistr/u8-prev.c: New file.
4093         * lib/unistr/u16-prev.c: New file.
4094         * lib/unistr/u32-prev.c: New file.
4095
4096         * modules/unistr/u8-set: New file.
4097         * modules/unistr/u16-set: New file.
4098         * modules/unistr/u32-set: New file.
4099         * lib/unistr/u8-set.c: New file.
4100         * lib/unistr/u16-set.c: New file.
4101         * lib/unistr/u32-set.c: New file.
4102         * lib/unistr/u-set.h: New file.
4103
4104         * modules/unistr/u8-startswith: New file.
4105         * modules/unistr/u16-startswith: New file.
4106         * modules/unistr/u32-startswith: New file.
4107         * lib/unistr/u8-startswith.c: New file.
4108         * lib/unistr/u16-startswith.c: New file.
4109         * lib/unistr/u32-startswith.c: New file.
4110         * lib/unistr/u-startswith.h: New file.
4111
4112         * modules/unistr/u8-stpcpy: New file.
4113         * modules/unistr/u16-stpcpy: New file.
4114         * modules/unistr/u32-stpcpy: New file.
4115         * lib/unistr/u8-stpcpy.c: New file.
4116         * lib/unistr/u16-stpcpy.c: New file.
4117         * lib/unistr/u32-stpcpy.c: New file.
4118         * lib/unistr/u-stpcpy.h: New file.
4119
4120         * modules/unistr/u8-stpncpy: New file.
4121         * modules/unistr/u16-stpncpy: New file.
4122         * modules/unistr/u32-stpncpy: New file.
4123         * lib/unistr/u8-stpncpy.c: New file.
4124         * lib/unistr/u16-stpncpy.c: New file.
4125         * lib/unistr/u32-stpncpy.c: New file.
4126         * lib/unistr/u-stpncpy.h: New file.
4127
4128         * modules/unistr/u8-strcat: New file.
4129         * modules/unistr/u16-strcat: New file.
4130         * modules/unistr/u32-strcat: New file.
4131         * lib/unistr/u8-strcat.c: New file.
4132         * lib/unistr/u16-strcat.c: New file.
4133         * lib/unistr/u32-strcat.c: New file.
4134         * lib/unistr/u-strcat.h: New file.
4135
4136         * modules/unistr/u8-strchr: New file.
4137         * modules/unistr/u16-strchr: New file.
4138         * modules/unistr/u32-strchr: New file.
4139         * lib/unistr/u8-strchr.c: New file.
4140         * lib/unistr/u16-strchr.c: New file.
4141         * lib/unistr/u32-strchr.c: New file.
4142
4143         * modules/unistr/u8-strcmp: New file.
4144         * modules/unistr/u16-strcmp: New file.
4145         * modules/unistr/u32-strcmp: New file.
4146         * lib/unistr/u8-strcmp.c: New file.
4147         * lib/unistr/u16-strcmp.c: New file.
4148         * lib/unistr/u32-strcmp.c: New file.
4149
4150         * modules/unistr/u8-strcpy: New file.
4151         * modules/unistr/u16-strcpy: New file.
4152         * modules/unistr/u32-strcpy: New file.
4153         * lib/unistr/u8-strcpy.c: New file.
4154         * lib/unistr/u16-strcpy.c: New file.
4155         * lib/unistr/u32-strcpy.c: New file.
4156         * lib/unistr/u-strcpy.h: New file.
4157
4158         * modules/unistr/u8-strcspn: New file.
4159         * modules/unistr/u16-strcspn: New file.
4160         * modules/unistr/u32-strcspn: New file.
4161         * lib/unistr/u8-strcspn.c: New file.
4162         * lib/unistr/u16-strcspn.c: New file.
4163         * lib/unistr/u32-strcspn.c: New file.
4164         * lib/unistr/u-strcspn.h: New file.
4165
4166         * modules/unistr/u8-strdup: New file.
4167         * modules/unistr/u16-strdup: New file.
4168         * modules/unistr/u32-strdup: New file.
4169         * lib/unistr/u8-strdup.c: New file.
4170         * lib/unistr/u16-strdup.c: New file.
4171         * lib/unistr/u32-strdup.c: New file.
4172         * lib/unistr/u-strdup.h: New file.
4173
4174         * modules/unistr/u8-strlen: New file.
4175         * modules/unistr/u16-strlen: New file.
4176         * modules/unistr/u32-strlen: New file.
4177         * lib/unistr/u8-strlen.c: New file.
4178         * lib/unistr/u16-strlen.c: New file.
4179         * lib/unistr/u32-strlen.c: New file.
4180         * lib/unistr/u-strlen.h: New file.
4181
4182         * modules/unistr/u8-strmblen: New file.
4183         * modules/unistr/u16-strmblen: New file.
4184         * modules/unistr/u32-strmblen: New file.
4185         * lib/unistr/u8-strmblen.c: New file.
4186         * lib/unistr/u16-strmblen.c: New file.
4187         * lib/unistr/u32-strmblen.c: New file.
4188
4189         * modules/unistr/u8-strmbtouc: New file.
4190         * modules/unistr/u16-strmbtouc: New file.
4191         * modules/unistr/u32-strmbtouc: New file.
4192         * lib/unistr/u8-strmbtouc.c: New file.
4193         * lib/unistr/u16-strmbtouc.c: New file.
4194         * lib/unistr/u32-strmbtouc.c: New file.
4195
4196         * modules/unistr/u8-strncat: New file.
4197         * modules/unistr/u16-strncat: New file.
4198         * modules/unistr/u32-strncat: New file.
4199         * lib/unistr/u8-strncat.c: New file.
4200         * lib/unistr/u16-strncat.c: New file.
4201         * lib/unistr/u32-strncat.c: New file.
4202         * lib/unistr/u-strncat.h: New file.
4203
4204         * modules/unistr/u8-strncmp: New file.
4205         * modules/unistr/u16-strncmp: New file.
4206         * modules/unistr/u32-strncmp: New file.
4207         * lib/unistr/u8-strncmp.c: New file.
4208         * lib/unistr/u16-strncmp.c: New file.
4209         * lib/unistr/u32-strncmp.c: New file.
4210
4211         * modules/unistr/u8-strncpy: New file.
4212         * modules/unistr/u16-strncpy: New file.
4213         * modules/unistr/u32-strncpy: New file.
4214         * lib/unistr/u8-strncpy.c: New file.
4215         * lib/unistr/u16-strncpy.c: New file.
4216         * lib/unistr/u32-strncpy.c: New file.
4217         * lib/unistr/u-strncpy.h: New file.
4218
4219         * modules/unistr/u8-strnlen: New file.
4220         * modules/unistr/u16-strnlen: New file.
4221         * modules/unistr/u32-strnlen: New file.
4222         * lib/unistr/u8-strnlen.c: New file.
4223         * lib/unistr/u16-strnlen.c: New file.
4224         * lib/unistr/u32-strnlen.c: New file.
4225         * lib/unistr/u-strnlen.h: New file.
4226
4227         * modules/unistr/u8-strpbrk: New file.
4228         * modules/unistr/u16-strpbrk: New file.
4229         * modules/unistr/u32-strpbrk: New file.
4230         * lib/unistr/u8-strpbrk.c: New file.
4231         * lib/unistr/u16-strpbrk.c: New file.
4232         * lib/unistr/u32-strpbrk.c: New file.
4233         * lib/unistr/u-strpbrk.h: New file.
4234
4235         * modules/unistr/u8-strrchr: New file.
4236         * modules/unistr/u16-strrchr: New file.
4237         * modules/unistr/u32-strrchr: New file.
4238         * lib/unistr/u8-strrchr.c: New file.
4239         * lib/unistr/u16-strrchr.c: New file.
4240         * lib/unistr/u32-strrchr.c: New file.
4241
4242         * modules/unistr/u8-strspn: New file.
4243         * modules/unistr/u16-strspn: New file.
4244         * modules/unistr/u32-strspn: New file.
4245         * lib/unistr/u8-strspn.c: New file.
4246         * lib/unistr/u16-strspn.c: New file.
4247         * lib/unistr/u32-strspn.c: New file.
4248         * lib/unistr/u-strspn.h: New file.
4249
4250         * modules/unistr/u8-strstr: New file.
4251         * modules/unistr/u16-strstr: New file.
4252         * modules/unistr/u32-strstr: New file.
4253         * lib/unistr/u8-strstr.c: New file.
4254         * lib/unistr/u16-strstr.c: New file.
4255         * lib/unistr/u32-strstr.c: New file.
4256         * lib/unistr/u-strstr.h: New file.
4257
4258         * modules/unistr/u8-strtok: New file.
4259         * modules/unistr/u16-strtok: New file.
4260         * modules/unistr/u32-strtok: New file.
4261         * lib/unistr/u8-strtok.c: New file.
4262         * lib/unistr/u16-strtok.c: New file.
4263         * lib/unistr/u32-strtok.c: New file.
4264         * lib/unistr/u-strtok.h: New file.
4265
4266         * modules/unistr/u8-uctomb: New file.
4267         * modules/unistr/u16-uctomb: New file.
4268         * modules/unistr/u32-uctomb: New file.
4269         * lib/unistr/u8-uctomb.c: New file.
4270         * lib/unistr/u16-uctomb.c: New file.
4271         * lib/unistr/u32-uctomb.c: New file.
4272
4273         * MODULES.html.sh (Unicode string functions): Add the new modules.
4274
4275 2007-01-08  Bruno Haible  <bruno@clisp.org>
4276
4277         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
4278         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
4279         subdirectories.
4280
4281 2007-01-08  Karl Berry  <karl@gnu.org>
4282
4283         * doc/error.texi: mention that main() fns must set program_name
4284         when progname is used.
4285
4286 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
4287
4288         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
4289         WCTYPE_H is empty, for the benefit of builds from non-distclean
4290         directories.  Problem reported by Eric Blake in
4291         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
4292
4293 2007-01-08  Bruno Haible  <bruno@clisp.org>
4294
4295         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
4296         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
4297         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
4298         PROVIDE_CANONICALIZE_FILENAME_MODE.
4299         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
4300
4301 2007-01-08  Bruno Haible  <bruno@clisp.org>
4302
4303         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
4304         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
4305         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
4306         * lib/fts.c: Likewise.
4307         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
4308
4309 2006-12-25  Bruno Haible  <bruno@clisp.org>
4310
4311         * modules/utf8-ucs4-safe: New file.
4312         * lib/utf8-ucs4-safe.h: New file.
4313         * lib/unistr/utf8-ucs4-safe.c: New file.
4314
4315         * modules/utf16-ucs4-safe: New file.
4316         * lib/utf16-ucs4-safe.h: New file.
4317         * lib/unistr/utf16-ucs4-safe.c: New file.
4318
4319         * MODULES.html.sh (Unicode string functions): Add the new modules.
4320
4321 2007-01-08  Bruno Haible  <bruno@clisp.org>
4322
4323         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
4324         (Depends-on): Add unitypes.
4325         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
4326         (u8_mbtouc_aux): Move out to separate file.
4327         (u8_mbtouc): Use ucs4_t, uint8_t types.
4328         * lib/unistr/utf8-ucs4.c: New file.
4329
4330         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
4331         (Depends-on): Add unitypes.
4332         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
4333         (u16_mbtouc_aux): Move out to separate file.
4334         (u16_mbtouc): Use ucs4_t, uint16_t types.
4335         * lib/unistr/utf16-ucs4.c: New file.
4336
4337         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
4338         (Depends-on): Add unitypes.
4339         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
4340         (u8_uctomb_aux): Move out to separate file.
4341         (u8_uctomb): Use ucs4_t, uint8_t types.
4342         * lib/unistr/ucs4-utf8.c: New file.
4343
4344         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
4345         (Depends-on): Add unitypes.
4346         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
4347         (u16_uctomb_aux): Move out to separate file.
4348         (u16_uctomb): Use ucs4_t, uint16_t types.
4349         * lib/unistr/ucs4-utf16.c: New file.
4350
4351 2006-12-25  Bruno Haible  <bruno@clisp.org>
4352
4353         * modules/unitypes: New file.
4354         * lib/unitypes.h: New file.
4355         * MODULES.html.sh (func_all_modules): New section "Unicode string
4356         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
4357         this section. Add unitypes.
4358
4359 2007-01-08  Bruno Haible  <bruno@clisp.org>
4360
4361         Avoid variable names that conflict with those from libtool.
4362         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
4363         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
4364         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
4365         library_names_spec to acl_library_names_spec, hardcode_* to
4366         acl_hardcode_*.
4367         Reported by Ralf Wildenhues.
4368
4369 2007-01-08  Bruno Haible  <bruno@clisp.org>
4370
4371         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
4372         definition.
4373         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
4374         definition.
4375         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
4376         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
4377         definition.
4378         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
4379         definition.
4380         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
4381         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
4382         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
4383         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
4384         definition.
4385         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
4386         definition.
4387         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
4388         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
4389         GC_USE_<algorithm>.
4390         * lib/gc-libgcrypt.c: Likewise.
4391         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
4392         * modules/gc-arctwo (configure.ac): Likewise.
4393         * modules/gc-des (configure.ac): Likewise.
4394         * modules/gc-hmac-md5 (configure.ac): Likewise.
4395         * modules/gc-hmac-sha1 (configure.ac): Likewise.
4396         * modules/gc-md2 (configure.ac): Likewise.
4397         * modules/gc-md4 (configure.ac): Likewise.
4398         * modules/gc-md5 (configure.ac): Likewise.
4399         * modules/gc-random (configure.ac): Likewise.
4400         * modules/gc-rijndael (configure.ac): Likewise.
4401         * modules/gc-sha1 (configure.ac): Likewise.
4402
4403 2007-01-08  Bruno Haible  <bruno@clisp.org>
4404
4405         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
4406         macro definition.
4407         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
4408         definition.
4409         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
4410         definition.
4411         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
4412         * modules/fcntl-safer (configure.ac): Likewise.
4413         * modules/fopen-safer (configure.ac): Likewise.
4414         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
4415         GNULIB_FWRITEERROR macro definition.
4416
4417 2007-01-08  Bruno Haible  <bruno@clisp.org>
4418
4419         * m4/gnulib-common.m4: New file.
4420         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
4421         (func_get_filelist): Add m4/gnulib-common.m4.
4422
4423 2007-01-08  Bruno Haible  <bruno@clisp.org>
4424
4425         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
4426         command.
4427
4428 2007-01-08  Jim Meyering  <jim@meyering.net>
4429
4430         Use a more robust test for a "can't happen" condition.
4431         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
4432         narrowed the st_size value.  Presuming the "can't happen" condition
4433         is true, that narrowing could conceivably convert an invalid st_size
4434         value into a valid one.  Instead, use a change based on Matthew
4435         Woehlke's original patch.
4436
4437         Slight readability improvement: use an assert-like macro
4438         in place of literal "abort ()" uses.
4439         * lib/fts.c (fts_assert): Define.
4440         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
4441         Use this macro instead of a bare 'abort'.
4442
4443 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
4444
4445         Don't worry about using IRIX 5.3's wctype.h broken definitions;
4446         simply work around them.
4447         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
4448         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
4449         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
4450         declaring.
4451         Don't bother to define as macros, since the standard doesn't require it.
4452         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
4453         longer worry about IRIX 5.3.
4454         (HAVE_WCTYPE_CTMP_BUG): Remove.
4455
4456 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
4457
4458         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
4459         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
4460         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
4461         Problems reported by Georg Schwarz for IRIX 5.3.
4462
4463         * gnulib-tool (autoconf_minversion): Take the maximum version number
4464         found, not the minimum.  Problem reported by James Youngman.
4465
4466 2007-01-03  Karl Berry  <karl@gnu.org>
4467
4468         * doc/error.texi: new file, explaining interaction with progname.
4469         * doc/gnulib.texi: include it.  Update copyright.
4470
4471 2007-01-03  Simon Josefsson  <simon@josefsson.org>
4472
4473         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
4474         AC_CANONICAL_HOST, to improve autobuild outputs.
4475
4476 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
4477             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
4478
4479         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
4480         sockets, server sockets, and other file descriptors.  Count errors
4481         to compute the return value.  Reorder the code a bit to be easier
4482         to follow.  Don't set event bits that were not requested (except
4483         POLLERR and POLLHUP).
4484
4485 2007-01-01  Bruno Haible  <bruno@clisp.org>
4486
4487         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
4488
4489 2007-01-03  Jim Meyering  <jim@meyering.net>
4490
4491         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
4492
4493 2007-01-02  Bruno Haible  <bruno@clisp.org>
4494
4495         * modules/settime (Include): Require timespec.h.
4496         * modules/nanosleep (Include): Likewise.
4497
4498 2007-01-01  Bruno Haible  <bruno@clisp.org>
4499
4500         * gnulib-tool (func_emit_copyright_notice): Bump year.
4501         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
4502
4503 2007-01-01  Bruno Haible  <bruno@clisp.org>
4504
4505         Improve support for OpenBSD.
4506         * build-aux/config.rpath (libname_spec): Export.
4507         (library_names_spec): New variable. Export.
4508         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
4509         library_names_spec from the config.rpath output. Locate shared library
4510         through the name pattern in library_names_spec.
4511
4512 2007-01-01  Eric Blake  <ebb9@byu.net>
4513
4514         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
4515
4516 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
4517
4518         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
4519         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
4520         assume the C locale, and avoid an "eval" that could cause trouble.
4521         Problem with SORT reported by Bob Proulx.
4522
4523         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
4524         Define.  Trivial patch from Henning Nielsen Lund, originally
4525         sent to bug-grep@gnu.org today.
4526
4527 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
4528
4529         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
4530         struct stat.  Problem reported by Henning Nielsen Lund.
4531         * lib/acl.c: Include acl.h first, to check interface.  Don't
4532         bother to include sys/types.h and sys/stat.h again.
4533
4534 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
4535
4536         Import the following change from libc; problem reported by
4537         Sven Verdoolaege.
4538
4539         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
4540
4541         [BZ #1373]
4542         * lib/argp.h: Remove __NTH for __argp_usage inline function.
4543
4544 2006-12-28  Jim Meyering  <jim@meyering.net>
4545
4546         * build-aux/announce-gen: Do not assume that the package
4547         builds any of tar.gz, tar.bz2, and .xdelta files.
4548         Suggestion from Simon Josefsson.
4549
4550 2006-12-28  Simon Josefsson  <simon@josefsson.org>
4551
4552         * modules/announce-gen: New file.
4553
4554 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
4555
4556         * lib/mbchar.h: Just include <wctype.h>; the wctype module
4557         handles its gotchas now.
4558         * lib/mbswidth.c: Likewise.
4559         * lib/wcwidth.h: Likewise.
4560         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
4561         and iswcntrl; the wctype module does this stuff now.
4562         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
4563         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
4564         * modules/mbchar (Depends-on): Add wctype.
4565         * modules/mbswidth (Depends-on): Likewise.
4566         * modules/wcwidth (Depends-on): Likewise.
4567
4568 2006-12-27  Eric Blake  <ebb9@byu.net>
4569
4570         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
4571         module uses more than what <wctype.h> is required to provide.
4572
4573 2006-12-26  Eric Blake  <ebb9@byu.net>
4574
4575         * gnulib-tool (sed_extract_prog): Avoid space-tab.
4576
4577 2006-12-26  Eric Blake  <ebb9@byu.net>
4578
4579         * modules/absolute-header: New module.
4580         * modules/fcntl (Depends-on): Depend on it.
4581         * modules/inttypes (Depends-on): Likewise.
4582         * modules/stdint (Depends-on): Likewise.
4583         * modules/sys_stat (Depends-on): Likewise.
4584         * modules/wctype (Depends-on): Likewise.
4585         * MODULES.html.sh (Support for building libraries and
4586         executables): Document it.
4587
4588 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
4589
4590         * gnulib-tool (SED): Remove, undoing previous change.
4591         The problem was that it broke coreutils on Solaris, because
4592         "sed --posix" leaked into a makefile.
4593         (sed): New alias, if 'alias' and GNU sed.
4594
4595 2006-12-24  Jim Meyering  <jim@meyering.net>
4596
4597         Work around an fchownat bug in glibc-2.4:
4598         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
4599         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
4600         in spite of the -P option.
4601         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
4602         New macros.
4603         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
4604         * modules/openat (Files): Add lib/fchownat.c.
4605         * lib/openat.c (fchownat): Don't define here.  Move to...
4606         * lib/fchownat.c: ...this new file.
4607
4608 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
4609
4610         Fix bug reported by Bruno Haible in
4611         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
4612         where quotearg.c didn't compile on Mac OS X 10.2 because it
4613         lacks <wchar.h> and wint_t.
4614         * lib/wctype_.h (__wctype_wint_t): New type.
4615         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
4616         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
4617         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
4618         Arg is now of type __wctype_wint_t, not wint_t.
4619         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
4620         substitute HAVE_WINT_T.
4621         * modules/wctype (Files): Add m4/wint_t.m4.
4622         (wctype.h): Substitute HAVE_WINT_T.
4623
4624 2006-12-23  Bruno Haible  <bruno@clisp.org>
4625
4626         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
4627
4628 2006-12-23  Bruno Haible  <bruno@clisp.org>
4629
4630         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
4631         S_ISLNK.
4632         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
4633         mingw.
4634
4635 2006-12-22  Bruno Haible  <bruno@clisp.org>
4636
4637         * lib/copy-file.c: Include acl.h.
4638         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
4639         Close the file descriptors only after being done with copy_acl.
4640         * modules/copy-file (Depends-on): Add acl.
4641
4642 2006-12-22  Bruno Haible  <bruno@clisp.org>
4643
4644         * gnulib-tool (SED): New variable.
4645         Use $SED instead of sed everywhere.
4646
4647 2006-12-22  Bruno Haible  <bruno@clisp.org>
4648
4649         * modules/no-c++: New file.
4650         * m4/no-c++.m4: New file.
4651         * MODULES.html.sh (Support for building libraries and executables):
4652         Add no-c++.
4653
4654 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
4655
4656         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
4657         Include <limits.h>, and use its INT_MAX to rewrite the
4658         j loop so that it does not overflow 'int'.  Problem reported by
4659         Ralf Wildenhues in
4660         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
4661         Play it safe by shifting left by 1 rather than multiplying by 2,
4662         as GCC is less likely to optimize this away when the value
4663         is signed (when it assumes overflow leads to undefined behavior).
4664         Also, don't assume time_t uses two's complement.
4665
4666 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
4667
4668         * MODULES.html.sh: New module wctype.
4669         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
4670         * lib/fnmatch.c: Don't bother to include <wchar.h> before
4671         <wctype.h>, since the new wctype module should fix this.
4672         * lib/quotearg.c: Include <wctype.h> unconditionally, since
4673         the wctype module should arrange for it.
4674         * lib/regex_internal.h: Likewise.
4675         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
4676         since the wctype module should handle this now.
4677         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
4678         * modules/fnmatch (Depends-on): Add wctype.
4679         * modules/quotearg (Depends-on): Likewise.
4680         * modules/regex (Depends-on): Likewise.
4681
4682 2006-12-19  Bruno Haible  <bruno@clisp.org>
4683
4684         * lib/strdup.h [C++]: Wrap definitions in extern "C".
4685         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
4686
4687 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4688
4689         * modules/savewd (Depends-on): Fix dependency on fcntl.
4690
4691 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
4692
4693         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
4694         conforms to C99, rather than relying on the user's environment
4695         setting of STDINT_H.
4696
4697 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
4698         and Eric Blake  <ebb9@byu.net>
4699
4700         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
4701         This is more consistent with the other defines here.
4702         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
4703         Port to z/OS.  Problem reported by Paul Gilmartin.
4704         Change local vars to use gl_ prefix rather than ac_.
4705         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
4706         with other defines.
4707         * modules/double-slash-root: New module.
4708         * modules/dirname (Files): Remove m4/double-slash-root.m4.
4709         (Depends-on): Add double-slash-root.
4710         * MODULES.html.sh (File system functions): Mention new module.
4711
4712 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
4713
4714         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
4715         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
4716         This is for the benefit of gzip, which doesn't do i18n.
4717
4718 2006-12-12  Jim Meyering  <jim@meyering.net>
4719
4720         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
4721         Reported by Andreas Schwab <schwab@suse.de>.
4722
4723 2006-12-12  Bruno Haible  <bruno@clisp.org>
4724
4725         Merge these changes.
4726         2006-09-05  Bruno Haible  <bruno@clisp.org>
4727         * lib/iconvme.c (iconv_string): No need to save and restore errno when
4728         iconv_alloc succeeded.
4729         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
4730         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
4731         test for " && dest " at the end - dest is always != NULL there. Call
4732         iconv with 4xNULL arguments initially, to reset the state. Call iconv
4733         with 2xNULL arguments, also to flush the state storage. Handle the
4734         IRIX iconv behaviour. Realloc the final result, to throw away unused
4735         memory.
4736
4737 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
4738
4739         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
4740         and fchmodat unconditionally, since glibc 2.4 has them.
4741         Problem reported by Arkadiusz Miskiewicz.
4742
4743 2006-12-10  Bruno Haible  <bruno@clisp.org>
4744
4745         * gnulib-tool (func_import): Show the include files only for those
4746         modules that are copied and specified.
4747         Reported by Karl Berry.
4748
4749 2006-12-08  Jim Meyering  <jim@meyering.net>
4750
4751         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
4752         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
4753
4754         * build-aux/announce-gen: Add two new options, both optional:
4755         --bootstrap-tools=TOOL_LIST
4756               a comma-separated list of tools, e.g.,
4757               autoconf,automake,bison,gnulib
4758         --gnulib-snapshot-date=DATE
4759               if gnulib is in the bootstrap tool list,
4760               then report this as the snapshot date.
4761               If not specified, use the current date/time.
4762               If you specify a date here, be sure it's UTC.
4763
4764 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4765
4766         * tests/test-argp-2.sh: Fix test to match actual output.
4767         (func_compare): Fix sed script to be portable.
4768
4769 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
4770
4771         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
4772         workaround for this case.  It is not autoconfigured now; offhand
4773         it's hard to see how to autoconfigure it.
4774
4775 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
4776
4777         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
4778         a directory that is about to be chowned.  Such a directory's
4779         initial file permissions should permit the owner only and this
4780         should not be changed until after the chown, since the group and
4781         other bits would be incorrect if they granted permission before
4782         the chown.
4783
4784         Fix porting problem for iswctype reported by Georg Schwarz in:
4785         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
4786         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
4787         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
4788         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
4789         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
4790
4791 2006-12-03  Jim Meyering  <jim@meyering.net>
4792
4793         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
4794         p->fts_statp may not yet be defined.
4795         (fts_read): Instead, set it in the caller, once p->fts_statp is
4796         sure to be defined, and corresponds to a top-level directory.
4797         This bug made du -x fail.  Here's the coreutils test case:
4798         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
4799         Reported by Mike Frysinger.
4800
4801 2006-12-01  Jim Meyering  <jim@meyering.net>
4802
4803         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
4804         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
4805         Reported by Simon Josefsson.
4806
4807 2006-11-30  Jim Meyering  <jim@meyering.net>
4808
4809         * m4/warning.m4: Use the all-permissive copyright notice
4810         recommended by RMS (rather than LGPL).
4811         * m4/vararrays.m4: Likewise.
4812         * m4/flexmember.m4: Likewise.
4813
4814 2006-11-29  Bruno Haible  <bruno@clisp.org>
4815
4816         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4817         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
4818         using +=.
4819         Reported by Simon Josefsson <simon@josefsson.org>.
4820
4821 2006-11-28  James Youngman <jay@gnu.org>
4822
4823         * README: Advise users that they might find the bug-gnulib@gnu.org
4824         and autotools-announce@gnu.org mailing lists useful.
4825
4826 2006-11-28  Bruno Haible  <bruno@clisp.org>
4827
4828         * m4/ptrdiff_max.m4: Remove file.
4829
4830 2006-11-21  Bruno Haible  <bruno@clisp.org>
4831
4832         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
4833         _AC_COMPUTE_INT.
4834         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4835         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
4836         _AC_COMPUTE_INT.
4837         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4838         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
4839         _AC_COMPUTE_INT.
4840         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4841
4842 2006-11-28  Jim Meyering  <jim@meyering.net>
4843
4844         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
4845         warning from "gcc -Wshadow" about shadowing the builtin.
4846
4847 2006-11-27  Bruno Haible  <bruno@clisp.org>
4848
4849         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
4850         _AC_COMPUTE_INT.
4851         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4852
4853 2006-11-27  Bruno Haible  <bruno@clisp.org>
4854             Paul Eggert  <eggert@cs.ucla.edu>
4855
4856         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
4857
4858 2006-11-26  Bruno Haible  <bruno@clisp.org>
4859
4860         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4861         noinst_LTLIBRARIES.
4862
4863 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
4864             Bruno Haible  <bruno@clisp.org>
4865
4866         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
4867         if compiling with "gcc -ansi".
4868
4869 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
4870
4871         Fix some incompatibilities with gcc -ansi -pedantic.
4872         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
4873         if compiling pedantically with GCC, unless it's C99 or later.
4874         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
4875         it mishandles gcc -ansi -pedantic as well.
4876         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
4877         if gcc -pedantic.
4878         * lib/regexec.c (check_node_accept_bytes): Don't use auto
4879         initializers for struct if -pedantic, unless it's C99 or later.
4880
4881 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
4882
4883         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
4884         Don't close an fd more than once. Identical atimes indicate
4885         success, not failure.
4886
4887 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
4888
4889         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
4890
4891 2006-11-23  Jim Meyering  <jim@meyering.net>
4892
4893         * build-aux/announce-gen: New file.  From coreutils.
4894
4895 2006-11-22  Jim Meyering  <jim@meyering.net>
4896
4897         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
4898         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
4899         (fts_read): Use a temporary to narrow the overused st_size member
4900         before using it in a switch statement.  Reported by Matthew Woehlke.
4901
4902         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
4903         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
4904
4905 2006-11-20  Bruno Haible  <bruno@clisp.org>
4906
4907         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
4908         changequote instead of pairs of brackets.
4909         Reported by Andreas Schwab <schwab@suse.de>.
4910
4911 2006-11-21  Jim Meyering  <jim@meyering.net>
4912
4913         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
4914         so as to remain compatible with older compilers.
4915         Patch from Michael Deutschmann.
4916
4917 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
4918
4919         * MODULES.html.sh (File system functions): Add openat.
4920
4921         * lib/openat.h (rpl_fstatat): New macro, if
4922         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
4923         (fstatat): Define to rpl_fstatat under the same conditions,
4924         unless COMPILING_FSTATAT.
4925         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
4926         seems to have the bug.
4927         * lib/fstatat.c: New file.
4928         * modules/openat (Files): Add it.
4929
4930 2006-11-20  Bruno Haible  <bruno@clisp.org>
4931
4932         * Makefile: New file.
4933
4934 2006-11-20  Jim Meyering  <jim@meyering.net>
4935
4936         The beginnings of syntax-related checks for gnulib.
4937         * lib/Makefile: New file.
4938         * lib/t-idcache: New script.  Ensure that the two halves of
4939         idcache.c stay in sync.
4940
4941         * lib/idcache.c: Adjust comments in user- and group- portions to
4942         be more accurate, and to be consistent with one another.
4943
4944 2006-11-20  Jim Meyering  <jim@meyering.net>
4945
4946         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
4947         continue using the flexible array member (thus, this module performs
4948         half as many malloc calls), with the addition that...
4949         (getgroup, getuser): Consistently record a non-match via an empty
4950         "name" string, and map an empty string match to a NULL return value.
4951         * modules/idcache (Depends-on): Re-add flexmember.
4952
4953         * lib/idcache.c (getuser): Remove all uses of the register keyword.
4954         (getuidbyname, getgroup, getgidbyname): Likewise.
4955
4956         Use cleaner syntax: NULL rather than 0.
4957         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
4958
4959 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
4960
4961         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
4962         It mishandled the case where the group was missing.
4963         Problem reported by Greg Schafer.
4964         * modules/idcache: Likewise.
4965
4966 2006-11-18  Jim Meyering  <jim@meyering.net>
4967
4968         * check-module (%exempt_header): Add exception for some
4969         conditionally-included headers.
4970
4971         * modules/i-ring (Depends-on): Add verify.
4972         (License): Change to LGPL.
4973
4974 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
4975
4976         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
4977         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
4978         and inttostr.h.  Use snprintf rather than uinttostr, so that
4979         LGPLed code doesn't depend on GPLed.
4980
4981 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
4982
4983         * modules/inline (License): Change from GPL to LGPL.
4984
4985 2006-11-17  Jim Meyering  <jim@meyering.net>
4986
4987         * modules/d-type (License): Switch to LGPL.
4988
4989 2006-11-15  Bruno Haible  <bruno@clisp.org>
4990
4991         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
4992
4993 2006-11-15  Eric Blake  <ebb9@byu.net>
4994
4995         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
4996         the module dependency.
4997
4998 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4999             Bruno Haible  <bruno@clisp.org>
5000
5001         * gnulib-tool (func_create_testdir): Add license consistency check.
5002
5003 2006-11-15  Eric Blake  <ebb9@byu.net>
5004
5005         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
5006         random "(cached)" in configure output.
5007
5008 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5009
5010         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
5011         test for conforming inttypes.h is both announced and cached.
5012
5013         * MODULES.html.sh (seen_modules, seen_files): New variables.
5014         (func_module): Rewrite to use a few less gnulib-tool and sed
5015         invocations.  Avoid a couple of quadratic algorithms for ...
5016         (missed_modules, missed_files): ... these, with ...
5017         (func_append, func_tmpdir): ... these new functions, from
5018         gnulib-tool.  Analogously, install traps for cleanup.
5019
5020         * tests/test-gc.c (main): Remove unused variables.
5021         * tests/test-read-file.c: Include stdlib.h, for 'free'.
5022
5023 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
5024
5025         * modules/inttostr (License): Change to LGPL.
5026
5027 2006-11-14  Eric Blake  <ebb9@byu.net>
5028
5029         * modules/tempname (License): Change to LGPL.
5030
5031 2006-11-14  Eric Blake  <ebb9@byu.net>
5032
5033         * doc/functions.texi (Function Portability): *printf functions on
5034         Cygwin now understand all POSIX size specifiers.
5035
5036 2006-11-14  Bruno Haible  <bruno@clisp.org>
5037
5038         * modules/c-ctype (License): Change to LGPL.
5039
5040 2006-11-12  Bruno Haible  <bruno@clisp.org>
5041
5042         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
5043         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
5044         for GNOME libraries, for which the include files are installed in
5045         subdirectories of $prefix/include.
5046
5047 2006-11-12  Bruno Haible  <bruno@clisp.org>
5048
5049         * m4/lib-link.m4: Require at least autoconf-2.54.
5050         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
5051         name to underscores for the --with option.
5052
5053 2006-11-13  Bruno Haible  <bruno@clisp.org>
5054
5055         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
5056         the tests directory.
5057         Reported by Ralf Wildenhues.
5058
5059 2006-11-13  Bruno Haible  <bruno@clisp.org>
5060
5061         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
5062         (func_emit_initmacro_end): Undo the override here.
5063         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
5064         Works around the famous automake error in coreutils.
5065
5066 2006-11-13  Eric Blake  <ebb9@byu.net>
5067
5068         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
5069         element, not its node.
5070
5071 2006-11-12  Bruno Haible  <bruno@clisp.org>
5072
5073         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
5074         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
5075
5076 2006-11-12  Bruno Haible  <bruno@clisp.org>
5077
5078         * gnulib-tool: New option --local-symlink.
5079         (func_usage): Document it.
5080         (lsymbolic): New variable.
5081         (func_import, func_create_testdir): If --symlink was not specified,
5082         test whether --local-symlink was specified and the file comes from
5083         the local_gnulib_dir.
5084
5085 2006-11-12  Bruno Haible  <bruno@clisp.org>
5086
5087         * gnulib-tool (func_ln): New function.
5088         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
5089
5090 2006-11-12  Bruno Haible  <bruno@clisp.org>
5091
5092         Finish support for source files in subdirectories.
5093         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
5094         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
5095         AUTOMAKE_OPTIONS.
5096         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
5097
5098 2006-11-12  Bruno Haible  <bruno@clisp.org>
5099
5100         * gnulib-tool (func_get_automake_snippet): Synthesize also an
5101         EXTRA_lib_SOURCES augmentation.
5102         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
5103
5104 2006-11-12  Jim Meyering  <jim@meyering.net>
5105
5106         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
5107         file descriptors.  This also averts a failure on systems with
5108         native openat support when a traversed directory lacks "x" access.
5109         * lib/fts_.h: Include "i-ring.h"
5110         (struct FTS) [fts_fd_ring]: New member.
5111         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
5112         (FCHDIR): Add parentheses.
5113         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
5114         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
5115         When descending, rather than simply closing the previous
5116         fts_cwd_fd value, push that file descriptor onto the ring.
5117         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
5118         (fts_open): Initialize the new fd_ring member.
5119         (fts_close): Clear the ring.
5120         (fts_safe_changedir): When possible, use our new fd_ring to skip
5121         the diropen and fstat and dev/ino comparison that would normally
5122         accompany a virtual `chdir ("..")'.
5123
5124         * modules/fts (Depends-on): Add i-ring.
5125         * modules/i-ring: New module.
5126         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
5127         * m4/i-ring.m4: New file.
5128
5129 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5130
5131         * gnulib-tool (func_create_testdir): Fix replacement of
5132         `build-aux' in configure.ac.  Run autotools in gltests
5133         subdirectory.
5134         (func_create_testdir, func_create_megatestdir, test): There is
5135         no need for '--force' in most autotool invocations in a new
5136         tree.  Actually fail the whole test if any of the tools, or the
5137         configure or make stages fail.
5138
5139         Sync from Automake.
5140         * build-aux/gnupload: Revert last change.  Add pointer to upload
5141         instructions of the GNU Maintenance Instructions.
5142         Suggestion by Karl Berry.
5143
5144 2006-11-10  Jim Meyering  <jim@meyering.net>
5145
5146         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
5147
5148 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5149
5150         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
5151         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
5152         (bind_textdomain_codeset) [! ENABLE_NLS]:
5153         Evaluate all the arguments.  That way, callers get compatible behavior
5154         if the arguments have side effects.  Also, it avoids some GCC
5155         diagnostics in some cases; Joel E. Denny reported problems when Bison
5156         was configured with --enable-gcc-warnigs.
5157
5158 2006-11-10  Jim Meyering  <jim@meyering.net>
5159
5160         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
5161         relevant options in CFLAGS (like -O, -fno-inline) are taken into
5162         account.
5163
5164 2006-11-10  Jim Meyering  <jim@meyering.net>
5165
5166         * modules/inline: New file/module.
5167         * modules/xalloc (Files): Remove m4/inline.m4.
5168         (Depends-on): Add inline, instead.
5169         * modules/oset: Likewise.
5170         * modules/list: Likewise.
5171
5172 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5173
5174         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
5175         Problem reported by Matthew Woehlke.
5176
5177 2006-11-09  Bruno Haible  <bruno@clisp.org>
5178
5179         * lib/tempname.c (gen_tempname): Remove variant that invokes
5180         __gen_tempname.
5181         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
5182         __gen_tempname.
5183
5184 2006-11-08  Bruno Haible  <bruno@clisp.org>
5185
5186         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
5187         to 'yes' instead of 'cross-compiling'.
5188
5189 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
5190
5191         * lib/quotearg.h (quotearg_free): New decl.
5192         * lib/quotearg.c (quotearg_free): New function.
5193         (slot0, nslots, slotvec0, slotvec):
5194         Now file-scope so that quotearg_free can get at them.
5195
5196 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5197
5198         Sync from Automake.
5199         * build-aux/gnupload: Add missing 'gnu' to example URL.
5200         Report by Karl Berry.
5201
5202 2006-11-08  Bruno Haible  <bruno@clisp.org>
5203
5204         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
5205         Suggested by Paul Eggert.
5206
5207 2006-11-08  Jim Meyering  <jim@meyering.net>
5208
5209         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
5210         It's already included if !_LIBC.
5211         (fts_safe_changedir): Add a comment.
5212
5213 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5214
5215         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
5216         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
5217         Matthew Woehlke.
5218
5219         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
5220         definitions up, to avoid colliding with change below.
5221         (static_inline) [HAVE_INLINE]: New macro.
5222         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
5223         Provide extern decls when !HAVE_INLINE.  Do not define unless
5224         static_inline is defined, either by us or by xmalloc.c.  Use
5225         static_inline rather than static inline.
5226         (XCALLOC): Optimize sizeof(T) = 1 case.
5227         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
5228
5229 2006-11-07  Bruno Haible  <bruno@clisp.org>
5230
5231         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
5232         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
5233         AC_C_INLINE.
5234         * modules/xalloc (Files): Add m4/inline.m4.
5235
5236 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5237
5238         * README: Fix typo.
5239         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
5240         (Miscellanous Notes): ...from this.
5241
5242 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5243
5244         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
5245         Mention that offsetof should be used instead of sizeof.
5246         From Bruno Haible.
5247
5248 2006-11-07  Bruno Haible  <bruno@clisp.org>
5249
5250         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
5251
5252 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
5253
5254         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
5255         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
5256         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
5257         (gl_tree_add_before, gl_tree_add_after):
5258         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
5259         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
5260         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
5261         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
5262         (gl_linked_add_after, gl_linked_add_at): Likewise.
5263         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
5264         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
5265         (gl_tree_add_before, gl_tree_add_after): Likewise.
5266         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
5267         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
5268         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
5269
5270 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5271
5272         * lib/gl_oset.h: Use C comment style, not C++ comment style.
5273
5274 2006-11-06  Bruno Haible  <bruno@clisp.org>
5275
5276         * m4/inline.m4: New file.
5277         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
5278         * modules/list (Files): Add m4/inline.m4.
5279         * modules/oset (Files): Likewise.
5280
5281 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
5282
5283         * lib/idcache.c: Include <stddef.h>, for offsetof.
5284         (struct userid.name): Change from char * to a flexible array member.
5285         All uses changed.
5286         * modules/idcache (Depends-on): Add flexmember.
5287
5288         * MODULES.html.sh (Core language properties): New module flexmember.
5289         * modules/flexmember, m4/flexmember.m4: New files.
5290
5291         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
5292         inline functions that are identical with the old xnmalloc_inline,
5293         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
5294         that we can avoid some unnecessary integer multiplications and
5295         divisions in the common case where the element size is known at
5296         compile time.
5297         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
5298         needed.
5299         (xnboundedmalloc): Remove.
5300         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
5301         arguments, for consistency with rest of this header.
5302         (xcharalloc): Rewrite using XNMALLOC.
5303         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
5304         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
5305         versions have been moved to lib/xalloc.h and renamed to be the
5306         non-*_inline versions.
5307         (xmalloc, xrealloc): Implement without reference to the xnmalloc
5308         and xnrealloc functions, since those functions are now inline and
5309         now call us.
5310         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
5311         renaming described above.
5312         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
5313         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
5314         captures the dependency in AC_C_INLINE.
5315
5316         New module canonicalize-lgpl, proposed by Charles Wilson in
5317         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
5318         with a few small changes afterwards.
5319         * MODULES.html.sh (File system functions): New module
5320         canonicalize-lgpl.
5321         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
5322         and canonicalize_file_name.
5323         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
5324         * modules/canonicalize-lgpl: New files.
5325
5326 2006-11-05  Bruno Haible  <bruno@clisp.org>
5327
5328         * gnulib-tool (func_import, func_create_testdir): Create directories
5329         also for files in subdirectories of lib/.
5330
5331 2006-11-05  Bruno Haible  <bruno@clisp.org>
5332
5333         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
5334         ANSI C compliant.
5335
5336 2006-11-03  Bruno Haible  <bruno@clisp.org>
5337
5338         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
5339         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
5340         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
5341         (xnboundedmalloc): New inline function.
5342         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
5343         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
5344         xmalloc.
5345         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
5346         xmalloc.
5347         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
5348         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
5349         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
5350         xmalloc.
5351         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
5352         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
5353         xmalloc.
5354         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
5355         gl_tree_add_after): Use XMALLOC instead of xmalloc.
5356         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
5357         xmalloc.
5358         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
5359         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
5360         gl_tree_add_after): Use XMALLOC instead of xmalloc.
5361         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
5362         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
5363         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
5364         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
5365
5366 2006-11-03  Bruno Haible  <bruno@clisp.org>
5367
5368         * lib/c-ctype.h [C++]: Define functions without name mangling.
5369         * lib/fwriteerror.h [C++]: Likewise.
5370         * lib/gcd.h [C++]: Likewise.
5371         * lib/linebreak.h [C++]: Likewise.
5372
5373 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
5374
5375         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
5376         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
5377         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
5378         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
5379         Check for functions and headers just once.
5380         Check for declaration of canonicalize_file_name.
5381         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
5382
5383 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5384
5385         * gnulib-tool (func_import): Fix typo in actioncmd.
5386
5387 2006-11-02  Bruno Haible  <bruno@clisp.org>
5388
5389         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
5390         newline sequence in the Makefile.am snippet as a space, like "make"
5391         does.
5392         Reported by Roger Persson <perrog@gmail.com>.
5393
5394 2006-11-01  Bruno Haible  <bruno@clisp.org>
5395
5396         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
5397         already declared in <string.h>.
5398         * lib/strcase.h (strncasecmp): Don't declare it if yes.
5399
5400 2006-11-01  Bruno Haible  <bruno@clisp.org>
5401
5402         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
5403         * lib/strcase.h: Include <string.h>.
5404         (strcasecmp): Define to rpl_strcasecmp here.
5405
5406 2006-11-01  Bruno Haible  <bruno@clisp.org>
5407
5408         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
5409
5410 2006-11-01  Eric Blake  <ebb9@byu.net>
5411
5412         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
5413
5414         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
5415
5416 2006-10-29  Bruno Haible  <bruno@clisp.org>
5417
5418         Make it compile in C++ mode.
5419         * lib/full-write.c (full_rw): Add a cast.
5420
5421 2006-11-01  Bruno Haible  <bruno@clisp.org>
5422
5423         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
5424         be POSIX compliant.
5425         Reported by Roger Persson <perrog@gmail.com>.
5426
5427 2006-11-01  Eric Blake  <ebb9@byu.net>
5428
5429         * lib/getopt_.h: Fix comments.
5430
5431 2006-10-31  Eric Blake  <ebb9@byu.net>
5432
5433         * modules/tmpdir (Depends-on): Add sys_stat.
5434         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
5435         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
5436         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
5437         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
5438         tempname.
5439
5440 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
5441
5442         Avoid some C++ diagnostics reported by Bruno Haible.
5443         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
5444         xmalloc.
5445         (quotearg_alloc): Use xcharalloc rather than xmalloc.
5446         (struct slotvec): Move to top level.
5447         (quotearg_n_options): Rewrite to avoid xmalloc.
5448         * lib/xalloc.h (xcharalloc): New function.
5449         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
5450         [defined __cplusplus]: Add function template that provides result
5451         type propagation.  This part of the change is from Bruno Haible.
5452
5453 2006-10-29  Bruno Haible  <bruno@clisp.org>
5454
5455         Make it compile in C++ mode.
5456         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
5457         * lib/strnlen1.c (strnlen1): Cast memchr result.
5458         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
5459         * lib/clean-temp.c (string_equals, string_hash): Add casts.
5460         (create_temp_dir): Rename local variable 'template'.
5461         (compile_csharp_using_sscli): Add cast.
5462         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
5463         * lib/findprog.c (find_in_path): Likewise.
5464         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
5465         * lib/wait-process.c (register_slave_subprocess): Likewise.
5466
5467 2006-10-22  Bruno Haible  <bruno@clisp.org>
5468
5469         * modules/tsearch: New file.
5470         * lib/tsearch.h: New file.
5471         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
5472         * m4/tsearch.m4: New file.
5473         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
5474
5475 2006-10-29  Eric Blake  <ebb9@byu.net>
5476
5477         * lib/arcfour.c: Assume config.h.
5478         * lib/arctwo.c: Likewise.
5479         * lib/base64.c: Likewise.
5480         * lib/check-version.c: Likewise.
5481         * lib/crc.c: Likewise.
5482         * lib/des.c: Likewise.
5483         * lib/gc-gnulib.c: Likewise.
5484         * lib/gc-libgcrypt.c: Likewise.
5485         * lib/gc-pbkdf2-sha1.c: Likewise.
5486         * lib/getaddrinfo.c: Likewise.
5487         * lib/getdelim.c: Likewise.
5488         * lib/getline.c: Likewise.
5489         * lib/hmac-md5.c: Likewise.
5490         * lib/hmac-sha1.c: Likewise.
5491         * lib/iconvme.c: Likewise.
5492         * lib/md2.c: Likewise.
5493         * lib/md4.c: Likewise.
5494         * lib/memxor.c: Likewise.
5495         * lib/read-file.c: Likewise.
5496         * lib/readline.c: Likewise.
5497         * lib/rijndael-alg-fst.c: Likewise.
5498         * lib/rijndael-api-fst.c: Likewise.
5499         * lib/xgetdomainname.c: Likewise.
5500
5501 2006-10-28  Eric Blake  <ebb9@byu.net>
5502
5503         * lib/xstrndup.c: Assume config.h.
5504
5505 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
5506
5507         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
5508         stat-macros.h is now for our own macros, whereas stat_h is for
5509         macros in the <sys/stat.h> name space.
5510         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
5511         (STAT_MACROS_H): Remove.
5512         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
5513         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
5514         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
5515         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
5516         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
5517         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
5518         Move these macros to ...
5519         * lib/stat_.h: here.  Don't include stat-macros.h.
5520         * lib/canonicalize.c: Don't include stat-macros.h.
5521         * lib/chown.c: Likewise.
5522         * lib/euidaccess.c: Likewise.
5523         * lib/file-type.c: Likewise.
5524         * lib/filemode.c: Likewise.
5525         * lib/glob.c: Likewise.
5526         * lib/isapipe.c: Likewise.
5527         * lib/lchown.c: Likewise.
5528         * lib/lstat.c: Likewise.
5529         * lib/mkdir-p.c: Likewise.
5530         * lib/rmdir.c: Likewise.
5531         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
5532         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
5533         unless mkdir isn't declared, to speed up 'configure'.
5534         Always create sys/stat.h, since it's unlikely any real sys/stat.h
5535         would define all the S_* symbols.
5536         * modules/canonicalize (Depends-on):
5537         Depend on sys_stat, not stat-macros.
5538         * modules/chown: Likewise.
5539         * modules/euidaccess: Likewise.
5540         * modules/filemode: Likewise.
5541         * modules/file-type: Likewise.
5542         * modules/glob: Likewise.
5543         * modules/isapipe: Likewise.
5544         * modules/lchown: Likewise.
5545         * modules/lstat: Likewise.
5546         * modules/mkancesdirs: Likewise.
5547         * modules/rmdir: Likewise.
5548         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
5549         * modules/modechange: Likewise.
5550         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
5551         (configure.ac): Remove gl_STAT_MACROS.
5552         * modules/sys_stat (Depends-on): Remove stat-macros.
5553
5554 2006-10-27  Bruno Haible  <bruno@clisp.org>
5555
5556         * m4/signed.m4: Remove file.
5557         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
5558         invocation.
5559         * modules/vasnprintf (Files): Remove m4/signed.m4.
5560
5561 2006-10-27  Bruno Haible  <bruno@clisp.org>
5562
5563         Update to GNU gettext 0.16.
5564         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
5565         m4/inttypes-h.m4, m4/signed.m4.
5566         * m4/gettext.m4: Update to GNU gettext 0.16.
5567         * m4/intl.m4: New file, from GNU gettext.
5568         * m4/intldir.m4: New file, from GNU gettext.
5569         * config/srclist.txt: Update
5570
5571 2006-10-27  Eric Blake  <ebb9@byu.net>
5572
5573         * MODULES.html.sh: Document tempname.
5574         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
5575         dependencies.
5576         (Files): Move lib/tempname.c...
5577         * modules/tempname: ...to this new module.
5578         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
5579         (gl_PREREQ_TEMPNAME): Move...
5580         * m4/tempname.m4: ...to this new file.
5581         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
5582         * modules/sys_stat (Depends-on): Add stat-macros.
5583         * lib/stat_.h (includes): Pick up stat macros.
5584         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
5585         if stat macros are broken.
5586         * lib/tempname.c (includes): No need to include "stat-macros.h".
5587         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
5588         (direxists, __path_search) [!_LIBC]: Don't compile these in
5589         gnulib; the tmpdir module covers that.
5590         * lib/tempname.h: New file.
5591
5592 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
5593
5594         * COPYING: Explain how gnulib-tool converts licence headers.
5595         Almost all wording by Eric Blake.
5596
5597 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
5598
5599         * lib/mbchar.h (is_basic_table): Make read-only.
5600         * lib/mbchar.c (is_basic_table): Likewise.
5601         Reported by John Darrington.
5602
5603 2006-10-25  Bruno Haible  <bruno@clisp.org>
5604
5605         * lib/progname.h (set_program_name): Undefine before defining.
5606
5607 2006-10-25  Bruno Haible  <bruno@clisp.org>
5608
5609         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
5610         false for non-gcc C++ compilers.
5611         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
5612
5613 2006-10-24  Bruno Haible  <bruno@clisp.org>
5614
5615         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
5616         iconv implementations like Irix iconv.
5617
5618 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5619
5620         * modules/vararrays: New file.
5621         * m4/vararrays.m4: New file, taken from diffutils.
5622         * MODULES.html.sh: New module vararrays.
5623
5624 2006-10-24  Karl Berry  <karl@gnu.org>
5625
5626         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
5627         Don't call GNU Unix.
5628
5629 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5630
5631         * users.txt: Add Libtool.
5632
5633         Sync from Libtool:
5634
5635         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5636
5637         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
5638         to gnulib's policy of including config.h unconditionally.
5639
5640 2006-10-24  Bruno Haible  <bruno@clisp.org>
5641
5642         * modules/wcwidth (Files): Add m4/wint_t.m4.
5643         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
5644         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
5645
5646 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5647
5648         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
5649         to pacify GCC with some -W flags enabled.  Problem reported by
5650         Bruno Haible.
5651
5652 2006-10-24  Jim Meyering  <jim@meyering.net>
5653
5654         * MODULES.html.sh: Remove uinttostr.  It's not a module.
5655         Reported by Karl Berry.
5656
5657 2006-10-23  Bruno Haible  <bruno@clisp.org>
5658
5659         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
5660
5661 2006-10-24  Bruno Haible  <bruno@clisp.org>
5662
5663         * lib/gl_list.h: Use C comment style, not C++ comment style.
5664
5665 2006-10-23  Eric Blake  <ebb9@byu.net>
5666
5667         * lib/getaddrinfo.c (includes): Add missing include.
5668
5669 2006-10-23  Bruno Haible  <bruno@clisp.org>
5670             Paul Eggert  <eggert@cs.ucla.edu>
5671
5672         Ability to rename obstack_free.
5673         * lib/obstack.h (__obstack_free): New macro. Declare instead of
5674         obstack_free.
5675         (obstack_free): Invoke the __obstack_free macro.
5676         * lib/obstack.c (obstack_free): Use __obstack_free macro.
5677
5678 2006-10-23  Bruno Haible  <bruno@clisp.org>
5679             Paul Eggert  <eggert@cs.ucla.edu>
5680
5681         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
5682         __argc, __argv from the declaration. (They are defined as macros on
5683         mingw.)
5684
5685 2006-10-22  Bruno Haible  <bruno@clisp.org>
5686
5687         * doc/gnulib-intro.texi: New file.
5688         * doc/gnulib.texi: Include it.
5689
5690 2006-10-21  Bruno Haible  <bruno@clisp.org>
5691
5692         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
5693         "Introduction", "Miscellanous Notes", "Particular Modules".
5694
5695 2006-10-21  Bruno Haible  <bruno@clisp.org>
5696
5697         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5698         Change mostlyclean-local rule to avoid sh syntax error from bash
5699         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
5700
5701 2006-10-23  Jim Meyering  <jim@meyering.net>
5702
5703         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
5704         in place of snprintf.
5705
5706         * modules/inttostr (Files): Add lib/uinttostr.c.
5707         * lib/uinttostr.c (inttostr): New file/function.
5708         * lib/inttostr.h (uinttostr): Declare.
5709         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
5710         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
5711         Add uinttostr.
5712         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
5713
5714 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
5715
5716         * lib/canonicalize.c (ELOOP): Define if not already defined.
5717         Problem reported by Bruno Haible in
5718         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
5719
5720 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
5721
5722         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
5723         Problem reported by Perry Smith and Ville Laurikari.
5724
5725         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
5726         uses.
5727
5728 2006-10-19  Bruno Haible  <bruno@clisp.org>
5729
5730         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
5731         for mingw.
5732
5733 2006-10-19  Bruno Haible  <bruno@clisp.org>
5734
5735         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
5736         Needed for mingw.
5737
5738 2006-10-19  Bruno Haible  <bruno@clisp.org>
5739
5740         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
5741
5742 2006-10-19  Bruno Haible  <bruno@clisp.org>
5743
5744         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
5745         it.
5746
5747 2006-10-19  Bruno Haible  <bruno@clisp.org>
5748
5749         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
5750         invocation.
5751
5752 2006-10-19  Bruno Haible  <bruno@clisp.org>
5753
5754         * gnulib-tool (func_create_testdir): Don't include ftruncate and
5755         mountlist by default.
5756
5757 2006-10-16  Bruno Haible  <bruno@clisp.org>
5758
5759         * lib/c-strstr.c: Include c-strstr.h.
5760
5761 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5762
5763         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
5764         in a slash.
5765
5766 2006-10-18  Bruno Haible  <bruno@clisp.org>
5767
5768         * lib/lock.h [C++]: Wrap definitions in extern "C".
5769
5770 2006-10-18  Bruno Haible  <bruno@clisp.org>
5771
5772         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
5773         gl_LIBOBJS list.
5774
5775 2006-10-18  Bruno Haible  <bruno@clisp.org>
5776
5777         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
5778
5779 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
5780
5781         * lib/xstrtol.h: Include gettext.h.
5782         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
5783         Problem reported by Eric Blake.
5784         * modules/xstrtol (Depends-on): Add gettext-h.
5785
5786 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
5787
5788         * lib/strftime.c (advance): New macro.
5789         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
5790         incomplete type, so you can't add 0 to it.  Problem and patch
5791         reported by Eelco Dolstra for dietlibc.
5792
5793 2006-10-18  Jim Meyering  <jim@meyering.net>
5794
5795         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
5796         type for a local, and rename it: s/up/user_proc/.
5797
5798 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
5799
5800         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
5801         READ_UTMP_USER_PROCESS.
5802         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
5803
5804 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
5805
5806         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
5807         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
5808
5809 2006-10-17  Eric Blake  <ebb9@byu.net>
5810
5811         * lib/sigprocmask.c (sigprocmask): Fix typo.
5812
5813         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
5814
5815         * modules/clean-temp (Makefile.am): Don't add to make output...
5816         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
5817         config.h.
5818
5819 2006-10-17  Bruno Haible  <bruno@clisp.org>
5820
5821         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
5822         differently if DEFAULT_TEXT_DOMAIN is set.
5823
5824 2006-10-16  Bruno Haible  <bruno@clisp.org>
5825
5826         * lib/clean-temp.c: Include fwriteerror.h.
5827
5828 2006-10-16  Bruno Haible  <bruno@clisp.org>
5829
5830         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
5831
5832 2006-10-16  Bruno Haible  <bruno@clisp.org>
5833
5834         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
5835         * lib/sigprocmask.h: Include <sys/types.h>.
5836         (sigset_t): Use the system's definition if present.
5837
5838 2006-10-17  Eric Blake  <ebb9@byu.net>
5839
5840         * lib/xvasprintf.c (includes): Assume config.h.
5841         * lib/xasprintf.c (includes): Likewise.
5842
5843 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
5844
5845         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
5846         at least as wide as intmax_t.
5847
5848 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
5849
5850         (Imported from Automake.)
5851         * build-aux/gnupload: Update to version 1.1 of directive file.
5852
5853 2006-10-16  Eric Blake  <ebb9@byu.net>
5854
5855         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
5856         match Automake 1.10a.
5857
5858 2006-10-14  Bruno Haible  <bruno@clisp.org>
5859
5860         * modules/sigprocmask: New file.
5861         * lib/sigprocmask.h: New file.
5862         * lib/sigprocmask.c: New file.
5863         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
5864         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
5865         request sigprocmask.o.
5866         (gl_PREREQ_SIGPROCMASK): New macro.
5867         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
5868         (Depends-on): Add sigprocmask.
5869         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
5870         gt_SIGNALBLOCKING. Test for 'raise' only once.
5871         * lib/fatal-signal.c: Include sigprocmask.h.
5872         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
5873         unblock_fatal_signals): Define always.
5874         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
5875         sigprocmask.
5876
5877 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
5878
5879         Sync from Automake.
5880         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
5881         which incorrectly sets the mode of an existing destination
5882         directory.  In some cases the unpatched install-sh could do the
5883         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
5884         system.  We hope this is rare in practice, but it's clearly worth
5885         fixing.  Problem reported by Alex Unleashed in
5886         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
5887         Also, don't bother to check for -m bugs unless we're using -m;
5888         suggested by Stepan Kasal.
5889
5890 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5891
5892         Sync from Automake.
5893         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
5894         `-c' flag, so they appear at the same position as in %FASTDEP%
5895         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
5896         which ignores unknown options only after the first non-option.
5897         Bug report against M4 by Nelson H. F. Beebe.
5898
5899 2006-10-13  Jim Meyering  <jim@meyering.net>
5900
5901         Fix a bug in yesterday's change.
5902         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
5903         p->fts_statp->st_dev would be used uninitialized.
5904         Ensures that we always call fts_stat on the very first entry.
5905         Miklos Szeredi reported that find -xdev stopped working.
5906
5907 2006-10-12  Bruno Haible  <bruno@clisp.org>
5908
5909         * gnulib-tool (func_get_automake_snippet): Append an automatically
5910         computed EXTRA_DIST augmentation.
5911         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
5912         * modules/alloca-opt (Makefile.am): Likewise.
5913         * modules/allocsa (Makefile.am): Likewise.
5914         * modules/arcfour (Makefile.am): Likewise.
5915         * modules/arctwo (Makefile.am): Likewise.
5916         * modules/argmatch (Makefile.am): Likewise.
5917         * modules/argz (Makefile.am): Likewise.
5918         * modules/atexit (Makefile.am): Likewise.
5919         * modules/backupfile (Makefile.am): Likewise.
5920         * modules/byteswap (Makefile.am): Likewise.
5921         * modules/c-strtod (Makefile.am): Likewise.
5922         * modules/c-strtold (Makefile.am): Likewise.
5923         * modules/calloc (Makefile.am): Likewise.
5924         * modules/canon-host (Makefile.am): Likewise.
5925         * modules/canonicalize (Makefile.am): Likewise.
5926         * modules/chdir-long (Makefile.am): Likewise.
5927         * modules/chdir-safer (Makefile.am): Likewise.
5928         * modules/check-version (Makefile.am): Likewise.
5929         * modules/chown (Makefile.am): Likewise.
5930         * modules/cloexec (Makefile.am): Likewise.
5931         * modules/close-stream (Makefile.am): Likewise.
5932         * modules/closeout (Makefile.am): Likewise.
5933         * modules/crc (Makefile.am): Likewise.
5934         * modules/csharpexec (Makefile.am): Likewise.
5935         * modules/cycle-check (Makefile.am): Likewise.
5936         * modules/des (Makefile.am): Likewise.
5937         * modules/dev-ino (Makefile.am): Likewise.
5938         * modules/dirfd (Makefile.am): Likewise.
5939         * modules/dirname (Makefile.am): Likewise.
5940         * modules/dup2 (Makefile.am): Likewise.
5941         * modules/eealloc (Makefile.am): Likewise.
5942         * modules/error (Makefile.am): Likewise.
5943         * modules/euidaccess (Makefile.am): Likewise.
5944         * modules/exclude (Makefile.am): Likewise.
5945         * modules/exitfail (Makefile.am): Likewise.
5946         * modules/fcntl-safer (Makefile.am): Likewise.
5947         * modules/fcntl (Makefile.am): Likewise.
5948         * modules/file-type (Makefile.am): Likewise.
5949         * modules/fileblocks (Makefile.am): Likewise.
5950         * modules/filemode (Makefile.am): Likewise.
5951         * modules/filenamecat (Makefile.am): Likewise.
5952         * modules/fnmatch (Makefile.am): Likewise.
5953         * modules/fopen-safer (Makefile.am): Likewise.
5954         * modules/fpending (Makefile.am): Likewise.
5955         * modules/fprintftime (Makefile.am): Likewise.
5956         * modules/free (Makefile.am): Likewise.
5957         * modules/fsusage (Makefile.am): Likewise.
5958         * modules/ftruncate (Makefile.am): Likewise.
5959         * modules/fts (Makefile.am): Likewise.
5960         * modules/gc-arcfour (Makefile.am): Likewise.
5961         * modules/gc-des (Makefile.am): Likewise.
5962         * modules/gc-hmac-md5 (Makefile.am): Likewise.
5963         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
5964         * modules/gc-md4 (Makefile.am): Likewise.
5965         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
5966         * modules/gc-sha1 (Makefile.am): Likewise.
5967         * modules/gc (Makefile.am): Likewise.
5968         * modules/getaddrinfo (Makefile.am): Likewise.
5969         * modules/getcwd (Makefile.am): Likewise.
5970         * modules/getdelim (Makefile.am): Likewise.
5971         * modules/getdomainname (Makefile.am): Likewise.
5972         * modules/getgroups (Makefile.am): Likewise.
5973         * modules/gethostname (Makefile.am): Likewise.
5974         * modules/gethrxtime (Makefile.am): Likewise.
5975         * modules/getline (Makefile.am): Likewise.
5976         * modules/getloadavg (Makefile.am): Likewise.
5977         * modules/getlogin_r (Makefile.am): Likewise.
5978         * modules/getndelim2 (Makefile.am): Likewise.
5979         * modules/getopt (Makefile.am): Likewise.
5980         * modules/getpagesize (Makefile.am): Likewise.
5981         * modules/getpass-gnu (Makefile.am): Likewise.
5982         * modules/getpass (Makefile.am): Likewise.
5983         * modules/getsubopt (Makefile.am): Likewise.
5984         * modules/gettime (Makefile.am): Likewise.
5985         * modules/gettimeofday (Makefile.am): Likewise.
5986         * modules/getugroups (Makefile.am): Likewise.
5987         * modules/getusershell (Makefile.am): Likewise.
5988         * modules/glob (Makefile.am): Likewise.
5989         * modules/group-member (Makefile.am): Likewise.
5990         * modules/hard-locale (Makefile.am): Likewise.
5991         * modules/hash (Makefile.am): Likewise.
5992         * modules/hmac-md5 (Makefile.am): Likewise.
5993         * modules/hmac-sha1 (Makefile.am): Likewise.
5994         * modules/human (Makefile.am): Likewise.
5995         * modules/idcache (Makefile.am): Likewise.
5996         * modules/imaxabs (Makefile.am): Likewise.
5997         * modules/imaxdiv (Makefile.am): Likewise.
5998         * modules/inet_ntop (Makefile.am): Likewise.
5999         * modules/inet_pton (Makefile.am): Likewise.
6000         * modules/intprops (Makefile.am): Likewise.
6001         * modules/inttostr (Makefile.am): Likewise.
6002         * modules/inttypes (Makefile.am): Likewise.
6003         * modules/isapipe (Makefile.am): Likewise.
6004         * modules/javaversion (Makefile.am): Likewise.
6005         * modules/lchmod (Makefile.am): Likewise.
6006         * modules/lchown (Makefile.am): Likewise.
6007         * modules/localcharset (Makefile.am): Likewise.
6008         * modules/long-options (Makefile.am): Likewise.
6009         * modules/lstat (Makefile.am): Likewise.
6010         * modules/malloc (Makefile.am): Likewise.
6011         * modules/mathl (Makefile.am): Likewise.
6012         * modules/mbchar (Makefile.am): Likewise.
6013         * modules/md2 (Makefile.am): Likewise.
6014         * modules/md4 (Makefile.am): Likewise.
6015         * modules/md5 (Makefile.am): Likewise.
6016         * modules/memcasecmp (Makefile.am): Likewise.
6017         * modules/memchr (Makefile.am): Likewise.
6018         * modules/memcmp (Makefile.am): Likewise.
6019         * modules/memcoll (Makefile.am): Likewise.
6020         * modules/memcpy (Makefile.am): Likewise.
6021         * modules/memmem (Makefile.am): Likewise.
6022         * modules/memmove (Makefile.am): Likewise.
6023         * modules/mempcpy (Makefile.am): Likewise.
6024         * modules/memrchr (Makefile.am): Likewise.
6025         * modules/memset (Makefile.am): Likewise.
6026         * modules/memxor (Makefile.am): Likewise.
6027         * modules/mkancesdirs (Makefile.am): Likewise.
6028         * modules/mkdir-p (Makefile.am): Likewise.
6029         * modules/mkdir (Makefile.am): Likewise.
6030         * modules/mkdtemp (Makefile.am): Likewise.
6031         * modules/mkstemp (Makefile.am): Likewise.
6032         * modules/mktime (Makefile.am): Likewise.
6033         * modules/modechange (Makefile.am): Likewise.
6034         * modules/mountlist (Makefile.am): Likewise.
6035         * modules/nanosleep (Makefile.am): Likewise.
6036         * modules/obstack (Makefile.am): Likewise.
6037         * modules/openat (Makefile.am): Likewise.
6038         * modules/pagealign_alloc (Makefile.am): Likewise.
6039         * modules/pathmax (Makefile.am): Likewise.
6040         * modules/physmem (Makefile.am): Likewise.
6041         * modules/poll (Makefile.am): Likewise.
6042         * modules/posixtm (Makefile.am): Likewise.
6043         * modules/posixver (Makefile.am): Likewise.
6044         * modules/putenv (Makefile.am): Likewise.
6045         * modules/quote (Makefile.am): Likewise.
6046         * modules/quotearg (Makefile.am): Likewise.
6047         * modules/raise (Makefile.am): Likewise.
6048         * modules/read-file (Makefile.am): Likewise.
6049         * modules/readline (Makefile.am): Likewise.
6050         * modules/readlink (Makefile.am): Likewise.
6051         * modules/readtokens (Makefile.am): Likewise.
6052         * modules/readutmp (Makefile.am): Likewise.
6053         * modules/realloc (Makefile.am): Likewise.
6054         * modules/regex (Makefile.am): Likewise.
6055         * modules/rename-dest-slash (Makefile.am): Likewise.
6056         * modules/rename (Makefile.am): Likewise.
6057         * modules/rijndael (Makefile.am): Likewise.
6058         * modules/rmdir (Makefile.am): Likewise.
6059         * modules/rpmatch (Makefile.am): Likewise.
6060         * modules/safe-read (Makefile.am): Likewise.
6061         * modules/safe-write (Makefile.am): Likewise.
6062         * modules/same-inode (Makefile.am): Likewise.
6063         * modules/same (Makefile.am): Likewise.
6064         * modules/save-cwd (Makefile.am): Likewise.
6065         * modules/savedir (Makefile.am): Likewise.
6066         * modules/setenv (Makefile.am): Likewise.
6067         * modules/settime (Makefile.am): Likewise.
6068         * modules/sha1 (Makefile.am): Likewise.
6069         * modules/sig2str (Makefile.am): Likewise.
6070         * modules/snprintf (Makefile.am): Likewise.
6071         * modules/stat-macros (Makefile.am): Likewise.
6072         * modules/stat-time (Makefile.am): Likewise.
6073         * modules/stdbool (Makefile.am): Likewise.
6074         * modules/stdint (Makefile.am): Likewise.
6075         * modules/stdlib-safer (Makefile.am): Likewise.
6076         * modules/stpcpy (Makefile.am): Likewise.
6077         * modules/stpncpy (Makefile.am): Likewise.
6078         * modules/strcase (Makefile.am): Likewise.
6079         * modules/strcasestr (Makefile.am): Likewise.
6080         * modules/strchrnul (Makefile.am): Likewise.
6081         * modules/strcspn (Makefile.am): Likewise.
6082         * modules/strdup (Makefile.am): Likewise.
6083         * modules/strerror (Makefile.am): Likewise.
6084         * modules/strftime (Makefile.am): Likewise.
6085         * modules/strndup (Makefile.am): Likewise.
6086         * modules/strnlen (Makefile.am): Likewise.
6087         * modules/strpbrk (Makefile.am): Likewise.
6088         * modules/strsep (Makefile.am): Likewise.
6089         * modules/strstr (Makefile.am): Likewise.
6090         * modules/strtod (Makefile.am): Likewise.
6091         * modules/strtoimax (Makefile.am): Likewise.
6092         * modules/strtok_r (Makefile.am): Likewise.
6093         * modules/strtol (Makefile.am): Likewise.
6094         * modules/strtoll (Makefile.am): Likewise.
6095         * modules/strtoul (Makefile.am): Likewise.
6096         * modules/strtoull (Makefile.am): Likewise.
6097         * modules/strtoumax (Makefile.am): Likewise.
6098         * modules/strverscmp (Makefile.am): Likewise.
6099         * modules/sys_socket (Makefile.am): Likewise.
6100         * modules/sys_stat (Makefile.am): Likewise.
6101         * modules/sysexits (Makefile.am): Likewise.
6102         * modules/time_r (Makefile.am): Likewise.
6103         * modules/timegm (Makefile.am): Likewise.
6104         * modules/timespec (Makefile.am): Likewise.
6105         * modules/tmpfile-safer (Makefile.am): Likewise.
6106         * modules/trim (Makefile.am): Likewise.
6107         * modules/unistd-safer (Makefile.am): Likewise.
6108         * modules/unlinkdir (Makefile.am): Likewise.
6109         * modules/unlocked-io (Makefile.am): Likewise.
6110         * modules/userspec (Makefile.am): Likewise.
6111         * modules/utime (Makefile.am): Likewise.
6112         * modules/utimecmp (Makefile.am): Likewise.
6113         * modules/utimens (Makefile.am): Likewise.
6114         * modules/vasnprintf (Makefile.am): Likewise.
6115         * modules/vasprintf (Makefile.am): Likewise.
6116         * modules/vsnprintf (Makefile.am): Likewise.
6117         * modules/xalloc (Makefile.am): Likewise.
6118         * modules/xgetcwd (Makefile.am): Likewise.
6119         * modules/xnanosleep (Makefile.am): Likewise.
6120         * modules/xreadlink (Makefile.am): Likewise.
6121         * modules/xstrtod (Makefile.am): Likewise.
6122         * modules/xstrtol (Makefile.am): Likewise.
6123         * modules/xstrtold (Makefile.am): Likewise.
6124         * modules/yesno (Makefile.am): Likewise.
6125         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
6126
6127 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
6128
6129         * modules/error (Makefile.am): Distribute files through
6130         EXTRA_DIST, not lib_SOURCES.
6131
6132 2006-10-12  Eric Blake  <ebb9@byu.net>
6133
6134         * modules/error (Makefile.am): Distribute files in /lib.
6135         * modules/obstack (Makefile.am): Likewise.
6136
6137 2006-10-12  Bruno Haible  <bruno@clisp.org>
6138
6139         * modules/acl (Makefile.am): Distribute all files in lib/ through
6140         EXTRA_DIST.
6141         * modules/arcfour (Makefile.am): Likewise.
6142         * modules/arctwo (Makefile.am): Likewise.
6143         * modules/argmatch (Makefile.am): Likewise.
6144         * modules/argz (Makefile.am): Likewise.
6145         * modules/atexit (Makefile.am): Likewise.
6146         * modules/backupfile (Makefile.am): Likewise.
6147         * modules/c-strtod (Makefile.am): Likewise.
6148         * modules/c-strtold (Makefile.am): Likewise.
6149         * modules/calloc (Makefile.am): Likewise.
6150         * modules/canon-host (Makefile.am): Likewise.
6151         * modules/canonicalize (Makefile.am): Likewise.
6152         * modules/chdir-long (Makefile.am): Likewise.
6153         * modules/chdir-safer (Makefile.am): Likewise.
6154         * modules/check-version (Makefile.am): Likewise.
6155         * modules/chown (Makefile.am): Likewise.
6156         * modules/cloexec (Makefile.am): Likewise.
6157         * modules/close-stream (Makefile.am): Likewise.
6158         * modules/closeout (Makefile.am): Likewise.
6159         * modules/crc (Makefile.am): Likewise.
6160         * modules/cycle-check (Makefile.am): Likewise.
6161         * modules/des (Makefile.am): Likewise.
6162         * modules/dirfd (Makefile.am): Likewise.
6163         * modules/dirname (Makefile.am): Likewise.
6164         * modules/dup2 (Makefile.am): Likewise.
6165         * modules/euidaccess (Makefile.am): Likewise.
6166         * modules/exclude (Makefile.am): Likewise.
6167         * modules/exitfail (Makefile.am): Likewise.
6168         * modules/fcntl-safer (Makefile.am): Likewise.
6169         * modules/file-type (Makefile.am): Likewise.
6170         * modules/fileblocks (Makefile.am): Likewise.
6171         * modules/filemode (Makefile.am): Likewise.
6172         * modules/filenamecat (Makefile.am): Likewise.
6173         * modules/fnmatch (Makefile.am): Likewise.
6174         * modules/fopen-safer (Makefile.am): Likewise.
6175         * modules/fpending (Makefile.am): Likewise.
6176         * modules/fprintftime (Makefile.am): Likewise.
6177         * modules/free (Makefile.am): Likewise.
6178         * modules/fsusage (Makefile.am): Likewise.
6179         * modules/ftruncate (Makefile.am): Likewise.
6180         * modules/fts (Makefile.am): Likewise.
6181         * modules/gc (Makefile.am): Likewise.
6182         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
6183         * modules/getaddrinfo (Makefile.am): Likewise.
6184         * modules/getcwd (Makefile.am): Likewise.
6185         * modules/getdelim (Makefile.am): Likewise.
6186         * modules/getdomainname (Makefile.am): Likewise.
6187         * modules/getgroups (Makefile.am): Likewise.
6188         * modules/gethostname (Makefile.am): Likewise.
6189         * modules/gethrxtime (Makefile.am): Likewise.
6190         * modules/getline (Makefile.am): Likewise.
6191         * modules/getloadavg (Makefile.am): Likewise.
6192         * modules/getlogin_r (Makefile.am): Likewise.
6193         * modules/getopt (Makefile.am): Likewise.
6194         * modules/getpass (Makefile.am): Likewise.
6195         * modules/getpass-gnu (Makefile.am): Likewise.
6196         * modules/getsubopt (Makefile.am): Likewise.
6197         * modules/gettime (Makefile.am): Likewise.
6198         * modules/gettimeofday (Makefile.am): Likewise.
6199         * modules/getugroups (Makefile.am): Likewise.
6200         * modules/getusershell (Makefile.am): Likewise.
6201         * modules/glob (Makefile.am): Likewise.
6202         * modules/group-member (Makefile.am): Likewise.
6203         * modules/hard-locale (Makefile.am): Likewise.
6204         * modules/hash (Makefile.am): Likewise.
6205         * modules/hmac-md5 (Makefile.am): Likewise.
6206         * modules/hmac-sha1 (Makefile.am): Likewise.
6207         * modules/human (Makefile.am): Likewise.
6208         * modules/idcache (Makefile.am): Likewise.
6209         * modules/imaxabs (Makefile.am): Likewise.
6210         * modules/imaxdiv (Makefile.am): Likewise.
6211         * modules/inet_ntop (Makefile.am): Likewise.
6212         * modules/inet_pton (Makefile.am): Likewise.
6213         * modules/inttostr (Makefile.am): Likewise.
6214         * modules/isapipe (Makefile.am): Likewise.
6215         * modules/lchown (Makefile.am): Likewise.
6216         * modules/long-options (Makefile.am): Likewise.
6217         * modules/lstat (Makefile.am): Likewise.
6218         * modules/malloc (Makefile.am): Likewise.
6219         * modules/mathl (Makefile.am): Likewise.
6220         * modules/mbchar (Makefile.am): Likewise.
6221         * modules/md2 (Makefile.am): Likewise.
6222         * modules/md4 (Makefile.am): Likewise.
6223         * modules/md5 (Makefile.am): Likewise.
6224         * modules/memcasecmp (Makefile.am): Likewise.
6225         * modules/memchr (Makefile.am): Likewise.
6226         * modules/memcmp (Makefile.am): Likewise.
6227         * modules/memcoll (Makefile.am): Likewise.
6228         * modules/memcpy (Makefile.am): Likewise.
6229         * modules/memmem (Makefile.am): Likewise.
6230         * modules/memmove (Makefile.am): Likewise.
6231         * modules/mempcpy (Makefile.am): Likewise.
6232         * modules/memrchr (Makefile.am): Likewise.
6233         * modules/memset (Makefile.am): Likewise.
6234         * modules/memxor (Makefile.am): Likewise.
6235         * modules/mkancesdirs (Makefile.am): Likewise.
6236         * modules/mkdir (Makefile.am): Likewise.
6237         * modules/mkdir-p (Makefile.am): Likewise.
6238         * modules/mkdtemp (Makefile.am): Likewise.
6239         * modules/mkstemp (Makefile.am): Likewise.
6240         * modules/mktime (Makefile.am): Likewise.
6241         * modules/modechange (Makefile.am): Likewise.
6242         * modules/mountlist (Makefile.am): Likewise.
6243         * modules/nanosleep (Makefile.am): Likewise.
6244         * modules/openat (Makefile.am): Likewise.
6245         * modules/pagealign_alloc (Makefile.am): Likewise.
6246         * modules/physmem (Makefile.am): Likewise.
6247         * modules/poll (Makefile.am): Likewise.
6248         * modules/posixtm (Makefile.am): Likewise.
6249         * modules/posixver (Makefile.am): Likewise.
6250         * modules/putenv (Makefile.am): Likewise.
6251         * modules/quote (Makefile.am): Likewise.
6252         * modules/quotearg (Makefile.am): Likewise.
6253         * modules/raise (Makefile.am): Likewise.
6254         * modules/read-file (Makefile.am): Likewise.
6255         * modules/readline (Makefile.am): Likewise.
6256         * modules/readlink (Makefile.am): Likewise.
6257         * modules/readtokens (Makefile.am): Likewise.
6258         * modules/readutmp (Makefile.am): Likewise.
6259         * modules/realloc (Makefile.am): Likewise.
6260         * modules/regex (Makefile.am): Likewise.
6261         * modules/rename (Makefile.am): Likewise.
6262         * modules/rename-dest-slash (Makefile.am): Likewise.
6263         * modules/rijndael (Makefile.am): Likewise.
6264         * modules/rmdir (Makefile.am): Likewise.
6265         * modules/rpmatch (Makefile.am): Likewise.
6266         * modules/safe-read (Makefile.am): Likewise.
6267         * modules/safe-write (Makefile.am): Likewise.
6268         * modules/same (Makefile.am): Likewise.
6269         * modules/save-cwd (Makefile.am): Likewise.
6270         * modules/savedir (Makefile.am): Likewise.
6271         * modules/setenv (Makefile.am): Likewise.
6272         * modules/settime (Makefile.am): Likewise.
6273         * modules/sha1 (Makefile.am): Likewise.
6274         * modules/sig2str (Makefile.am): Likewise.
6275         * modules/snprintf (Makefile.am): Likewise.
6276         * modules/stdlib-safer (Makefile.am): Likewise.
6277         * modules/stpcpy (Makefile.am): Likewise.
6278         * modules/stpncpy (Makefile.am): Likewise.
6279         * modules/strcase (Makefile.am): Likewise.
6280         * modules/strcasestr (Makefile.am): Likewise.
6281         * modules/strchrnul (Makefile.am): Likewise.
6282         * modules/strcspn (Makefile.am): Likewise.
6283         * modules/strdup (Makefile.am): Likewise.
6284         * modules/strerror (Makefile.am): Likewise.
6285         * modules/strftime (Makefile.am): Likewise.
6286         * modules/strndup (Makefile.am): Likewise.
6287         * modules/strnlen (Makefile.am): Likewise.
6288         * modules/strpbrk (Makefile.am): Likewise.
6289         * modules/strsep (Makefile.am): Likewise.
6290         * modules/strstr (Makefile.am): Likewise.
6291         * modules/strtod (Makefile.am): Likewise.
6292         * modules/strtoimax (Makefile.am): Likewise.
6293         * modules/strtok_r (Makefile.am): Likewise.
6294         * modules/strtol (Makefile.am): Likewise.
6295         * modules/strtoll (Makefile.am): Likewise.
6296         * modules/strtoul (Makefile.am): Likewise.
6297         * modules/strtoull (Makefile.am): Likewise.
6298         * modules/strtoumax (Makefile.am): Likewise.
6299         * modules/strverscmp (Makefile.am): Likewise.
6300         * modules/time_r (Makefile.am): Likewise.
6301         * modules/timegm (Makefile.am): Likewise.
6302         * modules/tmpfile-safer (Makefile.am): Likewise.
6303         * modules/unistd-safer (Makefile.am): Likewise.
6304         * modules/unlinkdir (Makefile.am): Likewise.
6305         * modules/userspec (Makefile.am): Likewise.
6306         * modules/utime (Makefile.am): Likewise.
6307         * modules/utimecmp (Makefile.am): Likewise.
6308         * modules/utimens (Makefile.am): Likewise.
6309         * modules/vasnprintf (Makefile.am): Likewise.
6310         * modules/vasprintf (Makefile.am): Likewise.
6311         * modules/vsnprintf (Makefile.am): Likewise.
6312         * modules/xalloc (Makefile.am): Likewise.
6313         * modules/xgetcwd (Makefile.am): Likewise.
6314         * modules/xnanosleep (Makefile.am): Likewise.
6315         * modules/xreadlink (Makefile.am): Likewise.
6316         * modules/xstrtod (Makefile.am): Likewise.
6317         * modules/xstrtol (Makefile.am): Likewise.
6318         * modules/xstrtold (Makefile.am): Likewise.
6319         * modules/yesno (Makefile.am): Likewise.
6320
6321 2006-10-12  Jim Meyering  <jim@meyering.net>
6322
6323         * m4/getloadavg.m4: Revert the change below.
6324
6325         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
6326         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
6327         fail with a symlink, which is what coreutils' ./bootstrap now
6328         creates by default.
6329
6330 2006-10-12  Bruno Haible  <bruno@clisp.org>
6331
6332         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
6333         mingw.
6334         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
6335         MSVC and mingw explicitly.
6336
6337 2006-10-11  Simon Josefsson  <jas@extundo.com>
6338             Bruno Haible  <bruno@clisp.org>
6339
6340         Add support for multiple gnulib-tool invocations in the scope of a
6341         single configure.ac file.
6342         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
6343         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
6344         with the same contents as the _LIBADD variable.
6345         (func_emit_initmacro_start, func_emit_initmacro_end,
6346         func_emit_initmacro_done): New functions.
6347         (func_import, func_create_testdir): Invoke them. Allow the identifiers
6348         gl_LIBOBJS and gl_LTLIBOBJS.
6349
6350 2006-10-11  Bruno Haible  <bruno@clisp.org>
6351
6352         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
6353         (func_create_testdir): Don't create po/Makefile.am, don't invoke
6354         autoreconf. Instead, invoke autopoint explicitly but move back the
6355         *.m4 files from gnulib.
6356
6357 2006-10-11  Bruno Haible  <bruno@clisp.org>
6358
6359         * gnulib-tool (func_usage): Make module names after --create-testdir
6360         optional.
6361         (func_create_testdir): If no module was specified, use nearly all
6362         modules.
6363
6364 2006-10-12  Jim Meyering  <jim@meyering.net>
6365
6366         Big performance improvement for fts-based tools that use FTS_NOSTAT.
6367         Avoid spurious inode-mismatch problems on non-POSIX file systems.
6368         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
6369         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
6370         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
6371         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
6372         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
6373         (fts_set_stat_required): New function.
6374         (fts_open): Defer the calls to fts_stat, if possible or requested.
6375         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
6376         into fts_stat itself.
6377         (fts_read): Perform any required (deferred) fts_stat call.
6378         (fts_build): Likewise, for the directory we're about to open and read.
6379         In the readdir loop, carefully decide whether each entry will require
6380         an eventual call to fts_stat, using dirent.d_type info if available.
6381         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
6382         a command line argument into this function.  Update all callers.
6383         Map a return value of FTS_DOT to FTS_D for a command line argument.
6384         * modules/fts (Depends-on): Add d-type.  Alphabetize.
6385         Thanks to Miklos Szeredi for his tenacity and for the initial
6386         bug report about "find" failing on a FUSE-based file system.
6387
6388         * lib/fts.c (fts_open): Use consistent indentation.
6389
6390 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
6391
6392         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
6393         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
6394         reported by Jim Meyering.  All uses of cache variables renamed
6395         to match Autoconf's.
6396         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
6397         the other one.
6398
6399         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
6400         Fix misspelling in diagnostic.
6401
6402 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
6403
6404         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
6405         defined.  Problem reported by Matthew Woehlke.
6406
6407         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
6408         Add support for Tandem NonStop R series.
6409         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
6410         Use new macro.
6411
6412         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
6413         (has_trailing_slash): Omit size arg; all callers changed.
6414         Omit 'inline', since it doesn't help performance and we'd
6415         need to configure it.
6416         Don't count //, ///, etc. as having a trailing slash.
6417         As a side effect, this removes a C99ism reported by Matthew Woehlke.
6418         (rpl_rename_dest_slash): On failure, use rename's errno rather
6419         than (in some cases) an incorrect or junk errno.
6420         Simplify code by removing need to compute length; this does
6421         cause it to make two passes instead of one over the file name,
6422         but it's worth it.
6423
6424         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
6425         change, since Autoconf's version may no longer be appropriate now
6426         that we are using CVS Autoconf's version.  Add support for Tandem.
6427
6428 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
6429             Bruno Haible  <bruno@clisp.org>
6430
6431         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
6432         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
6433         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
6434         gl_AC_TYPE_LONG_LONG.
6435
6436         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
6437         instead of HAVE_LONG_LONG.
6438         * lib/printf-args.c (printf_fetchargs): Likewise.
6439         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
6440         * lib/vasnprintf.c (VASNPRINTF): Likewise.
6441         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
6442         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
6443         gl_AC_TYPE_LONG_LONG.
6444
6445 2006-10-11  Bruno Haible  <bruno@clisp.org>
6446
6447         * m4/longlong.m4: Add comments.
6448         * m4/ulonglong.m4: Likewise.
6449
6450 2006-10-10  Bruno Haible  <bruno@clisp.org>
6451
6452         Make it possible to #define stpcpy, strdup to aliases.
6453         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
6454         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
6455
6456 2006-10-10  Bruno Haible  <bruno@clisp.org>
6457
6458         Make it possible to #define gcd to an alias.
6459         * lib/gcd.c: Include config.h.
6460
6461 2006-10-10  Bruno Haible  <bruno@clisp.org>
6462
6463         Make it possible to #define c_isascii to an alias.
6464         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
6465         defined. Undefine the macros before defining them, to avoid gcc
6466         warnings.
6467         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
6468         define NO_C_CTYPE_MACROS early.
6469
6470 2006-10-10  Bruno Haible  <bruno@clisp.org>
6471
6472         Make it possible to #define set_program_name to an alias.
6473         * lib/progname.c: Don't undefine set_program_name; instead, undefine
6474         ENABLE_RELOCATABLE early.
6475
6476 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
6477
6478         Port to Tandem NSK OSS, which has 64-bit signed int but at most
6479         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
6480         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
6481         More generally, don't assume that 64-bit signed int is available
6482         if unsigned int is, and vice versa.
6483         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
6484         unsigned symbols, not on their signed counterparts.
6485         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
6486         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
6487         (UINT64_C, UINTMAX_C):
6488         Likewise.
6489         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
6490         unsigned counterparts.
6491         (Have_long_long, Unsigned): New macros.
6492         (Int): Renamed from INT.
6493         (strtoimax): Use the new macros.
6494         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
6495         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
6496         * modules/inttypes (inttypes.h): Substitute
6497         HAVE_UNSIGNED_LONG_LONG_INT.
6498         * modules/stdint (stdint.h): Likewise.
6499         (Files): Add m4/ulonglong.m4.
6500
6501 2006-10-10  Bruno Haible  <bruno@clisp.org>
6502
6503         Fix a gcc -Wshadow warning.
6504         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
6505         to 'bucket'.
6506         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
6507         gl_linked_indexof_from_to): Likewise.
6508         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
6509         Likewise.
6510         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
6511         Likewise.
6512         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
6513         Reported by Eric Blake.
6514
6515 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
6516
6517         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
6518         for NetBSD.  Problem reported by Bruno Haible.
6519
6520 2006-10-09  Jim Meyering  <jim@meyering.net>
6521
6522         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
6523         Patch from Bruno Haible.
6524
6525 2006-10-09  Jim Meyering  <jim@meyering.net>
6526
6527         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
6528         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
6529         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
6530
6531 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
6532
6533         Don't include <config.h> twice; this doesn't work in some cases,
6534         e.g., when config.h has "#define intmax_t long long int" and
6535         we include <config.h>, <inttypes.h>, <config.h> in that order.
6536         Problem reported by Matthew Woehlke in:
6537         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
6538         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
6539         * lib/fts-cycle.c: Don't include config.h.
6540         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
6541         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
6542         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
6543         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
6544         inttypes.h.
6545         * lib/xstrtoumax.c: Likewise.
6546         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
6547         __strtol and the like, so that this module is more like its siblings.
6548         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
6549         Remove; no longer needed now that we assume gnulib inttypes.h.
6550
6551 2006-10-08  Bruno Haible  <bruno@clisp.org>
6552
6553         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
6554         option.
6555
6556 2006-10-07  Jim Meyering  <jim@meyering.net>
6557
6558         * modules/inttypes (inttypes.h): Revert what seems to have been
6559         an inadvertent part of today's change: use "|", not "/" in the
6560         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
6561
6562 2006-10-07  Bruno Haible  <bruno@clisp.org>
6563
6564         * modules/sublist: New file.
6565
6566 2006-10-07  Bruno Haible  <bruno@clisp.org>
6567
6568         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
6569         * modules/argz (argz.h): Likewise.
6570         * modules/arpa_inet (arpa/inet.h): Likewise.
6571         * modules/byteswap (byteswap.h): Likewise.
6572         * modules/configmake (configmake.h): Likewise.
6573         * modules/fcntl (fcntl.h): Likewise.
6574         * modules/fnmatch (fnmatch.h): Likewise.
6575         * modules/getopt (getopt.h): Likewise.
6576         * modules/glob (glob.h): Likewise.
6577         * modules/inttypes (inttypes.h): Likewise.
6578         * modules/netinet_in (netinet/in.h): Likewise.
6579         * modules/poll (poll.h): Likewise.
6580         * modules/stdbool (stdbool.h): Likewise.
6581         * modules/stdint (stdint.h): Likewise.
6582         * modules/sys_select (sys/select.h): Likewise.
6583         * modules/sys_socket (sys/socket.h): Likewise.
6584         * modules/sys_stat (sys/stat.h): Likewise.
6585         * modules/sysexits (sysexits.h): Likewise.
6586         * modules/unistd (unistd.h): Likewise.
6587         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6588         Add a "DO NOT EDIT" comment to the generated file.
6589         (func_import): Likewise for gnulib-comp.m4.
6590
6591 2006-10-07  Bruno Haible  <bruno@clisp.org>
6592
6593         * lib/gl_sublist.h: New file.
6594         * lib/gl_sublist.c: New file.
6595
6596 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
6597
6598         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
6599         name (relative to the original working directory) and the file
6600         name component (relative to the temporary working directory).  All
6601         callers changed.
6602         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
6603         * lib/mkdir-p.c (make_dir_parents): Likewise.
6604         * lib/mkdir-p.h (make_dir_parents): Likewise.
6605
6606 2006-10-06  Eric Blake  <ebb9@byu.net>
6607
6608         Define several macros for use by the clean-temp module.
6609         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
6610         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
6611         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
6612
6613         * lib/clean-temp.h (close_stream_temp): New declaration.
6614         * lib/clean-temp.c (includes): Pull in headers according to what
6615         other modules are in use.
6616         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
6617
6618 2006-10-06  Bruno Haible  <bruno@clisp.org>
6619
6620         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
6621         instead of fopen, fwriteerror.
6622
6623 2006-10-06  Bruno Haible  <bruno@clisp.org>
6624
6625         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
6626         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
6627         int.
6628         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
6629         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
6630         Return an error indicator.
6631         Suggested by Eric Blake.
6632
6633 2006-10-06  Bruno Haible  <bruno@clisp.org>
6634
6635         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
6636         Reported by Eric Blake.
6637
6638 2006-10-06  Bruno Haible  <bruno@clisp.org>
6639
6640         * modules/closeout (Description): Mention stderr too.
6641
6642 2006-10-06  Bruno Haible  <bruno@clisp.org>
6643         and Paul Eggert  <eggert@cs.ucla.edu>
6644
6645         * lib/closeout.c (close_stdout): Also close stderr.
6646         * lib/closeout.h: Update comment.
6647
6648 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
6649
6650         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
6651         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
6652         * lib/dirchownmod.c: Include lchown.h.
6653         * lib/lchown.c: Don't include files that lchown.h now includes.
6654         Don't declare chown, since lchown.h now does that.
6655         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
6656         (lchown): Define to rpl_chown if lchown is declared but
6657         does not exist.  Declare using a prototype if lchown is not
6658         declared.  Add a copyright notice.
6659         * lib/mkstemp.h: Include <unistd.h>.
6660         * lib/openat.c: Include lchown.h.
6661
6662         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
6663         we now test for that separately.
6664         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
6665         rather than O_NOFOLLOW, when testing whether it's possible to
6666         avoid a race condition reliably.
6667         * lib/savewd.c (savewd_chdir): Likewise.
6668
6669         Remove macros that are no longer needed now that stdint.h is
6670         reliable.
6671         * lib/fsusage.c (UINTMAX_MAX): Remove.
6672         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
6673         * lib/utimecmp.c (SIZE_MAX): Remove.
6674
6675         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
6676
6677         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
6678         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
6679         O_NOATIME works.
6680
6681 2006-10-05  Bruno Haible  <bruno@clisp.org>
6682
6683         * lib/gl_list.h (gl_sortedlist_search_from_to,
6684         gl_sortedlist_indexof_from_to): New declarations.
6685         (gl_list_implementation): New fields sortedlist_search_from_to,
6686         sortedlist_indexof_from_to.
6687         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
6688         inline functions.
6689         * lib/gl_list.c (gl_sortedlist_search_from_to,
6690         gl_sortedlist_indexof_from_to): New functions.
6691         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
6692         function.
6693         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
6694         (gl_array_sortedlist_search_from_to): New function.
6695         (gl_array_list_implementation): Update.
6696         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
6697         function.
6698         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
6699         (gl_carray_sortedlist_search_from_to): New function.
6700         (gl_carray_list_implementation): Update.
6701         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
6702         gl_linked_sortedlist_indexof_from_to): New functions.
6703         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
6704         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
6705         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
6706         gl_tree_sortedlist_indexof_from_to): New functions.
6707         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
6708         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
6709         Update.
6710         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
6711         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
6712         Update.
6713
6714 2006-10-05  Bruno Haible  <bruno@clisp.org>
6715
6716         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
6717         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
6718         (struct gl_list_implementation): Add fields search_from_to,
6719         indexof_from_to. Remove fields search, indexof.
6720         (gl_list_search): Use the search_from_to method.
6721         (gl_list_search_from, gl_list_search_from_to): New functions.
6722         (gl_list_indexof): Use the indexof_from_to method.
6723         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
6724         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
6725         (gl_list_search_from, gl_list_search_from_to): New functions.
6726         (gl_list_indexof): Use the indexof_from_to method.
6727         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
6728         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
6729         gl_array_indexof. Add start_index, end_index arguments.
6730         (gl_array_search_from_to): Renamed from gl_array_search. Add
6731         start_index, end_index arguments.
6732         (gl_array_remove, gl_array_list_implementation): Update.
6733         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
6734         gl_carray_indexof. Add start_index, end_index arguments.
6735         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
6736         start_index, end_index arguments.
6737         (gl_carray_remove, gl_carray_list_implementation): Update.
6738         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
6739         gl_linked_search. Add start_index, end_index arguments.
6740         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
6741         start_index, end_index arguments.
6742         (gl_linked_remove): Update.
6743         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
6744         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
6745         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
6746         field to 'size_t'.
6747         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
6748         gl_tree_search. Add start_index, end_index arguments.
6749         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
6750         start_index, end_index arguments.
6751         (gl_tree_remove): Update.
6752         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
6753         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
6754         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
6755         function.
6756         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
6757         gl_tree_search. Add start_index, end_index arguments.
6758         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
6759         start_index, end_index arguments.
6760         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
6761         Update.
6762         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
6763
6764 2006-10-05  Bruno Haible  <bruno@clisp.org>
6765
6766         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
6767
6768         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
6769         fwriteerror_temp): New declarations.
6770         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
6771         (descriptors): New variable.
6772         (cleanup): First, close the descriptors.
6773         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
6774         fclose_temp, fwriteerror_temp): New functions.
6775
6776 2006-10-04  Jim Meyering  <jim@meyering.net>
6777
6778         * lib/fts.c (fts_open): Tiny comment change.
6779
6780 2006-10-04  Bruno Haible  <bruno@clisp.org>
6781
6782         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
6783         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
6784         gl_LOCK_BODY.
6785         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
6786         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
6787         gl_LOCK_EARLY_BODY.
6788         (gl_LOCK): Require gl_LOCK_BODY.
6789
6790 2006-10-04  Bruno Haible  <bruno@clisp.org>
6791
6792         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
6793         (gl_oset_search_atleast): New declaration.
6794         (struct gl_oset_implementation): Add field 'search_atleast'.
6795         (gl_oset_search_atleast): New inline function.
6796         * lib/gl_oset.c (gl_oset_search_atleast): New function.
6797         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
6798         (gl_array_oset_implementation): Update.
6799         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
6800         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
6801         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
6802
6803 2006-10-04  Bruno Haible  <bruno@clisp.org>
6804
6805         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
6806
6807 2006-10-03  Bruno Haible  <bruno@clisp.org>
6808
6809         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
6810         from gl_avltreehash_list_implementation.
6811
6812 2006-10-03  Bruno Haible  <bruno@clisp.org>
6813
6814         * lib/gl_oset.c (gl_oset_add): Fix return type.
6815
6816 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
6817
6818         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
6819
6820 2006-10-02  Eric Blake  <ebb9@byu.net>
6821
6822         * modules/strnlen (Depends-on): Add extensions.
6823
6824 2006-10-02  Eric Blake  <ebb9@byu.net>
6825
6826         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
6827         definition in 2.60+.
6828
6829 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
6830
6831         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
6832         checks.
6833
6834 2006-10-02  Bruno Haible  <bruno@clisp.org>
6835
6836         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
6837         to the AUTOMAKE_OPTIONS.
6838         Reported by Jim Meyering.
6839
6840 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
6841
6842         Work around bug in Solaris 10 /proc file system:
6843         /proc/self/fd/NNN/.. isn't the parent directory of
6844         the directory whose file descriptor is NNN.  This needs to
6845         be worked around at run time, not compile time, since a
6846         program might be built on Solaris 8, where things work, and
6847         run on Solaris 10.
6848         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
6849         to use the following interface instead:
6850         (OPENAT_BUFFER_SIZE): New macro.
6851         (openat_proc_name): New function.
6852         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
6853         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
6854         Likewise.
6855         * lib/openat-proc.c: New file.
6856         * modules/openat (Files): Add lib/openat-proc.c.
6857         (Depends-on): Add same-inode, stdbool.
6858         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
6859
6860 2006-09-29  Bruno Haible  <bruno@clisp.org>
6861
6862         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
6863         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
6864         argument. Set stdout_closed before testing for ferror, not after.
6865         (fwriteerror, fwriteerror_no_ebadf): New functions.
6866
6867 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6868
6869         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
6870
6871 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
6872
6873         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
6874         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
6875
6876 2006-09-28  Jim Meyering  <jim@meyering.net>
6877
6878         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
6879         Include <unistd.h>.
6880
6881 2006-09-28  Bruno Haible  <bruno@clisp.org>
6882
6883         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
6884         * modules/linkedhash-list (Depends-on): Likewise.
6885         * modules/rbtreehash-list (Depends-on): Likewise.
6886
6887 2006-09-28  Bruno Haible  <bruno@clisp.org>
6888
6889         * lib/strndup.h: Simplify the redefinition of strndup.
6890         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
6891         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
6892
6893 2006-09-28  Bruno Haible  <bruno@clisp.org>
6894
6895         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
6896         * lib/gl_linkedhash_list.c: Likewise.
6897         * lib/gl_rbtreehash_list.c: Likewise.
6898
6899 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
6900
6901         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
6902         getaddrinfo.
6903
6904         * lib/__fpending.h: Don't include <stdio_ext.h> unless
6905         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
6906         it causes <stdio_ext.h> to cause a compile-time error.
6907         Problem reported by Nelson H. F. Beebe.
6908         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
6909         of HAVE_DECL___PENDING.
6910
6911         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
6912         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
6913         declaration.
6914
6915 2006-09-27  Jim Meyering  <jim@meyering.net>
6916
6917         This file could end up with a definition for a function
6918         named __strndup, rather than rpl_strndup on a system with
6919         incomplete weak_alias support.
6920         * lib/strndup.c (strndup): Rename from __strndup.
6921         Remove #defines that used to map __strndup to strndup.
6922         Don't use K&R prototypes.
6923         Remove LIBC-related code, since this file is not sync'd with glibc.
6924         * lib/strndup.h: Revamp, accordingly.
6925         * m4/strndup.m4: Modernize.
6926
6927 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
6928
6929         * modules/savewd (Depends-on): Add 'raise'.
6930         * lib/savewd.c: Include <signal.h>, for 'raise'.
6931
6932 2006-09-26  Jim Meyering  <jim@meyering.net>
6933
6934         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
6935         when we detect Darwin 8.7.0's acl_get_file bug.
6936         Rearrange to perform the new (below) run-test while $LIBS
6937         contains any acl-related library.  Set USE_ACL at the end.
6938         (gl_ACL_GET_FILE): New function.
6939
6940 2006-09-26  Eric Blake  <ebb9@byu.net>
6941
6942         * lib/verror.c: Include <config.h> unconditionally.
6943
6944 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
6945
6946         * modules/clock-time (Maintainer): Add self.
6947         * modules/getlogin_r (Depends-on): Add extensions.
6948
6949 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6950
6951         * modules/clock-time: New module.
6952         * modules/nanosleep (Depends-on): Add clock-time.
6953         * modules/gethrxtime (Depends-on): Likewise.
6954         * modules/gettime (Depends-on): Likewise.
6955         * modules/settime (Depends-on): Likewise.
6956
6957         * modules/fts-lgpl: Depend on openat.
6958         * modules/mkancesdirs: Depend on savewd.
6959         * modules/mkdir-p: Likewise.
6960
6961 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6962
6963         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
6964
6965         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
6966         `gl_have_arbitrary_file_name_length_limit' to
6967         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
6968         actually works between configure runs.
6969
6970 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6971             Bruno Haible  <bruno@clisp.org>
6972
6973         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
6974
6975 2006-09-25  Jim Meyering  <jim@meyering.net>
6976
6977         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
6978         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
6979
6980 2006-09-25  Eric Blake  <ebb9@byu.net>
6981
6982         * gnulib-tool (func_import, func_create_testdir): Fix typos in
6983         exec's in 2006-09-18 patch when shuffling fds.
6984
6985 2006-09-25  Bruno Haible  <bruno@clisp.org>
6986
6987         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
6988         Reported by Jim Meyering.
6989
6990 2006-09-24  Jim Meyering  <jim@meyering.net>
6991
6992         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
6993         compare a pointer against a literal "0".  That caused failures with
6994         at least HP-UX's hpcc.
6995
6996 2006-09-22  Simon Josefsson  <jas@extundo.com>
6997
6998         * modules/gc-sha1:
6999         * modules/gc-md4:
7000         * modules/gc-hmac-sha1:
7001         * modules/gc-hmac-md5:
7002         * modules/gc-des:
7003         * modules/gc-arcfour: Distribute more files.
7004
7005 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7006
7007         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
7008         (gl_linked_iterator_from_to): Initialize struct completely.
7009         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
7010         (gl_tree_iterator_from_to): Likewise
7011         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
7012         * lib/gl_array_list.c [lint] (gl_array_iterator)
7013         (gl_array_iterator_from_to): Likewise.
7014         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
7015         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
7016         (gl_carray_iterator_from_to): Likewise.
7017
7018         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
7019         * lib/md4.c (md4_process_block): Remove unused variable.
7020         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
7021         parentheses for clarity.
7022
7023 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7024
7025         * modules/bison-i18n (Depends-on): Add gettext.
7026
7027 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7028
7029         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
7030         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
7031         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
7032         also add missing comma that caused broken test.
7033         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
7034         stdlib.h, for `abort'.
7035         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
7036         variables.
7037         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
7038         include unistd.h if present, for `rmdir'.
7039         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
7040         variables.
7041         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
7042         in the process include standard headers for prototypes.
7043         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
7044         gets declared on GNU/Linux.
7045         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
7046         unistd.h, for `rmdir'.
7047         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
7048
7049         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
7050         always true.
7051         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
7052
7053         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
7054
7055 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7056
7057         * gnulib-tool (func_version): Create output all at once.  This
7058         may help avoid triggering unnecessary SIGPIPEs, and at any
7059         rate it doesn't hurt.
7060
7061 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7062             Bruno Haible  <bruno@clisp.org>
7063
7064         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
7065         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
7066         * m4/signed.m4 (bh_C_SIGNED): Likewise.
7067
7068         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
7069         (gl_FUNC_VASPRINTF): Invoke it.
7070
7071 2006-09-22  Bruno Haible  <bruno@clisp.org>
7072
7073         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
7074         getloadavg.c as first argument.
7075
7076 2006-09-22  Bruno Haible  <bruno@clisp.org>
7077
7078         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
7079         at the beginning of the gl_INIT macro.
7080         * modules/getloadavg (configure.ac): Pass $gl_source_base to
7081         gl_GETLOADAVG.
7082
7083 2006-09-22  Bruno Haible  <bruno@clisp.org>
7084
7085         * gnulib-tool (func_create_megatestdir): Don't include the config-h
7086         module.
7087         Suggested by Ralf Wildenhues.
7088
7089 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
7090
7091         Import this patch from libc:
7092
7093         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
7094
7095         * lib/regex_internal.c (re_string_reconstruct): Handle
7096         offset < pstr->valid_raw_len && pstr->offsets_needed case.
7097         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
7098         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
7099         re_string_context_at.
7100
7101         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
7102         now requires it.
7103         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
7104         gl_REGEX now does it for us.
7105         (gl_REGEX): Add test taken from
7106         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
7107
7108         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
7109         Check that large offsets work.  Modernize Autoconf usages.
7110         Prefer "yes" to mean a good thing rather than a bad.
7111         Don't put "#define mkstemp" in config.h, as this might interfere
7112         with standard system headers that "#define mkstemp mkstemp64".
7113
7114         * modules/mkstemp (Depends-on): Add extensions, so that
7115         mkstemp is visible on some platforms.
7116         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
7117         (Include): Change to "mkstemp.h" from <stdlib.h>.
7118         (Files): Add mkstemp.h.
7119
7120         * lib/mkstemp.h: New file, since some standard headers
7121         #define mkstemp.
7122         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
7123         Include "mkstemp.h".
7124         Make the _LIBC code resemble glibc original more,
7125         e.g., use K&R style.
7126         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
7127         (mkstemp): Remove, since mkstemp.h does this for us.
7128         * lib/stdlib--.h: Include mkstemp.h.
7129
7130         Import this patch from libc:
7131
7132         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7133
7134         * lib/tempname.c (__gen_tempname): Change attempts_min
7135         into a macro.  Use preprocessor to decide how to initialize
7136         attempts [Coverity CID 67].
7137
7138 2006-09-20  Bruno Haible  <bruno@clisp.org>
7139
7140         * lib/mkdtemp.c: Import from libc.
7141         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7142                 * sysdeps/posix/tempname.c (__gen_tempname): Change
7143                 attempts_min into a macro.  Use preprocessor to decide how to
7144                 initialize attempts [Coverity CID 67].
7145         2001-11-27  Paul Eggert  <eggert@twinsun.com>
7146                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
7147                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
7148
7149 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7150
7151         * gnulib-tool (func_exit): New function, to allow to pass the
7152         exit status portably through the trap.  Use everywhere.
7153         (--help, --version): Signal a write error.
7154         (trap): catch SIGPIPE, for write errors.
7155         Exit at the end of the trap, with the correct exit status.
7156
7157 2006-09-19  Karl Berry  <karl@gnu.org>
7158
7159         * doc/gnulib.texi: note about the license texinfo files.
7160
7161 2006-09-19  Eric Blake  <ebb9@byu.net>
7162
7163         * gnulib-tool: Avoid space-tab.
7164
7165 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7166
7167         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
7168         that prevented coreutils 6.1 from building.  Problem reported
7169         by Petter Reinholdtsen.
7170
7171 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7172
7173         * gnulib-tool (avoidlist): Fix typo that broke options like
7174         --avoid=lock that are used by coreutils bootstrap.
7175
7176 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
7177
7178         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
7179         more systematically.
7180
7181 2006-09-18  Jim Meyering  <jim@meyering.net>
7182
7183         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
7184
7185 2006-09-18  Bruno Haible  <bruno@clisp.org>
7186
7187         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
7188
7189 2006-09-18  Bruno Haible  <bruno@clisp.org>
7190
7191         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
7192         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
7193         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
7194         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
7195         * m4/gettext.m4: Require autoconf >= 2.52.
7196         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
7197         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
7198         of gl_cv_header_inttypes_h.
7199
7200 2006-09-18  Bruno Haible  <bruno@clisp.org>
7201
7202         * lib/javaversion.c: Include configmake.h.
7203
7204 2006-09-18  Bruno Haible  <bruno@clisp.org>
7205
7206         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
7207         avoid that the while loops be executed in a subshell.
7208
7209 2006-09-18  Bruno Haible  <bruno@clisp.org>
7210
7211         * MODULES.html.sh (func_module): Break long lines.
7212         Suggested by Bruce Korb <bkorb@gnu.org>.
7213
7214 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7215
7216         Speed up by a factor of 1.12.
7217         * gnulib-tool (nl): New variable.
7218         (func_import): Rewrite include directive extraction to only read each
7219         directive once.
7220
7221 2006-09-17  Bruno Haible  <bruno@clisp.org>
7222
7223         * modules/javaversion (Makefile.am): Remove DEFS setting.
7224         (Depends-on): Add configmake, for PKGDATADIR definition.
7225
7226 2006-09-17  Bruno Haible  <bruno@clisp.org>
7227
7228         * gnulib-tool (func_create_testdir): Rewrite all files at once.
7229
7230 2006-09-17  Bruno Haible  <bruno@clisp.org>
7231
7232         * gnulib-tool (func_append): New function, stolen from libtool.m4.
7233         (func_modules_transitive_closure, func_modules_add_dummy,
7234         func_modules_to_filelist, func_import, func_create_testdir,
7235         func_create_megatestdir, ...): Use it wherever possible.
7236         Suggested by Ralf Wildenhues.
7237
7238 2006-09-16  Karl Berry  <karl@gnu.org>
7239
7240         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
7241         to avoid sectioning errors.
7242         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
7243         [ifinfo]: blank line after @center-ed titles.
7244         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
7245         Spell FSF address consistently with others.
7246         (These changes approved by rms.)
7247
7248 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7249
7250         Speed up by a factor of 1.61.
7251         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
7252         already checked module names again.
7253
7254 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7255
7256         Speed up by a factor of 1.13.
7257         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
7258         for new_files, and the input to func_add_or_update.
7259
7260 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7261
7262         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
7263         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
7264
7265 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7266
7267         * modules/mkancesdirs (Depends-on): Add fcntl.
7268         * modules/savewd: New file.
7269         * MODULES.html.sh (File system functions): Add savewd.
7270
7271         * modules/configmake (Makefile.am): Add support for the
7272         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
7273
7274 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7275
7276         * m4/savewd.m4: New file.
7277
7278 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7279
7280         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
7281         (dirchownmod): New arg FD.  All callers changed.
7282         Use FD rather than opening the directory ourself, as opening is
7283         now the caller's responsibility.
7284         * lib/dirchownmod.h: Likewise.
7285         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
7286         hosts that require <sys/types.h> before <sys/stat.h>.  Include
7287         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
7288         (test_dir): Remove.
7289         (mkancesdirs): Return length of prefix of FILE that has already
7290         been made, or -2 if there is a child doing the work.  Redo
7291         algorithm so that it is O(N) rather than O(N**2).  Optimize away
7292         ".", and treat ".." specially since it might stray back into
7293         already-created areas.  Use a subprocess if necessary.  New arg
7294         WD; all users changed.  MAKE_DIR function should now return 1
7295         if it creates a directory that is not readable.  Return -2 if
7296         a child process is spun off.
7297         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
7298         Adjust signature to match code.
7299         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
7300         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
7301         all users changed.
7302         * lib/savewd.c, lib/savewd.h: New files.
7303
7304 2006-09-15  Jim Meyering  <jim@meyering.net>
7305
7306         * modules/rename-dest-slash: New module.
7307         * MODULES.html.sh (posix_compat): Add it here.
7308
7309         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
7310
7311 2006-09-15  Jim Meyering  <jim@meyering.net>
7312
7313         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
7314         file.
7315
7316         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
7317
7318 2006-09-15  Jim Meyering  <jim@meyering.net>
7319
7320         * lib/rename-dest-slash.c (has_trailing_slash): Use
7321         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
7322         (rpl_rename_dest_slash): Perform the cheaper trailing slash
7323         test before testing whether SRC is a directory.
7324         Suggestions from Bruno Haible.
7325
7326         Avoid a warning about an unused variable.
7327         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
7328         into the #ifdef block where it's used.
7329
7330         * lib/rename-dest-slash.c: New file.
7331
7332 2006-09-14  Bruno Haible  <bruno@clisp.org>
7333
7334         * lib/allocsa.c: Include <config.h> unconditionally.
7335         * lib/asnprintf.c: Likewise.
7336         * lib/asprintf.c: Likewise.
7337         * lib/c-strcasecmp.c: Likewise.
7338         * lib/c-strcasestr.c: Likewise.
7339         * lib/c-strncasecmp.c: Likewise.
7340         * lib/c-strstr.c: Likewise.
7341         * lib/classpath.c: Likewise.
7342         * lib/clean-temp.c: Likewise.
7343         * lib/concatpath.c: Likewise.
7344         * lib/copy-file.c: Likewise.
7345         * lib/csharpcomp.c: Likewise.
7346         * lib/csharpexec.c: Likewise.
7347         * lib/execute.c: Likewise.
7348         * lib/fatal-signal.c: Likewise.
7349         * lib/findprog.c: Likewise.
7350         * lib/fwriteerror.c: Likewise.
7351         * lib/gl_array_list.c: Likewise.
7352         * lib/gl_array_oset.c: Likewise.
7353         * lib/gl_avltree_list.c: Likewise.
7354         * lib/gl_avltree_oset.c: Likewise.
7355         * lib/gl_avltreehash_list.c: Likewise.
7356         * lib/gl_carray_list.c: Likewise.
7357         * lib/gl_linked_list.c: Likewise.
7358         * lib/gl_linkedhash_list.c: Likewise.
7359         * lib/gl_list.c: Likewise.
7360         * lib/gl_oset.c: Likewise.
7361         * lib/gl_rbtree_list.c: Likewise.
7362         * lib/gl_rbtree_oset.c: Likewise.
7363         * lib/gl_rbtreehash_list.c: Likewise.
7364         * lib/imaxabs.c: Likewise.
7365         * lib/imaxdiv.c: Likewise.
7366         * lib/javacomp.c: Likewise.
7367         * lib/javaexec.c: Likewise.
7368         * lib/javaversion.c: Likewise.
7369         * lib/linebreak.c: Likewise.
7370         * lib/localcharset.c: Likewise.
7371         * lib/lock.c: Likewise.
7372         * lib/mbchar.c: Likewise.
7373         * lib/mbswidth.c: Likewise.
7374         * lib/mkdtemp.c: Likewise.
7375         * lib/pipe.c: Likewise.
7376         * lib/printf-args.c: Likewise.
7377         * lib/printf-parse.c: Likewise.
7378         * lib/progname.c: Likewise.
7379         * lib/progreloc.c: Likewise.
7380         * lib/readlink.c: Likewise.
7381         * lib/sh-quote.c: Likewise.
7382         * lib/stpcpy.c: Likewise.
7383         * lib/stpncpy.c: Likewise.
7384         * lib/strcasecmp.c: Likewise.
7385         * lib/strcasestr.c: Likewise.
7386         * lib/strcspn.c: Likewise.
7387         * lib/striconv.c: Likewise.
7388         * lib/strncasecmp.c: Likewise.
7389         * lib/strnlen1.c: Likewise.
7390         * lib/strstr.c: Likewise.
7391         * lib/strtok_r.c: Likewise.
7392         * lib/tls.c: Likewise.
7393         * lib/tmpdir.c: Likewise.
7394         * lib/unicodeio.c: Likewise.
7395         * lib/unsetenv.c: Likewise.
7396         * lib/vasnprintf.c: Likewise.
7397         * lib/vasprintf.c: Likewise.
7398         * lib/wait-process.c: Likewise.
7399         * lib/xallocsa.c: Likewise.
7400         * lib/xsetenv.c: Likewise.
7401         * lib/xstriconv.c: Likewise.
7402
7403 2006-09-13  Simon Josefsson  <jas@extundo.com>
7404
7405         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
7406         that internally, suggested by Ralf Wildenhues
7407         <Ralf.Wildenhues@gmx.de>.
7408
7409 2006-09-13  Simon Josefsson  <jas@extundo.com>
7410
7411         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
7412         @LIBOBJS@.
7413         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7414
7415 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
7416
7417         * lib/_fpending.c: Include <config.h> unconditionally, since we no
7418         longer worry about uses that don't define HAVE_CONFIG_H.
7419         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
7420         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
7421         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
7422         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
7423         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
7424         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
7425         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
7426         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
7427         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
7428         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
7429         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
7430         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
7431         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
7432         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
7433         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
7434         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
7435         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
7436         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
7437         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
7438         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
7439         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
7440         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
7441         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
7442         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
7443         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
7444         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
7445         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
7446         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
7447         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
7448         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
7449         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
7450         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
7451         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
7452         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
7453         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
7454         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
7455         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
7456         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
7457         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
7458         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
7459         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
7460         Likewise.
7461
7462 2006-09-13  Eric Blake  <ebb9@byu.net>
7463
7464         * lib/getopt.c: Fix typo in last commit.
7465
7466 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
7467
7468         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
7469         dgettext.
7470
7471 2006-09-12  Jim Meyering  <jim@meyering.net>
7472
7473         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
7474         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
7475         Reported by Nelson H. F. Beebe.
7476
7477 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
7478
7479         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
7480         program_invocation_name and program_invocation_short_name are
7481         initialized.
7482         * lib/argp-namefrob.h: Move declarations of program_invocation_name
7483         and program_invocation_short_name to argp.h, so they are visible
7484         to user programs.
7485         * lib/argp.h: Likewise
7486
7487 2006-09-10  Bruno Haible  <bruno@clisp.org>
7488
7489         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
7490         m4/inttypes_h.m4, m4/uintmax_t.m4.
7491
7492 2006-09-10  Bruno Haible  <bruno@clisp.org>
7493
7494         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
7495         gl_AC_TYPE_UINTMAX_T.
7496
7497 2006-09-10  Bruno Haible  <bruno@clisp.org>
7498
7499         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
7500
7501 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
7502
7503         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
7504         convention.  Text proposed by Bruno Haible.
7505         (struct argp_option): Document the use of N_() wrappers.
7506
7507         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
7508         '\v', and translate the two parts separately, instead of feeding
7509         the whole string to gettext.  This allows to exclude
7510         '\v' from the strings visible to the translator by writing doc
7511         strings as N_("..") "\v" N_("..").
7512
7513 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
7514
7515         * config/srclist.txt: Undo latest change; the bug was fixed.
7516
7517 2006-09-09  Bruno Haible  <bruno@clisp.org>
7518
7519         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
7520         assignments if building a library without libtool.
7521         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
7522         in func_emit_lib_Makefile_am.
7523         (func_import): When building a static library libfoo.a, arrange to
7524         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
7525         (func_create_testdir): Likewise.
7526         * modules/gc (configure.ac, Makefile.am): If building statically,
7527         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
7528         * modules/iconvme (configure.ac, Makefile.am): Likewise.
7529         * modules/striconv (configure.ac, Makefile.am): Likewise.
7530         Based on a suggestion by Ralf Wildenhues.
7531
7532 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7533
7534         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
7535         Check for unistd.h too, since Autoconf doesn't assume POSIX.
7536         Also:
7537
7538         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7539         Add year_2050_test to catch glibc bug 2821
7540         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
7541
7542         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
7543         Prefer #ifdef to #if.
7544
7545         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
7546         Return from 'main' instead of calling 'exit'.
7547
7548 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7549
7550         * lib/mktime.c (guess_time_tm): Fix bug where mktime
7551         returned the maximum time_t value rather than (time_t) -1.
7552         Problem originally reported by William Bardwell
7553         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
7554
7555         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
7556         Moved to here ...
7557         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
7558         ... from here.
7559
7560 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7561
7562         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
7563         2821 is fixed.
7564
7565 2006-09-08  Jim Meyering  <jim@meyering.net>
7566
7567         Don't make generated files read-only.  That would bother too many
7568         people.  However, do retain the ability to work when targets are
7569         read-only: remove the destination and temporary files before writing
7570         them (when generated via sed or echo), or by using the -f option for
7571         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
7572         * modules/alloca-opt, modules/argz, modules/arpa_inet:
7573         * modules/byteswap, modules/configmake, modules/fcntl:
7574         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
7575         * modules/localcharset, modules/netinet_in, modules/poll:
7576         * modules/stdbool, modules/stdint, modules/sys_select:
7577         * modules/sys_socket, modules/sys_stat, modules/sysexits:
7578
7579 2006-09-08  Jim Meyering  <jim@meyering.net>
7580
7581         Avoid new build failure on FreeBSD 6.0.
7582         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
7583         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
7584         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
7585
7586 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7587
7588         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
7589
7590 2006-09-07  Jim Meyering  <jim@meyering.net>
7591
7592         Fix global typo in last change: use chmod u-w, not chmod u-x.
7593         Spotted by Paul Eggert and Bruce Korb.
7594         * modules/alloca-opt, modules/argz, modules/arpa_inet:
7595         * modules/byteswap, modules/configmake, modules/fcntl:
7596         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
7597         * modules/localcharset, modules/netinet_in, modules/poll:
7598         * modules/stdbool, modules/stdint, modules/sys_select:
7599         * modules/sys_socket, modules/sys_stat, modules/sysexits:
7600
7601 2006-09-06  Jim Meyering  <jim@meyering.net>
7602
7603         Make generated files be read-only.
7604         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
7605         Ensure that each generated file is now read-only.
7606         * modules/argz: Likewise.
7607         * modules/arpa_inet: Likewise.
7608         * modules/byteswap: Likewise.
7609         * modules/configmake: Likewise.
7610         * modules/fcntl: Likewise.
7611         * modules/fnmatch: Likewise.
7612         * modules/getopt: Likewise.
7613         * modules/glob: Likewise.
7614         * modules/inttypes: Likewise.
7615         * modules/netinet_in: Likewise.
7616         * modules/poll: Likewise.
7617         * modules/stdbool: Likewise.
7618         * modules/stdint: Likewise.
7619         * modules/sys_select: Likewise.
7620         * modules/sys_socket: Likewise.
7621         * modules/sys_stat: Likewise.
7622         * modules/sysexits: Likewise.
7623         * modules/localcharset: Same as above, but continue using temporary
7624         file named "t-$@" (why different?) rather than the "$@-t" used
7625         everywhere else.
7626
7627         * modules/sysexits (Makefile.am): Replace literal occurrences
7628         of "sysexit.h" more readable, and more consistent, "$@".
7629
7630 2006-09-06  Bruno Haible  <bruno@clisp.org>
7631
7632         * modules/striconv: New file.
7633         * modules/xstriconv: New file.
7634         * MODULES.html.sh (Internationalization functions): Add striconv,
7635         xstriconv.
7636
7637 2006-09-06  Bruno Haible  <bruno@clisp.org>
7638
7639         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
7640         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
7641         not using libtool correctly.
7642
7643 2006-09-06  Bruno Haible  <bruno@clisp.org>
7644
7645         * lib/striconv.h: New file.
7646         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
7647         iconvstring.c.
7648         * lib/xstriconv.h: New file.
7649         * lib/xstriconv.c: New file.
7650
7651 2006-09-06  Bruno Haible  <bruno@clisp.org>
7652
7653         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
7654         lib_..._LDFLAGS.
7655
7656 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7657
7658         * lib/argz_.h: Sync from Libtool.
7659
7660         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
7661                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
7662
7663         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
7664
7665 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
7666
7667         * modules/trim: New file.
7668
7669 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
7670
7671         * lib/trim.h: New file.
7672         * lib/trim.c: New file.
7673
7674 2006-09-05  Bruno Haible  <bruno@clisp.org>
7675
7676         * MODULES.html.sh (String handling): Add trim.
7677
7678 2006-09-04  Karl Berry  <karl@gnu.org>
7679
7680         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
7681         until next release.
7682
7683 2006-09-03  Bruno Haible  <bruno@clisp.org>
7684
7685         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
7686         correctly.
7687
7688 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7689
7690         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
7691         not gl_GETLOADAVG.  Omit unneeded semicolons.
7692         Problems reported by Ralf Wildenhues in
7693         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
7694         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
7695         at the end, which is the usual gnulib style.
7696
7697         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
7698         of doing all the work ourselves.
7699         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
7700         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
7701
7702 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7703
7704         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
7705         Problem reported by Ralf Wildenhues in
7706         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
7707
7708         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
7709         HAVE_STRUCT_STATFS_F_FSTYPENAME.
7710
7711 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7712
7713         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
7714         yesterday's patch by changing test -n to test -z.
7715
7716 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7717
7718         * modules/getloadavg (Files): Add m4/getloadavg.m4.
7719         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
7720         the former is now obsolescent.
7721
7722         * modules/chdir-long (Depends-on): Add fcntl.
7723
7724 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7725
7726         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
7727         obsolescent, and programs should use gnulib instead.
7728         * m4/getloadavg.m4: New file, with contents taken from Autoconf
7729         but with prefixes changed.
7730
7731 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7732
7733         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
7734         or stdbool.h, because they might not exist while configuring.
7735
7736         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
7737         Don't include unistd.h or limits.h; not needed, since chdir-long.h
7738         does that for us.
7739         (O_DIRECTORY): Remove.
7740
7741 2006-08-31  Eric Blake  <ebb9@byu.net>
7742
7743         * gnulib-tool: Don't let emacs change spaces to TAB.
7744
7745 2006-08-31  Bruno Haible  <bruno@clisp.org>
7746
7747         * gnulib-tool: When calling func_import more than once, do it in a
7748         subshell.
7749         Reported by Eric Blake <ebb9@byu.net>.
7750
7751 2006-08-31  Bruno Haible  <bruno@clisp.org>
7752
7753         * gnulib-tool (nl): Remove variable.
7754         (sed_transform_lib_file): Use more robust test for config-h module.
7755         (func_import): Fix typo in 2006-08-25 patch.
7756
7757 2006-08-31  Bruno Haible  <bruno@clisp.org>
7758
7759         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
7760         specified, augment Makefile.am variables instead of assigning them.
7761
7762 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7763
7764         Work around a bug in both the Linux and SunOS 64-bit kernels:
7765         nanosleep mishandles sleeps for longer than 2**31 seconds.
7766         Problem reported by Frank v Waveren in
7767         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
7768         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
7769         Check for nanosleep bug.
7770         (LIB_NANOSLEEP): Append clock_gettime library if needed.
7771
7772 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7773
7774         Work around a bug in both the Linux and SunOS 64-bit kernels:
7775         nanosleep mishandles sleeps for longer than 2**31 seconds.
7776         Problem reported by Frank v Waveren in
7777         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
7778         * lib/nanosleep.c (BILLION): New constant.
7779         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
7780         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
7781         implementation.
7782
7783 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7784
7785         * modules/nanosleep (Depends-on): Add gettime.
7786
7787 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7788         and Simon Josefsson  <jas@extundo.com>
7789         and Oskar Liljeblad  <oskar@osk.mine.nu>
7790
7791         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
7792         * gnulib-tool (func_import): New license type 'unmodifiable license
7793         text'.
7794         * modules/fdl: Use it.  Longer description.
7795         * module/gpl, module/lgpl: New files.
7796
7797 2006-08-30  Jim Meyering  <jim@meyering.net>
7798
7799         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
7800         shadowing the parameter.
7801
7802 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7803
7804         Sync from Libtool:
7805
7806         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7807
7808         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
7809         sharing with gnulib.  Report by Eric Blake.
7810
7811 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7812
7813         * modules/isapipe: New file.
7814         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
7815
7816 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7817
7818         * modules/configmake (Makefile.am): Add a comment, and omit
7819         the CONFIGMAKE_ prefix from generated macro names.  Suggested
7820         by Bruno Haible.
7821
7822 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7823
7824         * m4/isapipe.m4: New file.
7825
7826 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7827
7828         * lib/isapipe.c, lib/isapipe.h: New files.
7829
7830 2006-08-29  Jim Meyering  <jim@meyering.net>
7831
7832         * modules/configmake (Makefile.am): Make configmake.h depend on
7833         Makefile.  Otherwise, a stale configmake.h could hang around.
7834
7835 2006-08-29  Eric Blake  <ebb9@byu.net>
7836
7837         * lib/error.c (error_at_line, print_errno_message): Match libc, after
7838         resolution of upstream bug 3044.
7839
7840 2006-08-29  Bruno Haible  <bruno@clisp.org>
7841
7842         * modules/localcharset (Depends-on): Add configmake.
7843         (Makefile.am): Remove setting of LIBDIR through DEFS.
7844
7845 2006-08-29  Bruno Haible  <bruno@clisp.org>
7846
7847         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
7848         defined.
7849
7850 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7851
7852         * modules/fcntl: New file.
7853         * modules/chdir-safer (Depends-on): Add fcntl.
7854         * modules/fts: Likewise.
7855         * modules/mkdir-p: Likewise.
7856
7857         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
7858         This undoes the most recent change, since we're now addressing the
7859         problem in a different way.
7860
7861         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
7862         into output, since the output might be called Makefile.am even
7863         if $makefile_name is something different.
7864         (func_import): Use $makefile_am rather than
7865         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
7866         empty.
7867
7868         * modules/inttypes (Files): Add m4/inttypes-h.m4.
7869
7870 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7871
7872         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
7873         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
7874         recent change to stdint.m4, since we're now addressing the problem in a
7875         different way.
7876
7877 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7878
7879         * m4/fcntl_h.m4: New file.
7880
7881 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7882
7883         * lib/fcntl_.h: New file.
7884         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
7885         the fcntl module.
7886         * lib/dirchownmod.c: Likewise.
7887         * lib/fts.c: Likewise.
7888
7889         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
7890         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
7891         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
7892         just before including <inttypes.h>, to avoid circular inclusion.
7893
7894 2006-08-28  Jim Meyering  <jim@meyering.net>
7895
7896         * doc/visibility.texi: Actually read and correct the grammar of the
7897         sentence affected by yesterday's change.
7898
7899 2006-08-28  Eric Blake  <ebb9@byu.net>
7900
7901         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
7902         needs wrapper.
7903
7904 2006-08-28  Eric Blake  <ebb9@byu.net>
7905
7906         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
7907
7908 2006-08-28  Eric Blake  <ebb9@byu.net>
7909
7910         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
7911
7912 2006-08-28  Bruno Haible  <bruno@clisp.org>
7913
7914         * modules/c-strstr: New file, from GNU gettext.
7915         * MODULES.html.sh (String handling): Add c-strstr.
7916
7917 2006-08-28  Bruno Haible  <bruno@clisp.org>
7918
7919         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
7920         macros.
7921         Reported by Eric Blake.
7922
7923 2006-08-28  Bruno Haible  <bruno@clisp.org>
7924
7925         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
7926         (VASNPRINTF): Return a string of length > INT_MAX without failing.
7927         * lib/vasprintf.c: Include errno.h, limits.h.
7928         (EOVERFLOW): New fallback definition.
7929         (vasprintf): Test here whether the string length is > INT_MAX.
7930         * lib/vsnprintf.c: Include errno.h, limits.h.
7931         (EOVERFLOW): New fallback definition.
7932         (vsnprintf): Fix bug when generated string was too long for the buffer.
7933         Test here whether the string length is > INT_MAX.
7934
7935 2006-08-28  Bruno Haible  <bruno@clisp.org>
7936
7937         * lib/inttypes_.h (SCNX*): Remove definitions.
7938         Reported by Eric Blake.
7939
7940 2006-08-28  Bruno Haible  <bruno@clisp.org>
7941
7942         * lib/c-strstr.h: New file, from GNU gettext.
7943         * lib/c-strstr.c: New file, from GNU gettext.
7944
7945 2006-08-28  Bruno Haible  <bruno@clisp.org>
7946
7947         * gnulib-tool: Reorder some statements.
7948
7949 2006-08-28  Bruno Haible  <bruno@clisp.org>
7950
7951         * gnulib-tool: New option --makefile-name.
7952         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
7953         $makefile_name.
7954         (func_import): Write $makefile_name to the cache file, and read it from
7955         there unless explicitly specified. Use $makefile_name as file name
7956         instead of Makefile.am. Adjust the recommendations accordingly.
7957
7958 2006-08-28  Bruno Haible  <bruno@clisp.org>
7959
7960         * gnulib-tool (func_verify_module): Check against misapplying patch.
7961
7962 2006-08-28  Bruno Haible  <bruno@clisp.org>
7963
7964         * gnulib-tool (func_relativize, func_relconcat): New functions.
7965         Give an error if --local-dir is given with --update.
7966         Remove trailing slashes from $local_gnulib_dir.
7967         (func_import): Store the relativized $local_gnulib_dir in
7968         gnulib-cache.m4, and read it from there if not specified explicitly.
7969
7970 2006-08-28  Bruno Haible  <bruno@clisp.org>
7971
7972         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
7973         is the current directory. Respect also $local_gnulib_dir.
7974
7975 2006-08-28  Bruno Haible  <bruno@clisp.org>
7976             Simon Josefsson  <jas@extundo.com>
7977
7978         BeOS portability.
7979         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
7980
7981 2006-08-27  Jim Meyering  <jim@meyering.net>
7982
7983         * doc/visibility.texi: Remove duplicate word: "pointer".
7984
7985 2006-08-26  Bruno Haible  <bruno@clisp.org>
7986
7987         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
7988         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
7989         (Makefile.am): Create inttypes.h from inttypes_.h.
7990         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
7991
7992         * modules/imaxabs: New file.
7993
7994         * modules/imaxdiv: New file.
7995
7996 2006-08-26  Bruno Haible  <bruno@clisp.org>
7997
7998         * m4/inttypes.m4: New file.
7999         * m4/_inttypes_h.m4: Remove file.
8000         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
8001         PRI_MACROS_BROKEN.
8002         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
8003
8004         * m4/imaxabs.m4: New file.
8005
8006         * m4/imaxdiv.m4: New file.
8007
8008 2006-08-26  Bruno Haible  <bruno@clisp.org>
8009
8010         * lib/inttypes_.h: New file.
8011         * lib/inttypes.h: Remove file.
8012         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
8013
8014         * lib/imaxabs.c: New file.
8015
8016         * lib/imaxdiv.c: New file.
8017
8018 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8019
8020         New config-h module, so that "make" output needn't be cluttered
8021         by -DHAVE_CONFIG_H.
8022         * MODULES.html.sh (Support for building libraries and executables):
8023         Add config-h.
8024         * modules/config-h: New file.
8025         * gnulib-tool (nl, sed_transform_lib_file): New vars.
8026         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
8027         the config-h module is used.
8028
8029         New configmake module, so that "make" output needn't be cluttered
8030         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
8031         * MODULES.html.sh (Support for building libraries and executables):
8032         Add configmake.
8033         * modules/configmake: New file.
8034
8035 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8036
8037         * m4/config-h.m4: New file.
8038
8039 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8040
8041         * config/srclist.txt: Add elisp-comp.
8042
8043 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8044
8045         * MODULES.html.sh (Support for building libraries and executables):
8046         Add elisp-comp.
8047         * build-aux/elisp-comp: New file.
8048         * modules/elisp-comp: New file.
8049
8050 2006-08-24  Bruno Haible  <bruno@clisp.org>
8051
8052         * gnulib-tool (func_create_testdir): Use non-default values of
8053         sourcebase and m4base.
8054
8055 2006-08-24  Bruno Haible  <bruno@clisp.org>
8056
8057         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
8058         HTML structure.
8059
8060 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
8061
8062         * modules/openat (Depends-on): Add lchown.
8063
8064 2006-08-23  Bruno Haible  <bruno@clisp.org>
8065
8066         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
8067         of gl_LOCK_EARLY instead of gl_LOCK.
8068
8069 2006-08-23  Bruno Haible  <bruno@clisp.org>
8070
8071         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
8072         on OSF/1 to no.
8073         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
8074
8075 2006-08-23  Bruno Haible  <bruno@clisp.org>
8076
8077         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
8078         as unusable.
8079
8080         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
8081         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
8082         (gl_LOCK): New macro.
8083
8084 2006-08-22  Simon Josefsson  <jas@extundo.com>
8085
8086         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
8087         to md5 module.
8088
8089 2006-08-22  Simon Josefsson  <jas@extundo.com>
8090
8091         * MODULES.html.sh: Add "Support for maintaining and release
8092         projects".
8093
8094         * build-aux/gnupload: New file, from coreutils.
8095
8096 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8097
8098         Avoid the need for AC_LIBSOURCES in m4 macros.
8099         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
8100         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
8101         * modules/check-version (EXTRA_DIST): Add check-version.h.
8102         * modules/crc (EXTRA_DIST): Add crc.h.
8103         * modules/des (EXTRA_DIST): Add des.h.
8104         * modules/gc (EXTRA_DIST): Add gc.h.
8105         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
8106         * modules/getline (EXTRA_DIST): Add getline.h.
8107         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
8108         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
8109         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
8110         * modules/md2 (EXTRA_DIST): Add md2.h.
8111         * modules/md4 (EXTRA_DIST): Add md4.h.
8112         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
8113         * modules/read-file (EXTRA_DIST): Add read-file.h.
8114         * modules/readline (EXTRA_DIST): Add readline.h.
8115         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
8116         rijndael-api-fst.h.
8117
8118 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8119
8120         * m4/rijndael.m4 (gl_ARCFOUR):
8121         * m4/arctwo.m4 (gl_ARCTWO):
8122         * m4/check-version.m4 (gl_CHECK_VERSION):
8123         * m4/crc.m4 (gl_CRC):
8124         * m4/des.m4 (gl_DES):
8125         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
8126         * m4/gc.m4 (gl_GC):
8127         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
8128         * m4/getline.m4 (gl_FUNC_GETLINE):
8129         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
8130         * m4/hmac-md5.m4 (gl_HMAC_MD5):
8131         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
8132         * m4/md2.m4 (gl_MD2):
8133         * m4/md4.m4 (gl_MD4):
8134         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
8135         * m4/read-file.m4 (gl_FUNC_READ_FILE):
8136         * m4/readline.m4 (gl_FUNC_READLINE):
8137         * m4/rijndael.m4 (gl_RIJNDAEL):
8138         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
8139         to get the necessary .h files and whatnot.
8140
8141 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8142
8143         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
8144         gnulib rather than the other way around.
8145         * config/srclistvars.sh (COREUTILS): Remove.
8146
8147 2006-08-22  Jim Meyering  <jim@meyering.net>
8148
8149         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
8150
8151         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
8152
8153 2006-08-22  Eric Blake  <ebb9@byu.net>
8154
8155         * modules/regexprops-generic: New file.
8156         * MODULES.html.sh (Support for building documentation): List it.
8157
8158 2006-08-22  Eric Blake  <ebb9@byu.net>
8159
8160         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
8161         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
8162         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
8163         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
8164
8165 2006-08-22  Bruno Haible  <bruno@clisp.org>
8166
8167         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
8168         and lib_LTLIBRARIES like the other lib_* variables.
8169
8170 2006-08-22  Bruno Haible  <bruno@clisp.org>
8171
8172         * build-aux/x-to-1.in: New file, from GNU gettext.
8173
8174 2006-08-22  Bruno Haible  <bruno@clisp.org>
8175
8176         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
8177         <utmpx.h> exists.
8178
8179 2006-08-22  Bruno Haible  <bruno@clisp.org>
8180
8181         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
8182         <utmpx.h> exists.
8183
8184 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8185
8186         BeOS portability.
8187         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
8188         exist.
8189         Problem reported by Bruno Haible.
8190
8191 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8192
8193         Avoid the need for AC_LIBSOURCES in m4 macros.
8194         * modules/acl (EXTRA_DIST): Add acl.h.
8195         * modules/argmatch (Files): Add m4/argmatch.m4.
8196         (configure.ac): Add gl_ARGMATCH.
8197         (EXTRA_DIST): Renamed from lib_SOURCES, for
8198         consistency with the other modules.  Remove argmatch.c.
8199         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
8200         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
8201         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
8202         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
8203         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
8204         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
8205         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
8206         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
8207         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
8208         * modules/closeout (EXTRA_DIST): Add closeout.h.
8209         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
8210         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
8211         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
8212         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
8213         dirname.h; remove basename.c and stripslash.c.
8214         * modules/exclude (EXTRA_DIST): Add exclude.h.
8215         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
8216         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
8217         * modules/file-type (EXTRA_DIST): Add file-type.h.
8218         * modules/filemode (EXTRA_DIST): Add filemode.h.
8219         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
8220         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
8221         * modules/fpending (EXTRA_DIST): Add __fpending.h.
8222         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
8223         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
8224         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
8225         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
8226         * modules/getdate (EXTRA_DIST): Add getdate.c.
8227         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
8228         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
8229         * modules/getpass (EXTRA_DIST): Add getpass.h.
8230         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
8231         * modules/group-member (EXTRA_DIST): Add group-member.h.
8232         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
8233         * modules/hash (EXTRA_DIST): Add hash.h.
8234         * modules/human (EXTRA_DIST): Add human.h.
8235         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
8236         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
8237         * modules/lchown (EXTRA_DIST): Add lchown.h.
8238         * modules/long-options (EXTRA_DIST): Add long-options.h.
8239         * modules/lstat (EXTRA_DIST): Add lstat.h.
8240         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
8241         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
8242         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
8243         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
8244         * modules/memxor (EXTRA_DIST): Add memxor.h.
8245         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
8246         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
8247         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
8248         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
8249         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
8250         * modules/physmem (EXTRA_DIST): Add physmem.h.
8251         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
8252         * modules/posixver (EXTRA_DIST): Add posixver.h.
8253         * modules/quote (EXTRA_DIST): Add quote.h.
8254         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
8255         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
8256         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
8257         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
8258         regex_internal.h regexec.c.
8259         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
8260         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
8261         * modules/same (EXTRA_DIST): Add same.h.
8262         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
8263         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
8264         * modules/savedir (EXTRA_DIST): Add savedir.h.
8265         * modules/sha1 (EXTRA_DIST): Add sha1.h.
8266         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
8267         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
8268         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
8269         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
8270         * modules/strdup (EXTRA_DIST): Add strdup.h.
8271         * modules/strftime (EXTRA_DIST): Add strftime.h.
8272         * modules/strndup (EXTRA_DIST): Add strndup.h.
8273         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
8274         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
8275         * modules/time_r (EXTRA_DIST): Add time_r.h.
8276         * modules/timespec (EXTRA_DIST): Add timespec.h.
8277         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
8278         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
8279         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
8280         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
8281         * modules/userspec (EXTRA_DIST): Add userspec.h.
8282         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
8283         * modules/utimens (EXTRA_DIST): Add utimens.h.
8284         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
8285         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
8286         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
8287         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
8288         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
8289         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
8290         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
8291         * modules/yesno (EXTRA_DIST): Add yesno.h.
8292
8293 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8294
8295         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
8296
8297         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
8298         * m4/dev-ino.m4, same-inode.m4: Remove.
8299
8300         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
8301         * m4/acl.m4 (AC_FUNC_ACL):
8302         * m4/backupfile.m4 (gl_BACKUPFILE):
8303         * m4/c-strtod.m4 (gl_C99_STRTOLD):
8304         * m4/canon-host.m4 (gl_CANON_HOST):
8305         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
8306         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
8307         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
8308         * m4/cloexec.m4 (gl_CLOEXEC):
8309         * m4/close-stream.m4 (gl_CLOSE_STREAM):
8310         * m4/closeout.m4 (gl_CLOSEOUT):
8311         * m4/dirfd.m4 (gl_FUNC_DIRFD):
8312         * m4/dirname.m4 (gl_DIRNAME):
8313         * m4/exclude.m4 (gl_EXCLUDE):
8314         * m4/exitfail.m4 (gl_EXITFAIL):
8315         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
8316         * m4/file-type.m4 (gl_FILE_TYPE):
8317         * m4/filemode.m4 (gl_FILEMODE):
8318         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
8319         * m4/fpending.m4 (gl_FUNC_FPENDING):
8320         * m4/fprintftime.m4 (gl_FPRINTFTIME):
8321         * m4/fts.m4 (gl_FUNC_FTS):
8322         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
8323         * m4/getdate.m4 (gl_GETDATE):
8324         * m4/gethrxtime.m4 (gl_GETHRXTIME):
8325         * m4/getpagesize.m4 (gl_GETPAGESIZE):
8326         * m4/getpass.m4 (gl_FUNC_GETPASS):
8327         * m4/gettime.m4 (gl_GETTIME):
8328         * m4/getugroups.m4 (gl_GETUGROUPS):
8329         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
8330         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
8331         * m4/hard-locale.m4 (gl_HARD_LOCALE):
8332         * m4/hash.m4 (gl_HASH):
8333         * m4/idcache.m4 (gl_IDCACHE):
8334         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
8335         * m4/lchown.m4 (gl_FUNC_LCHOWN):
8336         * m4/long-options.m4 (gl_LONG_OPTIONS):
8337         * m4/lstat.m4 (gl_FUNC_LSTAT):
8338         * m4/md5.m4 (gl_MD5):
8339         * m4/memcasecmp.m4 (gl_MEMCASECMP):
8340         * m4/memcoll.m4 (gl_MEMCOLL):
8341         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
8342         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
8343         * m4/memxor.m4 (gl_MEMXOR):
8344         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
8345         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
8346         * m4/modechange.m4 (gl_MODECHANGE):
8347         * m4/mountlist.m4 (gl_MOUNTLIST):
8348         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
8349         * m4/openat.m4 (gl_FUNC_OPENAT):
8350         * m4/pathmax.m4 (gl_PATHMAX):
8351         * m4/physmem.m4 (gl_PHYSMEM):
8352         * m4/posixtm.m4 (gl_POSIXTM):
8353         * m4/posixver.m4 (gl_POSIXVER):
8354         * m4/quote.m4 (gl_QUOTE):
8355         * m4/quotearg.m4 (gl_QUOTEARG):
8356         * m4/readtokens.m4 (gl_READTOKENS):
8357         * m4/readutmp.m4 (gl_READUTMP):
8358         * m4/regex.m4 (gl_REGEX):
8359         * m4/safe-read.m4 (gl_SAFE_READ):
8360         * m4/safe-write.m4 (gl_SAFE_WRITE):
8361         * m4/same.m4 (gl_SAME):
8362         * m4/save-cwd.m4 (gl_SAVE_CWD):
8363         * m4/savedir.m4 (gl_SAVEDIR):
8364         * m4/settime.m4 (gl_SETTIME):
8365         * m4/sha1.m4 (gl_SHA1):
8366         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
8367         * m4/stat-macros.m4 (gl_STAT_MACROS):
8368         * m4/stat-time.m4 (gl_STAT_TIME):
8369         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
8370         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
8371         * m4/strdup.m4 (gl_FUNC_STRDUP):
8372         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
8373         * m4/strndup.m4 (gl_FUNC_STRNDUP):
8374         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
8375         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
8376         * m4/time_r.m4 (gl_TIME_R):
8377         * m4/timespec.m4 (gl_TIMESPEC):
8378         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
8379         * m4/unlinkdir.m4 (gl_UNLINKDIR):
8380         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
8381         * m4/userspec.m4 (gl_USERSPEC):
8382         * m4/utimecmp.m4 (gl_UTIMECMP):
8383         * m4/utimens.m4 (gl_UTIMENS):
8384         * m4/xalloc.m4 (gl_XALLOC):
8385         * m4/xgetcwd.m4 (gl_XGETCWD):
8386         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
8387         * m4/xreadlink.m4 (gl_XREADLINK):
8388         * m4/xstrtod.m4 (gl_XSTRTOD):
8389         * m4/yesno.m4 (gl_YESNO):
8390         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
8391         to get the necessary .h files and whatnot.
8392
8393 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
8394             Bruno Haible  <bruno@clisp.org>
8395
8396         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
8397         /bin/sh understanding of '!' conditional negation.
8398
8399 2006-08-21  Jim Meyering  <jim@meyering.net>
8400
8401         * modules/openat (Depends-on): Really alphabetize.
8402
8403         * modules/acl (Depends-on): Add error and quote.
8404
8405         * check-module (find_included_lib_files): Add at-func.c to the
8406         ok-to-include-more-than-once white list.
8407
8408         * modules/openat (Depends-on): Add lstat.  Alphabetize.
8409
8410 2006-08-21  Bruno Haible  <bruno@clisp.org>
8411
8412         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8413         Emit a pkgdata_DATA variable only if some snippets add contents to it.
8414         Reported by Martin Lambers <marlam@marlam.de>.
8415
8416 2006-08-21  Bruno Haible  <bruno@clisp.org>
8417
8418         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
8419         specify an installation location, don't emit a noinst_LIBRARIES or
8420         noinst_LTLIBRARIES assignment.
8421
8422 2006-08-21  Bruno Haible  <bruno@clisp.org>
8423
8424         BeOS portability.
8425         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
8426         BeOS has mbrtowc() but no <wctype.h>.
8427
8428 2006-08-21  Bruno Haible  <bruno@clisp.org>
8429
8430         BeOS portability.
8431         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
8432         exist.
8433
8434 2006-08-21  Bruno Haible  <bruno@clisp.org>
8435
8436         BeOS portability.
8437         * lib/mbchar.h: Include <wctype.h> only if it exists.
8438
8439 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8440
8441         Remove files that are no longer needed by their respective modules.
8442         * m4/obstack.m4: Remove.
8443         * m4/strerror_r.m4: Remove.
8444         * m4/uint32_t.m4: Remove.
8445         * m4/uintptr_t.m4: Remove.
8446         * m4/ullong_max.m4: Remove.
8447         * m4/xstrtoimax.m4: Remove.
8448         * m4/xstrtoumax.m4: Remove.
8449
8450         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
8451         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
8452         dependencies now capture this.
8453
8454         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
8455         Do not use AC_LIBSOURCES, since gnulib modules now do this.
8456         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
8457         * m4/human.m4 (gl_HUMAN): Likewise.
8458         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
8459         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
8460
8461         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
8462
8463         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
8464         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
8465         stdint.
8466         * m4/human.m4 (gl_HUMAN): Likewise.
8467         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
8468         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
8469         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
8470         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
8471         * m4/xstrtol (gl_XSTRTOL): Likewise.
8472
8473         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
8474         AC_TYPE_LONG_LONG_INT.
8475         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
8476         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
8477         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
8478         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
8479
8480         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
8481         on stdbool.
8482
8483         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
8484         (gl_PREREQ_XSTRTOUL): Remove.
8485
8486         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
8487
8488         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
8489         mode.
8490
8491 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8492
8493         Add and change modules to make it easier for coreutils to use
8494         gnulib-tool.
8495         * modules/backupfile (Files): Remove m4/d-ino.m4.
8496         (Depends-on): Add d-ino.
8497         * modules/cycle-check (Depends-on): Add stdint.
8498         (lib_SOURCES): Add cycle-check.h.
8499         * modules/d-ino: New module.
8500         * modules/d-type: New module.
8501         * modules/error (Files): Remove m4/strerror_r.m4.
8502         * modules/filemode (Files): Add m4/st_dm_mode.m4.
8503         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
8504         m4/inttypes_h.m4, m4/uintmax_t.m4.
8505         (Depends-on): Add stdint.
8506         (lib_SOURCES): Add fsusage.h.
8507         * modules/getcwd (Files): Remove d-ino.m4.
8508         (Depends-on): Add d-ino.
8509         * modules/getndelim2 (Depends-on): Add stdint.
8510         * modules/glob (Files): Remove m4/d-type.m4.
8511         (Depends-on): Add d-type.
8512         * modules/host-os: New module.
8513         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
8514         m4/inttypes_h.m4, m4/uintmax_t.m4.
8515         * Depends-on: Add stdint.
8516         (lib_SOURCES): Add human.h.
8517         * modules/inttostr (Files): Remove m4/intmax_t.m4,
8518         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
8519         m4/uintmax_t.m4, m4/ulonglong.m4.
8520         (Depends-on): Add stdint.
8521         (EXTRA_DIST): Add inttostr.h.
8522         * modules/lchmod: New module.
8523         * modules/link-follow: New module.
8524         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
8525         (Depends-on): Add lchmod.
8526         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
8527         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
8528         (Depends-on): Add stdint.
8529         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
8530         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
8531         (Depends-on): Add stdint.
8532         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
8533         * modules/perl: New module.
8534         * modules/regex (Depends-on): Add stdint.
8535         * modules/rmdir-errno: New module.
8536         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
8537         m4/intmax_t.m4.
8538         (Depends-on): Add stdint.
8539         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
8540         m4/uintmax_t.m4.
8541         (Depends-on): Add stdint.
8542         * modules/unlink-busy: New module.
8543         * modules/utimecmp (Depends-on): Add stdint.
8544         * modules/uptime: New module.
8545         * modules/winsz-ioctl: New module.
8546         * modules/winsz-termios: New module.
8547         * modules/xnanosleep (Depends-on): Add nanosleep.
8548         * modules/ullong_max: Remove.
8549         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
8550         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
8551         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
8552         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
8553         (Depends-on): Add inttypes.
8554         (lib_SOURCES): Add xstrtol.h.
8555         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
8556         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
8557         * MODULES.html.sh: Move 'assert' into the assert section.
8558         Move 'dummy' into the linking section.
8559         Remove ullong_max.
8560         Add section for compatibility checks for POSIX:2001 functions,
8561         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
8562         winsz-ioctl, and winsz-termios into it.
8563         Add lchmod.
8564         Add top-level Misc section and put host-os, perl, and uptime
8565         into it.
8566
8567 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8568
8569         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
8570         now assume the stdint module.  Do not include inttypes.h.
8571         * lib/fsusage.h: Likewise.
8572         * lib/getndelim2.c: Likewise.
8573         * lib/human.h: Likewise.
8574         * lib/inttostr.h: Likewise.
8575         * lib/obstack.c: Likewise.
8576         * lib/regex_internal.h: Likewise.
8577         * lib/tempname.c: Likewise.
8578         * lib/utimecmp.c: Likewise.
8579         * lib/xstrtol.h: Likewise.
8580
8581         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
8582
8583         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
8584         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
8585         * lib/xtime.h: Likewise.
8586
8587 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8588
8589         * modules/openat (Files): Add lib/fchmodat.c.
8590         Fixes problem reported by Jay Youngman.
8591
8592 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8593
8594         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
8595         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
8596
8597 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
8598             Bruno Haible  <bruno@clisp.org>
8599
8600         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
8601         and is a script that invokes bison. Tighten the code. Add comments.
8602
8603 2006-08-18  Jim Meyering  <jim@meyering.net>
8604
8605         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
8606         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
8607         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
8608         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
8609
8610 2006-08-18  Bruno Haible  <bruno@clisp.org>
8611
8612         * modules/bison-i18n: New file.
8613         * MODULES.html.sh (Internationalization functions): Add it.
8614
8615 2006-08-18  Bruno Haible  <bruno@clisp.org>
8616
8617         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
8618         sys/statvfs.h. When getmntinfo was found, check its declaration and
8619         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
8620
8621 2006-08-18  Bruno Haible  <bruno@clisp.org>
8622
8623         * m4/bison-i18n.m4: New file, from bison.
8624
8625 2006-08-18  Bruno Haible  <bruno@clisp.org>
8626
8627         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
8628         (ME_DUMMY): Treat "kernfs" as a dummy.
8629         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
8630
8631 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
8632
8633         Update from coreutils.
8634
8635         2006-08-15  Jim Meyering  <jim@meyering.net>
8636
8637         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
8638
8639         2006-01-17  Jim Meyering  <jim@meyering.net>
8640
8641         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
8642
8643         2006-01-11  Jim Meyering  <jim@meyering.net>
8644
8645         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
8646         Check for the lchmod function.
8647
8648 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
8649
8650         Update from coreutils.
8651
8652         * lib/__fpending.h: Add copyright notice.
8653         * lib/fprintftime.h: Likewise.
8654         * lib/savedir.c: Use (C) in copyright notice.
8655         * lib/savedir.h: Likewise.
8656
8657         2006-08-15  Jim Meyering  <jim@meyering.net>
8658
8659         * lib/at-func.c: New file, with the logic of all emulated at-functions.
8660         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
8661         in support of the EXPECTED_ERRNO macro.
8662         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
8663         definitions.  Instead, define the appropriate symbols and include
8664         "at-func.c".
8665         * lib/mkdirat.c (mkdirat): Likewise.
8666         * lib/fchmodat.c (fchmodat): Likewise.
8667         (ENOSYS): Remove definition.
8668         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
8669         it.  Don't include "unistd--.h" -- it wasn't ever used.
8670
8671         2006-01-17  Jim Meyering  <jim@meyering.net>
8672
8673         Rewrite fts.c not to change the current working directory,
8674         by using openat, fstatat, fdopendir, etc..
8675
8676         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
8677         (HAVE_OPENAT_SUPPORT): Define.
8678         [_LIBC] (fchdir): Don't undef or define; no longer used.
8679         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
8680         Now, this `function' always succeeds, and consumes its file descriptor
8681         parameter -- so callers must not close such FDs.  Update callers.
8682         (diropen_fd, opendirat, cwd_advance_fd): New functions.
8683         (diropen): Add parameter, SP.  Adjust all callers.
8684         Implement using diropen_fd, rather than open.
8685         (fts_open): Initialize new member, fts_cwd_fd.
8686         Remove fts_rft-setting code.
8687         (fts_close): Close fts_cwd_fd, if necessary.
8688         (__opendir2): Define in terms of opendir or opendirat,
8689         depending on whether the FST_NOCHDIR flag is set.
8690         (fts_build): Since fts_safe_changedir consumes its FD, and since
8691         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
8692         and close the dup'd file descriptor upon failure.
8693         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
8694         (fts_safe_changedir): Tweak semantics to reflect that this function
8695         now calls cwd_advance_fd and hence consumes its FD argument.
8696         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
8697         [struct FTS] (fts_rft): Remove now-unused member.
8698         [struct FTS] (fts_cycle.state): Improve comment.
8699
8700         * lib/openat.c (openat_needs_fchdir): New function.
8701         * lib/openat.h (openat_needs_fchdir): Declare it.
8702
8703 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
8704
8705         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
8706         Problem and fix reported by Pádraig Brady in
8707         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
8708
8709 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8710
8711         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
8712
8713 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8714
8715         * lib/memcoll.c (memcoll): Optimize for the common case where the
8716         arguments are bytewise equal.
8717
8718 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8719
8720         * doc/regexprops-generic.texi: Add a copyright notice.
8721
8722 2006-08-15  Bruno Haible  <bruno@clisp.org>
8723
8724         * modules/tmpdir (License): Change to LGPL.
8725
8726 2006-08-15  Bruno Haible  <bruno@clisp.org>
8727
8728         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
8729         module.
8730
8731 2006-08-14  Simon Josefsson  <jas@extundo.com>
8732
8733         * config/srclist.txt: Add gnupload.
8734
8735 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8736
8737         Change copyright notice from LGPL 2 to GPL 2, since that's the
8738         standard form used in the gnulib repository.
8739         * tests/test-lock.c: Likewise.
8740         * tests/test-stdint.c: Likewise.
8741         * tests/test-tls.c: Likewise.
8742
8743         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
8744         prelude-manager.  User shorter URLs for GNU projects, without '?'.
8745         Add copyright notice.
8746
8747         * check-module: Add copyright notice.  Output a copyright
8748         notice if "--version" is specified.
8749         * modules/COPYING: New file.
8750         * tests/test-getaddrinfo.c: Add copyright notice.
8751         * tests/test-verify.c: Likewise.
8752
8753 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8754
8755         Change copyright notice from LGPL 2 to GPL 2, since that's the
8756         standard form used in the gnulib repository.
8757         * lib/lock.c: LGPL -> GPL.
8758         * lib/lock.h: Likewise.
8759         * lib/strnlen1.c: Likewise.
8760         * lib/strnlen1.h: Likewise.
8761         * lib/tls.c: Likewise.
8762         * lib/tls.h: Likewise.
8763         * lib/tmpdir.c: Likewise.
8764
8765         * lib/TODO: Remove; this belongs only in coreutils.
8766
8767 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8768
8769         Add copyright notices to long-enough files that lack them, since
8770         otherwise the files aren't clearly free.  Use the same notice that
8771         getdate.texi already uses.
8772         * doc/alloca-opt.texi: Add copyright notice.
8773         * doc/alloca.texi: Likewise.
8774         * doc/ctime.texi: Likewise.
8775         * doc/functions.texi: Likewise.
8776         * doc/gcd.texi: Likewise.
8777         * doc/gnulib-tool.texi: Likewise.
8778         * doc/inet_ntoa.texi: Likewise.
8779         * doc/visibility.texi: Likewise.
8780
8781         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
8782         * doc/quote.texi: Add copyright notice.
8783
8784         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
8785         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
8786         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
8787         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
8788         is now obsolete, and give a pointer to the Sun list.
8789         Add copyright notice.
8790
8791 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8792
8793         * config/srclistvars.sh: Add copyright notice.
8794
8795 2006-08-14  Eric Blake  <ebb9@byu.net>
8796
8797         Import the following change from libc:
8798
8799         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
8800
8801         Upstream bug 2997.
8802         * lib/misc/error.c: Add space between program name and message if file
8803         name is missing.
8804
8805 2006-08-12  Karl Berry  <karl@gnu.org>
8806
8807         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
8808         remove, these originate in gnulib now.
8809
8810 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8811
8812         * doc/Makefile (standards.info standards.html standards.dvi):
8813         Also depend on make-stds.texi.
8814
8815 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
8816
8817         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
8818         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
8819
8820         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
8821         in wchar_t.  Problem reported by Eric Blake.
8822
8823         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
8824         LEN is smaller than SIZE.  Suggested by Bruno Haible.
8825         Also, help the compiler to keep LEN in a register.
8826
8827 2006-08-11  Eric Blake  <ebb9@byu.net>
8828
8829         * users.txt: Sort.  Add tar.
8830
8831 2006-08-11  Bruno Haible  <bruno@clisp.org>
8832
8833         * users.txt: New file.
8834
8835 2006-08-11  Bruno Haible  <bruno@clisp.org>
8836
8837         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
8838         before <wchar.h>. Needed for OSF/1 and BSD/OS.
8839
8840 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
8841
8842         * modules/snprintf (Depends-on): Remove minmax.
8843         (Maintainer): Add self and Bruno.
8844
8845 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
8846
8847         * lib/.cppi-disable: Add snprintf.h, socket_.h.
8848         * lib/snprintf.c: Include <errno.h> and <limits.h>.
8849         (EOVERFLOW): Define if the system does not.
8850         Do not include "minmax.h"; it wasn't used.
8851         (snprintf): Don't assume size_t promotes to an unsigned type.
8852         Fix bug when generated string was too long for the buffer: the
8853         buffer's contents are supposed to be the initial prefix of the
8854         output.  Don't assume vasnprintf returns EOVERFLOW if the size
8855         exceeds INT_MAX; do the check ourselves.
8856
8857         Import the following changes from libc:
8858
8859         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
8860
8861         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
8862         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
8863         set wc to the byte which couldn't be converted.
8864         (re_string_reconstruct): Don't clear valid_raw_len before calling
8865         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
8866         tip_context using re_string_context_at.
8867
8868         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
8869
8870         * lib/posix/regex.h: g++ still cannot handled [restrict].
8871
8872         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
8873
8874         * lib/posix/regex.h: Remove special handling for VMS.
8875
8876 2006-08-10  Jim Meyering  <jim@meyering.net>
8877
8878         * modules/same-inode: New module.
8879         * modules/dev-ino: New module.
8880         * modules/cycle-check: Depend on these modules, rather than simply
8881         including their .h files.
8882         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
8883         required via m4/cycle-check.m4.
8884         * modules/same: Depend on new same-inode module, rather than
8885         including same-inode.h.
8886         * modules/chdir-safer: New file.
8887
8888         * modules/chown (Depends-on): Add stat-macros.
8889
8890 2006-08-10  Jim Meyering  <jim@meyering.net>
8891
8892         * m4/cycle-check.m4: New file.
8893         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
8894         * m4/dev-ino.m4, m4/same-inode.m4: New files.
8895
8896 2006-08-10  Eric Blake  <ebb9@byu.net>
8897
8898         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
8899         in from original proposal.
8900
8901 2006-08-10  Eric Blake  <ebb9@byu.net>
8902         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
8903
8904         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
8905         namespace.
8906
8907 2006-08-10  Bruno Haible  <bruno@clisp.org>
8908
8909         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
8910         as well.
8911
8912 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8913
8914         Sync from coreutils.
8915
8916         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
8917
8918         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
8919         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
8920
8921 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8922
8923         * modules/restrict: Remove; no longer needed now that we assume
8924         Autoconf 2.59 or later.
8925         * MODULES.html.sh: Remove 'restrict'.
8926         * modules/argp (Depends-on): Remove 'restrict'.
8927         * modules/base64 (Depends-on): Likewise.
8928         * modules/gc (Depends-on): Likewise.
8929         * modules/getaddrinfo (Depends-on): Likewise.
8930         * modules/glob (Depends-on): Likewise.
8931         * modules/inet_ntop (Depends-on): Likewise.
8932         * modules/inet_pton (Depends-on): Likewise.
8933         * modules/memxor (Depends-on): Likewise.
8934         * modules/regex (Depends-on): Likewise.
8935         * modules/strtok_r (Depends-on): Likewise.
8936         * modules/time_r (Depends-on): Likewise.
8937
8938 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8939
8940         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
8941         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
8942         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
8943         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
8944         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
8945         * m4/memxor.m4 (gl_MEMXOR): Likewise.
8946         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
8947         gl_C_RESTRICT replaced by AC_C_RESTRICT.
8948
8949         Merge from coreutils.
8950         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
8951         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
8952         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
8953         * m4/time_r.m4 (gl_TIME_R): Likewise.
8954
8955 2006-08-09  Karl Berry  <karl@gnu.org>
8956
8957         * config/srclist.txt: no more gettext-tools, per Bruno.
8958
8959 2006-08-08  Eric Blake  <ebb9@byu.net>
8960
8961         * modules/verror: New module.
8962         * MODULES.html.sh: Document it.
8963
8964 2006-08-08  Eric Blake  <ebb9@byu.net>
8965
8966         * lib/verror.h, lib/verror.c: New files.
8967
8968 2006-08-08  Eric Blake  <ebb9@byu.net>
8969
8970         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
8971         verror_at_line output complies with GNU Coding Standards even when
8972         file is NULL.
8973
8974 2006-08-07  Bruno Haible  <bruno@clisp.org>
8975
8976         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
8977         versions of AIX.
8978         Reported by Ralf Wildenhues.
8979
8980 2006-08-07  Bruno Haible  <bruno@clisp.org>
8981
8982         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
8983         in an AC_DEFUN. Needed so that the autoconf snippets can use
8984         AC_REQUIRE.
8985
8986 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8987
8988         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8989         Initialize pkgdata_DATA.
8990         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
8991         overriding it.
8992
8993 2006-08-06  Eric Blake  <ebb9@byu.net>
8994
8995         * lib/error.h: Fold in some upstream changes from glibc.
8996         * lib/error.c: Likewise.
8997
8998 2006-08-04  Bruno Haible  <bruno@clisp.org>
8999
9000         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9001         Make the mostlyclean-local rule depend on mostlyclean-generic.
9002         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
9003
9004 2006-07-31  Bruno Haible  <bruno@clisp.org>
9005
9006         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
9007         <stdlib.h>, <string.h>.
9008
9009 2006-07-30  Bruno Haible  <bruno@clisp.org>
9010
9011         * modules/readlink (License): Change to LGPL.
9012
9013 2006-07-30  Bruno Haible  <bruno@clisp.org>
9014
9015         * modules/javaversion (Makefile.am): Distribute javaversion.java and
9016         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
9017         set PKGDATADIR to point to it.
9018
9019 2006-07-30  Bruno Haible  <bruno@clisp.org>
9020
9021         * modules/csharpexec (configure.ac): Comment out macro invocation.
9022         * modules/javaexec (configure.ac): Likewise.
9023         * modules/javacomp-script (configure.ac): Likewise.
9024
9025         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
9026
9027 2006-07-30  Bruno Haible  <bruno@clisp.org>
9028
9029         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
9030         linked-list.
9031
9032 2006-07-30  Bruno Haible  <bruno@clisp.org>
9033
9034         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
9035
9036 2006-07-30  Bruno Haible  <bruno@clisp.org>
9037
9038         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9039         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
9040         get removed.
9041
9042 2006-07-29  Bruno Haible  <bruno@clisp.org>
9043
9044         Make it possible for gnulib-tool to work with locally modified or
9045         augmented gnulib repositories.
9046         * gnulib-tool (func_usage): Document --local-dir option.
9047         (local_gnulib_dir): New variable.
9048         Handle --local-dir option.
9049         (func_lookup_file): New function.
9050         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
9051         (func_get_description, func_get_filelist, func_get_description,
9052         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
9053         func_get_automake_snippet, func_get_include_directive,
9054         func_get_license, func_get_maintainer): Use func_lookup_file.
9055         (func_import, func_create_testdir): Use func_lookup_file.
9056
9057 2006-07-29  Bruno Haible  <bruno@clisp.org>
9058
9059         * modules/setenv (Depends-on): Add unistd.
9060
9061 2006-07-29  Bruno Haible  <bruno@clisp.org>
9062
9063         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
9064
9065 2006-07-29  Bruno Haible  <bruno@clisp.org>
9066
9067         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
9068
9069 2006-07-29  Bruno Haible  <bruno@clisp.org>
9070
9071         * gnulib-tool (import, update): If there is no Makefile.am, look at
9072         aclocal.m4, instead of bailing out.
9073
9074 2006-07-29  Bruno Haible  <bruno@clisp.org>
9075
9076         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
9077         Categorize the options by when they are useful.
9078
9079 2006-07-29  Bruno Haible  <bruno@clisp.org>
9080
9081         * gnulib-tool (func_usage): Document option --no-libtool.
9082         Handle option --no-libtool.
9083         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
9084         for changed semantics of $libtool variable.
9085         (func_import): Likewise. If libtool is not used, show this through
9086         an option --no-libtool.
9087         (func_create_testdir): Update.
9088
9089 2006-07-29  Bruno Haible  <bruno@clisp.org>
9090
9091         * gnulib-tool (func_import): Extend error message about missing
9092         --doc-base.
9093
9094 2006-07-29  Bruno Haible  <bruno@clisp.org>
9095
9096         * gnulib-tool (func_import): Don't create the $docbase directory if
9097         there is no file to store there.
9098
9099 2006-07-29  Bruno Haible  <bruno@clisp.org>
9100
9101         * gnulib-tool (autoconf_minversion): If a --dir option is given and
9102         relevant, look for configure.ac there, not in the current directory.
9103         Also use a simple search for AC_PREREQ, not "autoconf --trace".
9104
9105 2006-07-29  Bruno Haible  <bruno@clisp.org>
9106
9107         * gnulib-tool (SORT): New variable.
9108         (func_usage): Undocument --assume-autoconf option.
9109         Remove --assume-autoconf option handling.
9110         (autoconf_minversion): Determine from the contents of configure.ac.
9111         (func_import): Remove autoconf_minversion handling.
9112         Suggested by Eric Blake.
9113
9114 2006-07-29  Bruno Haible  <bruno@clisp.org>
9115
9116         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
9117
9118 2006-07-29  Bruno Haible  <bruno@clisp.org>
9119
9120         * config/srclist.txt (*setenv.[ch]): Remove rules.
9121
9122 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9123
9124         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
9125
9126 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9127
9128         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
9129         arpa/inet.h.
9130
9131 2006-07-28  Simon Josefsson  <jas@extundo.com>
9132
9133         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
9134         * modules/inet_pton (Depends-on): Likewise.
9135
9136 2006-07-28  Simon Josefsson  <jas@extundo.com>
9137
9138         * m4/netinet_in_h.m4: New file.
9139
9140 2006-07-28  Simon Josefsson  <jas@extundo.com>
9141
9142         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
9143         #include's.
9144
9145 2006-07-28  Simon Josefsson  <jas@extundo.com>
9146
9147         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
9148         #include's.
9149
9150 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
9151
9152         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
9153         setgid on directories only if they set these bits.
9154         * lib/modechange.h: Remove obsolete comment about masks.
9155
9156 2006-07-28  Eric Blake  <ebb9@byu.net>
9157
9158         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
9159         macro expansion.
9160
9161 2006-07-28  Bruno Haible  <bruno@clisp.org>
9162
9163         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
9164
9165 2006-07-28  Bruno Haible  <bruno@clisp.org>
9166
9167         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
9168
9169 2006-07-28  Bruno Haible  <bruno@clisp.org>
9170
9171         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
9172         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
9173         Define fallbacks.
9174         Avoids link error on FreeBSD 4.x.
9175         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
9176
9177         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
9178         encoding.
9179         * lib/mbswidth.c (iswcntrl): Likewise.
9180
9181 2006-07-27  Bruno Haible  <bruno@clisp.org>
9182
9183         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
9184         test.
9185
9186 2006-07-27  Bruno Haible  <bruno@clisp.org>
9187
9188         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
9189         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
9190         defined.
9191
9192 2006-07-26  Eric Blake  <ebb9@byu.net>
9193
9194         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
9195
9196 2006-07-26  Eric Blake  <ebb9@byu.net>
9197
9198         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
9199         like mingw that lack mkstemp.
9200         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
9201         avoid compilation warning on mingw.
9202
9203 2006-07-26  Bruno Haible  <bruno@clisp.org>
9204
9205         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
9206         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
9207         INT_FAST*_MIN, INTPTR_MIN.
9208
9209 2006-07-25  Bruno Haible  <bruno@clisp.org>
9210
9211         * modules/version-etc (Depends-on): Add stdarg.
9212
9213 2006-07-25  Bruno Haible  <bruno@clisp.org>
9214
9215         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
9216         complex commands.
9217
9218 2006-07-25  Bruno Haible  <bruno@clisp.org>
9219
9220         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
9221         defined in <stdarg.h> or config.h.
9222
9223 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9224
9225         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
9226         (gl_STDIO_SAFER): Remove.
9227
9228 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9229
9230         * MODULES.html.sh (File stream based Input/Output):
9231         Add fopen-safer, tmpfile-safer; remove stdio-safer.
9232         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
9233         * modules/fopen-safer, modules/tmpfile-safer: New files.
9234         * modules/stdio-safer: Remove.
9235
9236 2006-07-24  Bruno Haible  <bruno@clisp.org>
9237
9238         * modules/tmpdir: New file.
9239         * MODULES.html.sh (File system functions): Add it.
9240
9241 2006-07-24  Bruno Haible  <bruno@clisp.org>
9242
9243         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
9244         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
9245
9246 2006-07-24  Bruno Haible  <bruno@clisp.org>
9247
9248         * modules/clean-temp: New file.
9249
9250 2006-07-24  Bruno Haible  <bruno@clisp.org>
9251
9252         * m4/tmpdir.m4: New file, from GNU gettext.
9253
9254 2006-07-24  Bruno Haible  <bruno@clisp.org>
9255
9256         * lib/tmpdir.h: New file, from GNU gettext.
9257         * lib/tmpdir.c: New file, from GNU gettext.
9258
9259 2006-07-24  Bruno Haible  <bruno@clisp.org>
9260
9261         * lib/clean-temp.h: New file, from GNU gettext.
9262         * lib/clean-temp.c: New file, from GNU gettext.
9263
9264 2006-07-23  Eric Blake  <ebb9@byu.net>
9265
9266         * modules/stdio-safer (Files): Add tmpfile-safer.c.
9267         (Depends-on): Add binary-io.
9268
9269 2006-07-23  Eric Blake  <ebb9@byu.net>
9270
9271         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
9272
9273 2006-07-23  Eric Blake  <ebb9@byu.net>
9274
9275         * lib/tmpfile-safer.c: New file.
9276         * lib/stdio-safer.h (fopen_safer): Add prototype.
9277         * lib/stdio--.h (tmpfile): Make safer.
9278
9279 2006-07-23  Bruno Haible  <bruno@clisp.org>
9280
9281         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
9282         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
9283         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
9284         gl_linked_remove_at): Use it.
9285
9286 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9287         and Simon Josefsson <jas@extundo.com>
9288
9289         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
9290
9291         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
9292
9293 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9294
9295         * modules/close-stream: New file.
9296         * modules/closeout (Description): Make it clear that it exits
9297         with a diagnostic on error.
9298         (Depends-on): Add close-stream.  Remove fpending, stdbool.
9299         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
9300
9301 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9302
9303         * m4/close-stream.m4: New file.
9304
9305 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9306
9307         * lib/close-stream.c, lib/close-stream.h: New files.
9308
9309 2006-07-22  Bruno Haible  <bruno@clisp.org>
9310
9311         Merge from GNU gettext 0.15.
9312
9313         2006-05-01  Bruno Haible  <bruno@clisp.org>
9314
9315                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
9316
9317         2006-07-22  Bruno Haible  <bruno@clisp.org>
9318
9319                 * modules/javaversion: New file.
9320                 * MODULES.html.sh (Java): Add javaversion.
9321
9322         2006-03-12  Bruno Haible  <bruno@clisp.org>
9323
9324                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
9325
9326         2005-12-04  Bruno Haible  <bruno@clisp.org>
9327
9328                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
9329                 (untested).
9330
9331         2006-06-21  Bruno Haible  <bruno@clisp.org>
9332
9333                 Avoid warnings from recent versions of mcs.
9334                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
9335                 -o, -L, -r any more. Use options documented since mcs-1.0
9336                 instead. Similarly for -g.
9337
9338         2005-12-04  Bruno Haible  <bruno@clisp.org>
9339
9340                 * build-aux/csharpcomp.sh.in: Suffix for resources is
9341                 .resources, not .resource.
9342
9343         2005-07-09  Bruno Haible  <bruno@clisp.org>
9344
9345                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
9346                 add a .dll suffix.
9347                 Reported by Mark Junker <mjscod@gmx.de>.
9348
9349         2006-07-22  Bruno Haible  <bruno@clisp.org>
9350
9351                 * modules/gettext: Upgrade to gettext-0.15.
9352                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
9353                 m4/visibility.m4.
9354                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
9355
9356 2006-07-22  Bruno Haible  <bruno@clisp.org>
9357
9358         Merge from GNU gettext 0.15.
9359
9360         2006-03-25  Bruno Haible  <bruno@clisp.org>
9361
9362                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
9363
9364         2006-07-21  Bruno Haible  <bruno@clisp.org>
9365
9366                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
9367                 "1.1".
9368
9369         2006-05-09  Bruno Haible  <bruno@clisp.org>
9370
9371                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
9372                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
9373                 for the conftestver execution.
9374
9375         2006-05-01  Bruno Haible  <bruno@clisp.org>
9376
9377                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
9378                 optional target-version argument. Verify that the compiler
9379                 groks source of the specified source-version, or add -source
9380                 option as necessary. Verify that the compiler produces
9381                 bytecode in the specified target-version, or add -target and
9382                 -source options as necessary. Make the result of the test
9383                 available as variable CONF_JAVAC. Also log error output in
9384                 config.log.
9385
9386         2006-03-11  Bruno Haible  <bruno@clisp.org>
9387
9388                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
9389
9390         2006-05-09  Bruno Haible  <bruno@clisp.org>
9391
9392                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
9393                 CLASSPATH_SEPARATOR to a semicolon.
9394
9395         2006-03-12  Bruno Haible  <bruno@clisp.org>
9396
9397                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
9398                 available as variable CONF_JAVA, for subsequent autoconf
9399                 tests. Also log error output in config.log.
9400
9401         2006-07-19  Bruno Haible  <bruno@clisp.org>
9402
9403                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
9404                 that getline works on glibc2 systems. Needed to avoid trouble
9405                 in relocatable.c.
9406                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
9407
9408         2005-12-04  Bruno Haible  <bruno@clisp.org>
9409
9410                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
9411                 launcher (untested).
9412
9413         2005-12-04  Bruno Haible  <bruno@clisp.org>
9414
9415                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
9416
9417         2006-07-22  Bruno Haible  <bruno@clisp.org>
9418
9419                 * gettext.m4: Update from GNU gettext-0.15.
9420                 * nls.m4: Likewise.
9421                 * po.m4: Likewise.
9422                 * inttypes-pri.m4: Likewise.
9423                 * inttypes-h.m4: Renamed from inttypes.m4.
9424                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
9425
9426 2006-07-22  Bruno Haible  <bruno@clisp.org>
9427
9428         Merge from GNU gettext 0.15.
9429
9430         2005-07-05  Bruno Haible  <bruno@clisp.org>
9431
9432                 * printf-args.c (printf_fetchargs): Work around broken
9433                 definition of wint_t on mingw.
9434
9435         2005-02-12  Bruno Haible  <bruno@clisp.org>
9436
9437                 * xallocsa.h: Add extern "C" for C++.
9438
9439         2006-05-17  Bruno Haible  <bruno@clisp.org>
9440
9441                 Cygwin portability.
9442                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
9443
9444         2006-04-30  Bruno Haible  <bruno@clisp.org>
9445
9446                 * progreloc.c: Include <mach-o/dyld.h> if available.
9447                 (find_executable): Use _NSGetExecutablePath when possible.
9448
9449         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9450
9451                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
9452                 function.
9453
9454         2005-12-29  Bruno Haible  <bruno@clisp.org>
9455
9456                 * progreloc.c (set_program_name_and_installdir): Fix
9457                 compilation error.
9458
9459         2005-12-04  Bruno Haible  <bruno@clisp.org>
9460
9461                 Cygwin portability.
9462                 * progreloc.c: Include <windows.h> also on Cygwin.
9463                 (find_executable): Add support for Cygwin.
9464                 (set_program_name_and_installdir): Handle also platforms with
9465                 nonempty EXEEXT.
9466
9467         2006-07-11  Bruno Haible  <bruno@clisp.org>
9468
9469                 * javacomp.c: Fix a comment.
9470                 Reported by Jim Meyering.
9471
9472         2006-04-30  Bruno Haible  <bruno@clisp.org>
9473
9474                 * javacomp.h (compile_java_class): Add source_version,
9475                 target_version arguments.
9476                 * javacomp.c: Rewritten to choose only a compiler that
9477                 respects the specified source_version and target_version.
9478
9479         2006-06-27  Bruno Haible  <bruno@clisp.org>
9480
9481                 Assume correct S_ISDIR macro.
9482                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
9483
9484         2006-07-22  Bruno Haible  <bruno@clisp.org>
9485
9486                 * javaversion.h: New file, from GNU gettext.
9487                 * javaversion.c: New file, from GNU gettext.
9488                 * javaversion.java: New file, from GNU gettext.
9489                 * javaversion.class: New file, from GNU gettext.
9490
9491         2006-05-17  Bruno Haible  <bruno@clisp.org>
9492
9493                 Cygwin portability.
9494                 * javaexec.c (execute_java_class): Test for jview program
9495                 also on Cygwin.
9496
9497         2006-04-09  Bruno Haible  <bruno@clisp.org>
9498
9499                 * fatal-signal.c: Don't include string.h.
9500                 (at_fatal_signal): Use a copying loop instead of memcpy.
9501
9502         2005-12-04  Bruno Haible  <bruno@clisp.org>
9503
9504                 * csharpexec.c: Add support for 'clix' launcher (untested).
9505                 (execute_csharp_using_sscli): New function.
9506                 (execute_csharp_program): Call it.
9507
9508         2006-06-21  Bruno Haible  <bruno@clisp.org>
9509
9510                 Avoid warnings from recent versions of mcs.
9511                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
9512                 -o, -L, -r any more. Use options documented since mcs-1.0
9513                 instead. Similarly for -g.
9514
9515         2005-07-09  Bruno Haible  <bruno@clisp.org>
9516
9517                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
9518                 add a .dll suffix.
9519                 Reported by Mark Junker <mjscod@gmx.de>.
9520
9521         2006-06-17  Bruno Haible  <bruno@clisp.org>
9522
9523                 * config.charset: Update for NetBSD 3.0.
9524
9525         2006-05-17  Bruno Haible  <bruno@clisp.org>
9526
9527                 Cygwin portability.
9528                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
9529
9530         2006-05-16  Bruno Haible  <bruno@clisp.org>
9531
9532                 * localcharset.c [CYGWIN]: Include <windows.h>.
9533                 (get_charset_aliases): For Cygwin, return the same CPxxx
9534                 aliases list as under WIN32.
9535                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
9536                 the environment variables. Fall back to GetACP().
9537
9538         2006-04-05  Bruno Haible  <bruno@clisp.org>
9539
9540                 * config.charset: Update Juan Manuel Guerrero's address.
9541
9542         2005-02-12  Bruno Haible  <bruno@clisp.org>
9543
9544                 * allocsa.h: Add extern "C" for C++.
9545
9546         2005-02-10  Bruno Haible  <bruno@clisp.org>
9547
9548                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
9549                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
9550
9551         2006-07-22  Bruno Haible  <bruno@clisp.org>
9552
9553                 * gettext.h: Update to GNU gettext-0.15.
9554
9555 2006-07-22  Bruno Haible  <bruno@clisp.org>
9556
9557         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
9558         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
9559         lib-prefix.m4, longdouble.m4, ssize_t.m4.
9560
9561 2006-07-21  Eric Blake  <ebb9@byu.net>
9562
9563         * modules/stdlib-safer: New file.
9564         * MODULES.html.sh (File stream based Input/Output): Add
9565         stdlib-safer.
9566
9567 2006-07-21  Eric Blake  <ebb9@byu.net>
9568
9569         * lib/stdlib-safer.h: New file from coreutils, required by
9570         stdlib--.h.
9571
9572 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
9573
9574         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
9575
9576 2006-07-20  Bruno Haible  <bruno@clisp.org>
9577
9578         * gnulib-tool: Recognize new option --assume-autoconf.
9579         (autoconf_minversion): New variable.
9580         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
9581
9582 2006-07-20  Bruno Haible  <bruno@clisp.org>
9583
9584         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
9585
9586 2006-07-19  Derek R. Price  <derek@ximbiot.com>
9587
9588         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
9589         Reindent and repaginate.
9590
9591 2006-07-19  Derek Price  <derek@ximbiot.com>
9592
9593         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
9594         Correct grammar.
9595
9596 2006-07-17  Bruno Haible  <bruno@clisp.org>
9597
9598         * modules/list: New file.
9599         * modules/array-list: New file.
9600         * modules/carray-list, modules/carray-list-tests: New files.
9601         * modules/linked-list, modules/linked-list-tests: New files.
9602         * modules/avltree-list, modules/avltree-list-tests: New files.
9603         * modules/rbtree-list, modules/rbtree-list-tests: New files.
9604         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
9605         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
9606         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
9607         * modules/oset: New file.
9608         * modules/array-oset: New file.
9609         * modules/avltree-oset, modules/avltree-oset-tests: New files.
9610         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
9611         * tests/test-carray_list.c: New file.
9612         * tests/test-linked_list.c: New file.
9613         * tests/test-avltree_list.c: New file.
9614         * tests/test-rbtree_list.c: New file.
9615         * tests/test-linkedhash_list.c: New file.
9616         * tests/test-avltreehash_list.c: New file.
9617         * tests/test-rbtreehash_list.c: New file.
9618         * tests/test-avltree_oset.c: New file.
9619         * tests/test-rbtree_oset.c: New file.
9620         * MODULES.html.sh (Container data structures): New section.
9621
9622 2006-07-17  Bruno Haible  <bruno@clisp.org>
9623
9624         * m4/gl_list.m4: New file.
9625
9626 2006-07-17  Bruno Haible  <bruno@clisp.org>
9627
9628         * lib/gl_list.h: New file.
9629         * lib/gl_list.c: New file.
9630         * lib/gl_array_list.h: New file.
9631         * lib/gl_array_list.c: New file.
9632         * lib/gl_carray_list.h: New file.
9633         * lib/gl_carray_list.c: New file.
9634         * lib/gl_linked_list.h: New file.
9635         * lib/gl_linked_list.c: New file.
9636         * lib/gl_anylinked_list1.h: New file.
9637         * lib/gl_anylinked_list2.h: New file.
9638         * lib/gl_avltree_list.h: New file.
9639         * lib/gl_avltree_list.c: New file.
9640         * lib/gl_anyavltree_list1.h: New file.
9641         * lib/gl_anyavltree_list2.h: New file.
9642         * lib/gl_rbtree_list.h: New file.
9643         * lib/gl_rbtree_list.c: New file.
9644         * lib/gl_anyrbtree_list1.h: New file.
9645         * lib/gl_anyrbtree_list2.h: New file.
9646         * lib/gl_anytree_list1.h: New file.
9647         * lib/gl_anytree_list2.h: New file.
9648         * lib/gl_linkedhash_list.h: New file.
9649         * lib/gl_linkedhash_list.c: New file.
9650         * lib/gl_anyhash_list1.h: New file.
9651         * lib/gl_anyhash_list2.h: New file.
9652         * lib/gl_avltreehash_list.h: New file.
9653         * lib/gl_avltreehash_list.c: New file.
9654         * lib/gl_rbtreehash_list.h: New file.
9655         * lib/gl_rbtreehash_list.c: New file.
9656         * lib/gl_anytreehash_list1.h: New file.
9657         * lib/gl_anytreehash_list2.h: New file.
9658
9659         * lib/gl_oset.h: New file.
9660         * lib/gl_oset.c: New file.
9661         * lib/gl_array_oset.h: New file.
9662         * lib/gl_array_oset.c: New file.
9663         * lib/gl_avltree_oset.h: New file.
9664         * lib/gl_avltree_oset.c: New file.
9665         * lib/gl_rbtree_oset.h: New file.
9666         * lib/gl_rbtree_oset.c: New file.
9667         * lib/gl_anytree_oset.h: New file.
9668
9669 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9670
9671         * m4/mkancesdirs.m4: New file.
9672         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
9673         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
9674         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
9675         it.
9676
9677 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9678
9679         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
9680         * lib/mkancesdirs.h: New files.
9681         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
9682         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
9683         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
9684         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
9685         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
9686         callers changed.  Revamp internals significantly, by not
9687         attempting to create directories that are temporarily more
9688         permissive than the final results.  Do not attempt to use
9689         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
9690         This removes some race conditions, fixes some bugs, and simplifies
9691         things.  Use new dirchownmod function to do owner and mode changes.
9692         * lib/mkdir-p.h: Likewise.
9693         * lib/modechange.c (octal_to_mode): New function.
9694         (struct mode_change): New member mentioned.
9695         (make_node_op_equals): New arg mentioned.  All callers changed.
9696         (mode_compile): Keep track of which mode bits the user has explicitly
9697         mentioned.
9698         (mode_adjust): New arg DIR, so that we implement the X op correctly.
9699         New arg PMODE_BITS, to keep track of which mode bits the user
9700         mentioned; it treats S_ISUID and S_ISGID speciall.
9701         All callers changed.
9702         * lib/modechange.h: Likewise.
9703
9704 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9705
9706         * MODULES.html.sh: Add mkancestors.
9707         * modules/mkancesdirs: New module.
9708         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
9709         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
9710         The chdir-safer and afs files are now orphans; I'll remove them
9711         unless someone speaks up.
9712         Add lib/dirchownmod.c, lib/dirchownmod.h.
9713         (Depends-on): Remove alloca, chown, save-cwd, dirname.
9714         Add lchown, mkancesdirs.
9715         (Maintainer): Add self.
9716
9717 2006-07-15  Karl Berry  <karl@gnu.org>
9718
9719         * gnulib-tool: help message wording/arrangement.
9720
9721 2006-07-14  Simon Josefsson  <jas@extundo.com>
9722
9723         * doc/gnulib.texi (Libtool and Windows): New section.
9724
9725 2006-07-12  Simon Josefsson  <jas@extundo.com>
9726
9727         * modules/gendocs (License): Fix license, approved by Karl.
9728
9729 2006-07-12  Eric Blake  <ebb9@byu.net>
9730
9731         * MODULES.html.sh: Add gendocs.
9732
9733 2006-07-11  Eric Blake  <ebb9@byu.net>
9734
9735         * modules/fdl: New module, to install doc/fdl.texi.
9736         * MODULES.html.sh: Add new section for documentation modules.
9737         * gnulib-tool: Avoid space-tab.
9738         (--doc-base): New option, to manage files from doc.
9739
9740 2006-07-11  Eric Blake  <ebb9@byu.net>
9741
9742         * m4/absolute-header.m4: Fix comments to match recent change.
9743
9744 2006-07-11  Eric Blake  <ebb9@byu.net>
9745
9746         * gnulib-tool: List --doc-base before --tests-base.
9747
9748 2006-07-11  Derek R. Price  <derek@ximbiot.com>
9749
9750         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
9751
9752 2006-07-11  Bruno Haible  <bruno@clisp.org>
9753
9754         * README: Mention where to put documentation.
9755
9756 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9757
9758         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
9759
9760 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
9761
9762         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
9763         to stdint.m4.
9764
9765 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
9766
9767         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
9768         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
9769         "no/such/file/stdint.h" when there is no such file, so that
9770         the resulting C code can be parsed by dodgy compilers.
9771         Problems reported by Bob Proulx.
9772
9773 2006-07-10  Derek R. Price  <derek@ximbiot.com>
9774
9775         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
9776         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
9777         macros into the GNU _D_EXACT_NAMLEN.
9778         * lib/savedir.c:  Likewise.
9779         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
9780
9781 2006-07-10  Derek R. Price  <derek@ximbiot.com>
9782         and Paul Eggert  <eggert@cs.ucla.edu>
9783
9784         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
9785         * m4/savedir.m4:
9786         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
9787         macros into the GNU _D_EXACT_NAMLEN.
9788
9789 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9790
9791         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
9792         around the absolute name, to work around a problem with the HP-UX
9793         11.23 native C compiler, reported by Bob Proulx.
9794
9795 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9796
9797         * doc/maintain.texi, make-stds.texi: Sync from
9798         <http://savannah.gnu.org/projects/gnustandards>.
9799
9800 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9801
9802         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
9803
9804 2006-07-09  Jim Meyering  <jim@meyering.net>
9805
9806         * m4/glob.m4: Remove a doubled word in a comment.
9807
9808 2006-07-09  Jim Meyering  <jim@meyering.net>
9809
9810         * lib/argp-pv.c: Remove a doubled word in a comment.
9811         * lib/check-version.c (check_version): Likewise.
9812         * lib/javacomp.c (compile_java_class): Likewise.
9813
9814 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
9815
9816         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
9817         for the benefit of people using Autoconf 2.60.  If you want to
9818         support older Autoconf versions you can copy m4/onceonly_2_57.m4
9819         (or m4/onceonly.m4, if pre-2.57) manually.
9820
9821 2006-07-08  Jim Meyering  <jim@meyering.net>
9822
9823         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
9824         comment.
9825         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
9826         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
9827         comment.
9828
9829 2006-07-08  Jim Meyering  <jim@meyering.net>
9830
9831         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
9832
9833 2006-07-07  Simon Josefsson  <jas@extundo.com>
9834
9835         * tests/test-crc.c: Change expected crc value, the test vector
9836         were probably computed using the old broken crc.c?
9837
9838 2006-07-06  Simon Josefsson  <jas@extundo.com>
9839
9840         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
9841         now the canonical place for the M4 file).
9842
9843         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
9844         from the sys_socket dependency now.
9845
9846         * modules/inet_pton (Files): Ditto.
9847
9848         * modules/inet_ntop (Files): Ditto.
9849
9850 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
9851
9852         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
9853         not gl_PREREQ_GETUSERSHELL.
9854
9855 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9856
9857         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
9858         with only one argument, for Autoconf 2.60.
9859         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
9860         expand to nothing, so add a shell command to avoid syntax error.
9861         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
9862
9863 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9864
9865         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
9866
9867 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9868
9869         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
9870         no longer needed.  Check for isblank decl.
9871         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
9872         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
9873         of existence.
9874
9875 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9876
9877         * lib/getloadavg.c: Use __VMS, not VMS.
9878         * lib/getopt.c: Likewise.
9879         * lib/getpagesize.h: Likewise.
9880         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
9881         and probably does not work.
9882
9883 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9884
9885         * lib/.cppi-disable: Add wcwidth.
9886         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
9887         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
9888         (ISGRAPH): Remove.  All uses changed to isgraph.
9889         (FOLD) [!defined _LIBC]: Remove special case.
9890         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
9891         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
9892         HAVE_ISBLANK.
9893         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
9894         case.
9895
9896 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
9897
9898         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
9899         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
9900         brackets.  Other minor changes to suppress some compiler
9901         warnings.
9902
9903 2006-07-06  Derek R. Price  <derek@ximbiot.com>
9904         and Paul Eggert  <eggert@cs.ucla.edu>
9905
9906         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
9907         of invoking obsolescent AC_HEADER_DIRENT macro.
9908         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
9909         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
9910         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
9911         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
9912         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
9913         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
9914         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
9915         * m4/readdir.m4: Remove; no longer needed.
9916
9917 2006-07-06  Derek R. Price  <derek@ximbiot.com>
9918         and Paul Eggert  <eggert@cs.ucla.edu>
9919
9920         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
9921         Don't worry about this obsolete case any more.
9922         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
9923         directories.
9924         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
9925         worry about this obsolete case any more.
9926         * lib/fts.c: Likewise.
9927         * lib/getcwd.c: Likewise.
9928         * lib/glob.h: Likewise.
9929         * lib/savedir.c: Likewise.
9930
9931 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
9932
9933         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
9934         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
9935         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
9936         needed.
9937         All uses removed.
9938         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9939         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
9940         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
9941         needed.
9942         * m4/getdate.m4 (gl_GETDATE): Likewise.
9943         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
9944         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
9945         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
9946         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9947         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
9948         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
9949         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
9950         needed.
9951
9952 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
9953
9954         * lib/memcasecmp.c: Include <limits.h>.
9955         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
9956         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
9957         Don't assume isdigit succeeds only on '0' through '9'.
9958
9959 2006-07-05  Eric Blake  <ebb9@byu.net>
9960
9961         * modules/getaddrinfo (Depends-on): Add snprintf.
9962
9963 2006-07-05  Eric Blake  <ebb9@byu.net>
9964
9965         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
9966         to avoid 'header present but could not be compiled' on cygwin.
9967
9968 2006-07-05  Eric Blake  <ebb9@byu.net>
9969
9970         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
9971         missing from netdb.h.
9972         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
9973
9974 2006-07-05  Derek R. Price  <derek@ximbiot.com>
9975
9976         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
9977         no longer needed.
9978         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
9979         * m4/getdate.m4 (gl_GETDATE): Likewise.
9980         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
9981         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
9982         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
9983         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9984         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
9985
9986 2006-07-05  Derek R. Price  <derek@ximbiot.com>
9987
9988         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
9989         All uses of is_space replaced by isspace.
9990         * lib/exit.h: Don't talk about STDC_HEADERS.
9991         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
9992         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
9993         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
9994         replaced by isprint etc.
9995         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
9996         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
9997         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
9998         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
9999         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
10000         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
10001
10002 2006-07-05  Bruno Haible  <bruno@clisp.org>
10003
10004         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
10005         the function exists, before testing against AIX.
10006         Reported by Martin Lambers <marlam@marlam.de>.
10007
10008 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
10009
10010         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
10011         From Mark D. Baushke.
10012
10013 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
10014
10015         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
10016         to the absolute name, not just one, to bypass Sun C 5.8's
10017         "warning: #include of /usr/include/... may be non-portable".
10018
10019 2006-07-04  Eric Blake  <ebb9@byu.net>
10020
10021         * modules/dirname-tests: New test module.
10022         * tests/test-dirname.c: New file, replacing dirname.c
10023         TEST_DIRNAME section that was recently deleted.
10024
10025 2006-07-04  Bruno Haible  <bruno@clisp.org>
10026
10027         Assume ANSI C header files and <ctype.h> functions.
10028         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
10029         (mbsnwidth): Use isprint, iscntrl instead.
10030
10031 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10032
10033         Merge from coreutils.
10034         * MODULES.html.sh: Add xstrtold.
10035         * modules/xstrtold: New file.
10036         * modules/cycle-check (Files): Add lib/same-inode.h.
10037         * modules/dirname (Files): Add m4/double-slash-root.m4.
10038         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
10039         * modules/mkdir-p (Files): Add lib/same-inode.h.
10040         * modules/same (Files): Add lib/same-inode.h.
10041
10042 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10043
10044         * m4/absolute-header.m4: Renamed from full-header-path.m4.
10045         This is to keep the terminology clean; POSIX talks about
10046         "absolute pathnames", not "full pathnames", but the GNU
10047         Coding Standards say to use "path" for something else;
10048         so use "absolute" to keep both sides happy.
10049         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
10050         Set gl_absolute_header, not gl_full_header_path.
10051         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
10052         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
10053         All uses changed.
10054
10055         Merge from coreutils.
10056
10057         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
10058
10059         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
10060         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
10061         want to require the building of c-strtod.o.
10062         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
10063         needs -lm directly.
10064         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
10065
10066         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
10067
10068         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
10069         --as-needed option if available.  Problem reported by Albert Chin in
10070         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
10071         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
10072         cc merely issues a bunch of annoying warnings for --as-needed
10073         (this problem was reported by Bob Proulx).  Also, try linking with
10074         -lm to detect a bug in binutils 2.16 (this problem was reported
10075         by Ralf Wildenhues).
10076
10077         2006-06-18  Jim Meyering  <jim@meyering.net>
10078
10079         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
10080         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
10081         macro.
10082         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
10083         also check for glibc-2.4's abort-inducing bug.
10084
10085         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
10086         Low-probability clean-up should be to use rmdir to get rid of
10087         the just-created directory, not unlink.
10088
10089         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
10090         configure fail, and request a bug report to inform us about it.
10091         Add a comment that, barring reports to the contrary, in 2007 we'll
10092         assume ftruncate is universally available.
10093
10094         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10095
10096         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
10097
10098         2006-03-12  Jim Meyering  <jim@meyering.net>
10099
10100         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
10101         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
10102         * m4/same.m4 (gl_SAME): Likewise.
10103         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
10104
10105         2006-03-11  Eric Blake  <ebb9@byu.net>
10106
10107         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
10108         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
10109         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
10110         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
10111
10112 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10113
10114         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
10115         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
10116         reported by Mark D. Baushke, one in
10117         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
10118
10119         Merge from coreutils.
10120
10121         * lib/.cppi-disable: Add stdint_.h.
10122         * lib/.cvsignore: Add stdint.h.
10123
10124         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
10125
10126         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
10127         both double and long double versions.
10128         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
10129         * lib/xstrtold.c: New file.
10130         * lib/xstrtod.h (xstrtold): New decl.
10131
10132         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
10133
10134         * lib/filemode.c (setst): Remove.
10135         (strmode): Rewrite to avoid setst.  This makes the code shorter,
10136         (arguably) clearer, and the generated code is a bit smaller on my
10137         Debian GNU/Linux stable x86 host.
10138
10139         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10140
10141         * lib/filemode.c: Include "filemode.h" first, to test the interface.
10142         Assume that filemode.h includes sys/types.h and sys/stat.h.
10143         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
10144         (ftypelet): Reorder to put common cases first, for efficiency.
10145         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
10146         to do 'M'.
10147         (strmode): Renamed from mode_string, and now stores 12 bytes instead
10148         of 10, for compatibility with FreeBSD.  All callers changed.
10149         (filemodestring): Now stores 12 bytes instead of 10, and sets file
10150         types that can't be deduced solely from st_mode.  First arg is now a
10151         const pointer.
10152         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
10153         (strmode): Renamed from mode_string.
10154         (filemodestring): New decl.
10155         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
10156         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
10157         needed.
10158         (S_ISPORT, S_ISWHT): New macros, if not already defined.
10159
10160         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
10161
10162         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
10163         fsusage.h now does that.  Include fsusage.h first, to test interface.
10164         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
10165         at most one method (the old code could have generated decls that
10166         didn't conform to C89, not that this was ever exercised).
10167         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
10168
10169         2006-03-19  Jim Meyering  <jim@meyering.net>
10170
10171         Work even in a chroot where d_ino values for entries in "/"
10172         don't match the stat.st_ino values for the same names.
10173         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
10174         number, iterate through all entries again, using lstat instead.
10175         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
10176         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
10177
10178         * lib/getcwd.c (__getcwd): Clarify a comment.
10179         Use memcpy in place of a call to strcpy.
10180
10181         2006-03-12  Jim Meyering  <jim@meyering.net>
10182
10183         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
10184         matches that of the current directory (which we're about to chdir ".."
10185         out of), then save the dev-ino of the parent, instead.
10186
10187         * lib/same-inode.h (SAME_INODE): New file/macro.
10188         * lib/chdir-safer.c (SAME_INODE): Remove definition.
10189         Include "same-inode.h", instead.
10190         * lib/same.c: Likewise.
10191         * lib/cycle-check.h: Include "same-inode.h".
10192         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
10193         * lib/cycle-check.c (SAME_INODE): Remove definition.
10194         * lib/root-dev-ino.h: Include "same-inode.h".
10195
10196         2006-03-11  Eric Blake  <ebb9@byu.net>
10197
10198         * lib/same.c (same_name): s/base_name/last_component/
10199         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
10200         * lib/filenamecat.c (file_name_concat): Likewise.
10201
10202         2006-03-11  Eric Blake  <ebb9@byu.net>,
10203                     Paul Eggert  <eggert@cs.ucla.edu>
10204
10205         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
10206         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
10207         drive prefix.
10208         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
10209         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
10210         (last_component): New method.
10211         * lib/dirname.c (dir_len): Determine when drive letters need a
10212         subsequent slash.  Preserve // when it is special.
10213         (dir_name): Don't append dot when drive letter is absolute.
10214         [TEST_DIRNAME]: Move into a full-blown gnulib test.
10215         * lib/basename.c (base_name): New semantics - malloc the result.
10216         Preserve // when it is special.  Preserve relative files that look
10217         like drive letters.
10218         (base_len): Preserve // when it is special.
10219         (last_component): New method, similar to old base_name semantics.
10220         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
10221         base_name.  Strip redundant slashes from ///.
10222
10223 2006-07-03  Jim Meyering  <jim@meyering.net>
10224
10225         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
10226         macro is used before the first cycle_check call.
10227
10228 2006-07-03  Eric Blake  <ebb9@byu.net>
10229
10230         * modules/dirname (Depends-on): Add xstrndup.
10231
10232 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10233
10234         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
10235         test cases, so that config.log is a bit easier to follow.
10236
10237 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10238
10239         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
10240         both are 64 bits, since this seems to be the tradition, and this
10241         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
10242         we ever run into a host that prefers long long to long in this
10243         case, we'll need another configure-time test.  Problem reported by
10244         Jim Meyering.
10245
10246 2006-07-02  Eric Blake  <ebb9@byu.net>
10247
10248         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
10249
10250 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10251
10252         * modules/inttypes (Depends-on): No longer depends on stdint.
10253         * modules/stdint (Description): Say more about assumptions.
10254         Say that the fast types might differ.  Say macros are used.
10255         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
10256         (Makefile.am): Revise list of substituted symbols to match
10257         new stdint.m4.
10258         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
10259         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
10260         * tests/test-stdint.c (verify_same_types)
10261         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
10262         the code conforms to C99/C89.
10263         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
10264         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
10265
10266 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10267
10268         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
10269         but fix a bug, by requiring at least 64 bits.
10270         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
10271         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
10272         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
10273         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
10274
10275         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
10276         changes.  Make 2.59 a prerequisite.  Check and substitute for
10277         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
10278         inttypes.h.  Do not use special include files; just use the
10279         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
10280         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
10281         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
10282         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
10283         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
10284         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
10285         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
10286         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
10287         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
10288         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
10289         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
10290         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
10291         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
10292         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
10293         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
10294         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
10295         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
10296         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
10297         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
10298         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
10299         WINT_MAX.  Check for C99 conformance more strictly, by detecting
10300         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
10301         not check for things that C99 does not require, e.g., int8_t.  If
10302         a test isn't needed unless <stdint.h> isn't working, and is
10303         unlikely to be needed for any other reason, then don't do it
10304         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
10305         size_t, since we assume C89 freestanding at least.  Do not check
10306         for sig_atomic_t, wchar_t, or wint_t, since the code now does
10307         the right thing even if the types are not defined.  Instead use:
10308         (gl_STDINT_TYPE_PROPERTIES): New macro.
10309         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
10310         testing whether <sys/types.h> clashes, as Autoconf does this for
10311         us now.  All uses removed.
10312         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
10313         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
10314         (gl_CHECK_TYPE_SAME):
10315         Remove; no longer needed.
10316         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
10317         exists, since we'll return 0 anyway in that case.
10318         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
10319
10320 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10321
10322         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
10323         possible collision with system files.
10324         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
10325         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
10326         WCHAR_MIN and WCHAR_MAX in this case.
10327         (<stddef.h>): Do not include; no longer needed.
10328         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
10329         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
10330         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
10331         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
10332         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
10333         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
10334         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
10335         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
10336         !defined(__c99))]: Include in this case too, since it's harmless
10337         now.
10338         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
10339         dangerous to do so.
10340         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
10341         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
10342         (_STDINT_MIN, _STDINT_MAX): New macros.
10343         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
10344         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
10345         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
10346         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
10347         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
10348         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
10349         macros, not typedefs; this simplifies things quite a bit.
10350         Use long int for all types narrower than int64_t.
10351         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
10352         Define in terms of long long int or int64_t or long int,
10353         not int64_t or int32_t.  This saves some compile-time testing.
10354         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
10355         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
10356         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
10357         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
10358         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
10359         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
10360         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
10361         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
10362         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
10363         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
10364         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
10365         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
10366         undef any previous version and define our own version, for
10367         simplicity and consistency with the new macros for types.
10368         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
10369         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
10370         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
10371         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
10372         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
10373         @WINT_T_SUFFIX@ to keep things simple here.
10374         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
10375         Simplify by assuming typical 8/16/32/64 host, since we're
10376         already doing that elsewhere anyway.
10377         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
10378         and assume long long int is 64 bits if available.  This
10379         speeds up 'configure'.
10380
10381 2006-07-01  Eric Blake  <ebb9@byu.net>
10382
10383         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
10384         Reported by Andreas Buening.
10385
10386 2006-07-01  Eric Blake  <ebb9@byu.net>
10387
10388         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
10389
10390 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
10391
10392         * lib/getaddrinfo.c: fixed typo
10393
10394 2006-06-29  Jim Meyering  <jim@meyering.net>
10395
10396         * modules/strftime (Maintainer): Add my name, since with the
10397         FPRINTFTIME changes strftime.c has forked from glibc.
10398
10399 2006-06-29  Eric Blake  <ebb9@byu.net>
10400
10401         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
10402
10403 2006-06-29  Eric Blake  <ebb9@byu.net>
10404
10405         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
10406
10407 2006-06-29  Eric Blake  <ebb9@byu.net>
10408
10409         * lib/stat_.h: New file.
10410
10411 2006-06-29  Eric Blake  <ebb9@byu.net>
10412
10413         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
10414         unused static function.
10415
10416 2006-06-29  Eric Blake  <ebb9@byu.net>
10417
10418         * doc/functions.texi (Function Portability): Document missing lstat
10419         on mingw.
10420
10421 2006-06-29  Eric Blake  <ebb9@byu.net>
10422
10423         * MODULES.html.sh: Add sys_stat.
10424         * modules/sys_stat: New module.
10425         * modules/mkstemp (Depends-on): Add sys_stat.
10426
10427 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10428
10429         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
10430
10431 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10432
10433         * m4/c-bs-a.m4: Removed.
10434
10435 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10436
10437         * lib/strftime.c: Assume strftime() exists.
10438
10439 2006-06-29  Derek Price  <derek@ximbiot.com>
10440
10441         * modules/c-bs-a: Removed - \a is C89.
10442         * MODULES.html.sh: Remove c-bs-a.
10443
10444 2006-06-29  Bruno Haible  <bruno@clisp.org>
10445
10446         * modules/wcwidth (License): Change to LGPL.
10447
10448 2006-06-28  Simon Josefsson  <jas@extundo.com>
10449
10450         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
10451         on _WIN32.
10452
10453         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
10454         getnameinfo.
10455
10456 2006-06-28  Simon Josefsson  <jas@extundo.com>
10457
10458         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
10459
10460 2006-06-28  Simon Josefsson  <jas@extundo.com>
10461
10462         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
10463         functions there.  It will succeed on Windows XP, but on Windows
10464         2000 and (presumably) earlier, it will fail, and use the internal
10465         re-implementation.
10466         (use_win32_p): New function.
10467         (getaddrinfo): Use strtoul on servname, to support numeric ports.
10468         Support AI_NUMERICSERV to disable getservbyname.
10469         (getnameinfo): New function, only supports
10470         NI_NUMERICHOST|NI_NUMERICSERV for now.
10471
10472         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
10473         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
10474         getnameinfo.
10475
10476 2006-06-28  Eric Blake  <ebb9@byu.net>
10477
10478         * modules/wcwidth: New file.
10479         * modules/mbchar (Depends-on): Add wcwidth.
10480         * modules/mbswidth (Depends-on): Add wcwidth.
10481         * MODULES.html.sh: Add wcwidth.
10482
10483 2006-06-28  Eric Blake  <ebb9@byu.net>
10484
10485         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
10486         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
10487
10488 2006-06-28  Eric Blake  <ebb9@byu.net>
10489
10490         * lib/xvasprintf.h: Fix comments.
10491
10492 2006-06-28  Eric Blake  <ebb9@byu.net>
10493
10494         * lib/mbchar.h (wcwidth): Include wcwidth.h.
10495         * lib/mbswidth.c (wcwidth): Move from here...
10496         * lib/wcwidth.h: ...to this new file.
10497
10498 2006-06-28  Derek R. Price  <derek@ximbiot.com>
10499
10500         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
10501
10502         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
10503         it's obsolete.
10504         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
10505
10506 2006-06-28  Derek R. Price  <derek@ximbiot.com>
10507
10508         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
10509         Autoconf 2.60 says this stuff was obsolete.
10510
10511 2006-06-28  Bruno Haible  <bruno@clisp.org>
10512
10513         * modules/wcwidth (Files): Add m4/wchar_t.m4.
10514
10515 2006-06-28  Bruno Haible  <bruno@clisp.org>
10516
10517         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
10518         gt_TYPE_WCHAR_T.
10519
10520 2006-06-28  Bruno Haible  <bruno@clisp.org>
10521
10522         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
10523         declaration for wcwidth.
10524         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
10525
10526 2006-06-28  Bruno Haible  <bruno@clisp.org>
10527
10528         * lib/mkdtemp.c [MINGW]: Include <io.h>.
10529         (mkdir): Define using _mkdir.
10530
10531 2006-06-28  Bruno Haible  <bruno@clisp.org>
10532
10533         * lib/getaddrinfo.h: Fix POSIX URL.
10534         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
10535         _WIN32.
10536         (use_win32_p): Make static.
10537         (getaddrinfo): Reject service name if it is empty or does not consist
10538         solely of decimal digits, or if its value is > 65535.
10539         (getnameinfo): Remove useless casts.
10540
10541 2006-06-27  Simon Josefsson  <jas@extundo.com>
10542
10543         * modules/sys_select: New file, suggested by Bruno Haible, Paul
10544         Eggert and Martin Lambers.
10545
10546 2006-06-27  Simon Josefsson  <jas@extundo.com>
10547
10548         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
10549         Eggert and Martin Lambers.
10550
10551 2006-06-27  Bruno Haible  <bruno@clisp.org>
10552
10553         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
10554         result to 0, not to empty.
10555         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
10556
10557 2006-06-27  Bruno Haible  <bruno@clisp.org>
10558
10559         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
10560
10561 2006-06-26  Simon Josefsson  <jas@extundo.com>
10562
10563         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
10564         present.
10565
10566 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
10567
10568         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
10569         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
10570         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
10571
10572 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
10573
10574         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
10575
10576 2006-06-26  Bruno Haible  <bruno@clisp.org>
10577
10578         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
10579
10580 2006-06-26  Bruno Haible  <bruno@clisp.org>
10581
10582         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
10583
10584 2006-06-26  Bruno Haible  <bruno@clisp.org>
10585
10586         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
10587         SGI C compiler in pre-C99 mode.
10588         Suggested by Mark D. Baushke and Larry Jones.
10589
10590 2006-06-26  Bruno Haible  <bruno@clisp.org>
10591
10592         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
10593         WCHAR_MAX.
10594         Reported by Mark D. Baushke and Larry Jones.
10595
10596 2006-06-26  Bruno Haible  <bruno@clisp.org>
10597
10598         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
10599         in pre-C99 mode.
10600         Suggested by Mark D. Baushke and Larry Jones.
10601
10602 2006-06-23  Simon Josefsson  <jas@extundo.com>
10603             Bruno Haible  <bruno@clisp.org>
10604
10605         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
10606         Emit mostlyclean-local rule.
10607         (func_emit_tests_Makefile_am): Likewise.
10608         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
10609
10610 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
10611
10612         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
10613
10614 2006-06-23  Bruno Haible  <bruno@clisp.org>
10615
10616         * tests/test-stdint.c: Update to match ISO C 99 Technical
10617         Corrigendum 1.
10618
10619 2006-06-23  Bruno Haible  <bruno@clisp.org>
10620
10621         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
10622
10623 2006-06-23  Bruno Haible  <bruno@clisp.org>
10624
10625         * lib/stdint_.h: Treat IRIX like OpenBSD.
10626
10627 2006-06-23  Bruno Haible  <bruno@clisp.org>
10628
10629         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
10630         ISO C 99 Technical Corrigendum 1.
10631
10632 2006-06-22  Simon Josefsson  <jas@extundo.com>
10633
10634         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
10635         MinGW.
10636
10637 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
10638
10639         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
10640         needed.  Some compiler complained about some of them.  Problem reported
10641         by Larry Jones in
10642         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
10643
10644 2006-06-21  Simon Josefsson  <jas@extundo.com>
10645
10646         * tests/test-getaddrinfo.c: New file.
10647
10648         * modules/getaddrinfo-tests: New file.
10649
10650         * MODULES.html.sh: Add inet_pton.
10651
10652         * modules/inet_pton: New file.
10653
10654 2006-06-21  Simon Josefsson  <jas@extundo.com>
10655
10656         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
10657         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
10658         of using the (limited) gnulib implementation on Windows XP.
10659
10660         * m4/inet_pton.m4: New file.
10661
10662 2006-06-21  Simon Josefsson  <jas@extundo.com>
10663
10664         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
10665         variable.
10666
10667         * lib/socket_.h: Don't define WINVER.
10668
10669         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
10670         slightly modified to work in gnulib.
10671
10672 2006-06-21  Simon Josefsson  <jas@extundo.com>
10673
10674         * doc/gnulib.texi (Windows sockets): Add.
10675
10676 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
10677
10678         * lib/read-file.c (fread_file): Start with buffer allocation of
10679         0 bytes rather than 1 byte; this simplifies the code.
10680         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
10681         code to free buffer and save/restore errno.
10682         (internal_read_file): Remove unused local.
10683
10684 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
10685
10686         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
10687         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
10688         Problem reported by Denis Excoffier in
10689         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
10690
10691 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10692
10693         * modules/sys_socket, modules/socklen: Include sys/types since
10694         FreeBSD 4.x's sys/socket.h needs it.
10695
10696 2006-06-19  Simon Josefsson  <jas@extundo.com>
10697
10698         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
10699
10700 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
10701
10702         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
10703
10704 2006-06-19  Bruno Haible  <bruno@clisp.org>
10705
10706         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
10707         and FULL_PATH_INTTYPES_H in angle brackets.
10708         Reported by Mark D. Baushke <mdb@gnu.org>.
10709
10710 2006-06-17  Eric Blake  <ebb9@byu.net>
10711
10712         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
10713         errno.
10714
10715 2006-06-17  Bruno Haible  <bruno@clisp.org>
10716
10717         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
10718         <sys/inttypes.h>.
10719
10720 2006-06-17  Bruno Haible  <bruno@clisp.org>
10721
10722         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
10723         whether errno is declared. Assume <errno.h> declares errno.
10724
10725 2006-06-17  Bruno Haible  <bruno@clisp.org>
10726
10727         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
10728
10729 2006-06-17  Bruno Haible  <bruno@clisp.org>
10730
10731         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
10732         problem on Solaris 2.5.1.
10733
10734 2006-06-16  Eric Blake  <ebb9@byu.net>
10735
10736         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
10737         * lib/unicodeio.c [!defined errno]: Likewise.
10738         * lib/strtol.c [!defined errno]: Likewise.
10739         * lib/strtod.c [!defined errno]: Likewise.
10740
10741 2006-06-15  Eric Blake  <ebb9@byu.net>
10742
10743         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
10744
10745 2006-06-15  Eric Blake  <ebb9@byu.net>
10746
10747         * config/srclist.txt (ssize_t.m4): Lose sync.
10748
10749 2006-06-15  Bruno Haible  <bruno@clisp.org>
10750
10751         * modules/stdint (Files): Include m4/full-header-path.m4,
10752         m4/size_max.m4, m4/wchar_t.m4.
10753         (Makefile.am): Many more substitutions.
10754         * modules/stdint-tests: New file.
10755         * tests/test-stdint.c: New file.
10756
10757 2006-06-15  Bruno Haible  <bruno@clisp.org>
10758
10759         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
10760         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
10761         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
10762         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
10763         gl_CHECK_TYPE_SAME): New macros.
10764
10765 2006-06-15  Bruno Haible  <bruno@clisp.org>
10766
10767         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
10768
10769 2006-06-15  Bruno Haible  <bruno@clisp.org>
10770
10771         * lib/stdint_.h: Rewritten to be fully auto-configured.
10772         Fixes bug on HP-UX/IA64.
10773
10774 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
10775
10776         * lib/getdate.y (__attribute__): Don't define if already defined.
10777         Problem reported by Larry Jones.
10778         * lib/utimens.c (__attribute__): Likewise.
10779
10780 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
10781
10782         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
10783         reported by Andreas Schwab.
10784
10785 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10786             Bruno Haible  <bruno@clisp.org>
10787
10788         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
10789         check for the declaration of strnlen and a run test that exposes the
10790         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
10791         rpl_strndup.
10792
10793 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10794             Bruno Haible  <bruno@clisp.org>
10795
10796         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
10797
10798 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10799
10800         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
10801         compile test, for Tru64 4.0D.
10802
10803 2006-05-28  Karl Berry  <karl@gnu.org>
10804
10805         * config/srclist.txt (printf-args.c): lose sync.
10806
10807 2006-05-26  Martin Lambers  <marlam@marlam.de>
10808
10809         * lib/getpass.c: Updates the test for the native W32 API, and adds
10810         missing includes, thus fixing compilation warnings.
10811
10812 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
10813
10814         * lib/exclude.c (exclude_fnmatch): New function.
10815         (excluded_file_name): Call exclude_fnmatch.
10816         * lib/exclude.h (excluded_file_name): New prototype
10817
10818 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
10819
10820         * lib/tempname.c (small_open, large_open): New macros.
10821         (__open, __open64) [!_LIBC]: Remove.
10822         (__gen_tempname): Use small_open and large_open instead of __open
10823         and __open64.  This fixes a portability bug on HP-UX 11.11i
10824         reported by Simon Wing-Tang in
10825         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
10826
10827 2006-05-24  Bruno Haible  <bruno@clisp.org>
10828
10829         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
10830         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
10831         Reported by Thorsten Maerz <torte@netztorte.de> via
10832         Aaron Stone <aaron@serendipity.cx>.
10833
10834 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
10835
10836         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
10837         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
10838         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
10839         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
10840         not really conditional on the cache.
10841         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
10842
10843 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
10844
10845         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
10846         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
10847         (my_usleep): Don't mishandle maximum value.
10848
10849 2006-05-19  Jim Meyering  <jim@meyering.net>
10850
10851         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
10852
10853 2006-05-17  Bruno Haible  <bruno@clisp.org>
10854
10855         Cygwin portability.
10856         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
10857
10858 2006-05-17  Bruno Haible  <bruno@clisp.org>
10859
10860         * lib/stdint_.h: Fix recognition of Cygwin.
10861
10862 2006-05-15  Bruno Haible  <bruno@clisp.org>
10863
10864         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
10865         on libtool patch by Ralf Wildenhues.
10866
10867 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
10868
10869         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
10870         test for C99 conformance; (bool) 0.5 is an integer constant
10871         expression, but (bool) -0.5 is not.  Problem reported by Fedor
10872         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
10873
10874 2006-05-11  Simon Josefsson  <jas@extundo.com>
10875
10876         * m4/xvasprintf.m4: Fix obvious typo.
10877
10878 2006-05-11  Jim Meyering  <jim@meyering.net>
10879
10880         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
10881         James Lemley.
10882
10883 2006-05-10  Simon Josefsson  <jas@extundo.com>
10884
10885         * lib/md4.c: Typo fix, update copyright years.
10886         (K1, K2): Don't use L because it turn computations into 64-bit on
10887         64-bit platforms.
10888
10889 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
10890
10891         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
10892         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
10893         unwanted sign propagation, e.g., on hosts with 64-bit int.
10894         There still are some problems with reeelly weird theoretical hosts
10895         (e.g., 33-bit int) but it's not worth worrying about now.
10896         * lib/sha1.c (rol): Likewise.
10897         (K1, K2, K3, K4): Remove unnecessary L suffix.
10898
10899 2006-05-10  Bruno Haible  <bruno@clisp.org>
10900
10901         * lib/des.c: Cast to avoid warnings.
10902
10903 2006-05-09  Bruno Haible  <bruno@clisp.org>
10904
10905         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
10906         (Depends-on): Depend also on xsize, stdarg.
10907         (configure.ac): Add gl_XVASPRINTF.
10908
10909 2006-05-09  Bruno Haible  <bruno@clisp.org>
10910
10911         * m4/xvasprintf.m4: New file.
10912
10913 2006-05-09  Bruno Haible  <bruno@clisp.org>
10914
10915         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
10916         (EOVERFLOW): Define fallback value.
10917         (xstrcat): New function.
10918         (xvasprintf): Recognize the special case of a string concatenation.
10919
10920 2006-05-08  Eric Blake  <ebb9@byu.net>
10921
10922         * gnulib-tool (func_version): Base copyright year on CVS date.
10923         (func_emit_copyright_notice): New function.
10924         (func_emit_lib_Makefile_am): Use it.
10925         (func_emit_tests_Makefile_am): Likewise.
10926         (func_import): Likewise.
10927
10928 2006-05-08  Bruno Haible  <bruno@clisp.org>
10929
10930         * modules/stdarg: New file.
10931         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
10932
10933 2006-05-08  Bruno Haible  <bruno@clisp.org>
10934
10935         * m4/stdarg.m4: New file, from GNU gettext.
10936
10937 2006-05-08  Bruno Haible  <bruno@clisp.org>
10938
10939         * config/srclist.txt (build-aux/config.rpath): different from latest
10940         release.
10941
10942 2006-05-08  Bruno Haible  <bruno@clisp.org>
10943
10944         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
10945
10946 2006-05-05  Jim Meyering  <jim@meyering.net>
10947
10948         * m4/warning.m4: New file, derived from bison's file by the same name.
10949
10950 2006-05-03  Bruno Haible  <bruno@clisp.org>
10951
10952         * lib/stdint_.h: Shorter URL.
10953         * lib/inttypes.h: Likewise.
10954
10955 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10956
10957         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
10958
10959 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10960
10961         * lib/verify.h: Document the internals better.  Most of this change
10962         was written by Bruno Haible.
10963
10964 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10965
10966         * doc/verify.texi: New file, partly based on a proposal by
10967         Bruno Haible.
10968
10969 2006-05-02  Bruno Haible  <bruno@clisp.org>
10970
10971         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
10972         test from here...
10973         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
10974
10975 2006-04-29  Bruno Haible  <bruno@clisp.org>
10976
10977         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
10978         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
10979
10980 2006-04-29  Bruno Haible  <bruno@clisp.org>
10981
10982         * gnulib-tool: Make --update option actually work.
10983
10984 2006-04-29  Bruno Haible  <bruno@clisp.org>
10985
10986         * doc/gcd.texi: New file.
10987         * doc/gnulib.texi: Include it.
10988
10989 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
10990
10991         * lib/getdate.y (get_date): When adding relative date, start with the
10992         initial time, not with the result of the first mktime call.
10993
10994 2006-04-25  Bruno Haible  <bruno@clisp.org>
10995
10996         * gnulib-tool (func_import): Output the include directives in three
10997         blocks, sorted separately.
10998         Reported by Ben Pfaff <blp@cs.stanford.edu>.
10999
11000 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
11001
11002         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
11003         to define main with arguments, for C++.  Reported by Eric Blake.
11004         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
11005         Prefer 'int main ()' to 'int main (void)', for C++.
11006         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
11007         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
11008         for 'main', for C99 and C++.
11009
11010 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
11011
11012         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
11013         Don't assume that exit status -1 is valid.
11014         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
11015         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
11016         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
11017         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
11018         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
11019         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
11020         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
11021         functions can be used without declaring them, or that you can
11022         exit with status -1.
11023         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
11024
11025 2006-04-24  Karl Berry  <karl@gnu.org>
11026
11027         * config/srclist.txt (longdouble.m4): sync lost.
11028
11029 2006-04-24  Eric Blake  <ebb9@byu.net>
11030
11031         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
11032
11033 2006-04-24  Bruno Haible  <bruno@clisp.org>
11034
11035         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
11036         poll() implementation in AIX.
11037         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11038
11039 2006-04-24  Bruno Haible  <bruno@clisp.org>
11040
11041         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
11042         assigned exactly once.
11043
11044 2006-04-23  Claudio Fontana  <claudio@gnu.org>
11045             Bruno Haible  <bruno@clisp.org>
11046
11047         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
11048         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
11049         for AM_CPPFLAGS.
11050
11051 2006-04-23  Bruno Haible  <bruno@clisp.org>
11052
11053         * modules/copy-file: Depend on unistd.
11054         * modules/execute: Likewise.
11055         * modules/fatal-signal: Likewise.
11056         * modules/findprog: Likewise.
11057         * modules/mkdtemp : Likewise.
11058         * modules/pipe: Likewise.
11059         * modules/wait-process: Likewise.
11060
11061 2006-04-23  Bruno Haible  <bruno@clisp.org>
11062
11063         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
11064         condition was already detected.
11065         Reported by Ben Pfaff <blp@cs.stanford.edu>.
11066
11067 2006-04-23  Bruno Haible  <bruno@clisp.org>
11068
11069         * lib/copy-file.c: Include <unistd.h> unconditionally.
11070         * lib/execute.c: Likewise.
11071         * lib/fatal-signal.c: Likewise.
11072         * lib/findprog.c: Likewise.
11073         * lib/mkdtemp.c: Likewise.
11074         * lib/pipe.h: Likewise.
11075         * lib/pipe.c: Likewise.
11076         * lib/wait-process.h: Likewise.
11077
11078 2006-04-23  Bruno Haible  <bruno@clisp.org>
11079
11080         * gnulib-tool (func_usage): Fix --import description. Document
11081         --update.
11082         (func_import): Create temporary file in a temporary directory, if
11083         --dry-run is specified. Silence errors from 'grep' when there are no
11084         m4 files in $m4dir.
11085         (func_create_testdir): Silence errors from 'grep' when there are no
11086         m4 files in $m4dir.
11087         Reported by Karl Berry <karl@freefriends.org>.
11088
11089 2006-04-20  Bruno Haible  <bruno@clisp.org>
11090
11091         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
11092         one argument, so that the code will be portable to Autoconf 2.60.
11093         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
11094         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
11095         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
11096
11097 2006-04-19  Derek Price  <derek@ximbiot.com>
11098             Eric Blake  <ebb9@byu.net>
11099
11100         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
11101         rather than "/full/path.h".  Update comment to match.  Shorten &
11102         generalize m4_translit call via AS_TR_CPP.
11103
11104 2006-04-19  Derek Price  <derek@ximbiot.com>
11105             Eric Blake  <ebb9@byu.net>
11106
11107         * lib/inttypes.h: Correct grammar in comment.
11108
11109 2006-04-18  Derek Price  <derek@ximbiot.com>
11110             Paul Eggert  <eggert@cs.ucla.edu>
11111
11112         * modules/inttypes: New file.
11113         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
11114
11115 2006-04-18  Derek Price  <derek@ximbiot.com>
11116             Paul Eggert  <eggert@cs.ucla.edu>
11117
11118         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
11119         New files.
11120
11121 2006-04-18  Derek Price  <derek@ximbiot.com>
11122             Paul Eggert  <eggert@cs.ucla.edu>
11123
11124         * lib/inttypes.h: New file.
11125         * lib/strtoimax.c: Assume <inttypes.h>.
11126
11127 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
11128
11129         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
11130         isn't mounted.  Problem reported by Kir Kolyshkin.
11131
11132 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
11133
11134         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
11135         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
11136         Derek R. Price.
11137         * lib/regex.h (RE_DUP_MAX): Update comment to match current
11138         implementation.
11139
11140 2006-04-12  Eric Blake  <ebb9@byu.net>
11141
11142         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
11143         is now done automatically by the corresponding Autoconf macro.
11144
11145 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
11146
11147         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
11148         time_r.h.
11149
11150 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11151
11152         Merge regex changes from libc, removing some of our
11153         POSIX-conformance changes that were rejected and redoing them in a
11154         less-intrusive way.
11155
11156         * lib/regcomp.c (re_compile_internal, init_dfa):
11157         Length arg is now size_t, not Idx.  All uses changed.
11158         (peek_token): Forward decl now says internal_function.
11159         (__re_error_msgid, __re_error_msgid_idx):
11160         Now static rather than extern with attribute_hidden.
11161         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
11162         For some reason libc prefers K&R style defns for external functions.
11163         (regerror) [!defined _LIBC]: Likewise.
11164         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
11165         (seek_collating_symbol_entry, lookup_collation_sequence_value):
11166         (build_range_exp, build_collating_symbol):
11167         Use K&R-style defn.
11168         (re_compile_fastmap): Use '\0' to memset, not 0.
11169         (utf8_sb_map): Make the calculations more obvious.
11170         (init_dfa, parse_bracket_exp, build_charclass_op):
11171         Call calloc and cast result, as glibc does.
11172         (init_word_char, fetch_token, peek_token, peek_token_bracket):
11173         (build_range_exp, build_collating_symbol):
11174         Now internal functions.
11175
11176         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
11177
11178         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
11179         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
11180         Don't depend on VMS; depend on __VMS instead, for POSIX
11181         namespace cleanness.
11182         (regoff_t): Define to ssize_t, not long int.
11183
11184         Remove the REG_ macros named below.  Instead, make the old names
11185         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
11186         __USE_GNU_REGEX.
11187         (REG_BACKSLASH_ESCAPE_IN_LISTS):
11188         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
11189         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
11190         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
11191         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
11192         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
11193         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
11194         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
11195         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
11196         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
11197         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
11198         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
11199         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
11200         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
11201         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
11202         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
11203         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
11204         (REG_NREGS):
11205         Remove.  All uses replaced by the old RE_* names.
11206         (RE_BACKSLASH_ESCAPE_IN_LISTS):
11207         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
11208         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
11209         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
11210         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
11211         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
11212         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
11213         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
11214         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
11215         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
11216         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
11217         Don't bother having these macros be independent of each others'
11218         values, since they no longer exist in the POSIX name space.
11219
11220         Rename the following member names back to their old names,
11221         unless !__USE_GNU_REGEX.  All uses changed back.
11222         (buffer): Renamed from re_buffer.
11223         (allocated): Renamed from re_allocated.
11224         (used): Renamed from re_used.
11225         (syntax): Renamed from re_syntax.
11226         (fastmap): Renamed from re_fastmap.
11227         (translate): Renamed from re_translate.
11228         (can_be_null): Renamed from re_can_be_null.
11229         (regs_allocated): Renamed from re_regs_allocated.
11230         (fastmap_accurate): Renamed from re_fastmap_accurate.
11231         (no_sub): Renamed from re_no_sub.
11232         (not_bol): Renamed from re_not_bol.
11233         (not_eol): Renamed from re_not_eol.
11234         (newline_anchor): Renamed from re_newline_anchor.
11235         (num_regs): Renamed from rm_num_regs.
11236         (start): Renamed from rm_start.
11237         (end): Renamed from rm_end.
11238
11239         (free_state): Move up a bit.
11240
11241         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
11242         #define to be empty.
11243         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
11244         when that is what is intended.
11245         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
11246         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
11247         (MAX): New macro.
11248         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
11249         All uses changed back to re_malloc, etc.  It's now the caller's
11250         responsibility to check for overflow; all callers changed.
11251         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
11252         (re_x2nrealloc): Remove.
11253         (free_state): Remove decl.
11254
11255         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
11256         (re_set_registers, re_exec):
11257         Use K&R-style defn.
11258
11259         2006-01-31  Roland McGrath  <roland@redhat.com>
11260
11261         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
11262         Reported by Mike Frysinger <vapier@gentoo.org>.
11263
11264         2006-01-15  Andreas Jaeger  <aj@suse.de>
11265
11266         [BZ #1950]
11267         * lib/regex_internal.c (re_string_reconstruct): Adjust for
11268         build_wcs_upper_buffer change.
11269         (build_wcs_upper_buffer): Change return type.
11270
11271         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
11272
11273         * lib/regex_internal.h: Include <stdint.h> if available.
11274
11275         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
11276
11277         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
11278
11279         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
11280
11281         * lib/regcomp.c: Adjust for changed secondary hash function.
11282
11283         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
11284
11285         * lib/regex.h: Pretty printing.
11286         Clean up namespace a bit.
11287
11288         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
11289
11290         * lib/regexec.c (update_cur_sifted_state, check_arrival,
11291         check_arrival_add_next_nodes): Avoid using uninitialized variable.
11292
11293         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
11294                     Ulrich Drepper  <drepper@redhat.com>
11295
11296         [BZ #1302]
11297         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
11298         changed.
11299         (bitset_word_t): Renamed from bitset_word.  All uses changed.
11300
11301         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
11302
11303         [BZ #281]
11304         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
11305         * lib/regcomp.c: Remove unnecessary uses of
11306         unsigned RE_TRANSLATE_TYPE.
11307         * lib/regex_internal.h: Likewise.
11308         * lib/regex_internal.c: Likewise.
11309         * lib/regexec.c: Likewise.
11310         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
11311
11312         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
11313
11314         * lib/regexec.c (find_recover_state): Remove unnecessary
11315         initialization.
11316         (transit_state_bkref): Make DFA a const pointer.
11317         (get_subexp): Likewise.
11318         (check_arrival): Likewise.
11319         (update_cur_sifted_state): Likewise.
11320         (re_search_internal): Likewise.
11321         (prune_impossible_nodes): Likewise.
11322         (acquire_init_state_context): Likewise.
11323         (proceed_next_node): Likewise.
11324         (set_regs): Likewise.
11325         (free_fail_stack_return): Likewise.
11326         (check_arrival_expand_ecl): Mark DFA parameter as const.
11327         (check_arrival_expand_ecl_sub): Likewise.
11328         (check_subexp_limits): Likewise.
11329         (sub_epsilon_src_nodes):  Likewise.
11330         (add_epsilon_src_nodes):  Likewise.
11331         (merge_state_array): Likewise.
11332         (update_regs): Likewise.
11333         (build_trtable): Likewise.
11334         (sift_states_backward): Mark MCTX parameter as const.
11335         (build_sifted_states): Likewise.
11336         (update_cur_sifted_state): Likewise.
11337         (sift_states_mkref): Likewise.
11338         (check_arrival_expand_ecl): Mark eclosure as const.
11339         (check_dst_limits_calc_pos_1): Likewise.
11340         * lib/regex_internal.h (re_match_context_t): Make dfa a const
11341         pointer.
11342
11343         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
11344
11345         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
11346         (transit_state_sb): Likewise.
11347         (transit_state_mb): Likewise.
11348         (sift_states_iter_mb): Likewise.
11349         (check_arrival_add_next_nodes): Likewise.
11350         (check_node_accept_bytes): Change first parameter to pointer-to-const.
11351         [_LIBC] (re_search_2_stub): Use mempcpy.
11352
11353         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
11354         mbrtowc for very simple UTF-8 case.
11355
11356         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
11357         a pointer-to-const.
11358         (re_acquire_state_context): Likewise.
11359         * lib/regex_internal.h: Adjust prototypes.
11360
11361         * lib/regex.c: Prevent using C++ compilers.
11362
11363         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
11364         (re_acquire_state_context): Likewise.
11365
11366 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11367
11368         * modules/regex (Depends-on): Add ssize_t.
11369
11370 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11371
11372         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
11373         translation table.
11374
11375 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11376
11377         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
11378
11379 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
11380             Bruno Haible  <bruno@clisp.org>
11381
11382         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
11383         <sys/types.h> and <inttypes.h>.
11384
11385 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11386
11387         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
11388         `__error_t_defined', so argp.h will not typedef the former.
11389
11390 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
11391
11392         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
11393         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
11394         glibc names.  Even if glibc is changed to conform to POSIX, the
11395         traditional names will be available anyway, since regex depends on
11396         the extensions module.  Also, fix a longstanding typo in the
11397         implementation of Spencer ERE test #75 from grep 2.3.  Problems
11398         reported by Emanuele Giaquinta.  Also, change sense of cached
11399         variable, so that the message makes sense.
11400
11401 2006-03-24  Simon Josefsson  <jas@extundo.com>
11402
11403         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
11404         including some doc fixes.
11405         (base64_encode_alloc): Fix +1 bug on allocation failures.
11406
11407 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11408
11409         * lib/base64.c (base64_encode): Do not read past end of array with
11410         unsanitized input on systems with CHAR_BIT > 8.
11411
11412 2006-03-24  Eric Blake  <ebb9@byu.net>
11413
11414         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
11415
11416 2006-03-22  Karl Berry  <karl@gnu.org>
11417
11418         * config/srclist.txt (*setenv.[ch]): get from coreutils.
11419         * config/srclistvars.sh (COREUTILS): new var.
11420
11421 2006-03-17  Jim Meyering  <jim@meyering.net>
11422
11423         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
11424         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
11425
11426 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
11427
11428         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
11429         no longer needs it.  Instead, check that regoff_t is as least
11430         as wide as ptrdiff_t.
11431
11432         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
11433         so that our regex.h stays compatible with the installed regex.
11434         This is helpful for installers who configure --without-included-regex.
11435         Problem reported by Emanuele Giaquinta.
11436
11437 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
11438
11439         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
11440         Typedef to long int, not to off_, as POSIX will likely change
11441         in that direction.
11442
11443 2006-03-15  Eric Blake  <ebb9@byu.net>
11444
11445         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
11446
11447 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
11448
11449         * lib/argp-help.c (validate_uparams): Fix typo
11450         * lib/argp-parse.c (argp_default_options): Consistently begin help
11451         messages with a lowercase letter.
11452
11453 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
11454
11455         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
11456         overrun buffers and shouldn't be used (much as gets shouldn't be
11457         used).
11458         * lib/time_r.c (asctime_r, ctime_r): Likewise.
11459
11460 2006-03-08  Simon Josefsson  <jas@extundo.com>
11461
11462         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
11463         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11464
11465 2006-03-08  Simon Josefsson  <jas@extundo.com>
11466
11467         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
11468         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11469
11470 2006-03-08  Simon Josefsson  <jas@extundo.com>
11471
11472         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
11473         signal that configure disabled the device.
11474
11475 2006-03-08  Simon Josefsson  <jas@extundo.com>
11476
11477         * build-aux/maint.mk: Fix refresh-po, to handle no translated
11478         languages.
11479
11480 2006-03-07  Simon Josefsson  <jas@extundo.com>
11481
11482         * modules/getopt (Depends-on): Add unistd.
11483
11484         * modules/unistd: New file.
11485
11486 2006-03-07  Simon Josefsson  <jas@extundo.com>
11487
11488         * modules/gc-random: New file.
11489
11490 2006-03-07  Simon Josefsson  <jas@extundo.com>
11491
11492         * m4/unistd_h.m4: New file.
11493
11494 2006-03-07  Simon Josefsson  <jas@extundo.com>
11495
11496         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
11497         test to be side-effect free by storing the result in the cache
11498         variable gl_cv_lib_readline, and moving the assignment of
11499         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
11500         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11501
11502 2006-03-07  Simon Josefsson  <jas@extundo.com>
11503
11504         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
11505         error on missing devices (the functions will return an error).
11506
11507         * m4/gc.m4: Move random stuff to gc-random.m4
11508
11509 2006-03-07  Simon Josefsson  <jas@extundo.com>
11510
11511         * lib/unistd_.h: New file.
11512
11513 2006-03-07  Simon Josefsson  <jas@extundo.com>
11514
11515         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
11516
11517 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
11518
11519         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
11520         Problem reported by Juan Manuel Guerrero.
11521
11522 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
11523
11524         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
11525         the unistd module.
11526         * lib/getlogin_r.c: Likewise.
11527         * lib/getlogin_r.h: Likewise.
11528         * lib/glob.c: Likewise.
11529         * lib/pagealign_alloc.c: Likewise.
11530         * lib/unistd_.h: Remove; no longer needed.
11531
11532 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
11533
11534         * MODULES.html.sh (Support for systems lacking POSIX:2001):
11535         Add unistd.
11536         * modules/c-stack (Depends-on): Add unistd.
11537         * modules/getlogin_r: Likewise.
11538         * modules/glob: Likewise.
11539         * modules/pagealign_alloc: Likewise.
11540         * modules/unistd (Files): Remove lib/unistd_.h.
11541         (EXTRA_DIST): Remove.
11542         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
11543         need unistd_.h.
11544         (MOSTLYCLEANFILES): Remove unistd.h-t.
11545
11546 2006-03-03  Simon Josefsson  <jas@extundo.com>
11547
11548         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
11549
11550 2006-03-03  Simon Josefsson  <jas@extundo.com>
11551
11552         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
11553         libidn and bison.
11554
11555 2006-03-03  Simon Josefsson  <jas@extundo.com>
11556
11557         * build-aux/maint.mk: Add indent target.
11558
11559 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
11560
11561         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
11562         our replacement poll.h in any case, to avoid a differing
11563         declaration from a system header.  Seen on AIX.
11564
11565 2006-03-01  Simon Josefsson  <jas@extundo.com>
11566
11567         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
11568         <kasal@ucw.cz>.
11569
11570 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
11571
11572         * modules/gettime (Depends-on): Add extensions module.
11573         * modules/nanosleep (Depends-on): Likewise.
11574         * modules/settime (Depends-on): Likewise.
11575
11576 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
11577
11578         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
11579         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
11580         pedantically.
11581         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
11582         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
11583
11584         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
11585         not "==".  Reported by Ralf Wildenhues.
11586
11587 2006-03-01  Karl Berry  <karl@gnu.org>
11588
11589         * doc/Copyright/request-*: new files, synced from gnuorg.
11590
11591 2006-03-01  Karl Berry  <karl@gnu.org>
11592
11593         * config/srclist.txt (Copyright/*): new entries.
11594
11595 2006-02-28  Simon Josefsson  <jas@extundo.com>
11596
11597         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
11598
11599 2006-02-27  Simon Josefsson  <jas@extundo.com>
11600
11601         * lib/base64.h: Indent #define's.  From Jim Meyering
11602         <jim@meyering.net>.
11603
11604 2006-02-27  Jim Meyering  <jim@meyering.net>
11605
11606         Revert the change of 2006-02-24, so these files can continue
11607         to be sync'd from gettext.
11608         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
11609         of `config.h'.
11610
11611 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
11612
11613         * modules/intprops: New file.
11614         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
11615         Add intprops.
11616         * modules/getloadavg (Files): Remove lib/intprops.h.
11617         (Depends-on): Add intprops.
11618         * modules/human: Likewise.
11619         * modules/inttostr: Likewise.
11620         * modules/openat: Likewise.
11621         * modules/sig2str: Likewise.
11622         * modules/userspec: Likewise.
11623         * modules/utimecmp: Likewise.
11624         * modules/xnanosleep: Likewise.
11625         * modules/xstrtol: Likewise.
11626
11627 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
11628
11629         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
11630         * modules/lock-tests (TESTS): Use $(EXEEXT).
11631         * modules/tls-tests: Likewise.
11632         * modules/argp-tests: Likewise.
11633         (check_PROGRAMS): New var, replacing...
11634         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
11635
11636 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11637
11638         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
11639         `config.h'.
11640
11641 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
11642
11643         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
11644
11645 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11646
11647         Sync from coreutils.
11648         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
11649         gl_CHDIR_SAFER.
11650
11651 2006-02-22  Jim Meyering  <jim@meyering.net>
11652
11653         Sync from coreutils.
11654         * m4/chdir-safer.m4: New file.
11655
11656 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
11657
11658         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
11659         AT_FDCWD exceeds INT_MAX.
11660         * lib/openat.h (AT_FDCWD): Likewise.
11661
11662 2006-02-17  Eric Blake  <address@hidden>
11663
11664         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
11665
11666 2006-02-16  Simon Josefsson  <jas@extundo.com>
11667
11668         * modules/getaddrinfo (Depends-on): Add sys_socket.
11669
11670 2006-02-15  Simon Josefsson  <jas@extundo.com>
11671
11672         * build-aux/maint.mk: Add dsyntax-check rule.
11673
11674 2006-02-15  Eric Blake  <ebb9@byu.net>
11675
11676         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
11677         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
11678         'present but cannot compile' warnings on cygwin.
11679         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
11680         use ws2tcpip.h if sys/socket.h works.
11681         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
11682         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
11683
11684 2006-02-14  Simon Josefsson  <jas@extundo.com>
11685
11686         * modules/maintainer-makefile (Files): Rename.
11687
11688         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
11689         and (the local) Makefile.cfg to maint-cfg.mk.
11690
11691         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
11692         to the latter.
11693
11694         * modules/maintainer-makefile: New module.
11695
11696         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
11697         severaly stripped to make it possible to build it up from scratch
11698         with reliable tests.
11699
11700         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
11701         fixes to permit overriding the default actions when configure and
11702         makefile are not available.
11703
11704 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
11705
11706         Sync from coreutils.
11707         * modules/lstat (Depends-on): Don't depend on xalloc.
11708         (License): Change from GPL to LGPL, since this is now simply a
11709         replacement for a libc function.
11710
11711 2006-02-14  Jim Meyering  <jim@meyering.net>
11712
11713         Sync from coreutils.
11714
11715         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
11716         failure on deficient systems, and simplify gnulib lgpl dependencies.
11717         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
11718         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
11719
11720         * lib/xalloc-die.c: Remove unused definition of N_.
11721
11722 2006-02-14  Jim Meyering  <jim@meyering.net>
11723
11724         Sync from coreutils.
11725         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
11726         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
11727         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
11728         double-quote uses of that variable, to accommodate the rare case in
11729         which getmntent is available in none of the libraries checked.  This
11730         happens at least on FreeBSD 5.0.
11731
11732 2006-02-13  Simon Josefsson  <jas@extundo.com>
11733
11734         * gnulib-tool (Usage): Fix --import, from
11735         karl@freefriends.org (Karl Berry).
11736
11737 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
11738
11739         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
11740
11741 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
11742
11743         * lib/argp-namefrob.h: Restore changes accidentally lost during the
11744         "autoupdate" on 2005-12-12.
11745
11746 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
11747
11748         * modules/closeout (Depends-on): Remove atexit.
11749
11750 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
11751
11752         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
11753         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
11754
11755 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
11756
11757         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
11758         __EXTENSIONS__ if this causes compilation to fail.  Problem
11759         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
11760         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
11761
11762 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
11763
11764         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
11765         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
11766         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
11767         All uses changed.
11768
11769 2006-01-26  Simon Josefsson  <jas@extundo.com>
11770
11771         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
11772         prototype is visible on mingw32.
11773
11774         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
11775         for mingw32.
11776
11777         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
11778         mingw32).
11779
11780 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
11781
11782         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
11783         attempt to open for write; this always fails, at least on POSIX
11784         hosts.  This reinstates the 2006-01-09 change, which was
11785         inadvertently removed.
11786
11787 2006-01-26  Bruno Haible  <bruno@clisp.org>
11788
11789         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
11790         Reported by Paul Eggert.
11791
11792 2006-01-26  Bruno Haible  <bruno@clisp.org>
11793             Paul Eggert  <eggert@cs.ucla.edu>
11794
11795         * lib/stdbool_.h (_Bool)
11796         [(! (defined __cplusplus || defined __BEOS__)
11797           && !defined __GNUC__
11798           && !(defined __HP_cc || defined __xlc__
11799                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
11800                || defined __sgi))]:
11801         #define to signed char in these cases too; this simplifies
11802         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
11803         etc., separately) and makes it more conservative.
11804
11805 2006-01-25  Simon Josefsson  <jas@extundo.com>
11806
11807         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
11808         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
11809         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
11810
11811 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
11812
11813         * lib/argp-namefrob.h: Bugfix. Remove stray #
11814
11815 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
11816
11817         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
11818         so that we test the test.
11819         Check for yet another HP-UX cc bug involving *bool |= bool.
11820
11821 2006-01-25  Karl Berry  <karl@gnu.org>
11822
11823         * config/srclist.txt (vasnprintf.c): sync lost.
11824
11825 2006-01-25  Jim Meyering  <jim@meyering.net>
11826
11827         Sync from the stable (b5) branch of coreutils:
11828
11829         * lib/fts.c (fts_children): Don't let close() clobber errno from
11830         failed fchdir().
11831
11832         * lib/fts.c (fts_stat): When following a symlink-to-directory,
11833         don't necessarily interpret stat-fails+lstat-succeeds as indicating
11834         a dangling symlink.  That can also happen at least for ELOOP.
11835         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
11836         FYI, this bug predates the inclusion of fts.c in coreutils.
11837
11838         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
11839         in their own block, so pre-c99 compilers don't object.
11840
11841         Avoid the double-free (first in fts_read, second in fts_close) that
11842         would occur when an `active' directory is made inaccessible (e.g.,
11843         via chmod a-x) during a traversal.
11844         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
11845         before returning.  Reproduce this failure by
11846         mkdir -p a/b; cd a; chmod a-x . b
11847         Reported by Stavros Passas.
11848
11849 2006-01-25  Jim Meyering  <jim@meyering.net>
11850
11851         * lib/fileblocks.c: Remove more useless parentheses.
11852         * lib/readutmp.h: Likewise.
11853
11854 2006-01-25  Bruno Haible  <bruno@clisp.org>
11855
11856         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
11857         warnings.
11858         Reported by Paul Eggert.
11859
11860 2006-01-25  Bruno Haible  <bruno@clisp.org>
11861
11862         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
11863         rid of a trap command. For Solaris sh.
11864         Reported by Mark D. Baushke <mdb@gnu.org>.
11865
11866 2006-01-24  Simon Josefsson  <jas@extundo.com>
11867
11868         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
11869         Bruno.
11870
11871 2006-01-24  Karl Berry  <karl@gnu.org>
11872
11873         * config/srclist.txt (argp-namefrob.h): sync lost.
11874
11875 2006-01-24  Jim Meyering  <jim@meyering.net>
11876
11877         * modules/openat (Files): Add lib/intprops.h.
11878         From Mark D. Baushke.
11879
11880 2006-01-24  Jim Meyering  <jim@meyering.net>
11881
11882         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
11883         Reported by Mark D. Baushke.
11884
11885 2006-01-24  Jim Meyering  <jim@meyering.net>
11886
11887         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
11888
11889 2006-01-24  Bruno Haible  <bruno@clisp.org>
11890
11891         * modules/strnlen (Maintainer): Change from glibc to all.
11892
11893 2006-01-24  Bruno Haible  <bruno@clisp.org>
11894
11895         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
11896         Patch by Paul Eggert.
11897
11898 2006-01-24  Bruno Haible  <bruno@clisp.org>
11899
11900         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
11901         already has it.
11902         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
11903         2005-11-26.
11904
11905         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
11906         'signed char' to avoid problems with the built-in _Bool type.
11907         Reported by Paul Eggert on 2005-11-26.
11908
11909 2006-01-24  Bruno Haible  <bruno@clisp.org>
11910
11911         * gnulib-tool (func_import): Avoid constructing complicated sed
11912         expressions inside backquote.
11913         Report and solution by Mark D. Baushke <mdb@gnu.org>.
11914
11915 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
11916
11917         These changes imported from libc.
11918         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
11919         test and two separate function calls.
11920         * lib/strndup.c (__strndup): Add libc_hidden_def.
11921
11922 2006-01-23  Simon Josefsson  <jas@extundo.com>
11923
11924         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
11925         Remove the test_*_SOURCES variable: automake infers it by default.
11926         * modules/tls-tests: Likewise.
11927
11928 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11929
11930         Work around porting bugs reported by Dieter in
11931         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
11932         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
11933         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
11934         Include "getopt.h" first, to check interface.
11935         (getenv): Declare only if defined HAVE_DECL_GETENV &&
11936         !HAVE_DECL_GETENV.
11937         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
11938         (__strndup): Revert to K&R-style function dfns, the glibc style.
11939         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
11940         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
11941         Include strnlen.h first, to get prototype properly.
11942         (strnlen): Renamed from __strnlen.
11943         Remove weak alias.
11944
11945 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11946
11947         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
11948
11949 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11950
11951         * config/srclist.txt: Adjust to reflect glibc reorganization.
11952         This affects only comments.
11953
11954 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11955
11956          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
11957          Reported by Bruce Korb <bkorb@gnu.org>.
11958
11959 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
11960
11961         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
11962         to pacify gcc -Wswitch-default.
11963
11964 2006-01-22  Bruno Haible  <bruno@clisp.org>
11965
11966         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
11967         temporary buffer for sprintf, take into account the precision also
11968         for 'd', 'i', 'u', 'o', 'x', 'X'.
11969
11970 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
11971
11972         * modules/argp-tests: New module
11973         * tests/test-argp.c: New file
11974         * tests/test-argp-2.sh: New file
11975
11976 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
11977
11978         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
11979         (__argp_base_name): Removed
11980         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
11981         typo.
11982         (__argp_base_name): Provide macro definition or extern declaration
11983         depending on the configuration
11984
11985 2006-01-20  Simon Josefsson  <jas@extundo.com>
11986
11987         * modules/inet_ntop (Depends-on): Depend on sys_socket.
11988
11989 2006-01-20  Simon Josefsson  <jas@extundo.com>
11990
11991         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
11992
11993 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
11994
11995         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
11996         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
11997         Suggested by Bruno Haible.
11998
11999 2006-01-20  Karl Berry  <karl@gnu.org>
12000
12001         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
12002         until changes propagate, I guess.
12003
12004 2006-01-19  Simon Josefsson  <jas@extundo.com>
12005
12006         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
12007
12008 2006-01-19  Simon Josefsson  <jas@extundo.com>
12009
12010         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
12011
12012 2006-01-19  Simon Josefsson  <jas@extundo.com>
12013
12014         * gnulib-tool: Set check_PROGRAMS.
12015
12016         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
12017         modules/des-tests, modules/gc-arcfour-tests,
12018         modules/gc-arctwo-tests, modules/gc-des-tests,
12019         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
12020         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
12021         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
12022         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
12023         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
12024         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
12025         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
12026         test_*_SOURCES.
12027
12028 2006-01-18  Simon Josefsson  <jas@extundo.com>
12029
12030         * modules/socklen (Depends-on): Depend on sys_socket.
12031
12032 2006-01-18  Simon Josefsson  <jas@extundo.com>
12033
12034         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
12035         modules/des-tests, modules/gc-arcfour-tests,
12036         modules/gc-arctwo-tests, modules/gc-des-tests,
12037         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
12038         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
12039         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
12040         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
12041         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
12042         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
12043         $(EXEEXT) to automake TESTS variable, for mingw32.
12044
12045 2006-01-17  Simon Josefsson  <jas@extundo.com>
12046
12047         * modules/socklen (Include): Need sys/socket.h.
12048
12049 2006-01-17  Bruno Haible  <bruno@clisp.org>
12050
12051         * modules/ssize_t (Include): Add <sys/types.h>.
12052
12053 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
12054
12055         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
12056         it's not portable and it doesn't work with cross-compiles.
12057         Problem reported by Bruno Haible.  Fix missing-$ typo in
12058         'test "gl_cv_ignore_unused_libraries" ...' that prevented
12059         -zignore from being used with Sun's C compiler.
12060
12061 2006-01-12  Simon Josefsson  <jas@extundo.com>
12062
12063         * lib/base64.c: Fix warning, reported by Bruno Haible
12064         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
12065
12066 2006-01-12  Bruno Haible  <bruno@clisp.org>
12067
12068         * modules/ldd: New file.
12069         * build-aux/ldd.sh.in: New file.
12070         * MODULES.html.sh (Support for building libraries and executables): Add
12071         ldd.
12072
12073 2006-01-12  Bruno Haible  <bruno@clisp.org>
12074
12075         * m4/ldd.m4: New file.
12076
12077 2006-01-12  Bruno Haible  <bruno@clisp.org>
12078
12079         * gnulib-tool (func_import, func_create_testdir): Don't go into an
12080         endless loop while replacing $auxdir with build-aux.
12081
12082 2006-01-11  Simon Josefsson  <jas@extundo.com>
12083
12084         * lib/stdint_.h (SIZE_MAX): Add missing (.
12085
12086 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
12087
12088         Sync from coreutils.
12089         * lib/md5.c: Fix commentary typos.
12090         (alignof, UNALIGNED_P): No need for a GCC-specific version.
12091         * lib/md5.h (__attribute__): Remove; unused.
12092         * lib/sha1.c: Fix commentary to match md5 better.
12093         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
12094         so that we don't need to worry about alignment.  All uses changed.
12095         This merges the 2005-10-28 md5 change into sha1.
12096
12097 2006-01-11  Jim Meyering  <jim@meyering.net>
12098
12099         Sync from coreutils.
12100         * lib/md5.c (OP): Fix spacing.
12101
12102 2006-01-11  Bruno Haible  <bruno@clisp.org>
12103
12104         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12105         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
12106         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
12107
12108 2006-01-11  Bruno Haible  <bruno@clisp.org>
12109
12110         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12111         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
12112         the "early" section as well.
12113
12114 2006-01-11  Bruno Haible  <bruno@clisp.org>
12115
12116         Avoid "ar: no archive members specified" error on MacOS X.
12117         * gnulib-tool (func_modules_add_dummy): New function.
12118         (func_import, func_create_testdir): Invoke it.
12119
12120 2006-01-11  Bruno Haible  <bruno@clisp.org>
12121
12122         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
12123         with $auxdir in AC_CONFIG_FILES statements.
12124
12125 2006-01-11  Bruno Haible  <bruno@clisp.org>
12126
12127         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12128         Initialize also noinst_HEADERS to empty.
12129
12130 2006-01-11  Bruno Haible  <bruno@clisp.org>
12131
12132         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
12133         variables.
12134         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
12135         autoreconf.
12136
12137 2006-01-11  Bruno Haible  <bruno@clisp.org>
12138
12139         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
12140         overridable by the user.
12141         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12142
12143 2006-01-10  Simon Josefsson  <jas@extundo.com>
12144
12145         * modules/sys_socket: New file.
12146
12147 2006-01-10  Simon Josefsson  <jas@extundo.com>
12148
12149         * m4/sys_socket_h.m4: New file.
12150
12151 2006-01-10  Simon Josefsson  <jas@extundo.com>
12152
12153         * lib/socket_.h: New file.
12154
12155 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12156
12157         * modules/readutmp (Maintainer): Add myself.
12158
12159 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12160
12161         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
12162         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
12163         People who are still concerned with buggy memcmp implementations
12164         can invoke gl_FUNC_MEMCMP themselves.
12165
12166 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12167
12168         * lib/regex_internal.h (BITSET_WORD_BITS):
12169         Work around a bug in 64-bit PGC (before version 6.1-2), where the
12170         preprocessor mishandles large unsigned values as if they were signed.
12171         Problem reported by Claudio Fontana in
12172         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
12173
12174 2006-01-10  Jim Meyering  <jim@meyering.net>
12175
12176         Avoid the double-free (first in fts_read, second in fts_close) that
12177         would occur when an `active' directory is made inaccessible (e.g.,
12178         via chmod a-x) during a traversal.
12179         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
12180         before returning.  Reproduce this failure by
12181         mkdir -p a/b; cd a; chmod a-x . b
12182         Reported by Stavros Passas.
12183
12184         Sync from coreutils.
12185         * lib/sha1.c: Tweak grammar in a comment.
12186
12187 2006-01-10  Jim Meyering  <jim@meyering.net>
12188
12189         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
12190         Patch by Joerg Sonnenberger.
12191
12192 2006-01-10  Bruno Haible  <bruno@clisp.org>
12193
12194         * modules/readutmp: Depend on module free.
12195         * modules/strtok_r: Depend on module restrict.
12196
12197 2006-01-10  Bruno Haible  <bruno@clisp.org>
12198
12199         * modules/gettext (configure.ac): Add an invocation of
12200         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
12201
12202 2006-01-10  Bruno Haible  <bruno@clisp.org>
12203
12204         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
12205         Reported by Werner Lemberg <wl@gnu.org>.
12206
12207 2006-01-10  Bruno Haible  <bruno@clisp.org>
12208
12209         * lib/localcharset.c: Update from GNU gettext.
12210
12211 2006-01-10  Bruno Haible  <bruno@clisp.org>
12212
12213         * lib/argp.h (__const): Remove macro. Use const instead.
12214         * lib/argp-fmtstream.h (__const): Likewise.
12215         * lib/glob_.h (__const): Remove macro.
12216         * lib/glob-libc.h: Use const instead of __const.
12217
12218 2006-01-10  Bruno Haible  <bruno@clisp.org>
12219
12220         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
12221         variable.
12222         Needed to avoid an automake error regarding the 'gettext' module.
12223
12224 2006-01-09  Simon Josefsson  <jas@extundo.com>
12225
12226         * modules/inet_ntop (Depends-on): Add restrict.
12227
12228 2006-01-09  Simon Josefsson  <jas@extundo.com>
12229
12230         * modules/gc-rijndael-tests (License): Put under LGPL.
12231
12232         * modules/gc-des-tests (License): Likewise.
12233
12234         * modules/gc-arcfour-tests (License): Likewise.
12235
12236         * modules/gc-arctwo-tests (License): Likewise.
12237
12238         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
12239
12240         * modules/gc-hmac-sha1-tests (Files): Likewise.
12241
12242         * modules/gc-hmac-md5-tests (License): Likewise.
12243
12244         * modules/gc-sha1-tests (License): Likewise.
12245
12246         * modules/gc-md5-tests (License): Likewise.
12247
12248         * modules/gc-md4-tests (License): Likewise.
12249
12250         * modules/gc-md2-tests (License): Likewise.
12251
12252         * modules/gc-tests (License): Likewise.
12253
12254         * modules/des-tests (License): Likewise.
12255
12256         * modules/md4-tests (License): Likewise.
12257
12258         * modules/md2-tests (License): Likewise.
12259
12260 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12261
12262         Sync from coreutils:
12263
12264         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
12265         * modules/lib-ignore: New file.
12266         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
12267         chdir-safer.m4, lchmod.m4.
12268         * modules/openat: Add mkdirat.c, openat-priv.h.
12269
12270 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12271
12272         Sync from coreutils.
12273         * m4/lib-ignore.m4: New file.
12274         * m4/lchmod.m4: New file.
12275
12276 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12277
12278         Sync from coreutils.
12279         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
12280         for write access: POSIX says that must fail.
12281         * lib/fts.c (diropen): Likewise.
12282         * lib/save-cwd.c (save_cwd): Likewise.
12283         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
12284         well, for minor improvements on hosts that lack O_DIRECTORY.
12285         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
12286         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
12287         Fall back on chown if open failed with EACCES.
12288
12289         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
12290         Report an error at compile-time if only a 1-second nominal clock
12291         resolution is found.
12292
12293         * lib/lchmod.h: New file.
12294         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
12295         (make_dir_parents): Use lchown rather than chown, and
12296         lchmod rather than chmod.
12297
12298         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
12299         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
12300         "proc" reported by n0dalus.
12301
12302         * lib/mountlist.c: Include <limits.h>.
12303         (dev_from_mount_options)
12304         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
12305         New function.  It no longer assumes "dev=" has the System V meaning
12306         on Linux (since it doesn't).  It also parses "dev=" more carefully.
12307         (read_file_system_list)
12308         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
12309         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
12310         dev= in that case.
12311
12312         * lib/posixtm.h (PDS_PRE_2000): New macro.
12313         * lib/posixtm.c (year): Arg is now syntax_bits rather than
12314         allow_century.  All usages changed.  Reject dates outside the range
12315         1969-1999 if PDS_PRE_2000 is used.
12316
12317 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12318
12319         Sync from coreutils.
12320         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
12321         (Time of day items): Mention the possibility of leap seconds.
12322         Problem reported by Dr. David Alan Gilbert.
12323
12324 2006-01-09  Jim Meyering  <jim@meyering.net>
12325
12326         Sync from coreutils.
12327
12328         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
12329
12330         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
12331
12332         * lib/modechange.c (mode_compile): Reject an invalid mode string
12333         that starts with an octal digit.  From Andreas Gruenbacher.
12334
12335         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
12336         and dup to open_safer and dup_safer, respectively.
12337         (openat_permissive): Fix typo in comment.
12338
12339         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
12340         "gettext.h"; either no longer needed or are guaranteed by openat.h.
12341         (_): Remove; no longer needed.
12342         (openat): Renamed from rpl_openat; no need for rpl_openat
12343         since openat.h renames openat for us.
12344         Replace most of the body with a call to openat_permissive,
12345         to avoid duplicate code.
12346         Port to (probably hypothetical) environments were mode_t is
12347         wider than int.
12348         (openat_permissive): Require mode arg, so that we can check
12349         types better.  Put it just after flags.  Change cwd failure
12350         indicator from pointer-to-bool to pointer-to-errno-value.
12351         All callers changed.
12352         Invoke openat_save_fail and/or openat_restore_fail if
12353         cwd_errno is null, so that openat can call us.
12354         (openat_permissive, fdopendir, fstatat, unlinkat):
12355         Simplify errno handling to avoid some duplicate code,
12356         as it's OK to set errno on success.
12357         * lib/openat.h: Revamp code so that function macros depend on
12358         __OPENAT_PREFIX only, not also on AT_FDCWD.
12359         (openat_ro): Remove.  Caller changed to use openat_permissive.
12360         (openat_permissive): Now a macro, if not a function.
12361         (openat_restore_fail, openat_save_fail): Now always functions,
12362         since mkdirat needs them even if __OPENAT_PREFIX is defined.
12363
12364         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
12365         and openat.c.
12366         * lib/mkdirat.c: Include openat-priv.h.
12367         Remove definitions of macros defined therein.
12368         * lib/openat.c: Likewise.
12369
12370         * lib/mkdirat.c (mkdirat): New file and function.
12371         * lib/openat.h (mkdirat): Declare.
12372
12373         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
12374
12375         * lib/openat.h (openat_permissive): Declare.
12376         (openat_ro): Define.
12377
12378         * lib/openat.c (EXPECTED_ERRNO): New macro.
12379         (openat_permissive): New function -- used in remove.c rewrite.
12380         (all functions): Set errno just before returning, only if there
12381         was an actual failure.
12382         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
12383
12384         Emulate openat-family functions using Linux's procfs, if possible.
12385         Idea and some code based on Ulrich Drepper's glibc changes.
12386
12387         * lib/openat.c: (BUILD_PROC_NAME): New macro.
12388         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
12389         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
12390         before falling back on save_cwd and restore_cwd.
12391         (fdopendir, fstatat, unlinkat): Likewise.
12392
12393         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
12394         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
12395
12396         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
12397         as second argument to va_arg.  Otherwise, some versions of gcc
12398         warn that `if this code is reached, the program will abort'.
12399
12400 2006-01-09  Jim Meyering  <jim@meyering.net>
12401
12402         Sync from coreutils.
12403         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
12404         Require openat-priv.h.
12405
12406 2006-01-09  Bruno Haible  <bruno@clisp.org>
12407
12408         * modules/strnlen (Include): Use strnlen.h.
12409
12410 2006-01-09  Bruno Haible  <bruno@clisp.org>
12411
12412         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
12413
12414 2006-01-09  Bruno Haible  <bruno@clisp.org>
12415
12416         * lib/sysexit_.h (EX_OK): New macro.
12417         Suggested by Martin Lambers <marlam@marlam.de>.
12418
12419 2006-01-09  Bruno Haible  <bruno@clisp.org>
12420
12421         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
12422         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
12423
12424 2006-01-09  Bruno Haible  <bruno@clisp.org>
12425
12426         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
12427         numbers.
12428
12429 2006-01-09  Bruno Haible  <bruno@clisp.org>
12430
12431         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
12432         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
12433         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
12434         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
12435
12436 2006-01-09  Bruno Haible  <bruno@clisp.org>
12437
12438         * build-aux/javacomp.sh.in: New file, moved from lib/.
12439         * modules/javacomp-script (Files): Update.
12440         (configure.ac): Add AC_CONFIG_FILES invocation.
12441         (EXTRA_DIST): Remove variable.
12442
12443         * build-aux/javaexec.sh.in: New file, moved from lib/.
12444         * modules/javaexec (Files): Update.
12445         (configure.ac): Add AC_CONFIG_FILES invocation.
12446         (EXTRA_DIST): Remove javaexec.sh.in.
12447
12448         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
12449         * modules/csharpcomp-script (Files): Update.
12450         (configure.ac): Add AC_CONFIG_FILES invocation.
12451         (EXTRA_DIST): Remove variable.
12452
12453         * build-aux/csharpexec.sh.in: New file, moved from lib/.
12454         * modules/csharpexec (Files): Update.
12455         (configure.ac): Add AC_CONFIG_FILES invocation.
12456         (EXTRA_DIST): Remove csharpexec.sh.in.
12457
12458 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
12459
12460         Sync from coreutils.
12461
12462         Add POSIX ACL support
12463         * lib/acl.h (copy_acl, set_acl): Add declarations.
12464         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
12465         systems other than Linux.
12466         (chmod_or_fchmod): New function: use fchmod when possible,
12467         and chmod otherwise.
12468         (file_has_acl): Add a POSIX ACL implementation, with a
12469         Linux-specific subcase.
12470         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
12471         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
12472         acls are unsupported.
12473         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
12474         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
12475         are unsupported.
12476
12477 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
12478
12479         Sync from coreutils.
12480         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
12481
12482 2006-01-07  Bruno Haible  <bruno@clisp.org>
12483
12484         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
12485         gl_EARLY.
12486
12487 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
12488
12489         * lib/strftime.c (tzname): Don't declare if it is already #defined.
12490         Problem reported for Mingw by Mark Junker.
12491
12492 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
12493
12494         * README: Gnulib normally doesn't generate a tarball.
12495
12496 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
12497
12498         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
12499         long int, not int, for nanosecond counts, so that people who are
12500         used to POSIX struct timespec won't be surprised.  Reported by Jim
12501         Meyering.
12502
12503 2005-12-28  Bruno Haible  <bruno@clisp.org>
12504
12505         * build-aux/config.rpath: Update from GNU gettext.
12506
12507 2005-12-16  Jim Meyering  <jim@meyering.net>
12508
12509         * modules/fprintftime: New module.
12510         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
12511
12512 2005-12-16  Jim Meyering  <jim@meyering.net>
12513
12514         * m4/fprintftime.m4: New file.
12515
12516 2005-12-16  Jim Meyering  <jim@meyering.net>
12517
12518         * lib/fprintftime.c, lib/fprintftime.h: New files.
12519
12520 2005-12-15  Simon Josefsson  <jas@extundo.com>
12521
12522         * modules/socklen (configure.ac): Fix M4 macro name, to align with
12523         new m4/socklen.m4.
12524
12525 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
12526
12527         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
12528         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
12529
12530 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
12531
12532         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
12533         * lib/argp-help.c (fill_in_uparams): Check if the constructed
12534         struct uparams is valid. Fall back to the default values if it is
12535         not.
12536
12537 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12538
12539         * modules/argp (Files): Add argp-pin.c
12540         (Depends-on): dirname
12541         (lib_SOURCES): Add argp-pin.c
12542
12543 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12544
12545         * m4/argp.m4:  Check if program_invocation_name and
12546         program_invocation_short_name are declared and define appropriate
12547         macros if they are not.
12548
12549 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12550
12551         * lib/argp-help.c (__argp_base_name): New function
12552         (__argp_short_program_name): Rewrite using __argp_base_name
12553         * lib/argp-namefrob.h: Define program_invocation_name and
12554         program_invocation_short_name if requested
12555         (__argp_base_name): Add prototype
12556         * lib/argp-parse.c (argp_def): Use gettext wrappers
12557         (argp_default_parser): Use __argp_base_name
12558         * lib/argp-pin.c: New file. Defines program_invocation_name and
12559         program_invocation_short_name on systems that lack them.
12560
12561 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
12562
12563         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
12564         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
12565         porting problem reported by Georg Schwarz in
12566         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
12567
12568 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
12569
12570         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
12571         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
12572         porting problem reported by Georg Schwarz in
12573         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
12574
12575 2005-12-05  Bruno Haible  <bruno@clisp.org>
12576
12577         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
12578         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
12579         Reported by Mark Junker <mjscod@gmx.de>.
12580
12581 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
12582
12583         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
12584         Use implementation from Albert Chin, with some
12585         comments/corrections by Stepan Kasal and myself.
12586
12587 2005-12-02  Bruno Haible  <bruno@clisp.org>
12588
12589         * gnulib-tool (func_import): Accept GPLed build tool modules when
12590         --lgpl is given.
12591         * modules/csharpcomp-script: New file.
12592         * modules/csharpcomp: Depend on it.
12593         * modules/javacomp-script: New file.
12594         * modules/javacomp: Depend on it.
12595         Suggested by Simon Josefsson.
12596
12597 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
12598
12599         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
12600         statement, to work around an HP-UX 10.20 compiler bug reported by
12601         Peter O'Gorman.
12602
12603 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
12604
12605         * modules/savedir (Depends-on): Add openat.
12606
12607 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
12608
12609         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
12610         (uintmax_t) [defined uintmax_t]: Do not declare.
12611         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
12612         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
12613         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
12614         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
12615         sake of portability to weird hosts that C allows (though we don't
12616         know of any practical examples).
12617
12618         * lib/savedir.h (fdsavedir): New decl.
12619         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
12620         contains most of the former guts of savedir.
12621         (savedir): Use savedirstream.
12622         Include "openat.h".
12623
12624 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
12625
12626         * modules/obstack (Files): Add m4/ulonglong.m4.
12627         Problem reported by Davide Angelocola.
12628
12629 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
12630
12631         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
12632         coreutils no longer futzes with rounding modes.
12633
12634 2005-11-14  Jim Meyering  <jim@meyering.net>
12635
12636         * lib/mkstemp-safer.c: Include <config.h>, required for possible
12637         replacement of mkstemp.
12638
12639 2005-11-10  Simon Josefsson  <jas@extundo.com>
12640
12641         * lib/readline.c: Remove EOL.
12642
12643 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12644
12645         * modules/gethrxtime (Depends-on): Add gettime.
12646
12647 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12648
12649         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
12650         or gettimeofday; no longer needed.
12651
12652 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12653
12654         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
12655         time business.
12656         (gethrxtime) [! (HAVE_NANOUPTIME
12657         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
12658         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
12659         our own approximation.
12660
12661 2005-11-08  Eric Blake  <ebb9@byu.net>
12662
12663         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
12664
12665 2005-11-08  Eric Blake  <ebb9@byu.net>
12666
12667         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
12668
12669 2005-11-04  Bruno Haible  <bruno@clisp.org>
12670
12671         * gnulib-tool: Implement --update mode.
12672
12673 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
12674
12675         Fix porting problem reported by Theodoros V. Kalamatianos.
12676         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
12677         Don't assume that futimes failing means we must fail.
12678
12679 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
12680
12681         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
12682         variables to suggest the intended function of the PATH_MAX check.
12683
12684 2005-10-30  Kean Johnston  <jkj@sco.com>
12685
12686         Trivial changes to support SCO systems.
12687         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
12688         as PATH_MAX.
12689         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
12690         where __ptr is null when no I/O is pending.
12691
12692 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
12693
12694         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
12695         leave errno alone.  Problem reported by Dmitry V. Levin.
12696
12697 2005-10-28  Simon Josefsson  <jas@extundo.com>
12698
12699         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
12700         Test more.
12701
12702         * tests/test-gc-md2.c, tests/test-md2.c: New files.
12703
12704         * modules/md2, modules/md2-tests: New files.
12705
12706 2005-10-28  Simon Josefsson  <jas@extundo.com>
12707
12708         * m4/inet_ntop.m4: More tests.
12709
12710         * m4/gc-md2.m4, md2.m4: New file.
12711
12712 2005-10-28  Simon Josefsson  <jas@extundo.com>
12713
12714         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
12715         "restrict" keywords, as per POSIX.  Protect the function
12716         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
12717         Don't use K&R prototypes.  Check the sprintf return values.
12718         Re-define EAFNOSUPPORT if not present.  Indent.
12719
12720         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
12721         suggested by Bruno Haible <bruno@clisp.org>.
12722
12723         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
12724
12725         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
12726
12727         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
12728         libgcrypt).
12729
12730         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
12731
12732         * lib/md2.h, lib/md2.c: New files.
12733
12734 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
12735
12736         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
12737         errno alone.  Problem reported by Frederic Jolliton.
12738
12739 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
12740
12741         * modules/verify (License): Change from GPL to LGPL.  This is a
12742         tiny module and there are apparently near-equivalents that are
12743         under the BSD license.
12744
12745 2005-10-24  Simon Josefsson  <jas@extundo.com>
12746
12747         * modules/sha1: Relicense to LGPL.
12748
12749 2005-10-24  Simon Josefsson  <jas@extundo.com>
12750
12751         * lib/md4.h: Shrink buffer size, now that we changed the type.
12752
12753 2005-10-23  Simon Josefsson  <jas@extundo.com>
12754
12755         * gnulib-tool (func_import): Fix --tests-base.
12756
12757 2005-10-22  Simon Josefsson  <jas@extundo.com>
12758
12759         * modules/arcfour (Depends-on): Need stdint.
12760
12761 2005-10-22  Simon Josefsson  <jas@extundo.com>
12762
12763         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
12764         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
12765
12766 2005-10-22  Simon Josefsson  <jas@extundo.com>
12767
12768         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
12769         suggested by Bruno Haible <bruno@clisp.org>.
12770
12771 2005-10-22  Simon Josefsson  <jas@extundo.com>
12772
12773         * lib/crc.h: Include stddef.h, for size_t.
12774
12775 2005-10-22  Simon Josefsson  <jas@extundo.com>
12776
12777         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
12778         arcfour_context struct (simplify test vector testing in GNU
12779         Shishi).
12780
12781 2005-10-21  Simon Josefsson  <jas@extundo.com>
12782
12783         * modules/des, modules/des-tests: New files.
12784
12785         * modules/gc-des, modules/gc-des-tests: New files.
12786
12787         * tests/test-des.c, tests/test-gc-des.c: New file.
12788
12789 2005-10-21  Simon Josefsson  <jas@extundo.com>
12790
12791         * modules/arctwo, modules/arctwo-tests: New files.
12792
12793         * tests/test-arctwo.c: New file.
12794
12795         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
12796
12797         * tests/test-gc-arctwo.c: New file.
12798
12799 2005-10-21  Simon Josefsson  <jas@extundo.com>
12800
12801         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
12802         Bruno Haible <bruno@clisp.org>.
12803
12804         * m4/gc-des.m4: New file.
12805
12806 2005-10-21  Simon Josefsson  <jas@extundo.com>
12807
12808         * m4/arctwo.m4: New file.
12809
12810         * m4/gc-arctwo.m4: New file.
12811
12812 2005-10-21  Simon Josefsson  <jas@extundo.com>
12813
12814         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
12815         block.
12816
12817 2005-10-21  Simon Josefsson  <jas@extundo.com>
12818
12819         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
12820         <bruno@clisp.org>.
12821
12822         * lib/hmac-sha1.c (hmac_sha1): Likewise.
12823
12824         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
12825         Bruno Haible <bruno@clisp.org>.
12826
12827         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
12828         <bruno@clisp.org>.
12829
12830 2005-10-21  Simon Josefsson  <jas@extundo.com>
12831
12832         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
12833
12834 2005-10-21  Simon Josefsson  <jas@extundo.com>
12835
12836         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
12837
12838 2005-10-21  Simon Josefsson  <jas@extundo.com>
12839
12840         * lib/des.h, lib/des.c: New files.
12841
12842         * lib/gc-gnulib.c: Support DES.c
12843
12844 2005-10-21  Simon Josefsson  <jas@extundo.com>
12845
12846         * lib/arctwo.h, lib/arctwo.c: New files.
12847
12848         * lib/gc-gnulib.c: Support ARCTWO.
12849
12850 2005-10-21  Simon Josefsson  <jas@extundo.com>
12851
12852         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
12853         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12854
12855 2005-10-21  Simon Josefsson  <jas@extundo.com>
12856
12857         * gnulib-tool (func_import, func_create_testdir): Define automake
12858         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
12859         Makefile.am snippet),
12860         suggested by Bruno Haible <bruno@clisp.org>.
12861
12862         * modules/gc (Makefile.am): Use it.
12863
12864 2005-10-21  Bruno Haible  <bruno@clisp.org>
12865
12866         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
12867         patch.
12868
12869 2005-10-19  Simon Josefsson  <jas@extundo.com>
12870
12871         * tests/test-gc-rijndael.c: New file.
12872
12873         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
12874
12875 2005-10-19  Simon Josefsson  <jas@extundo.com>
12876
12877         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
12878         interface too.
12879
12880 2005-10-19  Simon Josefsson  <jas@extundo.com>
12881
12882         * tests/test-gc-arcfour.c: New file.
12883
12884         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
12885
12886 2005-10-19  Simon Josefsson  <jas@extundo.com>
12887
12888         * modules/gc-md4, modules/gc-md4-tests: New file.
12889
12890         * tests/test-gc-md4.c: New file.
12891
12892 2005-10-19  Simon Josefsson  <jas@extundo.com>
12893
12894         * m4/gc-md4.m4: New file.
12895
12896 2005-10-19  Simon Josefsson  <jas@extundo.com>
12897
12898         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
12899         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
12900         <kasal@ucw.cz>.
12901
12902 2005-10-19  Simon Josefsson  <jas@extundo.com>
12903
12904         * m4/gc-arcfour.m4: New file.
12905
12906         * m4/gc-rijndael.m4: New file.
12907
12908 2005-10-19  Simon Josefsson  <jas@extundo.com>
12909
12910         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
12911
12912 2005-10-19  Simon Josefsson  <jas@extundo.com>
12913
12914         * lib/gc-gnulib.c: Support ARCFOUR.
12915
12916 2005-10-19  Simon Josefsson  <jas@extundo.com>
12917
12918         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
12919         support.
12920
12921         * lib/gc.h: Add ECB enum type.
12922
12923         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
12924
12925 2005-10-18  Simon Josefsson  <jas@extundo.com>
12926
12927         * tests/test-md5.c: New file.
12928
12929         * modules/md5-tests: New file.
12930
12931 2005-10-18  Simon Josefsson  <jas@extundo.com>
12932
12933         * tests/test-md4.c: New file.
12934
12935         * modules/md4, modules/md4-tests: New files.
12936
12937 2005-10-18  Simon Josefsson  <jas@extundo.com>
12938
12939         * m4/md4.m4: New file.
12940
12941 2005-10-18  Simon Josefsson  <jas@extundo.com>
12942
12943         * lib/md4.h, lib/md4.c: New files, based on md5.?.
12944
12945 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
12946
12947         * gnulib-tool (func_create_testdir): Omit the second check whether
12948         BUILT_SOURCES in nonempty.
12949
12950 2005-10-17  Simon Josefsson  <jas@extundo.com>
12951
12952         * tests/test-rijndael.c: New file.
12953
12954 2005-10-17  Simon Josefsson  <jas@extundo.com>
12955
12956         * modules/sha1: Depend on stdint instead of md5.
12957
12958         * modules/md5: Depend on stdint, remove uint32_t.
12959
12960 2005-10-17  Simon Josefsson  <jas@extundo.com>
12961
12962         * modules/gc-sha1-tests: New file.
12963
12964         * tests/test-gc-sha1.c: New file.
12965
12966 2005-10-17  Simon Josefsson  <jas@extundo.com>
12967
12968         * m4/md5.m4: Remove call to uint32_t.m4.
12969
12970 2005-10-17  Simon Josefsson  <jas@extundo.com>
12971
12972         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
12973
12974         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
12975         md5.h.
12976
12977         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
12978
12979         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
12980
12981 2005-10-17  Simon Josefsson  <jas@extundo.com>
12982
12983         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
12984
12985 2005-10-17  Simon Josefsson  <jas@extundo.com>
12986
12987         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
12988
12989 2005-10-17  Simon Josefsson  <jas@extundo.com>
12990
12991         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
12992
12993         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
12994
12995 2005-10-17  Bruno Haible  <bruno@clisp.org>
12996
12997         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
12998         that it can also be used in a test.
12999
13000 2005-10-16  Bruno Haible  <bruno@clisp.org>
13001
13002         * gnulib-tool (func_emit_tests_Makefile_am): Also define
13003         TESTS_ENVIRONMENT, so that individual tests can augment it.
13004
13005         * gnulib-tool (func_create_testdir): Use an intermediate target for
13006         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
13007         macros, like $(ALLOCA_H), which cannot be passed through the command
13008         line.
13009
13010 2005-10-15  Simon Josefsson  <jas@extundo.com>
13011
13012         * modules/rijndael-tests: New file.
13013
13014         * modules/rijndael: New file.
13015
13016 2005-10-15  Simon Josefsson  <jas@extundo.com>
13017
13018         * m4/rijndael.m4: New file.
13019
13020 2005-10-15  Simon Josefsson  <jas@extundo.com>
13021
13022         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
13023
13024         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
13025
13026 2005-10-14  Simon Josefsson  <jas@extundo.com>
13027
13028         * tests/test-arcfour.c: New file.
13029
13030         * modules/arcfour, modules/arcfour-tests: New files.
13031
13032 2005-10-14  Simon Josefsson  <jas@extundo.com>
13033
13034         * m4/arcfour.m4: New file.
13035
13036 2005-10-14  Simon Josefsson  <jas@extundo.com>
13037
13038         * lib/arcfour.h, lib/arcfour.c: New files.
13039
13040 2005-10-14  Roland McGrath  <roland@redhat.com>
13041
13042         Import from libc.  [BZ #1331]
13043         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
13044         macro argument.
13045         Reported by Matej Vela <vela@debian.org>.
13046
13047 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
13048
13049         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
13050         include <wchar.h>; no longer needed.
13051
13052 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
13053
13054         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
13055
13056 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
13057         and  Ulrich Drepper  <drepper@redhat.com>
13058
13059         Import from libc.
13060         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
13061         instead of inline stream orientation test and two separate
13062         function calls.  Pay no attention to USE_IN_LIBIO.
13063
13064 2005-10-13  Simon Josefsson  <jas@extundo.com>
13065
13066         * modules/gc-hmac-md5-tests: New file.
13067
13068         * tests/test-gc-hmac-sha1.c: New file.
13069
13070         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
13071
13072         * modules/gc-hmac-md5-tests: New file.
13073
13074         * tests/test-gc-md5.c: New file.
13075
13076         * modules/gc-md5-tests: New file.
13077
13078 2005-10-13  Simon Josefsson  <jas@extundo.com>
13079
13080         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
13081         Move memory allocation outside of loop.
13082
13083 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
13084
13085         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
13086         intermediate directory is in a read-only file system.  Problem
13087         reported by Eric Blake.
13088
13089 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
13090
13091         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
13092
13093 2005-10-12  Simon Josefsson  <jas@extundo.com>
13094
13095         * tests/test-hmac-sha1.c: New file.
13096
13097         * modules/hmac-sha1-tests: New file.
13098
13099         * modules/hmac-sha1: New file.
13100
13101 2005-10-12  Simon Josefsson  <jas@extundo.com>
13102
13103         * modules/gc-sha1: New file.
13104
13105 2005-10-12  Simon Josefsson  <jas@extundo.com>
13106
13107         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
13108
13109         * tests/test-gc-pbkdf2-sha1.c: New file.
13110
13111 2005-10-12  Simon Josefsson  <jas@extundo.com>
13112
13113         * modules/gc-md5, modules/gc-hmac-md5: New files.
13114
13115         * modules/gc (Files): Remove md5, memxor and hmac files.
13116
13117 2005-10-12  Simon Josefsson  <jas@extundo.com>
13118
13119         * m4/gc-pbkdf2-sha1.m4: New file.
13120
13121         * m4/gc-hmac-sha1.m4: New file.
13122
13123         * m4/gc-sha1: New file.
13124
13125         * m4/hmac-sha1.m4: New file.
13126
13127 2005-10-12  Simon Josefsson  <jas@extundo.com>
13128
13129         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
13130
13131         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
13132
13133 2005-10-12  Simon Josefsson  <jas@extundo.com>
13134
13135         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
13136         suggested by Bruno Haible <bruno@clisp.org>.
13137
13138 2005-10-12  Simon Josefsson  <jas@extundo.com>
13139
13140         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
13141
13142 2005-10-12  Simon Josefsson  <jas@extundo.com>
13143
13144         * lib/gc-pbkdf2-sha1.c: New file.
13145
13146         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
13147
13148 2005-10-12  Simon Josefsson  <jas@extundo.com>
13149
13150         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
13151
13152         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
13153
13154 2005-10-12  Simon Josefsson  <jas@extundo.com>
13155
13156         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
13157         GC_USE_HMAC_MD5, respectively.
13158
13159         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
13160         (gc_md5): Fix typo.
13161
13162         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
13163
13164         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
13165
13166         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
13167
13168 2005-10-12  Bruno Haible  <bruno@clisp.org>
13169
13170         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
13171         Reported by Stepan Kasal <kasal@ucw.cz>.
13172
13173 2005-10-11  Simon Josefsson  <jas@extundo.com>
13174
13175         * tests/test-crc.c: New file.
13176
13177         * modules/crc, modules/crc-tests: New files.
13178
13179 2005-10-11  Simon Josefsson  <jas@extundo.com>
13180
13181         * m4/crc.m4: New file.
13182
13183 2005-10-11  Simon Josefsson  <jas@extundo.com>
13184
13185         * lib/gc.h: Add gc_hash and gc_hash_buffer.
13186
13187         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
13188
13189         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
13190
13191 2005-10-11  Simon Josefsson  <jas@extundo.com>
13192
13193         * lib/crc.h, lib/crc.c: New files.
13194
13195         * lib/gc.h (gc_hash_buffer): Add doc.
13196
13197 2005-10-11  Bruno Haible  <bruno@clisp.org>
13198
13199         * modules/c-strcasestr: New file.
13200         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
13201
13202 2005-10-11  Bruno Haible  <bruno@clisp.org>
13203
13204         * modules/c-strcase: New file.
13205         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
13206
13207 2005-10-11  Bruno Haible  <bruno@clisp.org>
13208
13209         * lib/strcasecmp.c: Include limits.h.
13210         (strcasecmp): Avoid integer overflow on exotic platforms.
13211         * lib/strncasecmp.c: Include limits.h.
13212         (strncasecmp): Avoid integer overflow on exotic platforms.
13213         Reported by Paul Eggert.
13214
13215 2005-10-11  Bruno Haible  <bruno@clisp.org>
13216
13217         * lib/c-strcasestr.h: New file, from GNU gettext.
13218         * lib/c-strcasestr.c: New file, from GNU gettext.
13219
13220 2005-10-11  Bruno Haible  <bruno@clisp.org>
13221
13222         * lib/c-strcase.h: New file, from GNU gettext.
13223         * lib/c-strcasecmp.c: New file, from GNU gettext.
13224         * lib/c-strncasecmp.c: New file, from GNU gettext.
13225
13226 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
13227
13228         * modules/mempcpy (License): GPL -> LGPL.
13229         * modules/strchrnul (License): Likewise.
13230         * modules/sysexits (License): Likewise.
13231
13232 2005-10-08  Simon Josefsson  <jas@extundo.com>
13233
13234         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
13235
13236 2005-10-07  Simon Josefsson  <jas@extundo.com>
13237
13238         * m4/memxor.m4: Remove gl_C_RESTRICT call.
13239
13240 2005-10-06  Simon Josefsson  <jas@extundo.com>
13241
13242         * tests/test-hmac-md5.c: New file.
13243
13244         * modules/hmac-md5-tests: New file.
13245
13246         * modules/hmac-md5: New file.
13247
13248 2005-10-06  Simon Josefsson  <jas@extundo.com>
13249
13250         * m4/hmac-md5.m4: New file.
13251
13252         * m4/memxor.m4: Require gl_C_RESTRICT.
13253
13254 2005-10-06  Simon Josefsson  <jas@extundo.com>
13255
13256         * lib/memxor.c (memxor): Avoid casts and warnings.
13257
13258 2005-10-06  Simon Josefsson  <jas@extundo.com>
13259
13260         * lib/hmac-md5.c: New file.
13261
13262         * lib/hmac.h: New file.
13263
13264 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
13265
13266         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
13267         promotes to int, not unsigned int, to catch the AIX 5.3
13268         compiler bug.
13269
13270 2005-10-05  Simon Josefsson  <jas@extundo.com>
13271
13272         * modules/memxor: New file.
13273
13274         * modules/iconv (Files): Move config.rpath to havelib, it is used
13275         there.
13276
13277         * modules/havelib (Files): Add config.rpath.
13278
13279 2005-10-05  Simon Josefsson  <jas@extundo.com>
13280
13281         * m4/memxor.m4: New file.
13282
13283 2005-10-05  Simon Josefsson  <jas@extundo.com>
13284
13285         * lib/memxor.c (memxor): Fix compiler error.
13286
13287         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
13288         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
13289
13290         * lib/memxor.h, lib/memxor.c: New files.
13291
13292         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
13293         we assume all systems have it, suggested by Jim Meyering
13294         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
13295         any systems lack sys/socket.h; mingw32 is known to lack it, but we
13296         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
13297         same reasons.
13298
13299 2005-10-05  Simon Josefsson  <jas@extundo.com>
13300
13301         * config/srclist.txt: Add glibc bug 1423 for md5.h.
13302
13303 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
13304
13305         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
13306         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
13307         needed, since the source code now assumes these .h files.
13308
13309 2005-10-05  Derek Price  <derek@ximbiot.com>
13310
13311         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
13312
13313 2005-10-05  Bruno Haible  <bruno@clisp.org>
13314
13315         * modules/stdint (License): Change to LGPL.
13316
13317 2005-10-04  Simon Josefsson  <jas@extundo.com>
13318
13319         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
13320         D. Baushke" <mdb@gnu.org>.
13321
13322 2005-10-04  Bruno Haible  <bruno@clisp.org>
13323
13324         * lib/verify.h (verify_true): Provide alternative definition for C++.
13325
13326 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
13327
13328         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
13329         (SSIZE_MAX): New macro, if not already defined.
13330         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
13331         than 2 GiB.
13332
13333 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13334
13335         Sync from coreutils.
13336         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
13337         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
13338         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
13339         ULLONG_MAX doesn't work with 2.7.2.1.
13340
13341 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13342
13343         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
13344         From Ben Pfaff.
13345
13346         * modules/exclude (Depends-on): Depend on verify.
13347         * modules/strtoimax (Depends-on): Likewise.
13348         * modules/utimecmp (Depends-on): Likewise.
13349
13350 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13351
13352         * lib/exclude.c: Include verify.h.
13353         (verify): Remove.  All callers changed to use verify.h's version.
13354         * lib/strtoimax.c: Likewise.
13355         * lib/utimecmp.c: Likewis.e
13356
13357         Sync from coreutils.
13358         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
13359         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
13360         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
13361         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
13362         bother returning ENOSYS if settimeofday or stime fails; just let
13363         them return whatever errno they want to return.
13364         * lib/utimens.c: Include unistd.h, for dup2.
13365         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
13366         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
13367
13368 2005-10-02  Jim Meyering  <jim@meyering.net>
13369
13370         Sync from coreutils.
13371         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
13372         from glibc-2.2.5 that fails for read-only files.
13373
13374 2005-10-02  Jim Meyering  <jim@meyering.net>
13375
13376         Sync from coreutils.
13377         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
13378         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
13379         `#if HAVE_CONFIG_H'.
13380         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
13381         Remove AT_FDCWD test.
13382         Do not consume the fd unless successful.
13383         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
13384         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
13385         block, so that we don't even try to compile it if settimeofday is
13386         available.  This works around a compilation failure on OSF1 V5.1,
13387         due to stime requiring a `long int*' while tv_sec is `int'.
13388
13389 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
13390
13391         Sync from coreutils.
13392         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
13393         against `yes', rather than just testing for nonempty.
13394
13395 2005-10-01  Simon Josefsson  <jas@extundo.com>
13396
13397         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
13398         and Darwin.
13399
13400         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
13401         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
13402         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
13403         freeaddrinfo and gai_strerror are declared by the POSIX headers.
13404         Check if struct addrinfo is declared.
13405
13406 2005-10-01  Simon Josefsson  <jas@extundo.com>
13407
13408         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
13409         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
13410         AI_* and EAI_* definitions.  Protect function declarations.
13411
13412 2005-10-01  Jim Meyering  <jim@meyering.net>
13413
13414         Sync from coreutils.
13415
13416         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
13417         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
13418         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
13419         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
13420         in the inet and nsl libraries.  Required on Solaris 5.7.
13421
13422 2005-10-01  Jim Meyering  <jim@meyering.net>
13423
13424         Sync from coreutils.
13425         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
13426         in the inet and nsl libraries.  Required on Solaris 5.7.
13427
13428 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
13429
13430         * lib/getdelim.c (getdelim): Remove unused variables.
13431
13432 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
13433
13434         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
13435         so that the code works even with ancient cpp.  Portability problem
13436         with GCC 2.7.2.1 reported by Thomas M.Ott.
13437
13438 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
13439
13440         * modules/regex (Depends-on): Add strcase.
13441
13442         * modules/gethostname (Licence): Change from GPL to LGPL, since
13443         gethostname.c is a trivial implementation of a standard library
13444         function.
13445         * modules/poll (License): Change from GPL to LGPL, since it's
13446         derived from LGPL code.
13447
13448 2005-09-27  Jim Meyering  <jim@meyering.net>
13449
13450         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
13451         HAVE_CONFIG_H.
13452
13453         * lib/intprops.h (signed_type_or_expr__): Define.
13454         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
13455         for unsigned types.
13456
13457 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
13458
13459         * lib/verify.h (verify_expr): Remove, replacing with:
13460         (verify_true): New macro that returns true instead of void.
13461         (verify_type__): Remove.
13462         (verify): Use verify_true rather than verify_type__.
13463
13464 2005-09-26  Bruno Haible  <bruno@clisp.org>
13465
13466         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
13467         is necessary.
13468         (lib_SOURCES): Remove mbchar.c.
13469         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
13470         (Files): Add m4/mbrtowc.m4.
13471         * modules/mbiter: Likewise.
13472         * modules/mbuiter: Likewise.
13473
13474 2005-09-26  Bruno Haible  <bruno@clisp.org>
13475
13476         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
13477         compile mbchar.c if they are not both present.
13478         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
13479         * m4/mbiter.m4 (gl_MBITER): Likewise.
13480         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
13481         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
13482         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
13483
13484 2005-09-25  Jim Meyering  <jim@meyering.net>
13485
13486         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
13487         also uses socklen_t.
13488
13489 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
13490
13491         * lib/utimens.c (ENOSYS): Define if not already defined.
13492         (futimens): Support having a null PATH if the file descriptor
13493         is nonnegative.
13494
13495         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
13496         Remove.
13497         (__attribute): Define to empty unless GCC 3.1 or later.
13498         This works around a core dump on OpenBSD 3.4, which has GCC
13499         2.95.3, which dumps core when given __attribute__(()).  It also
13500         simplifies other tests, since we really don't want to bother with
13501         worrying about which ancient version of GCC supported what.
13502         Original problem reported by Yoann Vandoorselaere, with part of
13503         the fix suggested by Derek Price.
13504
13505 2005-09-24  Jim Meyering  <jim@meyering.net>
13506
13507         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
13508         so we can once again use a positive bitfield width of 1 -- now we
13509         don't have to explain why we were using a bitfield width of 2.
13510
13511 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
13512
13513         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
13514         and similarly for the other external symbols.  Problem reported
13515         by James Gallager.
13516
13517         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
13518         bug reported by Jim Meyering.
13519
13520         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
13521         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
13522         not needed, since socklen is a prerequisite module.
13523
13524 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
13525
13526         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
13527         Problem reported by Eric Blake.
13528         (getaddrinfo): Initialize se so that it's not garbage.
13529         Redo internal storage allocation so that it doesn't make unportable
13530         assumptions about alignment.
13531         Fix a memory leak.
13532
13533         * lib/utimens.c (futimens): Use futimesat if available.
13534         Prefer it to futimes since it doesn't have the futimes bug.
13535
13536         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
13537         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
13538         Instead, declare a function that returns a pointer to an array,
13539         and use verify_type__ to declare the size of the array.
13540         Problem and germ of a solution reported by Bruno Haible.
13541         (verify_type__): Use 2, not 1, for bitfield size, to avoid
13542         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
13543
13544 2005-09-23  Jim Meyering  <jim@meyering.net>
13545
13546         Sync from coreutils.
13547         Correct build failure (socklen_t not defined) on at least
13548         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
13549         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
13550
13551 2005-09-23  Jim Meyering  <jim@meyering.net>
13552
13553         * modules/getaddrinfo (Depends-on): Add socklen.
13554
13555 2005-09-23  Bruno Haible  <bruno@clisp.org>
13556
13557         * tests/test-verify.c: New file.
13558
13559 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13560
13561         Sync from coreutils.
13562
13563         * modules/argmatch (Depends-on): Add verify.
13564         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
13565         unistd-safer.
13566         * modules/save-cwd (Depends-on): Likewise.
13567
13568         * modules/openat (Files): Add lib/openat-die.c.
13569         (Depends-on): Remove error, exitfail.
13570         Add dirname.
13571
13572         * modules/verify: New file.
13573         * MODULES.html.sh (Diagnostics <assert.h>): New section,
13574         with "verify" module.
13575
13576 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13577
13578         Sync from coreutils.
13579
13580         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
13581         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
13582         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
13583         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
13584         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
13585         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
13586         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
13587         Don't bother checking for string.h, stdlib.h, unistd.h.
13588         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
13589         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
13590         module's job.
13591         * m4/jm-macros.m4 (gl_MACROS): Likewise.
13592         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
13593
13594         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
13595         (gl_GETDATE): Use it.
13596
13597         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
13598
13599 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13600
13601         Sync from coreutils.
13602
13603         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
13604         stat-time.h.
13605         * lib/argmatch.h: Include verify.h
13606         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
13607         (ARGMATCH_ASSERT): Remove; unused.
13608         * lib/canonicalize.c: Assume STDC_HEADERS.
13609         * lib/exclude.c: Include "strcase.h".
13610         * lib/regex_internal.h [!defined _LIBC]: Likewise.
13611         * lib/getusershell.c: Include stdio--.h rather than stdio.h
13612         and stdio-safer.h.
13613         (getusershell): Call fopen, not fopen_safer.
13614         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
13615         Do not include unistd-safer.h.
13616         (save_cwd): Don't call fd_safer; no longer needed
13617         now that we include fcntl--.h.
13618
13619         * lib/getdate.y (relative_time): New type.
13620         (RELATIVE_TIME_0): New constant.
13621         (parser_control): Use relative_time instead of doing it ourselves.
13622         (%union): Add new relative_time rel member.
13623         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
13624         Now typeless.
13625         (relunit, relunit_snumber): Now of type rel.
13626         (zone, rel, relunit, get_date): Adjust to above changes.
13627
13628         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
13629         Do not include unistd-safer.h.
13630         (getloadavg): Don't call fd_safer; no longer needed
13631         now that we include fcntl--.h.
13632
13633         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
13634         (make_dir_parents): Treat ENOSYS like EEXIST.
13635
13636         Improve quality of diagnostics on restore_cwd failure.
13637         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
13638         (make_dir_parents): Last arg is now int * (for errno), not bool *.
13639         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
13640         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
13641         each time through the loop.  Do not diagnose restore_cwd failure;
13642         that is the caller's job (and perhaps the caller does not care).
13643
13644         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
13645         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
13646         If the file already exists but is not a directory, don't bother
13647         to try to make its parents.
13648         Close potential file descriptor leak if we can't chdir("/") (!).
13649         Don't always return true if chdir($PWD) fails; return true only
13650         if the requested action was done successfully (except for the
13651         chdir($PWD)).
13652         Don't log final directory unless we actually made it.
13653         Refactor to avoid duplicate code to fix up permissions.
13654         Don't attempt to fix up parent permissions if chdir($PWD) fails.
13655
13656         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
13657         to make it a bit faster and (I hope) clearer.
13658         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
13659         Fix bug in formats like %2N.
13660
13661         * lib/verify.h: New file.
13662
13663 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13664
13665         Sync from coreutils.
13666         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
13667
13668 2005-09-22  Jim Meyering  <jim@meyering.net>
13669
13670         Sync from coreutils.
13671
13672         * m4/lstat.m4 (gl_FUNC_LSTAT):
13673         Use AC_LIBSOURCES to require lstat.c and lstat.h.
13674         Remove obsolete comment.
13675         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
13676         * m4/xstrtod.m4: Likewise.
13677
13678         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
13679
13680 2005-09-22  Jim Meyering  <jim@meyering.net>
13681
13682         Sync from coreutils.
13683
13684         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
13685
13686         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
13687         the .tm_year member, since otherwise gcc-4.0 would now warn about
13688         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
13689
13690         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
13691         order to avoid an unsuppressible warning from gcc on 64-bit systems.
13692
13693         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
13694         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
13695         when run in a time zone for which daylight savings time is in effect
13696         for the starting date.
13697
13698         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
13699         stop us from restricting permissions of just-created absolute-named
13700         directories.
13701         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
13702         to restore initial working directory.
13703         * lib/mkdir-p.c (make_dir_parents): New parameter:
13704         different_working_dir, to tell caller if/when we change the working
13705         directory and are unable to return to the initial one.
13706         * lib/mkdir-p.h (make_dir_parents): Update prototype.
13707         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
13708         `return false'.  This fixes a bug introduced on 2004-07-30.
13709
13710         * lib/openat.c (fdopendir): Be sure to close the supplied
13711         file descriptor before returning.  This makes our replacement
13712         implementation a little closer to Solaris's, where fdopendir
13713         ties the file descriptor to the returned DIR* pointer.
13714         * lib/openat.c (unlinkat): New function.
13715         * lib/openat.h (unlinkat): Add prototype.
13716         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
13717         (openat_restore_fail): Rename from openat_restore_die.
13718         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
13719
13720         Provide an alternative to exiting immediately upon save_cwd or
13721         restore_cwd failure.  Now, an application can arrange e.g.,
13722         to perform a longjump in that case.
13723         * lib/openat.c: Include dirname.h.
13724         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
13725         (rpl_openat, fdopendir, fstatat): Call openat_save_die
13726         and openat_restore_die rather than calling error directly.
13727         Don't include "error.h" or "exitfail.h"; they're no longer needed.
13728
13729         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
13730         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
13731         define.
13732
13733         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
13734         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
13735                             int utc, int nanoseconds);
13736         Background:
13737         date should not have to allocate a megabyte of virtual memory to
13738         handle a format argument like +%1048575T.  When implemented with
13739         strftime, it must allocate such a buffer, use strftime to fill it
13740         in, print it, then free it.
13741         With fprintftime, it simply prints everything and exits.
13742         With no need for memory allocation, that's one fewer way to fail.
13743         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
13744         optional field width, not before, so we accept %9:z, not %:9z.
13745         (my_strftime): Be sure to use L_('x') for literals.
13746
13747         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
13748         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
13749         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
13750         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
13751         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
13752         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
13753         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
13754         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
13755         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
13756         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
13757         * lib/xgethostname.c, lib/xreadlink.c:
13758         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
13759
13760         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
13761         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
13762         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
13763         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
13764         and don't include <sys/file.h>).
13765
13766 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
13767
13768         Sync from coreutils.
13769
13770         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
13771         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
13772         [!LDAV_DONE]: Avoid unused variable warning.
13773
13774 2005-09-21  Bruno Haible  <bruno@clisp.org>
13775
13776         * lib/unicodeio.h (unicode_to_mb): New declaration.
13777
13778 2005-09-20  Derek Price  <derek@ximbiot.com>
13779
13780         * lib/getaddrinfo.c: Don't include <netdb.h> included from
13781         getaddrinfo.h.
13782
13783 2005-09-20  Bruno Haible  <bruno@clisp.org>
13784
13785         * gnulib-tool: Remove trailing slashes from the values specified for
13786         --source-base, --m4-base, --tests-base, --aux-dir.
13787         Suggested by Simon Josefsson <jas@extundo.com>.
13788
13789 2005-09-20  Bruno Haible  <bruno@clisp.org>
13790
13791         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
13792         func_modules_to_filelist, func_import, func_create_testdir): Make all
13793         sorting results locale-independent, so that gnulib-cache.m4 doesn't
13794         change when gnulib-tool is invoked in a different locale.
13795
13796 2005-09-19  Simon Josefsson  <jas@extundo.com>
13797
13798         * m4/socklen.m4: Fix typo.
13799
13800 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13801
13802         Use a consistent style for including <config.h>.
13803         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
13804         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
13805         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
13806         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
13807         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
13808         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
13809         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
13810         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
13811         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
13812         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
13813         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
13814         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
13815         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
13816         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
13817         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
13818         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
13819         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
13820         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
13821         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
13822         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
13823         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
13824         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
13825         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
13826         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
13827         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
13828         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
13829         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
13830         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
13831         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
13832         lib/xstrtoumax.c, lib/yesno.c:
13833         Standardize inclusion of config.h.
13834         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
13835         lib/inttostr.h:  Removed inclusion of config.h from header files.
13836         * lib/inttostr.c:  Adjusted in-tree users.
13837         * lib/timespec.h: Remove superfluous warning to include config.h.
13838         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
13839         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
13840         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
13841         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
13842         config.h with HAVE_CONFIG_H.
13843
13844 2005-09-19  Jim Meyering  <jim@meyering.net>
13845
13846         * modules/pathmax (License): Change to LGPL.
13847
13848 2005-09-19  Derek Price  <derek@ximbiot.com>
13849
13850         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
13851
13852 2005-09-19  Bruno Haible  <bruno@clisp.org>
13853
13854         * gnulib-tool (import): Provide default for --tests-base.
13855
13856 2005-09-19  Bruno Haible  <bruno@clisp.org>
13857
13858         * doc/quote.texi: New file, extracted from gnulib.texi.
13859         * doc/ctime.texi: New file, extracted from gnulib.texi.
13860         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
13861         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
13862         * doc/gnulib.texi: Include them.
13863
13864 2005-09-18  Bruno Haible  <bruno@clisp.org>
13865
13866         Portability fix.
13867         * gnulib-tool (func_readlink): New function.
13868         (func_ln_if_changed): Use it.
13869
13870 2005-09-18  Bruno Haible  <bruno@clisp.org>
13871
13872         * gnulib-tool: Support --with-tests also with --import.
13873         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
13874         (func_import): Use variables $testsbase and $inctests. Emit a
13875         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
13876         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
13877         SUBDIRS += $testsdir.
13878         (func_create_testdir): Update.
13879
13880 2005-09-18  Bruno Haible  <bruno@clisp.org>
13881
13882         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
13883         instead of $dry_run.
13884         (func_cp_if_changed, func_mv_if_changed): Remove functions.
13885         (func_ln_if_changed): Don't handle dry-run here.
13886         (func_import): In dry-run mode, detect more precisely which actions
13887         would be performed, and don't use "...ing" verbs.
13888
13889 2005-09-18  Bruno Haible  <bruno@clisp.org>
13890
13891         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
13892         (func_import): Use join on two temporary files instead of three nested
13893         loops, in order to determine which files are new or old.
13894
13895 2005-09-18  Bruno Haible  <bruno@clisp.org>
13896
13897         * gnulib-tool (func_import): Comment out code that spits out the
13898         new files with --dry-run.
13899
13900 2005-09-18  Bruno Haible  <bruno@clisp.org>
13901
13902         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
13903
13904 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13905
13906         * lib/stat-time.h: New file.
13907         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
13908         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
13909         in a different way.
13910         (timespec_cmp): New function.
13911         * lib/utimecmp.c: Include stat-time.h.
13912         (SYSCALL_RESOLUTION): Depend on whether various struct stat
13913         members exist, not on the obsolescent ST_MTIM_NSEC.
13914         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
13915
13916 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13917
13918         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
13919
13920 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13921
13922         * MODULES.html.sh (File system functions): Add stat-time.
13923         * modules/stat-time: New file.
13924         * modules/timespec (Files): Remove m4/st_mtim.m4; this
13925         is now done in a different way, by the stat-time module.
13926         * modules/utimecmp (Depends-on): Add stat-time.
13927
13928 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
13929
13930         * m4/st_mtim.m4: Remove.  Superseded by...
13931         * m4/stat-time.m4: New file.
13932         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
13933         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
13934
13935 2005-09-15  Derek Price  <derek@ximbiot.com>
13936
13937         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
13938
13939 2005-09-15  Derek Price  <derek@ximbiot.com>
13940
13941         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
13942         * lib/regex_internal.c: Ditto, using this...
13943         (__GNUC_PREREQ): ...new macro.
13944         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
13945         using...
13946         (__GNUC_PREREQ): ...this new macro.
13947
13948         * lib/strstr.h: Include string.h. Define strstr as a macro here.
13949
13950 2005-09-15  Derek Price  <derek@ximbiot.com>
13951             Paul Eggert  <eggert@cs.ucla.edu>
13952
13953         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
13954         changes, consolidating in...
13955         * lib/regex_internal.h: ...this file.
13956
13957 2005-09-13  Jim Meyering  <jim@meyering.net>
13958
13959         * lib/canon-host.c: Filter through gnu indent and reword comments
13960         slightly.
13961         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
13962
13963 2005-09-13  Derek Price  <derek@ximbiot.com>
13964
13965         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
13966         failure.
13967         Reported by Jim Meyering  <jim@meyering.net>.
13968
13969 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13970
13971         * lib/base64.c: Typo.
13972         (base64_encode): Put b64str in initialized data section.
13973
13974 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
13975
13976         Merge glibc and coreutils changes into gnulib, plus a few
13977         extra fixes.
13978         * lib/md5.c: Use #error rather than a string.
13979         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
13980         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
13981         (__attribute__): Define to empty for non recent-GCC.
13982         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
13983         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
13984         Renamed from their non-__ counterparts, with new macros replacing
13985         them if not _LIBC.  Add __THROW attribute.
13986         (rol): Remove.
13987         (struct md5_ctx): Align buffer if using GCC.
13988         * lib/sha1.h (struct sha1_ctx): Likewise.
13989         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
13990         The old name was backwards.
13991         (NOTSWAP): Remove; not used.
13992         (rol): New macro, moved here from md5.h.
13993         (sha1_process_block): Remove a FIXME that doesn't make sense.
13994
13995 2005-09-12  Derek Price  <derek@ximbiot.com>
13996
13997         Return usable errors from canon-host.
13998         * lib/canon-host.h: New file.
13999         * lib/canon-host.c (canon_host): Wrap...
14000         (canon_host_r): ...this new function, which now relies exclusively on
14001         getaddrinfo.
14002         (ch_strerror): New function.
14003         (last_cherror): New global.
14004         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
14005         interface.
14006         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
14007         void *.
14008         (freeaddrinfo): Free ai->ai_canonname when set.
14009
14010 2005-09-12  Derek Price  <derek@ximbiot.com>
14011
14012         Make canon-host require getaddrinfo.
14013         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
14014         AC_LIBSOURCE canon-host.h.  Call...
14015         (gl_PREREQ_CANON_HOST): ...this new function, which requires
14016         gl_GETADDRINFO.
14017         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
14018
14019 2005-09-12  Derek Price  <derek@ximbiot.com>
14020
14021         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
14022         LGPL.
14023         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
14024
14025 2005-09-12  Derek Price  <derek@ximbiot.com>
14026
14027         * lib/gai_strerror.c: Include config.h when available.  Include
14028         getaddrinfo.h before other headers to test interface.
14029         Reported by Larry Jones <lawrence.jones@ugs.com>.
14030
14031 2005-09-12  Derek Price  <derek@ximbiot.com>
14032             Paul Eggert  <eggert@cs.ucla.edu>
14033
14034         * modules/glob (Files): Add glob-libc.h.
14035
14036 2005-09-12  Derek Price  <derek@ximbiot.com>
14037             Paul Eggert  <eggert@cs.ucla.edu>
14038
14039         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
14040         glob_.h, glob-libc.h.
14041         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
14042
14043 2005-09-12  Derek Price  <derek@ximbiot.com>
14044             Paul Eggert  <eggert@cs.ucla.edu>
14045
14046         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
14047         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
14048         protecting things that should be done only in gnulib contexts.
14049         * lib/glob_.h: New file, containing only the glob things needed for
14050         gnulib.
14051         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
14052         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
14053         (glob, globfree, glob_pattern_p): Now defined simply in terms of
14054         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
14055         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
14056         and to respect the namespace rules better.
14057
14058 2005-09-08  Simon Josefsson  <jas@extundo.com>
14059
14060         * modules/socklen: New file.
14061
14062 2005-09-08  Simon Josefsson  <jas@extundo.com>
14063
14064         * m4/socklen.m4: New file.
14065
14066 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14067
14068         * modules/utimens (Files): Add m4/utimbuf.m4, since
14069         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
14070         Reported by Sergey Poznyakoff.
14071
14072 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14073
14074         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
14075         definitions, since that's the preferred style in glibc.
14076         Fix a minor spacing issue, and update copyright notice to match
14077         glibc's.
14078
14079 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14080
14081         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
14082
14083 2005-09-06  Simon Josefsson  <jas@extundo.com>
14084
14085         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
14086         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
14087
14088 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14089
14090         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
14091         warning.
14092
14093 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14094
14095         * config/srclist.txt: Add glibc bug 1302.
14096
14097 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
14098
14099         Change bitset word type from unsigned int to unsigned long int,
14100         as this has better performance on typical 64-bit hosts.
14101         Port bitset code to hosts with unusual word sizes.
14102         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
14103         (build_collating_symbol):
14104         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
14105         argument is a bitset.  This is merely a style issue, but it makes
14106         it clearer that an entire array is expected.
14107         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
14108         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
14109         Port to the case where bitset_word is not the same as unsigned int.
14110         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
14111         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
14112         Likewise.
14113         * lib/regexec.c (check_dst_limits_calc_pos_1,
14114         check_subexp_matching_top):
14115         (build_trtable, group_nodes_into_DFAstates):
14116         Likewise.
14117         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
14118         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
14119         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
14120         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
14121         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
14122         * lib/regcomp.c (optimize_subexps, lower_subexp):
14123         Work even if bitset_word has holes in its bitwise representation.
14124         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
14125         * lib/regexec.c (check_dst_limits_calc_pos_1,
14126         check_subexp_matching_top):
14127         Likewise.
14128         * lib/regex_internal.c (re_string_reconstruct):
14129         Don't assume UCHAR_MAX == 255.
14130         * lib/regex_internal.h (bitset_set_all): Likewise.
14131         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
14132         All uses changed.
14133         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
14134         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
14135         All uses changed.
14136         (BITSET_WORD_MAX): New macro.
14137         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
14138         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
14139         (bitset_empty, bitset_copy):
14140         Prefer sizeof (bitset) to multiplying it out ourselves.
14141         (bitset_not_merge): Remove; unused.
14142         (bitset_contain): Return bool, not unsigned int with one bit on.
14143         All callers changed.
14144         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
14145         alignment than re_node_set; do this by defining a new internal
14146         type struct dests_alloc and using it to allocate memory.
14147
14148 2005-09-05  Bruno Haible  <bruno@clisp.org>
14149
14150         * gnulib-tool (func_import): Fix comparison in handling of symbolic
14151         links.
14152
14153 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
14154
14155         * modules/size_max (Makefile.am): Add size_max.h
14156
14157 2005-09-04  Derek Price  <derek@ximbiot.com>
14158
14159         * gnulib-tool (func_import): Fix reversed $symbolic logic.
14160
14161 2005-09-03  Simon Josefsson  <jas@extundo.com>
14162
14163         * gnulib-tool: Fix typo.
14164
14165 2005-09-03  Simon Josefsson  <jas@extundo.com>
14166
14167         * config/srclist.txt: Add glibc bug 1293.
14168
14169 2005-09-03  Derek Price  <derek@ximbiot.com>
14170
14171         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
14172         From Larry Jones <lawrence.jones@ugs.com>.
14173
14174 2005-09-02  Simon Josefsson  <jas@extundo.com>
14175
14176         * modules/socklen: New file.
14177
14178 2005-09-02  Simon Josefsson  <jas@extundo.com>
14179
14180         * modules/havelib: New module.
14181
14182         * modules/gettext, modules/iconv, modules/lock, modules/readline:
14183         Use havelib.
14184
14185 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14186
14187         Check for arithmetic overflow when calculating sizes, to prevent
14188         some buffer-overflow issues.  These patches are conservative, in the
14189         sense that when I couldn't determine whether an overflow was possible,
14190         I inserted a run-time check.
14191         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
14192         macros.
14193         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
14194         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
14195         (re_xnrealloc, re_x2nrealloc): New inline functions.
14196         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
14197         parse_bracket_exp):
14198         (build_equiv_class, build_charclass): Check for arithmetic overflow
14199         in size expression calculations.
14200         * lib/regex_internal.c (re_string_realloc_buffers):
14201         (build_wcs_upper_buffer, re_node_set_add_intersect):
14202         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
14203         (re_dfa_add_node, register_state): Likewise.
14204         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
14205         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
14206         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
14207         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
14208
14209 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14210
14211         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14212         m4/ulonglong.m4.  Problem reported by Martin Lambers.
14213
14214 2005-09-02  Bruno Haible  <bruno@clisp.org>
14215
14216         Support for lib vs. lib64 distinction on biarch platforms.
14217         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
14218         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
14219         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
14220
14221 2005-09-02  Bruno Haible  <bruno@clisp.org>
14222
14223         * gnulib-tool (import): In the other first-use case, provide defaults
14224         as well.
14225
14226 2005-09-02  Bruno Haible  <bruno@clisp.org>
14227
14228         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
14229         patches not yet found in the latest gettext release.
14230
14231 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
14232
14233         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
14234         to avoid a collision with bits/local_lim.h in glibc.
14235         All uses changed.  Problem reported by Dmitry V. Levin in
14236         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
14237
14238         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
14239         bugs in int versus size_t comparisons.
14240         (re_string_context_at): Fix bug where the code assumed that
14241         Idx is signed.
14242
14243         Use bool where appropriate.
14244         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
14245         All callers changed.
14246         (calc_eclosure_iter): Likewise, for ROOT arg.
14247         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
14248         (build_charclass_op): Likewise, for NON_MATCH arg.
14249         * lib/regex_internal.c (re_string_allocate, re_string_construct):
14250         (re_string_construct_common): Likewise, for ICASE arg.
14251         * lib/regexec.c (re_search_2_stub, re_search_stub):
14252         Likewise, for RET_LEN arg.
14253         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
14254         (set_regs): Likewise, for FL_BACKTRACK arg.
14255         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
14256         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
14257         (calc_eclosure_iter, parse_bracket_exp):
14258         Use bool for internal variables that are booleans.
14259         * lib/regexec.c (re_search_internal, check_matching,
14260         proceed_next_node):
14261         (set_regs, build_sifted_states, sift_states_bkref):
14262         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
14263         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
14264         (find_collation_sequence_value):
14265         Likewise.
14266         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
14267         (re_node_set_compare):
14268         Return bool, not int. All callers changed.
14269         * lib/regexec.c (check_halt_node_context, check_dst_limits):
14270         (build_trtable, check_node_accept): Likewise.
14271         * lib/regex_internal.h: Include stdbool.h.
14272
14273         Fix bugs uncovered when converting to bool.
14274         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
14275         failure instead of charging ahead blindly.
14276         * lib/regex_internal.c (register_state): Likewise.
14277         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
14278         for freeing internal storage.
14279         (group_nodes_into_DFA_states): Use unsigned int, not int, for
14280         bitset pieces used as boolean, to avoid undefined behavior
14281         on hosts that do int overflow checking.
14282
14283 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
14284
14285         * config/srclist.txt: Add glibc bugs 1285-1287.
14286
14287 2005-09-01  Jim Meyering  <jim@meyering.net>
14288
14289         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
14290         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
14291         Require gl_STAT_MACROS, too.
14292
14293 2005-09-01  Bruno Haible  <bruno@clisp.org>
14294
14295         * gnulib-tool (import): In the first-use case, provide defaults.
14296
14297 2005-09-01  Bruno Haible  <bruno@clisp.org>
14298
14299         * gnulib-tool (func_import): Remove the .tmp files.
14300
14301 2005-09-01  Bruno Haible  <bruno@clisp.org>
14302
14303         * gnulib-tool (func_import): Fix handling of symbolic links.
14304
14305 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14306
14307         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
14308         old glibc regex code mishandles strings longer than 2**31 bytes.
14309         This patch fixes this when the regex code is used in gnulib
14310         (i.e., outside glibc).
14311
14312         This patch should not affect the use of the regex code inside
14313         glibc.  No doubt this problem also needs to be handled for glibc
14314         as well, but the result will be an incompatible change to the
14315         glibc ABI, and the old ABI will have to be supported too.  That
14316         can be the the subject for another patch.
14317
14318         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
14319         governing whether the rest of this patch is active.  By default,
14320         the macro is disabled and the patch has no effect.
14321         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
14322         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
14323         (struct re_pattern_buffer, re_search, re_search_2, re_match):
14324         (re_match_2, re_set_registers): Use the new types.
14325         * lib/regex_internal.h (Idx, re_hashval_t): New types.
14326         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
14327         New macros.
14328         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
14329         (re_string_context_at, bin_tree_t, re_dfastate_t):
14330         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
14331         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
14332         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
14333         (re_string_char_size_at, re_string_wchar_at):
14334         (re_string_elem_size_at):
14335         Use the new types and macros to port to 64-bit hosts.
14336         Use unsigned types for internal values, so that the code
14337         mostly works even for arrays larger than SSIZE_MAX.
14338         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
14339         (search_duplicated_node, calc_eclosure_iter, fetch_number):
14340         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
14341         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
14342         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
14343         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
14344         (calc_inveclosure, parse_dup_op, build_range_exp):
14345         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
14346         (fetch_number, create_token_tree, mark_opt_subexp):
14347         Likewise.
14348         * lib/regex_internal.c (re_string_construct_common,
14349         create_ci_newstate):
14350         (create_cd_newstate, re_string_allocate, re_string_construct):
14351         (re_string_realloc_buffers, build_wcs_upper_buffer):
14352         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
14353         (re_string_reconstruct, re_string_peek_byte_case):
14354         (re_string_fetch_byte_case, re_string_context_at):
14355         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
14356         (re_node_set_init_copy, re_node_set_add_intersect):
14357         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14358         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14359         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
14360         (re_acquire_state, re_acquire_state_context, register_state):
14361         Likewise.
14362         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
14363         search_cur_bkref_entry):
14364         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
14365         (re_search_internal, re_search_2_stub, re_search_stub)
14366         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
14367         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
14368         (update_cur_sifted_state, check_dst_limits):
14369         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
14370         (check_subexp_limits, sift_states_bkref, merge_state_array):
14371         (check_subexp_matching_top, get_subexp, get_subexp_sub):
14372         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
14373         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
14374         (expand_bkref_cache, check_node_accept_bytes):
14375         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
14376         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
14377         (acquire_init_state_context, check_halt_node_context):
14378         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
14379         (sift_states_backward, clean_state_log_if_needed):
14380         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
14381         (find_recover_state, transit_state_sb, transit_state_mb):
14382         (transit_state_bkref, build_trtable, match_ctx_clean):
14383         Likewise.
14384         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
14385         to work around an assumption that REG_MISSING is negative.
14386
14387         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
14388         (seek_collating_symbol_entry) [defined _LIBC]:
14389         (lookup_collation_sequence_value) [defined _LIBC]:
14390         (build_range_exp, build_collating_symbol) [defined _LIBC]:
14391         Use prototypes rather than old-style function definitions.
14392         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
14393         (transit_state_sb) [0]:
14394         (find_collation_sequence_value) [defined _LIBC]: Likewise.
14395
14396         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
14397         rm_eo.
14398
14399         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
14400         (optimize_subexps, lower_subexp):
14401         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
14402         since the signed shift might overflow.  Use 1u<<31 instead.
14403         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
14404         Likewise.
14405         * lib/regexec.c (check_dst_limits_calc_pos_1,
14406         check_subexp_matching_top): Likewise.
14407
14408         * lib/regcomp.c (optimize_subexps, lower_subexp):
14409         Use CHAR_BIT rather than 8, for clarity.
14410         * lib/regexec.c (check_dst_limits_calc_pos_1):
14411         (check_subexp_matching_top): Likewise.
14412         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
14413         have to worry about portability issues when shifting it left.
14414         Remove no-longer-needed test for table_size > 0.
14415         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
14416         in a word, as the resulting behavior is undefined.
14417         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
14418         in one case, a <= should have been an <, and in another case the
14419         whole test was missing.
14420         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
14421         the standard name CHAR_BIT.
14422         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
14423         this is not true on one's complement and signed-magnitude hosts.
14424
14425         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
14426         next_last_offset.
14427         (struct re_dfa_t): Remove unused member states_alloc.
14428         * lib/regcomp.c (init_dfa): Don't initialize unused members.
14429
14430 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14431
14432         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
14433         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
14434         and large-file glibc and in 32-bit large-file Solaris.
14435
14436 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14437
14438         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
14439         lengths fit in regoff_t; this isn't true if regoff_t is the same
14440         width as size_t.
14441         * lib/regex.c (re_search_internal): 5th arg is LAST_START
14442         (= START + RANGE) instead of RANGE.  This avoids overflow
14443         problems when regoff_t is the same width as size_t.
14444         All callers changed.
14445         (re_search_2_stub): Check for overflow when adding the
14446         sizes of the two strings.
14447         (re_search_stub): Check for overflow when adding START
14448         to RANGE; if it occurs, substitute the extreme value.
14449
14450 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14451
14452         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
14453
14454 2005-08-31  Jim Meyering  <jim@meyering.net>
14455
14456         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
14457         a pointer-to-const.
14458         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
14459         (register_state): Likewise.
14460         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
14461         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
14462         (group_nodes_into_DFAstates): Likewise.
14463
14464 2005-08-31  Jim Meyering  <jim@meyering.net>
14465
14466         * check-module: Add a FIXME comment.
14467
14468 2005-08-31  Eric Blake  <ebb9@byu.net>
14469
14470         * modules/unistd-safer (Files): Add unistd--.h.
14471         * modules/stdio-safer (Files): Add stdio--.h.
14472
14473 2005-08-31  Derek Price  <derek@ximbiot.com>
14474
14475         * lib/getdelim.c (getdelim): Return EOF on EOF.
14476         Reported by Larry Jones <lawrence.jones@ugs.com>.
14477
14478 2005-08-31  Bruno Haible  <bruno@clisp.org>
14479
14480         Avoid unnecessary diffs in the generated lib/Makefile.am.
14481         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
14482         the generated files.
14483         (func_import): Don't set cmd.
14484
14485 2005-08-31  Bruno Haible  <bruno@clisp.org>
14486
14487         * lib/strstr.c: Include <stddef.h>, for NULL.
14488         * lib/strcasestr.c: Likewise.
14489         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
14490
14491 2005-08-31  Bruno Haible  <bruno@clisp.org>
14492
14493         * gnulib-tool: New option --macro-prefix.
14494         (func_import): Use macro_prefix.
14495         (import): Handle option --macro-prefix.
14496
14497 2005-08-31  Bruno Haible  <bruno@clisp.org>
14498
14499         * gnulib-tool (import): Rename most ac_* variables to cached_*.
14500         Also use new variables cached_lgpl, cached_libtool.
14501
14502 2005-08-31  Bruno Haible  <bruno@clisp.org>
14503
14504         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
14505         always instantiating them.
14506
14507 2005-08-31  Bruno Haible  <bruno@clisp.org>
14508
14509         * gnulib-tool (func_import): Read the previous cached settings
14510         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
14511         earlier added by gnulib but are now dropped. Warn when a gnulib file
14512         overwrites a non-gnulib file.
14513
14514 2005-08-31  Bruno Haible  <bruno@clisp.org>
14515
14516         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
14517         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
14518         projects that don't keep autogenerated files in CVS. Put into
14519         actioncmd only the specified modules, not the transitive closure.
14520
14521 2005-08-31  Bruno Haible  <bruno@clisp.org>
14522
14523         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
14524         Create directories that shall be filled.
14525         (import): Don't look for gl_* macros in configure.ac. Recurse across
14526         all directories containing a gnulib-cache.m4 files, if meaningful.
14527
14528 2005-08-31  Bruno Haible  <bruno@clisp.org>
14529
14530         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
14531         (import): Set seen_libtool when we see gl_LIBTOOL.
14532
14533 2005-08-31  Bruno Haible  <bruno@clisp.org>
14534
14535         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
14536         declaration macro definitions from generated gnulib.m4.
14537
14538 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
14539
14540         * lib/iconvme.h: Add prototype for iconv_alloc.
14541
14542 2005-08-29  Simon Josefsson  <jas@extundo.com>
14543
14544         * lib/iconvme.c: Fix errno.
14545
14546 2005-08-29  Bruno Haible  <bruno@clisp.org>
14547
14548         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
14549         that it works when the directory contains spaces.
14550
14551 2005-08-29  Bruno Haible  <bruno@clisp.org>
14552
14553         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
14554
14555 2005-08-29  Bruno Haible  <bruno@clisp.org>
14556
14557         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
14558         Emit more advice.
14559
14560 2005-08-29  Bruno Haible  <bruno@clisp.org>
14561         and Stepan Kasal  <kasal@ucw.cz>
14562
14563         * check-module: If more parameters are given, check each of them
14564         separately; add more exceptions, as noted by Jim Meyering.
14565         (check_module): New procedure.
14566         (%exempt_header): Now contains all exceptions.
14567
14568 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
14569
14570         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
14571
14572 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14573
14574         * lib/iconvme.c: Split iconv_string into iconv_alloc.
14575
14576 2005-08-28  Bruno Haible  <bruno@clisp.org>
14577
14578         * m4/gnulib-tool.m4: New file.
14579
14580 2005-08-27  Jim Meyering  <jim@meyering.net>
14581
14582         * modules/unistd-safer (Files): Add pipe-safer.c.
14583         * modules/fcntl-safer (Files): Add creat-safer.c.
14584
14585 2005-08-27  Jim Meyering  <jim@meyering.net>
14586
14587         * m4/stdlib-safer.m4: New file.  From coreutils.
14588         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
14589         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
14590         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
14591         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
14592         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
14593
14594 2005-08-27  Jim Meyering  <jim@meyering.net>
14595
14596         * lib/fopen-safer.c: Merge minor changes from coreutils.
14597         * lib/dup-safer.c: Likewise.
14598         * lib/fd-safer.c: Likewise.
14599
14600         Merge from coreutils.
14601         * lib/stdio--.h: New file.
14602         * lib/stdlib--.h: New file.
14603         * lib/mkstemp-safer.c: New file.
14604
14605         GNU tar needs these.
14606         * lib/pipe-safer.c: New file.
14607         * lib/creat-safer.c: New file.
14608         * lib/fcntl--.h (creat): Define to creat_safer.
14609         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
14610         * lib/unistd--.h (pipe): Define to pipe_safer.
14611         * lib/unistd-safer.h: Declare pipe_safer.
14612
14613 2005-08-26  Simon Josefsson  <jas@extundo.com>
14614
14615         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
14616         Haible <bruno@clisp.org>.
14617
14618 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
14619
14620         * lib/regex_internal.h: Remove all references to
14621         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
14622         or better.
14623         (bitset_not, bitset_merge, bitset_not_merge):
14624         (bitset_mask, re_string_allocate, re_string_construct):
14625         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
14626         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
14627         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
14628         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
14629         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14630         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14631         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
14632         (re_acquire_state_context):
14633         Remove unnecessary forward decls.
14634         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
14635         Put __attribute at function definition,
14636         now that the function decl has been removed.
14637         * lib/regex_internal.c (re_string_peek_byte_case):
14638         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
14639         Likewise.
14640
14641 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
14642
14643         * m4/regex.m4: Add AC_PREREQ(2.50).
14644         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
14645
14646 2005-08-25  Simon Josefsson  <jas@extundo.com>
14647
14648         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
14649         __fsetlocking.
14650
14651 2005-08-25  Simon Josefsson  <jas@extundo.com>
14652
14653         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
14654         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
14655         GLIBC specific code.
14656
14657 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14658
14659         Make regex safe for g++.  This fixes one real bug (an "err"
14660         that should have been "*err").  g++ problem reported by
14661         Sam Steingold.
14662         * lib/regex_internal.h (re_calloc): New macro, consistent with
14663         re_malloc etc.  All callers of calloc changed to use re_calloc.
14664         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
14665         not int.  All callers changed.
14666         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
14667         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
14668         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
14669         (find_recover_state): Change "err" to "*err"; this fixes what
14670         appears to be a real bug.
14671         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
14672         versus int.
14673
14674 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14675
14676         * modules/regex (Depends-on): Add malloc, since the code
14677         assumes that !malloc(0) means failure.
14678
14679 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14680
14681         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
14682
14683         alloca modernization/simplification for regex.
14684         * lib/regex.c: Remove portability cruft for alloca.  This no longer
14685         needs to be at the start of the file, and can be moved into
14686         regex_internal.h and simplified.
14687         * lib/regex_internal.h: Include <alloca.h>.
14688         (__libc_use_alloca) [!defined _LIBC]: New macro.
14689         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
14690         now works outside glibc.
14691
14692 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14693
14694         * config/srclist.txt: Add glibc bugs 1241, 1245.
14695
14696 2005-08-25  Jim Meyering  <jim@meyering.net>
14697
14698         * lib/open-safer.c: Include <config.h>.
14699         Otherwise, we'd lose LARGEFILE support in any file using
14700         e.g. "fcntl--.h"
14701
14702 2005-08-25  Bruno Haible  <bruno@clisp.org>
14703
14704         * m4/minmax.m4: Require autoconf 2.52.
14705         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
14706         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
14707         alternatives of translit over the alphabet.
14708         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
14709
14710 2005-08-24  Simon Josefsson  <jas@extundo.com>
14711
14712         * tests/test-getpass.c: New file.
14713
14714 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14715
14716         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
14717         for GNU regex features.
14718
14719 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14720
14721         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
14722         * lib/regex.h (regerror): Likewise.
14723
14724         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
14725         requires this.  (The code never needed it.)
14726
14727         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
14728         All uses of recently-renamed identifiers changed to use the new,
14729         POSIX-compliant names.  The code will build and run just fine
14730         without these changes, but it's better to eat our own dog food
14731         and use the standard-conforming names.
14732
14733         * lib/regex.h: Fix a multitude of POSIX name space violations.
14734         These changes have an effect only for programs that define
14735         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
14736         do not change anything for programs compiled in the normal way.
14737         Also, there is no effect on the ABI.
14738
14739         (_REGEX_SOURCE): New macro.
14740         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
14741         defined and _GNU_SOURCE is not; this fixes a name space violation.
14742
14743         Rename the following macros to obey POSIX requirements.
14744         The old names are still visible as macros if _REGEX_SOURCE is defined.
14745         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
14746         RE_BACKSLASH_ESCAPE_IN_LISTS.
14747         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
14748         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
14749         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
14750         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
14751         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
14752         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
14753         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
14754         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
14755         (REG_INTERVALS): renamed from RE_INTERVALS.
14756         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
14757         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
14758         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
14759         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
14760         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
14761         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
14762         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
14763         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
14764         RE_UNMATCHED_RIGHT_PAREN_ORD.
14765         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
14766         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
14767         (REG_DEBUG): renamed from RE_DEBUG.
14768         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
14769         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
14770         unusual, since we can't clash with the POSIX REG_ICASE.
14771         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
14772         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
14773         (REG_NO_SUB): renamed from RE_NO_SUB.
14774         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
14775         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
14776         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
14777         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
14778         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
14779         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
14780         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
14781         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
14782         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
14783         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
14784         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
14785         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
14786         RE_SYNTAX_POSIX_MINIMAL_BASIC.
14787         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
14788         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
14789         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
14790         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
14791         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
14792         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
14793         (REG_FIXED): Renamed from REGS_FIXED.
14794         (REG_NREGS): Renamed from RE_NREGS.
14795
14796         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
14797         of other REG_* macros, since POSIX says the user is allowed to
14798         #undef these macros selectively.
14799
14800         (reg_errcode_t): Update comment stating what other tables need
14801         to be consistent.
14802
14803         Rename the following enum values to obey POSIX requirements.
14804         The old names are still visible as macros.
14805         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
14806         is not defined, since GNU is supposed to be a superset of POSIX as
14807         much as possible, and since we want reg_errcode_t to be a signed
14808         type for implementation consistency.
14809         (_REG_NOERROR): Renamed from REG_NOERROR.
14810         (_REG_NOMATCH): Renamed from REG_NOMATCH.
14811         (_REG_BADPAT): Renamed from REG_BADPAT.
14812         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
14813         (_REG_ECTYPE): Renamed from REG_ECTYPE.
14814         (_REG_EESCAPE): Renamed from REG_EESCAPE.
14815         (_REG_ESUBREG): Renamed from REG_ESUBREG.
14816         (_REG_EBRACK): Renamed from REG_EBRACK.
14817         (_REG_EPAREN): Renamed from REG_EPAREN.
14818         (_REG_EBRACE): Renamed from REG_EBRACE.
14819         (_REG_BADBR): Renamed from REG_BADBR.
14820         (_REG_ERANGE): Renamed from REG_ERANGE.
14821         (_REG_ESPACE): Renamed from REG_ESPACE.
14822         (_REG_BADRPT): Renamed from REG_BADRPT.
14823         (_REG_EEND): Renamed from REG_EEND.
14824         (_REG_ESIZE): Renamed from REG_ESIZE.
14825         (_REG_ERPAREN): Renamed from REG_ERPAREN.
14826         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
14827         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
14828         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
14829         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
14830
14831         (_REG_RE_NAME, _REG_RM_NAME): New macros.
14832         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
14833         changed.  But support the old name if the new one is not defined
14834         and if _REGEX_SOURCE.
14835
14836         Change the following member names in struct re_pattern_buffer.
14837         The old names are still supported if !_REGEX_SOURCE.
14838         The new names are always supported, regardless of _REGEX_SOURCE.
14839         (re_buffer): Renamed from buffer.
14840         (re_allocated): Renamed from allocated.
14841         (re_used): Renamed from used.
14842         (re_syntax): Renamed from syntax.
14843         (re_fastmap): Renamed from fastmap.
14844         (re_translate): Renamed from translate.
14845         (re_can_be_null): Renamed from can_be_null.
14846         (re_regs_allocated): Renamed from regs_allocated.
14847         (re_fastmap_accurate): Renamed from fastmap_accurate.
14848         (re_no_sub): Renamed from no_sub.
14849         (re_not_bol): Renamed from not_bol.
14850         (re_not_eol): Renamed from not_eol.
14851         (re_newline_anchor): Renamed from newline_anchor.
14852
14853         Change the following member names in struct re_registers.
14854         The old names are still supported if !_REGEX_SOURCE.
14855         The new names are always supported, regardless of _REGEX_SOURCE.
14856         (rm_num_regs): Renamed from num_regs.
14857         (rm_start): Renamed from start.
14858         (rm_end): Renamed from end.
14859
14860         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
14861         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
14862         Prepend __ to parameter names.
14863
14864         Undo yesterday's changes.
14865
14866 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14867
14868         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
14869         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
14870         lib/regex.c.
14871
14872 2005-08-24  Jim Meyering  <jim@meyering.net>
14873
14874         Sync from coreutils.
14875         * m4/fcntl-safer.m4: New file.
14876
14877         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
14878         and object files for this module.
14879
14880 2005-08-24  Jim Meyering  <jim@meyering.net>
14881
14882         Sync from coreutils.
14883         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
14884
14885 2005-08-24  Jim Meyering  <jim@meyering.net>
14886
14887         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
14888         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
14889
14890 2005-08-24  Jim Meyering  <jim@meyering.net>
14891
14892         * modules/fcntl-safer: New module.
14893         * modules/fts (Depends-on): Add fcntl-safer.
14894         * MODULES.html.sh (File descriptor based Input/Output):
14895         Add fcntl-safer.
14896
14897 2005-08-24  Bruno Haible  <bruno@clisp.org>
14898
14899         Support for unit test modules.
14900         * modules/README: Mention tests modules.
14901         * modules/TEMPLATE-TESTS: New file.
14902         * gnulib-tool: New options --extract-tests-module, --with-tests and
14903         --tests-base (unused for the moment).
14904         (testsbase, inctests): New variables.
14905         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
14906         (func_verify_module): Exclude TEMPLATE-TESTS.
14907         (func_verify_nontests_module, func_verify_tests_module): New functions.
14908         (func_get_dependencies): Add implicit dependency for tests modules.
14909         (func_get_tests_module): New function.
14910         (func_modules_transitive_closure): When --with-tests was specified,
14911         include the unit tests as well, unless explicitly avoided.
14912         (func_emit_lib_Makefile_am): Ignore the tests modules here.
14913         (func_emit_tests_Makefile_am): New function.
14914         (func_create_testdir): When --with-tests was specified, emit a
14915         tests/ directory.
14916         * MODULES.html.sh (Future developments): Update.
14917
14918 2005-08-24  Bruno Haible  <bruno@clisp.org>
14919
14920         * modules/tls-tests: New file.
14921         * tests/test-tls.c: New file, from GNU gettext.
14922
14923 2005-08-24  Bruno Haible  <bruno@clisp.org>
14924
14925         * modules/lock-tests: New file.
14926         * tests/test-lock.c: New file, from GNU gettext.
14927
14928 2005-08-24  Bruno Haible  <bruno@clisp.org>
14929
14930         * lib/lock.h: Add multiple inclusion guard.
14931         * lib/tls.h: Add multiple inclusion guard.
14932
14933 2005-08-24  Bruno Haible  <bruno@clisp.org>
14934
14935         * gnulib-tool: Add support for the --aux-dir option to
14936         --create-testdir, --create-megatestdir, --test, --megatest.
14937         (func_create_testdir, func_create_megatestdir): Optionally emit a
14938         AC_CONFIG_AUX_DIR directive.
14939         (create-testdir, create-megatestdir, test, megatest): Provide a
14940         default value for $auxdir.
14941
14942 2005-08-24  Bruno Haible  <bruno@clisp.org>
14943
14944         * gnulib-tool (import): Use compound statement instead of subshell
14945         where possible.
14946
14947 2005-08-24  Bruno Haible  <bruno@clisp.org>
14948
14949         * gnulib-tool (import): Change --aux-dir default to "build-aux".
14950
14951 2005-08-24  Bruno Haible  <bruno@clisp.org>
14952
14953         * gnulib-tool (func_version): Update.
14954
14955 2005-08-24  Bruno Haible  <bruno@clisp.org>
14956
14957         * gnulib-tool (func_import, func_create_testdir,
14958         func_create_megatestdir): Quote all autoconf macro arguments.
14959
14960 2005-08-24  Bruno Haible  <bruno@clisp.org>
14961
14962         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
14963         option --force, because --force causes the aclocal.m4 of each
14964         subdirectory to be newer than the corresponding config.h.in.
14965
14966 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14967
14968         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
14969         All contents moved to gl_REGEX.
14970         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
14971         assume that it does.
14972
14973 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14974
14975         * lib/regex.h (REG_NOSYS)
14976         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
14977         Define, since POSIX requires it as of 2001.
14978         (_REG_ENOSYS)
14979         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
14980         New private symbol, used to keep the enum signed in all cases.
14981         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
14982         Youngman in
14983         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
14984
14985         * lib/regex_internal.c (re_string_skip_chars, register_state):
14986         (calc_state_hash):
14987         Remove forward decls; no longer needed now that we use prototypes.
14988         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
14989         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
14990         (clean_state_log_if_needed): Likewise.
14991
14992 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14993
14994         * config/srclist.txt: Add glibc bugs 1231-1233.
14995
14996 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
14997
14998         Fix problems reported by Sam Steingold in
14999         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
15000         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
15001         assumed that reg_errcode_t is a signed type, which is not
15002         necessarily true if _XOPEN_SOURCE is not defined.
15003         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
15004         since some compilers warn about it otherwise.
15005
15006 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15007
15008         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
15009         (init_word_char, create_initial_state, duplicate_node_closure):
15010         (fetch_token, peek_token_bracket, build_range_exp):
15011         (build_collating_symbol): Remove forward decls; no longer needed
15012         now that we use prototypes.
15013
15014         * lib/regcomp.c:
15015         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
15016         (re_compile_fastmap_iter, regcomp, regerror, regfree):
15017         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
15018         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
15019         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
15020         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
15021         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
15022         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
15023         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
15024         (build_range_exp, build_collating_symbol, parse_bracket_exp):
15025         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
15026         (build_charclass, build_charclass_op, fetch_number, create_tree):
15027         (create_token_tree, mark_opt_subexp, duplicate_tree):
15028         Use prototypes rather than old-style definitions.
15029
15030         * lib/regex_internal.c:
15031         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
15032         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
15033         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
15034         (re_string_reconstruct, re_string_peek_byte_case):
15035         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
15036         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
15037         (re_node_set_init_copy, re_node_set_add_intersect):
15038         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15039         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15040         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
15041         (re_acquire_state, re_acquire_state_context, register_state):
15042         (create_ci_newstate, create_cd_newstate, free_state):
15043         Likewise.
15044         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
15045         re_search_2):
15046         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
15047         (re_search_internal, prune_impossible_nodes):
15048         (acquire_init_state_context, check_matching, static):
15049         (check_halt_node_context, check_halt_state_context, proceed_next_node):
15050         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
15051         (update_regs, sift_states_backward, build_sifted_states):
15052         (clean_state_log_if_needed, merge_state_array):
15053         (update_cur_sifted_state, add_epsilon_src_nodes):
15054         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
15055         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
15056         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
15057         (find_recover_state, check_subexp_matching_top, transit_state_mb):
15058         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
15059         (check_arrival, check_arrival_add_next_nodes):
15060         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
15061         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
15062         (check_node_accept_bytes, check_node_accept, extend_buffers):
15063         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
15064         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
15065         (sift_ctx_init):
15066         Likewise.
15067
15068         * lib/regex_internal.h:
15069         (re_string_allocate, re_string_construct, re_string_reconstruct):
15070         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
15071         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
15072         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
15073         (re_string_context_at, re_string_peek_byte_case):
15074         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
15075         is defined, since we now use prototypes always.
15076
15077         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
15078         C89 or better.  All uses removed.
15079
15080 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15081
15082         * config/srclist.txt: Add glibc bugs 1220-1227.
15083
15084 2005-08-20  Jim Meyering  <jim@meyering.net>
15085
15086         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
15087         of unused local, dfa.
15088
15089 2005-08-20  Bruno Haible  <bruno@clisp.org>
15090
15091         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
15092
15093 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15094
15095         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
15096         (re_node_set_insert_last, re_dfa_add_node):
15097         Rename local variables to avoid GCC shadowing warnings.
15098
15099 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15100
15101         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
15102         [defined lint]: Suppress bogus uninitialized-variable warnings.
15103
15104         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
15105         and let the caller return REG_ESPACE if out of space.  This
15106         removes an uninitialied-variable warning with GCC 4.0.1, and also
15107         avoids taking the address of a local variable.  All callers
15108         changed.
15109
15110 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15111
15112         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
15113         $LIBCSRC/posix/regexec.c.
15114         Add glibc bug 1217 for regcomp.c.
15115
15116 2005-08-19  Jim Meyering  <jim@meyering.net>
15117
15118         * lib/regexec.c (proceed_next_node): Redo local variables to
15119         avoid GCC shadowing warnings.
15120
15121 2005-08-18  Bruno Haible  <bruno@clisp.org>
15122
15123         * lib/strstr.c (strstr): Fix return value in multibyte case.
15124         * lib/strcasestr.c (strcasestr): Likewise.
15125
15126 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
15127
15128         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
15129
15130 2005-08-17  Jim Meyering  <jim@meyering.net>
15131
15132         Make the %s format (seconds since the epoch) work for a negative
15133         number and when used with a zero-padded field width, e.g. %015s.
15134
15135         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
15136         label so that it precedes the code to set `digits'.  Otherwise,
15137         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
15138         print `00-22'.  Now, it prints `-0022', as it should.
15139
15140 2005-08-17  Bruno Haible  <bruno@clisp.org>
15141
15142         * modules/strstr (Files): Add m4/mbrtowc.m4.
15143         (Depends-on): Add mbuiter.
15144
15145 2005-08-17  Bruno Haible  <bruno@clisp.org>
15146
15147         * modules/strcasestr: New file.
15148         * MODULES.html.sh (String handling, based on ANSI C 89): Add
15149         strcasestr.
15150
15151 2005-08-17  Bruno Haible  <bruno@clisp.org>
15152
15153         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
15154
15155 2005-08-17  Bruno Haible  <bruno@clisp.org>
15156
15157         * modules/mbuiter: New file.
15158         * MODULES.html.sh (Extended multibyte and wide character utilities):
15159         Add mbuiter.
15160
15161 2005-08-17  Bruno Haible  <bruno@clisp.org>
15162
15163         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
15164         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
15165
15166 2005-08-17  Bruno Haible  <bruno@clisp.org>
15167
15168         * m4/strcasestr.m4: New file.
15169
15170 2005-08-17  Bruno Haible  <bruno@clisp.org>
15171
15172         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
15173         * lib/strstr.c: Completely rewritten, with multibyte locale support.
15174
15175 2005-08-17  Bruno Haible  <bruno@clisp.org>
15176
15177         * lib/strcasestr.h: New file.
15178         * lib/strcasestr.c: New file.
15179
15180 2005-08-17  Bruno Haible  <bruno@clisp.org>
15181
15182         * lib/strcasecmp.c: Use mbuiter.h.
15183
15184 2005-08-17  Bruno Haible  <bruno@clisp.org>
15185
15186         * lib/mbuiter.h: New file.
15187
15188 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
15189
15190         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
15191         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
15192         and gl_GETOPT are both invoked via different paths (as happens
15193         with GNU tar CVS because it uses both argp and getopt), the former
15194         wins.
15195
15196 2005-08-16  Bruno Haible  <bruno@clisp.org>
15197
15198         * modules/tls: New file.
15199         * MODULES.html.sh (Multithreading): Add tls.
15200
15201 2005-08-16  Bruno Haible  <bruno@clisp.org>
15202
15203         * modules/strnlen1: New file.
15204         * MODULES.html.sh (String handling): Add strnlen1.
15205
15206 2005-08-16  Bruno Haible  <bruno@clisp.org>
15207
15208         * modules/strcase (Files): Add m4/mbrtowc.m4.
15209         (Depends-on): Add strnlen1, mbchar.
15210
15211 2005-08-16  Bruno Haible  <bruno@clisp.org>
15212
15213         * modules/mbiter: New file.
15214         * MODULES.html.sh (Extended multibyte and wide character utilities):
15215         Add mbiter.
15216
15217 2005-08-16  Bruno Haible  <bruno@clisp.org>
15218
15219         * modules/mbfile: New file.
15220         * MODULES.html.sh (Extended multibyte and wide character utilities):
15221         Add mbfile.
15222
15223 2005-08-16  Bruno Haible  <bruno@clisp.org>
15224
15225         * modules/mbchar: New file.
15226         * MODULES.html.sh (Extended multibyte and wide character utilities):
15227         New section.
15228
15229 2005-08-16  Bruno Haible  <bruno@clisp.org>
15230
15231         * m4/tls.m4: New file, from GNU gettext.
15232
15233 2005-08-16  Bruno Haible  <bruno@clisp.org>
15234
15235         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
15236         always.
15237         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
15238
15239 2005-08-16  Bruno Haible  <bruno@clisp.org>
15240
15241         * m4/mbiter.m4: New file.
15242
15243 2005-08-16  Bruno Haible  <bruno@clisp.org>
15244
15245         * m4/mbfile.m4: New file.
15246
15247 2005-08-16  Bruno Haible  <bruno@clisp.org>
15248
15249         * m4/mbchar.m4: New file.
15250
15251 2005-08-16  Bruno Haible  <bruno@clisp.org>
15252
15253         * lib/tls.h: New file, from GNU gettext.
15254         * lib/tls.c: New file, from GNU gettext.
15255
15256 2005-08-16  Bruno Haible  <bruno@clisp.org>
15257
15258         * lib/strnlen1.h: New file.
15259         * lib/strnlen1.c: New file.
15260
15261 2005-08-16  Bruno Haible  <bruno@clisp.org>
15262
15263         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
15264         (mbi_init): Update.
15265         (mbi_avail, mbi_advance): Let the iteration end before the terminating
15266         NUL byte, not after it.
15267
15268 2005-08-16  Bruno Haible  <bruno@clisp.org>
15269
15270         * lib/strcase.h (strcasecmp): Add note in comments.
15271         * lib/strncasecmp.c: Use code from strcasecmp.c.
15272         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
15273         (strcasecmp): Work correctly in multibyte locales.
15274
15275 2005-08-16  Bruno Haible  <bruno@clisp.org>
15276
15277         * lib/mbiter.h: New file.
15278
15279 2005-08-16  Bruno Haible  <bruno@clisp.org>
15280
15281         * lib/mbfile.h: New file.
15282
15283 2005-08-16  Bruno Haible  <bruno@clisp.org>
15284
15285         * lib/mbchar.h: New file.
15286         * lib/mbchar.c: New file.
15287
15288 2005-08-16  Bruno Haible  <bruno@clisp.org>
15289
15290         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
15291         the valid ones. Makes the comparison operations transitive:
15292         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
15293         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
15294
15295 2005-08-15  Simon Josefsson  <jas@extundo.com>
15296
15297         * modules/ssize_t (License): Change to 'unlimited'.
15298
15299         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
15300
15301 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
15302
15303         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
15304         Add comments for each pending glibc patch.
15305
15306 2005-08-15  Bruno Haible  <bruno@clisp.org>
15307
15308         * lib/regex.h (__restrict_arr): Don't define to __restrict if
15309         __cplusplus is defined.
15310
15311 2005-08-14  Jim Meyering  <jim@meyering.net>
15312
15313         Sync from coreutils.
15314
15315         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
15316         Use the hash-table-based cycle-detection code not just when
15317         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
15318         Reported by James Youngman in
15319         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
15320         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
15321         FTS_TIGHT_CYCLE_CHECK.
15322         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
15323         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
15324         once again.
15325         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
15326         * lib/fts.c (fd_safer): Remove decl.
15327         Include fcntl--.h rather than unistd-safer.h
15328         (fts_safe_changedir): Don't call fd_safer; no longer needed
15329         now that we include fcntl--.h.
15330
15331 2005-08-12  Simon Josefsson  <jas@extundo.com>
15332
15333         * modules/getndelim2: Use ssize_t module.
15334         * modules/getnline: Likewise.
15335         * modules/safe-read: Likewise.
15336         * modules/xreadlink: Likewise.
15337
15338         * modules/ssize_t: New file.
15339
15340 2005-08-12  Simon Josefsson  <jas@extundo.com>
15341
15342         * m4/readline.m4: Look for termcap, curses or ncurses if required.
15343
15344 2005-08-12  Simon Josefsson  <jas@extundo.com>
15345
15346         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15347         ssize_t.
15348
15349 2005-08-12  Simon Josefsson  <jas@extundo.com>
15350
15351         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
15352         readline, getdelim and check_version.
15353         (Support for systems lacking ISO C 99: Sizes of integer types):
15354         Add size_max.
15355
15356 2005-08-12  Bruno Haible  <bruno@clisp.org>
15357
15358         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
15359
15360 2005-08-11  Simon Josefsson  <jas@extundo.com>
15361
15362         * modules/readline: New file.
15363
15364         * modules/strnlen (Files): Add strnlen.h.
15365
15366 2005-08-11  Simon Josefsson  <jas@extundo.com>
15367
15368         * m4/readline.m4: New file.
15369
15370 2005-08-11  Simon Josefsson  <jas@extundo.com>
15371
15372         * lib/readline.h, readline.c: New file.
15373
15374 2005-08-11  Simon Josefsson  <jas@extundo.com>
15375
15376         * doc/gnulib.texi (Initial import, Finishing touches): Mention
15377         gl_AVOID.
15378
15379 2005-08-11  Bruno Haible  <bruno@clisp.org>
15380
15381         * lib/strnlen.h (strnlen): Change parameter name to match comment.
15382
15383 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
15384
15385         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
15386
15387 2005-08-10  Simon Josefsson  <jas@extundo.com>
15388
15389         * tests/test-iconvme.c: New file.
15390
15391 2005-08-10  Simon Josefsson  <jas@extundo.com>
15392
15393         * m4/strnlen.m4: New file.
15394
15395         * m4/strndup.m4: Don't check for strnlen declaration, done in
15396         strnlen.m4.
15397
15398 2005-08-10  Simon Josefsson  <jas@extundo.com>
15399
15400         * lib/strndup.c: Use strnlen.h.
15401
15402         * lib/strnlen.h: New file.
15403
15404 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15405
15406         * README: Typos.
15407
15408 2005-08-02  Simon Josefsson  <jas@extundo.com>
15409
15410         * modules/readline: New file.
15411
15412 2005-08-02  Simon Josefsson  <jas@extundo.com>
15413
15414         * modules/getdelim: New file.
15415
15416         * modules/getline: Rewrite, don't use getndelim2.
15417
15418 2005-08-02  Simon Josefsson  <jas@extundo.com>
15419
15420         * m4/getline.m4: Separate out getdelim stuff into separate module.
15421
15422         * m4/getdelim.m4: New file.
15423
15424 2005-08-02  Simon Josefsson  <jas@extundo.com>
15425
15426         * lib/getline.h, getline.c: Rewrite.
15427
15428         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
15429
15430 2005-07-31  Bruno Haible  <bruno@clisp.org>
15431
15432         * lib/lock.h (gl_lock_initializer): New macro.
15433         (gl_lock_define_initialized): Use it.
15434         (gl_rwlock_initializer): New macro.
15435         (gl_rwlock_define_initialized): Use it.
15436         (gl_recursive_lock_initializer): New macro.
15437         (gl_recursive_lock_define_initialized): Use it.
15438
15439 2005-07-30  Karl Berry  <karl@gnu.org>
15440
15441         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
15442         Report from Ben Pfaff, regarding getopt.
15443
15444 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
15445
15446         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
15447         normal way.
15448         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
15449         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
15450         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
15451         (gl_GETOPT): Use the new macros.  Most of the implementation
15452         is moved to the new macros.  This is for programs like Emacs
15453         that don't want all the functionality of gl_GETOPT.
15454
15455 2005-07-26  Bruno Haible  <bruno@clisp.org>
15456
15457         * m4/lock.m4: Update from GNU gettext.
15458
15459 2005-07-26  Bruno Haible  <bruno@clisp.org>
15460
15461         * lib/lock.h: Update from GNU gettext.
15462         * lib/lock.c: Update from GNU gettext.
15463
15464 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
15465
15466         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
15467         obsolescent AC_TRY_RUN.  Include the default includes files, for
15468         'exit'.
15469
15470 2005-07-24  Bruno Haible  <bruno@clisp.org>
15471
15472         * modules/visibility: New file.
15473         * MODULES.html.sh (Misc): Add visibility.
15474
15475 2005-07-24  Bruno Haible  <bruno@clisp.org>
15476
15477         * m4/visibility.m4: New file.
15478
15479 2005-07-24  Bruno Haible  <bruno@clisp.org>
15480
15481         * doc/visibility.texi: New file.
15482
15483 2005-07-22  Bruno Haible  <bruno@clisp.org>
15484
15485         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
15486         $(ALLOCA_H), redundant through BUILT_SOURCES.
15487         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
15488         redundant through BUILT_SOURCES.
15489         * modules/byteswap (Makefile.am): Remove explicit dependency on
15490         $(BYTESWAP_H), redundant through BUILT_SOURCES.
15491         * modules/fnmatch (Makefile.am): Remove explicit dependency on
15492         $(FNMATCH_H), redundant through BUILT_SOURCES.
15493         * modules/getopt (Makefile.am): Remove explicit dependency on
15494         $(GETOPT_H), redundant through BUILT_SOURCES.
15495         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
15496         redundant through BUILT_SOURCES.
15497         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
15498         redundant through BUILT_SOURCES.
15499         * modules/stdbool (Makefile.am): Remove explicit dependency on
15500         $(STDBOOL_H), redundant through BUILT_SOURCES.
15501         * modules/stdint (Makefile.am): Remove explicit dependency on
15502         $(STDINT_H), redundant through BUILT_SOURCES.
15503         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
15504         Remove explicit dependency on $(SYSEXITS_H).
15505         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
15506
15507 2005-07-18  Simon Josefsson  <jas@extundo.com>
15508
15509         * lib/check-version.c (check_version): Accept identical versions too.
15510
15511 2005-07-18  Bruno Haible  <bruno@clisp.org>
15512
15513         * modules/lock: New file.
15514         * MODULES.html.sh (Multithreading): New section.
15515
15516 2005-07-18  Bruno Haible  <bruno@clisp.org>
15517
15518         * m4/lock.m4: New file, from GNU gettext.
15519
15520 2005-07-18  Bruno Haible  <bruno@clisp.org>
15521
15522         * lib/lock.h: New file, from GNU gettext.
15523         * lib/lock.c: New file, from GNU gettext.
15524
15525 2005-07-18  Bruno Haible  <bruno@clisp.org>
15526
15527         * lib/lock.h (gl_once_t): New type.
15528         (gl_once_define, gl_once): New macros.
15529         * lib/lock.c (fresh_once): New variable.
15530         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
15531         functions.
15532
15533 2005-07-16  Simon Josefsson  <jas@extundo.com>
15534
15535         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
15536         workaround, suggested by Bruno.
15537
15538 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
15539
15540         * modules/xalloc (Depends-on): Add xalloc-die.
15541         * modules/xvasprintf (Depends-on): Add xalloc-die.
15542
15543 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
15544
15545         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
15546         with a minor change.
15547
15548 2005-07-15  Bruno Haible  <bruno@clisp.org>
15549
15550         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
15551         When using lib/poll.c, define poll as rpl_poll.
15552
15553 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
15554
15555         * modules/argp (Depends-on): Remove unlocked-io.
15556
15557 2005-07-14  Derek Price  <derek@ximbiot.com>
15558
15559         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
15560         for glob symlink bug.
15561
15562 2005-07-14  Bruno Haible  <bruno@clisp.org>
15563
15564         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
15565         Instead, test for *_unlocked function declarations directly.
15566
15567 2005-07-11  Simon Josefsson  <jas@extundo.com>
15568
15569         * modules/size_max: New file.
15570
15571         * modules/xsize: Depend on size_max module for size_max.m4.
15572
15573 2005-07-11  Simon Josefsson  <jas@extundo.com>
15574
15575         * lib/size_max.h: New file.
15576
15577 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
15578
15579         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
15580         copyright symbol and the year.
15581         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
15582         (version_etc_va): Use parameterized copyright notice.
15583         Reword to conform to the current GNU coding standards.
15584
15585 2005-07-11  Karl Berry  <karl@gnu.org>
15586
15587         * doc/gnulib.texi (Quoting): new node.
15588         (Initial import): more info, from Patrice.
15589
15590 2005-07-11  Bruno Haible  <bruno@clisp.org>
15591
15592         * gnulib-tool (func_usage): Document option --avoid.
15593         (Command line options): Handle --avoid.
15594         (func_acceptable): New function.
15595         (func_modules_transitive_closure): Use it.
15596
15597 2005-07-11  Bruno Haible  <bruno@clisp.org>
15598
15599         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
15600         Reported by Jim Meyering.
15601
15602 2005-07-10  Bruno Haible  <bruno@clisp.org>
15603
15604         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
15605         Needed when size_t is smaller than 'unsigned int'.
15606         Reported by Paul Eggert.
15607
15608 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15609
15610         * modules/argp (Depends-on): Add unlocked-io
15611
15612 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15613
15614         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
15615         block of defines.
15616
15617 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
15618
15619         * config/srclist.txt: Comment out regcomp.c, since we have a porting
15620         fix now.
15621
15622 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
15623         and Paul Eggert  <eggert@cs.ucla.edu>
15624
15625         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
15626         in wint_t, not wchar_t.  Remove now-unnecessary cast.
15627
15628 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15629
15630         * modules/regex (Files): Add lib/regex_internal.c,
15631         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
15632         (Depends-on): Add extensions.
15633         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
15634
15635 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15636
15637         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
15638         pathconf.
15639         * m4/same.m4 (gl_SAME): Likewise.
15640         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
15641
15642         * m4/regex.m4: Adjust to new libc regex implementation.
15643         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
15644         all the .c and .h parts of (the new) regex.
15645         Quote the m4 stuff better.
15646         Check for RE_ICASE bug of old gnulib.
15647         Check for REG_STARTEND of recent libc.
15648         Rename local variables from jm_* to gl_*.
15649         Quote operand of "test -f".
15650         Say "recent enough" version of libc, not "version 2".
15651         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
15652         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
15653         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
15654         Remove check for btowc, isascii.
15655         Require AM_LANGINFO_CODESET.
15656
15657 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15658
15659         * lib/regex.c, regex.h: Sync from libc.
15660         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
15661         * lib/regexec.c:
15662         New files, synced from libc, except that regex_internal.h
15663         currently has a small porting fix.
15664
15665 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15666
15667         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
15668         regex_internal.c, regexec.c.
15669         Add regex_internal.h too, but as a comment, since the libc version
15670         is currently broken in gnulib mode.
15671
15672 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
15673
15674         Support programs like Emacs that use gnulib but not gettext.
15675         * MODULES.html.sh (Internationalization functions): Add gettext-h.
15676         * modules/gettext-h: New file.
15677         * modules/gettext (Files): Remove lib/gettext.h.
15678         (Depends-on): Add gettext-h.
15679         (Makefile.am): Remove lib_SOURCES.
15680         * modules/argmatch, modules/c-stack, modules/closeout:
15681         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
15682         * modules/execute, modules/file-type, modules/getaddrinfo:
15683         * modules/getopt, modules/human, modules/javacomp:
15684         * modules/javaexec, modules/mkdir-p, modules/obstack:
15685         * modules/openat, modules/pagealign_alloc, modules/pipe:
15686         * modules/quotearg, modules/regex, modules/rpmatch:
15687         * modules/unicodeio, modules/userspec, modules/version-etc:
15688         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
15689         * modules/xsetenv:
15690         Depend on gettext-h, not gettext.
15691
15692 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
15693
15694         * gnulib-tool (func_import): Add support for 'public domain' license.
15695         * modules/alloca, modules/atexit, modules/memmove:
15696         Now public domain, not GPL.
15697         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
15698         * modules/realloc, modules/strerror, modules/strtod:
15699         Now LGPL, not GPL.
15700
15701 2005-07-05  Bruno Haible  <bruno@clisp.org>
15702
15703         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
15704         autoconf CVS. Needed for mingw.
15705
15706 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15707
15708         Remove the dependency of the strftime module on the tzset module.
15709         * modules/strftime (Depends-on): Remove dependency on tzset.
15710
15711 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15712
15713         Remove the dependency of the strftime module on the tzset module.
15714         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
15715         gl_FUNC_TZSET_CLOBBER.
15716
15717 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15718
15719         Remove the dependency of the strftime module on the tzset module.
15720         * lib/strftime.c (my_strftime)
15721         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
15722         Copy the input structure, to work around some of the bug with
15723         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
15724         Solaris releases, you should also use the tzset module, but we won't
15725         require it as a dependency any more since we don't want LGPLed code
15726         to depend on GPLed code.
15727
15728 2005-07-02  Jim Meyering  <jim@meyering.net>
15729
15730         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
15731         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
15732         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
15733         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
15734
15735 2005-07-02  Jim Meyering  <jim@meyering.net>
15736
15737         * lib/backupfile.c (backup_args): Change a `0' to NULL.
15738
15739 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
15740
15741         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
15742         declares only 'struct timespec;' (!).
15743
15744 2005-07-01  Jim Meyering  <jim@meyering.net>
15745
15746         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
15747         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
15748         * lib/save-cwd.c, tempname.c:
15749         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
15750         and don't include <sys/file.h>).
15751
15752 2005-06-29  Jim Meyering  <jim@meyering.net>
15753
15754         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
15755         type name.  Use the variable name instead.
15756         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
15757         Likewise.
15758
15759 2005-06-28  Simon Josefsson  <jas@extundo.com>
15760
15761         * modules/check-version (Files): Add check-version.m4.
15762
15763 2005-06-28  Simon Josefsson  <jas@extundo.com>
15764
15765         * m4/check-version.m4: New file, suggested by Jim Meyering
15766         <jim@meyering.net>.
15767
15768 2005-06-28  Simon Josefsson  <jas@extundo.com>
15769
15770         * lib/check-version.h, lib/check-version.c: New files.
15771
15772 2005-06-28  Simon Josefsson  <jas@extundo.com>
15773
15774         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
15775         collision with global variable.  Better indentation.  Don't
15776         increment buffer pointer beyond buffer end.  Based on comments
15777         from Paul Eggert <eggert@cs.ucla.edu>.
15778
15779         * lib/base64.h: Indent.
15780
15781 2005-06-28  Simon Josefsson  <jas@extundo.com>
15782
15783         * doc/gnulib.texi (Library version handling): New section.
15784
15785 2005-06-28  Jim Meyering  <jim@meyering.net>
15786
15787         * check-module (find_included_lib_files): Hard-code another
15788         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
15789         but modules/fts-lgpl (correctly) does not list those files.
15790
15791         * modules/canonicalize (Files): Add lib/pathmax.h.
15792
15793 2005-06-25  Simon Josefsson  <jas@extundo.com>
15794
15795         * modules/check-version: New file.
15796
15797 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
15798
15799         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
15800         initializer of struct addrinfo, as an indication that we don't
15801         care how many members the structure has.
15802
15803 2005-06-24  Derek Price  <derek@ximbiot.com>
15804         and Bruno Haible  <bruno@clisp.org>
15805
15806         Remove stat module & update lstat.
15807         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
15808         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
15809         * m4/stat.m4: Remove this file.
15810
15811 2005-06-24  Derek Price  <derek@ximbiot.com>
15812         and Bruno Haible  <bruno@clisp.org>
15813
15814         Remove stat module & update lstat.
15815         * lib/stat.c: Remove this file...
15816         (slash_aware_lstat): ...moving this content and its support...
15817         * lib/lstat.c (rpl_lstat): ...into here.
15818         * lib/lstat.h: New file.
15819
15820 2005-06-24  Derek Price  <derek@ximbiot.com>
15821         and Bruno Haible  <bruno@clisp.org>
15822
15823         Remove stat module & update lstat.
15824         * config/srclist.txt (libc sources): Remove stat.
15825
15826 2005-06-24  Derek Price  <derek@ximbiot.com>
15827         and Bruno Haible  <bruno@clisp.org>
15828
15829         Remove stat module & update lstat.
15830         * MODULES.html.sh (stat): Remove.
15831         * MODULES.html: Regenerated.
15832         * modules/lstat (Description): Correct function name.
15833         (Files): Add "lstat.h".
15834         (Depends-on): Remove stat, add xalloc, stat-macros.
15835         * modules/stat: Remove this file.
15836         (Include): Add "lstat.h", remove <sys/stat.h>.
15837
15838 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
15839
15840         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
15841         (ranged_convert): Don't save conversion in a temporary struct.
15842         This causes a warning with GCC 4.0.0, and anyway in the typical
15843         case it's not worth the extra 100 bytes or so of code.
15844         (ranged_convert, __mktime_internal): When calling a function via a
15845         pointer P, use P () rather than (*P) (), as we now assume C89 or
15846         better.
15847
15848 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15849
15850         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
15851         "who -r" failed to give output.  Problem reported by Tim Waugh.
15852
15853         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
15854         (xcalloc): Use it to avoid needless tests.
15855         Problem reported by Jim Meyering.
15856
15857 2005-06-20  Derek Price  <derek@ximbiot.com>
15858
15859         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
15860         unnecessary for Autoconfs > 2.59c.
15861
15862 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15863
15864         * lib/argp.h (__option_is_short): Check upper limit of
15865         __key. Isprint() requires its argument to have the value
15866         of an unsigned char or EOF.
15867
15868 2005-06-16  Jim Meyering  <jim@meyering.net>
15869
15870         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
15871         when either N or S is zero.
15872
15873 2005-06-16  Derek Price  <derek@ximbiot.com>
15874
15875         * m4/bison.m4: Declare YACC & YFLAGS precious.
15876
15877 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
15878
15879         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
15880         multibyte string or pattern, fall back on unibyte matching.
15881         Problem reported by James Youngman.
15882
15883 2005-06-08  Bruno Haible  <bruno@clisp.org>
15884
15885         * modules/csharpcomp: New file.
15886         * MODULES.html.sh (C#): Add csharpcomp.
15887
15888 2005-06-08  Bruno Haible  <bruno@clisp.org>
15889
15890         * m4/csharpcomp.m4: New file, from GNU gettext.
15891
15892 2005-06-08  Bruno Haible  <bruno@clisp.org>
15893
15894         * lib/csharpcomp.h: New file, from GNU gettext.
15895         * lib/csharpcomp.c: New file, from GNU gettext.
15896         * lib/csharpcomp.sh.in: New file, from GNU gettext.
15897
15898 2005-06-08  Bruno Haible  <bruno@clisp.org>
15899
15900         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
15901         warning on mingw.
15902
15903 2005-06-07  Derek Price  <derek@ximbiot.com>
15904
15905         Sync from CVS.
15906         * lib/glob_.h: Indent nested #ifdef.
15907
15908 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15909
15910         Sync from coreutils.
15911         Use "file name" when talking about file names, instead of "filename"
15912         or "path", as per the GNU coding standards.
15913         * lib/mkdir-p.c: Renamed from makepath.c.
15914         (make_dir_parents): Renamed from make_path.  All callers changed.
15915         * lib/mkdir-p.h: Likewise.  All includers changed.
15916         * lib/filenamecat.c: Renamed from path-concat.c.
15917         (file_name_concat): Renamed from path_concat.  All callers changed.
15918         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
15919         * lib/filenamecat.h: Likewise.  All includers changed.
15920         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
15921         in comments or local variable names.
15922         * lib/basename.c: Likewise.
15923         * lib/canonicalize.c, canonicalize.h: Likewise.
15924         * lib/dirname.c, dirname.h: Likewise.
15925         * lib/euidaccess.c: Likewise.
15926         * lib/exclude.c: Likewise
15927         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
15928         * lib/fsusage.c, fsuage.h: Likewise.
15929         * lib/fts.c, fts_.h: Likewise.
15930         * lib/getcwd.c: Likewise.
15931         * lib/getloadavg.c: Likewise.
15932         * lib/mkstemp.c: Likewise.
15933         * lib/mountlist.c, mountlist.h: Likewise.
15934         * lib/openat.c, openat.h: Likewise.
15935         * lib/readlink-stub.c: Likewise.
15936         * lib/readutmp.c, readutmp.h: Likewise.
15937         * lib/rename.c: Likewise.
15938         * lib/rmdir.c: Likewise.
15939         * lib/same.c: Likewise.
15940         * lib/savedir.c: Likewise.
15941         * lib/stripslash.c: Likewise.
15942         * lib/tempname.c: Likewise.
15943         * lib/xreadlink.c: Likewise.
15944         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
15945         All uses changed.
15946         * lib/exclude.h: Likewise.
15947
15948         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
15949         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15950         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
15951         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15952         * lib/pathmax.h: Include <limits.h> unconditionally, since other
15953         files have been getting away with it for years (MORE/BSD 4.3
15954         is extinct now).
15955         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
15956         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15957
15958         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
15959         Define to 256, not 255, as per modern POSIX.
15960
15961 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15962
15963         Sync from coreutils.
15964         Use "file name" when talking about file names, instead of "filename"
15965         or "path", as per the GNU coding standards.
15966         * MODULES.html.sh: mkdir-p renamed from makepath.
15967         filenamecat renamed from path-concat.
15968         * modules/filenamecat: Renamed from modules/path-concat.
15969         (Files): filenamecat.h and filenamecat.c renamed from
15970         path-concat.h and path-concat.c.
15971         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
15972         (Include): filenamecat.h, not path-concat.h.
15973         * modules/mkdir-p: Renamed from modules/makepath.
15974         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
15975         makepath.c.
15976         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
15977         (Include): mkdir-p.h, not makepath.h.
15978
15979 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15980
15981         Sync from coreutils.
15982         * m4/mkdir-p.m4: Renamed from makepath.m4.
15983         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
15984         Rename files from makepath.c to mkdir-p.c, and from
15985         makepath.h to mkdir-p.h.
15986         * m4/filenamecat.m4: Renamed from path-concat.m4.
15987         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
15988         Rename files from path-concat.c to filenamecat.c,
15989         and from path-concat.h to filenamecat.h.
15990         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
15991         "file name" in local variables or comments.
15992         * m4/rename.m4: Likewise.
15993
15994 2005-06-01  Bruno Haible  <bruno@clisp.org>
15995
15996         * modules/csharpexec: New file.
15997         * MODULES.html.sh (C#): New section.
15998
15999 2005-06-01  Bruno Haible  <bruno@clisp.org>
16000
16001         * m4/csharp.m4: New file, from GNU gettext.
16002         * m4/csharpexec.m4: New file, from GNU gettext.
16003
16004 2005-06-01  Bruno Haible  <bruno@clisp.org>
16005
16006         * lib/csharpexec.h: New file, from GNU gettext.
16007         * lib/csharpexec.c: New file, from GNU gettext.
16008         * lib/csharpexec.sh.in: New file, from GNU gettext.
16009
16010 2005-05-31  Derek Price  <derek@ximbiot.com>
16011             Paul Eggert  <eggert@cs.ucla.edu>
16012
16013         Sync from cvs.
16014         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
16015
16016 2005-05-31  Derek Price  <derek@ximbiot.com>
16017             Paul Eggert  <eggert@cs.ucla.edu>
16018
16019         Sync from cvs.
16020         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
16021
16022 2005-05-29  Derek Price  <derek@ximbiot.com>
16023
16024         * config/srclist.txt (glob_.h, glob.c): Add these files.
16025
16026 2005-05-29  Derek Price  <derek@ximbiot.com>
16027
16028         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
16029         * modules/glob: New file.
16030         * modules/getlogin_r: Add link to POSIX spec in description.
16031
16032 2005-05-29  Derek Price  <derek@ximbiot.com>
16033             Paul Eggert  <eggert@cs.ucla.edu>
16034
16035         * m4/glob.m4: New file.
16036
16037 2005-05-29  Derek Price  <derek@ximbiot.com>
16038             Paul Eggert  <eggert@cs.ucla.edu>
16039
16040         * lib/glob_.h, lib/glob.c: New files.
16041
16042 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16043
16044         * modules/fts (Files): Remove m4/inttypes-pri.m4.
16045         * modules/fts-lgpl (Depends-on): Remove gettext.
16046
16047 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16048
16049         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
16050         and don't require gt_INTTYPES_PRI.
16051
16052 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16053
16054         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
16055
16056         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
16057         the configuration hassle isn't worth it.
16058         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
16059         (LONGEST_MODIFIER, PRIuMAX): Remove.
16060
16061 2005-05-27  Bruno Haible  <bruno@clisp.org>
16062
16063         * lib/getlogin_r.h: Remove second include of <stddef.h>.
16064
16065 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
16066
16067         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
16068         _POSIX_PTHREAD_SEMANTICS for Solaris.
16069
16070 2005-05-25  Derek Price  <derek@ximbiot.com>
16071
16072         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
16073
16074 2005-05-25  Derek Price  <derek@ximbiot.com>
16075             Paul Eggert  <eggert@cs.ucla.edu>
16076
16077         * modules/getlogin_r, m4/getlogin_r.m4: New files.
16078         * lib/getlogin_r.c, getlogin_r.h: New files.
16079
16080 2005-05-25  Bruno Haible  <bruno@clisp.org>
16081             Derek Price  <derek@ximbiot.com>
16082
16083         * lib/getlogin_r.h: Simplify API documentation.
16084
16085 2005-05-23  Derek Price  <derek@ximbiot.com>
16086
16087         * modules/minmax (Files): Add m4/minmax.m4.
16088         (configure.ac): Add gl_MINMAX.
16089
16090 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
16091
16092         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
16093         so that unistd-safer.h (GPL'ed code) need not be included.
16094
16095 2005-05-22  Bruno Haible  <bruno@clisp.org>
16096
16097         * m4/minmax.m4: New file.
16098         Based on a patch by Derek Price <derek@ximbiot.com>.
16099
16100 2005-05-22  Bruno Haible  <bruno@clisp.org>
16101
16102         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
16103         (INT64_MIN): Fix definition.
16104         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
16105
16106         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
16107         NEED_SIGNED_INT_TYPES.
16108
16109         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
16110         HAVE_SYSTEM_INTTYPES.
16111
16112 2005-05-22  Bruno Haible  <bruno@clisp.org>
16113
16114         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
16115         Also include <sys/param.h> if it defines MIN, MAX.
16116         Based on a patch by Derek Price <derek@ximbiot.com>.
16117
16118 2005-05-21  Jim Meyering  <jim@meyering.net>
16119
16120         * modules/fts (Files): Add m4/inttypes-pri.m4.
16121         (Depends-on): Add lstat and remove gettext.  Alphabetize.
16122
16123 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16124
16125         New fts module.
16126         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
16127         (setup_dir, free_dir): New functions.
16128         (enter_dir, leave_dir): Define trivial
16129         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
16130         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
16131         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
16132         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
16133         Move to fts-cycle.c.
16134         (fts_open): Use setup_dir.
16135         (fts_close): Use free_dir.
16136         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
16137         This adds a label and some gotos, but the alternatives were messier.
16138         Check for memory allocation failure when entering a dir.
16139         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
16140         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
16141         (FTS): New member fts_cycle, that is a union that contains the
16142         old active_dir_ht and cycle_state.  All uses changed to mention
16143         fts_cycle.ht and fts_cycle.state.
16144         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
16145         fts.c, with the following changes:
16146         (setup_dir, free_dir): New functions.
16147         (enter_dir): Now returns bool.  Return true if successful, false
16148         if memory exhausted.  All callers changed.
16149         Do not bother partly cleaning up on
16150         memory allocation failure; that is free_dir's job.
16151         However, free ad if hash_insert fails, to avoid memory leak.
16152         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
16153         fts->fts_options to see which union member to use.
16154
16155 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16156
16157         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
16158         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
16159
16160 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16161
16162         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
16163
16164 2005-05-20  Jim Meyering  <jim@meyering.net>
16165
16166         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
16167         Now a macro, to pacify GCC.
16168
16169 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16170
16171         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
16172         of -1.
16173
16174 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16175
16176         * lib/chown.c (rpl_chown): Return -1 on failure.
16177
16178 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16179
16180         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
16181         Don't check for stddef.h.
16182         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
16183         don't use its results.
16184         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
16185         since we include them unconditionally.  Don't require
16186         AM_STDBOOL_H, since stdbool is a prerequisite.
16187         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
16188         since we assume C89 or better.
16189         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
16190         as we don't use their results.
16191         Don't check for fchdir, memmove, memset, strrchr, as we use
16192         them unconditionally.
16193         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
16194         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
16195
16196 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16197
16198         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
16199         Include <stddef.h> unconditionally, since we assume C89 now.
16200         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
16201         * lib/fts.c: Include fts_.h first, to check interface.
16202         Do not include intprops.h; no longer needed.
16203         Include cycle-check.h and hash.h, since fts_.h no longer does.
16204         Remove unnecessary casts of closedir to void.
16205         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
16206         decide whether to decrement nlinks.
16207         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
16208         (FTS): Use struct hash_table * instead of Hash_table, so that
16209         we no longer need to include hash.h here.
16210
16211 2005-05-18  Jim Meyering  <jim@meyering.net>
16212
16213         * modules/dirfd (License): Change to LGPL.  Most of the code
16214         is already in the public domain.
16215
16216 2005-05-18  Jim Meyering  <jim@meyering.net>
16217
16218         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
16219         Reported by Yoann Vandoorselaere.
16220
16221 2005-05-17  Jim Meyering  <jim@meyering.net>
16222
16223         * m4/fts.m4: New file, from coreutils.
16224
16225 2005-05-17  Jim Meyering  <jim@meyering.net>
16226
16227         * lib/fts.c, lib/fts_.h: New files, from coreutils.
16228
16229 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16230
16231         Sync from coreutils.
16232         * m4/unlinkdir.m4: New file.
16233
16234 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16235
16236         Sync from coreutils.
16237         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
16238         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
16239         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
16240         White space changes only.
16241         * lib/makepath.c (make_path): Port to hosts where leading "//" is
16242         special.
16243         * lib/yesno.c: Include getline.h, not ctype.h.
16244         (yesno): Don't remove leading white space; POSIX doesn't allow it.
16245         Use getline to remove arbitrary restriction on response length.
16246
16247 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16248
16249         * config/srclist-update: Spell out "Street" in FSF postal
16250         mail address; this is the style the FSF seems to prefer.
16251
16252         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
16253         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
16254         this updates FSF postal mail address.
16255
16256         Sync from coreutils.
16257         * modules/unlinkdir: New file.
16258         * modules/yesno (Depends-on): Add getline.
16259         * MODULES.html.sh (File system functions): Add unlinkdir.
16260
16261 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16262
16263         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
16264         lib/strsep.h:
16265         Change the initial comment to refer to GPL, not LGPL.
16266         gnulib-tool will change it to LGPL as needed.
16267
16268         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
16269         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
16270         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
16271         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
16272         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
16273         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
16274         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
16275         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
16276         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
16277         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
16278         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
16279         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
16280         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
16281         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
16282         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
16283         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
16284         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
16285         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
16286         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
16287         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
16288         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
16289         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
16290         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
16291         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
16292         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
16293         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
16294         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
16295         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
16296         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
16297         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
16298         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
16299         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
16300         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
16301         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
16302         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
16303         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
16304         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
16305         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
16306         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
16307         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
16308         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
16309         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
16310         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
16311         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
16312         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
16313         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
16314         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
16315         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
16316         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
16317         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
16318         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
16319         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
16320         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
16321         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
16322         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
16323         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
16324         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
16325         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
16326         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
16327         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
16328         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
16329         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
16330         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
16331         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
16332         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
16333         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
16334         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
16335         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
16336         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
16337         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
16338         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
16339         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
16340         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
16341         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
16342         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
16343         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
16344         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
16345         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
16346         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
16347         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
16348         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
16349         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
16350         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
16351         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
16352         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
16353         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
16354         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
16355         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
16356         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
16357         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
16358         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
16359         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
16360         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
16361         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
16362         lib/yesno.c, lib/yesno.h:
16363         Update FSF postal mail address.
16364
16365 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16366
16367         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
16368         tests/test-memmem.c, tests/test-stpncpy.c:
16369         Update FSF postal mail address.
16370
16371 2005-05-13  Bruno Haible  <bruno@clisp.org>
16372
16373         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
16374         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
16375         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
16376         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
16377         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
16378         Add support for 64-bit integers in the MSVC compiler.
16379
16380 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16381
16382         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
16383
16384 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
16385
16386         * gnulib-tool (func_import): Sort and uniquify recommended includes.
16387
16388 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
16389
16390         * doc/getdate.texi (General date syntax): Don't say that date
16391         date --iso-8601=ns generates acceptable dates; it doesn't yet.
16392         Problem reported by Nic Ferrier.
16393
16394 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16395
16396         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
16397         specified in ai_socktype. Fix invalid ai_protocol
16398         check. ai_protocol is usually set to 0 or depending on
16399         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
16400         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
16401         ai_socktype / ai_protocol in the returned addrinfo structure.
16402
16403 2005-05-10  Simon Josefsson  <jas@extundo.com>
16404
16405         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
16406         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
16407
16408 2005-05-10  Karl Berry  <karl@gnu.org>
16409
16410         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
16411         (from http://www.gnu.org/licenses).
16412         * doc/COPYING.LIB: also rename to COPYING.LESSER.
16413         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
16414         fdl.texi suffices.
16415
16416 2005-05-10  Karl Berry  <karl@gnu.org>
16417
16418         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
16419         (COPYING.DOC): remove.
16420
16421         * config/srclist-update: new FSF address.
16422
16423 2005-05-10  Derek Price  <derek@ximbiot.com>
16424
16425         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
16426         possible.
16427
16428 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16429             Bruno Haible  <bruno@clisp.org>
16430
16431         * modules/inet_ntop: New file.
16432         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16433         inet_ntop.
16434
16435 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16436             Bruno Haible  <bruno@clisp.org>
16437
16438         * m4/inet_ntop.m4: New file.
16439
16440 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16441             Bruno Haible  <bruno@clisp.org>
16442
16443         * lib/inet_ntop.h: New file.
16444         * lib/inet_ntop.c: New file, from glibc with modifications.
16445
16446 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
16447
16448         * modules/time_r (License): Change to LGPL.
16449         * modules/extensions (License): Change to LGPL.  Actually,
16450         the license is more permissive than that, but currently gnulib-tool
16451         doesn't know how to handle more-permissive licenses.
16452
16453         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
16454         Problem reported by Dave Love.
16455
16456 2005-05-08  Jim Meyering  <jim@meyering.net>
16457
16458         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
16459         blank.
16460
16461 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
16462
16463         * modules/argmatch (Depends-on): Add stdbool.
16464         * modules/backupfile (Depends-on): Likewise.
16465         * modules/chdir-long (Depends-on): Likewise.
16466         * modules/closeout (Depends-on): Likewise.
16467         * modules/cycle-check (Depends-on): Likewise.
16468         * modules/dirname (Depends-on): Likewise.
16469         * modules/fnmatch (Depends-on): Likewise.
16470         * modules/fsusage (Depends-on): Likewise.
16471         * modules/fwriteerror (Depends-on): Likewise.
16472         * modules/getcwd (Depends-on): Likewise.
16473         * modules/getloadavg (Depends-on): Likewise.
16474         * modules/hard-locale (Depends-on): Likewise.
16475         * modules/makepath (Depends-on): Likewise.
16476         * modules/mountlist (Depends-on): Likewise.
16477         * modules/nanosleep (Depends-on): Likewise.
16478         * modules/posixtm (Depends-on): Likewise.
16479         * modules/quotearg (Depends-on): Likewise.
16480         * modules/readtokens (Depends-on): Likewise.
16481         * modules/readtokens0 (Depends-on): Likewise.
16482         * modules/readutmp (Depends-on): Likewise.
16483         * modules/save-cwd (Depends-on): Likewise.
16484         * modules/strftime (Depends-on): Likewise.
16485         * modules/userspec (Depends-on): Likewise.
16486         * modules/utimecmp (Depends-on): Likewise.
16487         * modules/xgetcwd (Depends-on): Likewise.
16488         * modules/xnanosleep (Depends-on): Likewise.
16489         * modules/xstrtod (Depends-on): Likewise.
16490         * modules/yesno (Depends-on): Likewise.
16491
16492 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
16493
16494         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
16495         needless checks.
16496
16497 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16498
16499         Merge from coreutils.  Among other things,
16500         add bulletproofing for cases where stdin, stdout, or stderr are closed.
16501         * lib/fd-safer.c: New file.
16502         * lib/fcntl-safer.h, open-safer.c: Remove.
16503         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
16504         * lib/dup-safer.c: Include unistd-safer.h first.
16505         Don't include errno.h.
16506         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
16507         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
16508         * lib/file-type.c: Rely on file-type.h change.
16509         * lib/getloadavg.c: Include unistd-safer.h.
16510         (getloadavg): Use safer open.
16511         * lib/getusershell.c: Include "stdio-safer.h".
16512         (getusershell): Use safer fopen.
16513         * lib/long-options.c (long_options): Use NULL rather than 0.
16514         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
16515         'free'.
16516         * lib/modechange.c: Likewise.
16517         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
16518         (MODE_DONE): New constant.
16519         (struct mode_change): Remove 'next' member.
16520         (make_node_op_equals): New function; like the old one of the
16521         same name, except it allocates an array.
16522         (mode_compile, mode_create_from_ref): Use it.
16523         (mode_compile): Allocate result as an array, not a linked list.
16524         Parse octal string ourself, so that we catch mistakes like "+0".
16525         (mode_adjust): Arg is an array, not a linked list.
16526         * lib/modechange.c: Include stat-macros.h, xalloc.h.
16527         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
16528         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
16529         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
16530         Remove.  This is now stat-macros.h's job.
16531         (talloc): Remove.  All callers replaced by xalloc, so that
16532         our invokers don't have to worry about reporting memory failures.
16533         (make_node_op_equals): Remove.
16534         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
16535         New constants.
16536         (struct mode_change): Moved here from modechange.h.
16537         (mode_append_entry): Remove.
16538         (mode_compile): Remove MASKED_OPS arg, since it encouraged
16539         apps to have incorrect behavior.  Use simpler algorithm for head
16540         and tail.  Don't futz with umask; that's now the job of mode_adjust.
16541         Detect more invalid usages rather than having somewhat-random behavior.
16542         Don't insert an "a=" action, as that leads to incorrect behavior.
16543         (mode_compile, mode_create_from_ref): Return NULL on error instead
16544         of an enum, since now there's only one way to have an error.  All
16545         callers changed.
16546         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
16547         at the correct time.  Simplify calculation of "+u" and its ilk.
16548         Don't mishandle "+X".
16549         (mode_free): Remove "register" and localize decls.
16550         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
16551         (struct mode_change): Move to modechange.c; callers don't
16552         need to see this stuff.
16553         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
16554         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
16555         (mode_change, mode_adjust): Reflect the new signatures noted above.
16556         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
16557         that might redefine system include files.
16558         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
16559         (my_usleep): Use NULL rather than (void *) 0.
16560         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
16561         Use siginterrupt to specify that system calls should be interrupted.
16562         (rpl_nanosleep): Move initialization of suspended closer to call of
16563         my_usleep.
16564         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
16565         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
16566         (desirable_utmp_entry): New function.
16567         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
16568         using x2nrealloc, to simplify logic.
16569         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
16570         size calculation.  Do not assume utmp file is a regular file.
16571         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
16572         (READ_UTMP_CHECK_PIDS): New constant.
16573         * lib/save-cwd.c: Include unistd-safer.h.
16574         (save_cwd): Use fd_safer.
16575         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
16576         [!_LIBC] Include "stat-macros.h" instead.
16577         * lib/unistd-safer.h (fd_safer): New decl.
16578
16579 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16580
16581         * modules/getloadavg (Depends-on): Add unistd-safer.
16582         * modules/getusershell (Depends-on): Add stdio-safer.
16583         * modules/lstat (Depends-on): Remove xalloc.
16584         * modules/mkstemp (Depends-on): Add stat-macros.
16585         * modules/modechange (Depends-on): Remove xstrtol.
16586         Add stat-macros, xalloc.
16587         * modules/save-cwd (Depends-on): Add unistd-safer.
16588         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
16589         * modules/unistd-safer (Files): Add lib/fd-safer.c
16590         (Makefile.am): Remove lib_SOURCES.
16591
16592         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
16593         Remove fcntl-safer; unistd-safer supersedes it.
16594
16595 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16596
16597         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
16598         AC_HEADER_STAT.
16599         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
16600         (gl_PREREQ_CHOWN): Remove.
16601         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
16602         it.  Don't require AC_HEADER_STAT.
16603         (gl_PREREQ_LSTAT): Remove.
16604         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
16605         Don't require AC_HEADER_STAT.
16606         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
16607         (gl_PREREQ_RMDIR): Remove.
16608         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
16609         mention stat-macros.h or AC_HEADER_STAT, since we'll make
16610         the stat-macros module a prerequisite.
16611         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
16612         * m4/filemode.m4 (gl_FILEMODE): Likewise.
16613         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
16614         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
16615         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
16616         variable names.
16617         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
16618         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
16619         variable prefixes.
16620         * m4/fcntl-safer.m4: Remove.
16621         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
16622         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
16623         Invoke gl_PREREQ_FD_SAFER.
16624         (gl_PREREQ_FD_SAFER): New macro.
16625         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
16626         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
16627         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
16628         Remove duplicate call to AC_LIBOBJ(readutmp).
16629         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
16630
16631         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
16632         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
16633
16634 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16635
16636         * MODULES.html.sh (Misc): Add byteswap.
16637
16638 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16639
16640         * modules/getcwd (Depends-on): Add extensions.
16641         * modules/openat (Depends-on): Likewise.
16642
16643 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16644
16645         * modules/byteswap: New file.
16646
16647 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16648
16649         * m4/byteswap.m4: New file.
16650
16651 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16652
16653         * lib/byteswap_.h: New file.
16654
16655 2005-04-25  Karl Berry  <karl@gnu.org>
16656
16657         * m4/gettext.m4: Update from GNU gettext 0.14.4.
16658
16659 2005-04-25  Albert Chin  <china@thewrittenword.com>
16660
16661         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
16662         Toolkit C bug.
16663
16664 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
16665
16666         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
16667         (func_ln_if_changed) Remove forcibly for no error message
16668         in case file does not exist.
16669
16670 2005-04-19  Simon Josefsson  <jas@extundo.com>
16671
16672         * gnulib-tool (Options): Make --symlink mean --symbolic.
16673
16674 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
16675
16676         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
16677
16678 2005-04-16  Simon Josefsson  <jas@extundo.com>
16679
16680         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
16681
16682 2005-04-15  Simon Josefsson  <jas@extundo.com>
16683
16684         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
16685
16686 2005-04-15  Simon Josefsson  <jas@extundo.com>
16687
16688         * gnulib-tool: Rename --symlink to --symbolic.
16689
16690 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
16691
16692         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
16693         symbolic links to files instead of copying/moving.  Add --aux-dir,
16694         specifying directory relative --dir where auxiliary build tools
16695         are placed.
16696
16697 2005-04-14  Bruno Haible  <bruno@clisp.org>
16698
16699         * modules/allocsa (License): Change to LGPL.
16700         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
16701
16702 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
16703
16704         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
16705         that "UTC +1 second" continues to work.  Problem reported
16706         by Dmitry V. Levin.
16707         (relunit_snumber): New rule.
16708         (relunit): Use it.
16709
16710 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
16711
16712         * lib/getdate.y (universal_time_zone_table): New constant.
16713         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
16714         universal_time_zone_table.
16715         (lookup_zone): Prefer universal_time_zone_table to
16716         local_time_zone_table, so that "GMT" time stamps are allowed in
16717         London during the summer.  Problem reported by Ian Abbott.
16718
16719 2005-04-12  Jim Meyering  <jim@meyering.net>
16720
16721         * lib/human.c (humblock): Set *options even when returning due to
16722         xstrtoumax conversion failure.  Thanks to a used-uninitialized
16723         warning from gcc-4.
16724
16725 2005-04-09  Jim Meyering  <jim@meyering.net>
16726
16727         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
16728         -Wuninitialized: initialize tm0.tm_year.
16729
16730 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
16731
16732         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
16733         count, since there's no maximum.  All uses changed.
16734         Add member dsts_seen.
16735         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
16736         not being INT_MAX.
16737         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
16738         Use pc_rels_seen to decide whther a date is absolute.
16739
16740         * lib/getdate.y (number): Don't overwrite year.
16741         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
16742         check.
16743
16744 2005-04-02  Simon Josefsson  <jas@extundo.com>
16745
16746         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
16747         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
16748
16749 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
16750
16751         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
16752         where no absolute path name can be longer than PATH_MAX.
16753
16754 2005-03-27  Jim Meyering  <jim@meyering.net>
16755
16756         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
16757
16758 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
16759
16760         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
16761         "one's complement" -> "ones' complement" in comment, as per Knuth.
16762         "value of type" -> "type or expression" in comment.
16763         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
16764
16765 2005-03-26  Jim Meyering  <jim@meyering.net>
16766
16767         Comment nits.
16768         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
16769         Correct typos: s/or/of/.
16770
16771 2005-03-26  Jim Meyering  <jim@meyering.net>
16772
16773         * modules/check-include-files: Move to ../ and rename to...
16774         * check-module: ...this.
16775
16776 2005-03-25  Jim Meyering  <jim@meyering.net>
16777
16778         * modules/xvasprintf (Files): Add xalloc.h.
16779
16780 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
16781
16782         * modules/gettext (Files): config/config.rpath ->
16783         build-aux/config.rpath
16784         * modules/iconv (Files): Likewise.
16785         Problem reported by Oskar Liljeblad.
16786
16787 2005-03-23  Jim Meyering  <jim@meyering.net>
16788
16789         * modules/check-include-files: New script to check for
16790         missing dependencies, multiple includes, etc.
16791
16792         * modules/c-strtold (Depends-on): Add xalloc.
16793         * modules/c-strtod (Depends-on): Add xalloc.
16794         * modules/hash (Depends-on): Add xalloc.
16795         (Files): Remove lib/xalloc.h.
16796
16797         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
16798         * modules/userspec (Files): Add lib/inttostr.h.
16799
16800 2005-03-23  Jim Meyering  <jim@meyering.net>
16801
16802         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
16803
16804 2005-03-22  Jim Meyering  <jim@meyering.net>
16805
16806         * modules/stat-macros: New module.
16807         * modules/canonicalize, modules/euidaccess, modules/file-type,
16808         * modules/filemode, modules/lchown, modules/makepath,
16809         * modules/rmdir, modules/stat: Depend on new stat-macros module
16810         rather than listing lib/stat-macros.h manually.
16811         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
16812
16813 2005-03-22  Jim Meyering  <jim@meyering.net>
16814
16815         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
16816
16817 2005-03-22  Bruno Haible  <bruno@clisp.org>
16818
16819         * config/srclist.txt: Replace target directory 'config' with
16820         'build-aux'.
16821         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
16822         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
16823         ../build-aux/.
16824
16825 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
16826
16827         * modules/chdir-long (Depends-on): Add mempcpy.
16828
16829         * modules/acl, modules/backupfile, modules/c-strtod,
16830         modules/c-strtold, modules/canon-host, modules/canonicalize,
16831         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
16832         modules/exclude, modules/exitfail, modules/file-type,
16833         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
16834         modules/getdate, modules/getline, modules/getpagesize,
16835         modules/getpass, modules/getugroups, modules/group-member,
16836         modules/hard-locale, modules/hash, modules/human, modules/idcache,
16837         modules/inttostr, modules/long-options, modules/makepath,
16838         modules/md5, modules/memcasecmp, modules/memcoll,
16839         modules/modechange, modules/mountlist, modules/path-concat,
16840         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
16841         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
16842         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
16843         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
16844         modules/strftime, modules/strndup, modules/strverscmp,
16845         modules/timespec, modules/unlocked-io, modules/userspec,
16846         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
16847         modules/yesno:
16848         Remove lib_SOURCES line from Makefile.am section, as this is now
16849         done automatically by the corresponding Autoconf macro.
16850
16851 2005-03-21  Jim Meyering  <jim@meyering.net>
16852
16853         Changes imported from coreutils.
16854
16855         * lib/cycle-check.c: Don't include xalloc.h.
16856
16857         * lib/path-concat.c: Don't include assert.h.
16858         (path_concat): Remove assertion that would have triggered
16859         for ABASE starting with more than one slash.
16860         Reported by Andreas Schwab.
16861
16862         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
16863         properly when ABASE is an absolute file name.
16864         Correct the description of this function.
16865         Include <assert.h>.
16866         Add an assertion and a test driver.
16867         This fixes a bug introduced on 2004-07-02.
16868         Andreas Schwab reported the resulting failure of cp --parents:
16869         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
16870
16871 2005-03-21  Jim Meyering  <jim@meyering.net>
16872
16873         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
16874         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
16875
16876 2005-03-21  Jim Meyering  <jim@meyering.net>
16877         and  Paul Eggert  <eggert@cs.ucla.edu>
16878
16879         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
16880         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
16881         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
16882         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
16883         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
16884         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
16885         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
16886         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
16887         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
16888         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
16889         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
16890         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
16891         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
16892         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
16893         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
16894         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
16895         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
16896         for these modules.
16897
16898 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
16899
16900         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
16901         (which shouldn't happen), generate nothing instead of returning 0
16902         immediately, so that nstrftime (NULL, ...) doesn't return 0.
16903
16904 2005-03-16  Bruno Haible  <bruno@clisp.org>
16905
16906         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
16907         HAVE_LONGLONG_64BIT.
16908
16909 2005-03-16  Bruno Haible  <bruno@clisp.org>
16910
16911         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
16912         HAVE_LONGLONG_64BIT.
16913
16914 2005-03-16  Bruno Haible  <bruno@clisp.org>
16915
16916         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
16917         HAVE_LONGLONG_64BIT.
16918
16919 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
16920
16921         * lib/strftime.c (my_strftime): Prepend space to format so that we can
16922         reliably distinguish strftime failure from empty output on POSIX
16923         hosts.
16924
16925 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
16926
16927         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
16928         (iconv_string): Don't guess a size-zero buffer, as that might cause
16929         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
16930         result would be 'too large', where 'too large' is (heuristically)
16931         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
16932         overflow concerns.  This will prevent some unwanted malloc failures
16933         when the inputs are very large.
16934
16935 2005-03-15  Karl Berry  <karl@gnu.org>
16936
16937         * config/srclist.txt (config.rpath): from gettext.
16938         * config/config.rpath: update.
16939
16940 2005-03-15  Bruno Haible  <bruno@clisp.org>
16941
16942         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
16943         to 'negate'.
16944
16945         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
16946         variable.
16947
16948         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
16949         results.
16950
16951 2005-03-14  Simon Josefsson  <jas@extundo.com>
16952
16953         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
16954         <fx@gnu.org>.
16955
16956 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
16957
16958         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
16959         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
16960         intprops.h.
16961         * lib/strtol.c: Likewise.
16962
16963 2005-03-14  Jim Meyering  <jim@meyering.net>
16964
16965         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
16966         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
16967         to be nonzero so that we (and caller) can detect the difference
16968         between a valid zero-length expansion and an error return, even
16969         when the underlying strftime fails before writing anything into
16970         that location.
16971
16972 2005-03-14  Bruno Haible  <bruno@clisp.org>
16973
16974         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
16975         Update from GNU gettext 0.14.3.
16976
16977 2005-03-10  Jim Meyering  <jim@meyering.net>
16978
16979         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
16980
16981 2005-03-10  Jim Meyering  <jim@meyering.net>
16982
16983         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
16984         so that this module works on systems without fchdir.
16985
16986 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
16987
16988         Factor int-properties macros into a single file, except for
16989         glibc-related files.
16990         * lib/intprops.h: New file.
16991         * lib/getloadavg.c: Include it instead of limits.h.
16992         (INT_STRLEN_BOUND): Remove.
16993         * lib/human.c: Include intprops.h.
16994         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
16995         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
16996         302/1000.
16997         * lib/inttostr.h: Include intprops.h instead of limits.h.
16998         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
16999         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
17000         for consistency with intprops.h.
17001         (time_t_is_integer, twos_complement_arithmetic): Use them.
17002         * lib/sig2str.h: Include <signal.h>, intprops.h.
17003         (INT_STRLEN_BOUND): Remove.
17004         * lib/strftime.c (TYPE_SIGNED): Remove.
17005         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
17006         * lib/strtol.c: Adjust comments to match intprops.h.
17007         * lib/userspec.c: Include intprops.h.
17008         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
17009         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
17010         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
17011         instead of rolling our own expressions.
17012         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
17013
17014         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
17015         instead of int.
17016         (my_strftime): Do not mishandle years close to INT_MAX, by doing
17017         the right thing even if adding 1900 would overflow.  Similarly
17018         for tm_mon + 1 and tm_yday + 1.
17019         Make %Y always equivalent to %C%y, and similarly for %G and %g.
17020         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
17021         (DO_SIGNED_NUMBER): New macro.
17022         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
17023
17024 2005-03-07  Bruno Haible  <bruno@clisp.org>
17025
17026         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
17027
17028 2005-03-07  Bruno Haible  <bruno@clisp.org>
17029
17030         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
17031
17032 2005-03-04  Derek R. Price  <derek@ximbiot.com>
17033
17034         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
17035         (func_import): Only replace files via --import when they have actually
17036         changed.
17037
17038 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17039
17040         * m4/mmap-anon.m4: New file.
17041         * m4/pagealign_alloc.m4: New file.
17042
17043 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17044             Bruno Haible  <bruno@clisp.org>
17045
17046         * modules/pagealign_alloc: New file.
17047         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
17048
17049 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17050             Bruno Haible  <bruno@clisp.org>
17051
17052         * lib/pagealign_alloc.h: New file.
17053         * lib/pagealign_alloc.c: New file.
17054
17055 2005-03-03  Bruno Haible  <bruno@clisp.org>
17056
17057         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
17058         Use an all-permissive copyright notice, recommended by RMS.
17059
17060 2005-03-02  Bruno Haible  <bruno@clisp.org>
17061
17062         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
17063         of AIX, the replacement has to be done only after <string.h> is
17064         included, therefore not in config.h. stpncpy.h does the replacement,
17065         and stpncpy.c uses it.
17066
17067 2005-03-02  Bruno Haible  <bruno@clisp.org>
17068
17069         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
17070         stpncpy.c uses it.
17071
17072 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17073
17074         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
17075         The workaround isn't strictly needed for POSIX conformance, and
17076         it's too much of a pain to configure and maintain.  We'll ask
17077         people to fix their kernels instead.
17078         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
17079         (NANOSLEEP_BUG_WORKAROUND): Remove.
17080         (xnanosleep): Remove the workaround.
17081
17082 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17083
17084         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
17085         Reported by Derek Price.
17086         (Include): Add "timespec.h".
17087
17088         * modules/xnanosleep (Depends-on): Remove gethrxtime.
17089
17090 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17091
17092         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
17093         to detect nanosleep bug.
17094
17095 2005-03-01  Bruno Haible  <bruno@clisp.org>
17096
17097         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
17098
17099 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
17100
17101         * modules/gethrxtime: New file.
17102         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
17103         (Depends-on): Add gethrxtime.
17104         (configure.ac): Add gl_XNANOSLEEP.
17105         (Makefile.am): Remove lib_SOURCES line.
17106
17107 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17108
17109         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
17110         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
17111
17112 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17113
17114         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
17115         * lib/timespec.h (gettime): Return void, since it always
17116         succeeds now.  All uses changed.
17117         * lib/gettime.c (gettime) Likewise.
17118         [HAVE_NANOTIME]: Prefer nanotime.
17119         Assume gettimeofday succeeds, as POSIX requires.
17120         Assime time () succeeds, since other code already does.
17121         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
17122         (timespec_subtract): Remove.
17123         (NANOSLEEP_BUG_WORKAROUND): New constant.
17124         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
17125         things considerably.  Use it only on GNU/Linux hosts, since the
17126         workaround shouldn't be needed elsewhere.
17127
17128 2005-02-24  Bruno Haible  <bruno@clisp.org>
17129
17130         * modules/gettext (Files): Add m4/glibc2.m4.
17131
17132 2005-02-24  Bruno Haible  <bruno@clisp.org>
17133
17134         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
17135         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
17136         * m4/progtest.m4:
17137         Update from GNU gettext 0.14.2.
17138         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
17139
17140 2005-02-24  Bruno Haible  <bruno@clisp.org>
17141
17142         * lib/localcharset.c: Update from GNU gettext 0.14.2.
17143         * lib/config.charset: Update from GNU gettext 0.14.2.
17144
17145 2005-02-24  Bruno Haible  <bruno@clisp.org>
17146
17147         * lib/gettext.h: Update from GNU gettext 0.14.2.
17148
17149 2005-02-23  Simon Josefsson  <jas@extundo.com>
17150
17151         * m4/iconvme.m4: New file.
17152
17153 2005-02-23  Jim Meyering  <jim@meyering.net>
17154
17155         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
17156         change.
17157         Thanks to Bruno Haible for catching it.
17158
17159 2005-02-22  Simon Josefsson  <jas@extundo.com>
17160
17161         * modules/iconvme: New file.
17162
17163         * MODULES.html.sh: Add iconvme.
17164
17165 2005-02-22  Simon Josefsson  <jas@extundo.com>
17166
17167         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
17168
17169 2005-02-22  Simon Josefsson  <jas@extundo.com>
17170
17171         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
17172
17173 2005-02-22  Jim Meyering  <jim@meyering.net>
17174
17175         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
17176         s/ifndef/ifdef/.
17177
17178 2005-02-20  Neil Conway  <neilc@samurai.com>
17179
17180         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
17181         returned by OSX/Darwin if the specified buffer is not large
17182         enough for the hostname.
17183
17184 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17185
17186         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
17187         pass it to _help, otherwise the latter coredumps trying to
17188         dereference state.root_argp.
17189
17190 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17191
17192         * modules/chdir-long (Depends-on): Add memrchr.
17193         * modules/memrchr (Files): Add lib/memrchr.h.
17194         (Include): "memrchr.h".
17195
17196 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17197
17198         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
17199
17200 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17201
17202         * lib/memrchr.h: New file.
17203         * lib/chdir-long.c: Include it.
17204         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
17205         Don't bother including stddef.h.
17206
17207 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
17208
17209         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
17210         inclusion.
17211         Include <sys/types.h>, for dev_t.
17212         (ME_DUMMY, ME_REMOTE): Move from here....
17213         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
17214         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
17215         Dmitry V. Levin.
17216         Include mountlist.h first, to test the interface.
17217
17218 2005-01-29  Bruno Haible  <bruno@clisp.org>
17219
17220         * lib/progname.c (program_name): Initialize.
17221         Needed when linking statically on MacOS X.
17222
17223 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17224
17225         Sync from coreutils.
17226         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
17227         (Depends-on): Add c-strtod.
17228         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
17229
17230 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17231
17232         Sync from coreutils.
17233         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
17234
17235         Remove files that are specific to coreutils.
17236         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
17237
17238 2005-01-28  Bruno Haible  <bruno@clisp.org>
17239
17240         * modules/javacomp: New file.
17241         * MODULES.html.sh (Java): Add javacomp.
17242
17243 2005-01-28  Bruno Haible  <bruno@clisp.org>
17244
17245         * m4/javacomp.m4: New file, from GNU gettext.
17246
17247 2005-01-28  Bruno Haible  <bruno@clisp.org>
17248
17249         * lib/javacomp.sh.in: New file, from GNU gettext.
17250         * lib/javacomp.h: New file, from GNU gettext.
17251         * lib/javacomp.c: New file, from GNU gettext.
17252
17253 2005-01-26  Simon Josefsson  <jas@extundo.com>
17254
17255         * lib/gai_strerror.c: Use GPL in header.
17256
17257 2005-01-26  Bruno Haible  <bruno@clisp.org>
17258
17259         * modules/javaexec: New file.
17260         * MODULES.html.sh (Java): Add javaexec.
17261
17262 2005-01-26  Bruno Haible  <bruno@clisp.org>
17263
17264         * m4/javaexec.m4: New file, from GNU gettext.
17265
17266 2005-01-26  Bruno Haible  <bruno@clisp.org>
17267
17268         * lib/javaexec.sh.in: New file, from GNU gettext.
17269         * lib/javaexec.h: New file, from GNU gettext.
17270         * lib/javaexec.c: New file, from GNU gettext.
17271
17272 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17273
17274         * modules/lchown (Depends-on): Remove lchown.h
17275
17276 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17277
17278         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
17279         must be defined if the header file was not found, in order
17280         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
17281
17282 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17283
17284         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
17285         initializers for struct pentry_state.
17286         (__argp_error): Check return value of __asprintf
17287         (__argp_failure): Translate error message
17288
17289         * lib/argp-parse.c: Removed braces around the expansion of N_()
17290
17291 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
17292
17293         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
17294         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
17295         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
17296         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
17297         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
17298         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
17299         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
17300         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
17301         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
17302         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
17303         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
17304         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
17305         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
17306         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
17307         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
17308         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
17309         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
17310         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
17311         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
17312         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
17313         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
17314         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
17315         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
17316         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
17317         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
17318         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
17319         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
17320         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
17321         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
17322         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
17323         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
17324         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
17325         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
17326         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
17327         xstrtol.m4, xstrtoumax.m4, yesno.m4:
17328         Use an all-permissive copyright notice, recommended by RMS.
17329
17330 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
17331
17332         * modules/chdir-long (Depends-on): Remove mempcpy.
17333
17334 2005-01-21  Jim Meyering  <jim@meyering.net>
17335
17336         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
17337         same value as for Solaris 9.
17338
17339         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
17340         component length.  This included changing the parameter to be
17341         of type `char *' rather than `char const *'.
17342         * lib/chdir-long.h (chdir_long): Update prototype.
17343
17344         * lib/openat.c (fdopendir, fstatat): New functions.
17345         * lib/openat.h: Include headers required for use of DIR and struct
17346         stat.
17347         [AT_SYMLINK_NOFOLLOW]: Define.
17348         (fdopendir, fstatat): Add prototypes.
17349
17350 2005-01-21  Bruno Haible  <bruno@clisp.org>
17351
17352         * modules/classpath: New file.
17353         * MODULES.html.sh (Java): Add classpath.
17354
17355 2005-01-21  Bruno Haible  <bruno@clisp.org>
17356
17357         * lib/classpath.h: New file, from GNU gettext.
17358         * lib/classpath.c: New file, from GNU gettext.
17359
17360 2005-01-20  Simon Josefsson  <jas@extundo.com>
17361
17362         * modules/version-etc-fsf: New file.
17363
17364 2005-01-20  Simon Josefsson  <jas@extundo.com>
17365
17366         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
17367         * lib/version-etc.c: Remove version_etc_copyright.
17368         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
17369         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
17370
17371 2005-01-20  Simon Josefsson  <jas@extundo.com>
17372
17373         * lib/base64.h (isbase64): Add.
17374
17375         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
17376         using a unsigned prototype, don't inline.
17377         (base64_decode): Use it.
17378
17379 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17380
17381         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
17382         it.
17383
17384 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17385
17386         * lib/save-cwd.c (save_cwd): Remove code to support the case
17387         where fchdir is missing or flaky.
17388
17389 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17390
17391         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
17392
17393 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
17394
17395         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
17396         AC_LIBSOURCES now does this.
17397         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
17398         with new ullong_max module.
17399
17400 2005-01-19  Bruno Haible  <bruno@clisp.org>
17401
17402         * modules/sh-quote: New file.
17403         * MODULES.html.sh (Executing programs): Add sh-quote.
17404
17405 2005-01-19  Bruno Haible  <bruno@clisp.org>
17406
17407         * lib/sh-quote.h: New file, from GNU gettext.
17408         * lib/sh-quote.c: New file, from GNU gettext.
17409
17410 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17411
17412         Merge from coreutils.
17413         * m4/ullong_max.m4: New file.
17414         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
17415         (gl_MACROS): Assume localeconv exists.
17416
17417 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17418
17419         Merge changes from coreutils, as described below in several
17420         changelogs dated today.
17421
17422         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
17423         (O_DIRECTORY): Remove; not needed here, since "." must be
17424         a directory.  All uses removed.
17425         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
17426         universal on Suns, and we also need to test for IRIX.
17427         Revamp code to use 'if' rather than '#if'.
17428         Avoid unnecessary comparison of cwd->desc to 0.
17429
17430         * lib/utimens.c (futimens): Robustify the previous patch, by checking
17431         for known valid error numbers rather than observed invalid ones.
17432
17433 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17434
17435         * modules/ullong_max: New file.
17436
17437         * modules/chdir-long, modules/openat: New files.
17438         * modules/save-cwd (Depends-on): Depend on chdir-long.
17439         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
17440
17441 2005-01-18  Jim Meyering  <jim@meyering.net>
17442
17443         Merge from coreutils.
17444         * m4/chdir-long.m4, m4/openat.m4: New files.
17445         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
17446         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
17447         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
17448         is sane and DOES follow symlinks.  Besides, testing 20 different
17449         systems found no broken chown implementations.
17450         Prompted by a change in rsync's copy of this macro.
17451         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
17452
17453         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
17454
17455         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
17456         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
17457         NULL-means-set-to-current-time semantics.
17458         Remove temporary file immediately, rather than waiting
17459         for configure's at-exit trap code to do it.
17460
17461 2005-01-18  Jim Meyering  <jim@meyering.net>
17462
17463         * lib/version-etc.c (version_etc_copyright): Update copyright date.
17464
17465         * lib/utimens.c (futimens): Account for the fact that futimes
17466         can also fail with errno == ENOSYS or errno == ENOENT.
17467         Patch from Dmitry V. Levin.
17468
17469         Change the name of the robust chdir function from chdir to chdir_long.
17470         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
17471         (restore_cwd): Use chdir_long, not chdir.
17472         * lib/chdir-long.c: Renamed from chdir.c.
17473         * lib/chdir-long.h: Renamed from chdir.h.
17474         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
17475         Hurd.
17476
17477 2005-01-18  Bruno Haible  <bruno@clisp.org>
17478
17479         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
17480         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
17481         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
17482         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
17483         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
17484         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
17485         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
17486         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
17487         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
17488         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
17489         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
17490         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
17491         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
17492         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
17493         Use an all-permissive copyright notice, recommended by RMS.
17494
17495 2005-01-18  Bob Proulx  <bob@proulx.com>
17496
17497         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
17498         simplify offsetof() macro construct to avoid compile failure with
17499         native HP-UX 11.0 ANSI C compiler.
17500
17501 2005-01-17  Bruno Haible  <bruno@clisp.org>
17502
17503         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
17504         redundant because stpncpy.m4 takes care of it.
17505
17506 2005-01-17  Bruno Haible  <bruno@clisp.org>
17507
17508         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
17509
17510 2005-01-17  Bruno Haible  <bruno@clisp.org>
17511
17512         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
17513         used.
17514
17515 2005-01-17  Bruno Haible  <bruno@clisp.org>
17516
17517         * lib/fwriteerror.h (fwriteerror): Change specification to include
17518         fclose.
17519         * lib/fwriteerror.c: Include <stdbool.h>.
17520         (fwriteerror): At the end, close the file stream. Record whether
17521         stdout was already closed.
17522
17523 2005-01-17  Bruno Haible  <bruno@clisp.org>
17524
17525         * lib/execute.c (environ): Declare if needed.
17526         * lib/pipe.c (environ): Likewise.
17527         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
17528
17529 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17530
17531         * modules/argp: Depend on vsnprintf
17532
17533 2005-01-10  Jim Meyering  <jim@meyering.net>
17534
17535         * modules/closeout (Depends-on): Add atexit.
17536
17537 2005-01-06  Bruno Haible  <bruno@clisp.org>
17538
17539         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
17540
17541 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
17542
17543         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
17544         definitions to be after all include files, to avoid collisions.
17545         Problem reported by Bob Proulx.
17546
17547 2005-01-04  Jim Meyering  <jim@meyering.net>
17548
17549         Changes imported from coreutils.
17550         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
17551         as the mkstemp template, use a temporary directory and an
17552         8.3-friendly template to avoid trouble on systems like DJGPP.
17553         Reported by Juan M. Guerrero via Stepan Kasal.
17554         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
17555         close. Remove the temporary directory right away, rather than waiting
17556         for configure's at-exit trap code to do it.
17557         Suggestion from Stepan Kasal.
17558
17559 2005-01-01  Simon Josefsson  <jas@extundo.com>
17560
17561         * gnulib-tool: Print #include directives when --import'ing.
17562
17563 2004-12-28  Simon Josefsson  <jas@extundo.com>
17564
17565         * tests/test-base64.c: Include required header files.  Remove
17566         unused variables.
17567
17568 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
17569
17570         * modules/error (Depends-on): Remove gettext.
17571
17572 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
17573
17574         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
17575         not needed.  This removes a dependency on the gettext module.
17576         [defined _LIBC]: Do not include <libintl.h>; not needed.
17577
17578 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
17579
17580         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
17581         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
17582
17583 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
17584
17585         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
17586         HAVE_DECL_STRTOLD.
17587
17588 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17589
17590         * modules/getdate (Depends-on): Remove alloca-opt.
17591
17592 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17593
17594         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
17595
17596 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17597
17598         * lib/argp-parse.c: Include <stddef.h>.
17599         (alignof, alignto): New macros.
17600         (parser_init): Don't assume that void * is aligned sufficiently
17601         for struct option.
17602
17603         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
17604         need to extend the stack.
17605         (YYINITDEPTH): New macro, so that the initial stack isn't overly
17606         large.
17607
17608 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17609
17610         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
17611
17612 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
17613
17614         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
17615         (2004-10-24) change.  Apparently this was a false alarm.
17616
17617         * modules/getdate: Depend on alloca-opt, not alloca.
17618
17619 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
17620
17621         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
17622         Remove now-obsolete comment about AIX.
17623         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
17624         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
17625         (YYMAXDEPTH): New macro.
17626
17627 2004-12-18  Simon Josefsson  <jas@extundo.com>
17628
17629         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
17630
17631 2004-12-18  Bruno Haible  <bruno@clisp.org>
17632
17633         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
17634
17635 2004-12-18  Bruno Haible  <bruno@clisp.org>
17636
17637         * lib/fatal-signal.c (fatal_signals): Make non-const.
17638         (init_fatal_signals): New function.
17639         (uninstall_handlers, install_handlers): Ignore signals that were set to
17640         SIG_IGN.
17641         (at_fatal_signal): Call init_fatal_signals.
17642         (init_fatal_signal_set): Likewise. Ignore signals that were set to
17643         SIG_IGN.
17644         Reported by Paul Eggert.
17645
17646 2004-12-18  Bruno Haible  <bruno@clisp.org>
17647
17648         * doc/alloca.texi: New file.
17649         * doc/alloca-opt.texi: New file.
17650
17651 2004-12-17  Jim Meyering  <jim@meyering.net>
17652
17653         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
17654         Otherwise, install-sh could exit with improper exit status when
17655         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
17656
17657 2004-12-16  Simon Josefsson  <jas@extundo.com>
17658
17659         * tests/test-base64.c: Add license.
17660
17661 2004-12-15  Stepan Kasal  <address@hidden>
17662
17663         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
17664
17665 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
17666
17667         * modules/getcwd (Files): Add m4/d-ino.m4.
17668         Suggested by Mark D. Baushke.
17669
17670 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
17671
17672         * lib/getdate.y (textint): New member "negative".
17673         (time_zone_hhmm): New function.
17674         Expect 14 shift-reduce conflicts, not 13.
17675         (o_colon_minutes): New rule.
17676         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
17677         (yylex): Set the "negative" member of signed numbers.
17678
17679 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
17680
17681         * doc/getdate.texi (Time of day items, Time zone items):
17682         Describe new formats +00:00, UTC+00:00.
17683
17684 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
17685
17686         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
17687         spurious "-l"s.  Problem reported by Stepan Kasal.
17688
17689 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
17690
17691         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
17692         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
17693
17694 2004-12-04  Simon Josefsson  <jas@extundo.com>
17695
17696         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
17697         Vandoorselaere <yoann@prelude-ids.org>.
17698
17699 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17700
17701         Changes imported from coreutils.
17702         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
17703         exist.
17704         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
17705
17706 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17707
17708         Changes imported from coreutils.
17709         * lib/hard-locale.c: Assume <locale.h> exists.
17710         Include "strdup.h".
17711         (GLIBC_VERSION): New macro.
17712         (hard_locale): Assume setlocale exists.
17713         Rewrite to avoid #ifdef.
17714         Use strdup rather than malloc + strcpy.
17715         * lib/human.c: Assume <locale.h> exists.
17716         (human_readable): Assume localeconv exists.
17717
17718 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17719
17720         * modules/hard-locale (Depends-on): Add strdup.
17721
17722 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
17723
17724         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
17725         convert T2, not T.  (Imported from libc.)
17726
17727 2004-11-30  Simon Josefsson  <jas@extundo.com>
17728
17729         * modules/restrict (License): Change to LGPL.
17730
17731 2004-11-30  Simon Josefsson  <jas@extundo.com>
17732
17733         * m4/restrict.m4: Add copyright and copying conditions.
17734
17735 2004-11-30  Simon Josefsson  <jas@extundo.com>
17736
17737         * m4/base64.m4: New file.
17738
17739 2004-11-30  Simon Josefsson  <jas@extundo.com>
17740
17741         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
17742         base64.
17743
17744         * tests/test-base64.c: New file.
17745
17746         * modules/base64: New file.
17747
17748 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
17749
17750         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
17751         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
17752
17753         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
17754
17755 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
17756
17757         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
17758         (__getcwd.c): Don't restore errno; glibc doesn't.
17759         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
17760         first, falling back to our code only if its results look suspicious.
17761         Ensure that the resulting buffer is only as large as necessary.
17762
17763         * lib/readutmp.c: Include readutmp.h first.
17764         Include <errno.h>, since readutmp.h no longer does that.
17765         * lib/readutmp.h: Don't include <errno.h>,
17766         <sys/param.h>, <time.h>; not needed to establish interface.
17767         (errno): Remove decl.
17768         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
17769         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
17770         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
17771
17772 2004-11-28  Simon Josefsson  <jas@extundo.com>
17773
17774         * lib/base64.h, base64.c: New file.
17775
17776 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
17777
17778         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
17779
17780 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
17781
17782         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
17783         (Depends-on): Remove pathmax, same.  Add mempcpy.
17784         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
17785         (Makefile.am): Append getcwd.h to lib_SOURCES.
17786         (Include): Add getcwd.h.
17787         (Maintainer): Change from Jim Meyering to "all, glibc",
17788         since getdate now uses intended-for-glibc code.
17789         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
17790         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
17791
17792 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
17793
17794         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
17795         HP's ANSI C compiler.
17796         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
17797         Declaring int functions causes warnings on some modern systems and
17798         shouldn't be needed to compile on ancient ones.
17799         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
17800         defined.
17801
17802         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
17803         with the following changes.
17804         (__set_errno): Parenthesize properly.
17805         Include <stdbool.h>.
17806         (MIN, MAX, MATCHING_INO): New macros.
17807         (__getcwd): Define with prototype, not K&R form.
17808         Use heuristics to allocate default buffer on stack if possible.
17809         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
17810         behavior, and to avoid the PATH_MAX limit when computing
17811         ../../../../...
17812         Use MATCHING_INO to compare inode number to file.
17813         Check for arithmetic overflow in size calculations.
17814         Fix bug in reallocation of dot array that caused getcwd to fail
17815         on directories nested deeper than 75.
17816         Be more careful about saving errno on error.
17817         Do not use realloc; use only free+malloc, as this is a bit
17818         more flexible and avoids a needless copy operation.
17819         Do not inspect st_dev and st_ino for symbolic links; POSIX
17820         doesn't specify the latter.
17821         Check for closedir errors.
17822         Avoid needless casts.
17823         Use "#ifdef weak_alias" around weak_alias, to be like other
17824         glibc code.
17825         The following changes to getcwd.c have effect only when used in
17826         gnulib; they have no effect inside glibc proper.
17827         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
17828         as alloca isn't used.
17829         (alloca, __alloca): Likewise.
17830         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
17831         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17832         unconditionally, as gnulib assumes C89 or better.
17833         Do not include <sys/param.h>.
17834         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
17835         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
17836         better.
17837         (NULL) [!defined NULL]: Remove; we assume C89 or better.
17838         Include <dirent.h> in a way that is compatible with modern Autoconf.
17839         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
17840         New macros, if not already defined.
17841         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
17842         Use "_LIBC", not "defined _LIBC", for consistency.
17843         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
17844         a mempcpy module.
17845         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
17846         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
17847         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
17848         credit only to Jim Meyering and adjust the copyright dates.
17849         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
17850         <stdlib.h>, <unistd.h>, "pathmax.h".
17851         Instead, include "xgetcwd.h" (first) and "getcwd.h".
17852         (INITIAL_BUFFER_SIZE): Remove.
17853         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
17854
17855 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
17856
17857         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
17858         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
17859         Use the _ONCE methods, for efficiency.
17860         Check for fcntl.h.  In test program, include <errno.h>
17861         and <fcntl.h> if available.  Remove old K&R cruft from
17862         test program.  Check for common errors in GNU/Linux,
17863         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
17864         don't do AC_LIBOBJ, as that's getcwd.m4's job.
17865         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
17866         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
17867         name accordingly.
17868         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
17869         accommodate new getcwd.c.
17870         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
17871         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
17872         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
17873         that's all we need now.
17874
17875 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17876
17877         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
17878         argp-parse.c depends on getopt internals, that means we should
17879         always use our getopt, to be on the safe side.
17880         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
17881         order not to spoil the result of an eventual previous invocation
17882         of gl_GETOPT_SUBSTITUTE.
17883
17884 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17885
17886         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
17887         redefinition warnings. To avoid them, include the defines
17888         in `#if !defined __need_getopt ... #endif'. The only place
17889         where __getopt_argv_const is used is in definitions
17890         of getopt_long and getopt_long_only below, which are as well
17891         protected by `#ifndef __need_getopt'.
17892         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
17893         __need_getopt after including <stdio.h> and <unistd.h> These
17894         headers might have defined it.
17895
17896 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
17897
17898         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
17899
17900 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
17901
17902         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
17903         (futimens): New function, which uses futimes if available.
17904         (futimens, utimens): Support timespec==NULL, with same semantics
17905         as utime and utimens.
17906         * lib/utimens.h (futimens): New decl.
17907
17908 2004-11-23  Jim Meyering  <jim@meyering.net>
17909
17910         * lib/getopt_.h: Remove trailing blanks.
17911
17912 2004-11-23  Jim Meyering  <jim@meyering.net>
17913
17914         * lib/__fpending.c: Add comment.
17915
17916 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
17917
17918         * modules/canonicalize (Depends-on): Add xreadlink.
17919         Problem reported by James Youngman.
17920
17921 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
17922
17923         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
17924         New macros.
17925         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
17926         optopt): Use them instead of invoking ## directly; otherwise, the
17927         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
17928
17929 2004-11-19  Bruno Haible  <bruno@clisp.org>
17930
17931         * lib/strtok_r.c: Move comments from here...
17932         * lib/strtok_r.h: ... to here.
17933
17934 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
17935
17936         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
17937         implementations that mishandle size_t overflow.
17938
17939 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
17940
17941         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
17942         might fail.  Problem reported by Yoann Vandoorselaere.
17943         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
17944         implementations that mishandle size_t overflow.
17945
17946 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17947
17948         * modules/canon-host (Depends-on): Add strdup.
17949
17950 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17951
17952         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
17953
17954 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17955
17956         * lib/canon-host.c: Include "strdup.h".
17957         (canon_host): Use getaddrinfo if available, so that IPv6 works.
17958         Use strdup instead of malloc/strcpy to duplicate strings.
17959
17960         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
17961         (human_space_before_unit): New constant.
17962         * lib/human.c (human_readable): Support it.
17963
17964         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
17965         (xgetcwd): Set errno correctly when failing.
17966         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
17967         the failure is actually due to a PATH_MAX problem.
17968
17969         Further getopt changes to make it more likely that glibc will
17970         buy the changes back.
17971         * lib/getopt.c (POSIXLY_CORRECT): New constant.
17972         (getopt): Use it, so to preserve glibc semantic
17973         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
17974         when compiling for libc.
17975         * lib/getopt_.h (__getopt_argv_const): Bring it back.
17976         (getopt_long, getopt_long_only): Use it.
17977
17978         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
17979         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
17980         (getopt): Argv is now char * const *, as per standard.
17981         (_getopt_internal_r, _getopt_internal): Argv is now char **,
17982         not char *__getopt_argv_const *.
17983         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
17984         _getopt_long_only_r): Likewise.
17985         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
17986         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
17987         _getopt_long_r, _getopt_long_only_r): Likewise.
17988         * lib/getopt_.h (__getopt_argv_const): Remove.
17989         (getopt): Argv is now char * const *, as per standard.
17990
17991         * lib/getdate.y (tORDINAL): New token.
17992         (day, relunit): Allow it for relative times.
17993         (relative_time_table): Use tORDINAL for ordinals.
17994
17995 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17996
17997         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
17998         Document that "second" isn't allowed as an ordinal number.
17999
18000 2004-11-16  Jim Meyering  <jim@meyering.net>
18001
18002         * modules/closeout (Depends-on): Add fpending.
18003
18004 2004-11-15  Jim Meyering  <jim@meyering.net>
18005
18006         * lib/closeout.c: Include "__fpending.h" once again.
18007         Include <stdbool.h>.
18008         (close_stdout): Don't fail just because stdout was closed initially,
18009         since some programs don't write to stdout in the normal course of
18010         operation (other than --version and --help), and we don't want this
18011         function to make e.g. `touch file >&-' fail.
18012         But do fail if it was closed and someone has tried to write to it.
18013         E.g., `printf foo >&-' must fail.
18014
18015 2004-11-13  Jim Meyering  <jim@meyering.net>
18016
18017         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
18018
18019 2004-11-12  Simon Josefsson  <jas@extundo.com>
18020
18021         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
18022         small doc fix is still pending.
18023
18024 2004-11-11  Simon Josefsson  <jas@extundo.com>
18025
18026         * modules/strtok_r: New file.
18027
18028         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18029         strtok_r.
18030
18031 2004-11-11  Simon Josefsson  <jas@extundo.com>
18032
18033         * m4/strtok_r.m4: New file.
18034
18035         * m4/getopt.m4: Replace opterr.
18036
18037 2004-11-11  Simon Josefsson  <jas@extundo.com>
18038
18039         * lib/strtok_r.h, strtok_r.c: New file.
18040
18041 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
18042
18043         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
18044         of replacing opterr, getopt, etc.  This should handle the
18045         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
18046
18047 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
18048
18049         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
18050         we can stop lying to compilers about the constness of argv when we
18051         are compiled outside glibc.
18052         (getopt, getopt_long, getopt_long_only): Use it.
18053         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
18054         _getopt_internal, getopt): Likewise.
18055         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
18056         _getopt_long_only_r): Likewise.
18057         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
18058         _getopt_long_r, _getopt_long_only_r): Likewise.
18059
18060         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
18061         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
18062         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
18063         the other external symbols.
18064         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
18065         declaration, since the above renaming now works around collisions.
18066
18067 2004-11-11  Jim Meyering  <jim@meyering.net>
18068
18069         * lib/linebreak.c: Remove trailing blanks.
18070         * lib/alloca_.h: Likewise.
18071         * lib/acosl.c: Likewise.
18072         * lib/euidaccess.c: Likewise.
18073         * lib/allocsa.h: Likewise.
18074
18075 2004-11-10  Simon Josefsson  <jas@extundo.com>
18076
18077         * m4/getaddrinfo.m4: New file.
18078
18079 2004-11-10  Simon Josefsson  <jas@extundo.com>
18080
18081         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
18082
18083 2004-11-10  Simon Josefsson  <jas@extundo.com>
18084
18085         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18086         getaddrinfo.
18087
18088         * modules/getaddrinfo: New file.
18089
18090 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18091
18092         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
18093
18094 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18095
18096         * lib/mktime.c (SHR): New macro, which is a portable
18097         substitute for >> that should work even on Crays.
18098         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
18099         Problem reported by Mark D. Baushke in
18100         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
18101         * lib/getdate.y (SHR): Likewise.
18102         (tm_diff): Use it.
18103         * lib/strftime.c (SHR): Likewise.
18104         (tm_diff): Use it.
18105         * lib/quotearg.c (struct quoting_options): Use unsigned int for
18106         quote_these_too, so that right shifts are well defined.  All uses
18107         changed.
18108
18109 2004-11-10  Jim Meyering  <jim@meyering.net>
18110
18111         Ensure that no close failure goes unreported.
18112         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
18113         return early when it seems there's nothing to flush.
18114         Don't include __fpending.h.
18115
18116 2004-11-10  Jim Meyering  <jim@meyering.net>
18117
18118         * modules/closeout (Depends-on): Remove fpending.
18119
18120 2004-11-10  Jim Meyering  <jim@meyering.net>
18121
18122         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
18123
18124 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18125
18126         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
18127         gl_FUNC_STRFTIME.
18128         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
18129         and AC_REQUIRE when possible, to avoid duplicate checks.
18130         Check for <wchar.h>.
18131
18132 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18133
18134         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
18135
18136 2004-11-09  Bruno Haible  <bruno@clisp.org>
18137
18138         * m4/sockpfaf.m4: New file.
18139
18140 2004-11-05  Bruno Haible  <bruno@clisp.org>
18141
18142         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
18143         Reported by Mark D. Baushke <mdb@cvshome.org>.
18144
18145 2004-11-04  Bruno Haible  <bruno@clisp.org>
18146
18147         2004-09-11  Bruno Haible  <bruno@clisp.org>
18148                 * allocsa.valgrind: New file.
18149         2004-02-06  Bruno Haible  <bruno@clisp.org>
18150                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
18151                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
18152                 Reported by Christopher Seip <chris.seip@hp.com>.
18153
18154 2004-11-04  Bruno Haible  <bruno@clisp.org>
18155
18156         * modules/allocsa (Files): Add lib/allocsa.valgrind.
18157         (Makefile.am): Distribute it.
18158
18159 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
18160
18161         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
18162         with errno == ERANGE if the buffer is too small.
18163         Problem reported by Mark D. Baushke.
18164
18165 2004-11-03  Albert Chin  <china@thewrittenword.com>
18166             Paul Eggert  <eggert@cs.ucla.edu>
18167
18168         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
18169         equivalent, substitute $ac_type for equivalent type rather than
18170         blindly using uint32_t *always* which won't work if uint32_t is not
18171         available.  Define _UINT32_T to work around typedef of uint32_t if
18172         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
18173         2.5.1.
18174
18175 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18176
18177         * m4/jm-macros.m4: Sync from coreutils.
18178         (gl_MACROS): Check for mbrlen, for pathchk.
18179         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
18180
18181 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18182
18183         * lib/xreadlink.c (MAXSIZE): New macro.
18184         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
18185         size does not exceed MAXSIZE.  Avoid cast.
18186         As suggested by Mark D. Baushke in
18187         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
18188         if readlink fails with buffer size just under MAXSIZE, try again
18189         with MAXSIZE.
18190
18191 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18192
18193         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
18194
18195 2004-11-02  Derek R. Price  <derek@ximbiot.com>
18196         and  Paul Eggert  <eggert@cs.ucla.edu>
18197
18198         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
18199         (get_date): Overparenthesize to avoid GCC warning.
18200
18201 2004-11-02  Bruno Haible  <bruno@clisp.org>
18202
18203         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
18204         returns void.
18205
18206 2004-11-02  Bruno Haible  <bruno@clisp.org>
18207
18208         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
18209         function returns void.
18210
18211 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18212
18213         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
18214         fflush_unlocked, flockfile, funlockfile, funlockfile,
18215         fputs_unlocked, putc_unlocked.
18216
18217 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18218
18219         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
18220         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
18221         already declared.
18222
18223 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18224
18225         * modules/getdate (Files): Add doc/getdate.texi.
18226         (Depends-on): Add setenv, xalloc.
18227
18228 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18229
18230         * lib/getdate.y: Add support for TZ="foo" within a date string.
18231         Fix some bugs near time_t boundaries.  Reject dates with
18232         out-of-range components, e.g., "Sept 31".
18233         Include <stdlib.h>, "setenv.h", "xalloc.h".
18234         (ISDIGIT_LOCALE): Remove; unused.
18235         Note that the TZ and time functions used here are not reentrant.
18236         (mktime_ok, get_tz): New functions.
18237         (TZBUFSIZE): New constant.
18238         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
18239         This requires that we sometimes generate our own TZ="XXX..." setting.
18240
18241 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18242
18243         * doc/getdate.texi: New file, from coreutils with modifications for
18244         the new TZ parsing.
18245
18246 2004-10-27  Derek R. Price  <derek@ximbiot.com>
18247
18248         * lib/mktime.c (not_equal_tm): Remove redundant check.
18249
18250 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18251
18252         * modules/regex (lib_SOURCES): Add regex.c.
18253         Reported by James Youngman in
18254         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
18255
18256 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18257
18258         * lib/getdate.y: Use Bison 1.875 features, and some minor
18259         code cleanups.  This change does not affect semantics.
18260         Don't include <stdlib.h>; no longer needed.
18261         Don't include unlocked-io.h; only the "#if TEST" code uses
18262         stdio, and performance isn't crucial there.
18263         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
18264         Bison 1.875 features as described below.
18265         All uses of "PC." replaced by "pc->".
18266         (YYSTYPE): Add a forward declaration.
18267         (yylex, yyerror): Use full prototypes in forward decls.
18268         Use "%pure-parser" rather than obsolescent "%pure_parser".
18269         Use %parse-param and %lex-param instead of obsolescent
18270         YYPARSE_PARAM and YYLEX_PARAM.
18271         (meridian_table, month_and_day_table, time_units_table,
18272         relative_time_table, time_zone_table, military_table,
18273         lookup_zone, lookup_word, get_date):
18274         Use NULL instead of 0 where appropriate.
18275         (to_hour): Avoid abort (), to avoid a dependency on
18276         stdlib.h.
18277         (yyerror, yylex): Now accepts parser_control * arg.
18278         (main) [TEST]: Use '\0' rather than 0 for char.
18279
18280 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
18281
18282         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
18283
18284 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
18285
18286         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
18287         It's now the caller's responsibility to handle the case where
18288         !HAVE_GETPAGESIZE && !defined getpagesize.
18289
18290         * lib/mktime.c (leapyear): Arg is long int, not int.
18291
18292 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
18293
18294         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
18295
18296 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
18297
18298         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
18299         missing.  Problem reported by James Youngman.
18300
18301 2004-10-16  Simon Josefsson  <jas@extundo.com>
18302
18303         * gnulib-tool: Fix comments.  Fix parse problem.
18304         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
18305
18306 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
18307
18308         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
18309         implementation of getopt_long.  Problem reported by Alexander Taler in:
18310         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
18311
18312 2004-10-15  Bruno Haible  <bruno@clisp.org>
18313
18314         * gnulib-tool: Untabify. Initialize supplied_libname.
18315         (func_usage): More homogenous output.
18316         (func_modules_transitive_closure, func_modules_to_filelist,
18317         func_emit_lib_Makefile_am): New functions.
18318         (func_import): New function, extracted from big case statement. Use
18319         func_get_license, func_modules_transitive_closure,
18320         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
18321         opt_lgpl. Don't use test -a, as it's not portable.
18322         (func_create_testdir): Use func_modules_transitive_closure,
18323         func_modules_to_filelist, func_emit_lib_Makefile_am.
18324
18325 2004-10-15  Bruno Haible  <bruno@clisp.org>
18326
18327         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
18328
18329 2004-10-15  Bruno Haible  <bruno@clisp.org>
18330
18331         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
18332         the portions belonging to each module.
18333         Suggested by Derek Robert Price <derek@ximbiot.com>.
18334
18335 2004-10-12  Simon Josefsson  <jas@extundo.com>
18336
18337         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
18338         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
18339         to real functions.
18340
18341 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18342
18343         * modules/vsnprintf: New file.
18344
18345 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18346
18347         * m4/vsnprintf.m4: New file.
18348
18349 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18350
18351         * lib/vsnprintf.h: New file.
18352         * lib/vsnprintf.c: New file.
18353
18354 2004-10-11  Bruno Haible  <bruno@clisp.org>
18355
18356         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
18357         vsnprintf.
18358
18359 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
18360
18361         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
18362
18363 2004-10-07  Bruno Haible  <bruno@clisp.org>
18364
18365         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
18366         fits into the provided buffer.
18367
18368 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
18369
18370         * lib/diacrit.c, diacrit.h: Add GPL notice.
18371
18372         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
18373         notice.
18374         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
18375         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
18376         This avoids a potential constant-folding bug.
18377
18378 2004-10-05  Bruno Haible  <bruno@clisp.org>
18379
18380         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
18381         for the declaration of strsep.
18382
18383 2004-10-05  Bruno Haible  <bruno@clisp.org>
18384
18385         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
18386
18387 2004-10-04  Simon Josefsson  <jas@extundo.com>
18388
18389         * modules/memmem: New file.
18390         * tests/test-memmem.c: New file.
18391         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
18392
18393 2004-10-04  Simon Josefsson  <jas@extundo.com>
18394
18395         * m4/memmem.m4: New file.
18396
18397 2004-10-04  Simon Josefsson  <jas@extundo.com>
18398
18399         * lib/memmem.h: New file.
18400         * lib/memmem.c: New file, taken from glibc.
18401
18402 2004-10-04  Simon Josefsson  <jas@extundo.com>
18403
18404         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
18405         '#ifdef USE_UNLOCKED_IO'.
18406
18407 2004-10-04  Simon Josefsson  <jas@extundo.com>
18408
18409         * config/srclist.txt: Add memmem from glibc.
18410
18411 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18412
18413         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
18414
18415         * modules/argmatch, modules/argp, modules/closeout, modules/error,
18416         modules/exclude, modules/getdate, modules/getline,
18417         modules/getndelim2, modules/getpass, modules/getpass-gnu,
18418         modules/getusershell, modules/linebuffer, modules/md5,
18419         modules/mountlist, modules/posixtm, modules/readtokens,
18420         modules/readutmp, modules/regex, modules/sha1,
18421         modules/version-etc, modules/yesno:
18422         Remove dependency on unlocked-io.
18423
18424 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18425
18426         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
18427
18428         * m4/unlocked-io.m4: Add copyright notice.
18429         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
18430
18431 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18432
18433         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
18434         * lib/xmalloc.c (xmemdup): Likewise.
18435         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
18436         XFREE): Remove these long-obsolescent macros.
18437         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
18438         * lib/xstrdup.c: Remove.
18439
18440         * lib/regex.c (re_comp): Cast gettext return value to char *,
18441         Problem reported by Martin Neitzel via Mark D. Baushke.
18442
18443 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18444
18445         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
18446         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
18447         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
18448         regex.c, sha1.c, version-etc.c, yesno.c:
18449         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
18450         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
18451         the includer's responsibility.
18452
18453         Sync from coreutils.
18454
18455         * lib/modechange.c (mode_compile): Don't decrement a pointer that
18456         points to the start of a string, as the C Standard says the
18457         resulting behavior is undefined.
18458
18459         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
18460         simple -> simple_backups, numbered_existing ->
18461         numbered_existing_backups, numbered -> numbered_backups
18462         to avoid shadowing problems.  All uses changed.
18463         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
18464         * lib/backupfile.c (check_extension, numbered_backup):
18465         Rename locals to avoid shadowing 'basename'.
18466         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
18467         once.
18468
18469         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
18470         * lib/.cvsignore: Add getopt.h.
18471
18472 2004-10-04  Bruno Haible  <bruno@clisp.org>
18473
18474         * modules/README: New file.
18475         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
18476         not a module.
18477
18478 2004-10-02  Jim Meyering  <jim@meyering.net>
18479
18480         * lib/dirfd.h, getpagesize.h: Add copyright notice.
18481
18482 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18483
18484         * modules/strsep: New file.
18485
18486 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18487
18488         * m4/strsep.m4: New file.
18489
18490 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18491
18492         * lib/strsep.h: New file.
18493         * lib/strsep.c: New file.
18494
18495 2004-10-01  Simon Josefsson  <jas@extundo.com>
18496
18497         * lib/snprintf.c (snprintf): Handle size==0.
18498
18499 2004-10-01  Simon Josefsson  <jas@extundo.com>
18500             Bruno Haible  <bruno@clisp.org>
18501
18502         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
18503         (snprintf): Declare 'args'.
18504
18505 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
18506
18507         * lib/snprintf.c: Remove comments as to why each header is needed.
18508
18509 2004-10-01  Bruno Haible  <bruno@clisp.org>
18510
18511         * MODULES.html.sh: Add strsep.
18512
18513 2004-09-30  Simon Josefsson  <jas@extundo.com>
18514
18515         * modules/snprintf: New file.
18516
18517 2004-09-30  Simon Josefsson  <jas@extundo.com>
18518
18519         * m4/snprintf.m4: New file.
18520
18521 2004-09-30  Simon Josefsson  <jas@extundo.com>
18522
18523         * lib/snprintf.h, lib/snprintf.c: New files.
18524
18525 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18526
18527         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
18528         (hol_entry_help): Never translate an empty string.
18529         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
18530         * lib/argp.h (OPTION_NO_TRANS): New option.
18531
18532 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
18533
18534         * modules/argp (Maintainer): Replace Simon Josefsson
18535         by Sergey Poznyakoff.
18536
18537 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
18538
18539         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
18540         changes merged back into glibc.
18541
18542 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
18543
18544         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
18545
18546 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
18547
18548         * lib/xvasprintf.c: Include xalloc.h.
18549         (xvasprintf): Use xalloc_die, not xmalloc_die.
18550
18551 2004-09-29  Bruno Haible  <bruno@clisp.org>
18552
18553         * modules/alloca-opt: New file, derived from modules/alloca.
18554         * modules/allocsa: Depend on alloca-opt instead of alloca.
18555         * modules/setenv: Likewise.
18556         * modules/vasnprintf: Likewise.
18557         * MODULES.html.sh: Add alloca-opt.
18558
18559 2004-09-28  Simon Josefsson  <jas@extundo.com>
18560
18561         * gnulib-tool: New parameter --lgpl, to asseert that modules are
18562         LGPL, and to replace license template from GPL to LGPL.
18563
18564 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
18565
18566         * modules/dummy: Change license to LGPL.
18567
18568 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
18569
18570         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
18571
18572 2004-09-24  Simon Josefsson  <jas@extundo.com>
18573
18574         * modules/minmax (License): Change from GPL to LGPL.
18575
18576 2004-09-23  Simon Josefsson  <jas@extundo.com>
18577
18578         * gnulib-tool (--import): Typo.
18579
18580 2004-09-23  Simon Josefsson  <jas@extundo.com>
18581
18582         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
18583
18584 2004-09-22  Bruno Haible  <bruno@clisp.org>
18585
18586         * modules/*: Add 'License' field.
18587         * gnulib-tool: Accept --extract-license option.
18588         (func_get_license): New function.
18589
18590 2004-09-21  Bruno Haible  <bruno@clisp.org>
18591
18592         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
18593         Reported by Simon Josefsson.
18594
18595 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
18596
18597         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
18598         gl_AC_TYPE_LONG_LONG.
18599
18600 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
18601
18602         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
18603
18604 2004-09-18  Simon Josefsson  <jas@extundo.com>
18605         and  Paul Eggert  <eggert@cs.ucla.edu>
18606
18607         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
18608         calls with autoreconf.  Define GL_LIB.
18609
18610 2004-09-14  Karl Berry  <karl@gnu.org>
18611
18612         * config/srclist.txt: unsync setenv.c, sigh.
18613
18614 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
18615
18616         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
18617         Problem reported by Bruno Haible in:
18618         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
18619
18620 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
18621
18622         * config/srclist.txt: Comment out argp-pvh.c.
18623
18624 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
18625
18626         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
18627         in case some system header has #define'd it.  Problem reported by
18628         Soeren D. Schulze in
18629         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
18630
18631 2004-09-09  Karl Berry  <karl@gnu.org>
18632
18633         * regex.[ch]: delete from the root.  These were supposed to be
18634                 synced with emacs cvs, but this has not happened for about
18635                 a year, and anyway nothing else uses emacs regex.[ch].
18636                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
18637                 lib/regex[.ch] is untouched.
18638
18639 2004-09-09  Bruno Haible  <bruno@clisp.org>
18640
18641         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
18642
18643 2004-09-09  Bruno Haible  <bruno@clisp.org>
18644
18645         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
18646         modifications.
18647         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
18648
18649 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
18650
18651         * modules/xvasprintf: New file.
18652         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
18653
18654 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
18655
18656         * lib/xvasprintf.h: New file.
18657         * lib/xvasprintf.c: New file.
18658         * lib/xasprintf.c: New file.
18659
18660 2004-09-08  Bruno Haible  <bruno@clisp.org>
18661
18662         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
18663
18664 2004-09-08  Bruno Haible  <bruno@clisp.org>
18665
18666         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
18667         length is > INT_MAX.
18668         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
18669         more.
18670
18671 2004-09-08  Bruno Haible  <bruno@clisp.org>
18672
18673         * lib/stdint_.h: New file, taken from GNU clisp.
18674
18675 2004-09-08  Bruno Haible  <bruno@clisp.org>
18676             Oskar Liljeblad  <oskar@osk.mine.nu>
18677
18678         * modules/stdint: New file.
18679         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
18680
18681 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18682
18683         Import from coreutils.
18684         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
18685         strings on unbounded length.  alloca's performance benefits aren't
18686         that important here.
18687         (V_STRDUP): Remove.
18688         (parse_with_separator): New function, with most of the internals
18689         of the old parse_user_spec.  Allow user to omit both user and group,
18690         for compatibility with FreeBSD.
18691         Clone only the user name, not the entire spec.
18692         Do not set *uid, *gid unless entirely successful.
18693         Avoid memory leak in some failing cases.
18694         Fix regression for USER.GROUP reported by Dmitry V. Levin in
18695         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
18696         (parse_user_spec): Rewrite to use parse_with_separator.
18697
18698 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18699
18700         * modules/userspec: Don't depend on alloca.
18701
18702 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18703
18704         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
18705
18706 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18707
18708         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
18709         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
18710         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
18711
18712 2004-08-16  Simon Josefsson  <jas@extundo.com>
18713
18714         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
18715         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
18716         Add --dry-run for --import.
18717         Let user provided command line parameters override configure.ac
18718         settings.
18719
18720 2004-08-12  Simon Josefsson  <jas@extundo.com>
18721
18722         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
18723         as discussed with Paul Eggert in threads rooted at
18724         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
18725         and
18726         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
18727         Before, the test was empty, and relied on ELIDE_CODE in source
18728         code.)
18729         (gl_PREREQ_GETOPT): New macro.
18730         (gl_GETOPT): Use them.
18731
18732 2004-08-12  Simon Josefsson  <jas@extundo.com>
18733
18734         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
18735         * lib/getopt_.h: Renamed from getopt.h.
18736
18737 2004-08-12  Simon Josefsson  <jas@extundo.com>
18738
18739         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
18740         Change default library name from libfoo to libgnu.
18741         Now, if you have a configure.ac that says:
18742                 gl_SOURCE_BASE(gl)
18743                 gl_M4_BASE(gl/m4)
18744                 gl_MODULES(error getopt etcetera)
18745                 gl_INIT
18746         you can import all you need by running:
18747                 ../gnulib/gnulib-tool --import
18748
18749         * modules/getopt (Files): Rename getopt.h to getopt_.h.
18750         (Makefile.am): Rewrite, use logic from argz.
18751         (Include): Use <getopt.h> instead of "getopt.h".
18752
18753 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18754
18755         * modules/argp (Files): Add m4/unlocked-io.m4.
18756         (Depends-on): Add extensions.
18757
18758 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18759
18760         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
18761         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
18762         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
18763         Check for program_invocation_name, program_invocation_short_name,
18764         flockfile, funlockfile, features.h, _getopt_long_only_r.
18765
18766 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18767
18768         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
18769         its complicated substitute.
18770         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
18771         and program_invocation_name.
18772         (__argp_basename) [!_LIBC]: Remove; the only use was
18773         replaced by its body.
18774         (__argp_short_program_name): Change condition from
18775         !defined __argp_short_program_name to
18776         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
18777         to match argp-namefrob.h.
18778         (__argp_failure): Don't assume strerror_r returns char *.
18779         * lib/argp-parse.c (N_): Define unconditionally.
18780         (argp_default_options): Fill out initializers with 0 to avoid
18781         gcc warnings.
18782
18783 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18784
18785         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
18786         getopt1.c.
18787
18788 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18789
18790         Merge from coreutils.
18791
18792         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
18793
18794         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
18795         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
18796
18797 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18798
18799         Merge from coreutils.
18800
18801         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
18802         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
18803         for Reliant Unix 5.43.
18804
18805         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
18806         (union fooround): Use uintmax_t, not long int.
18807         The rest is a merge from libc:
18808         [defined _LIBC]: Include <shlib-compat.h>.
18809         (_obstack) [defined _LIBC]: Remove after 2.3.4.
18810
18811         * lib/settime.c (settime): Recode to avoid warning with
18812         Sun Forte C 6U2.
18813
18814         * lib/strverscmp.c: Convert to UTF-8.
18815
18816 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18817
18818         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
18819         m4/uintmax_t.m4.
18820
18821 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18822
18823         * modules/xalloc-die: New file.
18824         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
18825
18826         * modules/md5 (Files): Add m4/uint32_t.m4.
18827         * modules/sha1: Renamed from modules/sha.
18828         (Files):
18829         Rename lib/sha.h to lib/sha1.h.
18830         Rename lib/sha.c to lib/sha1.c.
18831         Rename m4/sha.m4 to m4/sha1.m4.
18832         (lib_SOURCES): Likewise.
18833         (configure.ac): Rename gl_SHA to gl_SHA1.
18834         (Include): sha.h -> sha1.h.
18835
18836 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18837
18838         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
18839         * m4/sha1.m4: Renamed from sha.m4.
18840         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
18841
18842 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18843
18844         * lib/obstack.h (obstack_empty_p):
18845         Don't assume that chunk->contents is suitably aligned.
18846         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
18847         Likewise. Problem reported by Benno in
18848         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
18849
18850         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
18851         readable.  This could be improved further but it'd take some work.
18852
18853 2004-08-08  Simon Josefsson  <jas@extundo.com>
18854
18855         * modules/xgethostname (Depends-on): Remove exit and error (not
18856         used).
18857
18858         * modules/getpass-gnu: Add getpass.h.
18859         (Depends-on): Add stdbool.
18860         * modules/getpass: Add getpass.h.
18861
18862 2004-08-08  Simon Josefsson  <jas@extundo.com>
18863
18864         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
18865         Check getpass declaration.
18866
18867 2004-08-08  Simon Josefsson  <jas@extundo.com>
18868
18869         * lib/xgethostname.c: Don't include error.h (not used).
18870
18871         * lib/getpass.h: Add.
18872         * lib/getpass.c: Include getpass.h first.
18873
18874 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
18875
18876         * lib/xalloc-die.c: New file.
18877         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
18878         All uses removed.
18879         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
18880         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
18881         xalloc-die.c.
18882         (_, N_, xalloc_die): Move to xalloc-die.c.
18883         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
18884         so that we needn't mess with xalloc_msg_memory_exhausted.
18885
18886         * lib/sha1.h: Renamed from sha.h.
18887         (SHA1_H): Renamed from _SHA_H.
18888         (sha1_ctx): Renamed from sha_ctx.
18889         (sha1_init_ctx): Renamed from sha_init_ctx.
18890         (sha1_process_block): Renamed from sha_process_block.
18891         (sha1_process_bytes): Renamed from sha_process_bytes.
18892         (sha1_finish_ctx): Renamed from sha_finish_ctx.
18893         (sha1_read_ctx): Renamed from sha_read_ctx.
18894         (sha1_stream): Renamed from sha_stream.
18895         (sha1_buffer): Renamed from sha_buffer.
18896         * lib/sha1.c: Likewise; renamed from sha.c.
18897         Do not include <sys/types.h>.
18898         Include <stddef.h> rather than <stdlib.h>.
18899
18900 2004-08-08  Bruno Haible  <bruno@clisp.org>
18901
18902         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
18903         FILESYSTEM_PREFIX_LEN.
18904         * lib/progreloc.c: Likewise.
18905         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
18906
18907 2004-08-06  Simon Josefsson  <jas@extundo.com>
18908
18909         * modules/progname (Depends-on): Don't depend on stdbool.
18910
18911 2004-08-06  Simon Josefsson  <jas@extundo.com>
18912
18913         * modules/getsubopt: New file.
18914         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18915         getsubopt.
18916
18917 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18918
18919         More merge from coreutils.
18920
18921         * m4/utimens.m4, m4/utimecmp.m4: New files.
18922         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
18923         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
18924         prereq.m4, sha.m4: Import changes from coreutils.
18925
18926 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18927
18928         More merge from coreutils.
18929         * modules/raise, modules/readtokens0, modules/utimens:
18930         * modules/utimecmp, module/xnanosleep: New files.
18931         * modules/strftime: Add lib/strftime.h.
18932         Change include from <time.h> to "strftime.h".
18933         * modules/yesno: Add lib/yesno.h.
18934         * modules/backupfile: Remove lib/addext.c.
18935         * modules/euidaccess: Add stat-macros.h.
18936         * modules/canonicalize, modules/euidaccess,
18937         modules/filemode, modules/lchown, modules/makepath,
18938         modules/rmdir, modules/stat: Likewise.
18939
18940 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18941
18942         Merge from tar.
18943         * lib/argp-help.c (make_hol, hol_append): Don't assume that
18944         SIZE_MAX is a valid preprocessor constant.
18945         (__argp_basename): Change from "#ifndef _LIBC"
18946         to "#ifndef __argp_short_program_name", so that
18947         we don't compile these functions for tar.
18948
18949         More merges from coreutils.
18950         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
18951         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
18952         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
18953         * lib/addext.c: Remove; no longer needed.
18954         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
18955         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
18956         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
18957         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
18958         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
18959         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
18960         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
18961         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
18962         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
18963         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
18964         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
18965         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
18966         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
18967         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
18968         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
18969         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
18970         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
18971         Import changes from coreutils.
18972
18973 2004-08-05  Simon Josefsson  <jas@extundo.com>
18974
18975         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
18976
18977 2004-08-05  Simon Josefsson  <jas@extundo.com>
18978
18979         * m4/getsubopt.m4: New file.
18980
18981 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
18982
18983         Merge from coreutils.
18984
18985         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
18986         * m4/getcwd-path-max.m4: New files.
18987
18988         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
18989         FILESYSTEM_PREFIX_LEN ->
18990         FILE_SYSTEM_PREFIX_LEN.
18991         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
18992         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
18993         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
18994         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
18995
18996         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
18997         prerequisite modules now handle the DOS stuff.
18998         Don't check for unistd.h.
18999
19000 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19001
19002         Merge from coreutils.
19003
19004         * lib/.gdb-history: Remove; this doesn't belong here.
19005
19006         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
19007         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
19008         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
19009         * lib/getcwd.c: New files.
19010
19011         * lib/dirname.h: Include <stdbool.h>.
19012         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
19013         for consistency with POSIX terminology.  All uses changed.
19014         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
19015         (strip_trailing_slashes): Use bool for booleans.
19016         * lib/stripslash.c (strip_trailing_slashes): Likewise.
19017
19018         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
19019         sometimes returns a positive errno value even when it succeeds.
19020         (print_errno_message) [!LIBC]: Fall back on strerror if
19021         __strerror_r fails.
19022
19023         * lib/path-concat.c (mempcpy): Don't define if a system header defines
19024         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
19025         (longest_relative_suffix): New function.
19026         (path_concat): Use it.  Assume first argument is not NULL.
19027         Port to DOS.  Omit redundant separators.
19028         Report an error instead of returning NULL.
19029         Use mempcpy instead of memcpy.
19030         (xpath_concat): Remove: not declared or used.
19031
19032         * lib/same.h: Include <stdbool.h>
19033         (same_name): Return bool, not int.
19034         * lib/same.c (same_name): Likewise.
19035         (errno): Don't declare; we assume C89 or better now.
19036
19037         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
19038         if not already defined.
19039
19040         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
19041         * lib/dup-safer.c (errno): Likewise.
19042
19043 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19044
19045         Merge from coreutils.
19046         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
19047         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
19048         * modules/path-concat: Don't depend on strdup.
19049
19050 2004-08-03  Simon Josefsson  <jas@extundo.com>
19051
19052         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
19053         * lib/progname.h: Don't include stdbool.h.
19054
19055 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19056
19057         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
19058         * MODULES.html.sh (func_all_modules): Remove fatal.
19059
19060 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19061
19062         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
19063
19064 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19065
19066         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
19067         working.
19068
19069 2004-08-02  Simon Josefsson  <jas@extundo.com>
19070
19071         * lib/getsubopt.h: New file, with comments from Bruno Haible.
19072         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
19073         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
19074
19075 2004-08-01  Simon Josefsson  <jas@extundo.com>
19076
19077         * lib/xgetdomainname.c: Include stdlib.h, for free().
19078
19079 2004-07-19  Bruno Haible  <bruno@clisp.org>
19080
19081         * MODULES.html.sh (func_all_modules): Add dummy.
19082
19083 2004-07-16  Simon Josefsson  <jas@extundo.com>
19084
19085         * modules/dummy: New file.
19086
19087 2004-07-16  Simon Josefsson  <jas@extundo.com>
19088
19089         * lib/dummy.c: New file.
19090
19091 2004-07-16  Bruno Haible  <bruno@clisp.org>
19092
19093         * lib/backupfile.h: Add extern "C" for C++.
19094         * lib/closeout.h: Likewise.
19095         * lib/copy-file.h: Likewise.
19096         * lib/findprog.h: Likewise.
19097         * lib/full-write.h: Likewise.
19098         * lib/pathname.h: Likewise.
19099         * lib/progname.h: Likewise.
19100         * lib/stpcpy.h: Likewise.
19101         * lib/stpncpy.h: Likewise.
19102         * lib/strcase.h: Likewise.
19103         * lib/strstr.h: Likewise.
19104         * lib/xalloc.h: Likewise.
19105
19106         * lib/mbswidth.h: Add extern "C" for C++.
19107         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
19108
19109 2004-07-13  Robert Millan  <robertmh@gnu.org>
19110
19111         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
19112
19113 2004-07-09  Simon Josefsson  <jas@extundo.com>
19114
19115         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
19116         failed without this.)
19117
19118 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19119
19120         * modules/chown (Files): Add lib/fchown-stub.c, since
19121         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
19122
19123 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19124
19125         * lib/fchown-stub.c: New file.
19126
19127 2004-06-24  Jim Meyering  <jim@meyering.net>
19128
19129         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
19130
19131 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19132
19133         * modules/argz: Omit "#include".
19134
19135         * MODULES.html.sh (func_all_modules): Add calloc, to match
19136         2004-06-01 addition of calloc module.
19137
19138 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19139
19140         * m4/argz.m4: New file, which is autoupdated from libtool.
19141
19142 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19143
19144         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
19145         libtool.
19146
19147 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19148
19149         * config/srclist-update: Don't insist on "USA." before the
19150         close-comment, as libtool omits the period and puts the */ on a
19151         separate line.
19152         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
19153         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
19154
19155 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
19156
19157         * modules/argz: New file.
19158         * MODULES.html.sh (func_all_modules): Add argz.
19159
19160 2004-06-12  Jim Meyering  <jim@meyering.net>
19161         and  Paul Eggert  <eggert@cs.ucla.edu>
19162
19163         * modules/hash (Files): Add lib/xalloc.h.
19164         * modules/pipe (Depends-on): Add wait-process.
19165         * modules/stat (Depends-on): Add xalloc.
19166         * modules/userspec (Files): Add lib/userspec.h.
19167         * modules/xstrto
19168
19169         Upgrade from gettext-0.13.
19170         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
19171         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
19172         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
19173
19174 2004-06-10  Jim Meyering  <jim@meyering.net>
19175
19176         * lib/calloc.c: New file.
19177
19178 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
19179
19180         * lib/getdate.y (yylex): Allow space between sign and number.
19181         Problem reported by Dan Jacobson.
19182
19183 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19184
19185         Merge from coreutils CVS.
19186
19187         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
19188         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
19189         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
19190         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
19191         xstrtol.m4: Fix copyright date and/or serial number.
19192
19193         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
19194         See if we need an fchown replacement.
19195         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
19196         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
19197         and use the replacement function if we detect either defect.
19198
19199         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
19200         gl_UTIMECMP.
19201
19202 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19203         and  Jim Meyering  <jim@meyering.net>
19204
19205         Merge from coreutils CVS.
19206
19207         * lib/stat-macros.h: New file, with contents from file-type.h
19208         and coreutils' system.h.
19209         * lib/file-type.c: Include "stat-macros.h".
19210         * lib/file-type.h (file_type): Move all macro definitions to new file,
19211         stat-macros.h.
19212
19213         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
19214         Wrap old code with this conditional.
19215         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
19216         function that does not dereference symlinks.
19217         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
19218
19219         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
19220         dependency problems.
19221         (xreadlink): Accept new arg SIZE, for efficiency.
19222         All decls and uses changed.
19223         * lib/xreadlink.h: Include <stddef.h>, for size_t.
19224
19225         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
19226         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
19227
19228         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
19229         sysexits.h.
19230
19231 2004-06-01  Jim Meyering  <jim@meyering.net>
19232
19233         * m4/calloc.m4: New file.
19234
19235 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
19236
19237         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
19238         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
19239         Also, fix a typo in a diagnostic.
19240
19241 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19242
19243         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
19244         or AC_FUNC_REALLOC.
19245
19246 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19247
19248         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
19249         macros to be defined.
19250         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
19251         the allocator returns NULL because the requested size is zero.
19252
19253 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19254
19255         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
19256         var.  Add comment explaining why libc still defines it.  This
19257         merges the following patch from glibc:
19258         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
19259
19260 2004-05-20  Andreas Schwab  <schwab@suse.de>
19261
19262         * m4/free.m4: Replace free if it not known to work, not the other
19263         way round.
19264
19265 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
19266
19267         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
19268         present in glibc since revision 1.1 of this file.
19269         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
19270         obstack_alignment_mask, obstack_alloc, obstack_base,
19271         obstack_blank, obstack_blank_fast, obstack_chunk_size,
19272         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
19273         obstack_grow0, obstack_init, obstack_int_grow,
19274         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
19275         obstack_next_free, obstack_object_size, obstack_ptr_grow,
19276         obstack_ptr_grow_fast, obstack_room): Remove declarations of
19277         nonexistent functions.
19278
19279 2004-05-18  Karl Berry  <karl@gnu.org>
19280
19281         * config/srclist.txt: break link for vasnprintf.c.
19282
19283 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
19284
19285         Port obstack to the AS/400, where pointers are 16 bytes wide and
19286         you cannot cast an integer to a valid pointer.  This patch is
19287         currently waiting to be integrated into glibc; see
19288         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
19289
19290         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
19291         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
19292         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
19293         (struct obstack): temp member is now a union of a pointer and
19294         an integer, instead of an integer.  All integer uses changed.
19295         This does not affect the physical layout of struct obstack,
19296         except on hosts (like the AS/400) where the size or alignment of
19297         void * is greater than that of ptrdiff_t.
19298         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
19299         __STDC__)]: Store temporary in pointer member of union, not
19300         integer member.
19301         * lib/obstack.c: Include <stddef.h>, for offsetof.
19302         (struct fooalign): Remove; it doesn't need a name.
19303         (union fooround): Change double to long double, and add void *.
19304         (DEFAULT_ALIGNMENT): Use offsetof to compute.
19305         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
19306         not a macro.  Hence the values are always int; so remove all
19307         casts-to-int in uses.
19308
19309 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
19310
19311         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
19312         we can get this patch merged into glibc.
19313
19314 2004-05-17  Derek R. Price  <derek@ximbiot.com>
19315             Paul Eggert  <eggert@cs.ucla.edu>
19316
19317         * m4/argp: Depend on alloca.
19318
19319 2004-05-17  Derek R. Price  <derek@ximbiot.com>
19320             Paul Eggert  <eggert@cs.ucla.edu>
19321
19322         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
19323         freecoding.
19324
19325 2004-05-17  Bruno Haible  <bruno@clisp.org>
19326
19327         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
19328         precision that consists of a '.' followed by an empty digit string.
19329         Patch by Tor Lillqvist <tml@iki.fi>.
19330
19331 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
19332
19333         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
19334         for backward compatibility with older code.  We need our own
19335         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
19336         it under some other name, and our alloca.h will define it.
19337
19338 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
19339             Derek Price  <derek@ximbiot.com>
19340
19341         * lib/alloca.c: Include <alloca.h>, to get our interface.
19342         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
19343         include <alloca.h> first.  Use C89 prototype for alloca; this
19344         requires including <stddef.h> for size_t.  Use extern "C" if C++.
19345         Use #elif for simplicity, since we can assume C89 now.
19346         Don't try to source the system alloca.h since it will not be found
19347         and to prevent recursively including its replacement.
19348         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
19349         * lib/regex.c: Likewise.
19350
19351 2004-05-16  Derek Price  <derek@ximbiot.com>
19352             Paul Eggert  <eggert@cs.ucla.edu>
19353
19354         getline cleanup.  This changes the getndelim2 API: both order of
19355         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
19356         no delimiter).
19357
19358         * lib/getline.c: Don't include stddef.h or stdio.h, since our
19359         interface does that.
19360         (getline): Always use getdelim, so that we don't have two
19361         copies of this code.
19362         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
19363         if available.
19364         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
19365         (GETNDELIM2_MAXIMUM): New macro.
19366         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
19367         instead of the old practice of delim2==0.  All callers changed.
19368         Return -1 on overflow, instead of returning junk.
19369         Do not set *linesize unless allocation succeeds.
19370         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
19371         that we include sys/types.h.
19372         * lib/getnline.h: Likewise.
19373         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
19374         (getndelim2): Reorder arguments.
19375         * lib/getnline.c (getnline, getndelim):
19376         Don't discard the NMAX argument.
19377         (getnline): Invoke getndelim, to avoid code duplication.
19378         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
19379         of (size_t) -1 by callers of the getnline family.
19380
19381 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19382
19383         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
19384         Check for gettimeofday.
19385         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
19386         Check for settimeofday, stime.
19387
19388 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19389
19390         * lib/nanosleep.c (suspended): Change its type from int to
19391         sig_atomic_t volatile.
19392         (first_call): Make it private to rpl_nanosleep, and have it
19393         be zero initially as that's a bit faster.
19394         (my_usleep): Round up fractional times instead of truncating them,
19395         as this is the usual meaning for 'sleep'.
19396
19397         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
19398         doesn't work.
19399         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
19400         (ENOSYS): Define if not defined.
19401         (settime): Fall back on stime if it exists and settimeofday fails.
19402         But don't bother with fallbacks if a method fails with errno == EPERM.
19403
19404 2004-05-11  Jim Meyering  <jim@meyering.net>
19405
19406         Prior to this change, the save_cwd caller required read access to the
19407         current directory on most systems (ones with the fchdir function).
19408
19409         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
19410         fails, try write-only, and finally, resort to using xgetcwd.
19411
19412 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
19413
19414         * lib/obstack.c, obstack.h: Import changes from libc.
19415
19416 2004-04-28  Bruno Haible  <bruno@clisp.org>
19417
19418         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
19419         also implicitly appends .exe to executables.
19420         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
19421         accepts Windows pathnames.
19422         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
19423         Treat Cygwin like Windows, since it now accepts Windows pathnames.
19424         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
19425         Treat Cygwin like Windows, since it now accepts Windows pathnames.
19426         Reported by Derek Robert Price <derek@ximbiot.com>.
19427
19428 2004-04-21  Karl Berry  <karl@gnu.org>
19429
19430         * config/srclist.txt (localcharset.c): break sync.
19431
19432 2004-04-20  Paul Eggert  <eggert@twinsun.com>
19433
19434         * m4/host-os.m4: Add a copyright notice.
19435
19436 2004-04-20  Jim Meyering  <jim@meyering.net>
19437
19438         Change UTILS_ to gl_ in AC_DEFINE'd names.
19439         Change utils_- and jm_-prefixed variables, too.
19440         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
19441         UTILS_FUNC_MKDIR_TRAILING_SLASH.
19442         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
19443
19444         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
19445         Don't emit trailing blanks.
19446         Also rename jm_-prefixed variables to have gl_ prefix.
19447
19448         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
19449         Also rename jm_-prefixed variables to have gl_ prefix.
19450
19451         * m4/jm-macros.m4: Reflect the renamings.
19452         * m4/prereq.m4: Likewise.
19453
19454 2004-04-20  Jim Meyering  <jim@meyering.net>
19455
19456         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
19457         memory.
19458
19459 2004-04-20  Jim Meyering  <jim@meyering.net>
19460             Bruno Haible  <bruno@clisp.org>
19461
19462         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
19463         memory when realloc fails.
19464
19465 2004-04-19  Jim Meyering  <jim@meyering.net>
19466
19467         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
19468         now that readutmp.c may call `free (0)'.
19469
19470 2004-04-19  Bruno Haible  <bruno@clisp.org>
19471
19472         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
19473         * m4/inttypes_h.m4: Likewise.
19474         * m4/stdint_h.m4: Likewise.
19475         * m4/intmax_t.m4: Likewise.
19476         * m4/uintmax_t.m4: Likewise.
19477
19478 2004-04-18  Jim Meyering  <jim@meyering.net>
19479
19480         * m4/prereq.m4: Don't forbid jm_ prefix.
19481
19482         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
19483         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
19484         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
19485         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
19486         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
19487         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
19488         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
19489         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
19490         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
19491         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
19492         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
19493         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
19494         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
19495         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
19496         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
19497         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
19498         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
19499         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
19500         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
19501
19502 2004-04-18  Jim Meyering  <jim@meyering.net>
19503
19504         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
19505         failure, don't leak memory and do call END_UTMP_ENT.
19506
19507 2004-04-16  Jim Meyering  <jim@meyering.net>
19508
19509         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
19510         coreutils' stat program.
19511         (gl_PREREQ): Don't require jm_PREREQ_STAT.
19512
19513 2004-04-11  Paul Eggert  <eggert@twinsun.com>
19514
19515         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
19516         C89.
19517         (CHAR_BIT): Remove, since we assume C89.
19518         Include <stdint.h> if available, as per current Autoconf CVS advice.
19519
19520 2004-03-31  Jim Meyering  <jim@meyering.net>
19521
19522         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
19523         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
19524         * m4/xalloc.m4: Likewise.
19525
19526 2004-03-30  Paul Eggert  <eggert@twinsun.com>
19527
19528         Merge from coreutils.
19529
19530         * m4/inttostr.m4: New file.
19531         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
19532         Require AM_STDBOOL_H and gl_TIMESPEC instead.
19533         Require gl_CLOCK_TIME.
19534         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
19535
19536 2004-03-30  Paul Eggert  <eggert@twinsun.com>
19537
19538         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
19539         not bool, to be more consistent with Unix conventions.
19540         Suggested by Bruno Haible.
19541
19542         Merge from coreutils.
19543
19544         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
19545         * lib/umaxtostr.c: New files.
19546
19547         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
19548         the usual <time.h> dance.
19549         (get_date): Change signature to support fractional time stamps.
19550         All callers changed.
19551         * lib/getdate.y: Include "getdate.h" first, as we can now
19552         assume C89 and don't need to worry about 'const'.
19553         Similarly, include "unlocked-io.h" near start, not in middle.
19554         Include <limits.h>.
19555         (textint.value): Use long int rather than int.
19556         (textint.digits): Use size_t rather than int.
19557         (BILLION, LOG10_BILLION): New constants.
19558         (parser_control): New member rel_ns.  Members day_ordinal,
19559         time_zone, month, day, hour, minutes, rel_year, rel_month,
19560         rel_day, rel_hour, rel_minutes, rel_seconds
19561         are now long int, not int.  Member seconds is now struct timespec,
19562         not int.  New member timespec_seen.  Members dates_seen, days_seen,
19563         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
19564         not int.
19565         (%union.intval): Now long int, not int.
19566         New member timespec.
19567         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
19568         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
19569         (spec): Now is a timespec or an item list.
19570         (timespec, items): New nonterminals.
19571         (time, rel, relunit, number, get_date):
19572         Add support for fractional seconds.
19573         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
19574         (gmtime, localtime, mktime): Remove decls; not needed with C89.
19575         (to_hour): First arg is now long int, not int.
19576         (to_year): Returns long int, not int.
19577         Don't treat year -70 like 70.
19578         (tm_diff): Returns long int, not int.
19579         (lookup_word): Use bool instead of int when appropriate.
19580         (yylex): Use size_t for count, not int.
19581         Detect overflow when parsing large integer constants.
19582         Add support for fractions.
19583         (get_date): Make pointers 'const' if possible.
19584         Use more-portable code to detect integer overflow.
19585         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
19586         Don't use ctime; it's not reliable if the year has >4 digits.
19587
19588         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
19589         This is for compatibility with BSD.
19590
19591         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
19592         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
19593         From coreutils' system.h.
19594
19595         * lib/userspec.c: Don't include "posixver.h".
19596         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
19597         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
19598         compatible extension.  Simplify code by removing a boolean int
19599         that was always nonzero if a string was nonnull.
19600
19601 2004-03-30  Jim Meyering  <jim@meyering.net>
19602
19603         Merge from coreutils.
19604
19605         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
19606         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
19607         on some systems one must include <grp.h> before it.
19608         Reported by Christian Krackowizer.
19609
19610 2004-03-30  Jim Meyering  <jim@meyering.net>
19611
19612         Merge from coreutils.
19613
19614         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
19615
19616         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
19617         an empty input stream.
19618
19619         * lib/readtokens.c: Include <stdbool.h>.
19620         (readtoken): Use `size_t' rather than int/long.
19621         All callers adjusted.
19622         Use `bool' rather than `int' where appropriate.
19623         Use memset rather than an explicit loop.
19624         Use x2nrealloc rather than xrealloc.
19625         Allow the use of `\0' as a delimiter.
19626         (readtokens): Likewise.
19627         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
19628
19629 2004-03-30  Jim Meyering  <jim@meyering.net>
19630
19631         * m4/realloc.m4: Remove file, since now it does no more than
19632         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
19633         the `configure.ac' section of module/realloc.
19634         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
19635
19636 2004-03-30  Bruno Haible  <bruno@clisp.org>
19637
19638         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
19639         nonnull.
19640
19641 2004-03-29  Paul Eggert  <eggert@twinsun.com>
19642
19643         Merge changes to getloadavg.c from coreutils and Emacs.
19644
19645         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
19646         Define to an expression, not to the empty string.
19647         Include cloexec.h and xalloc.h.
19648         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
19649         Use set_cloexec_flag rather than rolling our own.
19650         * lib/cloexec.c, lib/cloexec.h: New files.
19651
19652 2004-03-29  Paul Eggert  <eggert@twinsun.com>
19653
19654         * m4/cloexec.m4: New file.
19655
19656 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19657
19658         * lib/getopt.h: Sync with libc CVS.
19659
19660 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19661             Bruno Haible  <bruno@clisp.org>
19662
19663         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
19664         mbswidth.
19665
19666 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19667             Bruno Haible  <bruno@clisp.org>
19668
19669         * lib/mbswidth.h: Include <wchar.h> only if
19670         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
19671         <wchar.h>.
19672         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
19673
19674 2004-03-09  Paul Eggert  <eggert@twinsun.com>
19675
19676         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
19677         Sync with libc CVS.
19678         * lib/getopt_int.h: New file, also synced from libc.
19679
19680 2004-03-09  Paul Eggert  <eggert@twinsun.com>
19681
19682         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
19683         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
19684         Bring back getopt.c, getopt.h, getopt1.c.
19685
19686 2004-03-07  Paul Eggert  <eggert@twinsun.com>
19687
19688         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
19689         All uses changed.  Check for sa_sigaction member; this fixes
19690         a bug first reported by Jason Andrade in
19691         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
19692
19693 2004-03-07  Paul Eggert  <eggert@twinsun.com>
19694
19695         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
19696         '#if' expressions.  Unlike the code it replaces, it does not
19697         depend on (defined _SC_PAGESIZE).  However, it does depend on
19698         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
19699         first reported by Jason Andrade in
19700         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
19701
19702 2004-02-25  Simon Josefsson  <jas@extundo.com>
19703
19704         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
19705
19706 2004-02-25  Simon Josefsson  <jas@extundo.com>
19707
19708         * lib/strdup.h: New file.
19709         * lib/strdup.c: Include it.
19710         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
19711         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
19712
19713 2004-02-23  Karl Berry  <karl@gnu.org>
19714
19715         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
19716         (from fencepost.gnu.org:/gd/gnuorg).
19717
19718 2004-02-23  Karl Berry  <karl@gnu.org>
19719
19720         * config/srclistvars.sh (GNUORG) [karl]: redefine.
19721         * config/srclist.txt: add maintain/standards documents.
19722
19723 2004-02-18  Bruno Haible  <bruno@clisp.org>
19724
19725         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
19726         Reported by Derek Robert Price <derek@ximbiot.com>.
19727
19728 2004-02-16  Karl Berry  <karl@gnu.org>
19729
19730         * config/mkinstalldirs, install-sh: update from automake.
19731
19732 2004-02-06  Karl Berry  <karl@gnu.org>
19733
19734         * m4/po.m4: update from gettext 0.14.1.
19735
19736 2004-02-06  Karl Berry  <karl@gnu.org>
19737
19738         * lib/config.charset: update from gettext 0.14.1.
19739
19740 2004-02-05  Paul Eggert  <eggert@twinsun.com>
19741
19742         Add comments and code, prompted by suggestions from Bruno Haible
19743         for sh-quote.
19744         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
19745         describing the enum quoting_style values.
19746         * lib/quotearg.c (quotearg_alloc): New function.
19747         (quotearg_buffer_restyled): Treat lone { and } as special.
19748         Treat = as special.  Work around bug with older shells
19749         that "see" a '\' that is really the 2nd byte of a multibyte char.
19750         Quote empty string with shell_quoting_style.
19751
19752 2004-02-03  Bruno Haible  <bruno@clisp.org>
19753
19754         * m4/pipe.m4: New file, from GNU gettext.
19755
19756 2004-02-03  Bruno Haible  <bruno@clisp.org>
19757
19758         * lib/pipe.h: New file, from GNU gettext.
19759         * lib/pipe.c: New file, from GNU gettext.
19760
19761 2004-01-27  Bruno Haible  <bruno@clisp.org>
19762
19763         * m4/execute.m4: New file, from GNU gettext.
19764
19765 2004-01-27  Bruno Haible  <bruno@clisp.org>
19766
19767         * lib/execute.h: New file, from GNU gettext.
19768         * lib/execute.c: New file, from GNU gettext.
19769         * lib/w32spawn.h: New file, from GNU gettext.
19770
19771 2004-01-24  Paul Eggert  <eggert@twinsun.com>
19772
19773         Merge from diffutils.
19774
19775         * lib/file-type.c (file_type): Add typed memory objects.
19776         * lib/file-type.h (S_TYPEISTMO): New macro.
19777
19778         * lib/c-stack.h (c_stack_action): Remove argv argument.
19779         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
19780         (die): Don't calculate message unless segv_action returns.
19781         (get_stack_location, min_address_from_argv, max_address_from_argv,
19782         volatile stack_base, volatile_stack_size): Remove.
19783         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
19784         that every segmentation violation is a stack overflow.  (Ouch!)
19785         See Debian bug 136249 (still outstanding) for more info about why
19786         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
19787
19788 2004-01-24  Paul Eggert  <eggert@twinsun.com>
19789
19790         Exit-status fix from coreutils.
19791
19792         Use exit_failure consistently in place of EXIT_FAILURE,
19793         so that program exit statuses are consistent on failure.
19794
19795         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
19796         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
19797         * lib/argmatch.h: Comment fix to match the above.
19798         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
19799         Now a macro referring to exit_failure, instead of a separate
19800         variable.  Include "exitfail.h" to get it.
19801         * lib/xstrtol.h: Include "exitfail.h".
19802         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
19803
19804         * lib/long-options.c (parse_long_options): Use prototype
19805         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
19806         for clarity.
19807
19808 2004-01-21  Jim Meyering  <jim@meyering.net>
19809
19810         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
19811         so as not to conflict with a different-sized __mktime_internal
19812         function in GNU libc.
19813         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
19814         Problem building statically-linked `ls' reported by Michael Brunnbauer.
19815
19816 2004-01-20  Karl Berry  <karl@gnu.org>
19817
19818         * config/config.guess: update from config.
19819
19820         * config/srclistvars.sh: GNUWWWLICENSES for karl.
19821
19822 2004-01-20  Bruno Haible  <bruno@clisp.org>
19823
19824         Safer stack allocation.
19825         * lib/setenv.c: Include allocsa.h.
19826         (alloca): Remove fallback definition.
19827         (freea): Remove macro.
19828         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
19829         instead of freea.
19830
19831 2004-01-20  Bruno Haible  <bruno@clisp.org>
19832
19833         * m4/eealloc.m4: New file, from GNU gettext.
19834
19835 2004-01-20  Bruno Haible  <bruno@clisp.org>
19836
19837         * m4/allocsa.m4: New file, from GNU gettext.
19838
19839 2004-01-20  Bruno Haible  <bruno@clisp.org>
19840
19841         * lib/xallocsa.h: New file, from GNU gettext.
19842         * lib/xallocsa.c: New file, from GNU gettext.
19843
19844 2004-01-20  Bruno Haible  <bruno@clisp.org>
19845
19846         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
19847
19848 2004-01-20  Bruno Haible  <bruno@clisp.org>
19849
19850         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
19851         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
19852         specially.
19853
19854 2004-01-20  Bruno Haible  <bruno@clisp.org>
19855
19856         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
19857         patch.
19858
19859 2004-01-20  Bruno Haible  <bruno@clisp.org>
19860
19861         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
19862
19863 2004-01-20  Bruno Haible  <bruno@clisp.org>
19864
19865         * lib/eealloc.h: New file.
19866
19867 2004-01-20  Bruno Haible  <bruno@clisp.org>
19868
19869         * lib/binary-io.h: Avoid warnings on Cygwin.
19870
19871 2004-01-20  Bruno Haible  <bruno@clisp.org>
19872
19873         * lib/allocsa.h: New file, from GNU gettext.
19874         * lib/allocsa.c: New file, from GNU gettext.
19875
19876 2004-01-18  Karl Berry  <karl@gnu.org>
19877
19878         * doc/gpl.texi, doc/lgpl.texi: new files.
19879
19880 2004-01-18  Karl Berry  <karl@gnu.org>
19881
19882         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
19883         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
19884
19885 2004-01-15  Paul Eggert  <eggert@twinsun.com>
19886
19887         Merge from coreutils.
19888
19889         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
19890         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
19891         (gl_DEFAULT_POSIX2_VERSION): Move
19892         the documentation from 'configure' into 'config.hin',
19893         so that 'configure --help' isn't burdened by it and
19894         we don't have to worry about its formatting there.
19895         Reword the documentation so that it's more succinct
19896         and can be run together into a single paragraph.
19897         * m4/same.m4 (gl_SAME): Check for pathconf.
19898
19899 2004-01-15  Paul Eggert  <eggert@twinsun.com>
19900
19901         Merge from coreutils.
19902
19903         * lib/posixver.c: Include posixver.h.
19904
19905         * lib/same.c: Include <stdbool.h>, <limits.h>.
19906         (_POSIX_NAME_MAX): Define if not defined.
19907         (MIN): New macro.
19908         (same_name): If file names are silently truncated, report
19909         that the file names are the same if they are the same after
19910         the silent truncation.
19911
19912         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
19913         conversion function.
19914         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
19915         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
19916         longer needed.
19917
19918 2004-01-15  Jim Meyering  <jim@meyering.net>
19919
19920         Merge from coreutils.
19921
19922         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
19923         if no library is required.
19924         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
19925         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
19926         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
19927         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
19928         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
19929         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
19930         value, $ac_cv_search_crypt, if it's "none required".
19931         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
19932         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
19933         not gl_FUNC_GETLOADAVG.
19934         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
19935         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
19936
19937 2004-01-15  Jim Meyering  <jim@meyering.net>
19938
19939         Merge from coreutils.
19940
19941         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
19942         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
19943         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
19944
19945         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
19946         optional configure-time default.
19947
19948         * lib/version-etc.c (version_etc_copyright): Update copyright date.
19949
19950         * lib/xreadlink.c (xreadlink): Correct outdated comment.
19951
19952 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
19953
19954         Merge from coreutils.
19955
19956         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
19957         value, $ac_cv_search_nanosleep, if it's "none required".
19958
19959 2004-01-14  Paul Eggert  <eggert@twinsun.com>
19960
19961         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
19962         with like-named macro in fnmatch.c.
19963         (EXT): Use an internal constant instead.
19964
19965         Merge fnmatch patches from glibc.
19966         * lib/fnmatch.c (mbsinit): Remove define.
19967         Add libc_hidden_ver (__fnmatch, fnmatch).
19968         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
19969         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
19970
19971 2004-01-14  Karl Berry  <karl@gnu.org>
19972
19973         * config/install-sh: update from automake.
19974
19975 2004-01-13  Karl Berry  <karl@gnu.org>
19976
19977         * config/install-sh: update from automake.
19978
19979 2004-01-09  Karl Berry  <karl@gnu.org>
19980
19981         * config/install-sh: update from automake.
19982
19983 2004-01-05  Karl Berry  <karl@gnu.org>
19984
19985         * config/config.{sub,guess}: update from config.
19986
19987 2003-12-31  Karl Berry  <karl@gnu.org>
19988
19989         * config/depcomp: update from automake.
19990
19991 2003-12-14  Karl Berry  <karl@gnu.org>
19992
19993         * lib/config.charset: update from gettext-runtime.
19994
19995 2003-12-03  Paul Eggert  <eggert@twinsun.com>
19996
19997         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
19998         Bug reported by Alfred M. Szmidt.
19999
20000 2003-12-03  Bruno Haible  <bruno@clisp.org>
20001
20002         * m4/gettext.m4: Upgrade from gettext-0.13.
20003         * m4/po.m4: Upgrade from gettext-0.13.
20004         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
20005         * m4/intmax.m4: New file, from gettext-0.13.
20006         * m4/printf-posix.m4: New file, from gettext-0.13.
20007
20008 2003-11-29  Karl Berry  <karl@gnu.org>
20009
20010         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
20011
20012 2003-11-25  Paul Eggert  <eggert@twinsun.com>
20013             Bruno Haible  <bruno@clisp.org>
20014
20015         * lib/printf-parse.h: Don't include sys/types.h.
20016         (ARG_NONE): New macro.
20017         (char_directive): Change type of *arg_index fields to size_t.
20018         * lib/printf-parse.c: Don't include sys/types.h.
20019         (SSIZE_MAX): Remove macro.
20020         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
20021         Remove unnecessary overflow check.
20022         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
20023         fields.
20024
20025 2003-11-25  Bruno Haible  <bruno@clisp.org>
20026
20027         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
20028
20029 2003-11-25  Bruno Haible  <bruno@clisp.org>
20030
20031         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
20032         gt_TYPE_SSIZE_T.
20033
20034 2003-11-24  Paul Eggert  <eggert@twinsun.com>
20035
20036         * modules/alloca: Remove dependency on xalloc.
20037
20038 2003-11-24  Paul Eggert  <eggert@twinsun.com>
20039
20040         * lib/alloca.c: Remove dependency on xalloc module.
20041         (xalloc_die): Remove.
20042         (memory_full) [!defined emacs]: New macro.
20043         [!defined emacs]: Don't include xalloc.h.
20044         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
20045         address arithmetic overflows.  Change datatypes a bit to avoid
20046         unnecessary casts.
20047
20048 2003-11-22  Jim Meyering  <jim@meyering.net>
20049
20050         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
20051         s/size/size_t/.
20052
20053 2003-11-21  Karl Berry  <karl@gnu.org>
20054
20055         * config/config.{sub,guess}: update from config.
20056
20057 2003-11-18  Karl Berry  <karl@gnu.org>
20058
20059         * config/config.{sub,guess}: update from config.
20060
20061         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
20062
20063 2003-11-17  Paul Eggert  <eggert@twinsun.com>
20064
20065         * README: Mention that S+T cannot overflow if S is the size of
20066         an existing object and T is sufficiently small.
20067
20068 2003-11-17  Jim Meyering  <jim@meyering.net>
20069
20070         On systems without utime and without a utimes function capable of
20071         dealing with a NULL struct utimbuf* argument, this utime replacement
20072         could -- in unusual circumstances -- leak a file descriptor.
20073         * lib/utime.c: Include <unistd.h> and <errno.h>.
20074         (utime_null): Be sure to close `fd' and to preserve errno.
20075         Reported by Geoff Collyer via Arnold Robbins.
20076
20077 2003-11-17  Bruno Haible  <bruno@clisp.org>
20078
20079         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
20080         (Depends-on): Add xsize.
20081
20082 2003-11-17  Bruno Haible  <bruno@clisp.org>
20083
20084         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
20085
20086 2003-11-17  Bruno Haible  <bruno@clisp.org>
20087
20088         * lib/vasnprintf.c (alloca): Remove fallback definition.
20089         (freea): Remove definition.
20090         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
20091         Reported by Paul Eggert.
20092
20093 2003-11-16  Paul Eggert  <eggert@twinsun.com>
20094             Bruno Haible  <bruno@clisp.org>
20095
20096         Protect against address arithmetic overflow.
20097         * lib/printf-args.h: Include stddef.h.
20098         (arguments): Change type of field 'count' to size_t.
20099         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
20100         'unsigned int' where appropriate.
20101         * lib/printf-parse.h: Include sys/types.h.
20102         (char_directive): Change type of *arg_index fields to ssize_t.
20103         (char_directives): Change type of fields 'count', max_*_length to
20104         size_t.
20105         * lib/printf-parse.c: Include sys/types.h and xsize.h.
20106         (SSIZE_MAX): Define fallback value.
20107         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
20108         instead of 'int' where appropriate. Check a_allocated, d_allocated
20109         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
20110         * lib/vasnprintf.c: Include xsize.h.
20111         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
20112         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
20113         overflow. Avoid wraparound when converting a width or precision from
20114         decimal to binary.
20115
20116 2003-11-16  Bruno Haible  <bruno@clisp.org>
20117
20118         Update from GNU gettext.
20119         * lib/printf-parse.c: Generalize to it can be compiled for wide
20120         strings.
20121         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
20122         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
20123         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
20124         SNPRINTF): New macros.
20125         Don't include <alloca.h> if the file is used inside libintl.
20126         (local_wcslen): New function, for Solaris 2.5.1.
20127         (VASNPRINTF): Use it instead of wcslen.
20128
20129 2003-11-16  Bruno Haible  <bruno@clisp.org>
20130
20131         * lib/xsize.h (xmax): New function.
20132         (xsum, xsum3, xsum4): Declare as "pure" functions.
20133
20134 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20135
20136         * modules/xalloc (Files): Undo latest change, since xalloc.h
20137         no longer needs SIZE_MAX or PTRDIFF_MAX.
20138
20139 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20140
20141         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
20142         gl_PTRDIFF_MAX.
20143
20144 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20145
20146         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
20147         "return", to pacify some unknown compiler.  Problem reported
20148         by Joerg Schilling.
20149
20150 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20151
20152         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
20153         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
20154         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
20155         heuristic is just as accurate as far as we know, and it removes a
20156         dependency on size_max.m4 and ptrdiff_max.m4.
20157
20158 2003-11-11  Bruno Haible  <bruno@clisp.org>
20159
20160         * modules/xsize (Files): Add m4/size_max.m4.
20161         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
20162
20163 2003-11-11  Bruno Haible  <bruno@clisp.org>
20164
20165         * m4/size_max.m4: New file.
20166         * m4/ptrdiff_max.m4: New file.
20167         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
20168         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
20169         (gl_XALLOC): Invoke it.
20170
20171 2003-11-11  Bruno Haible  <bruno@clisp.org>
20172
20173         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
20174         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
20175         defined.
20176
20177 2003-11-10  Paul Eggert  <eggert@twinsun.com>
20178
20179         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
20180         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
20181         rejected some allocations of exactly SIZE_MAX - 2 bytes.
20182         From Bruno Haible.
20183         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
20184         not (size_t) -1, since it's defined here.
20185
20186 2003-11-09  Karl Berry  <karl@gnu.org>
20187
20188         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
20189
20190 2003-11-06  Paul Eggert  <eggert@twinsun.com>
20191
20192         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
20193         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
20194         Reject sizes of exactly SIZE_MAX bytes.
20195         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
20196         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
20197
20198 2003-11-05  Bruno Haible  <bruno@clisp.org>
20199
20200         * lib/xsize.h: Include limits.h, to avoid a possible collision with
20201         SIZE_MAX defined in <limits.h> on Solaris.
20202
20203 2003-11-04  Jim Meyering  <jim@meyering.net>
20204
20205         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
20206         variable names, rather than @VAR@.
20207         * modules/poll: Likewise.
20208
20209 2003-11-04  Bruno Haible  <bruno@clisp.org>
20210
20211         * modules/xsize: New file.
20212         * modules/linebreak: Depend on xsize.
20213         * MODULES.html.sh (func_all_modules): Add xsize.
20214
20215 2003-11-04  Bruno Haible  <bruno@clisp.org>
20216
20217         * m4/xsize.m4: New file.
20218
20219 2003-11-04  Bruno Haible  <bruno@clisp.org>
20220
20221         * lib/xsize.h: New file.
20222         * lib/linebreak.c: Include xsize.h.
20223         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
20224         argument for overflow.
20225         Suggested by Paul Eggert.
20226
20227 2003-11-03  Karl Berry  <karl@gnu.org>
20228
20229         * config/config.{guess,sub}: update from config.
20230
20231 2003-11-03  Jim Meyering  <jim@meyering.net>
20232
20233         * modules/userspec (lib_SOURCES): Add userspec.h.
20234         (Include): Add "userspec.h".
20235         Improve description.
20236
20237 2003-11-03  Jim Meyering  <jim@meyering.net>
20238
20239         * lib/userspec.c: Include "userspec.h".
20240         * lib/userspec.h: New file.
20241
20242 2003-11-03  Bruno Haible  <bruno@clisp.org>
20243
20244         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
20245
20246 2003-11-03  Bruno Haible  <bruno@clisp.org>
20247
20248         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
20249         available, to avoid (extremely rare) race condition.
20250         Suggested by Paul Eggert.
20251
20252 2003-11-02  Karl Berry  <karl@gnu.org>
20253
20254         * config/srclist.txt (vasprintf.c): sync broken, sigh.
20255
20256 2003-10-31  Paul Eggert  <eggert@twinsun.com>
20257
20258         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
20259         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
20260         (read_filesystem_list): Set and use me_type_malloced.
20261         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
20262         whatever the type happens to be), for brevity and consistency.
20263         Check for size calculation overflow on Alphas running OSF/1.
20264
20265 2003-10-31  Jim Meyering  <jim@meyering.net>
20266
20267         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
20268
20269         * lib/linebuffer.c: Include <string.h> for declaration of memset.
20270
20271 2003-10-30  Paul Eggert  <eggert@twinsun.com>
20272             Bruno Haible  <bruno@clisp.org>
20273
20274         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
20275         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
20276
20277 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
20278
20279         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
20280         netbsd*-gnu*.  Suggested by Robert Millan.
20281
20282 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20283
20284         * modules/group-member: Depend on stdbool.
20285
20286 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20287
20288         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
20289
20290 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20291
20292         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
20293         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
20294         after the 'gnu' in these cases.  This fixes some bugs in the
20295         previous change, and is based on suggestions by Robert Millan.
20296
20297 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20298
20299         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
20300         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
20301         no longer needed.
20302         * lib/quotearg.c (quotearg_n_options): Use it.
20303         * lib/group-member.c: Include <stdbool.h>.
20304         (free_group_info): Arg is now const *; don't free arg.
20305         (get_group_info): Now returns bool and accepts struct group_info *,
20306         rather than returning a malloc'ed struct group_info *.
20307         All uses changed.  Check for overflow in internal size calculation.
20308
20309         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
20310         rather than xmalloc/xrealloc.
20311         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
20312         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
20313         conformance bug: the old code used a pointer after freeing the
20314         storage that it addressed.
20315         * lib/hash.c (hash_initialize): Simplify the code by using
20316         xalloc_oversized rather than doing it by hand.
20317         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
20318         the buffer preserved.  Use free and xmalloc instead.
20319         * lib/quotearg.c (quotearg_n_options): Likewise.
20320         Use a simpler test for size overflow.  Don't use xalloc_oversized
20321         because unsigned int might be wider than size_t (!); this suggests
20322         that we should switch from unsigned int to size_t for slot numbers.
20323
20324 2003-10-28  Paul Eggert  <eggert@twinsun.com>
20325
20326         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
20327         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
20328         NetBSD kernels.  Requested by Richard Stallman.
20329
20330 2003-10-27  Paul Eggert  <eggert@twinsun.com>
20331
20332         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
20333         to allocate the returned structure.  Do not allocate a subarray,
20334         as x2nrealloc will do that.
20335         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
20336         instead of xnrealloc.
20337         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
20338
20339 2003-10-27  Bruno Haible  <bruno@clisp.org>
20340
20341         * lib/stdbool_.h: Better support for BeOS.
20342
20343 2003-10-26  Paul Eggert  <eggert@twinsun.com>
20344
20345         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
20346         now uses inline.
20347
20348 2003-10-26  Paul Eggert  <eggert@twinsun.com>
20349
20350         * lib/xalloc.h (xalloc_oversized): New static inline function, for
20351         callers that want to do their own size-overflow checking.  Include
20352         <stdbool.h>, since xalloc_oversized returns bool.
20353         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
20354         to use xalloc_oversized.
20355
20356         Add two functions x2realloc, x2nrealloc, for programs that grow
20357         arrays dynamically by doubling their sizes.
20358         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
20359         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
20360         New functions.
20361
20362         Port to C99 semantics for 'inline' of external functions.
20363         Bug reported by Bruno Haible.
20364         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
20365         with the old contents of xnmalloc.
20366         (xnmalloc, xmalloc): Use it.
20367         (xnrealloc_inline): New static inline function,
20368         with the old contents of xnrealloc.
20369         (xnrealloc, xrealloc): Use it.
20370
20371         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
20372         that.
20373
20374 2003-10-26  Karl Berry  <karl@gnu.org>
20375
20376         * config/srclist.txt (COPYING.DOC): no longer available from
20377         /gd/gnuorg; don't know where the ultimate source is.
20378
20379 2003-10-25  Paul Eggert  <eggert@twinsun.com>
20380
20381         Fix several address-calculation bugs in the hash modules,
20382         plus some minor code cleanup.
20383
20384         * lib/hash.h: Include <stdbool.h>, for bool.
20385         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
20386         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
20387         hash_get_n_entries, hash_get_max_bucket_length,
20388         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
20389         hash_rehash): Use size_t rather than unsigned.
20390         * lib/hash.c (struct hash_table, hash_get_n_buckets,
20391         hash_get_n_buckets_used, hash_get_n_entries,
20392         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
20393         hash_get_entries, hash_do_for_each, hash_string, is_prime,
20394         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
20395         Likewise.
20396         (SIZE_MAX): Define if not defined.
20397         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
20398         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
20399         hash_print):
20400         Use const * when possible.
20401         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
20402         (check_tuning): Fix bug: if tuning parameters were very close to
20403         0 or 1, rounding errors could have caused subscript violations.
20404         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
20405         (hash_initialize): Add 'fail:' label
20406         to free table and return NULL, and use it to simplify code.
20407         Use calloc rather than clearing the storage ourself.
20408         (hash_initialize, hash_rehash): Check for arithmetic overflow in
20409         buffer size calculations.
20410         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
20411         Include <stddef.h>, for size_t.
20412         * lib/hash-pjw.c (hash_pjw): Likewise.
20413         Switch to method described by Bruno Haible.
20414         Include <limits.h>, for CHAR_BIT.
20415         (SIZE_BITS): New macro.
20416
20417 2003-10-23  Paul Eggert  <eggert@twinsun.com>
20418
20419         * m4/getline.m4 (AM_FUNC_GETLINE):
20420         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
20421         hosts.  Problem reported by Derek Robert Price in
20422         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
20423         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
20424         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
20425
20426 2003-10-21  Paul Eggert  <eggert@twinsun.com>
20427
20428         * lib/getndelim2.c (getndelim2): When size calculation overflows,
20429         ceiling the allocation at NMAX bytes rather than silently
20430         discarding input bytes before NMAX is reached.  This makes
20431         a difference only if NMAX exceeds SIZE_MAX / 2.
20432
20433         * lib/obstack.c: Merge from glibc.
20434         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
20435         Add libc_hidden_def (_obstack_newchunk).
20436         (_obstack_free) [! defined _LIBC]: Remove.
20437         [defined _LIBC]: Make a strong alias from obstack_free, rather than
20438         a clone of the function body.
20439         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
20440         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
20441
20442         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
20443         glibc.
20444         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
20445         arg to memcpy.
20446
20447         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
20448         (obstack_ptr_grow_fast, obstack_int_grow_fast):
20449         Don't use lvalue casts, as GCC plans to remove support for them
20450         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
20451         was also present in the non-GCC version, indicating that this
20452         code had always been buggy and had never been widely used.
20453         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
20454         Use the fast variant of each macro, rather than copying the
20455         definiens of the fast variant; that way, we'll be more likely to
20456         catch future bugs in the fast variants.
20457
20458 2003-10-20  Bruno Haible  <bruno@clisp.org>
20459
20460         * modules/wait-process: New file.
20461         * MODULES.html.sh (func_all_modules): Add wait-process.
20462
20463 2003-10-20  Bruno Haible  <bruno@clisp.org>
20464
20465         * m4/wait-process.m4: New file.
20466
20467 2003-10-20  Bruno Haible  <bruno@clisp.org>
20468
20469         * lib/wait-process.h: New file, from GNU gettext.
20470         * lib/wait-process.c: New file, from GNU gettext.
20471
20472 2003-10-19  Jim Meyering  <jim@meyering.net>
20473
20474         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
20475         HPUX 10.20.
20476
20477 2003-10-18  Karl Berry  <karl@gnu.org>
20478
20479         * config/config.guess: update from config.
20480
20481 2003-10-16  Paul Eggert  <eggert@twinsun.com>
20482
20483         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
20484         (getgroups): First arg is int, not size_t.
20485         Don't let 'free' mangle errno.
20486
20487 2003-10-16  Paul Eggert  <eggert@twinsun.com>
20488
20489         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
20490
20491 2003-10-16  Karl Berry  <karl@gnu.org>
20492
20493         * config/config.{guess,sub}: update from config.
20494
20495 2003-10-16  Jim Meyering  <jim@meyering.net>
20496
20497         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
20498         memcpy.
20499
20500 2003-10-15  Paul Eggert  <eggert@twinsun.com>
20501
20502         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
20503         (SIZE_MAX): Remove.
20504         (new_exclude, add_exclude_file): Initial size no longer needs to
20505         be a power of 2.
20506         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
20507         our own address arithmetic overflow checking.
20508
20509         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
20510         (fnmatch): Do not alloca more than 2000 wide characters;
20511         instead, use malloc for large buffers.
20512         Check for address arithmetic overflow, and return -1
20513         with errno set to ENOMEM in that case.
20514         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
20515         (NEW_PATTERN): Do not alloca more than 8000 bytes;
20516         instead, return -1.  Check for address arithmetic overflow.
20517
20518 2003-10-14  Paul Eggert  <eggert@twinsun.com>
20519
20520         Handle invalid suffixes and overflow independently, so that
20521         callers can treat them independently as needed.  Fix some bugs in
20522         suffix handling, e.g., "100k@" was not diagnosed as an invalid
20523         suffix for a human-readable blocksize.  The major caller-visible
20524         change is the addition of a new
20525         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
20526         that both overflow and suffix chars were found.
20527
20528         * lib/human.c (humblock): Don't check separately for invalid suffix
20529         char; that is xstrtoumax's job (now that its bug is fixed).
20530         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
20531         INTMAX_MAX]: New macros.
20532         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
20533         TYPE_MAXIMUM): New macros.
20534         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
20535         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
20536         if overflow occurs, as it's what __strtol does and it's more useful
20537         in practice.
20538         (__xstrtol): If __strtol reports some error other than ERANGE,
20539         reflect it to the caller as LONGINT_INVALID.  If it reports
20540         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
20541         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
20542         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
20543         value.
20544         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
20545         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
20546         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
20547         [defined UINTMAX_MAX]: New macros.
20548
20549 2003-10-14  Bruno Haible  <bruno@clisp.org>
20550
20551         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
20552
20553 2003-10-14  Bruno Haible  <bruno@clisp.org>
20554
20555         * m4/sig_atomic_t: New file, from GNU gettext.
20556         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
20557
20558 2003-10-14  Bruno Haible  <bruno@clisp.org>
20559
20560         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
20561         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
20562         Also use volatile where needed.
20563
20564 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20565
20566         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
20567         Change maintainer from Bruno Haible to 'all'.
20568
20569 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20570
20571         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
20572
20573 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20574
20575         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
20576         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
20577         and define in terms of the other primitives.
20578         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
20579         (SIZE_MAX): Define if not already defined.
20580         (array_size_overflow): New function.
20581         (xalloc_die): Abort instead of exiting if 'error' returns.
20582         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
20583         (xmalloc, xrealloc): Use them.
20584         (xcalloc): Check for address arithmetic overflow.
20585         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
20586         a bit faster than strcpy.
20587
20588 2003-10-10  Simon Josefsson  <jas@extundo.com>
20589
20590         * modules/argp (Depends-on): Add restrict and strcase.
20591
20592 2003-10-10  Simon Josefsson  <jas@extundo.com>
20593
20594         * m4/argp.m4: Add AC_C_INLINE.
20595
20596 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20597
20598         Merge getpass from libc, plus a few fixes.
20599
20600         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
20601         Include <stdbool.h>.
20602         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
20603         __fsetlocking to empty.
20604         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
20605         do include <bits/libc-lock.h>.
20606         Do not include <fcntl.h>; not needed.
20607         [_LIBC]: Include <wchar.h>.
20608         (NOTCANCEL_MODE): New macro.
20609         (flockfile, funlockfile) [_LIBC]: New macros.
20610         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
20611         [!_LIBC]: New macros.
20612         (call_fclose): New function.
20613         (getpass): Use it.  Save tty stream separately; this simplifies the
20614         code and makes it more reliable if stdin happens to equal stdout.
20615         Invoke __fsetlocking on tty.
20616         Handle thread cancellation if needed.
20617         Namespace cleanup (use __tcgetattr, __getline).
20618         Use bool for Booleans.
20619         [USE_IN_LIBIO]: Handle wide streams.
20620         [!_LIBC]: Unconditionally do the fseek, since we don't know what
20621         stream might go where.
20622
20623         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
20624         doesn't have to include <stdio.h> before us.
20625         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
20626         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
20627         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
20628         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
20629         if not declared, so that we can use getpass.c code from libc without
20630         rewriting it.
20631         (flockfile, ftrylockfile, funlockfile): New macros.
20632
20633 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20634
20635         * modules/getpass: Depend on stdbool.
20636
20637 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20638
20639         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
20640
20641 2003-10-07  Karl Berry  <karl@gnu.org>
20642
20643         * config/config.{guess,sub}: update from config.
20644
20645 2003-10-06  Jim Meyering  <jim@meyering.net>
20646             Bruno Haible  <bruno@clisp.org>
20647
20648         This lets translators provide better translations for the
20649         "Written by ..." part of --version output.
20650         * lib/version-etc.h: Include stdarg.h.
20651         (version_etc_copyright): Declare as readonly.
20652         (version_etc): Make this function variadic with a NULL-terminated list
20653         of author name strings.
20654         (version_etc_va): New declaration.
20655         * lib/version-etc.c: Include stdarg.h, stdlib.h.
20656         (version_etc_copyright): Declare as readonly.
20657         (version_etc_va): New function. Provide a different translatable string
20658         for each possible number of authors < 10. Abbreviate when there are 10
20659         authors or more.
20660         (version_etc): Make this function variadic. Call version_etc_va.
20661         Suggestion from Gary V. Vaughan.
20662
20663         * lib/long-options.h (parse_long_options): Change prototype: the
20664         authors string is moved to the end and becomes variadic.
20665         * lib/long-options.c: Include stdarg.h.
20666         (parse_long_options): Make this function variadic, too.
20667         Call version_etc_va, not version_etc.
20668
20669 2003-10-06  Bruno Haible  <bruno@clisp.org>
20670
20671         * modules/version-etc-2: Remove file.
20672         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
20673
20674 2003-10-06  Bruno Haible  <bruno@clisp.org>
20675
20676         * modules/fatal-signal: New file.
20677         * MODULES.html.sh (func_all_modules): Add fatal-signal.
20678
20679 2003-10-06  Bruno Haible  <bruno@clisp.org>
20680
20681         * m4/fatal-signal.m4: New file.
20682         * m4/signalblocking.m4: New file, from GNU gettext.
20683
20684 2003-10-06  Bruno Haible  <bruno@clisp.org>
20685
20686         * lib/version-etc-2.h: Remove file.
20687         * lib/version-etc-2.c: Remove file.
20688
20689 2003-10-06  Bruno Haible  <bruno@clisp.org>
20690
20691         * lib/fatal-signal.h: New file, from GNU gettext.
20692         * lib/fatal-signal.c: New file, from GNU gettext.
20693
20694 2003-10-05  Paul Eggert  <eggert@twinsun.com>
20695
20696         * README: Rework advice for preventing empty .o files.
20697         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
20698         not <sys/types.h>.
20699
20700 2003-10-04  Karl Berry  <karl@gnu.org>
20701
20702         * lib/argp*: update from libc.
20703
20704 2003-10-04  Karl Berry  <karl@gnu.org>
20705
20706         * config/config.{guess,sub}: update from config.
20707
20708 2003-10-02  Bruno Haible  <bruno@clisp.org>
20709
20710         * modules/lchown (Include): Add lchown.h.
20711         * modules/time_r (Include): Use "..." syntax.
20712         * modules/xgetdomainname (Include): Add xgetdomainname.h.
20713
20714 2003-10-01  Simon Josefsson  <jas@extundo.com>
20715
20716         * MODULES.html.sh (func_all_modules): Move gethostname from section
20717         'based on' to section 'lacking' POSIX:2001.
20718
20719 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
20720
20721         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
20722         to output mode on the same stream.
20723
20724 2003-09-29  Paul Eggert  <eggert@twinsun.com>
20725
20726         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
20727         Fix arg typo in previous patch.
20728
20729 2003-09-28  Jim Meyering  <jim@meyering.net>
20730
20731         * lib/error.c: Correct cpp indentation.
20732
20733 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20734
20735         * modules/free: New file.
20736
20737 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20738
20739         * m4/free.m4: New file.
20740
20741 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20742
20743         * lib/minmax.h (MIN, MAX)
20744         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
20745         Omit the special code that used __typeof__, since we worry that
20746         it could be more trouble than it's worth.  See:
20747         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
20748         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
20749
20750         * lib/free.c: New file.
20751
20752 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
20753
20754         Trivial fixes to Makefile.am parts of module listings.
20755         * modules/strstr: Append strstr.h to lib_SOURCES.
20756         * modules/strcase: Likewise, for strcase.h.
20757
20758 2003-09-27  Karl Berry  <karl@gnu.org>
20759
20760         * config/mkinstalldirs: update from automake.
20761
20762 2003-09-26  Paul Eggert  <eggert@twinsun.com>
20763
20764         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
20765         (error_tail): Do not loop, reallocating temporary buffer, since
20766         the output cannot contain more wide characters than the input
20767         contains bytes, the size must be big enough already.  This avoids
20768         one potential size overflow calculation.  Check for size overflow
20769         when calculating temporary buffer size.  Free temporary buffer
20770         when done, if it was allocated with malloc; this plugs a memory
20771         leak.  Remove casts from void * to pointers, that are no longer
20772         needed now that we're assuming C89 or better.
20773
20774         Merge error changes from glibc.
20775
20776         * lib/error.c, error.h: Update copyright notice header to match glibc.
20777         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
20778         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
20779         Disable cancellation while printing error.
20780         * lib/error.h: Prepend __ to parameter names.
20781
20782 2003-09-26  Jim Meyering  <jim@meyering.net>
20783
20784         * lib/error.c (error_tail): Move some declarations
20785         into inner scope where the local variables are used.
20786
20787 2003-09-26  Bruno Haible  <bruno@clisp.org>
20788
20789         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
20790         stpncpy().
20791         Don't define stpncpy through config.h; it's now done through stpncpy.h.
20792
20793 2003-09-26  Bruno Haible  <bruno@clisp.org>
20794
20795         * lib/stpncpy.h (gnu_stpncpy): New declaration.
20796         (stpncpy): Define as alias for gnu_stpncpy.
20797         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
20798
20799 2003-09-25  Simon Josefsson  <jas@extundo.com>
20800
20801         * lib/xgetdomainname.h: New file.
20802         * lib/xgetdomainname.c: New file.
20803
20804 2003-09-25  Simon Josefsson  <jas@extundo.com>
20805             Bruno Haible  <bruno@clisp.org>
20806
20807         * modules/getdomainname: New file.
20808         * modules/xgetdomainname: New file.
20809         * MODULES.html.sh (func_all_modules): Add getdomainname,
20810         xgetdomainname.
20811
20812 2003-09-25  Simon Josefsson  <jas@extundo.com>
20813             Bruno Haible  <bruno@clisp.org>
20814
20815         * m4/getdomainname.m4: New file.
20816
20817 2003-09-25  Simon Josefsson  <jas@extundo.com>
20818             Bruno Haible  <bruno@clisp.org>
20819
20820         * lib/getdomainname.h: New file.
20821         * lib/getdomainname.c: New file.
20822
20823 2003-09-25  Karl Berry  <karl@gnu.org>
20824
20825         * lib/argp-fmtstream.c, argp-help.c: update from libc.
20826
20827 2003-09-25  Karl Berry  <karl@gnu.org>
20828
20829         * config/install-sh: update from automake.
20830
20831 2003-09-25  Bruno Haible  <bruno@clisp.org>
20832
20833         * modules/version-etc-2: New file, from modules/version-etc with
20834         modifications.
20835         * MODULES.html.sh (func_all_modules): Add version-etc-2.
20836
20837 2003-09-25  Bruno Haible  <bruno@clisp.org>
20838
20839         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
20840         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
20841
20842 2003-09-24  Simon Josefsson  <jas@extundo.com>
20843
20844         * modules/xgethostname: Add xgethostname.h.
20845
20846 2003-09-24  Paul Eggert  <eggert@twinsun.com>
20847
20848         * lib/linebuffer.c (freebuffer): Don't free the argument, just
20849         the buffer associated with the argument.  Bug reported by
20850         Simon Josefsson.
20851
20852 2003-09-24  Paul Eggert  <eggert@twinsun.com>
20853
20854         * README: Document assumptions that 'int' is at least 32 bits
20855         wide, that integer arithmetic is 2's complement without overflow,
20856         that there are no holes in integer values, that adding sizes of
20857         two nonoverlapping objects can't overflow, and that all-bits-zero
20858         yields scalar zero.  Fix spelling and capitalization typos.
20859
20860 2003-09-19  Karl Berry  <karl@gnu.org>
20861
20862         * lib/argp.h: update from libc.
20863
20864 2003-09-17  Paul Eggert  <eggert@twinsun.com>
20865
20866         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
20867         to avoid spurious warnings like "AC_RUN_IFELSE was called before
20868         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
20869
20870 2003-09-17  Paul Eggert  <eggert@twinsun.com>
20871
20872         * gnulib-tool: Use "test -h", not "test -L", for portability
20873         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
20874         (tags_regexp): Remove, since \| doesn't conform to POSIX.
20875         (sed_extract_prog): Issue s commands one-by-one, rather than
20876         using \| in one s command.
20877
20878 2003-09-16  Paul Eggert  <eggert@twinsun.com>
20879
20880         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
20881         input error, instead of returning NULL the next time we are called
20882         (and therefore losing track of errno).
20883
20884 2003-09-16  Bruno Haible  <bruno@clisp.org>
20885
20886         * gnulib-tool (func_create_testdir): Warn about duplicated
20887         dependencies.
20888
20889 2003-09-15  Paul Eggert  <eggert@twinsun.com>
20890
20891         * modules/argmatch, modules/fatal, modules/obstack,
20892         modules/xalloc, modules/xgethostname: Sort dependencies by
20893         importance, not alphabetically.
20894
20895 2003-09-15  Paul Eggert  <eggert@twinsun.com>
20896
20897         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
20898         fails, so that the caller gets the proper errno.
20899
20900         * lib/readutmp.c (read_utmp): Likewise.
20901         Check for fstat error.  Close stream and free storage
20902         when failing.
20903
20904 2003-09-14  Karl Berry  <karl@gnu.org>
20905
20906         * config/srclist.txt (strdup.c): disable for c89 changes.
20907
20908 2003-09-14  Jim Meyering  <jim@meyering.net>
20909
20910         * lib/getloadavg.c: Correct cpp indentation.
20911         * lib/strdup.c: Likewise.
20912         * lib/vasnprintf.c: Likewise.
20913
20914 2003-09-14  Bruno Haible  <bruno@clisp.org>
20915
20916         * modules/fwriteerror: New file.
20917         * MODULES.html.sh (func_all_modules): Add fwriteerror.
20918
20919 2003-09-14  Bruno Haible  <bruno@clisp.org>
20920
20921         * lib/fwriteerror.h: New file.
20922         * lib/fwriteerror.c: New file.
20923
20924 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20925
20926         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
20927         modules/xgethostname, modules/xalloc: Depend on exit.
20928
20929 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20930
20931         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
20932
20933         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
20934         and AC_MINIX, too, so that their extensions are available.
20935
20936         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
20937         This macro has been superseded by gl_BACKUPFILE.
20938
20939         More patches to assume C89 or better.
20940
20941         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
20942
20943         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
20944         unconditionally.
20945         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
20946         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
20947         Include <string.h>, <stdlib.h> unconditionally.
20948         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
20949         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
20950         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
20951         headers or for string.h.
20952         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
20953         or strtoul.
20954
20955         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
20956         headers.
20957         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
20958         * m4/userspec.m4 (gl_USERSPEC): Likewise.
20959         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
20960         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
20961         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
20962         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
20963         memcpy, memset.
20964         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
20965         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
20966         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
20967         strtol.
20968         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
20969         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
20970         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
20971         strtoul.
20972
20973 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20974
20975         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
20976         * lib/obstack.c [!defined _LIBC]: Likewise.
20977         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
20978         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
20979         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
20980
20981         More changes to assume C89 or better.
20982
20983         * lib/error.c (error_tail): Assume vprintf.
20984
20985         * lib/argmatch.c (getenv): Remove decl.
20986         * lib/progreloc.c (get_full_program_name): Define via prototype.
20987         * lib/setenv.c (clearenv): Likewise.
20988         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
20989         needed.
20990         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
20991         (malloc, memcpy): Remove decls.
20992         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
20993         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
20994         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
20995         (memcpy): Remove macro.
20996         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
20997         (__P): Remove.  All uses removed.
20998         (PTR): Remove.  All uses changed to void *.
20999         (CHAR_BIT, NULL): Remove.
21000         (spaces, zeros, memset_space, memset_zero)
21001         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
21002         Remove.
21003         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
21004         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
21005         Define with prototype.
21006         Remove now-unnecessary prototype decl.
21007         (extra_args_spec): Assume ANSI C.  All uses changed.
21008         (extra_args_spec_iso): Remove.
21009         (my_strftime, emacs_strftimeu): Define via prototype.
21010         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
21011         unconditionally.
21012         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
21013         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
21014         (strtoul, strtol): Remove decls.
21015         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
21016         LONG_MAX): Remove.
21017         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
21018         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
21019         (LOCALE_PARAM_PROTO): New macro.
21020         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
21021         (INTERNAL (strtol), strtol): Define with a prototype.
21022         (PARAMS): Remove.  All uses removed.
21023         * lib/tempname.c: Include <string.h> unconditionally.
21024         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
21025         * lib/xgethostname.c (main): Define with a prototype.
21026         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
21027         Include <stdlib.h> unconditionally.
21028         (calloc, malloc, realloc, free): Remove decls.
21029         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
21030         Include <stdlib.h> unconditionally.  Sort include file names.
21031         (strtod): Remove.
21032         (xstrtod): Define with a prototype.
21033         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
21034         (strtol, strtoul): Remove decls.
21035
21036 2003-09-11  Paul Eggert  <eggert@twinsun.com>
21037
21038         More patches to assume C89 or better.
21039         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
21040         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
21041         string.h, memchr, STDC_HEADERS.
21042
21043 2003-09-11  Paul Eggert  <eggert@twinsun.com>
21044
21045         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
21046         Include <stdlib.h>, <string.h> unconditionally.
21047         Remove now-unnecessary cast to char *.
21048         * lib/strnlen.c: Include <string.h> unconditionally.
21049         * lib/yesno.c (yesno): Define with a prototype.
21050
21051 2003-09-11  Bruno Haible  <bruno@clisp.org>
21052
21053         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
21054
21055 2003-09-10  Jim Meyering  <jim@meyering.net>
21056
21057         * lib/error.c: Correct indentation of cpp directives.
21058
21059 2003-09-10  Bruno Haible  <bruno@clisp.org>
21060
21061         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
21062         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
21063         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
21064         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
21065         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
21066         <stdlib.h> and <string.h> checks.
21067         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
21068         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
21069
21070 2003-09-10  Bruno Haible  <bruno@clisp.org>
21071
21072         * lib/strcspn.c: Include <string.h> unconditionally.
21073         * lib/strpbrk.c: Include <string.h> unconditionally.
21074         * lib/strstr.c: Include <string.h> unconditionally.
21075         * lib/unicodeio.c: Include <string.h> unconditionally.
21076         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
21077         * lib/unsetenv.c: Likewise.
21078         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
21079         * lib/yesno.c: Include <stdlib.h> unconditionally.
21080         (rpmatch): Add prototype.
21081
21082 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21083
21084         More patches to assume C89 or better.
21085         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
21086         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
21087         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
21088         or for string.h.
21089         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
21090         stdlib.h.
21091         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
21092         C headers.
21093         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
21094         string.h.
21095         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
21096         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
21097         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
21098         or for string.h.
21099         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
21100         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
21101         C headers.
21102         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
21103         memcpy.
21104         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
21105         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
21106         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
21107         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
21108         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
21109         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
21110         string.h, free.
21111         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
21112         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
21113         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
21114         C headers, or for string.h.
21115         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
21116         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
21117         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
21118         headers, memory.h, stdlib.h, string.h, strings.h.
21119         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
21120         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
21121         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
21122         strchr.
21123         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
21124         headers, memory.h, string.h.
21125         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
21126         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
21127         free.
21128         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
21129         headers.
21130         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
21131         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
21132         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
21133         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
21134         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
21135
21136 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21137
21138         More K&R removal.
21139
21140         * lib/acosl.c (main): Use a prototype.
21141         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
21142         tanl.c: Likewise.
21143
21144         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
21145
21146         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
21147         (getopt, etopt_long, getopt_long_only, _getopt_internal)
21148         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
21149         with a prototype.
21150         * lib/getopt.c (const): Remove macro.
21151         Include <string.h> unconditionally.
21152         (my_index): Remove; all uses changed to strchr.
21153         (strlen): Remove decl.
21154         (exchange): Remove forward decl; no longer needed.
21155         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
21156         Define with prototype.
21157         * lib/getopt1.c (const): Remove macro.
21158         (getopt_long, getopt_long_only, main): Define with prototype.
21159
21160         * lib/getugroups.c: Include <string.h> unconditionally.
21161
21162         * lib/getusershell.c: Include <stdlib.h> unconditionally.
21163         (getusershell, setusershell, endusershell, readname, main):
21164         Define with prototypes.
21165
21166         * lib/group-member.c: Include group-member.h first.
21167         Include <stdlib.h> unconditionally.
21168
21169         * lib/hard-locale.c: Include hard-locale.h first.
21170         Include <stdlib.h>, <string.h> unconditionally.
21171
21172         * lib/hash.c (free, malloc): Remove decls.
21173         Include <stdlib.h> unconditionally.
21174
21175         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
21176         (getenv): Do not declare.
21177
21178         * lib/idcache.c: Include <string.h> unconditionally.
21179
21180         * lib/long-options.c: Include long-options.h first, to test interface.
21181         Include <stdlib.h> unconditionally.
21182
21183         * lib/makepath.c: Include makepath.h first, to test interface.
21184         Include <stdlib.h> and <string.h> unconditionally.
21185
21186         * lib/linebuffer.c: Include <stdlib.h>.
21187         (free): Remove decl.
21188
21189         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
21190         stddef.h. rpl_malloc returns void *, not char *.
21191         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
21192         prototype.
21193
21194         * lib/md5.h: Include <limits.h> unconditionally.
21195         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
21196         (__P): Remove; all uses removed.
21197         * lib/md5.c: Include "md5.h" first.
21198         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
21199         md5_buffer, md5_process_bytes, md5_process_block):
21200         Define with prototypes.
21201         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
21202         * lib/sha.c: Include "sha.h" first.
21203         Include <stdlib.h>, <string.h> unconditionally.
21204
21205         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
21206         * lib/memcmp.c (__ptr_t): Likewise.
21207         * lib/memrchr.c (__ptr_t): Likewise.
21208         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
21209         Include <string.h> unconditionally.
21210         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
21211         * lib/memchr.c: Include <stdlib.h> unconditionally.
21212         * lib/memchr.c (LONG_MAX): Remove.
21213         * lib/memrchr.c (LONG_MAX): Likewise.
21214         * lib/memchr.c (__memchr): Define via a prototype.
21215         * lib/memrchr.c (__memrchr): Likewise.
21216         * lib/memcmp.c (__P): Remove, and remove all uses.
21217         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
21218         Remove forward decls; no longer needed.
21219         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
21220         Use types required by C89 in prototype.
21221
21222         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
21223         * lib/savedir.c: Likewise.
21224         * lib/mkdir.c (free): Remove decl.
21225         * lib/rmdir.c (rmdir): Define with a prototype.
21226         * lib/savedir.c: Include savedir.h first, to test interface.
21227
21228         * lib/mktime.c (STDC_HEADERS): Remove.
21229         Include <stdlib.h>, <string.h> unconditionally.
21230
21231         * lib/modechange.c: Include <stdlib.h> unconditionally.
21232         (malloc): Remove decl.
21233
21234         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
21235         (free): Remove decl.
21236
21237         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
21238         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
21239         (This type really should be intptr_t, but that's a C99ism.)
21240         (_obstack_memcpy): Remove: all uses changed to memcpy.
21241         Include <string.h> unconditionally.
21242         (struct obstack): Assume __STDC__ for types of members
21243         chunkfun, freefun, extra_arg.
21244         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
21245         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
21246         obstack_begin, obstack_specify_allocation,
21247         obstack_specify_allocation_with_arg, obstack_chunkfun,
21248         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
21249         Remove unprototyped decls and the macros that use them.
21250         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
21251         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
21252         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
21253         (defined __STDC__ && __STDC__)]:
21254         Remove nonprototyped code.
21255         Include <stdlib.h> unconditionally.
21256         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
21257         _obstack_allocated_p, _obstack_free, obstack_free,
21258         _obstack_memory_used, print_and_abort):
21259         Define using prototypes.
21260         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
21261         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
21262         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
21263         obstack_next_free, obstack_object_size, obstack_room) [0]:
21264         Remove unused, unprototyped code.
21265
21266         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
21267
21268         * lib/physmem.c (physmem_total, physmem_available, main): Define
21269         with prototypes.
21270
21271         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
21272         (main): Define with a prototype.
21273
21274         * lib/posixver.c (getenv): Remove decl.
21275
21276         * lib/putenv.c (malloc): Returns void *, not char *.
21277         Include <string.h> unconditionally.
21278         (strchr, memcpy, NULL): Do not define.
21279
21280         * lib/readtokens.c: Include readtokens.h first, to test interface.
21281         Include <stdlib.h>, <string.h> unconditionally.
21282         (init_tokenbuffer): Define with a prototype.
21283
21284         * lib/regex.c (PARAMS): Remove.  All uses removed.
21285         All uses of _RE_ARGS removed, too.
21286         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
21287         unconditionally.
21288         (bzero): Assume memset exists.
21289         (memcmp, memcpy, NULL): Remove.
21290         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
21291         char, or assignments to local vars of type signed char.
21292         (init_syntax_once, PREFIX(extract_number_and_incr),
21293         PREFIX(print_partial_compiled_pattern),
21294         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
21295         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
21296         PREFIX(regex_grow_registers), PREFIX(regex_compile),
21297         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
21298         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
21299         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
21300         wcs_compile_range, byte_compile_range, truncate_wchar,
21301         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
21302         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
21303         count_mbs_length, wcs_re_match_2_internal,
21304         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
21305         PREFIX(alt_match_null_string_p),
21306         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
21307         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
21308         regfree, PREFIX(extract_number)): Define with prototype.  Remove
21309         now-unnecessary declaration, if any.
21310         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
21311         regcomp, regexec):
21312         Remove now-unnecessary casts among pointer types.
21313         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
21314
21315         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
21316         (free): Remove decl.
21317
21318         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
21319
21320         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
21321         (free): Remove decl.
21322
21323         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
21324         * lib/xgetcwd.c: Likewise.
21325
21326         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
21327         (free): Remove decl.
21328
21329         * lib/strchrnul.c (strchrnul): Define with a prototype.
21330         Fix bug: c_in was not converted to char before searching.
21331
21332         The following changes are not K&R related:
21333
21334         * lib/group-member.h: Include <sys/types.h>, so that this file is
21335         self-contained.
21336         * lib/makepath.h: Likewise.
21337
21338         * lib/getusershell.c (readname, default_index, line_size, readname):
21339         Use size_t, not int, for sizes.
21340         (readname): If the size overflows, report an error instead of
21341         looping forever.
21342
21343 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21344
21345         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
21346         libc.
21347
21348 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21349
21350         * README: New section: portability guidelines.
21351
21352 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
21353
21354         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
21355         C89 spec.
21356
21357 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
21358
21359         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
21360
21361 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21362
21363         Assume C89 or better; remove K&R cruft.
21364         A few of these changes were first proposed by Derek Robert Price
21365         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
21366
21367         * lib/addext.c: Include <string.h> unconditionally.
21368         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
21369         Don't declare getenv or malloc.
21370
21371         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
21372         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
21373         (NULL): Remove.
21374         (find_stack_direction, alloca): Use prototypes.
21375
21376         * lib/atexit.c (atexit): Define using a prototype.
21377
21378         * lib/basename.c, dirname.c, stripslash.c:
21379         Include <string.h> unconditionally.
21380
21381         * lib/bcopy.c: Include <stddef.h>.
21382         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
21383
21384         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
21385
21386         * lib/error.h (error, error_at_line, error_print_progname)
21387         [! (defined (__STDC__) && __STDC__)]: Remove decls.
21388         * lib/error.c: Include error.h first, to check interface.
21389         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
21390         (VA_START): Remove; all uses changeed to va_start.
21391         (exit, strerror): Remove decls.
21392         (error_print_progname): Prototype uncondionally.
21393         Don't include <errno.h>; no longer needed.
21394         (private_strerror): Remove.
21395         (error_tail): Always define.
21396         (error, error_at_line): Assume C89 or better; always use prototypes.
21397         * lib/fatal.c: Include "fatal.h" first, to test interface.
21398         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
21399         (VA_START): Remove; all uses changed to va_start.
21400         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
21401         this case.
21402         (exit): Remove decl.
21403         (fatal): Prototype unconditionally.  Assume va_start works.
21404         Abort at end, to pacify gcc.
21405
21406         * lib/euidaccess.c (main): Define with a prototype.
21407
21408         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
21409
21410         * lib/exitfail.c: Include <stdlib.h> unconditionally.
21411
21412         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
21413         prototypes.
21414         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
21415         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
21416         (getenv): Remove decl.
21417         (fnmatch): Define using a prototype.
21418         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
21419         (FCT): Define using a prototype.
21420
21421         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
21422
21423         * lib/gethostname.c: Include <stddef.h>.
21424         (gethostname): Define with prototype.  Length is size_t, not int.
21425
21426 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21427
21428         Assume C89 or better; remove K&R cruft.
21429         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
21430         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
21431         string.h, getenv, malloc.
21432         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
21433         headers.
21434         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
21435         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
21436         do not check for strerror.
21437         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
21438         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
21439         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
21440         do not check for doprnt or vprintf.
21441         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
21442         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
21443
21444 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21445
21446         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
21447         getversion.c should have been removed then, but was accidentally
21448         preserved.
21449
21450         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
21451         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
21452
21453 2003-09-08  Karl Berry  <karl@gnu.org>
21454
21455         * config/config.sub, config.guess, srclistvars.sh: update from savannah
21456                 config, forget about prep.
21457
21458         * config/depcomp, missing: update from automake.
21459
21460 2003-09-07  Paul Eggert  <eggert@twinsun.com>
21461
21462         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
21463         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
21464
21465 2003-09-07  Paul Eggert  <eggert@twinsun.com>
21466
21467         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
21468         copy_tm_result.  Bug reported by Simon Josefsson in
21469         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
21470
21471 2003-09-06  Paul Eggert  <eggert@twinsun.com>
21472
21473         * m4/time_r.m4: New file.
21474         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
21475         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
21476         is. Check for timegm declaration.
21477         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
21478         Do not check for gmtime_r.
21479         Replace mktime if __mktime_internal does not exist and if mktime
21480         hasn't been replaced already.
21481
21482 2003-09-06  Paul Eggert  <eggert@twinsun.com>
21483
21484         * lib/time_r.c, lib/time_r.h: New files.
21485
21486         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
21487         __localtime_r.
21488         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
21489         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
21490
21491         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
21492         __gmtime_r.
21493         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
21494         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
21495         Include <time_r.h>.
21496
21497         * lib/timegm.c: Switch to glibc implementation, with the following
21498         changes:
21499         [defined HAVE_CONFIG_H]: Include <config.h>.
21500         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
21501         (__mktime_internal) [!defined _LIBC]: New decl.
21502         (__gmtime_r) [!defined _LIBC]: New macro and function.
21503         (timegm): Use a prototype, since gnulib assumes C89.
21504         Do not bother declaring tmp to be const, as it's not really usefu.
21505         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
21506         (timegm): Declare only if HAVE_DECL_TIMEGM.
21507
21508 2003-09-06  Paul Eggert  <eggert@twinsun.com>
21509
21510         * MODULES.html.sh (func_all_modules): Add time_r.
21511         * modules/time_r: New file.
21512         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
21513         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
21514
21515 2003-09-03  Paul Eggert  <eggert@twinsun.com>
21516
21517         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
21518         Bug reported by Lute Kamstra in
21519         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
21520
21521         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
21522         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
21523         course with correspondingly smaller numbers for tomorrow and
21524         yesterday.  From Tadayoshi Funaba.  Originally installed into
21525         sh-utils on 1999-08-07, but the patch got lost (I guess during the
21526         coreutils merge?).
21527
21528 2003-08-31  Simon Josefsson  <jas@extundo.com>
21529
21530         * modules/timegm: New file.
21531         * MODULES.html.sh (func_all_modules): Add timegm.
21532
21533 2003-08-31  Simon Josefsson  <jas@extundo.com>
21534
21535         * m4/timegm.m4: New file.
21536
21537 2003-08-31  Simon Josefsson  <jas@extundo.com>
21538
21539         * lib/timegm.h: New file.
21540         * lib/timegm.c: New file.  Based on
21541         wget-1.8.2/src/http.c:mktime_from_utc.
21542
21543 2003-08-31  Karl Berry  <karl@gnu.org>
21544
21545         * lib/argp.h: update from libc.
21546
21547 2003-08-28  Bruno Haible  <bruno@clisp.org>
21548
21549         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
21550         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
21551         followed by '#define fnmatch fnmatch_posix' gives an error.
21552
21553 2003-08-28  Bruno Haible  <bruno@clisp.org>
21554
21555         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
21556         warning on QNX, which defines O_BINARY to 000000.
21557
21558 2003-08-27  Jim Meyering  <jim@meyering.net>
21559
21560         * m4/mkstemp.m4: Require that the system mkstemp be able to create
21561         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
21562         would fail after 32.  Reported by Danny Levinson.  Details here:
21563         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
21564
21565 2003-08-24  Bruno Haible  <bruno@clisp.org>
21566
21567         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
21568         MSVC7 <stdio.h> is included later.
21569
21570 2003-08-22  Simon Josefsson  <jas@extundo.com>
21571
21572         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
21573
21574 2003-08-20  Karl Berry  <karl@gnu.org>
21575
21576         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
21577
21578 2003-08-20  Bruno Haible  <bruno@clisp.org>
21579
21580         * modules/progname: New file.
21581         * MODULES.html.sh (func_all_modules): Add progname.
21582
21583 2003-08-20  Bruno Haible  <bruno@clisp.org>
21584
21585         * lib/progname.h: New file, from GNU gettext.
21586         * lib/progname.c: New file, from GNU gettext.
21587         * lib/progreloc.c: New file, from GNU gettext.
21588
21589 2003-08-19  Jim Meyering  <jim@meyering.net>
21590
21591         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
21592         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
21593
21594 2003-08-19  Bruno Haible  <bruno@clisp.org>
21595
21596         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
21597         more.
21598
21599 2003-08-19  Bruno Haible  <bruno@clisp.org>
21600
21601         * lib/xstrdup.c: Assume <string.h> exists.
21602
21603 2003-08-18  Paul Eggert  <eggert@twinsun.com>
21604
21605         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
21606         in makefile rules.
21607
21608 2003-08-18  Jim Meyering  <jim@meyering.net>
21609
21610         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
21611         * m4/lib-ld.m4: Likewise.
21612
21613 2003-08-18  Jim Meyering  <jim@meyering.net>
21614
21615         * lib/setenv.h: Indent nested cpp directive.
21616         * lib/vasnprintf.c: Remove trailing blanks.
21617
21618 2003-08-17  Simon Josefsson  <jas@extundo.com>
21619
21620         * modules/xstrndup: New file.
21621         * MODULES.html.sh (func_all_modules): Add xstrndup.
21622
21623 2003-08-17  Simon Josefsson  <jas@extundo.com>
21624
21625         * modules/argp: Fix autoconf macro name. Add more dependencies.
21626
21627 2003-08-17  Simon Josefsson  <jas@extundo.com>
21628
21629         * m4/xstrndup.m4: New file.
21630
21631 2003-08-17  Simon Josefsson  <jas@extundo.com>
21632
21633         * m4/argp.m4: New file.
21634
21635 2003-08-17  Simon Josefsson  <jas@extundo.com>
21636             Bruno Haible  <bruno@clisp.org>
21637
21638         * lib/xstrndup.h: New file.
21639         * lib/xstrndup.c: New file.
21640
21641 2003-08-17  Bruno Haible  <bruno@clisp.org>
21642
21643         * modules/strndup (Files, Include): Add lib/strndup.h.
21644
21645 2003-08-17  Bruno Haible  <bruno@clisp.org>
21646
21647         * modules/euidaccess (Files): Add lib/euidaccess.h.
21648
21649 2003-08-17  Bruno Haible  <bruno@clisp.org>
21650
21651         * lib/strndup.h: New file.
21652
21653 2003-08-17  Bruno Haible  <bruno@clisp.org>
21654
21655         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
21656         like AC_GNU_SOURCE.
21657         * modules/extensions (configure.ac): Comment out the invocation of
21658         gl_USE_SYSTEM_EXTENSIONS.
21659
21660 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21661
21662         Merges from coreutils, etc.
21663         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
21664         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
21665         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
21666         fixing a typo.
21667         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
21668         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
21669
21670 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21671
21672         Document merge from coreutils.
21673         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
21674         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
21675         * modules/utime: Add m4/utimes-null.m4.
21676
21677 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21678
21679         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
21680         space, undoing this 2003-08-12 change:
21681         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
21682
21683 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21684
21685         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
21686         strtoul.c from libc, undoing this 2003-08-12 change:
21687         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
21688
21689 2003-08-16  Jim Meyering  <jim@meyering.net>
21690
21691         Merges from coreutils.
21692         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
21693         prefix.  Adjust cache variables similarly.  Create 500 rather than
21694         just 300 files, to exercise bug on Darwin6.5, too.
21695         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
21696         $missing_dir.
21697         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
21698         AM_SYS_POSIX_TERMIOS.
21699         Reported by mkc@mathdogs.com.
21700         Also change use of $am_cv_sys_posix_termios
21701         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
21702         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
21703         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
21704         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
21705         in /proc/mounts until it finds one with matching device number.  This
21706         is unnecessary when the FILE argument *is* a mount point.  No stat call
21707         is necessary in that case.  So, disable the statvfs-testing code on
21708         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
21709         as RedHat bug# 84846.
21710         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
21711         to 1MB, so as not to render systems with no stack size limit (e.g.,
21712         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
21713         Include <unistd.h>.  On some systems,
21714         it is required for the definition of _SC_PAGESIZE.
21715
21716 2003-08-16  Jim Meyering  <jim@meyering.net>
21717
21718         Merge from coreutils.
21719         * lib/xstrtoimax.c: #else #if -> #elif.
21720         * lib/xstrtoumax.c: Likewise.
21721
21722 2003-08-16  Jim Meyering  <jim@meyering.net>
21723
21724         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
21725         * m4/utimes.m4: Removed.
21726         * m4/utimes-null.m4: Renamed from utimes.m4.
21727
21728         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
21729         to 1MB, so as not to render systems with no stack size limit (e.g.,
21730         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
21731         Include <unistd.h>.  On some systems,
21732         it is required for the definition of _SC_PAGESIZE.
21733
21734 2003-08-16  Jim Meyering  <jim@meyering.net>
21735         and Paul Eggert  <eggert@cs.ucla.edu>
21736
21737         Merges from coreutils, etc.
21738
21739         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
21740         using the latest version from cvs.  This avoids problems with #line
21741         directives using a vendor (Sun) compiler.
21742         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
21743         Don't set GETGROUPS_LIB here; now it's
21744         done via getgroups.m4's wrapper function.
21745         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
21746         rather than just in sh-util/configure.in, so that the
21747         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
21748         same.
21749         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
21750         AC_FUNC_GETLOADAVG where to find getloadavg.c.
21751         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
21752         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
21753         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
21754         Remove code that is now done by the newly-required macros.
21755         Append $(EXEEXT) to DF_PROG.
21756         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
21757         Do not invoke or require the following here,
21758         since prereq.m4 or some gnulib .m4 now does this for us:
21759         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
21760         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
21761         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
21762         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
21763         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
21764         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
21765         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
21766         AC_FUNC_OBSTACK.
21767         Do not replace the following functions, as this is now the job
21768         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
21769         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
21770         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
21771         atexit getpass, strdup, getpagesize.
21772         Replace 'raise'.
21773         Do not check for the following functions, as this is now the job
21774         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
21775         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
21776         setregid.
21777         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
21778         Check for sys/sysctl.h.
21779         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
21780         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
21781         of checking for ssize_t ourselves.
21782
21783         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
21784         Require every macro that gnulib/modules/* suggests for us.
21785         (jm_PREREQ_ADDEXT): New macro.
21786         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
21787         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
21788
21789         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
21790         (gl_PHYSMEM): Use it.
21791         Also check for `table' function.
21792         Check for new headers and functions.
21793         Add check for sys/sysmp.h.
21794         With suggestions from Kaveh Ghazi.
21795         Ignore headers that are present but cannot be compiled.  This
21796         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
21797         C 5.4.
21798
21799 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21800
21801         Document merge from coreutils.
21802         * modules/userspec: Depend on posixver.
21803         * modules/strftime: Depend on tzset.
21804
21805 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21806
21807         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
21808         rather than tab, after '#' in shell-script copyright notices.
21809         Suggested by Bruno Haible.
21810
21811 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21812
21813         * config/srclist-update: Use three spaces, rather than tab, after '#'
21814         in shell-script copyright notices.  Suggested by Bruno Haible.
21815         Remove unnecessary parenthesization in regular expression.
21816
21817 2003-08-15  Jim Meyering  <jim@meyering.net>
21818
21819         Merge from coreutils.
21820         * lib/xgethostname.c: Include <stdlib.h>.
21821         (xghostname): Don't exit for anything other than memory-related
21822         failure; just return NULL.
21823         * lib/userspec.c: Include "posixver.h".
21824         (parse_user_spec): Accept `.' as a separator only
21825         in pre-POSIX-200112 mode.
21826         * lib/strtoimax.c: Use #elif rather than #else #if.
21827         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
21828         Remove function, now that we can rely on a working tzset function.
21829         [!_LIBC]: Ensure that the required autoconf test has been run.
21830         [!defined _NL_CURRENT && HAVE_STRFTIME]:
21831         Use underlying_strftime for %r.
21832         * lib/sha.c: Merge in some clean-up and optimization changes from
21833         glibc.
21834         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
21835         Ensure that it is a multiple of 64.
21836         Rearrange loop exit tests so as to avoid performing an
21837         additional fread after encountering an error or EOF.
21838         * lib/realloc.c: Update copyright date.
21839
21840 2003-08-15  Jim Meyering  <jim@meyering.net>
21841         and Paul Eggert  <eggert@twinsun.com>
21842
21843         Merge from coreutils.
21844         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
21845         member but strut utmpx does not.  Needed for AIX 4.3.3.
21846         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
21847
21848 2003-08-15  Jim Meyering  <jim@meyering.net>
21849         and Paul Eggert  <eggert@cs.ucla.edu>
21850
21851         Merges from coreutils, etc.
21852         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
21853         Require gl_FUNC_TZSET_CLOBBER.
21854         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
21855         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
21856         members.
21857
21858 2003-08-14  Paul Eggert  <eggert@twinsun.com>
21859
21860         Help the merge from coreutils.
21861         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
21862         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
21863         * m4/tzset.m4: Use it too.
21864
21865 2003-08-14  Paul Eggert  <eggert@twinsun.com>
21866
21867         * modules/tzset: New file.
21868
21869 2003-08-14  Jim Meyering  <jim@meyering.net>
21870
21871         Merges from coreutils.
21872         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
21873         variable names, rather than @FNMATCH_H@.
21874         * modules/alloca: Likewise for $(ALLOCA_H).
21875
21876         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
21877         the three copies of the literal target, `fnmatch.h'.
21878         * modules/alloca (alloca.h): Likewise.
21879
21880 2003-08-14  Jim Meyering  <jim@meyering.net>
21881
21882         Merge from coreutils.
21883         * m4/tzset.m4: New file.
21884         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
21885         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
21886         otherwise, AIX 5.1 systems would end up using the latter.
21887         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
21888         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
21889         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
21890         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
21891
21892 2003-08-14  Jim Meyering  <jim@meyering.net>
21893
21894         Merge from coreutils.
21895         * lib/obstack.h: Whitespace changes.
21896         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
21897         and xcalloc return values.
21898         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
21899         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
21900         hang on OSF/1 5.1 for DIR on both local and remote file systems.
21901         Reported by (and fix confirmed by) Nelson H. F. Beebe.
21902         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
21903         error from mntctl.
21904         Use mntctl's return value to drive the entry-processing loop, since
21905         we can't rely on the value of the vmt_length member in the last
21906         entry.  On some systems doing so could result in exhausting
21907         virtual memory.  Based in part on a patch from Mike Jetzer.
21908
21909 2003-08-14  Jim Meyering  <jim@meyering.net>
21910         and Paul Eggert  <eggert@twinsun.com>
21911
21912         Merges from coreutils, plus other fixes.
21913         * lib/physmem.c: Merge in portability changes from gcc/libiberty
21914         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
21915         for credits and details.  Thanks to Kaveh Ghazi for helping
21916         to keep these files in sync.
21917         (ARRAY_SIZE): Define it.
21918         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
21919         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
21920         (memcasecmp): Don't assume size_t fits in unsigned int.
21921         Remove casts and duplicate code.
21922         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
21923         (memcpy): Remove definition.
21924         Merge in some clean-up and optimization changes from glibc.
21925         [BLOCKSIZE]: Move definition to top of file.
21926         Ensure that it is a multiple of 64.
21927         Rearrange loop exit tests so as to avoid performing an
21928         additional fread after encountering an error or EOF.
21929         * lib/md5.h (md5_uintptr): Define.
21930         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
21931         return to the initial working directory.  Preserve errno
21932         for caller.
21933         * lib/idcache.c: Include "xalloc.h".
21934         (xmalloc, xrealloc): Remove decls.
21935         (getuser): Remove casts no longer required in C89.
21936         * lib/human.c: Include stdio.h, for sprintf.
21937         * lib/group-member.c: Include "xalloc.h".
21938         (xmalloc, xrealloc): Remove decls.
21939         (get_group_info): Remove casts no longer required in C89.
21940         * lib/getusershell.c (readname): Remove casts no longer required in
21941         C89.
21942         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
21943         * lib/getline.c: Whitespace fix, from coreutils.
21944
21945 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21946
21947         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
21948         Check for isascii.
21949
21950         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
21951         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
21952         Undo previous (whitespace-only) change.
21953
21954 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21955
21956         * lib/exclude.c: Include <ctype.h>
21957         (IN_CTYPE_DOMAIN): New macro.
21958         (is_space): New fn.
21959         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
21960         and empty lines.
21961
21962         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
21963         Undo previous (whitespace-only) change.
21964
21965 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21966
21967         * config/srclist-update: Change update back to the old behavior,
21968         leaving whitespace alone.  Use one 'sed' command rather than a
21969         pipeline.
21970         (fixlicense): Now a variable, not a function.
21971         (remove_trailing_blanks): Remove.
21972         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
21973         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
21974         Undo previous (whitespace-only) change.
21975
21976 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21977
21978         Merge from coreutils.
21979         * modules/euidaccess: Add lib_SOURCES, include for new
21980         file euidaccess.h
21981
21982 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21983
21984         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
21985         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
21986         Normalize leading white space and remove trailing white space.
21987
21988         Merge from coreutils
21989         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
21990
21991         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
21992         0.12.1.  These files are now being upgraded automatically by
21993         ../config/srclist-update.
21994
21995 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21996
21997         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
21998         Normalize leading white space and remove trailing white space.
21999         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
22000         notice, as per ../config/srclist-update.
22001
22002         Merge from coreutils.
22003         * lib/euidaccess.h: New file.
22004         * lib/euidaccess.c: Include it.
22005         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
22006         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
22007         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
22008
22009 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22010
22011         * config/srclist-update: Add copyright notice.
22012         (remove_id_lines, remove_trailing_blanks): New constants.
22013         (fixfile): Use them to normalize spacing a bit in copied files.
22014         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
22015         Normalize leading white space and remove trailing white space.
22016
22017         * config/texinfo.tex: Sync with texinfo.
22018
22019         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
22020         strtoul.c from libc, to merge coreutils whitespace changes.
22021
22022         * config/srclist.txt: Get the following m4 files from gettext:
22023         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
22024         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
22025         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
22026         wint_t.m4.
22027
22028 2003-08-12  Karl Berry  <karl@gnu.org>
22029
22030         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
22031         been made.
22032
22033 2003-08-11  Paul Eggert  <eggert@twinsun.com>
22034
22035         * modules/gnu-source, m4/gnu-source.m4:
22036         Remove; we're assuming Autoconf 2.54 or later now.
22037         Suggested by Bruno Haible.
22038         * MODULES.html.sh (func_all_modules): Remove gnu-source.
22039
22040 2003-08-11  Bruno Haible  <bruno@clisp.org>
22041
22042         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
22043
22044 2003-08-11  Bruno Haible  <bruno@clisp.org>
22045
22046         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
22047         (vasnprintf): Use it instead of wcslen.
22048
22049 2003-08-11  Bruno Haible  <bruno@clisp.org>
22050
22051         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
22052         value to ensure that _Bool promotes to int. Use #define for _Bool when
22053         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
22054
22055 2003-08-10  Karl Berry  <karl@gnu.org>
22056
22057         * lib/regex.h: update from libc (whitespace fix).
22058
22059 2003-08-09  Paul Eggert  <eggert@twinsun.com>
22060
22061         Merge some files from coreutils.  These changes were
22062         originally made by Jim Meyering.
22063         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
22064         many older Unixes require this.
22065         * lib/alloca.c (alloca): Remove cast to argument of free;
22066         no longer needed in C89.
22067         * lib/alloca_.h, regex.h: Fix white space to match
22068         what GNU indent does.
22069
22070 2003-08-09  Paul Eggert  <eggert@twinsun.com>
22071
22072         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
22073         apparently Emacs's Unicode mode got confused before my 2003-08-05
22074         checkin.
22075
22076 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22077
22078         * m4/extensions.m4: New file.
22079         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
22080         Require gl_USE_SYSTEM_EXTENSIONS.
22081         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
22082         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
22083
22084 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22085
22086         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
22087         * modules/extensions, modules/gnu-source: New files.
22088         * modules/timespec, modules/unlocked-io: Depend on extensions.
22089
22090 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22091
22092         * modules/restrict: New file.
22093         * MODULES.html.sh (func_all_modules): Add restrict.
22094         * modules/regex: Depend on restrict.
22095
22096 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22097
22098         * m4/restrict.m4: New file.
22099         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
22100
22101 2003-08-07  Bruno Haible  <bruno@clisp.org>
22102
22103         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
22104         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
22105
22106 2003-08-07  Bruno Haible  <bruno@clisp.org>
22107
22108         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
22109         makes the module 'getndelim2' compatible with the module 'getline'.
22110
22111 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22112
22113         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
22114         byte with "\201" to avoid glitches when editing that source file
22115         with multi-gnome-terminal.
22116
22117 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22118
22119         * lib/bumpalloc.h: Remove.
22120
22121 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22122
22123         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
22124         * modules/bumpalloc: Remove.
22125
22126 2003-08-04  Paul Eggert  <eggert@twinsun.com>
22127
22128         * lib/getloadavg.c: Change copyright notice and spacing to conform to
22129         GNU coding style.
22130
22131         Merge from coreutils.
22132         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
22133         1. From glibc.
22134         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
22135         from Karl Berry, implemented by Jim Meyering.
22136         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
22137         from Dmitry V. Levin.
22138         Remove anachronistic cast of xrealloc.
22139         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
22140         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
22141         type. Otherwise, it wouldn't compile with at least /bin/cc on
22142         ymp-cray-unicos9.0.2.X.
22143         Combine two mostly-identical uses of alloca into one.
22144         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
22145
22146 2003-08-04  Dave Love  <d.love@dl.ac.uk>
22147
22148         [From Emacs.]
22149
22150         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
22151         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
22152         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
22153         obsolete NLIST_NAME_UNION.
22154         [__GNU__]: Undef BSD and FSCALE.
22155         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
22156
22157 2003-08-03  Paul Eggert  <eggert@twinsun.com>
22158
22159         * lib/stdbool_.h (_Bool): Make it signed char, instead of
22160         an enum type, so that it's guaranteed to promote to int.  See:
22161         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
22162
22163 2003-08-03  Karl Berry  <karl@gnu.org>
22164
22165         * config/depcomp: update from automake.
22166
22167 2003-07-31  Paul Eggert  <eggert@twinsun.com>
22168
22169         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
22170         (strerror): Don't assume that a printable int fits in 14 bytes.
22171
22172 2003-07-31  Bruno Haible  <bruno@clisp.org>
22173
22174         * modules/getpass-gnu: New file.
22175         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
22176
22177 2003-07-31  Bruno Haible  <bruno@clisp.org>
22178
22179         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
22180
22181 2003-07-24  Karl Berry  <karl@gnu.org>
22182
22183         * config/missing: update from automake.
22184
22185 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
22186             Bruno Haible  <bruno@clisp.org>
22187
22188         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
22189         * lib/getline.c (getline, getdelim): Likewise.
22190         Remove _GNU_SOURCE define; now it's defined in config.h through
22191         m4/getline.m4.
22192
22193 2003-07-23  Karl Berry  <karl@gnu.org>
22194
22195         * config/config.sub: update from prep.
22196
22197 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22198
22199         * modules/xalloc (Depends-on): Add exitfail.
22200         * modules/xmemcoll: Likewise.
22201
22202 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22203
22204         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
22205         over-parenthesization in macros.
22206
22207         Sync with coreutils.
22208
22209         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
22210         required by C99.
22211
22212         Use `exit_failure' for xalloc and xmemcoll instead of their own
22213         private exit-failure variables.
22214         * lib/xalloc.h (xalloc_exit_failure): Remove.
22215         * lib/xmalloc.c: Likewise.  Include exitfail.h.
22216         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
22217         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
22218         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
22219         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
22220
22221 2003-07-20  Jim Meyering  <jim@meyering.net>
22222
22223         * modules/closeout (Depends-on): Add exitfail.
22224         Suggestion from Bruno Haible.
22225
22226 2003-07-19  Karl Berry  <karl@gnu.org>
22227
22228         * config/config.sub: update from prep.
22229
22230 2003-07-18  Paul Eggert  <eggert@twinsun.com>
22231
22232         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
22233         Remove.
22234         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
22235         to test that it can stand by itself.  Include "exitfail.h".
22236         Clients should set exit_failure instead.
22237         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
22238
22239 2003-07-18  Bruno Haible  <bruno@clisp.org>
22240
22241         * modules/getndelim2: New file.
22242         * modules/getline: Share files with module getndelim2.
22243         * modules/getnline: Depend on getndelim2 instead of sharing files with
22244         it. Add getnline.c to lib_SOURCES.
22245         * MODULES.html.sh (func_all_modules): Add getndelim2.
22246
22247 2003-07-18  Bruno Haible  <bruno@clisp.org>
22248
22249         * m4/getndelim2.m4: New file.
22250         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
22251         invoke gl_PREREQ_GETNDELIM2.
22252         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
22253         gl_PREREQ_GETNDELIM2.
22254         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
22255         gl_GETNDELIM2.
22256
22257 2003-07-18  Bruno Haible  <bruno@clisp.org>
22258
22259         * lib/getndelim2.h: New file.
22260         * lib/getndelim2.c: Make into a module of its own. Include config.h,
22261         getndelim2.h.
22262         (getndelim2): Make non-static. Change return type to ssize_t.
22263         * lib/getline.h: Change argument names.
22264         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
22265         * lib/getnline.c: Include getndelim2.h.
22266
22267 2003-07-18  Andreas Schwab  <schwab@suse.de>
22268
22269         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
22270
22271 2003-07-17  Karl Berry  <karl@gnu.org>
22272
22273         * config/config.sub: update from prep.
22274
22275 2003-07-17  Bruno Haible  <bruno@clisp.org>
22276
22277         * modules/getnline: New file.
22278         * modules/getline: Add lib/getndelim2.c to source file list.
22279         * MODULES.html.sh (func_all_modules): Add getnline.
22280
22281 2003-07-17  Bruno Haible  <bruno@clisp.org>
22282
22283         * m4/getnline.m4: New file.
22284
22285 2003-07-17  Bruno Haible  <bruno@clisp.org>
22286
22287         * m4/Makefile.am.in: Remove file.
22288         * m4/Makefile.am: Remove file.
22289         * m4/Makefile.in: Remove file.
22290
22291 2003-07-17  Bruno Haible  <bruno@clisp.org>
22292
22293         * lib/getnline.h: New file.
22294         * lib/getnline.c: New file.
22295         * lib/getndelim2.c: New file, extracted from getline.c.
22296         (getndelim2): Renamed from getdelim2, with added nmax argument.
22297         * lib/getline.c: Include getndelim2.c.
22298         (getdelim2): Moved out to getndelim2.c.
22299         (getline, getdelim): Update.
22300
22301 2003-07-17  Bruno Haible  <bruno@clisp.org>
22302
22303         * lib/Makefile.am: Remove file.
22304         * lib/Makefile.in: Remove file.
22305
22306 2003-07-17  Bruno Haible  <bruno@clisp.org>
22307
22308         * configure.in: Remove file.
22309         * Makefile.in: Remove file.
22310
22311 2003-07-17  Bruno Haible  <bruno@clisp.org>
22312
22313         * MODULES.html.sh: Put the </BODY> right before </HTML>.
22314
22315 2003-07-16  Karl Berry  <karl@gnu.org>
22316
22317         * config/srclist-update: was running fixlicense twice, which caused
22318                 texinfo.tex to be nullified for some reason.  Simplify,
22319                 $gplsrc is no longer needed as far as I can see?
22320
22321 2003-07-16  Jim Meyering  <jim@meyering.net>
22322
22323         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
22324
22325 2003-07-15  Paul Eggert  <eggert@twinsun.com>
22326
22327         * config/srclist.txt: Get the following files from gettext-runtime/intl
22328         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
22329         ref-del.sin.  From Bruno Haible.
22330         * config/srclist-update (fixfile): Change grep pattern again, since the
22331         previous fix didn't work (there was another trailing $).  Use
22332         '[$]' to escape the $s.
22333
22334 2003-07-15  Karl Berry  <karl@gnu.org>
22335
22336         * lib/vasnprintf.c: update from gettext.
22337
22338 2003-07-15  Karl Berry  <karl@gnu.org>
22339
22340         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
22341         gets expanded when surrounded by '$'.
22342
22343 2003-07-15  Jim Meyering  <jim@meyering.net>
22344
22345         * modules/save-cwd: Don't depend on error.  From Derek Price.
22346
22347 2003-07-15  Jim Meyering  <jim@meyering.net>
22348
22349         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
22350
22351 2003-07-14  Simon Josefsson  <jas@extundo.com>
22352
22353         * modules/mempcpy: New file.
22354         * MODULES.html.sh (func_all_modules): Add mempcpy.
22355
22356 2003-07-14  Simon Josefsson  <jas@extundo.com>
22357
22358         * m4/mempcpy.m4: New file.
22359
22360 2003-07-14  Simon Josefsson  <jas@extundo.com>
22361
22362         * lib/mempcpy.h: New file.
22363         * lib/mempcpy.c: New file.
22364
22365 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22366
22367         * modules/getdate, modules/posixtm: Depend on mktime.
22368
22369 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22370
22371         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
22372         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
22373         unicodeio.c, unicodeio.h, unlocked-io.h:
22374         Switch from LGPL to GPL.
22375
22376 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22377
22378         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
22379         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
22380         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
22381         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
22382         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
22383         updated automatically by ../config/srclist-update.  This changes
22384         their license from LPGL to GPL.
22385
22386 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22387
22388         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
22389         assumed to refer to the root of the most recent stable gettext version.
22390         * config/srclistvars.sh: Add defaults for eggert.
22391         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
22392         Match "This program" as well as "The program".  This is needed
22393         for gettext.
22394
22395 2003-07-14  Jim Meyering  <jim@meyering.net>
22396
22397         Don't emit diagnostics.  Let callers do that.
22398         * lib/save-cwd.c: Don't include "error.h".
22399         (save_cwd): Don't call error.  Ensure that errno is valid
22400         when returning nonzero.
22401
22402         * lib/save-cwd.h (restore_cwd): Update prototype.
22403         * lib/save-cwd.c (restore_cwd): Remove two parameters.
22404         Simplify.  Don't call error upon failure.  Let callers do that.
22405         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
22406         when auditing is enabled.  But don't bother updating the #if.
22407
22408 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
22409
22410         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
22411         it breaks C++ compilation.
22412         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
22413
22414 2003-07-10  Simon Josefsson  <jas@extundo.com>
22415
22416         * modules/strchrnul (Makefile.am): Add strchrnul.h.
22417
22418 2003-07-10  Jim Meyering  <jim@meyering.net>
22419
22420         * m4/clock_time.m4: Remove trailing blank.
22421         * m4/intmax_t.m4: Likewise.
22422
22423 2003-07-10  Jim Meyering  <jim@meyering.net>
22424
22425         * lib/vasnprintf.c: Remove trailing blanks.
22426         Make cpp indentation consistent.
22427
22428 2003-07-09  Paul Eggert  <eggert@twinsun.com>
22429
22430         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
22431         posixver.c, strftime.c, strnlen.c, strverscmp.c:
22432         Switch from LGPL to GPL.
22433
22434 2003-07-09  Paul Eggert  <eggert@twinsun.com>
22435
22436         * config/srclist.txt: Sort sublists.  Add
22437         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
22438         that differ from gnulib for one reason or another; we'd like this list
22439         to be smaller but for now let's document what we have.
22440
22441 2003-07-08  Paul Eggert  <eggert@twinsun.com>
22442
22443         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
22444         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
22445         and sweeter "eval x=$x".
22446         * config/srclist.txt: Get lib/argp* from glibc.
22447
22448 2003-07-07  Paul Eggert  <eggert@twinsun.com>
22449
22450         * lib/mktime.c: Fix some boundary cases and remove need for floating
22451         point.
22452
22453         Issue a compile-time diagnostic if time_t is floating point, or if
22454         two's complement arithmetic is not in effect, or if arithmetic
22455         right shift does not propagate the sign.  These assumptions were
22456         all in the original code but they weren't checked.
22457
22458         (TIME_T_MIDPOINT, verify): New macros.
22459         (__isleap): Remove; it has integer overflow problems.
22460         (leapyear): New function, without those problems.
22461         (ydhms_tm_diff): Remove; splitting into two parts.
22462         (ydhms_diff): New function, containing the arithmetic part of
22463         the old ydhms_tm_diff function.  Issue a compile-time
22464         diagnostic if we are not using C99 integer division.
22465         Avoid casts when possible.
22466         (guess_time_tm): New function, containing the checking part of
22467         the old ydhms_tm_diff function.  Return the new value, rather than
22468         the difference between it and the old.  Accept a new argument T
22469         so that *T specifies the old value.  Check for overflow in the result.
22470
22471         (__mktime_internal): Use a time_t offset, not a long int offset.
22472         This undoes the 2003-06-04 change, which is no longer needed now
22473         that we have better overflow checking.
22474         (localtime_offset): Likewise.
22475
22476         (__mktime_internal): Avoid harmful overflow on hosts where time_t
22477         and long are 64-bit but int is only 32-bit.
22478         (ydhms_diff): Use long int to store year1 and yday1.
22479         Issue a compile-time diagnostic if long int is not wide enough.
22480
22481         (__mktime_internal): Use long int to store adjusted year and yday.
22482         Use plain C rather than preprocessor commands, if that doesn't
22483         affect efficiency.
22484         Check for overflow (and try to repair) after each probe
22485         rather than checking only at the very end.  This avoids some bugs
22486         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
22487         does not equal GMT offset at maximum time).
22488         Use integer to check for overflow rather than floating point; this
22489         is more portable to non-IEEE hosts, and is a tad faster.
22490         When we detect that we are oscillating between two values,
22491         don't check whether tm_isdst has the requested value, since
22492         we already know the answer.  When tm_isdst has the wrong value,
22493         use a different heuristic to find the right one, based on the
22494         extreme values actually observed in practice in tz2003a,
22495         rather than the (overly optimistic) "previous 3 calendar quarters".
22496
22497         (not_equal_tm, print_tm, check_result): Use "const T" rather than
22498         "T const" to accommodate glibc style.
22499         (check_result): Use less-confusing report format.  "long" -> "long int.
22500         (main): Likewise.
22501         Don't loop if the iteration overflows time_t.
22502         Allow a negative step in the iteration.
22503
22504 2003-07-06  Karl Berry  <karl@gnu.org>
22505
22506         * config/depcomp: update from automake.
22507         * config/config.sub: update from prep.
22508
22509 2003-07-03  Karl Berry  <karl@gnu.org>
22510
22511         * config/config.guess: update from prep.
22512
22513 2003-07-01  Paul Eggert  <eggert@twinsun.com>
22514
22515         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
22516         xreadlink.c now includes it unconditionally.
22517
22518 2003-07-01  Paul Eggert  <eggert@twinsun.com>
22519
22520         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
22521         having it depend on HAVE_SYS_TYPES_H.
22522
22523 2003-07-01  Bruno Haible  <bruno@clisp.org>
22524
22525         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
22526         <sys/types.h> should be sufficient.
22527         Reported by Paul Eggert.
22528
22529 2003-06-26  Karl Berry  <karl@gnu.org>
22530
22531         * config/depcomp: update from automake.
22532
22533 2003-06-26  Bruno Haible  <bruno@clisp.org>
22534
22535         * modules/human: Depend on module stdbool.
22536
22537 2003-06-25  Bruno Haible  <bruno@clisp.org>
22538
22539         * modules/readlink: New file.
22540         * modules/xreadlink: Depend on it.
22541         * MODULES.html.sh (func_all_modules): Add readlink.
22542
22543 2003-06-25  Bruno Haible  <bruno@clisp.org>
22544
22545         * m4/readlink.m4: New file.
22546
22547 2003-06-25  Bruno Haible  <bruno@clisp.org>
22548
22549         * lib/readlink.c: New file.
22550
22551 2003-06-22  Karl Berry  <karl@gnu.org>
22552
22553         * config/srclist.txt: update mkinstalldirs from automake.
22554         * config/mkinstalldirs: update.
22555
22556 2003-06-22  Bruno Haible  <bruno@clisp.org>
22557
22558         Portability to mingw32.
22559         * m4/ssize_t.m4: New file, from GNU gettext.
22560         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
22561         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
22562
22563 2003-06-22  Bruno Haible  <bruno@clisp.org>
22564
22565         * modules/safe-read: Add m4/ssize_t.m4.
22566         * modules/xreadlink: Add m4/ssize_t.m4.
22567
22568 2003-06-20  Bruno Haible  <bruno@clisp.org>
22569
22570         Assume C89, so PARAMS isn't needed.
22571         * lib/unicodeio.h (PARAMS): Remove.
22572         * lib/unicodeio.c: Don't use PARAMS.
22573
22574 2003-06-18  Karl Berry  <karl@gnu.org>
22575
22576         * config/config.{guess,sub}: update from prep.
22577
22578 2003-06-18  Jim Meyering  <jim@meyering.net>
22579
22580         Merge changes from coreutils.
22581         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
22582         Remove explicit declarations of xmalloc and realloc.
22583         Include xalloc.h.
22584         (read_utmp): Remove anachronistic cast of xmalloc.
22585
22586 2003-06-17  Paul Eggert  <eggert@twinsun.com>
22587
22588         Assume C89, so PARAMS isn't needed.
22589         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
22590         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
22591         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
22592         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
22593         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
22594         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
22595         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
22596         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
22597         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
22598         lib/xstrtod.h, lib/xstrtol.h: Likewise.
22599         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
22600         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
22601         no longer needed. Anyway, config.h should always be included before any
22602         other file.
22603
22604 2003-06-11  Simon Josefsson  <jas@extundo.com>
22605
22606         * modules/sysexits: New file.
22607         * MODULES.html.sh (func_all_modules): Add sysexits.
22608
22609 2003-06-11  Simon Josefsson  <jas@extundo.com>
22610
22611         * lib/sysexit_.h: New file.
22612
22613 2003-06-11  Derek Price  <derek@ximbiot.com>
22614
22615         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
22616         necessary.
22617
22618 2003-06-11  Bruno Haible  <bruno@clisp.org>
22619
22620         * m4/sysexits.m4: New file.
22621
22622 2003-06-10  Simon Josefsson  <jas@extundo.com>
22623
22624         * lib/argp.h: New file, from glibc.
22625         * lib/argp-ba.c: New file, from glibc.
22626         * lib/argp-eexst.c: New file, from glibc.
22627         * lib/argp-fmtstream.c: New file, from glibc.
22628         * lib/argp-fmtstream.h: New file, from glibc.
22629         * lib/argp-fs-xinl.c: New file, from glibc.
22630         * lib/argp-help.c: New file, from glibc.
22631         * lib/argp-namefrob.h: New file, from glibc.
22632         * lib/argp-parse.c: New file, from glibc.
22633         * lib/argp-pv.c: New file, from glibc.
22634         * lib/argp-pvh.c: New file, from glibc.
22635         * lib/argp-xinl.c: New file, from glibc.
22636
22637 2003-06-10  Simon Josefsson  <jas@extundo.com>
22638
22639         * modules/strchrnul: New file.
22640
22641 2003-06-10  Simon Josefsson  <jas@extundo.com>
22642
22643         * modules/argp: New file.
22644
22645 2003-06-10  Simon Josefsson  <jas@extundo.com>
22646
22647         * m4/strchrnul.m4: New file.
22648
22649 2003-06-10  Simon Josefsson  <jas@extundo.com>
22650
22651         * lib/strchrnul.h: New file.
22652         * lib/strchrnul.c: New file.
22653
22654 2003-06-10  Bruno Haible  <bruno@clisp.org>
22655
22656         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
22657
22658 2003-06-07  Karl Berry  <karl@gnu.org>
22659
22660         * config/config.{guess,sub}: update from prep.
22661
22662 2003-06-07  Jim Meyering  <jim@meyering.net>
22663
22664         * modules/strtod: Use $(...) notation, not @...@ for
22665         AC_REPLACE'd variables.
22666         * modules/localcharset: Likewise.
22667
22668 2003-06-07  Jim Meyering  <jim@meyering.net>
22669
22670         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
22671         in place of my name in the copyright comment.
22672         Remove definition and uses of __P.
22673
22674         From coreutils.
22675         * lib/stat.c: Don't declare xmalloc explicitly.
22676         Instead, include "xalloc.h".
22677         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
22678         xrealloc, and xcalloc return values.
22679         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
22680         Improve comment.
22681         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
22682
22683 2003-06-07  Bruno Haible  <bruno@clisp.org>
22684
22685         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
22686         avoid AC_CONFIG_LINKS.
22687         * modules/fnmatch (Makefile.am): Use explicit creation rule for
22688         fnmatch.h, to avoid AC_CONFIG_LINKS.
22689         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
22690
22691 2003-06-07  Bruno Haible  <bruno@clisp.org>
22692
22693         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
22694         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
22695         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
22696         directory.
22697         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
22698         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
22699         directory.
22700
22701 2003-06-06  Jim Meyering  <jim@meyering.net>
22702
22703         Merge from coreutils.
22704         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
22705         Consolidate declarations and initializations of *_base* locals.
22706
22707         Merge from coreutils.
22708         This avoids a core dump on systems without GNU putenv,
22709         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
22710         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
22711         (unsetenv): New static function, from GNU libc.
22712         (rpl_putenv): Use it.
22713
22714         * lib/modechange.c: Remove trailing blanks.
22715
22716         Merge from coreutils.
22717         * lib/fsusage.c: Remove declaration of statfs.
22718         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
22719
22720         * lib/posixtm.c: Include <stdbool.h> unconditionally.
22721
22722 2003-06-06  Jim Meyering  <jim@meyering.net>
22723
22724         * lib/stdbool_.h: Renamed from stdbool.h.in.
22725
22726 2003-06-06  Jim Meyering  <jim@meyering.net>
22727             Bruno Haible  <bruno@clisp.org>
22728
22729         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
22730         Adjust Makefile.am snippet not to redirect directly to target.
22731         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
22732
22733 2003-06-05  Paul Eggert  <eggert@twinsun.com>
22734
22735         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
22736         mismatch, look in future quarters as well as past.  This fixes a
22737         bug when processing fall-backwards gaps immediately after a long
22738         period of daylight-saving time.
22739
22740         * lib/mktime.c: Assume freestanding C89 or better.
22741         (HAVE_LIMITS_H): Remove.  Assume it's 1.
22742         (__P): Remove; not used.
22743         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
22744         (mktime, not_equal_tm, print_tm, check_result,
22745         main): Use prototypes.  Use const * where appropriate.
22746         (main): Fix typo in testing code that uncovered by above changes.
22747         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
22748
22749 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22750
22751         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
22752         locale.h, localeconv.  This merges changes from coreutils.
22753
22754         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
22755         It can be removed after the next Autoconf is released.
22756         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
22757         needed.
22758
22759 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22760
22761         * lib/mktime.c: Fix Debian bug 177940
22762         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
22763         (localtime_offset): Now long int, not time_t, because we want it
22764         to be guaranteed to be signed.  All uses changed.
22765         (__mktime_internal): If overflow would occur when adding offset,
22766         don't add it.
22767
22768         Merge 'human' changes from coreutils.  Rewrite to support
22769         locale-specific notations like thousands separators.
22770         * lib/human.c: Simplify authorship notice.
22771         Include human.h immediately after config.h.
22772         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
22773         <limits.h>: Do not include, since human.h does.
22774         (SIZE_MAX, UINTMAX_MAX): New macros.
22775         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
22776         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
22777         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
22778         (power_letter): Renamed from suffixes.
22779         (generate_suffix_backwards): Remove.
22780         (adjust_value): Now takes int style (because of human.h changes)
22781         and long double value (for greater precision on some platforms).
22782         (group_number): New function.
22783         (human_readable): Use it.  Use integer options, not enum.
22784         Put the options before the sizes in the arg list.
22785         Support all the new options.
22786         The old human_readable function has been removed;
22787         use inttostr.h instead.
22788         (human_readable, default_block_size, humblock):
22789         Use uintmax_t, not int, for block sizes.
22790         (human_readable_inexact, block_size_types): Remove.
22791         (block_size_opts): New constant.
22792         (human_options): Renamed from human_block_size, with new signature
22793         that allows block sizes up to UINTMAX_MAX.  All callers changed.
22794         * lib/human.h: Add copyright and authorship notice.
22795         Include <limits.h> and <stdbool.h> unconditionally.
22796         (PARAMS): Remove.  All uses removed.
22797         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
22798         (enum human_inexact_style): Remove tag; now a nameless enum.
22799         (human_floor, human_ceiling, human_round_to_even): Now have
22800         values 2, 0, 1 rather than -1, 1, 0.
22801         (human_group_digits, human_suppress_point_zero, human_autoscale,
22802         human_base_1024, human_SI, human_B): New constants.
22803         (human_readable_inexact, human_block_size): Remove.
22804         (human_readable): Size args are now uintmax_t, not int.
22805         (human_options): New decl.
22806
22807         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
22808         unnecessary now that we assume C89 or better.  This change
22809         imported from coreutils.
22810
22811         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
22812         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
22813         in the 2003-05-30 sync from glibc.
22814
22815         .h files should stand alone, but we shouldn't include <sys/types.h>
22816         if we can get away with just <stddef.h>.
22817
22818         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
22819         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
22820         rather than <sys/types.h>, as we merely need size_t.
22821         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
22822         to get size_t.
22823         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
22824         Include <stdio.h>, to get FILE.
22825         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
22826         memcasecmp.h has included <stddef.h> and all we need is size_t.
22827         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
22828         our interface, instead of including <sys/types.h>
22829
22830 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22831
22832         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
22833         now, as glibc mktime is buggy on non-glibc systems.
22834
22835 2003-06-03  Karl Berry  <karl@gnu.org>
22836
22837         * config/config.sub: update from prep.
22838
22839 2003-06-02  Paul Eggert  <eggert@twinsun.com>
22840
22841         [from coreutils]
22842         Fix some minor time-related bugs with POSIX time arguments.
22843         Some valid time stamps were being rejected (notably -1, and
22844         time stamps before 1900 on 64-bit hosts).  And some invalid
22845         time stamps were being accepted, e.g. September 31.
22846
22847         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
22848         that we can return (time_t) -1 successfully.
22849         * lib/posixtm.c: Likewise.
22850         [HAVE_STDBOOL_H]: Include <stdbool.h>.
22851         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
22852         (t): Remove static var.
22853         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
22854         of static var.  All uses changed.
22855         (year): Do not reject years before 1900; they can occur with
22856         64-bit time_t.
22857         (posix_time_parse): Do not check for out-of-range components;
22858         that is now the caller's responsibility, since our checks were
22859         only approximations.
22860         (posixtime): Use mktime to check for out-of-range components,
22861         since it knows them exactly.
22862         If mktime returns (time_t) -1, check whether an error actually occurred
22863         by invoking localtime on -1.
22864         (main) [TEST_POSIXTIME]: Check for input data errors, and report
22865         posixtime failures better.
22866         Improve the test data (in comments only).
22867
22868 2003-06-02  Karl Berry  <karl@gnu.org>
22869
22870         * config/mkinstalldirs (version): new variable.
22871         (--version): new option.
22872         (usage): improve message.
22873
22874 2003-05-30  Karl Berry  <karl@gnu.org>
22875
22876         * lib/mktime.c: update from libc.
22877
22878 2003-05-30  Bruno Haible  <bruno@clisp.org>
22879
22880         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
22881         * config/config.rpath: Upgrade to gettext-0.12.1.
22882
22883 2003-05-30  Bruno Haible  <bruno@clisp.org>
22884
22885         * m4/gettext.m4: Upgrade to gettext-0.12.1.
22886         * m4/nls.m4: New file, from gettext-0.12.1.
22887         * m4/po.m4: New file, from gettext-0.12.1.
22888         * m4/progtest.m4: Upgrade to gettext-0.12.1.
22889
22890 2003-05-30  Bruno Haible  <bruno@clisp.org>
22891
22892         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
22893         * lib/localcharset.h: Likewise.
22894         * lib/localcharset.c: Likewise.
22895
22896 2003-05-29  Karl Berry  <karl@gnu.org>
22897
22898         * config/config.rpath: update from gettext.
22899
22900 2003-05-28  Paul Eggert  <eggert@twinsun.com>
22901
22902         Assume the headers required for C89 freestanding compilers.
22903         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
22904         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
22905         * m4/human.m4 (gl_HUMAN): Likewise.
22906         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
22907         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
22908         * m4/userspec.m4 (gl_USERSPEC): Likewise.
22909         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
22910         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
22911         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
22912
22913 2003-05-28  Paul Eggert  <eggert@twinsun.com>
22914
22915         Assume the headers required for C89 freestanding compilers.
22916         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
22917         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
22918         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
22919         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
22920         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
22921         define, since <limits.h> is guaranteed to do that.
22922         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
22923         * lib/exclude.c: Include <stdbool.h> unconditionally.
22924         * lib/tempname.c: Include <stddef.h> unconditionally.
22925         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
22926         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
22927         <stddef.h> does that.
22928         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
22929         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
22930         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
22931         needed.
22932         * lib/xstrtol.c: Likewise.
22933         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
22934         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
22935
22936         * lib/addext.c (addext): Use assignment rather than cast, to avoid
22937         warnings on some platforms.
22938
22939         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
22940         arbitrarily.
22941
22942 2003-05-26  Jim Meyering  <jim@meyering.net>
22943
22944         Merge in a change from coreutils:
22945         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
22946         that is guaranteed to be `no'.  Use `no_such_member' to indicate
22947         that condition, rather than `-1' which is slightly misleading.
22948         Change the name of the cache variable to have the gl_ prefix.
22949         Prompted by a patch from Richard Dawe for DJGPP.
22950
22951 2003-05-24  Karl Berry  <karl@gnu.org>
22952
22953         * config/config.guess: update from prep.
22954
22955 2003-05-22  Karl Berry  <karl@gnu.org>
22956
22957         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
22958
22959 2003-05-20  Karl Berry  <karl@gnu.org>
22960
22961         * config/config.guess: update from prep.
22962
22963 2003-05-18  Karl Berry  <karl@gnu.org>
22964
22965         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
22966         might actually be set by the user.
22967
22968         * config/depcomp, install-sh, mdate-sh: update from automake.
22969
22970 2003-05-17  Bruno Haible  <bruno@clisp.org>
22971
22972         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
22973         invalid expansion for AC_EGREP_CPP.
22974         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
22975         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
22976         Suggested by Akim Demaille <akim@epita.fr> in
22977         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
22978
22979 2003-05-12  Jim Meyering  <jim@meyering.net>
22980
22981         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
22982         the space-padded-by-default conversion specifiers, %e, %k, %l.
22983
22984 2003-05-12  Bruno Haible  <bruno@clisp.org>
22985
22986         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
22987         the string is longer than 4 KB.
22988
22989 2003-05-11  Karl Berry  <karl@gnu.org>
22990
22991         * config/config.{guess,sub}: update from prep.
22992
22993 2003-05-09  Bruno Haible  <bruno@clisp.org>
22994
22995         * modules/error: Add m4/strerror_r.m4 to file list.
22996
22997 2003-05-03  Bruno Haible  <bruno@clisp.org>
22998
22999         Upgrade to Unicode-4.0.
23000         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
23001         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
23002         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
23003         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
23004         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
23005         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
23006         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
23007         Change width of U+E0100..U+E01EF from 1 to 0.
23008
23009 2003-04-25  Jim Meyering  <jim@meyering.net>
23010
23011         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
23012         of type size_t, not int.
23013
23014 2003-04-25  Bruno Haible  <bruno@clisp.org>
23015
23016         * lib/copy-file.c: Include <stddef.h>, for size_t.
23017
23018 2003-04-21  Paul Eggert  <eggert@twinsun.com>
23019
23020         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
23021         code which expansion is under static control.  Patch imported from
23022         Akim Demaille's patch to Bison; see
23023         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
23024
23025 2003-04-14  Bruno Haible  <bruno@clisp.org>
23026
23027         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
23028
23029 2003-04-11  Jim Meyering  <jim@meyering.net>
23030
23031         Merge changes from Coreutils.
23032
23033         2003-03-22  Jim Meyering  <jim@meyering.net>
23034
23035         * lib/strftime.c (widen): Cast alloca return value to proper type.
23036
23037         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
23038
23039         From GNU libc.
23040         * lib/strftime.c (my_strftime): Handle very large width
23041         specifications for numeric values correctly.  Improve checks for
23042         overflow.
23043
23044         2003-01-19  Jim Meyering  <jim@meyering.net>
23045
23046         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
23047         definitions.
23048         (nl_get_alt_digit) [! defined my_strftime]: Define.
23049         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
23050         _nl_get_alt_digit and _nl_get_walt_digit.
23051
23052         * lib/strftime.c (my_strftime): Merge in locale-related changes from
23053         libc. These changes have no effect outside of _LIBC.
23054
23055 2003-04-10  Bruno Haible  <bruno@clisp.org>
23056
23057         * modules/findprog: New file.
23058         * MODULES.html.sh (func_all_modules): Add it.
23059
23060 2003-04-10  Bruno Haible  <bruno@clisp.org>
23061
23062         * m4/findprog.m4: New file.
23063         * m4/eaccess.m4: New file.
23064
23065 2003-04-10  Bruno Haible  <bruno@clisp.org>
23066
23067         * lib/findprog.h: New file, from GNU gettext.
23068         * lib/findprog.c: New file, from GNU gettext.
23069
23070 2003-04-05  Jim Meyering  <jim@meyering.net>
23071
23072         Merge changes from Coreutils.
23073
23074         * lib/exclude.h (PARAMS): Remove definition and uses.
23075         * lib/exclude.c: Remove uses of `PARAMS'.
23076
23077         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
23078         Add test-cases for DOS filenames. Declare program_name.
23079         (main): Set up program_name.  Patch by Rich Dawe.
23080
23081         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
23082         error from mntctl.
23083         Use mntctl's return value to drive the entry-processing loop, since
23084         we can't rely on the value of the vmt_length member in the last
23085         entry.  On some systems doing so could result in exhausting
23086         virtual memory.  Based in part on a patch from Mike Jetzer.
23087
23088 2003-04-04  Bruno Haible  <bruno@clisp.org>
23089
23090         * modules/linebreak: New file.
23091         * MODULES.html.sh (func_all_modules): Add it.
23092
23093 2003-04-04  Bruno Haible  <bruno@clisp.org>
23094
23095         * m4/linebreak.m4: New file.
23096
23097 2003-04-04  Bruno Haible  <bruno@clisp.org>
23098
23099         * lib/linebreak.h: New file, from GNU gettext.
23100         * lib/linebreak.c: New file, from GNU gettext with slight
23101         modifications.
23102         * lib/lbrkprop.h: New file, from GNU gettext.
23103
23104 2003-04-03  Bruno Haible  <bruno@clisp.org>
23105
23106         * modules/utf8-ucs4: New file.
23107         * modules/utf16-ucs4: New file.
23108         * modules/ucs4-utf8: New file.
23109         * modules/ucs4-utf16: New file.
23110         * MODULES.html.sh (func_all_modules): Add them.
23111
23112 2003-04-03  Bruno Haible  <bruno@clisp.org>
23113
23114         * m4/utf-ucs4.m4: New file.
23115         * m4/ucs4-utf.m4: New file.
23116
23117 2003-04-03  Bruno Haible  <bruno@clisp.org>
23118
23119         * lib/utf8-ucs4.h: New file, from GNU gettext.
23120         * lib/utf16-ucs4.h: New file, from GNU gettext.
23121         * lib/ucs4-utf8.h: New file, from GNU gettext.
23122         * lib/ucs4-utf16.h: New file, from GNU gettext.
23123
23124 2003-04-02  Bruno Haible  <bruno@clisp.org>
23125
23126         * modules/binary-io: New file.
23127         * MODULES.html.sh (func_all_modules): Add it.
23128
23129 2003-04-02  Bruno Haible  <bruno@clisp.org>
23130
23131         * lib/binary-io.h: New file, from GNU gettext.
23132
23133 2003-04-01  Bruno Haible  <bruno@clisp.org>
23134
23135         * modules/pathname: New file.
23136         * MODULES.html.sh (func_all_modules): Add it.
23137
23138 2003-04-01  Bruno Haible  <bruno@clisp.org>
23139
23140         * lib/pathname.h: New file, from GNU gettext.
23141         * lib/concatpath.c: New file, from GNU gettext.
23142
23143 2003-03-30  Bruno Haible  <bruno@clisp.org>
23144
23145         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
23146
23147 2003-03-30  Bruno Haible  <bruno@clisp.org>
23148
23149         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
23150         function chown() doesn't exist.
23151
23152 2003-03-28  Bruno Haible  <bruno@clisp.org>
23153
23154         * modules/copy-file: New file.
23155         * MODULES.html.sh (func_all_modules): Add it.
23156
23157 2003-03-28  Bruno Haible  <bruno@clisp.org>
23158
23159         * m4/copy-file.m4: New file.
23160
23161 2003-03-28  Bruno Haible  <bruno@clisp.org>
23162
23163         * lib/copy-file.h: New file, from GNU gettext.
23164         * lib/copy-file.c: New file, from GNU gettext.
23165
23166 2003-03-18  Jim Meyering  <jim@meyering.net>
23167
23168         * lib/quote.c (quote_n): Fix typo in comment.
23169
23170 2003-03-18  Bruno Haible  <bruno@clisp.org>
23171
23172         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
23173         checking.
23174         * m4/onceonly_2_57.m4: Likewise.
23175
23176 2003-03-17  Bruno Haible  <bruno@clisp.org>
23177
23178         * m4/onceonly.m4: Require autoconf 2.54 or newer.
23179         (m4_quote): Remove macro.
23180         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
23181
23182 2003-03-14  Jim Meyering  <jim@meyering.net>
23183
23184         Merge changes from Coreutils.
23185         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
23186         to be const, in order to avoid warnings.
23187         (obstack_room): Likewise.
23188         (obstack_empty_p): Likewise.
23189
23190 2003-03-14  Bruno Haible  <bruno@clisp.org>
23191
23192         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
23193         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
23194
23195 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23196
23197         Merge changes from Bison.
23198         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
23199         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
23200         when compiling Bison 1.875's `bitset bset = obstack_alloc
23201         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
23202         * lib/hash.c: Include <stdbool.h> unconditionally.
23203
23204 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23205
23206         * m4/onceonly.m4 (m4_quote): New macro.
23207         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
23208         Quote AC_FOREACH variable-expansions properly.
23209
23210 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23211
23212         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
23213
23214 2003-03-09  Paul Eggert  <eggert@twinsun.com>
23215
23216         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
23217         Reported by Bruce Becker; see:
23218         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
23219
23220 2003-03-03  Paul Eggert  <eggert@twinsun.com>
23221             Bruno Haible  <bruno@clisp.org>
23222
23223         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
23224         Reported by John Hughes, see
23225         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
23226
23227 2003-02-20  Bruno Haible  <bruno@clisp.org>
23228
23229         * MODULES.html.sh (func_all_modules): Add poll.
23230
23231 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23232
23233         * modules/poll: New file.
23234
23235 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23236
23237         * lib/poll_.h: New file.
23238         * lib/poll.c: New file.
23239
23240 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23241
23242         * m4/poll.m4: New file.
23243
23244 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23245
23246         * modules/mathl: New file.
23247
23248 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23249
23250         * lib/mathl.h: New file.
23251         * lib/acosl.c: New file.
23252         * lib/asinl.c: New file.
23253         * lib/atanl.c: New file.
23254         * lib/ceill.c: New file.
23255         * lib/cosl.c: New file.
23256         * lib/expl.c: New file.
23257         * lib/floorl.c: New file.
23258         * lib/frexpl.c: New file.
23259         * lib/ldexpl.c: New file.
23260         * lib/logl.c: New file.
23261         * lib/sincosl.c: New file.
23262         * lib/sinl.c: New file.
23263         * lib/sqrtl.c: New file.
23264         * lib/tanl.c: New file.
23265         * lib/trigl.c: New file.
23266         * lib/trigl.h: New file.
23267
23268 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23269
23270         * m4/mathl.m4: New file.
23271
23272 2003-02-18  Bruno Haible  <bruno@clisp.org>
23273
23274         * MODULES.html.sh (func_all_modules): Add mathl.
23275
23276 2003-02-17  Bruno Haible  <bruno@clisp.org>
23277
23278         * modules/mkdtemp: New module.
23279         * MODULES.html.sh (func_all_modules): Add it.
23280
23281 2003-02-17  Bruno Haible  <bruno@clisp.org>
23282
23283         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
23284
23285 2003-02-17  Bruno Haible  <bruno@clisp.org>
23286
23287         * lib/mkdtemp.h: New file, from GNU gettext.
23288         * lib/mkdtemp.c: New file, from GNU gettext.
23289
23290 2003-02-02  Jim Meyering  <jim@meyering.net>
23291
23292         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
23293         e.g. glibc-2.2.93.
23294
23295 2003-01-31  Bruno Haible  <bruno@clisp.org>
23296
23297         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
23298         'rpl_rename'.
23299         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
23300         'rpl_strnlen'.
23301         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
23302         'rpl_strtod'.
23303         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
23304         'rpl_utime'.
23305
23306 2003-01-31  Bruno Haible  <bruno@clisp.org>
23307
23308         * lib/rename.c: #undef rename before defining rpl_rename.
23309         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
23310
23311 2003-01-30  Bruno Haible  <bruno@clisp.org>
23312
23313         * modules/vasnprintf, modules/vasprintf: New modules.
23314         * MODULES.html.sh (func_all_modules): Add them.
23315
23316 2003-01-30  Bruno Haible  <bruno@clisp.org>
23317
23318         * m4/signed.m4: New file, from GNU gettext.
23319         * m4/longdouble.m4: New file, from GNU gettext.
23320         * m4/wchar_t.m4: New file, from GNU gettext.
23321         * m4/wint_t.m4: New file, from GNU gettext.
23322         * m4/vasnprintf.m4: New file.
23323         * m4/vasprintf.m4: New file.
23324
23325 2003-01-30  Bruno Haible  <bruno@clisp.org>
23326
23327         * lib/printf-args.h: New file, from GNU gettext.
23328         * lib/printf-args.c: New file, from GNU gettext.
23329         * lib/printf-parse.h: New file, from GNU gettext.
23330         * lib/printf-parse.c: New file, from GNU gettext.
23331         * lib/vasnprintf.h: New file, from GNU gettext.
23332         * lib/vasnprintf.c: New file, from GNU gettext.
23333         * lib/asnprintf.c: New file, from GNU gettext.
23334         * lib/vasprintf.h: New file, from GNU gettext with modifications.
23335         * lib/vasprintf.c: New file, from GNU gettext.
23336         * lib/asprintf.c: New file, from GNU gettext.
23337
23338 2003-01-29  Bruno Haible  <bruno@clisp.org>
23339
23340         * modules/stpncpy: New module.
23341         * MODULES.html.sh (func_all_modules): Add it.
23342
23343 2003-01-29  Bruno Haible  <bruno@clisp.org>
23344
23345         * m4/stpncpy.m4: New file.
23346
23347 2003-01-29  Bruno Haible  <bruno@clisp.org>
23348
23349         * lib/stpncpy.h: New file, from GNU gettext with modifications.
23350         * lib/stpncpy.c: New file, from GNU gettext with modifications.
23351
23352 2003-01-28  Bruno Haible  <bruno@clisp.org>
23353
23354         * modules/c-ctype: New module.
23355         * MODULES.html.sh (func_all_modules): Add it.
23356
23357 2003-01-28  Bruno Haible  <bruno@clisp.org>
23358
23359         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
23360         Paul Eggert.
23361         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
23362         Paul Eggert.
23363
23364 2003-01-27  Bruno Haible  <bruno@clisp.org>
23365
23366         * modules/xsetenv: New module.
23367         * MODULES.html.sh (func_all_modules): Add it.
23368
23369 2003-01-27  Bruno Haible  <bruno@clisp.org>
23370
23371         * lib/xsetenv.h: New file, from GNU gettext.
23372         * lib/xsetenv.c: New file, from GNU gettext.
23373
23374 2003-01-23  Jim Meyering  <jim@meyering.net>
23375
23376         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
23377         from working on systems without dirfd (at least Irix and OSF1/Tru64).
23378
23379 2003-01-23  Bruno Haible  <bruno@clisp.org>
23380
23381         * modules/minmax: New module.
23382         * MODULES.html.sh (func_all_modules): Add it.
23383
23384 2003-01-23  Bruno Haible  <bruno@clisp.org>
23385
23386         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
23387         Eggert.
23388
23389 2003-01-22  Bruno Haible  <bruno@clisp.org>
23390
23391         * modules/exit: New module.
23392         * MODULES.html.sh (func_all_modules): Add it.
23393
23394 2003-01-22  Bruno Haible  <bruno@clisp.org>
23395
23396         * lib/exit.h: New file, from GNU gettext.
23397
23398 2003-01-19  Bruno Haible  <bruno@clisp.org>
23399
23400         * gnulib-tool: Recognize option --extract-maintainer.
23401         (func_get_maintainer): New function.
23402         * modules/*: Add Maintainer entry.
23403
23404 2003-01-16  Jim Meyering  <jim@meyering.net>
23405
23406         * m4/regex.m4: The `regex' struct is both input and output.
23407         Initialize it before each use.  Patch by Tim Waugh.
23408
23409 2003-01-16  Bruno Haible  <bruno@clisp.org>
23410
23411         * MODULES.html.sh: Add a table of contents. Add the module name as
23412         leftmost column. Add hyperlinks.
23413
23414 2003-01-15  Bruno Haible  <bruno@clisp.org>
23415
23416         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
23417
23418 2003-01-15  Bruno Haible  <bruno@clisp.org>
23419
23420         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
23421         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
23422         suffix.
23423
23424 2003-01-15  Bruno Haible  <bruno@clisp.org>
23425
23426         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
23427
23428 2003-01-15  Bruno Haible  <bruno@clisp.org>
23429
23430         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
23431         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
23432
23433 2003-01-14  Jim Meyering  <jim@meyering.net>
23434
23435         * lib/same.c (same_name): Tweak a comment.
23436
23437 2003-01-14  Bruno Haible  <bruno@clisp.org>
23438
23439         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
23440         when a string comparison is sufficient.
23441
23442 2003-01-14  Bruno Haible  <bruno@clisp.org>
23443
23444         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
23445         'unsigned int'.
23446
23447 2003-01-14  Bruno Haible  <bruno@clisp.org>
23448
23449         * lib/hash-pjw.c: Add comment about low quality of this function.
23450
23451 2003-01-13  Bruno Haible  <bruno@clisp.org>
23452
23453         * modules/stpcpy: Distribute lib/stpcpy.h.
23454         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
23455
23456 2003-01-13  Bruno Haible  <bruno@clisp.org>
23457
23458         * modules/*: Add a description.
23459         * modules/strpbrk: Fix Makefile.am snippet.
23460         * modules/strtoimax: Fix dependencies.
23461         * modules/strtoumax: Likewise.
23462
23463 2003-01-13  Bruno Haible  <bruno@clisp.org>
23464
23465         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
23466         * modules/alloca (Makefile.am): All object files depend on alloca.h.
23467         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
23468
23469 2003-01-13  Bruno Haible  <bruno@clisp.org>
23470
23471         * gnulib-tool (func_create_testdir): Store config/* files in the main
23472         directory.
23473         * config.rpath: Move to ...
23474         * config/config.rpath: ... here.
23475         * modules/gettext: Contains config/config.rpath, not config.rpath.
23476         * modules/iconv: Likewise.
23477
23478 2003-01-12  Paul Eggert  <eggert@twinsun.com>
23479
23480         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
23481         to avoid collisions with libcurses and libreadline.
23482
23483         * m4/getstr.m4: Remove.
23484         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
23485
23486 2003-01-12  Paul Eggert  <eggert@twinsun.com>
23487
23488         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
23489         to avoid collisions with libcurses and libreadline.
23490
23491         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
23492         * lib/getstr.h, getstr.c: Remove.
23493         * lib/getline.c: Include "getline.h", to check interface.
23494         Move body of old getstr.c here: this defines MIN_CHUNK and
23495         declares getdelim2, which is renamed from getstr.
23496         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
23497
23498         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
23499         All uses changed.
23500         * lib/linebuffer.h: Likewise.
23501         (readline): Remove backward-compatibility macro.
23502
23503 2003-01-12  Paul Eggert  <eggert@twinsun.com>
23504
23505         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
23506         to avoid collisions with libcurses and libreadline.
23507         * getstr: Remove.
23508         * MODULES.html.sh: Remove getstr.
23509         * modules/getline: Depend on unlocked-io, not getstr.
23510
23511 2003-01-12  Jim Meyering  <jim@meyering.net>
23512
23513         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
23514
23515 2003-01-10  Bruno Haible  <bruno@clisp.org>
23516
23517         * modules/alloca: Change Makefile.am requirements. Simplify Include
23518         requirements. Add lib/alloca_.h to file list.
23519
23520 2003-01-10  Bruno Haible  <bruno@clisp.org>
23521
23522         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
23523
23524 2003-01-10  Bruno Haible  <bruno@clisp.org>
23525
23526         * lib/alloca_.h: New file.
23527         * lib/getdate.y: Unconditionally include alloca.h.
23528         * lib/makepath.c: Likewise.
23529         * lib/setenv.c: Likewise.
23530         * lib/userspec.c: Likewise.
23531
23532 2003-01-09  Karl Berry  <karl@gnu.org>
23533
23534         * MODULES.html.sh: include `dirname $0` in PATH, to find
23535         gnulib-tool.
23536
23537 2003-01-09  Bruno Haible  <bruno@clisp.org>
23538
23539         * modules/stdbool: Change configure.ac, Makefile.am requirements.
23540         Simplify Include requirements. Add lib/stdbool.h.in to file list.
23541
23542 2003-01-09  Bruno Haible  <bruno@clisp.org>
23543
23544         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
23545
23546 2003-01-09  Bruno Haible  <bruno@clisp.org>
23547
23548         * lib/stdbool.h.in: New file.
23549
23550 2003-01-09  Bruno Haible  <bruno@clisp.org>
23551
23552         * gnulib-tool (func_all_modules): Ignore files ending in ~.
23553         * MODULES.html.sh: Likewise.
23554
23555 2003-01-08  Jim Meyering  <jim@meyering.net>
23556
23557         * lib/full-write.c: Undefine and define-away `const' after inclusion
23558         of errno.h, not before.  Suggestion from Bruno Haible.
23559
23560 2003-01-08  Bruno Haible  <bruno@clisp.org>
23561
23562         * modules/full-read: Depend on full-write.
23563
23564 2003-01-08  Bruno Haible  <bruno@clisp.org>
23565
23566         * lib/safe-read.c: Include specification header first, to ensure its
23567         selfcontainedness.
23568         * lib/full-write.c: Likewise.
23569
23570 2003-01-07  Jim Meyering  <jim@meyering.net>
23571
23572         * lib/full-write.c: Rework so that it may serve to define full_read,
23573         too.
23574         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
23575
23576 2003-01-07  Bruno Haible  <bruno@clisp.org>
23577
23578         * lib/strtoimax.c: Include <stdint.h> as an alternative to
23579         <inttypes.h>.
23580         * lib/xstrtol.h: Likewise.
23581         * lib/xstrtoimax.c: Likewise.
23582         * lib/xstrtoumax.c: Likewise.
23583         * lib/human.h: Likewise.
23584
23585         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
23586         on systems that have <inttypes.h> but not <stdint.h>.
23587
23588 2003-01-07  Bruno Haible  <bruno@clisp.org>
23589
23590         * MODULES.html.sh: Add copyright notice.
23591         (missed_files): Omit CVS directory entries.
23592         (func_module): Make it work with sed-3.02.
23593         * MODULES.txt: Remove file.
23594
23595 2003-01-06  Jim Meyering  <jim@meyering.net>
23596
23597         * lib/version-etc.c: Update year in translatable copyright string.
23598
23599 2003-01-03  Karl Berry  <karl@gnu.org>
23600
23601         * config/config.{guess,sub}: update from prep.
23602
23603 2003-01-02  Karl Berry  <karl@gnu.org>
23604
23605         * doc/COPYING.DOC: belatedly updated to 1.2.
23606
23607 2003-01-01  Karl Berry  <karl@gnu.org>
23608
23609         * gnulib-tool (func_verify_module): report module name $module in
23610         error message, not $1.
23611         * gnulib-tool (create-testdir): don't complain if destdir couldn't
23612         be created, only if it doesn't exist.
23613         * gnulib-tool (last_checkin_date): don't expand the $Date here.
23614
23615 2002-12-31  Paul Eggert  <eggert@twinsun.com>
23616
23617         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
23618
23619 2002-12-31  Paul Eggert  <eggert@twinsun.com>
23620
23621         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
23622         memcmp if strcoll doesn't work.
23623
23624 2002-12-31  Bruno Haible  <bruno@clisp.org>
23625
23626         * lib/utime.c (utime_null): No need to call ftruncate if the file was
23627         nonempty.
23628
23629 2002-12-31  Bruno Haible  <bruno@clisp.org>
23630
23631         * lib/memcoll.c (STRCOLL): New macro.
23632         (memcoll): Use it.
23633
23634 2002-12-31  Bruno Haible  <bruno@clisp.org>
23635
23636         * lib/localcharset.h: New file.
23637         * lib/localcharset.c: Include it.
23638         * lib/unicodeio.c: Likewise.
23639
23640 2002-12-31  Bruno Haible  <bruno@clisp.org>
23641
23642         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
23643         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
23644
23645 2002-12-31  Bruno Haible  <bruno@clisp.org>
23646
23647         * lib/getline.h: Include <stddef.h>, for size_t.
23648
23649         * lib/unicodeio.h: Include <stddef.h>, for size_t.
23650         * lib/unicodeio.c: Don't include <stddef.h>.
23651
23652 2002-12-31  Bruno Haible  <bruno@clisp.org>
23653
23654         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
23655         HAVE_TM_ZONE.
23656
23657 2002-12-24  Karl Berry  <karl@gnu.org>
23658
23659         * config/config.guess: update from prep.
23660
23661 2002-12-24  Bruno Haible  <bruno@clisp.org>
23662
23663         General infrasructure.
23664         * m4/README: Rewritten.
23665         * m4/onceonly.m4: New file.
23666         * m4/onceonly_2_57.m4: New file.
23667
23668         Module atexit.
23669         * m4/atexit.m4: New file.
23670
23671         Module strtod.
23672         * m4/strtod.m4: New file.
23673
23674         Module strtol.
23675         * m4/strtol.m4: New file.
23676
23677         Module strtoul.
23678         * m4/strtoul.m4: New file.
23679
23680         Module memchr.
23681         * m4/memchr.m4: New file.
23682
23683         Module memcmp.
23684         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
23685         (jm_FUNC_MEMCMP): Invoke it.
23686
23687         Module memcpy.
23688         * m4/memcpy.m4: New file.
23689
23690         Module memmove.
23691         * m4/memmove.m4: New file.
23692
23693         Module memset.
23694         * m4/memset.m4: New file.
23695
23696         Module strcspn.
23697         * m4/strcspn.m4: New file.
23698
23699         Module strpbrk.
23700         * m4/strpbrk.m4: New file.
23701
23702         Module strstr.
23703         * m4/strstr.m4: New file.
23704
23705         Module strerror.
23706         * m4/strerror.m4: New file.
23707
23708         Module mktime.
23709         * m4/mktime.m4: Renamed from jm-mktime.m4.
23710         (gl_PREREQ_MKTIME): New macro.
23711         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
23712
23713         Module malloc.
23714         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
23715         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
23716         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
23717
23718         Module realloc.
23719         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
23720         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
23721         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
23722
23723         Module strftime.
23724         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
23725         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
23726         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
23727         gl_TM_GMTOFF.
23728         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
23729
23730         Module xalloc.
23731         * m4/xalloc.m4: New file.
23732
23733         Module alloca.
23734         * m4/alloca.m4: New file.
23735
23736         Module putenv.
23737         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
23738         (jm_FUNC_PUTENV): Invoke it.
23739
23740         Module setenv.
23741         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
23742         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
23743         when invoked twice.
23744         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
23745         gt_FUNC_SETENV.
23746
23747         Module memrchr.
23748         * m4/memrchr.m4: New file.
23749
23750         Module stpcpy.
23751         * m4/stpcpy.m4: New file.
23752
23753         Module strcase.
23754         * m4/strcase.m4: New file.
23755
23756         Module strdup.
23757         * m4/strdup.m4: New file.
23758
23759         Module strnlen.
23760         * m4/strnlen.m4: New file.
23761
23762         Module strndup.
23763         * m4/strndup.m4: New file.
23764
23765         Module xstrtod.
23766         * m4/xstrtod.m4: New file.
23767
23768         Module xstrtol.
23769         * m4/xstrtol.m4: New file.
23770
23771         Module getdate.
23772         * m4/getdate.m4: New file.
23773
23774         Module unlocked-io.
23775         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
23776         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
23777         * m4/jm-glibc-io.m4n: Remove file.
23778
23779         Module long-options.
23780         * m4/long-options.m4: New file.
23781
23782         Module md5.
23783         * m4/md5.m4: New file.
23784
23785         Module sha.
23786         * m4/sha.m4: New file.
23787
23788         Module getstr.
23789         * m4/getstr.m4: New file.
23790
23791         Module getline.
23792         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
23793         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
23794         <sys/types.h>, for size_t. Use the function name gnu_getline, not
23795         simply getline. Infoke gl_PREREQ_GETLINE.
23796
23797         Module obstack.
23798         * m4/obstack.m4: New file.
23799
23800         Module hash.
23801         * m4/hash.m4: New file.
23802
23803         Module readtokens.
23804         * m4/readtokens.m4: New file.
23805
23806         Module strverscmp.
23807         * m4/strverscmp.m4: New file.
23808
23809         Module stdbool.
23810         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
23811         OSF/1.
23812
23813         Module strtoll.
23814         * m4/strtoll.m4: New file.
23815
23816         Module strtoull.
23817         * m4/strtoull.m4: New file.
23818
23819         Module strtoimax.
23820         * m4/strtoimax.m4: New file.
23821
23822         Module strtoumax.
23823         * m4/strtoumax.m4: New file.
23824
23825         Module xstrtoimax.
23826         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
23827         jm_AC_PREREQ_XSTRTOIMAX.
23828         Moved the strtol prerequisites to strtol.m4.
23829         Moved the strtoll prerequisites to strtoll.m4.
23830         Moved the strtoimax prerequisites to strtoimax.m4.
23831
23832         Module xstrtoumax.
23833         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
23834         jm_AC_PREREQ_XSTRTOUMAX.
23835         Moved the strtoul prerequisites to strtoul.m4.
23836         Moved the strtoull prerequisites to strtoull.m4.
23837         Moved the strtoumax prerequisites to strtoumax.m4.
23838
23839         Module chown.
23840         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
23841         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
23842
23843         Module dup2.
23844         * m4/dup2.m4: New file.
23845
23846         Module ftruncate.
23847         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
23848         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
23849
23850         Module getgroups.
23851         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
23852         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
23853
23854         Module gettimeofday.
23855         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
23856         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
23857         gl_PREREQ_GETTIMEOFDAY.
23858
23859         Module mkdir.
23860         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
23861         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
23862
23863         Module mkstemp.
23864         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
23865         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
23866         jm_AC_TYPE_UINTMAX_T.
23867         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
23868
23869         Module stat.
23870         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
23871         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
23872
23873         Module lstat.
23874         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
23875         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
23876
23877         Module timespec.
23878         * m4/timespec.m4 (gl_TIMESPEC): New macro.
23879         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
23880         * m4/st_mtim.m4: Indentation.
23881
23882         Module nanosleep.
23883         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
23884         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
23885         gl_PREREQ_NANOSLEEP.
23886
23887         Module regex.
23888         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
23889         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
23890         (gl_REGEX): New macro.
23891
23892         Module rename.
23893         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
23894         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
23895
23896         Module rmdir.
23897         * m4/rmdir.m4: New file.
23898
23899         Module utime.
23900         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
23901         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
23902         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
23903
23904         Module dirname.
23905         * m4/dirname.m4: New file.
23906
23907         Module getopt.
23908         * m4/getopt.m4: New file.
23909
23910         Module unistd-safer.
23911         * m4/unistd-safer.m4: New file.
23912
23913         Module fnmatch.
23914         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
23915         declaration.
23916         (gl_PREREQ_FNMATCH_EXTRA): New macro.
23917         (gl_FUNC_FNMATCH_POSIX): New macro.
23918         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
23919         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
23920         simply fnmatch.
23921
23922         Module exclude.
23923         * m4/exclude.m4: New file.
23924
23925         Module human.
23926         * m4/human.m4: New file.
23927
23928         Module acl.
23929         * m4/acl.m4: Nop.
23930
23931         Module backupfile.
23932         * m4/backupfile.m4: New file.
23933         * m4/d-ino.m4: Indentation.
23934
23935         Module fsusage.
23936         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
23937         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
23938         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
23939
23940         Module dirfd.
23941         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
23942         requirements.
23943
23944         Module euidaccess.
23945         * m4/euidaccess.m4: New file.
23946
23947         Module file-type.
23948         * m4/file-type.m4: New file.
23949
23950         Module fileblocks.
23951         * m4/fileblocks.m4: New file.
23952
23953         Module filemode.
23954         * m4/filemode.m4: New file.
23955
23956         Module isdir.
23957         * m4/isdir.m4: New file.
23958
23959         Module lchown.
23960         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
23961         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
23962
23963         Module makepath.
23964         * m4/makepath.m4: New file.
23965
23966         Module modechange.
23967         * m4/modechange.m4: New file.
23968
23969         Module mountlist.
23970         * m4/mountlist.m4: New file.
23971         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
23972         Indentation.
23973
23974         Module path-concat.
23975         * m4/path-concat.m4: New file.
23976
23977         Module pathmax.
23978         * m4/pathmax.m4: New file.
23979
23980         Module same.
23981         * m4/same.m4: New file.
23982
23983         Module save-cwd.
23984         * m4/save-cwd.m4: New file.
23985
23986         Module savedir.
23987         * m4/savedir.m4: New file.
23988
23989         Module xgetcwd.
23990         * m4/xgetcwd.m4: New file.
23991         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
23992
23993         Module xreadlink.
23994         * m4/xreadlink.m4: New file.
23995
23996         Module safe-read.
23997         * m4/safe-read.m4: New file.
23998
23999         Module safe-write.
24000         * m4/safe-write.m4: New file.
24001
24002         Module closeout.
24003         * m4/closeout.m4: New file.
24004
24005         Module stdio-safer.
24006         * m4/stdio-safer.m4: New file.
24007
24008         Module getpass.
24009         * m4/getpass.m4: New file.
24010
24011         Module getugroups.
24012         * m4/getugroups.m4: New file.
24013
24014         Module group-member.
24015         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
24016         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
24017
24018         Module idcache.
24019         * m4/idcache.m4: New file.
24020
24021         Module userspec.
24022         * m4/userspec.m4: New file.
24023
24024         Module gettime.
24025         * m4/clock_time.m4: New file.
24026         * m4/gettime.m4: New file.
24027
24028         Module settime.
24029         * m4/settime.m4: New file.
24030
24031         Module posixtm.
24032         * m4/posixtm.m4: New file.
24033
24034         Module gethostname.
24035         * m4/gethostname.m4: New file.
24036
24037         Module canon-host.
24038         * m4/canon-host.m4: New file.
24039
24040         Module gettext.
24041         * m4/codeset.m4: New file, from gettext-0.11.5.
24042         * m4/gettext.m4: New file, from gettext-0.11.5.
24043         * m4/glibc21.m4: New file, from gettext-0.11.5.
24044         * m4/iconv.m4: New file, from gettext-0.11.5.
24045         * m4/intdiv0.m4: New file, from gettext-0.11.5.
24046         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
24047         * m4/inttypes.m4: New file, from gettext-0.11.5.
24048         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
24049         * m4/isc-posix.m4: New file, from gettext-0.11.5.
24050         * m4/lcmessage.m4: New file, from gettext-0.11.5.
24051         * m4/lib-ld.m4: New file, from gettext-0.11.5.
24052         * m4/lib-link.m4: New file, from gettext-0.11.5.
24053         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
24054         * m4/progtest.m4: New file, from gettext-0.11.5.
24055         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
24056         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
24057         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
24058
24059         Module localcharset.
24060         * m4/localcharset.m4: New file.
24061
24062         Module hard-locale.
24063         * m4/hard-locale.m4: New file.
24064
24065         Module mbswidth.
24066         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
24067         onceonly macros.
24068         * m4/mbrtowc.m4: Add comment.
24069
24070         Module memcasecmp.
24071         * m4/memcasecmp.m4: New file.
24072
24073         Module memcoll.
24074         * m4/memcoll.m4: New file.
24075
24076         Module unicodeio.
24077         * m4/unicodeio.m4: New file.
24078
24079         Module rpmatch.
24080         * m4/rpmatch.m4: New file.
24081
24082         Module yesno.
24083         * m4/yesno.m4: New file.
24084
24085         Module exitfail.
24086         * m4/exitfail.m4: New file.
24087
24088         Module c-stack.
24089         * m4/c-stack.m4 (gl_C_STACK): New macro.
24090         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
24091
24092         Module error.
24093         * m4/error.m4 (gl_ERROR): New macro.
24094         (jm_PREREQ_ERROR): Use onceonly macros.
24095
24096         Module fatal.
24097         * m4/fatal.m4: New file.
24098
24099         Module getloadavg.
24100         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
24101         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
24102
24103         Module getpagesize.
24104         * m4/getpagesize.m4: New file.
24105
24106         Module getusershell.
24107         * m4/getusershell.m4: New file.
24108
24109         Module physmem.
24110         * m4/physmem.m4: New file.
24111
24112         Module posixver.
24113         * m4/posixver.m4: New file.
24114
24115         Module quotearg.
24116         * m4/quotearg.m4: New file.
24117
24118         Module quote.
24119         * m4/quote.m4: New file.
24120
24121         Module readutmp.
24122         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
24123
24124         Module sig2str.
24125         * m4/sig2str.m4: New file.
24126
24127         Other.
24128         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
24129         ulonglong.m4.
24130         * m4/intmax_t.m4: New file.
24131         * m4/d-type.m4: Indentation.
24132         * m4/jm-macros.m4: Update.
24133         * m4/prereq.m4 (jm_PREREQ): Update.
24134         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
24135         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
24136         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
24137         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
24138         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
24139         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
24140         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
24141         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
24142         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
24143         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
24144         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
24145         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
24146         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
24147         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
24148         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
24149         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
24150         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
24151         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
24152         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
24153
24154 2002-12-24  Bruno Haible  <bruno@clisp.org>
24155
24156         * MODULES.txt: Update according to m4/ changes.
24157
24158         Module gettext.
24159         * config.rpath: New file, from gettext-0.11.5.
24160
24161         * modules/*: New module descriptions.
24162         * gnulib-tool: New file.
24163         * MODULES.html.sh: New file.
24164
24165 2002-12-21  Karl Berry  <karl@gnu.org>
24166
24167         * doc/fdl.texi: update to version 1.2.
24168
24169 2002-12-19  Karl Berry  <karl@gnu.org>
24170
24171         * config/config.guess: update from prep.
24172
24173 2002-12-18  Bruno Haible  <bruno@clisp.org>
24174
24175         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
24176         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
24177
24178 2002-12-17  Bruno Haible  <bruno@clisp.org>
24179
24180         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
24181         stdlib.h, string.h.
24182
24183 2002-12-17  Bruno Haible  <bruno@clisp.org>
24184
24185         * lib/canon-host.c (strdup): Remove unused declaration.
24186
24187         * lib/fsusage.c: Include full_read.h.
24188         (get_fs_usage): Use full_read instead of safe_read.
24189
24190         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
24191
24192 2002-12-12  Karl Berry  <karl@gnu.org>
24193
24194         * config/config.guess: update from prep.
24195
24196 2002-12-11  Bruno Haible  <bruno@clisp.org>
24197
24198         * m4/setenv.m4: New file, from gettext-0.11.5.
24199
24200 2002-12-11  Bruno Haible  <bruno@clisp.org>
24201
24202         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
24203         not unsetenv().
24204         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
24205         modifications:
24206
24207         2002-12-11  Bruno Haible  <bruno@clisp.org>
24208
24209                 * setenv.c (alloca): Fall back to malloc.
24210                 (freea): New macro.
24211                 (setenv): Use freea() to free memory allocated with alloca().
24212
24213         2002-11-13  Bruno Haible  <bruno@clisp.org>
24214
24215                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
24216                 function declarations.
24217                 * unsetenv.c (unsetenv): Likewise.
24218
24219         2002-03-04  Bruno Haible  <bruno@clisp.org>
24220
24221                 Portability to AIX 4.3.3.
24222                 * unsetenv.c: New file, extracted from setenv.c.
24223                 * setenv.c: Move the unsetenv() function to unsetenv.c.
24224
24225         2001-12-20  Bruno Haible  <bruno@clisp.org>
24226
24227                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
24228                 use malloc instead. For SunOS 4.
24229
24230         2001-12-11  Bruno Haible  <bruno@clisp.org>
24231
24232                 * setenv.c: Declare alloca.
24233                 (compar_fn_t): New typedef.
24234                 (KNOWN_VALUE, STORE_VALUE): Use it.
24235
24236         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
24237         setenv.h.
24238
24239 2002-12-10  Paul Eggert  <eggert@twinsun.com>
24240
24241         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
24242         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
24243         Choose values that are less likely to collide with system fnmatch
24244         options.
24245         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
24246         defined (e.g., a pure POSIX system).
24247         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
24248         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
24249
24250 2002-12-06  Paul Eggert  <eggert@twinsun.com>
24251
24252         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
24253         a pain in practice to deal with generated m4 files.  This change
24254         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
24255
24256         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
24257         and jm-glibc-io.m4, as they are no longer a special case.
24258         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
24259         kludge and the auto-generation stuff.  Check only whether the
24260         functions are declared, not whether they exist, since older hosts
24261         that don't declare the functions can't use the optimization anyway.
24262
24263 2002-12-06  Jim Meyering  <jim@meyering.net>
24264
24265         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
24266
24267         Merge in changes from libc's misc/error.c, in preparation
24268         for the merge of gnulib's changes back into libc.
24269
24270         * lib/error.c (_): Define only if not already defined.
24271         Move definition to follow all #include directives.
24272         Include unlocked-io.h only if !_LIBC.
24273         [_LIBC]: Include <libio/libioP.h>.
24274         [USE_IN_LIBIO]: Include <libio/iolibio.h>
24275         (fflush): Tweak definition to use INTUSE.
24276         (putc): Define.
24277
24278 2002-12-05  Paul Eggert  <eggert@twinsun.com>
24279
24280         * lib/alloca.c [defined emacs]: Include "lisp.h".
24281         (xalloc_die) [defined emacs]: New macro.
24282         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
24283         [! defined emacs]: Include <xalloc.h>.
24284         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
24285         (pointer): Typedef to POINTER_TYPE *.
24286         (malloc): Remove decl; we now always use xmalloc.
24287         (alloca): Use old-style definition, since Emacs needs this.
24288         Check for arithmetic overflow when computing combined size.
24289
24290 2002-12-04  Paul Eggert  <eggert@twinsun.com>
24291
24292         Do not generate unlocked-io.h automatically, since it's easier to
24293         maintain it by hand.
24294
24295         * lib/unlocked-io.h: New file, from GNU diffutils,
24296         but with proper copyright notice and attribution.
24297         * lib/gen-uio: Remove.
24298         * lib/Makefile.am: Add copyright notice.
24299         (libfetish_a_SOURCES): Add unlocked-io.h.
24300         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
24301         (DISTCLEANFILES, io_functions): Remove macros.
24302         (EXTRA_DIST): Remove gen_uio.
24303         (unlocked-io.h): Remove rule.
24304
24305 2002-12-04  Jim Meyering  <jim@meyering.net>
24306
24307         Reflect the fact that stat.c and lstat.c are no longer generated.
24308         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
24309         (DISTCLEANFILES): Likewise.
24310         (EXTRA_DIST): Likewise.
24311         (all_local): Don't depend on stat.c or lstat.c.
24312         (stat.c, lstat.c): Remove rules.
24313         (EXTRA_DIST): Remove xstat.in.
24314
24315         * lib/xstat.in: Remove file.  Contents moved into stat.c.
24316         * lib/stat.c: New file.  Contents mostly from xstat.in.
24317         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
24318         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
24319
24320         * lib/safe-read.c: Rework so that it may serve to define safe_write,
24321         too.
24322         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
24323
24324 2002-12-03  Jim Meyering  <jim@meyering.net>
24325
24326         * lib/safe-read.c, safe-write.c: Change variable names and comments,
24327         but not semantics, to minimize the differences between these two files.
24328         (safe_read): Change comment to mention SAFE_READ_ERROR.
24329
24330         * lib/safe-read.c (IS_EINTR): Define.
24331         (safe_read): Use IS_EINTR in place of in-function cpp directives.
24332
24333 2002-12-02  Jim Meyering  <jim@meyering.net>
24334
24335         * lib/safe-read.c (EINTR): Define.
24336         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
24337         (INT_MAX): Provide fallback.
24338         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
24339
24340         * lib/safe-read.h (SAFE_READ_ERROR): Define.
24341
24342 2002-12-02  Bruno Haible  <bruno@clisp.org>
24343
24344         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
24345         Define, taken from safe-read.c.
24346         (INT_MAX): Provide fallback.
24347         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
24348         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
24349
24350         * lib/safe-read.c (EINTR): Remove definition.
24351         (safe_read): Don't use EINTR if it is absent.
24352
24353 2002-12-01  Jim Meyering  <jim@meyering.net>
24354
24355         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
24356         zero.
24357         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
24358
24359 2002-11-27  Paul Eggert  <eggert@twinsun.com>
24360
24361         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
24362         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
24363         with `if (! (value < limit)) abort ();', for readability.
24364
24365 2002-11-26  Karl Berry  <karl@gnu.org>
24366
24367         * lib/strdup.c: copy from libc again, with jim's ok.
24368         * lib/.cppi-disable: re-add strdup.c
24369
24370 2002-11-25  Karl Berry  <karl@gnu.org>
24371
24372         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
24373         instead of "strtol.c".
24374
24375 2002-11-25  Karl Berry  <karl@gnu.org>
24376
24377         * config/install-sh: update from automake for variable quoting, $0 in
24378         error msgs, etc.
24379
24380         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
24381         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
24382         entry.
24383
24384 2002-11-25  Jim Meyering  <jim@meyering.net>
24385
24386         * lib/mktime.c: Sync from libc, now that it has the latest fix.
24387
24388 2002-11-24  Karl Berry  <karl@gnu.org>
24389
24390         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
24391         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
24392
24393 2002-11-24  Jim Meyering  <jim@meyering.net>
24394
24395         Update from coreutils:
24396
24397         * lib/mktime.c: Merge in changes from libc.
24398
24399         Avoid a link-time failure on some Linux systems.
24400         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
24401         (otherwise).
24402         (__mon_yday): Declare with the STATIC attribute.
24403         (__mktime_internal): Likewise.
24404         Based on a report from Greg Schafer.
24405
24406 2002-11-23  Jim Meyering  <jim@meyering.net>
24407
24408         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
24409         Use `unsigned', not `int', as type of index.
24410
24411         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
24412
24413         * lib/fsusage.c: Remove unneeded parentheses around operands of
24414         `defined'.
24415
24416 2002-11-22  Paul Eggert  <eggert@twinsun.com>
24417
24418         * lib/quotearg.h: Allow multiple inclusion by surrounding with
24419         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
24420         so that we can be included first.
24421         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
24422         * lib/quotearg.c: Include quotearg.h immediately after config.h.
24423         No need to include stddef.h or sys/types.h any more.
24424         Surround local include files with "", not "<>".
24425         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
24426         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
24427         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
24428         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
24429         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
24430         (ISPRINT): Remove; no longer needed now that we assume C89.
24431
24432         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
24433         Preserve errno.
24434
24435         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
24436         quotearg_char): Use SIZE_MAX rather than
24437         (size_t) -1 when we are talking about "infinity".
24438
24439         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
24440
24441 2002-11-22  Paul Eggert  <eggert@twinsun.com>
24442
24443         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
24444         hint that one should use `if (! x) abort ();' rather than `assert
24445         (x);', and anyway it's one less thing to worry about configuring.
24446         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
24447         hash_rehash, hash_insert): Use abort rather than assert.
24448
24449 2002-11-22  Bruno Haible  <bruno@clisp.org>
24450
24451         * lib/safe-read.h: Assume C89. Add comments.
24452         (safe_read): Change return type to size_t.
24453         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
24454         byte counts > SSIZE_MAX correctly.
24455         * lib/safe-write.h: New file.
24456         * lib/safe-write.c: New file.
24457         * lib/full-read.h: New file.
24458         * lib/full-read.c: New file.
24459         * lib/full-write.h: Assume C89. Add comments.
24460         * lib/full-write.c: Include safe-write.h.
24461         (full_write): Rewritten to use safe_write.
24462         Suggested by Jim Meyering and Paul Eggert.
24463
24464 2002-11-21  Jim Meyering  <jim@meyering.net>
24465
24466         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
24467
24468         Merge in changes from the coreutils.
24469
24470         2002-09-25  Paul Eggert  <eggert@twinsun.com>
24471         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
24472         <stdint.h>.
24473         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
24474         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
24475         int.  Work more efficiently if X is the same width as uintmax_t.
24476         Do not compare X to -1, to avoid bogus compiler warning.
24477         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
24478         Don't assume that f_frsize and f_bsize are the same type.
24479
24480         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
24481         warning on FreeBSD.
24482
24483         * lib/makepath.c (make_path): Restore umask *before* creating the final
24484         component.
24485         (make_path): Minor reformatting.
24486
24487         * lib/xmalloc.c: Adjust to work with new autoconf macros,
24488         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
24489         HAVE_MALLOC/HAVE_REALLOC.
24490
24491         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
24492         dummy ones.  At least on GNU/Linux systems, `auto' means something
24493         else.
24494         From Michael Stone.
24495
24496 2002-11-21  Bruno Haible  <bruno@clisp.org>
24497
24498         Remove case insensitive option matching.
24499         * lib/argmatch.h (argcasematch): Remove declaration.
24500         (ARGCASEMATCH): Remove macro.
24501         (__xargmatch_internal): Remove case_sensitive argument.
24502         (XARGMATCH): Update.
24503         (XARGCASEMATCH): Remove macro.
24504         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
24505         case_sensitive argument.
24506         (argcasematch): Remove function.
24507         (__xargmatch_internal): Remove case_sensitive argument.
24508         (main): Use XARGMATCH instead of XARGCASEMATCH.
24509
24510         * lib/xmalloc.c: Change compile-time error message. Add comment about
24511         required autoconf version.
24512
24513 2002-11-20  Paul Eggert  <eggert@twinsun.com>
24514
24515         Merge argmatch cleanups from Bison.  Assume C89.
24516
24517         * lib/argmatch.c: Include config.h here, not in argmatch.h.
24518         Include stdlib.h, for EXIT_FAILURE.
24519         Always include <string.h>, since we assume C89.
24520         (EXIT_FAILURE): Remove pre-C89 bug workaround.
24521         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
24522         Include <stddef.h> instead, since it's all we need for size_t.
24523         (PARAMS): Remove.  All uses removed.
24524         (ARRAY_CARDINALITY): Do not bother to #undef.
24525         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
24526         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
24527         Remove unnecessary parentheses.
24528         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
24529         Insert necessary parentheses.
24530         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
24531         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
24532
24533 2002-11-19  Bruno Haible  <bruno@clisp.org>
24534
24535         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
24536         * lib/mbswidth.h: Include <stddef.h>, for size_t.
24537
24538         * lib/mbswidth.h (PARAMS): Remove macro.
24539         (mbswidth, mbsnwidth): Use ANSI C function declarations.
24540         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
24541
24542         * lib/gcd.h (PARAMS): Remove macro.
24543         (gcd): Use ANSI C function declarations.
24544         * lib/gcd.c (gcd): Likewise.
24545
24546 2002-11-15  Bruno Haible  <bruno@clisp.org>
24547
24548         * lib/strcspn.c: Include <stddef.h>.
24549         (strcspn): Use ANSI C function declaration. Change return type to
24550         size_t. Use NULL.
24551         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
24552         (strpbrk): Use NULL.
24553         * lib/strpbrk.h (PARAMS): Remove macro.
24554         (strpbrk): Use ANSI C function declaration.
24555         * lib/strstr.c: Don't include <sys/types.h>.
24556         * lib/strstr.h (PARAMS): Remove macro.
24557         (strstr): Use ANSI C function declarations.
24558
24559 2002-11-14  Karl Berry  <karl@gnu.org>
24560
24561         * config/mkinstalldirs: `do' on separate line, instead of
24562         `for var; do'.
24563
24564 2002-11-06  Bruno Haible  <bruno@clisp.org>
24565
24566         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
24567         * lib/gcd.c (gcd): Likewise.
24568
24569 2002-11-05  Bruno Haible  <bruno@clisp.org>
24570
24571         * lib/gcd.h: New file, from gettext-0.11.5.
24572         * lib/gcd.c: New file, from gettext-0.11.5.
24573
24574 2002-11-05  Bruno Haible  <bruno@clisp.org>
24575
24576         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24577         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24578         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24579         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24580
24581         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
24582         <libintl.h>.
24583         * lib/makepath.c: Include gettext.h instead of <locale.h> and
24584         <libintl.h>.
24585
24586         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
24587         * lib/human.c: Include gettext.h instead of <libintl.h>.
24588         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
24589         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
24590         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
24591         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
24592         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
24593         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
24594         (textdomain): Remove definition.
24595         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
24596
24597         * lib/long-options.c: Remove include of <libintl.h> and definition of
24598         _.
24599         * lib/same.c: Remove include of <libintl.h> and definition of _.
24600
24601 2002-11-04  Owen Taylor  <otaylor@redhat.com>
24602
24603         * lib/config.charset: A few additions for Solaris.
24604
24605 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
24606
24607         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
24608         * lib/localcharset.c (locale_charset): Declare as extern "C".
24609
24610 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
24611
24612         * lib/config.charset: msdos in uk_UA uses CP1125.
24613
24614 2002-11-04  Bruno Haible  <bruno@clisp.org>
24615
24616         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
24617         * lib/strcase.h: New file, from GNU gettext-0.11.5.
24618         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
24619         * lib/strstr.h: New file, from GNU gettext-0.11.5.
24620         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
24621
24622 2002-11-04  Bruno Haible  <bruno@clisp.org>
24623
24624         * lib/localcharset.c (locale_charset): Don't return an empty string.
24625
24626 2002-11-04  Bruno Haible  <bruno@clisp.org>
24627
24628         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
24629         aliases.
24630
24631 2002-11-04  Bruno Haible  <bruno@clisp.org>
24632
24633         * lib/config.charset: Update for newest glibc. Add canonical names
24634         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
24635
24636 2002-11-04  Bruno Haible  <bruno@clisp.org>
24637
24638         * lib/config.charset: Add support for NetBSD.
24639
24640 2002-11-04  Bruno Haible  <bruno@clisp.org>
24641
24642         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
24643
24644 2002-11-01  Bruno Haible  <bruno@clisp.org>
24645
24646         * configure.in: Add AC_CONFIG_AUX_DIR call.
24647         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
24648         test/Makefile.
24649         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
24650
24651 2002-09-28  Karl Berry  <karl@gnu.org>
24652
24653         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
24654         installed automake until the next release, since changes have been
24655         made.
24656
24657 2002-09-25  Karl Berry  <karl@gnu.org>
24658
24659         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
24660         * lib/getopt*: copy from libc/posix.
24661         * lib/gettext.h: copy from gettext.
24662         * lib/.cppi-disable: add strdup.c, gettext.h.
24663
24664 2002-09-25  Karl Berry  <karl@gnu.org>
24665
24666         * config/srclist.txt: enable gettext.h check.
24667         * config/config.{guess,sub}: update from prep.
24668         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
24669                 from automake 1.6.3.
24670         See srclist*.
24671
24672 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
24673
24674         * regex.c (PATFETCH): Remove the translating fetch.
24675         (PATFETCH_RAW): Rename to PATFETCH.
24676         (set_image_of_range): New fun.
24677         (SET_RANGE_TABLE_WORK_AREA): Use it.
24678         (regex_compile): Don't translate the pattern chars so eagerly.
24679         Only do it when inserting an `exactn' bytecode or when handling
24680         a char-range.
24681         (mutually_exclusive_p): Avoid empty statement.
24682
24683 2002-07-06  Jim Meyering  <meyering@lucent.com>
24684
24685         * m4/README: Don't mention Makefile.am.in.
24686         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
24687
24688 2002-07-01  Jim Meyering  <meyering@lucent.com>
24689
24690         * lib/c-stack.c: Include sys/time.h.
24691         From Volker Borchert.
24692
24693 2002-06-26  Paul Eggert  <eggert@twinsun.com>
24694
24695         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
24696
24697 2002-06-26  Paul Eggert  <eggert@twinsun.com>
24698
24699         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
24700         New macro.  Use it uniformly instead of
24701         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
24702         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
24703         reported by Vin Shelton.
24704
24705 2002-06-22  Paul Eggert  <eggert@twinsun.com>
24706
24707         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
24708         Do not assume SA_SIGINFO behavior.
24709         Bug reported by Jim Meyering on NetBSD 1.5.2.
24710
24711 2002-06-22  Jim Meyering  <meyering@lucent.com>
24712
24713         * m4/c-stack.m4: New file, from diffutils-2.8.2.
24714         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
24715
24716         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
24717         now that configure.ac uses AC_GNU_SOURCE.
24718         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
24719         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
24720
24721         Update to latest tools.  Suggestions from Paul Eggert.
24722         * m4/stdbool.m4: New file, from diffutils-2.8.2.
24723         * m4/gnu-source.m4: Update from diffutils-2.8.2.
24724         * m4/fnmatch.m4: Likewise.
24725         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
24726         to AC_HEADER_STDBOOL
24727
24728 2002-06-22  Jim Meyering  <meyering@lucent.com>
24729
24730         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
24731         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
24732
24733 2002-06-22  Jim Meyering  <meyering@lucent.com>
24734
24735         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
24736
24737         * lib/exitfail.c, exitfail.h: Likewise.
24738         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
24739
24740         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
24741         of fnmatch.h.
24742         (EXTRA_DIST): Add fnmatch_loop.c.
24743         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
24744
24745         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
24746         * lib/fnmatch.c: Update from diffutils-2.8.2.
24747         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
24748         * lib/fnmatch.h: Remove file.
24749
24750 2002-06-21  Jim Meyering  <meyering@lucent.com>
24751
24752         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
24753         * m4/mbrtowc.m4: Likewise.
24754
24755         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
24756         * m4/mbswidth.m4: Reflect name change:
24757         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
24758         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
24759
24760         * m4/lib-link.m4: Update from gettext-0.11.2.
24761         * m4/gettext.m4: Likewise.
24762
24763         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
24764         From Alfred M. Szmidt.
24765
24766 2002-06-18  Paul Eggert  <eggert@twinsun.com>
24767
24768         * lib/file-type.h: Report an error if neither S_ISREG nor
24769         S_IFREG is defined, instead of using a test specific to glibc
24770         2.2.  This should be safe, since POSIX requires S_ISREG and
24771         Unix Version 7 had S_IFREG.  We don't need to check for
24772         <sys/types.h> since we don't use any symbols that it defines.
24773
24774 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
24775
24776         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
24777         $@-t, so that each temporary file name is unique and valid in the first
24778         8 characters, for operation under DOS.
24779
24780 2002-06-15  Paul Eggert  <eggert@twinsun.com>
24781
24782         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
24783
24784 2002-06-15  Jim Meyering  <meyering@lucent.com>
24785
24786         Work even with DJGPP 2.03, which lacks support for symlinks.
24787         From Richard Dawe.
24788         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
24789         is defined.
24790         * lib/lchown.c (S_ISLNK): Likewise.
24791
24792 2002-06-15  Jim Meyering  <meyering@lucent.com>
24793
24794         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
24795         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
24796         have been included before this file.
24797
24798 2002-06-14  Jim Meyering  <meyering@lucent.com>
24799
24800         * lib/file-type.h: Use the version from diffutils-2.8.2.
24801         * lib/file-type.c: Likewise.
24802
24803 2002-06-07  Jim Meyering  <meyering@lucent.com>
24804
24805         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
24806         They're needed at least for NetBSD 1.5.2.
24807         ($statxfs_includes): Include those same headers.
24808         ($statxfs_includes): Include sys/vfs.h if available.
24809         ($statxfs_includes): Likewise for sys/statvfs.h.
24810         Check for the following members in both structs statfs and statvfs:
24811         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
24812
24813 2002-06-01  Jim Meyering  <meyering@lucent.com>
24814
24815         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
24816         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
24817
24818 2002-05-28  Jim Meyering  <meyering@lucent.com>
24819
24820         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
24821         Reported by Volker Borchert.
24822
24823 2002-05-27  Jim Meyering  <meyering@lucent.com>
24824
24825         Fix a problem seen only on nonconforming systems whereby ls.c's
24826         use of localtime, and then of gettimeofday would cause trouble:
24827         the localtime call used to initialize rpl_gettimeofday's save
24828         mechanism would clobber ls's current local time information so
24829         that in any long listing the first file would always be listed
24830         with date 1970-01-01.  Analysis by Volker Borchert.
24831
24832         * lib/gettimeofday.c (localtime): Undefine.
24833         (rpl_localtime): New function.
24834
24835 2002-05-27  Jim Meyering  <meyering@lucent.com>
24836
24837         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
24838         localtime.
24839
24840         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
24841         use the replacement function; it wouldn't resolve at link time.
24842         Reported by Volker Borchert.
24843
24844 2002-05-22  Jim Meyering  <meyering@lucent.com>
24845
24846         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
24847         file-type.h.
24848         * lib/file-type.h: New file.
24849         * lib/file-type.c (file_type): New file/function.  Extracted from
24850         diffutils.
24851
24852 2002-04-30  Jim Meyering  <meyering@lucent.com>
24853
24854         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
24855
24856 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24857
24858         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
24859
24860 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24861
24862         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
24863         Do not check for alloca.h (no longer used) or stdbool.h (was never
24864         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
24865
24866 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24867
24868         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
24869
24870 2002-04-29  Jim Meyering  <meyering@lucent.com>
24871
24872         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
24873         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
24874         Use AC_FUNC_STRNLEN here instead.
24875
24876         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
24877         With autoconf-2.53a, it's part of AC_PROG_CC.
24878
24879 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24880
24881         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
24882         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
24883
24884 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24885
24886         * lib/sig2str.h, lib/sig2str.c: New files.
24887         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
24888
24889 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24890
24891         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
24892         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
24893         of 127, since 64 is the largest conceivable number for ancient
24894         nonstandard hosts.
24895         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
24896
24897 2002-04-28  Jim Meyering  <meyering@lucent.com>
24898
24899         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
24900
24901 2002-04-24  Jim Meyering  <meyering@lucent.com>
24902
24903         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
24904         (jm_PREREQ): Use it.
24905
24906         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
24907         mach/mach.h fcntl.h.
24908         Check for this function: setlocale.
24909
24910 2002-04-24  Jim Meyering  <meyering@lucent.com>
24911
24912         * lib/gettext.h: New file, from Gettext.
24913         * lib/Makefile.am (INCLUDES): Remove -I../intl.
24914         (libfetish_a_SOURCES): Add gettext.h.
24915
24916 2002-04-16  Jim Meyering  <meyering@lucent.com>
24917
24918         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
24919         ut_pid, ut_id, ut_exit.
24920
24921 2002-04-16  Jim Meyering  <meyering@lucent.com>
24922
24923         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
24924         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
24925         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
24926
24927 2002-04-12  Jim Meyering  <meyering@lucent.com>
24928
24929         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
24930         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
24931         existence of the getmntinfo function.  Needed for Darwin 5.3.
24932
24933         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
24934         This is necessary at least on Darwin 5.3.
24935
24936         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
24937         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
24938         strnlen.o in the library, and that makes some versions of ranlib
24939         object.
24940
24941 2002-04-12  Jim Meyering  <meyering@lucent.com>
24942
24943         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
24944
24945 2002-04-09  Jim Meyering  <meyering@lucent.com>
24946
24947         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
24948         to be more precise.  Rather than saying we're checking whether the
24949         function `works', say what we're testing.
24950         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
24951         Reported by Bruno Haible.
24952
24953 2002-03-10  Jim Meyering  <meyering@lucent.com>
24954
24955         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
24956         Suggestion from Santiago Vila.
24957
24958 2002-03-08  Jim Meyering  <meyering@lucent.com>
24959
24960         * lib/rename.c: Mention that this wrapper is needed also on
24961         mips-dec-ultrix4.4 systems.
24962
24963 2002-03-02  Jim Meyering  <meyering@lucent.com>
24964
24965         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
24966         not HAVE_CLOCK_SETTIME.
24967
24968 2002-02-27  Paul Eggert  <eggert@twinsun.com>
24969
24970         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
24971         Check for clock_settime.
24972
24973 2002-02-27  Paul Eggert  <eggert@twinsun.com>
24974
24975         * lib/nanosleep.h: Rename to....
24976         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
24977
24978         * lib/gettime.c: New file.
24979         * lib/settime.c: New file.
24980         * lib/stime.c: Remove.
24981
24982         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
24983         timespec.h.  Remove nanosleep.h.
24984
24985 2002-02-25  Paul Eggert  <eggert@twinsun.com>
24986
24987         * m4/acl.m4: New file.
24988         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
24989         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
24990
24991 2002-02-25  Paul Eggert  <eggert@twinsun.com>
24992
24993         * lib/acl.c, lib/acl.h: New files.
24994         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
24995
24996 2002-02-24  Jim Meyering  <meyering@lucent.com>
24997
24998         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
24999         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
25000         cause trouble.  Reported by Nelson Beebe.
25001
25002 2002-02-23  Paul Eggert  <eggert@twinsun.com>
25003
25004         * lib/path-concat.c (xpath_concat): Reorder code to pacify
25005         compilers that don't know that xalloc_die never returns.
25006
25007 2002-02-20  Jim Meyering  <meyering@lucent.com>
25008
25009         * lib/getdate.c: Regenerate using bison-1.33.
25010
25011 2002-02-17  Jim Meyering  <meyering@lucent.com>
25012
25013         * config/config.guess (main): Don't use `head -1'; it's no longer
25014         portable. Use `sed 1q' instead.
25015
25016 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
25017
25018         * m4/codeset.m4: Upgrade to gettext-0.11.
25019         * m4/gettext.m4: Upgrade to gettext-0.11.
25020         * m4/glibc21.m4: Upgrade to gettext-0.11.
25021         * m4/iconv.m4: Upgrade to gettext-0.11.
25022         * m4/isc-posix.m4: Upgrade to gettext-0.11.
25023         * m4/lcmessage.m4: Upgrade to gettext-0.11.
25024         * m4/lib-ld.m4: New file, from gettext-0.11.
25025         * m4/lib-link.m4: New file, from gettext-0.11.
25026         * m4/lib-prefix.m4: New file, from gettext-0.11.
25027         * m4/progtest.m4: Upgrade to gettext-0.11.
25028
25029 2002-02-15  Paul Eggert  <eggert@twinsun.com>
25030
25031         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
25032         (jm_PREREQ): Use it.
25033
25034 2002-02-15  Paul Eggert  <eggert@twinsun.com>
25035
25036         * lib/posixver.c, lib/posixver.h: New files.
25037         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
25038
25039 2002-02-02  Paul Eggert  <eggert@twinsun.com>
25040             Bruno Haible  <bruno@clisp.org>
25041
25042         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
25043         (fwrite_success_callback): New declaration.
25044         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
25045         print_unicode_char. Call failure callback instead of error.
25046         (fwrite_success_callback): New function.
25047         (exit_failure_callback): New function.
25048         (fallback_failure_callback): New function.
25049         (print_unicode_char): Call unicode_to_mb.
25050
25051 2002-01-26  Jim Meyering  <meyering@lucent.com>
25052
25053         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
25054         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
25055
25056 2002-01-26  Jim Meyering  <meyering@lucent.com>
25057
25058         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
25059
25060 2002-01-22  Paul Eggert  <eggert@twinsun.com>
25061
25062         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
25063
25064 2002-01-22  Jim Meyering  <meyering@lucent.com>
25065
25066         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
25067         Otherwise, some versions of automake would omit the rule that makes
25068         Makefile from Makefile.in.
25069
25070 2002-01-21  Paul Eggert  <eggert@twinsun.com>
25071
25072         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
25073         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
25074         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
25075         (memcoll): Set errno to zero if there is no error.
25076
25077         * lib/quotearg.c (quotearg_buffer_restyled):
25078         Fix bug with quoting buffers containing NUL when backslashing escapes.
25079         This bug was exposed by the other changes in this patch.
25080         (quotearg_n_options): New arg ARGSIZE.
25081         All callers changed.
25082         (quoting_options_from_style): New function.
25083         (quotearg_n_style): Use it.
25084         (quotearg_n_style_mem): New function.
25085
25086         * lib/quotearg.h (quotearg_n_style_mem): New function.
25087
25088 2002-01-19  Jim Meyering  <meyering@lucent.com>
25089
25090         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
25091         Remove useless quotes: DF_PROG="df".
25092         * m4/strnlen.m4: New file.
25093
25094 2002-01-16  Paul Eggert  <eggert@twinsun.com>
25095
25096         * lib/backupfile.c (ISDIGIT): Comment fix.
25097         * lib/getdate.y (ISDIGIT): Likewise.
25098         * lib/posixtm.c (ISDIGIT, year): Likewise.
25099         * lib/strverscmp.c (ISDIGIT): Likewise.
25100         * lib/userspec.c (ISDIGIT): Likewise.
25101
25102 2002-01-16  Jim Meyering  <meyering@lucent.com>
25103
25104         * lib/getdate.y: Add three semicolons, each just before a closing
25105         brace. Bison (as of version 1.31) no longer papers over that mistake.
25106
25107 2002-01-05  Jim Meyering  <meyering@lucent.com>
25108
25109         * lib/version-etc.c (version_etc_copyright): Update copyright year.
25110
25111 2001-12-19  Paul Eggert  <eggert@twinsun.com>
25112
25113         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
25114         not silently exit merely because the output buffer happens to
25115         have nothing pending.
25116
25117 2001-12-18  Paul Eggert  <eggert@twinsun.com>
25118
25119         See the big note in ../ChangeLog.
25120         * lib/human.c (suffixes): Prefer K to k for 1024.
25121         (generate_suffix_backwards): New function.
25122         (human_readable_inexact): Use it.
25123         * lib/xstrtol.c (__xstrtol): If there is no number but there
25124         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
25125         Accept 'K' as well as 'k'.
25126
25127 2001-12-15  Jim Meyering  <meyering@lucent.com>
25128
25129         * lib/regex.h (__restrict_arr): Update from libc.
25130
25131         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
25132         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
25133         (STREQ): Define.
25134
25135 2001-12-14  Jim Meyering  <meyering@lucent.com>
25136
25137         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
25138         Suggestion from Bruno Haible.
25139
25140 2001-12-10  Jim Meyering  <meyering@lucent.com>
25141
25142         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
25143         xrealloc, Instead, include "xalloc.h".
25144         (initbuffer): Don't cast xmalloc return value to char*.
25145         (readline): Reword comment.
25146         Don't cast xrealloc return value to char*
25147         Return NULL, not 0.
25148
25149 2001-12-09  Jim Meyering  <meyering@lucent.com>
25150
25151         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
25152         about `signed and unsigned type in conditional expression'.
25153         * lib/posixtm.c (posix_time_parse): Likewise.
25154
25155         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
25156
25157         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
25158         to avoid a pedantic warning.
25159
25160         * lib/getstr.c: Don't include assert.h.
25161         (getstr): Remove warning-evoking assertions.
25162         Return -1 if offset parameter is out of bounds.
25163         Change the type of a local from int to size_t.
25164
25165         * lib/strftime.c (my_strftime_localtime_r): Include this function
25166         definition in the `#if ! HAVE_TM_GMTOFF' block.
25167
25168         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
25169         Include xalloc.h instead.
25170
25171 2001-12-02  Jim Meyering  <meyering@lucent.com>
25172
25173         * lib/tempname.c: Don't declare getenv, thus reverting the change of
25174         2001-11-18.  It's no longer necessary, now that stdlib.h is always
25175         included.
25176
25177         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
25178         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
25179
25180 2001-11-30  Akim Demaille  <akim@epita.fr>
25181
25182         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
25183         before being defined.
25184
25185 2001-11-27  Paul Eggert  <eggert@twinsun.com>
25186
25187         * lib/quotearg.h (quotearg_n, quotearg_n_style):
25188         First arg is int, not unsigned.
25189         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
25190         (SIZE_MAX, UINT_MAX): New macros.
25191         (quotearg_n_options): Abort if N is negative.
25192         Avoid overflow check on hosts where size_t is 64 bits and int
25193         is 32 bits, as overflow is impossible there.
25194         Fix off-by-one typo that caused unnecessary reallocation.
25195
25196 2001-11-27  Jim Meyering  <meyering@lucent.com>
25197
25198         * lib/tempname.c: Merge with version from libc.
25199         * lib/regex.c: Likewise.
25200
25201         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
25202         systems for which STDC_HEADERS is 0, it was not included, resulting in
25203         a warning about an integer-to-pointer conversion problem with getenv.
25204         Reported by Volker Borchert.
25205
25206 2001-11-26  Jim Meyering  <meyering@lucent.com>
25207
25208         * lib/gtod.h: Remove file.
25209         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
25210         * lib/gettimeofday.c: Don't include gtod.h.
25211         (GTOD_init): Remove function.
25212         (rpl_gettimeofday): Do its job here instead, rather than aborting.
25213         Suggestion from Volker Borchert.
25214
25215 2001-11-23  Jim Meyering  <meyering@lucent.com>
25216
25217         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
25218         it.
25219         * lib/hash.c (struct hash_table): Define it here instead.
25220
25221 2001-11-22  Jim Meyering  <meyering@lucent.com>
25222
25223         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
25224
25225 2001-11-20  Jim Meyering  <meyering@lucent.com>
25226
25227         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
25228         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
25229
25230 2001-11-19  Jim Meyering  <meyering@lucent.com>
25231
25232         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
25233         directory.  Use "conftestXXXXXX" as the template.
25234         Suggestion from Paul Eggert.
25235
25236         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
25237         immediately, so the test doesn't mistakenly hit the max-open-files
25238         limit.
25239
25240 2001-11-18  Paul Eggert  <eggert@twinsun.com>
25241
25242         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
25243         (TEMPORARIES): New macro.
25244         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
25245         removes an artificial limitation (e.g. HP-UX 10.20, where
25246         TMP_MAX is 17576).
25247
25248 2001-11-18  Jim Meyering  <meyering@lucent.com>
25249
25250         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
25251
25252 2001-11-18  Jim Meyering  <meyering@lucent.com>
25253
25254         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
25255         on SunOS 4.
25256
25257         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
25258         files will be created before anything else.
25259
25260 2001-11-17  Paul Eggert  <eggert@twinsun.com>
25261
25262         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
25263         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
25264
25265 2001-11-17  Jim Meyering  <meyering@lucent.com>
25266
25267         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
25268         Prompted by a report from Bob Proulx.
25269
25270         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
25271         Instead, require UTILS_FUNC_MKSTEMP.
25272
25273 2001-11-17  Jim Meyering  <meyering@lucent.com>
25274
25275         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
25276         Now, that's done as part of AC_FUNC_STRTOD.
25277
25278 2001-11-17  Jim Meyering  <meyering@lucent.com>
25279
25280         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
25281         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
25282         rather than group writable.  Patch by Juan F. Codagnone.
25283
25284         * lib/readtokens.c: Remove explicit declarations of xmalloc and
25285         xrealloc, Instead, include "xalloc.h".
25286
25287         * lib/mountlist.c: Include unlocked-io.h after all system headers.
25288         Remove explicit declarations of xmalloc, xrealloc,
25289         and xstrdup.  Instead, include "xalloc.h".
25290
25291         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
25292         unlocked-io.h.
25293         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
25294         Likewise.
25295         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
25296
25297         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
25298         Reported by Padraig Brady.
25299
25300         * lib/mkstemp.c: #undef mkstemp.
25301         Include config.h.
25302         (rpl_mkstemp): Rename from mkstemp.
25303         Protoize.
25304
25305 2001-11-16  Jim Meyering  <meyering@lucent.com>
25306
25307         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
25308         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
25309         determine the amount of total physical memory, use pstat_getstatic.
25310         HPUX-11 doesn't define _SC_PHYS_PAGES.
25311         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
25312         If sysconf couldn't be used to determine the amount of available
25313         physical memory, use both pstat_getstatic and pstat_getdynamic.
25314         Based on a patch from Bob Proulx.
25315
25316 2001-11-10  Jim Meyering  <meyering@lucent.com>
25317
25318         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
25319         (jm_PREREQ): Use it.
25320
25321 2001-11-09  Jim Meyering  <meyering@lucent.com>
25322
25323         * m4/jm-macros.m4: Require autoconf-2.52f.
25324         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
25325         Use these AC_-prefixed names, not the AM_-prefixed ones.
25326
25327         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
25328
25329 2001-11-05  Jim Meyering  <meyering@lucent.com>
25330
25331         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
25332
25333 2001-11-04  Jim Meyering  <meyering@lucent.com>
25334
25335         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
25336         $DEFS.
25337
25338 2001-11-03  Jim Meyering  <meyering@lucent.com>
25339
25340         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
25341         of AC_DEFUN.
25342
25343         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
25344         know the name of the variable in the macro definition.
25345
25346 2001-11-03  Jim Meyering  <meyering@lucent.com>
25347
25348         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
25349         in argmatch_to_argument call.
25350
25351         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
25352         argument.
25353
25354         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
25355         e.g., a fault due to an attempt to free a NULL pointer.
25356
25357 2001-11-01  Jim Meyering  <meyering@lucent.com>
25358
25359         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
25360         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
25361
25362 2001-11-01  Jim Meyering  <meyering@lucent.com>
25363
25364         * lib/dirfd.c, lib/dirfd.h: New files.
25365         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
25366
25367         * lib/hash.c (hash_print) [TESTING]: Clean up.
25368
25369 2001-10-22  Paul Eggert  <eggert@twinsun.com>
25370
25371         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
25372         to avoid a warning if -Wall.
25373
25374 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
25375
25376         * README: New file
25377         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
25378         (per RMS's instructions, this is now the canonical source)
25379         * lgpl/, gpl/: New directories.
25380
25381 2001-10-21  Paul Eggert  <eggert@twinsun.com>
25382
25383         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
25384
25385 2001-10-21  Jim Meyering  <meyering@lucent.com>
25386
25387         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
25388         this code would end up calling gettext even in packages built
25389         with --disable-nls.
25390         * lib/getopt.c (_): Likewise.
25391         * lib/regex.c (_): Likewise.
25392
25393 2001-10-20  Paul Eggert  <eggert@twinsun.com>
25394
25395         * m4/error.m4 (jm_PREREQ_ERROR):
25396         Do not invoke AC_CHECK_FUNCS with strerror_r, as
25397         AC_FUNC_STRERROR_R does that.
25398         Check for strerror declaration.
25399
25400         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
25401         are supposed to have them these days.
25402         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
25403         Merge changes from latest Autoconf CVS.
25404         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
25405         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
25406         POSIX decided to standardize on the int flavor of strerror_r.
25407
25408 2001-10-20  Paul Eggert  <eggert@twinsun.com>
25409
25410         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
25411         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
25412         Use strerror_r that is only a macro, even if it is not a function.
25413         (strerror): Check for HAVE_DECL_STRERROR before declaring.
25414         (private_strerror): Use prototypes, not old-style function definition.
25415         (print_errno_message): New function.
25416         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
25417         char*-flavored one.
25418         (error_tail, error, error_at_line): Use it.
25419
25420 2001-10-11  Jim Meyering  <meyering@lucent.com>
25421
25422         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
25423         and quote_n (1, ... to avoid clobbering a buffer.
25424
25425 2001-10-05  Jim Meyering  <meyering@lucent.com>
25426
25427         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
25428         hash-pjw.h.
25429         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
25430         * lib/hash-pjw.h: New file.
25431
25432 2001-09-30  Jim Meyering  <meyering@lucent.com>
25433
25434         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
25435         `struct fsstat' has the `f_fstypename' member.
25436         Use that to define FS_TYPE, which is now used to make
25437         the getfsstat link test tighter.
25438
25439 2001-09-30  Jim Meyering  <meyering@lucent.com>
25440
25441         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
25442         Include <sys/ucred.h>, for Apple Darwin.
25443         Include sys/mount.h and sys/fs_types.h only if available.
25444         (FS_TYPE): Define.
25445         (read_filesystem_list): Use FS_TYPE.
25446
25447 2001-09-29  Paul Eggert  <eggert@twinsun.com>
25448
25449         * lib/exclude.c (excluded_filename): 0 -> false, since it's
25450         a boolean context.
25451
25452 2001-09-29  Jim Meyering  <meyering@lucent.com>
25453
25454         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
25455         [one-argument getmntent function]): Include stdio.h before mntent.h.
25456         SunOS 4.1.x needs it for the declaration of `FILE'.
25457         Patch by Volker Borchert.
25458
25459         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
25460         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
25461         sys/fs_types.h, and make the link-test for getfsstat guard #include
25462         directives with appropriate #if HAVE_*_H tests so that we can
25463         detect getfsstat on Apple Darwin1.3.7 systems.
25464         Reported by Nelson Beebe.
25465         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
25466
25467 2001-09-28  Paul Eggert  <eggert@twinsun.com>
25468
25469         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
25470         #defines strtoimax.  Also treat the other strto* functions
25471         like strtoimax.
25472
25473         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
25474         Check for strtoul and strtoumax,
25475         as those declarations are made even in the signed case.
25476         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
25477         Likewise, for strtol and strtoimax.
25478
25479 2001-09-28  Paul Eggert  <eggert@twinsun.com>
25480
25481         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
25482         #defines strtoimax.  Also treat the other strto* functions
25483         like strtoimax.
25484
25485         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
25486         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
25487         (strtoimax, strtoumax): Do not declare if already defined as a macro.
25488
25489 2001-09-26  Jim Meyering  <meyering@lucent.com>
25490
25491         Most macros in unlocked-io.h had the wrong number of arguments.
25492         * lib/gen-uio: New script.
25493         (USE_UNLOCKED_IO): Define to 1 if not already defined.
25494         * lib/unlocked-io.hin: Remove file.
25495         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
25496         rather than trying to embed it here.
25497         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
25498         Reported by Padraig Brady.
25499
25500 2001-09-25  Volker Borchert  <bt@teknon.de>
25501
25502         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
25503         `result'.
25504
25505 2001-09-24  Jim Meyering  <meyering@lucent.com>
25506
25507         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
25508
25509 2001-09-23  Jim Meyering  <meyering@lucent.com>
25510
25511         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
25512         instead of the mere test for existence of mntent.h.  The latter
25513         would get a false-positive on AIX 3.4 systems.
25514         In the outer getmntent if-block, don't die if neither of the getmntent
25515         tests succeeds.  Instead, just fall through and continue with the
25516         remaining tests.
25517
25518 2001-09-23  Jim Meyering  <meyering@lucent.com>
25519
25520         * lib/mountlist.c: Remove useless parentheses in #if directives.
25521         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
25522         the deprecated MOUNTED symbol is no longer defined in mntent.h.
25523
25524 2001-09-22  Jim Meyering  <meyering@lucent.com>
25525
25526         * m4/gettext.m4: New file.  From gettext.
25527         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
25528         * m4/progtest.m4: Likewise
25529         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
25530         * m4/glibc21.m4: Likewise.
25531
25532         * m4/libintl.m4: Remove.  No longer used.
25533
25534 2001-09-22  Jim Meyering  <meyering@lucent.com>
25535
25536         * lib/localcharset.c: Update from latest gettext.
25537         * lib/config.charset: Likewise.
25538
25539 2001-09-20  Jim Meyering  <meyering@lucent.com>
25540
25541         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
25542         strtoimax.
25543         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
25544         strtoumax.
25545
25546 2001-09-20  Jim Meyering  <meyering@lucent.com>
25547
25548         * lib/xstrtol.c (strtoimax): Guard declaration with
25549         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
25550         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
25551         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
25552         (strtoumax): Likewise, for completeness (it wasn't necessary).
25553
25554 2001-09-17  Paul Eggert  <eggert@twinsun.com>
25555
25556         * lib/strtoimax.c (HAVE_LONG_LONG):
25557         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
25558         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
25559         to work around bug in IBM C compiler.
25560
25561 2001-09-17  Jim Meyering  <meyering@lucent.com>
25562
25563         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
25564         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
25565         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
25566         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
25567         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
25568         whenever the right hand side need not be expanded by the shell.
25569
25570 2001-09-16  Paul Eggert  <eggert@twinsun.com>
25571
25572         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
25573         library.  It's not correct, as some older glibcs are buggy.
25574         fnmatch wasn't fixed until glibc 2.2.
25575
25576         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
25577         special shell magic here.
25578
25579 2001-09-16  Jim Meyering  <meyering@lucent.com>
25580
25581         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
25582         * m4/jm-macros.m4: Require it.
25583
25584 2001-09-16  Jim Meyering  <meyering@lucent.com>
25585
25586         * lib/mkdir.c: New file.
25587
25588 2001-09-15  Jim Meyering  <meyering@lucent.com>
25589
25590         * m4/jm-macros.m4: Check for help2man.
25591
25592 2001-09-11  Jim Meyering  <meyering@lucent.com>
25593
25594         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
25595         The body, by Paul Eggert, was moved here from configure.in.
25596         * m4/jm-macros.m4: Require UTILS_HOST_OS.
25597
25598 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25599
25600         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
25601         (jm_PREREQ): Use it.
25602
25603 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25604
25605         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
25606         Use ssize_t, not int, to store result of readlink.
25607         Check for ssize_t overflow as well as size_t overflow,
25608         as POSIX says the result of readlink is implementation-defined
25609         when ssize_t overflows.
25610         Remove unnecessary cast to char*.
25611         Use free+malloc instead of realloc, as the storage doesn't need
25612         to be preserved and it's clearer and can be more efficient that way.
25613         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
25614         * lib/xreadlink.h (xreadlink): Update prototype.
25615
25616 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25617
25618         * lib/xgetcwd.c: Revert some of the previous change; intead,
25619         fix the HAVE_GETCWD_NULL code to behave more like the
25620         !HAVE_GETCWD_NULL code used to.
25621
25622         Include "xalloc.h".
25623         (xgetcwd): Do not return NULL when memory is exhausted; instead,
25624         invoke xalloc_die.
25625
25626 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25627
25628         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
25629         sys/param.h, as pathmax.h includes them.
25630
25631 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25632
25633         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
25634         (jm_PREREQ_XGETCWD): New macro.
25635
25636         * m4/getcwd.m4: New file.
25637
25638 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25639
25640         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
25641         like the HAVE_GETCWD_NULL code.
25642         Include pathmax.h if not HAVE_GETCWD.
25643         Do not include xalloc.h.
25644         (INITIAL_BUFFER_SIZE): New symbol.
25645         Do not use xmalloc / xrealloc, since the caller is responsible for
25646         handling errors.  Preserve errno around `free' during failure.
25647         Do not overrun buffer when using getwd.
25648
25649 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25650
25651         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
25652         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
25653         getcwd (NULL, 0).
25654
25655 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25656
25657         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
25658         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
25659         spotted by Jim Meyering.
25660
25661 2001-09-03  Jim Meyering  <meyering@lucent.com>
25662
25663         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
25664         failure.
25665
25666 2001-09-02  Jim Meyering  <meyering@lucent.com>
25667
25668         * lib/error.c: Update from GNU libc.
25669
25670 2001-09-01  Jim Meyering  <meyering@lucent.com>
25671
25672         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
25673         Used by df.
25674
25675 2001-09-01  Jim Meyering  <meyering@lucent.com>
25676
25677         * lib/xreadlink.c: New file.
25678         * lib/xreadlink.h: New file.
25679         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
25680         xreadlink.h.
25681
25682         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
25683         doesn't conflict with sparc Solaris 7's definition in
25684         /usr/include/sys/int_types.h.
25685
25686         * lib/exclude.c: Use `""', not `<>' to #include non-system header
25687         files.
25688         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
25689         and strncasecmp as r-values.  Unixware didn't have declarations.
25690
25691 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25692
25693         * lib/xstrtol.h: Add copyright notice.
25694         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
25695         LONGINT_INVALID_SUFFIX_CHAR.
25696
25697 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25698
25699         * lib/xstrtol.c (strtoimax): New decl.
25700
25701 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25702
25703         * lib/xgetcwd.c: Don't include pathmax.h.
25704         Include stdlib.h and unistd.h if available.
25705         Include xalloc.h.
25706         (xmalloc, xstrdup, free): Remove decls.
25707         (xgetcwd): Don't assume sizes fit in unsigned.
25708         Check for overflow when computing sizes.
25709         Simplify reallocation code.
25710
25711 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25712
25713         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
25714         a directory's st_size can have an arbitrary value, so the old
25715         usage could waste an arbitrary amount of memory.  All uses
25716         changed.
25717         * lib/savedir.h: Update prototype.
25718
25719 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25720
25721         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
25722
25723         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
25724         old strtoimax.c.
25725
25726         Also, make the following further changes to make this file's
25727         configuration more similar to that of strtol.c:
25728         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
25729         (strtoumax, uintmax_t, strtoull, strtol): Remove.
25730         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
25731         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
25732         changed to signed values.
25733
25734         And make the following changes as well:
25735         Fix copyright notice, as 1999 was missing.
25736         (verify): New macro.
25737         (strtoimax): Check sizes at compile-time, not run-time.
25738         Prefer strtol to strtoll if both work.
25739         (main): Remove; it was not that useful and was a pain to maintain.
25740
25741         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
25742
25743 2001-08-31  Jim Meyering  <meyering@lucent.com>
25744
25745         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
25746         Use an initial, malloc'd, buffer of length 128 rather than
25747         a statically allocated one of length 1024.
25748
25749 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25750
25751         Simplify code, partly by assuming autoconf 2.52 semantics.
25752
25753         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
25754
25755         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
25756         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
25757         All uses removed.
25758         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
25759         Move AC_REQUIRE to next-to-top level, to avoid confusion.
25760         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
25761         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
25762         jm_AC_HEADER_INTTYPES_H.
25763         * m4/jm-macros.m4 (jm_MACROS): Likewise.
25764
25765         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
25766
25767         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
25768         Quote first arg of AC_DEFUN.
25769         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
25770         since they are needed to parse the include file even if we need
25771         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
25772         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
25773         but with opposite signedness.
25774
25775 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25776
25777         Merge 'exclude' changes from tar 1.13.22.
25778         This fixes one or two unlikely storage allocation overflow bugs,
25779         but doesn't change user-visible behavior otherwise.
25780
25781 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25782
25783         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
25784         (jm_PREREQ_EXCLUDE): New macro.
25785
25786 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25787
25788         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
25789         tm to be declared.
25790
25791 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25792
25793         * lib/hash.c: Remove '2001' from copyright notice.
25794
25795 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25796
25797         * lib/full-write.h: New file.
25798         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
25799         * lib/full-write.c: Correct credits, as cccp.c no longer
25800         exists and anyway it was so heavily changed from the old cccp
25801         code as to be unrecognizable.  Include full-write.h.
25802         (full_write) Return size_t, with short writes meaning failure.
25803         All callers changed.  This fixes a bug with large buffers
25804         on 64-bit hosts.
25805         * lib/utime.c: Include full-write.h.
25806
25807 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25808
25809         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
25810         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
25811         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
25812         Include if available.
25813         (<xalloc.h>): Include
25814         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
25815         (verify): New macro.  Use it to verify that EXCLUDE macros do not
25816         collide with FNM macros.
25817         (struct patopts): New struct.
25818         (struct exclude): Use it, as exclude patterns now come with options.
25819         (new_exclude): Support above changes.
25820         (new_exclude, add_exclude_file):
25821         Initial size must now be a power of two to simplify overflow checking.
25822         (free_exclude, fnmatch_no_wildcards): New function.
25823         (excluded_filename): No longer requires options arg, as the options
25824         are determined by add_exclude.  Now returns bool, not int.
25825         (excluded_filename, add_exclude):
25826         Add support for the fancy new exclusion options.
25827         (add_exclude, add_exclude_file): Now takes int options arg.
25828         Check for arithmetic overflow when computing sizes.
25829         (add_exclude_file): xrealloc might modify errno, so don't
25830         realloc until after errno might be used.
25831
25832         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
25833         New macros.
25834         (free_exclude): New decl.
25835         (add_exclude, add_exclude_file): Now takes int options arg.
25836         (excluded_filename): No longer requires options arg, as the options
25837         are determined by add_exclude.  Now returns bool, not int.
25838
25839 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25840
25841         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
25842
25843 2001-08-27  Jim Meyering  <meyering@lucent.com>
25844
25845         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
25846
25847         * lib/version-etc.c (N_): Remove definition.
25848         Revert most of last change.
25849         Instead, simply don't mark the `Copyright...' string for translation.
25850         Based on advice from Paul Eggert.
25851
25852         * lib/strtoxmax.c: Tweak comment.
25853
25854 2001-08-26  Jim Meyering  <meyering@lucent.com>
25855
25856         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
25857
25858         * m4/xstrtoimax.m4: New file.
25859         * m4/xstrtoumax.m4: Add comments explaining why we
25860         AC_REPLACE_FUNCS(strtol).
25861
25862 2001-08-26  Jim Meyering  <meyering@lucent.com>
25863
25864         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
25865         of copyright with `%s' so translators don't get an untranslated
25866         message in 2002.
25867         (COPYRIGHT_YEAR): Define.
25868         (version_etc): Use fprintf rather than fputs.
25869         Suggestion from Ulrich Drepper.
25870
25871         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
25872
25873         * lib/strtoll.c: New file, from GNU libc.
25874         * lib/xstrtoimax.c: New file.
25875
25876         * lib/xstrtol.h: Add xstrtoimax.
25877         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
25878         * lib/strtoimax.c: New file.  Likewise, but first define
25879         STRTOUXMAX_SIGNED.
25880
25881         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
25882         ...
25883         * lib/strtoxmax.c: ... then renamed to this.
25884
25885 2001-08-18  Paul Eggert  <eggert@twinsun.com>
25886
25887         * m4/inttypes.m4: Add AC_PREREQ(2.13).
25888         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
25889         (jm_AC_TYPE_INTMAX_T): New macro.
25890         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
25891
25892         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
25893
25894         * m4/longlong.m4: Renamed from ulonglong.m4.
25895         * m4/inttypes.m4: Renamed from inttypes_h.m4.
25896         * m4/uintmax_t.m4: Removed.
25897
25898 2001-08-13  Paul Eggert  <eggert@twinsun.com>
25899
25900         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
25901         Port to Solaris 8, where 'sed' requires a space after the 'r'
25902         command, and where sh dislikes "$/".  Clean up the spacing a bit.
25903         Redirect output to $tmp just once.
25904
25905 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
25906
25907         * lib/addext.c (<errno.h>): Include.
25908         (errno): Declare if not defined.
25909         (addext): Work correctly when pathconf returns -1 and leaves
25910         errno alone because there is no limit.  Also, work even if
25911         pathconf returns a value greater than SIZE_MAX.
25912
25913 2001-08-12  Jim Meyering  <meyering@lucent.com>
25914
25915         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
25916         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
25917         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
25918         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
25919         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
25920         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
25921         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
25922         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
25923         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
25924         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
25925         utime.m4, utimes.m4, xstrtoumax.m4:
25926         Quote the first argument in each use of AC_DEFUN.
25927
25928 2001-08-12  Jim Meyering  <meyering@lucent.com>
25929
25930         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
25931         Simply `return getcwd (NULL, 0);'.
25932         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
25933         Use 1300 as initial value for length, not PATH_MAX.
25934
25935         * lib/pathmax.h: Clean up cpp syntax.
25936
25937 2001-08-12  Jim Meyering  <meyering@lucent.com>
25938
25939         * lib/gettimeofday.c: New file.
25940         * lib/gtod.h: New file.
25941         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
25942
25943 2001-08-05  Jim Meyering  <meyering@lucent.com>
25944
25945         * m4/jm-macros.m4: Require autoconf-2.52.
25946
25947 2001-08-04  Jim Meyering  <meyering@lucent.com>
25948
25949         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
25950         stmt, to get in sync with glibc.
25951
25952 2001-08-03  Paul Eggert  <eggert@twinsun.com>
25953
25954         The following changes are from gettext 0.10.39 as maintained by
25955         Bruno Haible.
25956
25957         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
25958         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
25959         with inverted sense.  All uses changed.
25960
25961         * lib/mbswidth.c: Don't include <limits.h>.
25962         Include <stdlib.h> and <string.h> unconditionally.
25963         (iswcntrl, mbsinit, ISCNTRL): New macros.
25964         (mbsnwidth): Use K&R style function declarations.
25965         Don't bother checking for MB_LEN_MAX == 1, since the compiler
25966         can optimize it when MB_CUR_MAX == 1.
25967         The width of control characters is zero, not 1.
25968
25969 2001-08-03  Paul Eggert  <eggert@twinsun.com>
25970
25971         The following changes are from gettext 0.10.39 as maintained by
25972         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
25973
25974         * m4/codeset.m4: Upgrade to serial AM1.
25975         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
25976         all uses changed.  Quote first arg of AC_DEFUN.
25977         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
25978
25979         * m4/iconv.m4: Upgrade to serial AM2.
25980         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
25981         Add --with-libconv-prefix.
25982         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
25983         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
25984         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
25985         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
25986         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
25987
25988         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
25989         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
25990         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
25991         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
25992         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
25993         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
25994         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
25995         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
25996         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
25997
25998         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
25999         string.h any more.
26000
26001         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
26002         not the default value.
26003
26004         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
26005         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
26006         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
26007         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
26008         Also check for iswcntrl, used for wcwidth fallback.
26009         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
26010         to Autoconf 2.13.
26011
26012 2001-08-03  Jim Meyering  <meyering@lucent.com>
26013
26014         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
26015         as it was in the original.  Reported by Paul Eggert.
26016
26017 2001-07-16  Jim Meyering  <meyering@lucent.com>
26018
26019         * m4/gettimeofday.m4: New file.
26020         Prompted by a report from Bernhard Baehr.
26021
26022 2001-07-15  Jim Meyering  <meyering@lucent.com>
26023
26024         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
26025         stuff. Now it's in ../Makefile.cfg.
26026
26027 2001-07-15  Jim Meyering  <meyering@lucent.com>
26028
26029         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
26030         (BUILT_SOURCES): Add unlocked-io.h.
26031         (io_functions): Define.
26032         (unlocked-io.h): New rule.
26033         (DISTCLEANFILES): Add unlocked-io.h.
26034         (all-local): Depend on unlocked-io.h, to ensure it is created.
26035
26036         * lib/unlocked-io.hin: New file
26037
26038         * lib/regex.c: Update from glibc.
26039
26040 2001-07-05  Jim Meyering  <meyering@lucent.com>
26041
26042         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
26043         recommendation.
26044         (libfetish_a_SOURCES): Put all .h files here instead.
26045         Remove a thus-exposed (better checks in automake) duplicate and
26046         two unnecessary .h files.
26047
26048 2001-07-04  Jim Meyering  <meyering@lucent.com>
26049
26050         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
26051         that generates jm-glibc-io.m4 so that it doesn't trigger any make
26052         distcheck failure.
26053
26054 2001-07-02  Jim Meyering  <meyering@lucent.com>
26055
26056         The following changes were prompted by suggestions from Bruno Haible.
26057
26058         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
26059         is now generated.
26060         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
26061         definition of EXTRA_DIST.
26062         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
26063         ensure that the generated file is created/updated whenever the list
26064         of $(unlocked_functions) is changed.
26065         (jm-glibc-io.m4): New rule.
26066         (unlocked-io.h): New rule -- currently unused.
26067
26068 2001-06-24  Jim Meyering  <meyering@lucent.com>
26069
26070         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
26071         unmatched right bracket, rather than kludging it with an extra,
26072         falsely-matching quote in a comment.  Patch by Akim Demaille.
26073
26074 2001-06-11  Jim Meyering  <meyering@lucent.com>
26075
26076         * lib/regex.c: Update from GNU libc.
26077
26078 2001-05-27  Jim Meyering  <meyering@lucent.com>
26079
26080         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
26081         Check for ut_type in struct utmp.
26082
26083 2001-05-27  Jim Meyering  <meyering@lucent.com>
26084
26085         * lib/readutmp.h (UT_TYPE): Define.
26086
26087 2001-05-24  Jim Meyering  <meyering@lucent.com>
26088
26089         * lib/argmatch.c: Include "quote.h".
26090         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
26091         quote function.  Reported by Göran Uddeborg.
26092
26093 2001-05-22  Jim Meyering  <meyering@lucent.com>
26094
26095         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
26096         now that we use the package-supplied version unconditionally.
26097         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
26098
26099 2001-05-21  Jim Meyering  <meyering@lucent.com>
26100
26101         * m4/regex.m4: Change a couple backticks to single quotes to avoid
26102         shell syntax errors.
26103
26104 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26105
26106         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
26107
26108 2001-05-20  Paul Eggert  <eggert@twinsun.com>
26109
26110         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
26111         Don't bother to check library strftime, since
26112         we'll be using our own my_strftime function anyway.
26113         Define my_strftime instead of strftime.
26114
26115 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
26116
26117         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
26118         which is not yet declared.
26119
26120 2001-05-15  Jim Meyering  <meyering@lucent.com>
26121
26122         * m4/regex.m4: Use proper quoting so brackets appear in the test
26123         program.
26124         Reported by, and with help from, Bruno Haible.
26125
26126 2001-05-13  Jim Meyering  <meyering@lucent.com>
26127
26128         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
26129         undefined.
26130
26131 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26132
26133         dirname code cleanup.  base_name now behaves more compatibly
26134         with POSIX basename when given file names that have trailing
26135         slashes, and similarly for dir_name.  Add new primitives
26136         base_len and dir_len.  Put the directory-name-related decls
26137         into dirname.h.
26138
26139         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
26140         * lib/backupfile.c (base_name): Likewise.
26141         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
26142         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
26143         * lib/makepath.c (strip_trailing_slashes): Likewise.
26144         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
26145         ISSLASH): Likewise.
26146         * lib/rename.c (strip_trailing_slashes): Likewise.
26147         * lib/same.c (base_name): Likewise.
26148         * lib/stripslash.c (ISSLASH): Likewise.
26149
26150         * lib/addext.c: Include <dirname.h> after size_t is defined.
26151         * lib/backupfile.c: Likewise.
26152
26153         * lib/addext.c (addext): Use base_len to trim redundant
26154         trailing slashes instead of doing it ourselves.
26155         But do not trim the last slash if it is not redundant.
26156
26157         * lib/backupfile.c (find_backup_file_name,
26158         max_backup_version): Use base_len instead of rolling it ourselves.
26159         Handle the case of "" and (on DOS) "C:" correctly.
26160
26161         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
26162         needed. Include <string.h>, <dirname.h>.
26163         (base_name): Allow file names ending in slashes, other than names
26164         that are all slashes.  In this case, return the basename followed
26165         by the slashes.  This is more general, and can be used in places
26166         where the original base_name purposely had an assertion failure.
26167         (base_len): New function.
26168
26169         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
26170         Do not include <assert.h>; no longer needed.
26171         Include xalloc.h.
26172         (memrchr): Remove decl.
26173         (dir_name_r): Remove.
26174         (dir_len): Renamed from dirlen.  All callers changed.
26175         Rewrite in terms of base_name, for simplicity and consistency.
26176         (dir_name): Never return NULL.  All callers changed.
26177         Do not include <stdlib.h> in test program; no longer needed.
26178         return 0; is fine for test program.
26179
26180         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
26181         New macros.
26182         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
26183
26184         * lib/path-concat.c (path_concat): Use base_len to compute
26185         base length, not strlen; this means we cannot rely on memcpy
26186         to null-terminate.
26187
26188         * lib/same.c (STREQ): Remove.
26189         (same_name): Handle the case where the basename ends in trailing '/'.
26190
26191         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
26192         a slash was stripped.  Do not strip the last slash after a
26193         file system prefix.
26194
26195 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26196
26197         * lib/Makefile.am (libfetish_a_SOURCES):
26198         Add strftime.c, since we now compile it on all hosts.
26199
26200         * lib/strftime.c (my_strftime):
26201         Define to nstrftime if emacs, but only if my_strftime is not defined.
26202         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
26203         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
26204         Add one more extra argument: a nanoseconds value.
26205         All uses changed.
26206         (ns): New macro.
26207         (my_strftime function): Add %N format.
26208         (emacs_strftimeu): Renamed from emacs_strftime,
26209         with extra ut argument.
26210
26211 2001-05-09  Paul Eggert  <eggert@twinsun.com>
26212
26213         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
26214
26215 2001-04-21  Jim Meyering  <meyering@lucent.com>
26216
26217         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
26218         doesn't interfere.
26219
26220 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26221
26222         * m4/ftruncate.m4: Check for chsize.
26223         Link with ftruncate.o unconditionally if ftruncate is missing.
26224         This was required when cross-compiling to i586-mingw32msvc.
26225
26226 2001-04-08  Jim Meyering  <meyering@lucent.com>
26227
26228         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
26229         recomputed; that's necessary when the offset spans a DST transition.
26230         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
26231
26232 2001-04-02  Jim Meyering  <meyering@lucent.com>
26233
26234         * lib/regex.h, regex.c: Update from GNU libc.
26235
26236 2001-03-24  Jim Meyering  <meyering@lucent.com>
26237
26238         * m4/jm-macros.m4: Require autoconf-2.49d.
26239
26240 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
26241
26242         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
26243
26244 2001-03-19  Paul Eggert  <eggert@twinsun.com>
26245
26246         * lib/version-etc.c (version_etc_copyright): Update to 2001.
26247
26248 2001-03-17  Jim Meyering  <meyering@lucent.com>
26249
26250         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
26251         now that the version in autoconf is equivalent.
26252         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
26253
26254         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
26255         Suggestion from Akim Demaille.
26256
26257         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
26258         (jm_PREREQ_TEMPNAME): New function.
26259
26260 2001-03-16  Paul Eggert  <eggert@twinsun.com>
26261
26262         * lib/tempname.c (uint64_t): Define to uintmax_t if
26263         not defined, and if UINT64_MAX is not defined.
26264         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
26265         Reported by John David Anglin.
26266
26267 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
26268
26269         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
26270         resolve alias if codeset is empty.
26271         * lib/config.charset (BeOS): Use wildcard syntax.
26272
26273 2001-03-13  Jim Meyering  <meyering@lucent.com>
26274
26275         * lib/path-concat.c (path_concat)
26276         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
26277         concatenating e.g., `C:' and `foo'.
26278         From Bruno Haible.
26279
26280 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
26281
26282         * lib/localcharset.c (locale_charset): Don't use
26283         setlocale(LC_CTYPE,NULL). Don't return NULL.
26284         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
26285
26286 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
26287
26288         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
26289         support for DOS/DJGPP.
26290
26291 2001-03-01  Paul Eggert  <eggert@twinsun.com>
26292
26293         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
26294         lacks mkstemp.  Compile our own tempname.c if we compile our own
26295         mkstemp.c, as mkstemp relies on tempname.
26296
26297 2001-03-01  Jim Meyering  <meyering@lucent.com>
26298
26299         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
26300         AH_VERBATIM really does output its argument verbatim.
26301
26302 2001-02-28  Paul Eggert  <eggert@twinsun.com>
26303
26304         * lib/Makefile.am (libfetish_a_SOURCES):
26305         Add dup-safer.c, fopen-safer.c.
26306         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
26307
26308         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
26309         * lib/unistd-safer.h: New files.
26310
26311 2001-02-25  Paul Eggert  <eggert@twinsun.com>
26312
26313         The mkstemp replacement is taken from glibc 2.2.2, with some
26314         portability fixes for use outside glibc, as follows:
26315
26316         * lib/tempname.c (struct_stat64): New macro.
26317         (direxists, __gen_tempname): Use it.
26318         This avoids a portability problem with Solaris 8.
26319
26320         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
26321         (<stddef.h>, <stdint.h>, <string.h>):
26322         Include only if STDC_HEADERS || _LIBC.
26323         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
26324         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
26325         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
26326         (__set_errno): Define this macro if <errno.h> doesn't.
26327         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
26328         Define these macros if <stdio.h> doesn't.
26329         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
26330         Define these macros if <sys/stat.h>
26331         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
26332         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
26333         __xstat64): Define if not _LIBC.
26334         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
26335         (__gen_tempname): Invoke gettimeofday only if
26336         HAVE_GETTIMEOFDAY || _LIBC;
26337         otherwise, fall back on plain "time".
26338         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
26339
26340         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
26341
26342         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
26343
26344 2001-02-18  Paul Eggert  <eggert@twinsun.com>
26345
26346         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
26347
26348 2001-02-17  Paul Eggert  <eggert@twinsun.com>
26349
26350         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
26351         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
26352         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
26353         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
26354
26355 2001-02-17  Paul Eggert  <eggert@twinsun.com>
26356
26357         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
26358         Remove workaround macros for hosts that have mbrtowc but not
26359         mbstate_t, as we now insist on proper declarations for both
26360         before using mbrtowc.
26361
26362 2001-02-17  Jim Meyering  <meyering@lucent.com>
26363
26364         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
26365         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
26366         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
26367         UnixWare 7.1.1.
26368
26369         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
26370         rather than AC_CACHE_VAL.
26371
26372 2001-02-17  Jim Meyering  <meyering@lucent.com>
26373
26374         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
26375         around included file name.
26376
26377         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
26378
26379         * lib/strftime.c: Update from GNU libc (the only changes were to
26380         comments).
26381
26382 2001-02-17  Jim Meyering  <meyering@lucent.com>
26383
26384         * lib/regex.c: Update from libc.
26385
26386 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
26387
26388         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
26389         clash.
26390
26391 2001-02-16  Paul Eggert  <eggert@twinsun.com>
26392
26393         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
26394         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
26395         Reported by Mark Hounschell via Paul Eggert.
26396
26397 2001-02-07  Jim Meyering  <meyering@lucent.com>
26398
26399         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
26400
26401 2001-02-05  Jim Meyering  <meyering@lucent.com>
26402
26403         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
26404         it includes the patch required for `large file' support with at least
26405         HP-UX's 10.20 /bin/cc.
26406
26407 2001-02-03  Jim Meyering  <meyering@lucent.com>
26408
26409         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
26410         AS_IF, now that it works once again (mysteriously).
26411         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
26412
26413 2001-01-30  Jim Meyering  <meyering@lucent.com>
26414
26415         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
26416         * m4/chown.m4: Rename conftestchown to conftest.chown.
26417         * m4/rename.m4: s/conftestdir/conftest.d1/ and
26418         s/conftestdir2/conftest.d2/.
26419         * m4/utimes.m4: s/conftestdata/conftest.data/
26420         Inspired by Pavel Roskin's change in autoconf.
26421
26422 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
26423
26424         * lib/config.charset: Update for FreeBSD 4.2.
26425
26426 2001-01-27  Jim Meyering  <meyering@lucent.com>
26427
26428         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
26429         a use of AS_IF.
26430         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
26431
26432 2001-01-26  Jim Meyering  <meyering@lucent.com>
26433
26434         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
26435         quotearg.c includes it.
26436
26437 2001-01-26  Jim Meyering  <meyering@lucent.com>
26438
26439         * lib/quotearg.c: Include stddef.h.
26440         * lib/quote.c: Include stddef.h.
26441         Reported by Axel Kittenberger.
26442
26443         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
26444         line in double quotes so that it evokes a better diagnostic.
26445         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
26446         Reported by Axel Kittenberger.
26447
26448 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
26449
26450         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
26451         as if it was a `charset'.
26452
26453 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
26454
26455         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
26456         has const.
26457
26458 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
26459
26460         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
26461         to avoid a warning.  Add back 'const' to inptr.
26462
26463 2001-01-20  Jim Meyering  <meyering@lucent.com>
26464
26465         Be sure that headers are checked before used in code compiled
26466         for the type checks.
26467         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
26468         In place of that, invoke jm_CHECK_ALL_TYPES.
26469         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
26470         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
26471         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
26472         The check for ssize_t was mistakenly run before the test for unistd.h.
26473
26474         The configure-time check for stdbool.h was missing.
26475         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
26476         (jm_PREREQ_HASH): New function.
26477
26478 2001-01-17  Jim Meyering  <meyering@lucent.com>
26479
26480         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
26481         for autoconf-2.49c.
26482         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
26483
26484 2001-01-16  Jim Meyering  <meyering@lucent.com>
26485
26486         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
26487         From Bruno Haible.
26488
26489 2001-01-14  Jim Meyering  <meyering@lucent.com>
26490
26491         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
26492         foo and bar.  Create conftestdir/ in the script, not in the C code.
26493         Remove directories in the script, not in the C code.
26494         Remove conftestdir{,2} before trying to create the directory.
26495         Make the entire configure script fail if the mkdir fails.
26496
26497 2001-01-14  Jim Meyering  <meyering@lucent.com>
26498
26499         * lib/rename.c: New file.  From Volker Borchert.
26500         Include stdlib.h, string.h or strings.h, and xalloc.h.
26501         Use strip_trailing_slashes rather than open-coding it.
26502
26503 2001-01-03  Paul Eggert  <eggert@twinsun.com>
26504
26505         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
26506
26507 2001-01-03  Jim Meyering  <meyering@lucent.com>
26508
26509         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
26510         of local `inptr' to avoid warning with some system declarations of
26511         iconv.
26512
26513 2001-01-02  Volker Borchert  <bt@teknon.de>
26514
26515         * m4/rename.m4: New file.
26516         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
26517
26518 2001-01-01  Jim Meyering  <meyering@lucent.com>
26519
26520         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
26521         even on systems with utmpx.h.  It's necessary for the declaration of
26522         utmp's ut_user member.  Reported by Andreas Jaeger.
26523
26524         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
26525         available. They are required for the declarations of getgrgid and
26526         getpwuid resp.
26527         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
26528         Reported by Andreas Jaeger.
26529
26530 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
26531
26532         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
26533         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
26534         so `make install' also works in VPATH builds.
26535
26536 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
26537
26538         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
26539         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
26540         can be used in subdirectories.
26541
26542 2000-12-29  Paul Eggert  <eggert@twinsun.com>
26543
26544         * lib/modechange.c: Do not assume that mode_t uses the
26545         traditional octal encoding.  E.g. "chmod 1 FOO" should set
26546         the other-execute bit of FOO even if S_IXOTH != 1.
26547
26548         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
26549         WOTH, XOTH, ALLM): New macros.
26550         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
26551          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
26552         Use them.
26553         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
26554         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
26555         (mode_compile):
26556         No need to use uintmax_t; unsigned long is long enough.
26557         Don't bother to get suffix since we don't use it.
26558
26559 2000-12-26  Jim Meyering  <meyering@lucent.com>
26560
26561         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
26562         better with autoheader.
26563
26564 2000-12-24  Jim Meyering  <meyering@lucent.com>
26565
26566         * lib/hash.c (is_prime): Return explicit boolean values.
26567         (hash_get_first): Return NULL to appease Irix5.6's 89.
26568         Reported by Nelson Beebe.
26569
26570 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
26571
26572         * lib/localcharset.c (locale_charset): Add support for Win32.
26573
26574 2000-12-18  Paul Eggert  <eggert@twinsun.com>
26575
26576         * lib/physmem.h, lib/physmem.c: New files.
26577
26578         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
26579         (noinst_HEADERS): Add physmem.h.
26580
26581         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
26582         't' for compatibility with Solaris 8 sort.
26583
26584 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
26585
26586         * lib/config.charset: Add support for BeOS.
26587
26588 2000-12-17  Jim Meyering  <meyering@lucent.com>
26589
26590         * m4/dos.m4 (jm_AC_DOS): New file and macro.
26591         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
26592
26593 2000-12-16  Jim Meyering  <meyering@lucent.com>
26594
26595         This bug had a serious impact on chown: `chown N:M FILE' (for integer
26596         N and M) would have treated it like `chown N:N FILE'.
26597
26598         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
26599
26600 2000-12-16  Jim Meyering  <meyering@lucent.com>
26601
26602         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
26603         SHELLS_FILE to a file name that's useful on djgpp systems.
26604         Include stdlib.h.
26605         (ADDITIONAL_DEFAULT_SHELLS): Define.
26606         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
26607         Based mostly on a patch from Prashant TR.
26608
26609 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
26610
26611         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
26612         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
26613         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
26614
26615 2000-12-08  Andreas Schwab  <schwab@suse.de>
26616
26617         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
26618         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
26619
26620 2000-12-07  Jim Meyering  <meyering@lucent.com>
26621
26622         * lib/stripslash.c (ISSLASH): Define.
26623         (strip_trailing_slashes): Use ISSLASH rather than comparing against
26624         `/'.
26625         From Prashant TR.
26626
26627         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
26628         (dir_name_r): Declare this function as static.
26629         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
26630         manifest itself on a name containing a mix of slashes and
26631         backslashes.
26632         Make this function work with names starting with a DOS-style
26633         drive letter and colon prefix.
26634         (dir_name): Append `.' if necessary.
26635         Based mostly on patches from Prashant TR and Eli Zaretskii.
26636
26637         * lib/dirname.h (dir_name_r): Remove prototype.
26638
26639 2000-12-06  Paul Eggert  <eggert@twinsun.com>
26640
26641         * m4/off_t-format.m4: Remove this file.
26642         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
26643
26644 2000-12-06  Jim Meyering  <meyering@lucent.com>
26645
26646         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
26647         replacement strtoull, we may well need the replacement strtoul, too.
26648         Check for declarations of strtoul and strtoull.
26649         Check for strtol.  Mainly as a cue to cause automake to include
26650         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
26651         Check for limits.h -- strtol.c needs it.
26652
26653 2000-12-05  Jim Meyering  <meyering@lucent.com>
26654
26655         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
26656
26657 2000-12-04  Jim Meyering  <meyering@lucent.com>
26658
26659         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
26660         Also include memory.h, stdlib.h, unistd.h if appropriate.
26661         Reported by Andreas Jaeger (conflicting declaration of malloc).
26662
26663 2000-12-02  Jim Meyering  <meyering@lucent.com>
26664
26665         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
26666         * m4/jm-macros.m4 (jm_MACROS): require it.
26667
26668 2000-12-02  Jim Meyering  <meyering@lucent.com>
26669
26670         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
26671
26672 2000-12-01  Paul Eggert  <eggert@twinsun.com>
26673
26674         * lib/memrchr.c: Include <config.h> before any system include file.
26675
26676 2000-11-30  Jim Meyering  <meyering@lucent.com>
26677
26678         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
26679
26680 2000-11-30  Jim Meyering  <meyering@lucent.com>
26681
26682         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
26683
26684 2000-11-29  Paul Eggert  <eggert@twinsun.com>
26685
26686         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
26687
26688 2000-11-26  Jim Meyering  <meyering@lucent.com>
26689
26690         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
26691
26692 2000-11-22  Paul Eggert  <eggert@twinsun.com>
26693
26694         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
26695         size of (size_t) -1; it's not portable.
26696
26697 2000-11-17  Jim Meyering  <meyering@lucent.com>
26698
26699         * lib/strstr.c: Update from GNU libc.
26700
26701 2000-11-17  Akim Demaille  <akim@epita.fr>
26702
26703         * lib/obstack.h: Formatting changes.
26704         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
26705         prevent type checking.
26706         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
26707         cast the value to (void *): assigning a `foo *' to a `void *'
26708         variable is valid.
26709         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
26710
26711 2000-11-16  Jim Meyering  <meyering@lucent.com>
26712
26713         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
26714
26715 2000-11-11  Jim Meyering  <meyering@lucent.com>
26716
26717         * lib/error.c: Add a couple #includes, merging from GNU libc version.
26718
26719 2000-11-10  Jim Meyering  <meyering@lucent.com>
26720
26721         * lib/obstack.h: Update from GNU libc.
26722         * lib/obstack.c: Likewise.
26723
26724 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
26725
26726         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
26727
26728 2000-11-06  Paul Eggert  <eggert@twinsun.com>
26729
26730         * lib/getusershell.c (setusershell): Use rewind rather than
26731         fseek/fseeko, to avoid configuration hassles with fseeko.
26732         Don't bother opening SHELLS_FILE if shellstream is NULL;
26733         it's not necessary.
26734
26735 2000-11-05  Jim Meyering  <meyering@lucent.com>
26736
26737         * lib/makepath.h (make_dir): Declare.
26738         * lib/makepath.c (make_dir): Remove `static' attribute.
26739         Tweak a comment.
26740
26741 2000-11-04  Jim Meyering  <meyering@lucent.com>
26742
26743         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
26744
26745 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
26746
26747         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
26748         last one in a bucket, advance to the next bucket.
26749
26750 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
26751
26752         * lib/fnmatch.c: Do not comment out all the code if we are using
26753         the GNU C library, because in some cases we are replacing buggy
26754         code in the GNU C library itself.
26755
26756 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
26757
26758         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
26759         (regex_compile): Catch bogus \(\1\).
26760
26761 2000-10-30  Paul Eggert  <eggert@twinsun.com>
26762
26763         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
26764         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
26765         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
26766
26767 2000-10-30  Paul Eggert  <eggert@twinsun.com>
26768
26769         * lib/error.h, getline.h, modechange.h:
26770         Remove "2000" from Copyright line, as the file hasn't been
26771         changed this year other than in the copyright notice.
26772
26773         * lib/xalloc.h: Add "2000" to Copyright line, as this file
26774         was changed this year.
26775
26776 2000-10-29  Jim Meyering  <meyering@lucent.com>
26777
26778         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
26779         renaming.
26780         * m4/ls-mntd-fs.m4: Likewise
26781
26782 2000-10-29  Jim Meyering  <meyering@lucent.com>
26783
26784         * lib/xstat.in: Fix grammar in comment.
26785
26786 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
26787
26788         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
26789         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
26790         doesn't define __restrict_arr.
26791
26792 2000-10-28  Jim Meyering  <meyering@lucent.com>
26793
26794         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
26795         (jm_PREREQ_MEMCHR): New function.
26796
26797 2000-10-28  Jim Meyering  <meyering@lucent.com>
26798
26799         * lib/memchr.c: Update from libc.
26800         Adjust for portability:
26801         [HAVE_STDLIB_H]: Include stdlib.h.
26802         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
26803         Undef __memchr, too.
26804         [!weak_alias]: Define __memchr to memchr.
26805
26806         * lib/regex.c: Update from libc.
26807         * lib/regex.h: Likewise.
26808         * lib/getopt1.c: Likewise.
26809         * lib/memcmp.c: Likewise.
26810
26811         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
26812         Avoid using fseek, when possible -- it's broken by design.
26813         Patch by Ulrich Drepper.
26814
26815 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
26816
26817         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
26818         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
26819         Giving in to popular pressure to shut up the compiler with casts.
26820
26821 2000-10-26  Jim Meyering  <meyering@lucent.com>
26822
26823         * lib/strftime.c: Update from libc.
26824
26825 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
26826
26827         * regex.c: More `unsigned char' -> `re_char' changes.
26828         Also change several `int' into `re_wchar_t'.
26829         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
26830         (PUSH_FAILURE_POINTER): Don't cast any more.
26831         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
26832         We want GCC to complain, since this piece of code makes
26833         re_match non-reentrant, which *should* be fixed.
26834         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
26835         (EXTEND_BUFFER): Use RETALLOC.
26836         (SET_LIST_BIT): Don't cast.
26837         (re_wchar_t): New type.
26838         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
26839         that those two functions will always properly return.
26840         (IMMEDIATE_QUIT_CHECK): Cast to void.
26841         (analyse_first): Use recursion rather than an explicit stack.
26842         (re_compile_fastmap): Can't fail anymore.
26843         (re_search_2): Don't check re_compile_fastmap for failure.
26844         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
26845         Now also sets the new value (passed in a new argument).
26846         (re_match_2_internal): Use it.
26847         Also, use a new var `reg' of type size_t when looping through regs
26848         rather than reuse the inappropriate `mcnt'.
26849
26850 2000-10-25  Jim Meyering  <meyering@lucent.com>
26851
26852         * lib/obstack.c: Update from libc.
26853
26854 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
26855
26856         * regex.c (regex_compile): Change the way of handling a range from
26857         a char less than 256 to a char not less than 256.
26858
26859 2000-10-24  Andrew Innes  <andrewi@gnu.org>
26860
26861         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
26862         NT-Emacs only.
26863         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
26864         so that re_search functions only quit when callers expect them to.
26865
26866 2000-10-23  Jim Meyering  <meyering@lucent.com>
26867
26868         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
26869         wrong.  That set_locale call must not have any side effects.
26870         From Paul Eggert.
26871
26872 2000-10-22  Jim Meyering  <meyering@lucent.com>
26873
26874         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
26875         [CYCLIC]: Remove now-unused definition.
26876
26877         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
26878         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
26879         Suggestion from Ulrich Drepper.
26880
26881 2000-10-21  Jim Meyering  <meyering@lucent.com>
26882
26883         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
26884         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
26885         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
26886
26887 2000-10-21  Jim Meyering  <meyering@lucent.com>
26888
26889         * lib/dirname.c (memrchr): Declare if necessary.
26890         (dir_name): Remove the restriction that there be no
26891         trailing slashes.  Now, this code skips past them, effectively
26892         ignoring them.
26893         [TEST_DIRNAME] (main): New unit tests.
26894
26895         * lib/memrchr.c: New file from GNU libc.
26896         Undef __memrchr, too.
26897         [!weak_alias]: Define __memrchr to memrchr.
26898         Guard weak_alias use with `#ifdef weak_alias'.
26899
26900 2000-10-21  Jim Meyering  <meyering@lucent.com>
26901
26902         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
26903         (dir_name): Use dir_name_r.
26904         * lib/dirname.h (dir_name_r): Declare it.
26905
26906 2000-10-17  Jim Meyering  <meyering@lucent.com>
26907
26908         * lib/quote.h (PARAMS): Define and use.
26909         Reported by Akim Demaille.
26910
26911         * lib/getopt.c: Update from libc.
26912
26913 2000-10-16  Jim Meyering  <meyering@lucent.com>
26914
26915         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
26916         setlocale.
26917         From Jan Fedak.
26918
26919 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
26920
26921         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
26922
26923 2000-09-25  Jim Meyering  <meyering@lucent.com>
26924
26925         * lib/md5.h (rol): Define (from GnuPG).
26926
26927         * lib/sha.c: Give credit (GnuPG) where due.
26928         (M): Use rol rather than open-coding it.
26929         Add a FIXME comment.
26930
26931 2000-09-21  Jim Meyering  <meyering@lucent.com>
26932
26933         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
26934         Reported by Michael Stone.
26935
26936 2000-09-20  Jim Meyering  <meyering@lucent.com>
26937
26938         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
26939         (noinst_HEADERS): Add sha.h.
26940         Based on code from Scott G. Miller and from GnuPG.
26941
26942 2000-09-18  Jim Meyering  <meyering@lucent.com>
26943
26944         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
26945         LIBS. Otherwise, everyone ends up linking with -lelf for some
26946         configurations.
26947         Reported by Mike Stone.
26948
26949 2000-09-15  Jim Meyering  <meyering@lucent.com>
26950
26951         * lib/regex.c: Update from libc.
26952
26953 2000-09-10  Jim Meyering  <meyering@lucent.com>
26954
26955         * lib/getopt.c (_getopt_internal): Update from glibc.
26956
26957 2000-09-09  Jim Meyering  <meyering@lucent.com>
26958
26959         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
26960         think it should be used as a general replacement for isascii.
26961         * lib/fnmatch.c: Likewise.
26962         * lib/mbswidth.c: Likewise
26963         * lib/regex.c: Likewise.
26964
26965         Don't use atoi.
26966         * lib/userspec.c: Include sys/param.h and limits.h.
26967         Include xstrtol.h.
26968         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
26969         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
26970         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
26971         UID, GID.  Check range.
26972
26973 2000-09-06  Jim Meyering  <meyering@lucent.com>
26974
26975         * lib/getopt.c (_getopt_internal): Update from glibc.
26976
26977 2000-08-30  Jim Meyering  <meyering@lucent.com>
26978
26979         * lib/strftime.c: Merge in changes from GNU libc.
26980
26981 2000-08-26  Jim Meyering  <meyering@lucent.com>
26982
26983         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
26984         * m4/fpending.m4: New file.
26985
26986 2000-08-26  Jim Meyering  <meyering@lucent.com>
26987
26988         * lib/closeout.c: Include "__fpending.h".
26989         (close_stdout_status): Return right away if there's nothing to flush.
26990
26991         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
26992         * lib/__fpending.c: New file.
26993         * lib/__fpending.h: New file.
26994
26995 2000-08-20  Jim Meyering  <meyering@lucent.com>
26996
26997         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
26998         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
26999         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
27000
27001 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
27002
27003         Improve fileutils installation on systems where running
27004         programs (like install) can't be unlinked.
27005         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
27006         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
27007
27008 2000-08-07  Paul Eggert  <eggert@twinsun.com>
27009
27010         Standardize on "memory exhausted" instead of "Memory exhausted"
27011         or "virtual memory exhausted".
27012         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
27013         "virtual memory exhausted".
27014         * lib/same.c (same_name): Invoke xalloc_die instead of printing
27015         our own message.
27016         * lib/userspec.c (parse_user_spec): Likewise.
27017         * lib/bumpalloc.h: comment fix
27018         * lib/same.c, userspec.c: Include xalloc.h.
27019
27020         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
27021         not char *const and pointing to a constant array.
27022         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
27023         (xrealloc): Comment fix.
27024
27025         * lib/userspec.c (parse_user_spec):
27026         Don't translate a message until just before returning,
27027         to avoid unnecessary translation.
27028
27029 2000-08-07  Jim Meyering  <meyering@lucent.com>
27030
27031         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
27032         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
27033         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
27034         getgroups.c, gethostname.c, getopt.h, group-member.c,
27035         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
27036         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
27037         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
27038         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
27039         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
27040         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
27041         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
27042         yesno.c: Back out Copyright date changes for each file with no change
27043         this year.  This eases coordination with other programs using the same
27044         source code modules.  From Paul Eggert.
27045
27046 2000-08-06  Paul Eggert  <eggert@twinsun.com>
27047
27048         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
27049         not char, for compatibility with glibc 2.1.3 strftime.c.
27050
27051 2000-08-03  Greg McGary  <greg@mcgary.org>
27052
27053         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
27054         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
27055         (EXTEND_BUFFER): Use them.
27056
27057 2000-08-01  Jim Meyering  <meyering@lucent.com>
27058
27059         * lib/dirname.c (ISSLASH): Define.
27060         (BACKSLASH_IS_PATH_SEPARATOR): Define.
27061         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
27062         both `\' and `/' may be use as path separators.
27063         Based on a patch from Prashant TR.
27064
27065 2000-07-31  Paul Eggert  <eggert@twinsun.com>
27066
27067         * lib/quotearg.c (quotearg_n_options): Don't make the initial
27068         slot vector a constant, since it might get modified.
27069
27070 2000-07-31  Jim Meyering  <meyering@lucent.com>
27071
27072         * lib/xmalloc.c: Use `virtual memory exhausted', not
27073         `Memory exhausted'.
27074         * lib/obstack.c (print_and_abort): Likewise.
27075
27076 2000-07-30  Paul Eggert  <eggert@twinsun.com>
27077
27078         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
27079         buffer, so that the caller can always quote one small
27080         component of a "memory exhausted" message in slot 0.
27081         From a suggestion by Jim Meyering.
27082
27083 2000-07-30  Jim Meyering  <meyering@lucent.com>
27084
27085         * lib/makepath.c (make_path): Quote the other instance, too.
27086
27087         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
27088         (STATIC_BUF_SIZE): Define.
27089         (quotearg_n_options): Use only statically allocated storage when
27090         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
27091         than STATIC_BUF_SIZE.
27092
27093 2000-07-29  Jim Meyering  <meyering@lucent.com>
27094
27095         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
27096         * lib/dirname.c (dir_name): Likewise.
27097
27098         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
27099         `/'.
27100
27101         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
27102         (dir_name): Assert that there are no trailing slashes.
27103
27104 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
27105
27106         * lib/mbswidth.h (mbswidth): Add a flags argument.
27107         (mbswidth): New declaration.
27108         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
27109         * lib/mbswidth.c (mbswidth): Add a flags argument.
27110         (mbsnwidth): New function.
27111
27112 2000-07-24  Jim Meyering  <meyering@lucent.com>
27113
27114         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
27115
27116 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27117
27118         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
27119
27120 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27121
27122         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
27123         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
27124         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
27125         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
27126         invoke multibyte primitives.
27127
27128 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27129
27130         * lib/quotearg.c:
27131         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
27132         so that mbstate_t is always defined.
27133
27134         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
27135         be 1 in at least one GCC installation, and this configuration
27136         error is likely to be common.  Ignoring MB_LEN_MAX hurts
27137         performance on hosts that have mbrtowc but have only unibyte
27138         locales, but I assume these hosts are rare.
27139
27140 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27141
27142         * lib/mbswidth.c (_XOPEN_SOURCE):
27143         Don't define; this causes problems on Solaris 7.
27144         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
27145
27146 2000-07-23  Jim Meyering  <meyering@lucent.com>
27147
27148         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
27149         too: getgrgid, getpwuid, getuid.
27150
27151 2000-07-23  Jim Meyering  <meyering@lucent.com>
27152
27153         * lib/basename.c (base_name): Add an assertion.
27154
27155 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
27156
27157         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
27158         shadow its mbsinit function.
27159
27160 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27161
27162         * lib/mbswidth.h: New file.
27163         * lib/mbswidth.c: New file.
27164         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
27165         (noinst_HEADERS): Add mbswidth.h.
27166
27167 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27168
27169         * lib/config.charset: Add support for FreeBSD. Improve support for
27170         HP-UX and IRIX 6.
27171
27172 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
27173
27174         * m4/mbswidth.m4: New file.
27175         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
27176
27177 2000-07-15  Jim Meyering  <meyering@lucent.com>
27178
27179         * lib/makepath.c: Include quote.h.
27180         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
27181         corresponding argument in a `quote (...)' call.
27182         Give better diagnostics.
27183
27184         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
27185         (noinst_HEADERS): Add quote.h.
27186
27187         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
27188         from tar's src/misc.c.
27189         * lib/quote.h: New file.  Prototypes for same.
27190
27191 2000-07-14  Paul Eggert  <eggert@twinsun.com>
27192
27193         From a suggestion by Bruno Haible.
27194         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
27195         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
27196         to decide whether to define the BeOS workaround macro;
27197         this adjusts to the change to AC_MBSTATE_T.
27198
27199 2000-07-14  Jim Meyering  <meyering@lucent.com>
27200
27201         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
27202         jm_AC_TYPE_UINTMAX_T.
27203
27204 2000-07-13  Paul Eggert  <eggert@twinsun.com>
27205
27206         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
27207
27208         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
27209         quotearg_buffer_restyled): Add support for
27210         clocale_quoting_style.  Undo previous change to
27211         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
27212         and "{RIGHT QUOTATION MARK}" msgids.
27213
27214 2000-07-10  Paul Eggert  <eggert@twinsun.com>
27215
27216         From a suggestion by Bruno Haible.
27217         * m4/mbstate_t.m4 (AC_MBSTATE_T):
27218         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
27219         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
27220         and mbstate_t, to a single-part test that simply defines mbstate_t.
27221         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
27222         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
27223
27224 2000-07-10  Jim Meyering  <meyering@lucent.com>
27225
27226         * m4/strerror_r.m4: Mirror the correction made in autoconf.
27227
27228         * m4/gnu-source.m4: Output to confdefs.h directly.
27229         Suggestion from Akim Demaille.
27230
27231 2000-07-09  Paul Eggert  <eggert@twinsun.com>
27232
27233         The old behavior of quoting `like this' doesn't look good with
27234         newer, ISO-style fonts.  See:
27235         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
27236
27237         Instead, quote "like this" by default.  Let the translator
27238         tailor the locale-specific quoting behavior by providing
27239         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
27240
27241         * lib/quotearg.c (N_): New macro.
27242         (gettext_default): New function.
27243         (quotearg_buffer_restyled): Use
27244         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
27245         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
27246
27247 2000-07-09  Jim Meyering  <meyering@lucent.com>
27248
27249         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
27250         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
27251
27252         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
27253         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
27254
27255 2000-07-09  Jim Meyering  <meyering@lucent.com>
27256
27257         * lib/Most files: Update copyright dates to include 2000.
27258
27259 2000-07-08  Jim Meyering  <meyering@lucent.com>
27260
27261         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
27262         if not defined.
27263         (xgethostname): Remove now-unnecessary #ifdef.
27264         Move declaration of `err' into loop where it's used.
27265
27266 2000-07-05  Paul Eggert  <eggert@twinsun.com>
27267         and Bruno Haible  <haible@clisp.cons.org>
27268
27269         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
27270         only if the test for an object-type mbstate_t fails.  This
27271         prevents us from mistakenly reporting that mbstate_t is a
27272         system object type after we "#define mbstate_t int" to work
27273         around its lack.
27274
27275 2000-07-05  Paul Eggert  <eggert@twinsun.com>
27276         and Bruno Haible  <haible@clisp.cons.org>
27277
27278         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
27279
27280 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27281
27282         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
27283         to strerror_r.
27284         Include <ctype.h> for use of isalpha.
27285
27286 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27287
27288         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
27289         by allocating a larger buffer. Test the gethostname return value for
27290         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
27291         returns an error and ENAMETOOLONG isn't defined.
27292
27293 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27294
27295         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
27296         dimension.
27297
27298 2000-07-04  Jim Meyering  <meyering@lucent.com>
27299
27300         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
27301         of the deprecated AC_CHECKING.
27302
27303 2000-07-04  Jim Meyering  <meyering@lucent.com>
27304
27305         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
27306         Reported by Bruno Haible.
27307
27308 2000-07-04  Jim Meyering  <meyering@lucent.com>
27309
27310         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
27311         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
27312         lacks mbrtowc.
27313
27314 2000-07-03  Paul Eggert  <eggert@twinsun.com>
27315
27316         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
27317         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
27318
27319 2000-07-03  Paul Eggert  <eggert@twinsun.com>
27320         and Bruno Haible  <haible@clisp.cons.org>
27321
27322         * lib/quotearg.c (mbrtowc):
27323         Assign to *pwc, and return 1 only if result is nonzero.
27324         (iswprint): Use ISPRINT when substituting our own mbrtowc.
27325
27326 2000-07-03  Jim Meyering  <meyering@lucent.com>
27327
27328         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
27329
27330 2000-07-03  Jim Meyering  <meyering@lucent.com>
27331
27332         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
27333         This is necessary to get a definition of e.g., UTMP_FILE on
27334         HP-UX 10.20.
27335         From Bob Proulx.
27336
27337 2000-07-02  Jim Meyering  <meyering@lucent.com>
27338
27339         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
27340
27341         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
27342         AC_LIBOBJ(function_name).
27343         * m4/chown.m4: Likewise.
27344         * m4/fnmatch.m4: Likewise.
27345         * m4/ftruncate.m4: Likewise.
27346         * m4/getgroups.m4: Likewise.
27347         * m4/getline.m4: Likewise.
27348         * m4/group-member.m4: Likewise.
27349         * m4/jm-macros.m4: Likewise.
27350         * m4/lstat.m4: Likewise.
27351         * m4/malloc.m4: Likewise.
27352         * m4/memcmp.m4: Likewise.
27353         * m4/nanosleep.m4: Likewise.
27354         * m4/putenv.m4: Likewise.
27355         * m4/realloc.m4: Likewise.
27356         * m4/regex.m4: Likewise.
27357         * m4/stat.m4: Likewise.
27358         * m4/strftime.m4: Likewise.
27359
27360 2000-07-02  Jim Meyering  <meyering@lucent.com>
27361
27362         * lib/quotearg.c (mbstate_t): Don't define here.
27363
27364 2000-07-02  Jim Meyering  <meyering@lucent.com>
27365
27366         * lib/nanosleep.c (SIGCONT): Define if not already defined.
27367
27368 2000-07-01  Jim Meyering  <meyering@lucent.com>
27369
27370         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
27371
27372 2000-07-01  Jim Meyering  <meyering@lucent.com>
27373
27374         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
27375         problem.
27376
27377 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
27378
27379         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
27380         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
27381
27382 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
27383
27384         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
27385         per change in ../m4/ls-mntd-fs.m4.
27386         (read_filesystem_list): Ignore symbolic links.
27387
27388 2000-06-29  Jim Meyering  <meyering@lucent.com>
27389
27390         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
27391         for declaration of strcmp.
27392
27393         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
27394
27395         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
27396         Avoid warning by casting result to `char *' to remove `const'.
27397
27398 2000-06-28  Jim Meyering  <meyering@lucent.com>
27399
27400         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
27401         included by quotearg.c, for which we perform this test.  From
27402         Bruno Haible.
27403
27404 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
27405
27406         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
27407         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
27408         <utmpx.h> exists, put readutmp.o into LIBOBJS.
27409
27410 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
27411
27412         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
27413
27414 2000-06-26  Paul Eggert  <eggert@twinsun.com>
27415
27416         savedir now sets errno on failure and invokes xmalloc to get memory.
27417         Fix a couple of other minor bugs while we're at it.
27418
27419         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
27420         (NAMLEN): Remove macro.
27421         (malloc, realloc): Remove decls.
27422         (stpcpy): Likewise.
27423         ("xalloc.h"): Include.
27424         (NAME_SIZE_DEFAULT): New macro.
27425         (savedir): Use xmalloc / xrealloc to allocate memory.
27426         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
27427         Skip "" directory entries.
27428         Use strlen to calculate directory entry length, since the old method
27429         is rarely used these days and isn't worth supporting.
27430         Don't use a pointer after freeing it.
27431         Check for integer overflow when calculating allocation size.
27432         Use memcpy to copy entries, instead of stpcpy.
27433         Set errno properly when returning NULL.
27434         Check for readdir error.
27435
27436 2000-06-26  Jim Meyering  <meyering@lucent.com>
27437
27438         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
27439
27440 2000-06-25  Jim Meyering  <meyering@lucent.com>
27441
27442         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
27443         Linux header bug when _XOPEN_SOURCE is defined to 500.
27444
27445 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
27446
27447         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
27448         deficiency.
27449
27450 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
27451
27452         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
27453         Include xalloc.h.
27454         Don't include <stdlib.h>.  Don't declare malloc, realloc.
27455
27456 2000-06-24  Jim Meyering  <meyering@lucent.com>
27457
27458         * m4/strerror_r.m4: Revive this file -- to try out an experimental
27459         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
27460         for which strerror does return char*, but which lacks a conveniently
27461         accessible declaration of the function.  If the compile-test says
27462         strerror_r doesn't work, then resort to a `run'-test that works on
27463         BeOS and segfaults on DEC Unix.
27464
27465 2000-06-24  Jim Meyering  <meyering@lucent.com>
27466
27467         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
27468
27469 2000-06-23  Paul Eggert  <eggert@twinsun.com>
27470
27471         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
27472         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
27473
27474 2000-06-23  Paul Eggert  <eggert@twinsun.com>
27475
27476         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
27477         (mbrtowc, mbstate_t): Define substitutes if
27478         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
27479         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
27480         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
27481
27482 2000-06-23  Jim Meyering  <meyering@lucent.com>
27483
27484         * m4/afs.m4: Add missing AC_MSG_RESULT.
27485         Reported by Bruno Haible.
27486
27487         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
27488         Suggestion from Bruno Haible.
27489
27490 2000-06-23  Jim Meyering  <meyering@lucent.com>
27491
27492         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
27493
27494 2000-06-21  Jim Meyering  <meyering@lucent.com>
27495
27496         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
27497
27498 2000-06-21  Jim Meyering  <meyering@lucent.com>
27499
27500         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
27501         (noinst_HEADERS): Add getstr.h.
27502
27503         * lib/getline.c (getstr): Move into a separate file.
27504         * lib/getstr.c (getstr): New file, extracted from getline.c, with
27505         the following changes: new parameter, delim2; both delim[12]
27506         parameters have type `int', not `char'.  The latter would lose
27507         with 8-bit delimiters.
27508         * lib/getstr.h: New file.
27509
27510 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
27511
27512         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
27513         than 1024, return a memory chunk of least possible size, instead
27514         of size PATH_MAX + 2. In the loop, increment the size proportionally.
27515         Use free/xmalloc instead of xrealloc to avoid copying for very long
27516         paths.
27517
27518 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
27519
27520         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
27521         the empty string.
27522
27523 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
27524
27525         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
27526         address, not strdup.  Include <stdlib.h> and don't declare free().
27527
27528 2000-06-19  Jim Meyering  <meyering@lucent.com>
27529
27530         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
27531
27532 2000-06-18  Jim Meyering  <meyering@lucent.com>
27533
27534         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
27535
27536         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
27537         `checking whether...' message to be consistent with that of the
27538         lstat test.
27539
27540 2000-06-18  Jim Meyering  <meyering@lucent.com>
27541
27542         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
27543         Besides, these days every porting target provides a mkdir function.
27544
27545         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
27546         needed. (this snippet comes from src/system.h).
27547
27548 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
27549
27550         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
27551
27552 2000-06-15  Paul Eggert  <eggert@twinsun.com>
27553
27554         * lib/human.c (adjust_value): New function.
27555         (human_readable_inexact): Apply rounding style even when
27556         printing approximate values.
27557
27558 2000-06-14  Paul Eggert  <eggert@twinsun.com>
27559
27560         * lib/human.c (human_readable_inexact): Allow an input block
27561         size that is not a multiple of the output block size, and vice versa.
27562         Reported by Piergiorgio Sartor.
27563
27564 2000-06-14  Paul Eggert  <eggert@twinsun.com>
27565
27566         * lib/getdate.y (get_date): Apply relative times after time
27567         zone indicator, not before.  Reported by Todd A. Jacobs.
27568
27569 2000-06-13  Jim Meyering  <meyering@lucent.com>
27570
27571         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
27572
27573         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
27574
27575 2000-06-12  Paul Eggert  <eggert@twinsun.com>
27576
27577         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
27578
27579 2000-06-12  Jim Meyering  <meyering@lucent.com>
27580
27581         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
27582         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
27583         optional argument.
27584         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
27585         the optional argument, `lib'.
27586
27587 2000-06-08  Jim Meyering  <meyering@lucent.com>
27588
27589         * m4/largefile.m4: Remove file (now that it's part of autoconf).
27590
27591 2000-06-04  Paul Eggert  <eggert@twinsun.com>
27592
27593         Rewrite largefile configuration so that we don't need to run
27594         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
27595         AC_CANONICAL_HOST in configure.in -- jmm]
27596
27597         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
27598         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
27599         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
27600         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
27601         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
27602         All uses changed.
27603         Instead of inspecting the output of getconf, try to compile the
27604         test program without and with the macro definition.
27605         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
27606         for getconf.  Instead, check for the needed flags by compiling
27607         test programs.
27608
27609 2000-06-04  Paul Eggert  <eggert@twinsun.com>
27610
27611         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
27612
27613 2000-06-04  Jim Meyering  <meyering@lucent.com>
27614
27615         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
27616         SunOS 4.1.4 for which gid_t is an unsigned type.
27617
27618 2000-06-03  Jim Meyering  <meyering@lucent.com>
27619
27620         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
27621         now that autoconf requires that.
27622
27623         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
27624         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
27625         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
27626
27627 2000-06-03  Jim Meyering  <meyering@lucent.com>
27628
27629         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
27630
27631 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
27632
27633         * m4/glibc21.m4: New file.
27634         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
27635
27636 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
27637
27638         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
27639         newer, don't install charset.alias.
27640         * lib/config.charset: Change the Linux/glibc rules so they become empty
27641         on glibc-2.1 or newer.
27642
27643 2000-06-02  Jim Meyering  <meyering@lucent.com>
27644
27645         * lib/mountlist.c: Back out last change.  Instead, do this...
27646         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
27647         me_dummy member using the same `ignore'-testing code.
27648         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
27649         fs_type strings.
27650         From Mark D. Roth.
27651
27652 2000-05-29  Jim Meyering  <meyering@lucent.com>
27653
27654         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
27655         mounts with the `ignore' attribute.  Based on a patch from
27656         Mark D. Roth.
27657
27658 2000-05-28  Jim Meyering  <meyering@lucent.com>
27659
27660         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
27661         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
27662         * m4/stat.m4: Likewise.
27663         * m4/lstat.m4: Likewise.
27664         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
27665
27666         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
27667         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
27668
27669 2000-05-26  Jim Meyering  <meyering@lucent.com>
27670
27671         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
27672
27673 2000-05-24  Jim Meyering  <meyering@lucent.com>
27674
27675         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
27676         autoconf requires that.
27677         * m4/lib-check.m4: Likewise.
27678         * m4/jm-macros.m4: Likewise.
27679         * m4/strftime.m4: Likewise.
27680
27681         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
27682         AC_CHECK_DECLS, now that autoconf requires that.
27683
27684 2000-05-22  Jim Meyering  <meyering@lucent.com>
27685
27686         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
27687         * m4/lstat.m4: Likewise.
27688
27689 2000-05-22  Jim Meyering  <meyering@lucent.com>
27690
27691         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
27692
27693 2000-05-20  Jim Meyering  <meyering@lucent.com>
27694
27695         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
27696         (jm_PREREQ): Use it.
27697
27698 2000-05-18  Jim Meyering  <meyering@lucent.com>
27699
27700         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
27701         back, too, since it may have been modified by allocate_entry.
27702         (hash_delete): Rewrite to use neither the assignment operator
27703         nor the comma operator in an if-expression.
27704
27705 2000-05-15  Paul Eggert  <eggert@twinsun.com>
27706
27707         * lib/closeout.c:
27708         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
27709         Remove; no longer needed.
27710         "quotearg.h": Add include.
27711         (file_name): Do not bother to explicitly initialize to NULL; it's less
27712         efficient on some hosts.
27713         (close_stdout_status): Remove test as to whether stdout was already
27714         closed; it breaks for the case "echo x | sort >&-".
27715         Quote file name colons.
27716         Do not assume that _("write error") lacks format strings.
27717
27718 2000-05-15  Jim Meyering  <meyering@lucent.com>
27719
27720         * lib/version-etc.c (version_etc_copyright): Update the copyright
27721         string used in all --version output.
27722
27723 2000-05-14  Jim Meyering  <meyering@lucent.com>
27724
27725         * lib/closeout.c (close_stdout_set_file_name): New function.
27726         (close_stdout_status): Use new file-scoped global.
27727         Return right away if fstat says the stdout file descriptor is invalid.
27728         * lib/closeout.h (close_stdout_set_file_name): Declare.
27729
27730 2000-05-10  Jim Meyering  <meyering@lucent.com>
27731
27732         * lib/closeout.c [default_exit_status]: New file-scoped variable.
27733         (close_stdout_set_status): New function.
27734         * lib/closeout.h (close_stdout_set_status): Declare.
27735
27736 2000-05-09  Jim Meyering  <meyering@lucent.com>
27737
27738         * m4/gettext.m4: Rename this...
27739         * m4/libintl.m4: ...to this.
27740
27741 2000-05-08  Jim Meyering  <meyering@lucent.com>
27742
27743         * lib/long-options.c: Don't include closeout.h.
27744         (parse_long_options): Don't call close_stdout for --version.
27745
27746 2000-05-06  Paul Eggert  <eggert@twinsun.com>
27747
27748         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
27749         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
27750         2.1.3 bug.  This avoids a clash when files like regex.c define
27751         _GNU_SOURCE.
27752
27753 2000-05-06  Jim Meyering  <meyering@lucent.com>
27754
27755         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
27756         (AC_REPLACE_FUNCS): Add strnlen.
27757
27758         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
27759         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
27760
27761         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
27762         AC_SEARCH_LIBS call for nanosleep.
27763         (LIB_NANOSLEEP): Set and AC_SUBST.
27764
27765 2000-05-06  Jim Meyering  <meyering@lucent.com>
27766
27767         * lib/strnlen.c: Undefine __strnlen and strnlen.
27768         [!weak_alias]: Define __strnlen to strnlen.
27769
27770         * lib/atexit.c: New file, from libiberty.
27771
27772 2000-05-06  Jim Meyering  <meyering@lucent.com>
27773
27774         * lib/closeout.c (close_stdout_status): Also check for errors on the
27775         stderr stream.
27776
27777 2000-05-05  Jim Meyering  <meyering@lucent.com>
27778
27779         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
27780         AC_SEARCH_LIBS call for clock_gettime.
27781         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
27782
27783         * m4/search-libs.m4: Update from autoconf.
27784
27785         su doesn't work on Solaris 2.6.
27786         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
27787         <shadow.h>.  Reported by Dragos Harabor.
27788
27789 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
27790
27791         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
27792         memcpy instead of xmalloc, xrealloc, path_concat.
27793         (locale_charset): Treat empty environment variables as absent.
27794         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
27795
27796 2000-05-04  Jim Meyering  <meyering@lucent.com>
27797
27798         * lib/getopt.c: Update from glibc.
27799         * lib/obstack.c: Likewise.
27800         * lib/obstack.h: Likewise.
27801         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
27802         file
27803
27804         * lib/regex.h: Likewise.
27805         * lib/strndup.c: Likewise.
27806         * lib/strnlen.c: New file, from glibc.
27807
27808 2000-05-03  Jim Meyering  <meyering@lucent.com>
27809
27810         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
27811
27812 2000-05-02  Paul Eggert  <eggert@twinsun.com>
27813
27814         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
27815         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
27816         compile-time test, rather than inspecting host and OS, to
27817         decide whether to define _LARGEFILE_SOURCE.
27818
27819 2000-05-01  Jim Meyering  <meyering@lucent.com>
27820
27821         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
27822
27823         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
27824         Based on a patch from Bruno Haible.
27825
27826 2000-05-01  Jim Meyering  <meyering@lucent.com>
27827
27828         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
27829
27830 2000-04-29  Jim Meyering  <meyering@lucent.com>
27831
27832         * lib/path-concat.c: Declare strdup only if it's not defined.
27833         * lib/canon-host.c: Likewise.
27834
27835 2000-04-28  Jim Meyering  <meyering@lucent.com>
27836
27837         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
27838         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
27839         is included first, then limits.h is included by locale.h by libintl.h.
27840         From John David Anglin.
27841
27842 2000-04-25  Jim Meyering  <meyering@lucent.com>
27843
27844         * lib/makepath.c (S_IRWXUGO): Define.
27845         (make_path): Always perform explicit chmod if MODE specifies any
27846         of the `special' permission bits.  Prompted by a bug report against
27847         install from Mate Wierdl and Joost van Baal.
27848
27849 2000-04-18  Jim Meyering  <meyering@lucent.com>
27850
27851         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
27852         (jm_PREREQ): Use it.
27853
27854 2000-04-18  Jim Meyering  <meyering@lucent.com>
27855
27856         * lib/README: New file.
27857
27858         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
27859         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
27860
27861 2000-04-17  Jim Meyering  <meyering@lucent.com>
27862
27863         Get it right :-)
27864         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
27865         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
27866         Suggestion from Akim Demaille.
27867
27868 2000-04-17  Jim Meyering  <meyering@lucent.com>
27869
27870         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
27871         the definition of it to rpl_strftime also defined-away the system's
27872         declaration.
27873
27874 2000-04-15  Jim Meyering  <meyering@lucent.com>
27875
27876         Use `C' to denote so-called `contiguous' files, the same way
27877         that tar does.
27878         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
27879         (ftypelet): Use S_ISCTG.
27880         From Michael Deutschmann.
27881
27882 2000-04-14  Jim Meyering  <meyering@lucent.com>
27883
27884         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
27885         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
27886         clobbered.
27887
27888 2000-04-14  Jim Meyering  <meyering@lucent.com>
27889
27890         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
27891
27892 2000-04-13  Jim Meyering  <meyering@lucent.com>
27893
27894         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
27895         AH_VERBATIM to insert required #ifndef into config.h.in.
27896         Suggestion from Akim Demaille.
27897
27898 2000-04-12  Jim Meyering  <meyering@lucent.com>
27899
27900         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
27901         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
27902         Christian Krackowizer.
27903
27904         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
27905         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
27906         (AC_SYS_LARGEFILE): Require.
27907         (AM_C_PROTOTYPES): Require.
27908
27909 2000-04-08  Jim Meyering  <meyering@lucent.com>
27910
27911         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
27912         names don't conflict.  Reported by Eli Zaretskii.
27913
27914 2000-04-07  Jim Meyering  <meyering@lucent.com>
27915
27916         * lib/putenv.c: Move inclusion of errno.h so it follows that of
27917         sys/types.h, to work around system header problems on AIX 3.2.5.
27918         From Bruno Haible.
27919
27920 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
27921
27922         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
27923         bug.  Deal with the different error behavior of Irix iconv.
27924
27925 2000-04-05  Paul Eggert  <eggert@twinsun.com>
27926
27927         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
27928         IRIX if the installer said otherwise.
27929
27930 2000-04-05  Jim Meyering  <meyering@lucent.com>
27931
27932         Portability tweaks required for ultrix4.3.
27933         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
27934         (jm_CHECK_DECLS): Add getutent to the list of functions.
27935         (_jm_DECL_HEADERS): Add utmpx.h.
27936         From John David Anglin.
27937
27938         * m4/strftime.m4: Back out the 2000-04-02 change.
27939         Instead of that change, simply undefine putenv in the test program.
27940
27941 2000-04-05  Jim Meyering  <meyering@lucent.com>
27942
27943         Portability tweaks required for ultrix4.3.
27944         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
27945         getutent.
27946         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
27947         * lib/canon-host.c: Declare strdup.
27948         * lib/path-concat.c: Likewise.
27949         From John David Anglin.
27950
27951 2000-04-04  Jim Meyering  <meyering@lucent.com>
27952
27953         Be more DOS 8.3-friendly.
27954         * lib/ref-add.sin: Renamed from ref-add.sed.in.
27955         * lib/ref-del.sin: Renamed from ref-del.sed.in.
27956         * lib/Makefile.am: Reflect renaming.
27957         Reported by Eli Zaretskii.
27958
27959         Use a temporary file name that won't clash with `charset.alias'
27960         in the DOS 8.3 name space.
27961         * lib/Makefile.am (charset_tmp): Define.
27962         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
27963         (uninstall-local): Likewise.
27964         Reported by Eli Zaretskii.
27965
27966 2000-04-03  Jim Meyering  <meyering@lucent.com>
27967
27968         * m4/gettext.m4: Fix typo in comment.
27969
27970         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
27971         textutils/configure.in).  Suggestion from Paul Eggert.
27972         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
27973
27974 2000-04-02  Paul Eggert  <eggert@twinsun.com>
27975
27976         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
27977         variable in the shell rather than using putenv, which isn't
27978         portable.  This avoids the configure-time inter-test dependency
27979         on the potentially-renamed putenv function.
27980
27981 2000-03-30  Paul Eggert  <eggert@twinsun.com>
27982
27983         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
27984         before checking struct stat.st_blksize, so that
27985         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
27986
27987 2000-03-29  Paul Eggert  <eggert@twinsun.com>
27988
27989         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
27990         since strftime.c uses HAVE_STRFTIME to decide whether to use
27991         the underlying strftime.
27992
27993 2000-03-29  Paul Eggert  <eggert@twinsun.com>
27994
27995         * lib/time/strftime.c (my_strftime): Make sure we call the system
27996         strftime, not ourselves, when invoking the underlying strftime.
27997
27998 2000-03-24  Jim Meyering  <meyering@lucent.com>
27999
28000         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
28001         (charset_alias): Define.
28002         (install-exec-local): Factor out common code.
28003         (uninstall-local): Split lines longer than 80.
28004         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
28005         (SUFFIXES): Define.
28006         (.sed.in.sed): New rule.  Don't redirect directly to $@.
28007         (CLEANFILES): Add ref-add.sed and ref-del.sed.
28008
28009 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
28010
28011         * lib/config.charset: Output a line containing "Packages using this
28012         file".
28013         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
28014         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
28015         ref-del.sed): New rules.
28016
28017 2000-03-17  Jim Meyering  <meyering@lucent.com>
28018
28019         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
28020         Otherwise, include <strings.h>
28021
28022 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
28023
28024         * lib/unicodeio.c (utf8_wctomb): New function.
28025         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
28026         format instead of in UCS-4 with platform dependent endianness.
28027
28028 2000-03-10  Jim Meyering  <meyering@lucent.com>
28029
28030         * m4/lib-check.m4: Look for getspnam in -lgen, too.
28031         From Marco Franzen.
28032
28033 2000-03-07  Paul Eggert  <eggert@twinsun.com>
28034
28035         * lib/savedir.c (savedir): Work even if directory size is
28036         negative; this can happen with some screwy NFS configurations.
28037
28038 2000-03-06  Jim Meyering  <meyering@lucent.com>
28039
28040         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
28041         if it's NULL (because we ran out of memory).  From Bruno Haible.
28042
28043 2000-03-05  Jim Meyering  <meyering@lucent.com>
28044
28045         * lib/localcharset.c ("path-concat.h"): Include.
28046         (get_charset_aliases): Use path_concat instead of ANSI string
28047         concatenation.
28048
28049         * lib/unicodeio.h (PARAMS): Define.
28050         Use it to guard prototype.
28051
28052 2000-03-04  Jim Meyering  <meyering@lucent.com>
28053
28054         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
28055         for lib/localcharset.c.
28056
28057 2000-03-04  Jim Meyering  <meyering@lucent.com>
28058
28059         * lib/Makefile.am (install-exec-local): Create $(libdir) before
28060         installing into it.
28061         (uninstall-local): Uncomment this rule so `make distcheck' works
28062         once again.
28063
28064         * lib/unicodeio.c (<errno.h>): Include it.
28065         (errno): Declare if not defined.
28066
28067         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
28068
28069         * lib/config.charset: New version, incorporating remarks from a linux
28070         i18n mailing list.  From Bruno Haible.
28071
28072 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
28073
28074         * m4/codeset.m4: New file.
28075         * m4/iconv.m4: New file.
28076         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
28077
28078 2000-03-03  Jim Meyering  <meyering@lucent.com>
28079
28080         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
28081
28082 2000-03-02  Jim Meyering  <meyering@lucent.com>
28083
28084         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
28085         the messages come out on separate lines.
28086
28087         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
28088         rather than jm_CHECK_DECLARATIONS.
28089         * m4/decl.m4: Remove now-unused file.
28090
28091         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
28092         geteuid.
28093
28094 2000-03-02  Jim Meyering  <meyering@lucent.com>
28095
28096         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
28097
28098 2000-03-01  Jim Meyering  <meyering@lucent.com>
28099
28100         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
28101         * lib/unicodeio.c: Likewise.
28102
28103 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
28104
28105         * lib/config.charset: New file.
28106         * lib/localcharset.c: New file.
28107         * lib/unicodeio.h, lib/unicodeio.c: New files.
28108         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
28109         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
28110         (noinst_HEADERS): Add unicodeio.h.
28111         (all-local, install-exec-local, charset.alias): New targets.
28112
28113 2000-02-28  Paul Eggert  <eggert@twinsun.com>
28114
28115         * lib/quotearg.c (ALERT_CHAR): New macro.
28116         (quotearg_buffer_restyled): Use it.
28117
28118 2000-02-27  Jim Meyering  <meyering@lucent.com>
28119
28120         * m4/check-decl.m4: Add getenv to the list.
28121
28122 2000-02-27  Jim Meyering  <meyering@lucent.com>
28123
28124         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
28125         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
28126
28127         * lib/backupfile.c: Guard inclusion of stdlib.h with
28128         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
28129         Declare malloc if needed.
28130
28131         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
28132         `#ifndef HAVE_DECL..'
28133         now that autoconf always defines the HAVE_DECL_ symbols.
28134         * lib/human.c: Likewise.
28135         * lib/same.c: Likewise.
28136         * lib/strtoumax.c: Likewise.
28137
28138         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
28139         declaration check was not run.
28140         * lib/hash.c: Likewise.
28141         * lib/human.c: Likewise.
28142         * lib/same.c: Likewise.
28143         * lib/strtoumax.c: Likewise.
28144
28145         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
28146         `.', then first look up the entire `.'-containing string as a login
28147         name.
28148
28149 2000-02-23  Jim Meyering  <meyering@lucent.com>
28150
28151         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
28152         in place of my hack.
28153
28154 2000-02-18  Paul Eggert  <eggert@twinsun.com>
28155
28156         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
28157         (textint): New typedef.
28158         (parser_control): Member year changed from int to textint.
28159         All uses changed.
28160         (YYSTYPE): Removed; replaced by %union with int and textint members.
28161         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
28162         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
28163         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
28164         (tSNUMBER, tUNUMBER): Now of type <textintval>.
28165         (date, number, to_year): Use width of number in digits, not its value,
28166         to determine whether it's a 2-digit year, or a 2-digit time.
28167         (yylex): Store number of digits of numeric tokens.
28168         Reported by John Kendall.
28169
28170         (parser_control): Changed from struct parser_control to typedef (for
28171         consistency).  All uses changed.
28172
28173         (tID): Removed; not used.
28174         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
28175
28176 2000-02-14  Paul Eggert  <eggert@twinsun.com>
28177
28178         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
28179         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
28180
28181 2000-02-12  Jim Meyering  <meyering@lucent.com>
28182
28183         * lib/userspec.c (ISDIGIT): Define it.
28184         (isdigit): Remove definition.
28185         (is_number): Use ISDIGIT, not isdigit.
28186         <libintl.h>: Include.
28187         (_ and N_): Define.
28188         (parse_user_spec): Mark translatable strings.
28189
28190 2000-02-10  Jim Meyering  <meyering@lucent.com>
28191
28192         With these changes, nanosleep.[ch] are finally enough like the other
28193         lib/* replacement files to compile on a few more losing systems.
28194
28195         * lib/nanosleep.h: Don't include config.h.
28196         Remove prototype from declaration of nanosleep.
28197         (PARAMS): Remove now-unneeded definition.
28198         * lib/nanosleep.c: #undef nanosleep.
28199         (rpl_nanosleep): Rename from nanosleep.
28200
28201 2000-02-10  Jim Meyering  <meyering@lucent.com>
28202
28203         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
28204         gnu_nanosleep to rpl_nanosleep.
28205
28206 2000-02-09  Jim Meyering  <meyering@lucent.com>
28207
28208         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
28209         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
28210
28211 2000-02-08  Akim Demaille  <akim@epita.fr>
28212
28213         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
28214         `[' and `]' and remove uses of `changequote'.
28215         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
28216         (AC_SYS_LARGEFILE): Likewise.
28217         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
28218         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
28219         of changequote.
28220         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
28221         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
28222         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
28223         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
28224
28225 2000-02-05  Jim Meyering  <meyering@lucent.com>
28226
28227         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
28228         Remove explicit use of AC_HEADER_TIME.  It is required by
28229         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
28230         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
28231         in autoconf whereby the expansion of the latter ended up preceding
28232         the expansion of its prerequisite, AC_HEADER_TIME.
28233         Reported by Volker Borchert.
28234
28235 2000-02-03  Jim Meyering  <meyering@lucent.com>
28236
28237         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
28238
28239 2000-02-03  Jim Meyering  <meyering@lucent.com>
28240
28241         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
28242         rather than with `#if HAVE_UTMPNAME'.
28243
28244 2000-02-02  Jim Meyering  <meyering@lucent.com>
28245
28246         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
28247         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
28248         Reported by Eli Zaretskii.
28249
28250 2000-02-01  Jim Meyering  <meyering@lucent.com>
28251
28252         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
28253
28254 2000-01-31  Jim Meyering  <meyering@lucent.com>
28255
28256         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
28257         functions.  Add the time.h and sys/time.h headers along with the
28258         AC_REQUIRE'ment of AC_HEADER_TIME.
28259
28260 2000-01-31  Jim Meyering  <meyering@lucent.com>
28261
28262         * lib/nanosleep.h (nanosleep): Guard declaration with
28263         `#if ! HAVE_DECL_NANOSLEEP'.
28264         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
28265         the declaration in that vendor's sys/timers.h.
28266         Reported by Christian Krackowizer.
28267
28268         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
28269         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
28270         (ISPRINT): Likewise.
28271         Reported by Tom Tromey.
28272
28273 2000-01-30  Jim Meyering  <meyering@lucent.com>
28274
28275         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
28276
28277         * m4/prereq.m4 (utmp_includes): Define.
28278         Check for ut_user and ut_name members in both struct utmpx
28279         and struct utmp.
28280
28281 2000-01-30  Jim Meyering  <meyering@lucent.com>
28282
28283         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
28284         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
28285         header files where only utmpx.ut_user is declared.
28286
28287         * lib/readutmp.h (UT_USER): Define.
28288
28289 2000-01-29  Jim Meyering  <meyering@lucent.com>
28290
28291         * m4/lib-check.m4: New file containing library-related checks from
28292         fileutils and sh-utils (textutils had none).
28293
28294 2000-01-28  Jim Meyering  <meyering@lucent.com>
28295
28296         * m4/perl.m4: Change format of warning message to look more like that
28297         from the missing script.  Suggestion from François Pinard.
28298
28299 2000-01-25  Jim Meyering  <meyering@lucent.com>
28300
28301         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
28302         well as time.h in the compile check.
28303         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
28304         Fix typo in cross-compiling case: s/yes/no/.
28305
28306 2000-01-23  Jim Meyering  <meyering@lucent.com>
28307
28308         * m4/jm-macros.m4: Move df-related tests here from
28309         fileutils/configure.in
28310
28311         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
28312         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
28313
28314         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
28315         s/space/ac_fsusage_space/.
28316         (jm_FILE_SYSTEM_USAGE): Take two parameters.
28317
28318         * m4/ftruncate.m4: New file (derived from part of
28319         fileutils/configure.in).
28320         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
28321         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
28322
28323         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
28324         AC_SUBST these here, rather than just in sh-util/configure.in, so
28325         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
28326         all the same.
28327         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
28328         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
28329         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
28330         (AC_SUBST(POW_LIBM)): Likewise.
28331         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
28332
28333 2000-01-23  Jim Meyering  <meyering@lucent.com>
28334
28335         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
28336         obstack.c.
28337
28338 2000-01-22  Jim Meyering  <meyering@lucent.com>
28339
28340         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
28341
28342         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
28343
28344         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
28345         configure.in
28346         (AC_CHECK_HEADERS): Likewise for sh-utils.
28347         (AC_CHECK_HEADERS): Likewise for textutils.
28348         Merge the three lists of headers.
28349
28350         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
28351         from fileutils' configure.in.
28352
28353         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
28354         code. Moved tests into their own function (_jm_DECL_HEADERS) in
28355         check-decl.m4.
28356
28357         * m4/check-decl.m4: Use #if rather than #ifdef.
28358         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
28359         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
28360         (_jm_DECL_HEADERS): Define new function.
28361         (jm_CHECK_DECLARATIONS): Require it.
28362
28363 2000-01-22  Jim Meyering  <meyering@lucent.com>
28364
28365         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
28366         [! HAVE_DECL_STRTOULL]: Declare strtoull.
28367         Required for some AIX systems.  Reported by Christian Krackowizer.
28368         [TESTING] (main): New function.
28369
28370         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
28371         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
28372         letters.
28373
28374         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
28375         iswprint.
28376
28377         * lib/strverscmp.c (ISDIGIT): Define.
28378         (strverscmp): Use ISDIGIT, not isdigit.
28379
28380 2000-01-19  Jim Meyering  <meyering@lucent.com>
28381
28382         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
28383         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
28384         defines `struct timespec' in <sys/time.h>
28385
28386         * m4/c-bs-a.m4: Remove uses of changequote altogether.
28387         Thanks to Akim for explaining.
28388
28389 2000-01-17  Paul Eggert  <eggert@twinsun.com>
28390
28391         * lib/nanosleep.c (nanosleep):
28392         Don't use SA_INTERRUPT to decide whether to call sigaction, as
28393         POSIX.1 doesn't require SA_INTERRUPT and some systems
28394         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
28395         it's been part of POSIX.1 since day 1 (in 1988).
28396
28397 2000-01-17  Jim Meyering  <meyering@lucent.com>
28398
28399         * lib/interlock: Remove unused file.  Reported by François Pinard.
28400
28401 2000-01-16  Paul Eggert  <eggert@twinsun.com>
28402
28403         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
28404         alert, backslash, formfeed, and vertical tab unnecessarily in
28405         shell quoting style.
28406
28407 2000-01-16  Jim Meyering  <meyering@lucent.com>
28408
28409         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
28410         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
28411         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
28412         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
28413
28414 2000-01-16  Jim Meyering  <meyering@lucent.com>
28415
28416         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
28417         because the latter didn't work.
28418
28419 2000-01-15  Jim Meyering  <meyering@lucent.com>
28420
28421         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
28422         (AC_REPLACE_FUNCS): Add memcpy and memset.
28423         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
28424         Add strpbrk.
28425         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
28426
28427 2000-01-12  Jim Meyering  <meyering@lucent.com>
28428
28429         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
28430         (jm_PREREQ): Use it.
28431         (jm_PREREQ_READUTMP): New macro.
28432         (jm_PREREQ): Use it.
28433
28434 2000-01-11  Paul Eggert  <eggert@twinsun.com>
28435
28436         Quote multibyte characters correctly.
28437         * m4/c-bs-a.m4: New file.
28438         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
28439         (jm_PREREQ): Use it.
28440
28441 2000-01-11  Paul Eggert  <eggert@twinsun.com>
28442
28443         * m4/uintmax_t.m4: Port to autoconf 2.13.
28444
28445 2000-01-08  Jim Meyering  <meyering@ascend.com>
28446
28447         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
28448         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
28449
28450 2000-01-04  Jim Meyering  <meyering@ascend.com>
28451
28452         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
28453         jm_STRUCT_DIRENT_D_TYPE.
28454         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
28455         jm_STRUCT_DIRENT_D_INO.
28456         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
28457         jm_STRUCT_UTIMBUF.
28458         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
28459         renamings.
28460         * m4/utime.m4: Likewise.
28461
28462         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
28463         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
28464
28465 2000-01-03  Paul Eggert  <eggert@twinsun.com>
28466
28467         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
28468         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
28469
28470 2000-01-02  Jim Meyering  <meyering@ascend.com>
28471
28472         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
28473         remember if this is necessary.
28474
28475 1999-12-26  Jim Meyering  <meyering@ascend.com>
28476
28477         * m4/jm-macros.m4: Use it here.
28478         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
28479
28480 1999-12-23  Jim Meyering  <meyering@ascend.com>
28481
28482         * m4/jm-macros.m4: Check for clock_gettime (moved from
28483         fileutils/configure.in)
28484         Check for gettimeofday.
28485
28486 1999-12-20  Jim Meyering  <meyering@ascend.com>
28487
28488         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
28489         autoconf-2.14a-1999-12-20.
28490
28491 1999-12-19  Jim Meyering  <meyering@ascend.com>
28492
28493         * m4/lstat-slash.m4: New file.
28494         * m4/jm-macros.m4: Use the new macro:
28495         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
28496
28497 1999-12-07  Jim Meyering  <meyering@ascend.com>
28498
28499         * m4/perl.m4: Require that File::Compare be available, too.
28500         Too many systems seem to lack it.
28501
28502         * m4/strftime.m4: Add checks for most of the cpp macros tested in
28503         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
28504
28505 1999-11-18  Paul Eggert  <eggert@twinsun.com>
28506
28507         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
28508         problem with the QNX 4.25 shell, which doesn't propagate exit
28509         status of failed commands inside shell assignments.
28510
28511 1999-11-17  Jim Meyering  <meyering@ascend.com>
28512
28513         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
28514
28515 1999-11-07  Jim Meyering  <meyering@ascend.com>
28516
28517         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
28518
28519 1999-11-06  Jim Meyering  <meyering@ascend.com>
28520
28521         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
28522         * m4/jm-macros.m4 (jm_MACROS): Use it here.
28523
28524 1999-11-05  Jim Meyering  <meyering@ascend.com>
28525
28526         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
28527         configure.in of textutils, fileutils, and sh-utils into this one
28528         (shared between those packages) file.
28529         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
28530         AC_STRUCT_ST_BLKSIZE.
28531
28532 1999-11-03  Jim Meyering  <meyering@ascend.com>
28533
28534         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
28535         of AC_CHECK_TYPE checks includes unistd.h.
28536         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
28537         Suggestion from Akim Demaille.
28538
28539 1999-10-30  Jim Meyering  <meyering@ascend.com>
28540
28541         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
28542         m4-quoted string.
28543         * m4/ls-mntd-fs.m4: Likewise.
28544         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
28545         * m4/jm-winsz1.m4: Likewise.
28546
28547         * m4/const.m4: Remove file, since the fix made it into the experimental
28548         version of autoconf.
28549         * m4/mktime.m4: Likewise.
28550
28551         * m4/check-type.m4: Remove file, now that the latest version of
28552         AC_CHECK_TYPE takes a third arg to specify additional #includes.
28553
28554         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
28555         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
28556         AC_CHECK_TYPE.
28557
28558 1999-10-04  Jim Meyering  <meyering@ascend.com>
28559
28560         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
28561
28562 1999-09-22  Paul Eggert  <eggert@twinsun.com>
28563
28564         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
28565         2.95.1 bug with HP-UX 10.20.
28566
28567 1999-09-17  Jim Meyering  <meyering@ascend.com>
28568
28569         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
28570         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
28571         due to missing strdup (against sh-utils-2.0).
28572
28573 1999-08-29  Jim Meyering  <meyering@ascend.com>
28574
28575         * m4/jm-macros.m4: Require jm_BISON.
28576         * m4/bison.m4: New file.
28577
28578 1999-08-17  Paul Eggert  <eggert@twinsun.com>
28579
28580         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
28581         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
28582
28583 1999-08-05  Jim Meyering  <meyering@ascend.com>
28584
28585         * m4/getline.m4: Rename test file from conftestdata to conftest.data
28586         to avoid conflicts with `conftest' on 8+3 filesystems.
28587         Suggestion from Eli Zaretskii.
28588
28589 1999-08-04  Jim Meyering  <meyering@ascend.com>
28590
28591         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
28592         fileutils and sh-utils (textutils's getline test was inadequate).
28593         (AM_FUNC_GETLINE): Run this test.
28594         (AC_CHECK_FUNCS): Check for getdelim.
28595         Reported by Bob Proulx.
28596
28597 1999-08-02  Jim Meyering  <meyering@ascend.com>
28598
28599         * m4/jm-macros.m4: Add a comment.
28600
28601 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28602
28603         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
28604         <inttypes.h> defines strtoumax as a macro (and not as a
28605         function).
28606
28607 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28608
28609         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
28610         that we can shift, multiply and divide unsigned long long
28611         values; Ultrix cc can't do it.
28612
28613 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28614
28615         * m4/mktime.m4: New file, which is a preview of what should appear
28616         in the next public autoconf release.
28617
28618 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28619
28620         * m4/lfs.m4: Remove this file.
28621         * m4/largefile.m4: New file.  It contains the old contents of
28622         lfs.m4, except that all names with prefix AC_LFS have been
28623         changed to use the prefix AC_SYS_LARGEFILE instead, to be
28624         compatible with future autoconf versions.  Also, some minor m4
28625         quoting problems have been fixed.
28626
28627 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28628
28629         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
28630         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
28631         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
28632         and simplify the shell code.
28633
28634 1999-08-01  Jim Meyering  <meyering@ascend.com>
28635
28636         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
28637         m4.
28638
28639 1999-07-20  Jim Meyering  <meyering@ascend.com>
28640
28641         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
28642
28643 1999-07-15  Jim Meyering  <meyering@ascend.com>
28644
28645         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
28646
28647 1999-05-22  Jim Meyering  <meyering@ascend.com>
28648
28649         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
28650
28651 1999-05-20  Jim Meyering  <meyering@ascend.com>
28652
28653         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
28654         Add a colon after each `then' in case $4 is empty.
28655
28656 1999-05-16  Jim Meyering  <meyering@ascend.com>
28657
28658         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
28659
28660 1999-05-10  Jim Meyering  <meyering@ascend.com>
28661
28662         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
28663
28664         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
28665         AC_FUNC_MKTIME.
28666
28667 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
28668
28669         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
28670
28671 1999-05-04  Paul Eggert  <eggert@twinsun.com>
28672
28673         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
28674         not CPPFLAGS, so that linking works correctly in IRIX.
28675
28676 1999-04-30  Paul Eggert  <eggert@twinsun.com>
28677
28678         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
28679
28680 1999-04-20  Paul Eggert  <eggert@twinsun.com>
28681
28682         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
28683         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
28684         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
28685         jm_AC_TYPE_UNSIGNED_LONG_LONG.
28686         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
28687
28688         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
28689
28690 1999-04-20  Jim Meyering  <meyering@ascend.com>
28691
28692         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
28693         AC_REPLACE xstroull if necessary.  From Paul Eggert.
28694         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
28695
28696 1999-04-18  Jim Meyering  <meyering@ascend.com>
28697
28698         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
28699         * m4/jm-macros.m4: Use it.
28700
28701 1999-04-06  Jim Meyering  <meyering@ascend.com>
28702
28703         * m4/strftime.m4: Remove test for %f.
28704
28705 1999-03-29  Jim Meyering  <meyering@ascend.com>
28706
28707         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
28708         superset of the AC_TYPE_* checks in the textutils, fileutils,
28709         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
28710         AC_TYPE_PID_T.
28711
28712 1999-03-28  Jim Meyering  <meyering@ascend.com>
28713
28714         * m4/jm-macros.m4: Define GNU_PACKAGE here.
28715         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
28716         replaced e.g., in the *.sh files of the sh-utils.
28717
28718 1999-03-20  Jim Meyering  <meyering@ascend.com>
28719
28720         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
28721         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
28722         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
28723
28724 1999-03-19  Jim Meyering  <meyering@ascend.com>
28725
28726         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
28727
28728 1999-03-12  Jim Meyering  <meyering@ascend.com>
28729
28730         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
28731
28732 1999-03-07  Jim Meyering  <meyering@ascend.com>
28733
28734         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
28735         declared.
28736
28737 1999-02-17  Jim Meyering  <meyering@ascend.com>
28738
28739         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
28740         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
28741
28742 1999-02-07  Jim Meyering  <meyering@ascend.com>
28743
28744         * m4/group-member.m4: New file -- extracted from sh-utils'
28745         configure.in.
28746
28747         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
28748         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
28749
28750 1999-02-06  Jim Meyering  <meyering@ascend.com>
28751
28752         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
28753         * m4/fnmatch.m4: Likewise.
28754         * m4/getgroups.m4: Likewise.
28755         * m4/lstat.m4: Likewise.
28756         * m4/malloc.m4: Likewise.
28757         * m4/putenv.m4: Likewise.
28758         * m4/realloc.m4: Likewise.
28759         * m4/regex.m4: Likewise.
28760         * m4/stat.m4: Likewise.
28761         * m4/strftime.m4: Likewise.
28762         Suggestion from Alain Magloire.
28763
28764         * m4/chown.m4: Use `.$ac_objext', not `.o'.
28765         * m4/fnmatch.m4: Likewise.
28766         * m4/getgroups.m4: Likewise.
28767         * m4/getline.m4: Likewise.
28768         * m4/lstat.m4: Likewise.
28769         * m4/malloc.m4: Likewise.
28770         * m4/memcmp.m4: Likewise.
28771         * m4/putenv.m4: Likewise.
28772         * m4/realloc.m4: Likewise.
28773         * m4/regex.m4: Likewise.
28774         * m4/stat.m4: Likewise.
28775         * m4/strftime.m4: Likewise.
28776         Suggestion from Alain Magloire.
28777
28778         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
28779         an argument.
28780
28781         * m4/regex.m4: Add a run-time Test for proper operation of
28782         re_compile_pattern.
28783
28784 1999-01-31  Jim Meyering  <meyering@ascend.com>
28785
28786         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
28787
28788 1999-01-30  Jim Meyering  <meyering@ascend.com>
28789
28790         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
28791
28792         * m4/jm-mktime.m4: Make this a wrapper around the official
28793         AM_FUNC_MKTIME rather than my private copy, now that the official one
28794         is up to date.
28795         * m4/mktime.m4: Remove file.
28796
28797         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
28798         * m4/uptime.m4: Likewise.
28799         * m4/uintmax_t.m4: Likewise.
28800
28801 1999-01-28  Jim Meyering  <meyering@ascend.com>
28802
28803         * m4/jm-macros.m4: Use jm_AFS.
28804         * m4/afs.m4: New file (from fileutils' configure.in).
28805
28806         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
28807         * m4/chown.m4: Likewise.
28808         * m4/d-ino.m4: Likewise.
28809         * m4/d-type.m4: Likewise.
28810         * m4/fnmatch.m4: Likewise.
28811         * m4/getgroups.m4: Likewise.
28812         * m4/gettext.m4: Likewise.
28813         * m4/jm-mktime.m4: Likewise.
28814         * m4/jm-winsz2.m4: Likewise.
28815         * m4/lcmessage.m4: Likewise.
28816         * m4/ls-mntd-fs.m4: Likewise.
28817         * m4/malloc.m4: Likewise.
28818         * m4/memcmp.m4: Likewise.
28819         * m4/putenv.m4: Likewise.
28820         * m4/realloc.m4: Likewise.
28821         * m4/st_mtim.m4: Likewise.
28822         * m4/strftime.m4: Likewise.
28823
28824 1999-01-16  Jim Meyering  <meyering@ascend.com>
28825
28826         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
28827         (ARGMATCH_DIE_DECL): Define.
28828
28829 1999-01-12  Jim Meyering  <meyering@ascend.com>
28830
28831         * m4/Makefile.am.in: Rewrite to avoid using fmt.
28832         Reported by Lars Hecking.
28833
28834 1999-01-10  Jim Meyering  <meyering@ascend.com>
28835
28836         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
28837         gross kludge.
28838         * m4/inttypes_h.m4: Likewise.
28839         * m4/lstat.m4: Likewise.
28840         * m4/malloc.m4: Likewise.
28841         * m4/readdir.m4: Likewise.
28842         * m4/realloc.m4: Likewise.
28843         * m4/st_dm_mode.m4: Likewise.
28844         * m4/stat.m4: Likewise.
28845         * m4/utimbuf.m4: Likewise.
28846         * m4/utimes.m4: Likewise.
28847
28848         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
28849         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
28850         comments in config.h.in are meaningful.
28851
28852         * m4/jm-macros.m4: Require autoconf-2.13 here.
28853
28854         * m4/regex.m4: By default, don't use the included regex.c on systems
28855         with glibc 2.  Suggestion from Uli Drepper.
28856
28857 1999-01-02  Jim Meyering  <meyering@ascend.com>
28858
28859         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
28860
28861 1998-12-18  Jim Meyering  <meyering@ascend.com>
28862
28863         * m4/Makefile.am.in (Makefile.am): Simplify rule.
28864         Based on a suggestion from Lars Hecking.
28865
28866 1998-11-16  Paul Eggert  <eggert@twinsun.com>
28867
28868         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
28869
28870 1998-11-16  Jim Meyering  <meyering@ascend.com>
28871
28872         * m4/lfs.m4: Double-quote the `uname...` expression.
28873
28874 1998-11-14  Jim Meyering  <meyering@ascend.com>
28875
28876         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
28877         * m4/stat.m4: Likewise.
28878
28879 1998-11-03  Jim Meyering  <meyering@ascend.com>
28880
28881         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
28882         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
28883
28884 1998-10-18  Jim Meyering  <meyering@ascend.com>
28885
28886         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
28887
28888 1998-10-17  Jim Meyering  <meyering@ascend.com>
28889
28890         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
28891         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
28892         calls for those previously hard-coded headers.  Instead, take a new
28893         parameter.
28894         (jm_CHECK_DECLARATIONS): Reflect interface change.
28895         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
28896         (jm_CHECK_DECL_LOCALTIME_R): New macro.
28897
28898         * m4/mktime.m4: Test for spring-forward gap before long-running test.
28899
28900 1998-10-14  Jim Meyering  <meyering@ascend.com>
28901
28902         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
28903         instead of "TZ=America/Vancouver".  From Paul Eggert.
28904
28905 1998-10-11  Jim Meyering  <meyering@ascend.com>
28906
28907         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
28908         This adds a test for a recently added compatibility fix for mktime.c.
28909         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
28910
28911 1998-09-27  Jim Meyering  <meyering@ascend.com>
28912
28913         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
28914
28915         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
28916         ../configure.in, including a change from Gordon Matzigkeit to allow
28917         cross-compiling for the Hurd.
28918
28919         * m4/glibc.m4: New file/macro to test for the GNU C Library
28920         versions 1 and 2.  From Gordon Matzigkeit.
28921         Indent.
28922
28923 1998-09-21  Jim Meyering  <meyering@ascend.com>
28924
28925         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
28926
28927 1998-08-18  Paul Eggert  <eggert@twinsun.com>
28928
28929         Port nanosecond-resolution times to UnixWare 2.1.2 and
28930         pedantic Solaris 2.6.
28931
28932         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
28933         AC_STRUCT_ST_MTIM.
28934         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
28935         Generate name of ns member, instead of just 1 or undef.
28936         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
28937
28938 1998-08-15  Jim Meyering  <meyering@ascend.com>
28939
28940         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
28941         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
28942         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
28943         instead of jm_TYPE_SSIZE_T.
28944
28945 1998-08-12  Jim Meyering  <meyering@ascend.com>
28946
28947         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
28948
28949 1998-08-02  Jim Meyering  <meyering@ascend.com>
28950
28951         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
28952         in acconfig.h manually.
28953
28954 1998-07-31  Paul Eggert  <eggert@twinsun.com>
28955
28956         * m4/st_mtim.m4: New file.
28957
28958 1998-07-28  Jim Meyering  <meyering@ascend.com>
28959
28960         * m4/utimes.m4: Undef stat.
28961
28962 1998-07-25  Jim Meyering  <meyering@ascend.com>
28963
28964         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
28965         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
28966
28967 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
28968
28969         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
28970         uid and gid actually remain unchanged.
28971
28972 1998-07-07  Jim Meyering  <meyering@ascend.com>
28973
28974         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
28975
28976 1998-07-04  Jim Meyering  <meyering@ascend.com>
28977
28978         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
28979         to prove that this macro can be used in packages without regex.c.
28980
28981 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
28982
28983         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
28984         is to be used.
28985
28986 1998-07-03  Jim Meyering  <meyering@ascend.com>
28987
28988         * m4/gettext.m4: Add -lintl if it's found to be necessary.
28989
28990         * m4/gettext.m4: New file -- from gettext-0.10.35.
28991         * m4/lcmessage.m4: Likewise.
28992         * m4/progtest.m4: Likewise.
28993
28994         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
28995         * m4/jm-macros.m4: Require the new macro.
28996
28997 1998-06-29  Jim Meyering  <meyering@ascend.com>
28998
28999         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
29000         for the definition of NGROUPS (used in a system header included
29001         by sys/mount.h).
29002
29003 1998-06-28  Jim Meyering  <meyering@ascend.com>
29004
29005         * m4/ls-mntd-fs.m4: New file.
29006         * m4/fstypename.m4: New file.
29007
29008         * m4/jm-macros.m4: Require the new macro.
29009         * m4/jm-glibc-io.m4: New file.
29010
29011 1998-05-19  Jim Meyering  <meyering@ascend.com>
29012
29013         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
29014         * m4/lchown.m4: New file.
29015
29016         * m4/Makefile.am.in: New file.
29017         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
29018
29019 1998-05-14  Jim Meyering  <meyering@ascend.com>
29020
29021         * m4/Makefile.am (EXTRA_DIST): Add them.
29022         * m4/jm-macros.m4: New file.
29023         * m4/utimbuf.m4: New file.
29024
29025 1998-05-12  Jim Meyering  <meyering@ascend.com>
29026
29027         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
29028
29029 1998-05-11  Jim Meyering  <meyering@ascend.com>
29030
29031         * m4/isc-posix.m4: New file.
29032
29033 1998-05-10  Jim Meyering  <meyering@ascend.com>
29034
29035         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
29036
29037 1998-05-09  Jim Meyering  <meyering@ascend.com>
29038
29039         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
29040         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
29041         with automake.
29042
29043         * m4/ssize_t.m4: New file.
29044         * m4/mktime.m4: Remove file -- the new automake has this now.
29045
29046 1998-04-26  Jim Meyering  <meyering@ascend.com>
29047
29048         * m4/assert.m4: New file.
29049         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
29050
29051 1998-04-05  Jim Meyering  <meyering@ascend.com>
29052
29053         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
29054         (jm_PREREQ): Use it here.
29055
29056 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
29057
29058         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
29059         in acconfig.h.
29060
29061 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
29062
29063         * m4/prereq.m4: New file.
29064         * m4/error.m4: New file.
29065         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
29066
29067 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
29068
29069         * m4/getline.m4: Don't set am_cv_func_working_getline before the
29070         cache-check for the same variable -- that defeated the purpose of
29071         the test; the test program was never run.  This was a problem only
29072         on systems with losing getline functions -- HP-UX 10.20 is one.
29073         Reported by Bjorn Helgaas.
29074
29075 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
29076
29077         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
29078
29079 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
29080
29081         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
29082
29083         * m4/const.m4: New file.  Use an initializer in this declaration
29084         typedef int charset[2]; const charset x;
29085         Reported by Bob Glickstein.
29086
29087 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
29088
29089         * m4/chown.m4: Fix reversed types on -1 args to chown.
29090         From Kaveh Ghazi.
29091
29092 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
29093
29094         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
29095         Add lseek and memchr.
29096
29097         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
29098         T.E.Dickey <dickey@clark.net> said that some older preprocessors
29099         have a 20-character limit on names.
29100
29101 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
29102
29103         * m4/inttypes_h.m4: New file.
29104         * m4/uintmax_t.m4: New file.
29105         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
29106
29107 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
29108   Free Software Foundation, Inc.
29109 Copying and distribution of this file, with or without modification,
29110 are permitted provided the copyright notice and this notice are preserved.