* lib/stat-time.h (USE_BIRTHTIME): Remove.
[gnulib.git] / ChangeLog
1 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
2
3         * lib/stat-time.h (USE_BIRTHTIME): Remove.
4         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
5         (get_stat_birthtime_ns): Do not try to use "spare" fields.
6         (get_stat_birthtime_ns): Simplify compile-time tests.
7         (get_stat_birthtime): Change the API to look like
8         get_stat_mtime etc., except return a negative tv_nsec on error.
9         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
10         Don't check for "spare" fields.
11         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
12         or for struct stat.st_birthtime, as these tests aren't used.
13         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
14
15 2007-03-27  Bruno Haible  <bruno@clisp.org>
16
17         * lib/stat-time.h: Include <sys/stat.h>.
18
19 2007-03-27  James Youngman  <jay@gnu.org>
20
21         * lib/stat-time.h (get_stat_birthtime): New function for
22           retrieving st_birthtime as provided by UFS2 (hence *BSD).
23         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
24           and its variants.
25         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
26         * modules/stat-time-test: New file.
27         * tests/test-stat-time.c: New test, devised by Bruno Haible.
28
29 2007-03-26  Bruno Haible  <bruno@clisp.org>
30
31         Better support of signalling NaNs.
32         * lib/atanl.c: Include isnanl.h.
33         (atanl): Perform test for NaN at the beginning of the function and
34         through a call to isnanl.
35         * lib/cosl.c: Include isnanl.h.
36         (cosl): Perform test for NaN at the beginning of the function and
37         through a call to isnanl.
38         * lib/ldexpl.c: Include isnanl.h.
39         (ldexpl): Perform test for NaN through a call to isnanl.
40         * lib/logl.c: Include isnanl.h.
41         (logl): Perform test for NaN at the beginning of the function and
42         through a call to isnanl.
43         * lib/sinl.c: Include isnanl.h.
44         (sinl): Perform test for NaN at the beginning of the function and
45         through a call to isnanl.
46         * lib/sqrtl.c: Include isnanl.h.
47         (sqrtl): Perform test for NaN at the beginning of the function and
48         through a call to isnanl.
49         * lib/tanl.c: Include isnanl.h.
50         (tanl): Perform test for NaN at the beginning of the function and
51         through a call to isnanl.
52         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
53         * modules/mathl (Depends-on): Add isnanl.
54
55 2007-03-26  Eric Blake  <ebb9@byu.net>
56
57         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
58         regression in logic sense of previous patch.
59
60 2007-03-26  Bruno Haible  <bruno@clisp.org>
61
62         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
63         unportable shell command "if ! ...".
64         Reported by Ralf Wildenhues.
65
66 2007-03-25  Bruno Haible  <bruno@clisp.org>
67
68         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
69         <sysexits.h> file, and only add EX_CONFIG.
70         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
71         absolute file name and whether it is sufficient. Substitute also
72         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
73         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
74         ABSOLUTE_SYSEXITS_H into sysexits.h.
75
76 2007-03-25  Bruno Haible  <bruno@clisp.org>
77
78         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
79         hints is NULL.
80
81 2007-03-25  Bruno Haible  <bruno@clisp.org>
82
83         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
84         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
85
86 2007-03-25  Bruno Haible  <bruno@clisp.org>
87
88         * lib/vasnprintf.c: Include langinfo.h.
89         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
90         multithread-safe.
91         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
92         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
93         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
94         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
95         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
96         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
97         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
98         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
99         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
100         Reported by Simon Josefsson.
101
102 2007-03-25  Bruno Haible  <bruno@clisp.org>
103
104         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
105         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
106         * modules/vasnprintf (Depends-on): Add stdint.
107
108 2007-03-25  Bruno Haible  <bruno@clisp.org>
109
110         * modules/fpieee: New file.
111         * m4/fpieee.m4: New file.
112         * modules/isnan-nolibm (Depends-on): Add fpieee.
113         * modules/isnanl-nolibm (Depends-on): Add fpieee.
114         * modules/isnanl (Depends-on): Add fpieee.
115
116 2007-03-25  Bruno Haible  <bruno@clisp.org>
117
118         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
119
120 2007-03-25  Bruno Haible  <bruno@clisp.org>
121
122         Avoid test failures on IRIX 6.5.
123         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
124         (main): Use it.
125         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
126         macros.
127         (main): Use them.
128
129 2007-03-25  Bruno Haible  <bruno@clisp.org>
130
131         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
132         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
133         exists but doesn't work.
134         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
135         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
136         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
137         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
138
139 2007-03-25  Bruno Haible  <bruno@clisp.org>
140
141         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
142         returns inf. Needed on IRIX 6.5.
143
144 2007-03-25  Bruno Haible  <bruno@clisp.org>
145
146         * tests/test-frexpl.c: Include isnanl-nolibm.h.
147         (main): Use isnanl instead of x != x idiom.
148         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
149
150         * tests/test-frexp.c: Include isnan.h.
151         (main): Use isnan instead of x != x idiom.
152         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
153
154 2007-03-25  Bruno Haible  <bruno@clisp.org>
155
156         * tests/test-frexp.c (NaN): New function/macro.
157         (main): Use it instead of 0.0 / 0.0.
158         * tests/test-isnan.c (NaN): New function/macro.
159         (main): Use it instead of 0.0 / 0.0.
160         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
161         (test_function): Use it instead of 0.0 / 0.0.
162         * tests/test-vasprintf-posix.c (NaN): New function/macro.
163         (test_function): Use it instead of 0.0 / 0.0.
164         * tests/test-snprintf-posix.h (NaN): New function/macro.
165         (test_function): Use it instead of 0.0 / 0.0.
166         * tests/test-sprintf-posix.h (NaN): New function/macro.
167         (test_function): Use it instead of 0.0 / 0.0.
168         * tests/test-fprintf-posix.h (NaN): New function/macro.
169         (test_function): Use it instead of 0.0 / 0.0.
170         * tests/test-printf-posix.h (NaN): New function/macro.
171         (test_function): Use it instead of 0.0 / 0.0.
172
173         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
174
175 2007-03-25  Bruno Haible  <bruno@clisp.org>
176
177         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
178
179 2007-03-25  Bruno Haible  <bruno@clisp.org>
180
181         * lib/regexec.c (merge_state_with_log): Make static.
182
183 2007-03-25  Bruno Haible  <bruno@clisp.org>
184
185         * lib/trigl.c (kernel_rem_pio2): Make static.
186
187 2007-03-25  Bruno Haible  <bruno@clisp.org>
188
189         * lib/sincosl.c (sincosl_table): Make static.
190
191 2007-03-25  Bruno Haible  <bruno@clisp.org>
192
193         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
194         if the compiler does not support C99.
195
196 2007-03-25  Bruno Haible  <bruno@clisp.org>
197
198         * modules/time (Makefile.am): Ensure all rule action lines start with a
199         tab.
200
201 2007-03-24  Bruno Haible  <bruno@clisp.org>
202
203         * modules/tsearch-tests: New file.
204         * tests/test-tsearch.sh: New file.
205         * tests/test-tsearch.c: New file, mostly copied from glibc.
206
207         * modules/search-tests: New file.
208         * tests/test-search.c: New file.
209
210         * modules/search: New file.
211         * lib/search_.h: New file, incorporating lib/tsearch.h.
212         * m4/search_h.m4: New file.
213         * lib/tsearch.h: Remove file.
214         * lib/tsearch.c: Include search.h instead of tsearch.h.
215         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
216         HAVE_TSEARCH.
217         * modules/tsearch (Files): Remove lib/tsearch.h.
218         (Depends-on): Add search.
219         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
220         (Include): Change tsearch.h into search.h.
221
222 2007-03-24  Bruno Haible  <bruno@clisp.org>
223
224         * modules/fpucw: New file.
225         * lib/fpucw.h: New file.
226         * lib/frexp.c: Include fpucw.h.
227         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
228         (FUNC): Use them.
229         * lib/printf-frexp.c: Include fpucw.h.
230         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
231         (FUNC): Use them.
232         * lib/vasnprintf.c: Include fpucw.h.
233         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
234         'long double' calculations.
235         * tests/test-frexpl.c: Include fpucw.h.
236         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
237         * tests/test-printf-frexpl.c: Include fpucw.h.
238         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
239         * modules/frexpl (Depends-on): Add fpucw.
240         * modules/printf-frexpl (Depends-on): Likewise.
241         * modules/fprintf-posix (Depends-on): Likewise.
242         * modules/snprintf-posix (Depends-on): Likewise.
243         * modules/sprintf-posix (Depends-on): Likewise.
244         * modules/vasnprintf-posix (Depends-on): Likewise.
245         * modules/vasprintf-posix (Depends-on): Likewise.
246         * modules/vfprintf-posix (Depends-on): Likewise.
247         * modules/vsnprintf-posix (Depends-on): Likewise.
248         * modules/vsprintf-posix (Depends-on): Likewise.
249         * modules/frexpl-tests (Depends-on): Likewise.
250         * modules/printf-frexpl-tests (Depends-on): Likewise.
251
252 2007-03-24  Bruno Haible  <bruno@clisp.org>
253
254         * lib/float+.h: New file.
255         * lib/isnan.c: Include float+.h.
256         (SIZE): New macro.
257         (FUNC): Compare only SIZE bytes of the value.
258         * lib/vasnprintf.c: Include float+.h.
259         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
260         SIZEOF_LDBL or SIZEOF_DBL bytes.
261         * modules/isnan-nolibm (Files): Add lib/float+.h.
262         * modules/isnanl-nolibm (Files): Add lib/float+.h.
263         * modules/isnanl (Files): Add lib/float+.h.
264         * modules/vasnprintf (Files): Add lib/float+.h.
265
266 2007-03-24  Bruno Haible  <bruno@clisp.org>
267
268         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
269         include isnanl-nolibm.h.
270
271 2007-03-24  Bruno Haible  <bruno@clisp.org>
272
273         * tests/test-read-file.c (main): Don't produce spurious output for
274         expected situations. Make the test fail if it encountered unexpected
275         results.
276
277 2007-03-24  Bruno Haible  <bruno@clisp.org>
278
279         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
280         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
281
282 2007-03-24  Bruno Haible  <bruno@clisp.org>
283
284         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
285
286 2007-03-24  Bruno Haible  <bruno@clisp.org>
287
288         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
289         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
290
291         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
292         * modules/utf8-ucs4: Turn into a symbolic link to module
293         unistr/u8-mbtouc.
294
295         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
296         utf8-ucs4-unsafe.
297         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
298         unistr/u8-mbtouc-unsafe.
299
300         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
301         * modules/utf16-ucs4: Turn into a symbolic link to module
302         unistr/u16-mbtouc.
303
304         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
305         utf16-ucs4-unsafe.
306         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
307         unistr/u16-mbtouc-unsafe.
308
309         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
310         * modules/ucs4-utf8: Turn into a symbolic link to module
311         unistr/u8-ubtomb.
312
313         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
314         * modules/ucs4-utf16: Turn into a symbolic link to module
315         unistr/u16-ubtomb.
316
317 2007-03-24  Bruno Haible  <bruno@clisp.org>
318
319         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
320         Enable the function only if HAVE_INLINE.
321         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
322         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
323         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
324         Enable the function only if HAVE_INLINE.
325         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
326         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
327         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
328         Enable the function only if HAVE_INLINE.
329         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
330         Enable the function only if HAVE_INLINE.
331         * modules/utf8-ucs4: Update.
332         * modules/utf8-ucs4-unsafe: Update.
333         * modules/utf16-ucs4: Update.
334         * modules/utf16-ucs4-unsafe: Update.
335         * modules/ucs4-utf8: Update.
336         * modules/ucs4-utf16: Update.
337
338 2007-03-24  Bruno Haible  <bruno@clisp.org>
339
340         * lib/utf8-ucs4.h: Remove file.
341         * lib/utf8-ucs4-unsafe.h: Remove file.
342         * lib/utf16-ucs4.h: Remove file.
343         * lib/utf16-ucs4-unsafe.h: Remove file.
344         * lib/ucs4-utf8.h: Remove file.
345         * lib/ucs4-utf16.h: Remove file.
346         * lib/unistr.h: Include their previous contents.
347         * m4/utf-ucs4.m4: Remove file.
348         * m4/ucs4-utf.m4: Remove file.
349         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
350         (Depends-on): Add unistr/base.
351         (configure.ac): Remove gl_UTF_UCS4.
352         (Makefile.am): Update.
353         (Include): Change to unistr.h.
354         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
355         (Depends-on): Add unistr/base.
356         (configure.ac): Remove gl_UTF_UCS4.
357         (Makefile.am): Update.
358         (Include): Change to unistr.h.
359         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
360         (Depends-on): Add unistr/base.
361         (configure.ac): Remove gl_UTF_UCS4.
362         (Makefile.am): Update.
363         (Include): Change to unistr.h.
364         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
365         (Depends-on): Add unistr/base.
366         (configure.ac): Remove gl_UTF_UCS4.
367         (Makefile.am): Update.
368         (Include): Change to unistr.h.
369         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
370         (Depends-on): Add unistr/base.
371         (configure.ac): Remove gl_UCS4_UTF.
372         (Makefile.am): Update.
373         (Include): Change to unistr.h.
374         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
375         (Depends-on): Add unistr/base.
376         (configure.ac): Remove gl_UCS4_UTF.
377         (Makefile.am): Update.
378         (Include): Change to unistr.h.
379         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
380         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
381         utf8-ucs4-unsafe.h.
382         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
383         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
384         utf16-ucs4-unsafe.h.
385         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
386         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
387         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
388         * lib/unistr/u8-strchr.c: Likewise.
389         * lib/unistr/u8-strrchr.c: Likewise.
390         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
391         * lib/unistr/u16-strchr.c: Likewise.
392         * lib/unistr/u16-strrchr.c: Likewise.
393         * lib/striconveh.c: Update.
394         * lib/linebreak.c: Update.
395
396 2007-03-24  Bruno Haible  <bruno@clisp.org>
397
398         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
399         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
400
401 2007-03-22  Bruno Haible  <bruno@clisp.org>
402
403         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
404
405 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
406
407         * MODULES.html.sh (File system functions): New module write-any-file.
408         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
409         * m4/write-any-file.m4: New files.
410
411 2007-03-23  Eric Blake  <ebb9@byu.net>
412
413         * gnulib-tool: Rearrange space-tab sequences, since some editors
414         like to eat them.
415
416 2007-03-23  Eric Blake  <ebb9@byu.net>
417
418         * lib/version-etc.c (version_etc_va): Update license wording to
419         be more concise.  Recommended by Richard Stallman.
420
421 2007-03-22  Bruno Haible  <bruno@clisp.org>
422
423         * lib/poll.c (MSG_PEEK): New fallback definition.
424
425 2007-03-22  Bruno Haible  <bruno@clisp.org>
426
427         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
428         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
429         (main): Update.
430         Fixes a compilation error on BeOS.
431
432 2007-03-22  Bruno Haible  <bruno@clisp.org>
433
434         * modules/frexpl-tests: New file.
435         * tests/test-frexpl.c: New file.
436
437         * modules/frexpl: New file.
438         * m4/frexpl.m4: New file.
439         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
440         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
441         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
442         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
443         (Depends-on): Add frexpl. Remove isnanl-nolibm.
444         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
445
446 2007-03-22  Bruno Haible  <bruno@clisp.org>
447
448         * lib/frexpl.c: Share code with lib/frexp.c.
449         * modules/mathl (Files): Add lib/frexp.c.
450         (Depends-on): Add isnanl-nolibm.
451
452 2007-03-22  Bruno Haible  <bruno@clisp.org>
453
454         * modules/printf-frexp (Files): Add m4/frexp.m4.
455         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
456         only if the found frexp function actually works.
457
458 2007-03-22  Bruno Haible  <bruno@clisp.org>
459
460         * lib/frexp.c: Remove older implementation that uses divisions.
461
462 2007-03-21  Bruno Haible  <bruno@clisp.org>
463
464         * modules/frexp-tests: New file.
465         * tests/test-frexp.c: New file.
466
467         * modules/frexp: New file.
468         * lib/frexp.c: New file.
469         * m4/frexp.m4: New file.
470         * lib/math_.h (frexp): New declaration.
471         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
472         REPLACE_FREXP.
473         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
474
475 2007-03-21  Bruno Haible  <bruno@clisp.org>
476
477         * modules/isnanl-tests: New file.
478         * tests/test-isnanl.c: New file.
479
480         * modules/isnanl: New file.
481         * lib/isnanl.h: New file.
482         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
483         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
484         gl_FUNC_ISNANL_WORKS.
485         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
486         New macros.
487
488 2007-03-21  Bruno Haible  <bruno@clisp.org>
489
490         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
491         lib/isnanl.h.
492         (Include): Update.
493         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
494         * lib/vasnprintf.c: Update.
495         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
496         tests/test-isnanl.h, remove tests/test-isnanl.c.
497         (Makefile.am): Update.
498         * tests/test-isnanl-nolibm.c: New file.
499         * tests/test-isnanl.h: New file.
500         * tests/test-isnanl.c: Remove file.
501
502 2007-03-21  Jim Meyering  <jim@meyering.net>
503
504         When trying to open ".", treat ESTALE like EACCES.
505         * lib/savewd.c (savewd_save): Resort to forking not just upon
506         failure with EACCES, but also when errno is ESTALE.
507
508 2007-03-20  Bruno Haible  <bruno@clisp.org>
509
510         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
511         Needed on AIX 5.1. Reported by Matthew Woehlke.
512
513 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
514
515         Suggestions by Bruno Haible:
516         * lib/acl-internal.h: Include "gettext.h" rather than rolling
517         our own.
518         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
519         * modules/acl (Depends-on): Add gettext.
520
521 2007-03-19  Bruno Haible  <bruno@clisp.org>
522
523         * modules/iconvme: Remove file.
524         * lib/iconvme.h: Remove file.
525         * lib/iconvme.c: Remove file.
526         * m4/iconvme.m4: Remove file.
527
528 2007-03-19  Bruno Haible  <bruno@clisp.org>
529
530         * doc/relocatable-maint.texi: Break long shell script line.
531         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
532
533 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
534
535         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
536         handle file_has_acl.
537         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
538         * lib/acl.c: Move header inclusions and related macro defns into
539         lib/acl-internal.h.
540         (S_ISLNK): Remove defn, since that's now done for us.
541         (file_has_acl): Move to lib/file-has-acl.c.
542         Call acl_trivial if available.  This is the crucial part of the fix.
543         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
544         shared within the library.  Rewrite a bit, partly to make it compatible
545         with the GNU coding style.
546         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
547         Remove unnecessary double-quotes.
548         Don't test for acl_to_text; the build will catch that.
549         Replace acl_entries if it doesn't exist and it is needed.
550         Check for -lsec and acl_trivial (as used on Solaris 10).
551         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
552         lib/file-has-acl.c.
553         (Depends-on): Add sys_stat, for S_ISLNK.
554
555 2007-03-19  Ben Pfaff  <blp@gnu.org>
556
557         * doc/gnulib.texi: Fix typos.
558         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
559
560 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
561
562         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
563         If size is zero here, buf must be zero.
564
565 2007-03-19  Simon Josefsson  <simon@josefsson.org>
566
567         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
568         <bruno@clisp.org>.
569
570 2007-03-18  Bruno Haible  <bruno@clisp.org>
571
572         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
573         Suggested by Eric Blake.
574
575 2007-03-18  Ben Pfaff  <blp@gnu.org>
576
577         * doc/relocatable.texi: Recommend using as prefix a directory
578         that does not exist and will never be created.  Based on
579         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
580         and others.
581
582 2007-03-17  Bruno Haible  <bruno@clisp.org>
583
584         * lib/fchownat.c: Include lchown.h.
585
586 2007-03-17  Bruno Haible  <bruno@clisp.org>
587
588         Fix endless loop when the given allocated size was > INT_MAX.
589         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
590         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
591         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
592         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
593         * lib/sprintf.c (sprintf): Likewise.
594
595 2007-03-17  Bruno Haible  <bruno@clisp.org>
596
597         * tests/test-argp-2.sh (func_compare): Output a context diff.
598
599 2007-03-17  Bruno Haible  <bruno@clisp.org>
600
601         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
602         locale's decimal-point character.
603
604 2007-03-17  Bruno Haible  <bruno@clisp.org>
605
606         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
607         before comparing it. Needed because on some platforms (e.g. x86) a
608         'long double' occupies less bytes than sizeof (long double).
609
610 2007-03-17  Bruno Haible  <bruno@clisp.org>
611
612         * tests/test-crc.c (main): Make printf statements 64-bit clean.
613         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
614         * tests/test-getaddrinfo.c (simple): Likewise.
615         * tests/test-read-file.c (main): Likewise.
616
617 2007-03-17  Bruno Haible  <bruno@clisp.org>
618
619         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
620
621 2007-03-17  Bruno Haible  <bruno@clisp.org>
622
623         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
624         unused variable.
625
626 2007-03-17  Bruno Haible  <bruno@clisp.org>
627
628         * tests/test-c-strcasecmp.c: Include c-strcase.h.
629         * tests/test-c-strncasecmp.c: Likewise.
630
631 2007-03-17  Bruno Haible  <bruno@clisp.org>
632
633         * modules/stdlib (Depends-on): Add unistd.
634         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
635         Needed for MacOS X 10.3.
636
637 2007-03-17  Bruno Haible  <bruno@clisp.org>
638
639         * lib/unistr/u-strdup.h: Include <stdlib.h>.
640
641 2007-03-17  Bruno Haible  <bruno@clisp.org>
642
643         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
644
645 2007-03-17  Bruno Haible  <bruno@clisp.org>
646
647         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
648         to reflect files copied from gnulib (with or without modifications).
649         Suggested by Jim Meyering.
650
651 2007-03-17  Eric Blake  <ebb9@byu.net>
652
653         * NEWS: Document stdlib change from 2007-02-18.
654
655 2007-03-17  Jim Meyering  <jim@meyering.net>
656
657         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
658         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
659         someone uses a name containing shell meta-characters.
660         Reported by Alfred M. Szmidt.
661
662         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
663
664 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
665
666         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
667         and copy gettext configuration files only if configure.ac contains
668         a use of AM_GNU_GETTEXT_VERSION.
669
670 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
671
672         * build-aux/bootstrap (gnulib_name): New variable.
673         (gnulib_tool_options): Use it.
674
675 2007-03-13  Simon Josefsson  <simon@josefsson.org>
676
677         * tests/test-des.c: Use new namespace.
678
679 2007-03-15  Bruno Haible  <bruno@clisp.org>
680
681         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
682         Reported by James Youngman <jay@gnu.org>.
683
684 2007-03-15  Bruno Haible  <bruno@clisp.org>
685
686         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
687         declared prototype. Needed with cc on OSF/1 5.1.
688
689 2007-03-15  Bruno Haible  <bruno@clisp.org>
690
691         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
692         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
693         (struct gl_list_implementation): Add dispose_fn argument to the
694         'create_empty', 'create' methods.
695         (struct gl_list_impl_base): Add field 'dispose_fn'.
696         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
697         argument.
698         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
699         dispose_fn argument.
700         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
701         dispose_fn on the dropped values.
702         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
703         dispose_fn argument.
704         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
705         dropped values.
706         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
707         (gl_tree_remove_node): Call dispose_fn on the dropped value.
708         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
709         (gl_tree_remove_node): Call dispose_fn on the dropped value.
710         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
711         argument.
712         (gl_tree_list_free): Call dispose_fn on the dropped values.
713         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
714         the dropped values.
715         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
716         Add dispose_fn argument.
717         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
718         Call dispose_fn on the dropped values.
719         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
720         Add dispose_fn argument.
721         (gl_sublist_create): Initialize the 'dispose_fn' field.
722         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
723         * tests/test-array_list.c (main): Update.
724         * tests/test-carray_list.c (main): Update.
725         * tests/test-avltree_list.c (main): Update.
726         * tests/test-rbtree_list.c (main): Update.
727         * tests/test-avltreehash_list.c (main): Update.
728         * tests/test-rbtreehash_list.c (main): Update.
729         * tests/test-linked_list.c (main): Update.
730         * tests/test-linkedhash_list.c (main): Update.
731         * tests/test-array_oset.c (main): Update.
732
733 2007-03-15  Bruno Haible  <bruno@clisp.org>
734
735         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
736         (gl_oset_create_empty): Add dispose_fn argument.
737         (struct gl_oset_implementation): Add dispose_fn argument to
738         'create_empty' method.
739         (struct gl_oset_impl_base): Add dispose_fn field.
740         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
741         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
742         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
743         values.
744         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
745         (gl_tree_oset_free): Call dispose_fn on the dropped values.
746         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
747         dropped value.
748         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
749         dropped value.
750         * tests/test-array_oset.c (main): Update.
751         * tests/test-avltree_oset.c (main): Update.
752         * tests/test-rbtree_oset.c (main): Update.
753         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
754
755 2007-03-13  Bruno Haible  <bruno@clisp.org>
756
757         * tests/test-stdbool.c (i): Update after last patch.
758
759 2007-03-12  Bruno Haible  <bruno@clisp.org>
760
761         * lib/quotearg.c: Include <wctype.h> early, before the definition of
762         the iswprint macro. Needed on Solaris 2.5.1.
763
764 2007-03-12  Bruno Haible  <bruno@clisp.org>
765
766         * tests/test-printf-frexp.c (main): Declare x as volatile.
767
768 2007-03-12  Simon Josefsson  <simon@josefsson.org>
769
770         * doc/gnulib.texi (Build robot for gnulib): New section.
771
772 2007-03-12  Jim Meyering  <jim@meyering.net>
773
774         * build-aux/bootstrap: New file.
775         * build-aux/bootstrap.conf: New file, from coreutils.
776
777 2007-03-11  Bruno Haible  <bruno@clisp.org>
778
779         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
780
781 2007-03-12  Simon Josefsson  <simon@josefsson.org>
782
783         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
784         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
785         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
786
787 2007-03-11  Bruno Haible  <bruno@clisp.org>
788
789         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
790         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
791
792 2007-03-11  Bruno Haible  <bruno@clisp.org>
793
794         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
795         formula. Needed for SunPRO C 5.0.
796
797 2007-03-11  Bruno Haible  <bruno@clisp.org>
798
799         * modules/long-options (Depends-on): Add getopt.
800
801 2007-03-11  Bruno Haible  <bruno@clisp.org>
802
803         * modules/modechange (Depends-on): Add stdbool.
804
805 2007-03-11  Bruno Haible  <bruno@clisp.org>
806
807         * modules/i-ring (Depends-on): Add stdbool.
808
809 2007-03-11  Bruno Haible  <bruno@clisp.org>
810
811         * modules/gc-des (Depends-on): Add stdbool.
812
813 2007-03-11  Bruno Haible  <bruno@clisp.org>
814
815         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
816
817 2007-03-11  Bruno Haible  <bruno@clisp.org>
818
819         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
820
821 2007-03-11  Bruno Haible  <bruno@clisp.org>
822
823         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
824
825 2007-03-11  Bruno Haible  <bruno@clisp.org>
826
827         * lib/vasnprintf.c (sprintf): Undefine.
828
829 2007-03-11  Bruno Haible  <bruno@clisp.org>
830
831         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
832         initializers in SunPRO C and Compaq C compilers.
833
834 2007-03-11  Bruno Haible  <bruno@clisp.org>
835
836         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
837         decrementing code ANSI C compliant.
838
839 2007-03-11  Bruno Haible  <bruno@clisp.org>
840
841         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
842         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
843
844 2007-03-11  Bruno Haible  <bruno@clisp.org>
845
846         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
847         <stdbool.h> substitute doesn't pass.
848
849 2007-03-11  Bruno Haible  <bruno@clisp.org>
850
851         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
852
853 2007-03-11  Bruno Haible  <bruno@clisp.org>
854
855         * gnulib-tool (func_create_megatestdir): Create also an autobuild
856         script, for submission to autobuild.josefsson.org.
857
858 2007-03-10  Bruno Haible  <bruno@clisp.org>
859
860         * modules/canonicalize-lgpl-tests: New file.
861         * tests/test-canonicalize-lgpl.sh: New file.
862         * tests/test-canonicalize-lgpl.c: New file.
863
864         * modules/c-strcase-tests: New file.
865         * tests/test-c-strcase.sh: New file.
866         * tests/test-c-strcasecmp.c: New file.
867         * tests/test-c-strncasecmp.c: New file.
868
869         * modules/atexit-tests: New file.
870         * tests/test-atexit.sh: New file.
871         * tests/test-atexit.c: New file.
872
873 2007-03-10  Bruno Haible  <bruno@clisp.org>
874
875         * tests/test-binary-io.sh: Use temporary filenames that are not so
876         likely to clash with those of other tests (in a parallel make).
877         * tests/test-binary-io.c: Likewise.
878
879 2007-03-10  Bruno Haible  <bruno@clisp.org>
880
881         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
882         fallback; use #error instead.
883         Suggested by Simon Josefsson.
884
885 2007-03-10  Bruno Haible  <bruno@clisp.org>
886
887         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
888         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
889         first and the last.
890
891 2007-03-10  Bruno Haible  <bruno@clisp.org>
892
893         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
894
895 2007-03-10  Bruno Haible  <bruno@clisp.org>
896
897         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
898         "make distcheck".
899         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
900         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
901         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
902
903 2007-03-10  Bruno Haible  <bruno@clisp.org>
904
905         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
906         variable.
907         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
908         variable.
909
910 2007-03-09  Eric Blake  <ebb9@byu.net>
911         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
912
913         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
914         types are not being provided by gnulib.
915         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
916         types are supported.
917
918 2007-03-10  Bruno Haible  <bruno@clisp.org>
919
920         * lib/stdio_.h (__attribute__): New macro.
921         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
922         vsprintf): Specify __attribute__ __format__ for GCC.
923         Suggested by Eric Blake.
924
925 2007-03-09  Bruno Haible  <bruno@clisp.org>
926
927         * modules/printf-posix-tests: New file.
928         * tests/test-printf-posix.sh: New file.
929         * tests/test-printf-posix.c: New file.
930
931         * modules/printf-posix: New file.
932         * lib/printf.c: New file.
933         * m4/printf-posix-rpl.m4: New file.
934         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
935         REPLACE_PRINTF.
936         * lib/stdio_.h (printf): New declaration.
937         (format, __format__, ____printf____, ____scanf____, ____strftime____,
938         ____strfmon____): New macros.
939         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
940         REPLACE_PRINTF.
941
942 2007-03-09  Bruno Haible  <bruno@clisp.org>
943
944         * tests/test-vasnprintf-posix2.sh: New file.
945         * tests/test-vasnprintf-posix2.c: New file.
946         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
947         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
948         (Makefile.am): Activate test-vasnprintf-posix2.sh.
949
950         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
951         a locale dependent decimal point, rather than always '.'.
952
953 2007-03-09  Eric Blake  <ebb9@byu.net>
954
955         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
956         spite of platforms like Tandem/NSK that define it to -1.
957
958 2007-03-08  Bruno Haible  <bruno@clisp.org>
959
960         * modules/vprintf-posix-tests: New file.
961         * tests/test-vprintf-posix.sh: New file.
962         * tests/test-vprintf-posix.c: New file.
963         * tests/test-printf-posix.h: New file.
964
965         * modules/vprintf-posix: New file.
966         * lib/vprintf.c: New file.
967         * m4/vprintf-posix.m4: New file.
968         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
969         REPLACE_VPRINTF.
970         * lib/stdio_.h (vprintf): New declaration.
971         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
972         REPLACE_VPRINTF.
973
974 2007-03-08  Bruno Haible  <bruno@clisp.org>
975
976         * modules/fprintf-posix-tests: New file.
977         * tests/test-fprintf-posix.sh: New file.
978         * tests/test-fprintf-posix.c: New file.
979
980         * modules/fprintf-posix: New file.
981         * lib/fprintf.c: New file.
982         * m4/fprintf-posix.m4: New file.
983         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
984         REPLACE_FPRINTF.
985         * lib/stdio_.h (fprintf): New declaration.
986         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
987         REPLACE_FPRINTF.
988
989 2007-03-08  Bruno Haible  <bruno@clisp.org>
990
991         * modules/vfprintf-posix-tests: New file.
992         * tests/test-vfprintf-posix.sh: New file.
993         * tests/test-vfprintf-posix.c: New file.
994         * tests/test-fprintf-posix.h: New file.
995         * tests/test-fprintf-posix.out: New file.
996
997         * modules/vfprintf-posix: New file.
998         * lib/vfprintf.c: New file.
999         * m4/vfprintf-posix.m4: New file.
1000         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
1001         REPLACE_VFPRINTF.
1002         * lib/stdio_.h (vfprintf): New declaration.
1003         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
1004         REPLACE_VFPRINTF.
1005
1006 2007-03-08  Bruno Haible  <bruno@clisp.org>
1007
1008         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
1009
1010 2007-03-08  Bruno Haible  <bruno@clisp.org>
1011
1012         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
1013         instead of 'expr' invocations.
1014         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1015         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1016         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1017         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1018         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1019         Suggested by Paul Eggert.
1020
1021 2007-03-08  Bruno Haible  <bruno@clisp.org>
1022
1023         * modules/fseterr-tests: New file.
1024         * tests/test-fseterr.c: New file.
1025
1026         * modules/fseterr: New file.
1027         * lib/fseterr.h: New file.
1028         * lib/fseterr.c: New file.
1029
1030 2007-03-08  Bruno Haible  <bruno@clisp.org>
1031
1032         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
1033         * lib/getopt_.h: Likewise.
1034         * lib/mbswidth.h: Likewise.
1035         * lib/setenv.h: Likewise.
1036         * lib/vasnprintf.h: Likewise.
1037         * lib/vasprintf.h: Likewise.
1038         * lib/verror.h: Likewise.
1039         * lib/xsetenv.h: Likewise.
1040         * lib/xvasprintf.h: Likewise.
1041
1042 2007-03-08  Jim Meyering  <jim@meyering.net>
1043
1044         * users.txt: Add parted.
1045
1046         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
1047
1048 2007-03-07  Bruno Haible  <bruno@clisp.org>
1049
1050         * m4/printf.m4: Make the shell script snippets copy&pastable.
1051
1052 2007-03-02  Bruno Haible  <bruno@clisp.org>
1053
1054         * lib/netinet_in_.h: New file.
1055         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
1056         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
1057         * modules/netinet_in (Files): Add lib/netinet_in_.h.
1058         (Depends-on): Add absolute-header.
1059         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
1060         into netinet/in.h.
1061
1062 2007-03-03  Bruno Haible  <bruno@clisp.org>
1063
1064         * lib/sys_select_.h: New file.
1065         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
1066         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
1067         * modules/sys_select (Files): Add lib/sys_select_.h.
1068         (Depends-on): Add absolute-header.
1069         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
1070         into sys/select.h.
1071
1072 2007-03-02  Bruno Haible  <bruno@clisp.org>
1073
1074         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
1075         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
1076         values.
1077         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
1078         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
1079         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
1080         * modules/sys_socket (Depends-on): Add absolute-header.
1081         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
1082         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
1083         (Include): Remove requirement of inclusion of <sys/types.h>.
1084
1085 2007-03-02  Bruno Haible  <bruno@clisp.org>
1086
1087         * lib/byteswap_.h (bswap_32): Fix formula.
1088
1089 2007-03-06  Bruno Haible  <bruno@clisp.org>
1090
1091         * modules/sprintf-posix-tests: New file.
1092         * tests/test-sprintf-posix.c: New file.
1093
1094         * modules/sprintf-posix: New file.
1095         * lib/sprintf.c: New file.
1096         * m4/sprintf-posix.m4: New file.
1097         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
1098         REPLACE_SPRINTF.
1099         * lib/stdio_.h (sprintf): New declaration.
1100         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
1101         REPLACE_SPRINTF.
1102
1103 2007-03-06  Bruno Haible  <bruno@clisp.org>
1104
1105         * modules/vsprintf-posix-tests: New file.
1106         * tests/test-vsprintf-posix.c: New file.
1107         * tests/test-sprintf-posix.h: New file.
1108
1109         * modules/vsprintf-posix: New file.
1110         * lib/vsprintf.c: New file.
1111         * m4/vsprintf-posix.m4: New file.
1112         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
1113         REPLACE_VSPRINTF.
1114         * lib/stdio_.h (vsprintf): New declaration.
1115         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
1116         REPLACE_VSPRINTF.
1117
1118 2007-03-06  Bruno Haible  <bruno@clisp.org>
1119
1120         * modules/vsnprintf (Depend-on): Remove minmax.
1121
1122 2007-03-06  Bruno Haible  <bruno@clisp.org>
1123
1124         * modules/snprintf-posix-tests: New file.
1125         * tests/test-snprintf-posix.c: New file.
1126
1127         * modules/snprintf-posix: New file.
1128         * m4/snprintf-posix.m4: New file.
1129         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
1130         gl_FUNC_SNPRINTF.
1131         (gl_FUNC_SNPRINTF): Invoke it.
1132         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
1133         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
1134         is set.
1135         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
1136
1137 2007-03-06  Bruno Haible  <bruno@clisp.org>
1138
1139         * modules/vsnprintf-posix-tests: New file.
1140         * tests/test-vsnprintf-posix.c: New file.
1141         * tests/test-snprintf-posix.h: New file.
1142
1143         * modules/vsnprintf-posix: New file.
1144         * m4/vsnprintf-posix.m4: New file.
1145         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
1146         gl_FUNC_VSNPRINTF.
1147         (gl_FUNC_VSNPRINTF): Invoke it.
1148         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
1149         * lib/stdio_.h (vsnprintf): Define as a replacement if
1150         REPLACE_VSNPRINTF is set.
1151         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
1152
1153 2007-03-06  Bruno Haible  <bruno@clisp.org>
1154
1155         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
1156         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
1157
1158 2007-03-06  Bruno Haible  <bruno@clisp.org>
1159
1160         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
1161         (asinl): Declare also if HAVE_DECL_ASINL is set.
1162         (atanl): Declare also if HAVE_DECL_ATANL is set.
1163         (ceill): Declare also if HAVE_DECL_CEILL is set.
1164         (cosl): Declare also if HAVE_DECL_COSL is set.
1165         (expl): Declare also if HAVE_DECL_EXPL is set.
1166         (floorl): Declare also if HAVE_DECL_FLOORL is set.
1167         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
1168         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
1169         (logl): Declare also if HAVE_DECL_LOGL is set.
1170         (sinl): Declare also if HAVE_DECL_SINL is set.
1171         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
1172         (tanl): Declare also if HAVE_DECL_TANL is set.
1173         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
1174         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
1175         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
1176         declaration of frexpl, ldexpl.
1177         * modules/printf-frexpl (Depends-on): Add math.
1178         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
1179
1180 2007-03-05  Bruno Haible  <bruno@clisp.org>
1181
1182         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
1183         frexpl and ldexpl are declared.
1184         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
1185
1186 2007-03-05  Bruno Haible  <bruno@clisp.org>
1187
1188         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
1189         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
1190
1191 2007-03-05  Bruno Haible  <bruno@clisp.org>
1192
1193         * lib/stdio_.h: Include <stddef.h>.
1194
1195 2007-03-05  Bruno Haible  <bruno@clisp.org>
1196
1197         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
1198
1199 2007-03-05  Bruno Haible  <bruno@clisp.org>
1200
1201         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
1202         NetBSD 4, from Ralf Wildenhues.
1203
1204 2007-03-04  Bruno Haible  <bruno@clisp.org>
1205
1206         * lib/vasprintf.h: Update #if logic for the case when the functions
1207         exist but are overridden.
1208
1209 2007-03-04  Bruno Haible  <bruno@clisp.org>
1210
1211         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
1212         implementations: glibc-2.4 and MacOS X 10.3.
1213         * tests/test-vasnprintf-posix.c (test_function): Test also the case
1214         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
1215         * tests/test-vasprintf-posix.c (test_function): Likewise.
1216
1217 2007-03-04  Bruno Haible  <bruno@clisp.org>
1218
1219         * modules/vasprintf-posix-tests: New file.
1220         * tests/test-vasprintf-posix.c: New file.
1221
1222         * modules/vasprintf-posix: New file.
1223         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
1224         defined.
1225         * m4/vasprintf-posix.m4: New file.
1226         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
1227         gl_FUNC_VASPRINTF.
1228         (gl_FUNC_VASPRINTF): Invoke it.
1229         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
1230         here.
1231         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
1232
1233 2007-03-04  Bruno Haible  <bruno@clisp.org>
1234
1235         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
1236         REPLACE_GETTIMEOFDAY.
1237         * modules/sys_time (Makefile.am): Likewise.
1238         * m4/sys_time_h.m4: Likewise.
1239         * m4/gettimeofday.m4: Likewise.
1240
1241 2007-03-04  Bruno Haible  <bruno@clisp.org>
1242
1243         * modules/vasnprintf-posix-tests: New file.
1244         * tests/test-vasnprintf-posix.c: New file.
1245
1246         * modules/vasnprintf-posix: New file.
1247         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
1248         printf-frexpl.h.
1249         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
1250         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
1251         REPLACE_VASNPRINTF is defined.
1252         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
1253         gl_FUNC_VASNPRINTF.
1254         (gl_FUNC_VASNPRINTF): Invoke it.
1255         * m4/vasnprintf-posix.m4: New file.
1256         * m4/printf.m4: New file.
1257
1258 2007-03-04  Bruno Haible  <bruno@clisp.org>
1259
1260         Compile progreloc.c only if --enable-relocatable is specified.
1261         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
1262         if --enable-relocatable was specified.
1263         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
1264         lib_SOURCES.
1265
1266 2007-03-04  Jim Meyering  <jim@meyering.net>
1267
1268         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
1269         Use it consistently, rather than enumerating errno constants.
1270
1271 2007-03-04  Bruno Haible  <bruno@clisp.org>
1272
1273         * modules/xvasprintf-tests: New file.
1274         * tests/test-xvasprintf.c: New file.
1275
1276         * modules/vasprintf-tests: New file.
1277         * tests/test-vasprintf.c: New file.
1278
1279         * modules/vasnprintf-tests: New file.
1280         * tests/test-vasnprintf.c: New file.
1281
1282         * modules/vsnprintf-tests: New file.
1283         * tests/test-vsnprintf.c: New file.
1284
1285         * modules/snprintf-tests: New file.
1286         * tests/test-snprintf.c: New file.
1287
1288 2007-03-04  Bruno Haible  <bruno@clisp.org>
1289
1290         Compile relocatable.c only if --enable-relocatable is specified.
1291         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
1292         gl_RELOCATABLE_LIBRARY.
1293         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
1294         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
1295         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
1296         gl_RELOCATABLE_LIBRARY.
1297         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
1298         (Makefile.am): Remove lib_SOURCES.
1299         * modules/relocatable-lib-lgpl (configure.ac): Invoke
1300         gl_RELOCATABLE_LIBRARY.
1301         (Makefile.am): Remove lib_SOURCES.
1302         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
1303         always.
1304         * modules/relocatable-prog-wrapper (configure.ac): Invoke
1305         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
1306
1307 2007-03-04  Bruno Haible  <bruno@clisp.org>
1308
1309         * modules/argmatch-tests: New file.
1310         * tests/test-argmatch.c: New file.
1311
1312         * tests/test-allocsa.c (main): Halve the number of loop runs.
1313
1314         * modules/alloca-opt-tests: New file.
1315         * tests/test-alloca-opt.c: New file.
1316
1317 2007-03-04  Jim Meyering  <jim@meyering.net>
1318
1319         Work around difference between Linux ACLs and Solaris 10 ZFS.
1320         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
1321         for EINVAL.
1322
1323 2007-03-03  Bruno Haible  <bruno@clisp.org>
1324
1325         * modules/relocatable-prog (Depends-on): Add back progreloc's
1326         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
1327
1328 2007-03-03  Bruno Haible  <bruno@clisp.org>
1329
1330         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
1331         * modules/relocatable-lib: New file.
1332
1333 2007-03-03  Bruno Haible  <bruno@clisp.org>
1334
1335         * modules/relocatable-prog: Renamed from modules/relocatable.
1336         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
1337
1338 2007-03-03  Bruno Haible  <bruno@clisp.org>
1339
1340         * modules/relocatable-script (Files): Add doc/relocatable.texi,
1341         m4/relocatable-lib.m4.
1342         (Depends-on): Remove 'relocatable'.
1343         (configure.ac): Add gl_RELOCATABLE_NOP.
1344
1345 2007-03-03  Bruno Haible  <bruno@clisp.org>
1346
1347         * modules/relocatable-prog-wrapper: New file.
1348         * modules/relocatable (Depends-on): Add it. Remove all other
1349         dependencies except progname.
1350         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
1351
1352         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
1353         (gl_FUNC_STRERROR): Nop.
1354         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
1355
1356         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
1357         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
1358
1359         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
1360         (gl_FUNC_READLINK): Update.
1361
1362         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
1363
1364 2007-03-03  Bruno Haible  <bruno@clisp.org>
1365
1366         * lib/xreadlink.c: Include <unistd.h> unconditionally.
1367         * modules/xreadlink (Depends-on): Add unistd.
1368         * modules/xreadlink-with-size (Depends-on): Likewise.
1369
1370 2007-03-03  Bruno Haible  <bruno@clisp.org>
1371
1372         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
1373         extracted from gt_FUNC_SETENV.
1374         (gt_FUNC_SETENV): Remove macro.
1375         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
1376         remove gt_FUNC_SETENV.
1377
1378 2007-03-03  Bruno Haible  <bruno@clisp.org>
1379
1380         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
1381         ENABLE_RELOCATABLE here.
1382         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
1383
1384 2007-03-03  Bruno Haible  <bruno@clisp.org>
1385
1386         * modules/rbtreehash-list-tests (Depends-on): Add progname.
1387         * tests/test-rbtreehash_list.c: Include progname.h.
1388         (main): Call set_program_name.
1389
1390         * modules/rbtree-oset-tests (Depends-on): Add progname.
1391         * tests/test-rbtree_oset.c: Include progname.h.
1392         (main): Call set_program_name.
1393
1394         * modules/rbtree-list-tests (Depends-on): Add progname.
1395         * tests/test-rbtree_list.c: Include progname.h.
1396         (main): Call set_program_name.
1397
1398         * modules/linked-list-tests (Depends-on): Add progname.
1399         * tests/test-linked_list.c: Include progname.h.
1400         (main): Call set_program_name.
1401
1402 2007-03-03  Bruno Haible  <bruno@clisp.org>
1403
1404         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
1405         All uses of __restrict changed to _Restrict_.
1406         * lib/glob_.h (__restrict): Remove macro.
1407
1408 2007-03-02  Bruno Haible  <bruno@clisp.org>
1409
1410         * modules/gettext (configure.ac): Require gettext infrastructure
1411         from version 0.16.1.
1412
1413 2007-03-02  Bruno Haible  <bruno@clisp.org>
1414
1415         * modules/linkedhash-list-tests (Depends-on): Add progname.
1416         * tests/test-linkedhash_list.c: Include progname.h.
1417         (main): Call set_program_name.
1418
1419         * modules/carray-list-tests (Depends-on): Add progname.
1420         * tests/test-carray_list.c: Include progname.h.
1421         (main): Call set_program_name.
1422
1423         * modules/avltreehash-list-tests (Depends-on): Add progname.
1424         * tests/test-avltreehash_list.c: Include progname.h.
1425         (main): Call set_program_name.
1426
1427         * modules/avltree-oset-tests (Depends-on): Add progname.
1428         * tests/test-avltree_oset.c: Include progname.h.
1429         (main): Call set_program_name.
1430
1431         * modules/avltree-list-tests (Depends-on): Add progname.
1432         * tests/test-avltree_list.c: Include progname.h.
1433         (main): Call set_program_name.
1434
1435         * modules/array-oset-tests (Depends-on): Add progname.
1436         * tests/test-array_oset.c: Include progname.h.
1437         (main): Call set_program_name.
1438
1439         * modules/array-list-tests (Depends-on): Add progname.
1440         * tests/test-array_list.c: Include progname.h.
1441         (main): Call set_program_name.
1442
1443         * modules/argp-tests (Depends-on): Add progname.
1444         * tests/test-argp.c: Include argp.h first. Include progname.h.
1445         (main): Call set_program_name.
1446
1447 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
1448
1449         * doc/gnulib-tool.texi (Initial import): Reword description of
1450         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
1451         limited effect even if defined after the first system include.
1452
1453 2007-03-01  Bruno Haible  <bruno@clisp.org>
1454
1455         * build-aux/config.libpath: Update to libtool-1.5.22.
1456         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
1457
1458 2007-03-01  Bruno Haible  <bruno@clisp.org>
1459
1460         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
1461         foo_CFLAGS.
1462         Reported by Ralf Wildenhues.
1463
1464 2007-03-01  Bruno Haible  <bruno@clisp.org>
1465
1466         * build-aux/install-reloc: Remove object files left over by some
1467         compilers.
1468         Reported by Ralf Wildenhues.
1469
1470 2007-03-01  Bruno Haible  <bruno@clisp.org>
1471
1472         * build-aux/install-reloc: Break long lines.
1473
1474 2007-03-01  Bruno Haible  <bruno@clisp.org>
1475
1476         * doc/relocatable.texi: Document that it may not work on OpenBSD.
1477         Reported by Ralf Wildenhues.
1478
1479 2007-03-01  Bruno Haible  <bruno@clisp.org>
1480
1481         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
1482         include ordering constraints.
1483
1484 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
1485
1486         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
1487         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
1488         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
1489         as another example.
1490         * lib/time_.h: Fix misspelling.
1491         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
1492         Require gl_HEADER_TIME_H_DEFAULTS.
1493         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
1494         * m4/time_r.m4 (gl_TIME_R): Likewise.
1495         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
1496
1497 2007-03-01  Bruno Haible  <bruno@clisp.org>
1498
1499         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
1500         * m4/utimens.m4 (gl_UTIMENS): Likewise.
1501
1502 2007-03-01  Jim Meyering  <jim@meyering.net>
1503
1504         * modules/xreadlink (Maintainer): Add my name.
1505         * modules/xreadlink-with-size (Depends-on): Alphabetize.
1506
1507 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
1508             Bruno Haible  <bruno@clisp.org>
1509
1510         * build-aux/install-reloc: Compile also c-ctype.c.
1511         * build-aux/relocatable.sh.in: New file.
1512         * doc/relocatable.texi: New file.
1513         * doc/relocatable-maint.texi: New file.
1514         * doc/gnulib.texi: Include relocatable-maint.texi.
1515         * lib/progreloc.c: Include unistd.h unconditionally.
1516         * lib/relocwrapper.c: Include unistd.h unconditionally.
1517         Include c-ctype.h.
1518         (add_dotbin): Use c_tolower.
1519         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
1520         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
1521         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
1522         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
1523         to m4/relocatable-lib.m4.
1524         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
1525         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
1526         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
1527         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
1528         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
1529         * modules/relocatable: New file.
1530         * modules/relocatable-lib: New file.
1531         * modules/relocatable-script: New file.
1532
1533 2007-02-28  Bruno Haible  <bruno@clisp.org>
1534
1535         Import --enable-relocatable infrastructure.
1536         * build-aux/config.libpath: New file, from GNU gettext.
1537         * build-aux/install-reloc: New file, from GNU gettext.
1538         * build-aux/reloc-ldflags: New file, from GNU gettext.
1539         * lib/relocatable.h: New file, from GNU gettext.
1540         * lib/relocatable.c: New file, from GNU gettext.
1541         * lib/relocwrapper.c: New file, from GNU gettext.
1542         * m4/relocatable.m4: New file, from GNU gettext.
1543
1544 2007-02-28  Bruno Haible  <bruno@clisp.org>
1545
1546         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
1547
1548         * modules/xreadlink: New file, from GNU gettext with modifications.
1549         * lib/xreadlink.c: New file, from GNU gettext.
1550         * lib/xreadlink.h: Add comments.
1551         (xreadlink): New declaration.
1552
1553         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
1554         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
1555         lib/xreadlink-with-size.c.
1556         (configure.ac): Remove gl_XREADLINK invocation.
1557         (Makefile.am): Augment lib_SOURCES.
1558         * m4/xreadlink.m4: Remove file.
1559         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
1560         (xreadlink_with_size): Renamed from xreadink.
1561         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
1562         * modules/canonicalize (Depends-on): Replace xreadlink with
1563         xreadlink-with-size.
1564         * lib/canonicalize.c (canonicalize_filename_mode): Update.
1565
1566 2007-02-25  Jim Meyering  <jim@meyering.net>
1567
1568         * build-aux/announce-gen: When complaining about excess arguments,
1569         list them.
1570
1571 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
1572
1573         * README: Document signed integer overflow situation more
1574         accurately.
1575
1576 2007-02-25  Bruno Haible  <bruno@clisp.org>
1577
1578         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
1579         'a' or 'A' conversion.
1580
1581 2007-02-25  Bruno Haible  <bruno@clisp.org>
1582
1583         * modules/filename: Renamed from modules/pathname.
1584         (Files): Replace lib/pathname.h with lib/filename.h. Replace
1585         lib/concatpath.c with lib/concat-filename.c.
1586         (Makefile.am): Update.
1587         (Include): Replace pathname.h with filename.h.
1588         * lib/filename.h: Renamed from lib/pathname.h.
1589         (concatenated_filename): Renamed from concatenated_pathname.
1590         * lib/concat-filename.c: Renamed from lib/concatpath.c.
1591         (concatenated_filename): Renamed from concatenated_pathname.
1592         * lib/findprog.c: Include filename.h instead of pathname.h.
1593         (find_in_path): Update.
1594         * lib/javacomp.c: Include filename.h instead of pathname.h.
1595         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
1596         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
1597         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
1598         is_oldgcj_14_13_usable, is_javac_usable): Update.
1599         * lib/javaexec.c: Include filename.h instead of pathname.h.
1600         (execute_java_class): Update.
1601         * modules/findprog: Update.
1602         * modules/javacomp: Update.
1603         * modules/javaexec: Update.
1604         * MODULES.html.sh (File system functions): Add 'filename', remove
1605         'pathname'.
1606
1607 2007-02-25  Bruno Haible  <bruno@clisp.org>
1608
1609         * modules/printf-frexpl-tests: New file.
1610         * tests/test-printf-frexpl.c: New file.
1611
1612         * modules/printf-frexpl: New file.
1613         * lib/printf-frexpl.h: New file.
1614         * lib/printf-frexpl.c: New file.
1615         * m4/printf-frexpl.m4: New file.
1616
1617 2007-02-25  Bruno Haible  <bruno@clisp.org>
1618
1619         * modules/printf-frexp-tests: New file.
1620         * tests/test-printf-frexp.c: New file.
1621
1622         * modules/printf-frexp: New file.
1623         * lib/printf-frexp.h: New file.
1624         * lib/printf-frexp.c: New file.
1625         * m4/printf-frexp.m4: New file.
1626
1627 2007-02-25  Bruno Haible  <bruno@clisp.org>
1628
1629         Assume automake >= 1.10 for the tests.
1630         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
1631         * modules/arctwo-tests: Likewise.
1632         * modules/argp-tests: Likewise.
1633         * modules/avltree-list-tests: Likewise.
1634         * modules/avltree-oset-tests: Likewise.
1635         * modules/avltreehash-list-tests: Likewise.
1636         * modules/carray-list-tests: Likewise.
1637         * modules/crc-tests: Likewise.
1638         * modules/des-tests: Likewise.
1639         * modules/gc-arcfour-tests: Likewise.
1640         * modules/gc-arctwo-tests: Likewise.
1641         * modules/gc-des-tests: Likewise.
1642         * modules/gc-hmac-md5-tests: Likewise.
1643         * modules/gc-hmac-sha1-tests: Likewise.
1644         * modules/gc-md2-tests: Likewise.
1645         * modules/gc-md4-tests: Likewise.
1646         * modules/gc-md5-tests: Likewise.
1647         * modules/gc-pbkdf2-sha1-tests: Likewise.
1648         * modules/gc-rijndael-tests: Likewise.
1649         * modules/gc-sha1-tests: Likewise.
1650         * modules/gc-tests: Likewise.
1651         * modules/getaddrinfo-tests: Likewise.
1652         * modules/hmac-md5-tests: Likewise.
1653         * modules/hmac-sha1-tests: Likewise.
1654         * modules/linked-list-tests: Likewise.
1655         * modules/linkedhash-list-tests: Likewise.
1656         * modules/lock-tests: Likewise.
1657         * modules/md2-tests: Likewise.
1658         * modules/md4-tests: Likewise.
1659         * modules/md5-tests: Likewise.
1660         * modules/rbtree-list-tests: Likewise.
1661         * modules/rbtree-oset-tests: Likewise.
1662         * modules/rbtreehash-list-tests: Likewise.
1663         * modules/read-file-tests: Likewise.
1664         * modules/rijndael-tests: Likewise.
1665         * modules/stdint-tests: Likewise.
1666         * modules/tls-tests: Likewise.
1667
1668 2007-02-24  Bruno Haible  <bruno@clisp.org>
1669
1670         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
1671         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
1672         function; instead check whether isnan with a double argument links.
1673         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
1674         function; instead check whether isnan with a 'long double' argument
1675         links.
1676         Reported by Eric Blake <ebb9@byu.net>.
1677
1678 2007-02-24  Bruno Haible  <bruno@clisp.org>
1679
1680         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
1681         defined.
1682         * lib/isnanl.c: Remove all code. Just include isnan.c.
1683         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
1684
1685 2007-02-25  Jim Meyering  <jim@meyering.net>
1686
1687         Avoid conflicting types for 'unsetenv' on FreeBSD.
1688         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
1689         conflicting with FreeBSD's (5.0 and 6.1) function declaration
1690         in stdlib.h.
1691
1692 2007-02-24  Bruno Haible  <bruno@clisp.org>
1693
1694         * modules/isnanl-nolibm-tests: New file.
1695         * tests/test-isnanl.c: New file.
1696
1697         * modules/isnanl-nolibm: New file.
1698         * lib/isnanl.h: New file.
1699         * lib/isnanl.c: New file.
1700         * m4/isnanl.m4: New file.
1701
1702 2007-02-24  Bruno Haible  <bruno@clisp.org>
1703
1704         * modules/isnan-nolibm-tests: New file.
1705         * tests/test-isnan.c: New file.
1706
1707         * modules/isnan-nolibm: New file.
1708         * lib/isnan.h: New file.
1709         * lib/isnan.c: New file.
1710         * m4/isnan.m4: New file.
1711
1712 2007-02-24  Bruno Haible  <bruno@clisp.org>
1713
1714         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
1715         assume that an exponent fits in 20 bits.
1716
1717 2007-02-24  Jim Meyering  <jim@meyering.net>
1718
1719         * m4/regex.m4: Update the description of the configure-time option,
1720         --without-included-regex, to state accurately what the defaults are,
1721         and perhaps to give people an idea why using this option is risky.
1722
1723 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
1724
1725         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
1726         loops on small arguments.  This attempts to avoid the problem
1727         Bruno Haible reported for AIX 4.3.2 in
1728         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
1729
1730 2007-02-23  Bruno Haible  <bruno@clisp.org>
1731
1732         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
1733         Needed for help2man.
1734
1735 2007-02-23  Karl Berry  <karl@gnu.org>
1736
1737         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
1738         exists, foo.h should be cvs-ignored, not committed.
1739
1740 2007-02-23  Eric Blake  <ebb9@byu.net>
1741
1742         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
1743         * lib/stat-time.h (includes): Likewise.
1744         * lib/utimecmp.c (includes): Likewise.
1745         * lib/utimens.h (includes): Likewise.
1746         * lib/getdate.y (includes): Also include "timespec.h" for use
1747         internal to the module.
1748         * modules/utimens (Depends-on): Revert yesterday's patch.
1749         * modules/nanosleep (Depends-on): Add missing dependency.
1750
1751 2007-02-22  Bruno Haible  <bruno@clisp.org>
1752
1753         * lib/glob.c: Don't include getlogin_r.h.
1754
1755 2007-02-22  Jim Meyering  <jim@meyering.net>
1756
1757         * modules/utimens (Depends-on): Add timespec, required for
1758         utimens.h's inclusion of timespec.h.
1759
1760 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
1761
1762         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
1763         long unreadable paths in GNU/Linux.  Problem reported by Andreas
1764         Schwab in
1765         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
1766         I'll try to think of a better way to fix the Solaris problem.
1767
1768         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
1769         like glibc; on Solaris 10, it fails with errno == EINVAL.
1770         POSIX says the behavior is unspecified if the first argument is NULL,
1771         so play it safe and never pass NULL to the system getcwd.
1772
1773 2007-02-21  Jim Meyering  <jim@meyering.net>
1774
1775         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
1776         of gettimeofday.  It would conflict with the one now always
1777         provided via sys_time_.h.  Reported by Matthew Woehlke, as
1778         an IRIX 6.5 build failure.
1779
1780 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
1781
1782         Minor fixups to port to Solaris 10 with Sun C 5.8.
1783         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
1784         * modules/getcwd (Depends-on): Add dirfd.
1785         * lib/putenv.c (putenv): #undef it.
1786         (rpl_putenv): New decl.
1787         (malloc, free): Include <stdlib.h> rather than prototyping separately.
1788
1789 2007-02-20  Bruno Haible  <bruno@clisp.org>
1790
1791         * modules/stdio-tests: New file.
1792         * tests/test-stdio.c: New file.
1793
1794         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
1795         (Depends-on): Add stdio.
1796         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
1797         (Include): Use <stdio.h> instead of vsnprintf.h.
1798         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
1799         HAVE_DECL_VSNPRINTF.
1800         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
1801
1802         * modules/snprintf (Files): Remove lib/snprintf.h.
1803         (Depends-on): Add stdio.
1804         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
1805         (Include): Use <stdio.h> instead of snprintf.h.
1806         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
1807         HAVE_DECL_SNPRINTF.
1808         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
1809         * lib/getaddrinfo.c: Likewise.
1810
1811         * modules/stdio: New file.
1812         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
1813         * lib/snprintf.h: Remove file.
1814         * lib/vsnprintf.h: Remove file.
1815         * lib/.cppi-disable: Remove snprintf.h.
1816         * m4/stdio_h.m4: New file.
1817         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
1818
1819 2007-02-20  Jim Meyering  <jim@meyering.net>
1820
1821         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
1822         used by e.g., mingw.  From Bruno Haible.
1823
1824 2007-02-19  Bruno Haible  <bruno@clisp.org>
1825
1826         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
1827         warnings.
1828         Reported by Ben Pfaff <blp@cs.stanford.edu>.
1829
1830 2007-02-19  Bruno Haible  <bruno@clisp.org>
1831
1832         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
1833         from mingw users.
1834
1835 2007-02-19  Bruno Haible  <bruno@clisp.org>
1836
1837         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
1838         warnings.
1839         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
1840
1841 2007-02-19  Jim Meyering  <jim@meyering.net>
1842
1843         Don't use FD after a successful "fdopendir (fd)".
1844         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
1845         Reset it by calling dirfd on the just-obtained DIR*.
1846
1847         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
1848         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
1849
1850 2007-02-18  Bruno Haible  <bruno@clisp.org>
1851
1852         * lib/readlink.c: Include <unistd.h>.
1853         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
1854         HAVE_READLINK.
1855         * modules/readlink (Depends-on): Add unistd.
1856         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1857         (Include): Add <unistd.h>.
1858
1859         * lib/getlogin_r.h: Remove file.
1860         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
1861         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
1862         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
1863         HAVE_DECL_GETLOGIN_R.
1864         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
1865         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1866         (Include): Use <unistd.h> instead of getlogin_r.h.
1867
1868         * lib/getcwd.h: Remove file.
1869         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
1870         * lib/xgetcwd.c: Likewise.
1871         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
1872         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
1873         * modules/getcwd (Files): Remove lib/getcwd.h.
1874         (Depends-on): Add unistd.
1875         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1876         (Include): Use <unistd.h> instad of getcwd.h.
1877
1878         * lib/ftruncate.c: Include <unistd.h> first.
1879         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
1880         Set HAVE_FTRUNCATE.
1881         * modules/ftruncate (Depends-on): Add unistd.
1882         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1883
1884         * lib/fchdir.c: Include <unistd.h> first.
1885         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
1886         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
1887         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
1888         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1889         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
1890
1891         * lib/dup2.c: Include <unistd.h> first.
1892         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
1893         HAVE_DUP2.
1894         * modules/dup2 (Depends-on): Add unistd.
1895         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1896
1897         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
1898         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
1899         REPLACE_CHOWN. Don't define chown as a macro here.
1900         * modules/chown (Depends-on): Add unistd.
1901         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
1902
1903         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
1904         Add definition for GL_LINK_WARNING.
1905         (chown, dup2): New declarations.
1906         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
1907         link warning.
1908         (ftruncate): New declaration.
1909         (getcwd): New declaration, taken from old getcwd.h.
1910         (getlogin_r): New declaration, taken from old getlogin_r.h.
1911         (readlink): New declaration.
1912         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
1913         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
1914         (gl_PREREQ_UNISTD): Remove macro.
1915         (gl_UNISTD_MODULE_INDICATOR): New macro.
1916         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
1917         many new variables. Don't set UNISTD_H.
1918         * modules/unistd (Description): Change.
1919         (Depends-on): Add link-warning.
1920         (configure.ac): Update.
1921         (Makefile.am): Create unistd.h always. Substitute many new variables
1922         into it.
1923
1924 2007-02-18  Bruno Haible  <bruno@clisp.org>
1925
1926         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
1927         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
1928         HAVE_GETSUBOPT.
1929         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
1930         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
1931         * lib/getsubopt.h: Remove file.
1932         * modules/getsubopt (Files): Remove lib/getsubopt.h.
1933         (Depends-on): Add stdlib.
1934         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
1935         (Includes): Use <stdlib.h> instead of getsubopt.h.
1936         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
1937         Set HAVE_GETSUBOPT.
1938         * lib/getsubopt.c: Don't include getsubopt.h.
1939
1940 2007-02-18  Bruno Haible  <bruno@clisp.org>
1941
1942         * modules/fchdir (Depends-on): Add dup2.
1943
1944 2007-02-18  Bruno Haible  <bruno@clisp.org>
1945
1946         * lib/stdlib_.h: Handle glibc's special invocation convention
1947         specially.
1948
1949 2007-02-18  Bruno Haible  <bruno@clisp.org>
1950
1951         * modules/stdlib-tests: New file.
1952         * tests/test-stdlib.c: New file.
1953
1954         * modules/mkstemp (Files): Remove lib/mkstemp.h.
1955         (Depends-on): Add stdlib.
1956         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
1957         (Includes): Use <stdlib.h> instead of mkstemp.h.
1958         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
1959         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
1960         * lib/mkstemp.c: Don't include mkstemp.h.
1961         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
1962         * lib/stdlib--.h: Don't include mkstemp.h.
1963
1964         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
1965         (Depends-on): Add stdlib.
1966         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
1967         (Includes): Use <stdlib.h> instead of mkdtemp.h.
1968         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
1969         HAVE_MKDTEMP.
1970         * lib/mkdtemp.c: Don't include mkdtemp.h.
1971         * lib/clean-temp.c: Don't include mkdtemp.h.
1972
1973         * modules/exit (Files): Remove lib/exit.h.
1974         (Depends-on): Add stdlib.
1975         (Makefile.am): Remove lib_SOURCES.
1976         (Include): Use <stdlib.h> instead of exit.h.
1977         * lib/argmatch.c: Don't include exit.h.
1978         * lib/execute.c: Likewise.
1979         * lib/pagealign_alloc.c: Likewise.
1980         * lib/pipe.c: Likewise.
1981         * lib/wait-process.c: Likewise.
1982         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
1983         * lib/exitfail.c: Likewise.
1984         * lib/savewd.c: Likewise.
1985         * lib/xsetenv.c: Likewise.
1986
1987         * modules/stdlib: New file.
1988         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
1989         and extra comments about mkstemp().
1990         * lib/exit.h: Remove file.
1991         * lib/mkdtemp.h: Remove file.
1992         * lib/mkstemp.h: Remove file.
1993         * m4/stdlib_h.m4: New file.
1994         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
1995
1996 2007-02-18  Bruno Haible  <bruno@clisp.org>
1997
1998         * modules/math-tests: New file.
1999         * tests/test-math.c: New file.
2000
2001         * modules/math: New file.
2002         * modules/mathl (Files): Remove lib/mathl.h.
2003         (Depends-on): Add math.
2004         (Makefile.am): Don't mention mathl.h.
2005         (Include): Use <math.h> instead of mathl.h.
2006         * lib/math_.h: New file.
2007         * lib/mathl.h: Remove file.
2008         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
2009         mathl.h.
2010         * lib/asinl.c: Likewise.
2011         * lib/atanl.c: Likewise.
2012         * lib/ceill.c: Likewise.
2013         * lib/cosl.c: Likewise.
2014         * lib/expl.c: Likewise.
2015         * lib/floorl.c: Likewise.
2016         * lib/frexpl.c: Likewise.
2017         * lib/ldexpl.c: Likewise.
2018         * lib/logl.c: Likewise.
2019         * lib/sincosl.c: Likewise.
2020         * lib/sinl.c: Likewise.
2021         * lib/sqrtl.c: Likewise.
2022         * lib/tanl.c: Likewise.
2023         * lib/trigl.c: Likewise.
2024         * m4/math_h.m4: New file.
2025         * MODULES.html.sh (Mathematics): Add math.
2026
2027 2007-02-17  Bruno Haible  <bruno@clisp.org>
2028
2029         * modules/wctype-tests: New file.
2030         * tests/test-wctype.c: New file.
2031
2032         * modules/wchar-tests: New file.
2033         * tests/test-wchar.c: New file.
2034
2035         * modules/unistd-tests: New file.
2036         * tests/test-unistd.c: New file.
2037
2038         * modules/time-tests: New file.
2039         * tests/test-time.c: New file.
2040
2041         * modules/sysexits-tests: New file.
2042         * tests/test-sysexits.c: New file.
2043
2044         * modules/sys_time-tests: New file.
2045         * tests/test-sys_time.c: New file.
2046
2047         * modules/sys_stat-tests: New file.
2048         * tests/test-sys_stat.c: New file.
2049
2050         * modules/sys_socket-tests: New file.
2051         * tests/test-sys_socket.c: New file.
2052
2053         * modules/sys_select-tests: New file.
2054         * tests/test-sys_select.c: New file.
2055
2056         * modules/string-tests: New file.
2057         * tests/test-string.c: New file.
2058
2059         * modules/stdbool-tests: New file.
2060         * tests/test-stdbool.c: New file.
2061
2062         * modules/netinet_in-tests: New file.
2063         * tests/test-netinet_in.c: New file.
2064
2065         * modules/inttypes-tests: New file.
2066         * tests/test-inttypes.c: New file.
2067
2068         * modules/fcntl-tests: New file.
2069         * tests/test-fcntl.c: New file.
2070
2071         * modules/byteswap-tests: New file.
2072         * tests/test-byteswap.c: New file.
2073
2074         * modules/arpa_inet-tests: New file.
2075         * tests/test-arpa_inet.c: New file.
2076
2077 2007-02-17  Bruno Haible  <bruno@clisp.org>
2078
2079         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
2080         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
2081         if the corresponding module is not enabled. Emit link warnings if
2082         the function is used nevertheless.
2083         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
2084         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
2085         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
2086         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
2087         * modules/inttypes (Depends-on): Add link-warning.
2088         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2089         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
2090         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
2091         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
2092         * modules/imaxdiv (configure.ac): Likewise.
2093         * modules/strtoimax (configure.ac): Likewise.
2094         * modules/strtoumax (configure.ac): Likewise.
2095
2096 2007-02-17  Bruno Haible  <bruno@clisp.org>
2097
2098         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
2099         gl_STRING_MODULE_INDICATOR_DEFAULTS.
2100         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
2101         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
2102
2103 2007-02-17  Bruno Haible  <bruno@clisp.org>
2104
2105         * modules/link-warning: New file.
2106         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
2107         * lib/string_.h (GL_LINK_WARNING): Remove definition.
2108         * modules/string (Depends-on): Add link-warning.
2109         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2110         string.h.
2111         * MODULES.html.sh (Support for building libraries and executables): Add
2112         link-warning.
2113
2114 2007-02-17  Bruno Haible  <bruno@clisp.org>
2115
2116         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
2117         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
2118         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
2119         long lines.
2120
2121 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
2122             Bruno Haible  <bruno@clisp.org>
2123
2124         * modules/tmpfile: New file.
2125         * lib/tmpfile.c: New file.
2126         * m4/tmpfile.m4: New file.
2127         * MODULES.html.sh (func_all_modules): New section "Input/output".
2128
2129 2007-02-15  Bruno Haible  <bruno@clisp.org>
2130
2131         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
2132         (supports_delete_on_close): New function.
2133         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
2134
2135 2007-02-14  Bruno Haible  <bruno@clisp.org>
2136
2137         * modules/mbspcasecmp-tests: New file.
2138         * tests/test-mbspcasecmp.sh: New file.
2139         * tests/test-mbspcasecmp.c: New file.
2140
2141         New module mbspcasecmp.
2142         * modules/mbspcasecmp: New file.
2143         * lib/mbspcasecmp.c: New file.
2144         * lib/string_.h (strncasecmp): Change warning message.
2145         (mbspcasecmp): New declaration.
2146         * m4/mbspcasecmp.m4: New file.
2147         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2148         GNULIB_MBSPCASECMP.
2149         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
2150         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
2151
2152 2007-02-14  Bruno Haible  <bruno@clisp.org>
2153
2154         * modules/mbsncasecmp-tests: New file.
2155         * tests/test-mbsncasecmp.sh: New file.
2156         * tests/test-mbsncasecmp.c: New file.
2157
2158         New module mbsncasecmp.
2159         * modules/mbsncasecmp: New file.
2160         * lib/mbsncasecmp.c: New file.
2161         * lib/string_.h (mbsncasecmp): New declaration.
2162         * m4/mbsncasecmp.m4: New file.
2163         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2164         GNULIB_MBSNCASECMP.
2165         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
2166         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
2167
2168 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
2169
2170         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
2171         Verify that it doesn't overlap with our flags.
2172         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
2173         do not have the desired effect in multibyte locales; instead, use
2174         mbscasecmp.
2175         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
2176         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
2177         we don't require GNU fnmatch ourselves (if our users require it, they
2178         should do so explicitly).
2179
2180         Fix regex code so it doesn't rely on strcasecmp.
2181         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
2182         Otherwise, include gnulib's langinfo.h.
2183         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
2184         undesirable behavior in non-C locales.  Instead, rely on localecharset.
2185         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
2186         * modules/regex (FILES): Remove m4/codeset.m4.
2187         (Depends-on): Add localcharset.  Remove strcase.
2188
2189 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2190
2191         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
2192         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
2193
2194 2007-02-13  Bruno Haible  <bruno@clisp.org>
2195
2196         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
2197         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
2198
2199 2007-02-12  Bruno Haible  <bruno@clisp.org>
2200
2201         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
2202         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
2203         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
2204         time warning rather than a link error.
2205
2206 2007-02-12  Bruno Haible  <bruno@clisp.org>
2207
2208         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
2209         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
2210         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
2211
2212 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
2213
2214         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
2215         args, not 2.
2216
2217 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
2218
2219         New module 'time', so that apps can include <time.h> as per
2220         POSIX and GNU instead of separate include files like time_r.h
2221         and timegm.h.  This implementation tries out a simpler approach
2222         for replacing decls in standard include files (as compared to
2223         the string module), somewhat as an experiment.
2224
2225         * config/srclist.txt: Comment out mktime.c for now.
2226         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
2227         since it doesn't apply any more.  Use generic wording instead.
2228         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
2229         'time'.
2230         * lib/time_.h, m4/time_h.m4, modules/time: New files.
2231         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
2232         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
2233         Don't include <sys/types.h>; no longer needed since we assume C89.
2234         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
2235         * lib/strftime.c: Likewise.
2236         * lib/time_r.c: Likewise.
2237         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
2238         * lib/nanosleep.c: Include <time.h> first, to check interface.
2239         * lib/strptime.c: Likewise.
2240         * lib/time_r.c: Likewise.
2241         * lib/timegm.c: Likewise.
2242         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
2243         needed.
2244         * lib/timegm.c: Don't include timegm.h; no longer needed.
2245         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
2246         time.h now handles any problems in that area.
2247         (struct timespec, nanosleep): Remove; time.h now arranges for these.
2248         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
2249         that time.h defines struct timespec.
2250         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
2251         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
2252         handles that.
2253         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
2254         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
2255         needed.  Set REPLACE_LOCALTIME.
2256         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
2257         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
2258         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
2259         nanosleep; time_h.m4 now does that.  Don't require
2260         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
2261         module handles this now.
2262         * modules/getdate (Depends-on): Remove timespec.  Add time.
2263         * modules/nanosleep (Depends-on): Likewise.
2264         * modules/stat-time (Depends-on): Likewise.
2265         * modules/nanosleep (Include): Include time.h, not timespec.h.
2266         * modules/strptime (Files): Remove lib/strptime.h.
2267         (Depends-on): Add extensions, time.
2268         (Include): Include time.h, not strptime.h.
2269         * modules/time_r (Files): Remove lib/time_r.h.
2270         (Depends-on): Add time.
2271         (Include): Include time.h, not time_r.h.
2272         * modules/timegm: Likewise.
2273         * modules/timespec (Description): Now does timespec-related decls
2274         of our own, instead of struct timespec itself.
2275         (Depends-on): Add time; remove extensions.
2276         (Maintainer): Add self.
2277         * modules/utimecmp (Depends-on): Add time; remove timespec.
2278         * modules/utimens (Depends-on): Likewise.
2279         * modules/xnanosleep (Depends-on): Likewise.
2280
2281 2007-02-11  Bruno Haible  <bruno@clisp.org>
2282
2283         * lib/c-strstr.c: Include allocsa.h.
2284         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2285         * lib/c-strcasestr.c: Include allocsa.h.
2286         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2287         * lib/strcasestr.c: Include allocsa.h.
2288         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2289         * lib/mbsstr.c: Include allocsa.h.
2290         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
2291         allocsa/freesa instead of malloc/free.
2292         * lib/mbscasestr.c: Include allocsa.h.
2293         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
2294         allocsa/freesa instead of malloc/free.
2295         * modules/c-strstr (Depends-on): Add allocsa.
2296         * modules/c-strcasestr (Depends-on): Likewise.
2297         * modules/strcasestr (Depends-on): Likewise.
2298         * modules/mbsstr (Depends-on): Likewise.
2299         * modules/mbscasestr (Depends-on): Likewise.
2300
2301 2007-02-11  Bruno Haible  <bruno@clisp.org>
2302
2303         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
2304
2305         * modules/mbsspn-tests: New file.
2306         * tests/test-mbsspn.sh: New file.
2307         * tests/test-mbsspn.c: New file.
2308
2309 2007-02-11  Bruno Haible  <bruno@clisp.org>
2310
2311         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
2312
2313         * modules/mbspbrk-tests: New file.
2314         * tests/test-mbspbrk.sh: New file.
2315         * tests/test-mbspbrk.c: New file.
2316
2317 2007-02-11  Bruno Haible  <bruno@clisp.org>
2318
2319         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
2320         unneeded cast.
2321
2322         * modules/mbscspn-tests: New file.
2323         * tests/test-mbscspn.sh: New file.
2324         * tests/test-mbscspn.c: New file.
2325
2326 2007-02-11  Bruno Haible  <bruno@clisp.org>
2327
2328         * modules/mbscasecmp-tests: New file.
2329         * tests/test-mbscasecmp.sh: New file.
2330         * tests/test-mbscasecmp.c: New file.
2331
2332 2007-02-11  Bruno Haible  <bruno@clisp.org>
2333
2334         Ensure O(n) worst-case complexity of mbscasestr.
2335         * lib/mbscasestr.c: Include stdbool.h.
2336         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
2337         functions.
2338         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
2339         the bookkeeping indicates that it's worth it.
2340         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
2341
2342         * modules/mbscasestr-tests: New file.
2343         * tests/test-mbscasestr1.c: New file.
2344         * tests/test-mbscasestr2.sh: New file.
2345         * tests/test-mbscasestr2.c: New file.
2346         * tests/test-mbscasestr3.sh: New file.
2347         * tests/test-mbscasestr3.c: New file.
2348         * tests/test-mbscasestr4.sh: New file.
2349         * tests/test-mbscasestr4.c: New file.
2350         * m4/locale-tr.m4: New file.
2351
2352 2007-02-11  Bruno Haible  <bruno@clisp.org>
2353
2354         Ensure O(n) worst-case complexity of mbsstr.
2355         * lib/mbsstr.c: Include stdbool.h.
2356         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
2357         functions.
2358         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
2359         bookkeeping indicates that it's worth it.
2360         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
2361
2362         * modules/mbsstr-tests: New file.
2363         * tests/test-mbsstr1.c: New file.
2364         * tests/test-mbsstr2.sh: New file.
2365         * tests/test-mbsstr2.c: New file.
2366         * tests/test-mbsstr3.sh: New file.
2367         * tests/test-mbsstr3.c: New file.
2368         * m4/locale-fr.m4: New file.
2369
2370 2007-02-11  Bruno Haible  <bruno@clisp.org>
2371
2372         * lib/mbsrchr.c (mbsrchr): Fix bug.
2373
2374         * modules/mbsrchr-tests: New file.
2375         * tests/test-mbsrchr.sh: New file.
2376         * tests/test-mbsrchr.c: New file.
2377
2378 2007-02-11  Bruno Haible  <bruno@clisp.org>
2379
2380         * lib/mbschr.c (mbschr): Fix bug.
2381
2382         * modules/mbschr-tests: New file.
2383         * tests/test-mbschr.sh: New file.
2384         * tests/test-mbschr.c: New file.
2385         * m4/locale-zh.m4: New file.
2386
2387 2007-02-11  Bruno Haible  <bruno@clisp.org>
2388
2389         Support for copying multibyte string iterators.
2390         * lib/mbiter.h: Include <string.h>.
2391         (mbiter_multi_copy): New function.
2392         (mbi_copy): New macro.
2393         * lib/mbuiter.h: Include <string.h>.
2394         (mbuiter_multi_copy): New function.
2395         (mbui_copy): New macro.
2396
2397 2007-02-11  Bruno Haible  <bruno@clisp.org>
2398
2399         New module mbslen.
2400         * modules/mbslen: New file.
2401         * lib/mbslen.c: New file.
2402         * lib/string_.h (mbslen): New declaration.
2403         * m4/mbslen.m4: New file.
2404         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2405         GNULIB_MBSLEN.
2406         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
2407         * MODULES.html.sh (Internationalization functions): Add mbslen.
2408
2409 2007-02-11  Bruno Haible  <bruno@clisp.org>
2410
2411         Ensure O(n) worst-case complexity of strcasestr substitute.
2412         * lib/strcasestr.c: Include stdbool.h.
2413         (knuth_morris_pratt): New function.
2414         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
2415         bookkeeping indicates that it's worth it.
2416         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
2417
2418         * modules/strcasestr-tests: New file.
2419         * tests/test-strcasestr.c: New file.
2420
2421 2007-02-11  Bruno Haible  <bruno@clisp.org>
2422
2423         Ensure O(n) worst-case complexity of c_strcasestr.
2424         * lib/c-strcasestr.c: Include stdbool.h, string.h.
2425         (knuth_morris_pratt): New function.
2426         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
2427         the bookkeeping indicates that it's worth it.
2428         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
2429
2430         * modules/c-strcasestr-tests: New file.
2431         * tests/test-c-strcasestr.c: New file.
2432
2433 2007-02-11  Bruno Haible  <bruno@clisp.org>
2434
2435         Ensure O(n) worst-case complexity of c_strstr.
2436         * lib/c-strstr.c: Include stdbool.h, string.h.
2437         (knuth_morris_pratt): New function.
2438         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
2439         bookkeeping indicates that it's worth it.
2440         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
2441
2442         * lib/c-strstr.c: Complete rewrite for maintainability.
2443
2444         * modules/c-strstr-tests: New file.
2445         * tests/test-c-strstr.c: New file.
2446
2447 2007-02-11  Bruno Haible  <bruno@clisp.org>
2448
2449         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
2450         5.2.1 and earlier, whereby \055 was treated just like the range
2451         delimiter '-'.
2452         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
2453
2454 2007-02-08  Bruno Haible  <bruno@clisp.org>
2455
2456         * modules/regex (Depends-on): Add stdbool.
2457         Reported by Dalibor Topic <robilad@kaffe.org>.
2458
2459 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
2460
2461         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
2462         Prefer returning from main to exiting from it.
2463         Remove unnecessary parens after sizeof.
2464
2465 2007-02-05  Bruno Haible  <bruno@clisp.org>
2466
2467         New module mbssep.
2468         * modules/mbssep: New file.
2469         * lib/mbssep.c: New file.
2470         * lib/string_.h (strsep): Add a conditional link warning.
2471         (mbssep): New declaration.
2472         * m4/mbssep.m4: New file.
2473         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2474         GNULIB_MBSSEP.
2475         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
2476         * MODULES.html.sh (Internationalization functions): Add mbssep.
2477
2478 2007-02-05  Bruno Haible  <bruno@clisp.org>
2479
2480         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
2481         Optimize search in case of 1 delimiter.
2482
2483 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
2484
2485         * lib/acl.h: Include sys/types.h before sys/acl.h.
2486
2487 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
2488
2489         Merge upstream fix for glibc bugzilla #3957:
2490
2491         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
2492
2493         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
2494         bit for RE_HAT_LISTS_NOT_NEWLINE.
2495         (build_charclass_op): Remove bogus comment.
2496
2497 2007-02-05  Simon Josefsson  <simon@josefsson.org>
2498
2499         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
2500
2501 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
2502
2503         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
2504         * lib/memmem.c [!defined _LIBC]: Include config.h.
2505
2506 2007-02-04  Bruno Haible  <bruno@clisp.org>
2507
2508         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
2509         warning message.
2510
2511 2007-02-04  Bruno Haible  <bruno@clisp.org>
2512
2513         New module mbstok_r.
2514         * modules/mbstok_r: New file.
2515         * lib/mbstok_r.c: New file.
2516         * lib/string_.h (strtok_r): Change argument names to match the
2517         comments. Add a conditional link warning.
2518         (mbstok_r): New declaration.
2519         * m4/mbstok_r.m4: New file.
2520         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2521         GNULIB_MBSTOK_R.
2522         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
2523         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
2524
2525 2007-02-04  Bruno Haible  <bruno@clisp.org>
2526
2527         New module mbsspn.
2528         * modules/mbsspn: New file.
2529         * lib/mbsspn.c: New file.
2530         * lib/string_.h (strspn): Add a conditional link warning.
2531         (mbsspn): New declaration.
2532         * m4/mbsspn.m4: New file.
2533         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2534         GNULIB_MBSSPN.
2535         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
2536         * MODULES.html.sh (Internationalization functions): Add mbsspn.
2537
2538 2007-02-04  Bruno Haible  <bruno@clisp.org>
2539
2540         New module mbspbrk.
2541         * modules/mbspbrk: New file.
2542         * lib/mbspbrk.c: New file.
2543         * lib/string_.h (strpbrk): Add a conditional link warning.
2544         (mbspbrk): New declaration.
2545         * m4/mbspbrk.m4: New file.
2546         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2547         GNULIB_MBSPBRK.
2548         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
2549         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
2550
2551 2007-02-04  Bruno Haible  <bruno@clisp.org>
2552
2553         New module mbscspn.
2554         * modules/mbscspn: New file.
2555         * lib/mbscspn.c: New file.
2556         * lib/string_.h (strcspn): Add a conditional link warning.
2557         (mbscspn): New declaration.
2558         * m4/mbscspn.m4: New file.
2559         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2560         GNULIB_MBSCSPN.
2561         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
2562         * MODULES.html.sh (Internationalization functions): Add mbscspn.
2563
2564 2007-02-04  Bruno Haible  <bruno@clisp.org>
2565
2566         New module mbscasestr, reduced goal of strcasestr.
2567         * modules/mbscasestr: New file.
2568         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
2569         (mbscasestr): Renamed from strcasestr.
2570         * lib/strcasestr.c: Don't include mbuiter.h.
2571         (strcasestr): Remove support for multibyte locales.
2572         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
2573         Change the conditional link warning.
2574         (mbscasestr): New declaration.
2575         * m4/mbscasestr.m4: New file.
2576         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
2577         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
2578         REPLACE_STRCASESTR.
2579         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
2580         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
2581         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
2582         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
2583         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
2584         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
2585         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
2586         (Depends-on): Remove mbuiter.
2587         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
2588
2589 2007-02-04  Bruno Haible  <bruno@clisp.org>
2590
2591         Simplify handling of strncasecmp.
2592         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
2593         the conditional link warning.
2594         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
2595         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
2596         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
2597         * modules/strcase (configure.ac): Don't invoke
2598         gl_STRING_MODULE_INDICATOR.
2599         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
2600
2601 2007-02-04  Bruno Haible  <bruno@clisp.org>
2602
2603         New module mbscasecmp, reduced goal of strcasecmp.
2604         * modules/mbscasecmp: New file.
2605         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
2606         (mbscasecmp): Renamed from strcasecmp.
2607         * lib/strcasecmp.c: Don't include mbuiter.h.
2608         (strcasecmp): Remove support for multibyte locales.
2609         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
2610         Change the conditional link warning.
2611         (mbscasecmp): New declaration.
2612         * m4/mbscasecmp.m4: New file.
2613         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
2614         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
2615         REPLACE_STRCASECMP.
2616         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
2617         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2618         GNULIB_MBSCASECMP.
2619         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
2620         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
2621         * modules/strcase (Files): Remove m4/mbrtowc.m4.
2622         (Depends-on): Remove mbuiter.
2623         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
2624
2625 2007-02-04  Bruno Haible  <bruno@clisp.org>
2626
2627         New module mbsstr. Remove module strstr.
2628         * modules/mbsstr: New file.
2629         * modules/strstr: Remove file.
2630         * lib/mbsstr.c: Renamed from lib/strstr.c.
2631         (mbsstr): Renamed from strstr.
2632         * lib/string_.h (strstr): Remove declaration. Change the conditional
2633         link warning.
2634         (mbsstr): New declaration.
2635         * m4/mbsstr.m4: New file.
2636         * m4/strstr.m4: Remove file.
2637         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
2638         REPLACE_STRSTR.
2639         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
2640         Don't initialize GNULIB_STRSTR.
2641         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
2642         substitute GNULIB_STRSTR and REPLACE_STRSTR.
2643         * MODULES.html.sh (Internationalization functions): Add mbsstr.
2644         (Support for systems lacking ANSI C 89): Remove strstr.
2645
2646 2007-02-04  Bruno Haible  <bruno@clisp.org>
2647
2648         New module mbsrchr.
2649         * modules/mbsrchr: New file.
2650         * lib/mbsrchr.c: New file.
2651         * lib/string_.h (strrchr): Add a conditional link warning.
2652         (mbsrchr): New declaration.
2653         * m4/mbsrchr.m4: New file.
2654         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2655         GNULIB_MBSRCHR.
2656         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
2657         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
2658
2659 2007-02-04  Bruno Haible  <bruno@clisp.org>
2660
2661         New module mbschr.
2662         * modules/mbschr: New file.
2663         * lib/mbschr.c: New file.
2664         * lib/string_.h (strchr): Add a conditional link warning.
2665         (mbschr): New declaration.
2666         * m4/mbschr.m4: New file.
2667         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2668         GNULIB_MBSCHR.
2669         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
2670         * MODULES.html.sh (Internationalization functions): Add mbschr.
2671
2672 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
2673
2674         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
2675
2676         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
2677
2678 2007-02-04  Bruno Haible  <bruno@clisp.org>
2679
2680         New module description section 'configure.ac-early'.
2681         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
2682         (func_get_autoconf_early_snippet): New function.
2683         (func_import, func_create_testdir): Use it. Remove special cases for
2684         modules 'extensions' and 'lock'.
2685         * modules/extensions (configure.ac-early): Require
2686         gl_USE_SYSTEM_EXTENSIONS.
2687         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
2688
2689 2007-02-04  Bruno Haible  <bruno@clisp.org>
2690
2691         Make use of gcj-4.3's -fsource and -ftarget option.
2692         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
2693         and if so try the options -fsource and -ftarget.
2694         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
2695         source_version, ftarget_option, target_version arguments.
2696         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
2697         (is_envjavac_oldgcj_14_14_usable): Renamed from
2698         is_envjavac_gcj_14_14_usable.
2699         (is_envjavac_oldgcj_14_13_usable): Renamed from
2700         is_envjavac_gcj_14_13_usable.
2701         (is_gcj_present): Update.
2702         (is_gcj_43, is_gcj43_usable): New functions.
2703         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
2704         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
2705         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
2706         try the options -fsource and -ftarget.
2707
2708 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
2709
2710         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
2711         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
2712         larger value.
2713
2714 2007-02-03  Jim Meyering  <jim@meyering.net>
2715
2716         Give tools a better chance to allocate space for very large buffers.
2717         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
2718
2719         Make pwd and readlink work also when run with an unreadable parent dir
2720         on systems with openat support.
2721         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
2722         provided getcwd function, even when we have openat support.
2723         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
2724
2725 2007-02-02  Bruno Haible  <bruno@clisp.org>
2726
2727         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
2728         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
2729         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
2730         portability problems if one of these functions is only used on specific
2731         platforms.
2732         Reported by Paul Eggert.
2733
2734 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
2735
2736         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
2737         is causing more trouble than it's curing.
2738         * lib/regex_internal.h (__mempcpy): Remove.
2739         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
2740         (and make the code a tad smaller to boot).
2741         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
2742
2743 2007-02-02  Jim Meyering  <jim@meyering.net>
2744
2745         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
2746         section, not in the Makefile.am: one.
2747
2748 2007-02-02  Eric Blake  <ebb9@byu.net>
2749
2750         * lib/strchrnul.c: Always include config.h first.
2751
2752         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
2753         gnulib strstr is not necessary here.
2754
2755 2007-02-02  Simon Josefsson  <simon@josefsson.org>
2756
2757         * m4/socklen.m4: Fix typo.
2758
2759 2007-02-02  Eric Blake  <ebb9@byu.net>
2760
2761         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
2762         * modules/netinet_in (Makefile.am): Likewise.
2763
2764 2007-02-01  Bruno Haible  <bruno@clisp.org>
2765
2766         * lib/string_.h (GL_LINK_WARNING): New macro.
2767         (strcasecmp, strstr, strcasestr): If provided by the system,
2768         conditionally define as a macro that leads to a warning instead of to
2769         an error.
2770         (strncasecmp): Conditionally define as a macro that leads to a warning.
2771
2772 2007-02-01  Karl Berry  <karl@gnu.org>
2773
2774         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
2775
2776 2007-02-01  Bruno Haible  <bruno@clisp.org>
2777
2778         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
2779         renamings.
2780
2781 2007-02-01  Eric Blake  <ebb9@byu.net>
2782
2783         * modules/regex (Depends-on): Revert dependence on mempcpy.
2784         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
2785         module's definition of mempcpy.
2786         Reported by Paul Eggert.
2787
2788 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
2789
2790         * lib/string_.h: If the gnulib module XYZ is not present, undefine
2791         the symbol XYZ before redefining it.  This fixes a problem with
2792         programs that don't use XYZ, when compiled on systems that define
2793         XYZ to something else.
2794
2795 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
2796
2797         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
2798         occurs when "mkdir -m foo" creates a setgid directory that is (1)
2799         writeable to group or other and (2) is intended to have a special
2800         mode bit that is set or cleared.  In such a case, the directory
2801         should be neither group- nor other-writeable until the special
2802         mode bits are right.
2803
2804 2007-01-31  Eric Blake  <ebb9@byu.net>
2805
2806         * modules/mountlist (Depends-on): Add strstr.
2807
2808         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
2809         bug.
2810         * modules/string (Makefile.am): Remove redundant replacement.
2811         * modules/regex (Depends-on): Add mempcpy.
2812
2813 2007-01-31  Bruno Haible  <bruno@clisp.org>
2814
2815         New module description field 'Link'.
2816         * gnulib-tool (func_usage): Document --extract-link-directive.
2817         (sed_extract_prog): Recognize 'Link' directive.
2818         (func_get_link_directive): New function.
2819         (func_import): Show summary of link directives.
2820         Handle --extract-link-directive option.
2821         * modules/acl (Link): New section.
2822         * modules/clock-time (Link): New section.
2823         * modules/euidaccess (Link): New section.
2824         * modules/gettext (Link): New section.
2825         * modules/iconv (Link): New section.
2826         * modules/lock (Link): New section.
2827         * modules/nanosleep (Link): New section.
2828         * modules/readline (Link): New section.
2829
2830 2007-01-27  Bruno Haible  <bruno@clisp.org>
2831
2832         Enforce the use of gnulib modules for unportable <string.h> functions.
2833         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
2834         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
2835         (gl_HEADER_STRING_H_BODY): Require it.
2836         * lib/string_.h: If the gnulib module XYZ is not present, redefine
2837         the symbol XYZ to one that gives a link error.
2838         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
2839         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
2840         * modules/mempcpy (configure.ac): Likewise.
2841         * modules/memrchr (configure.ac): Likewise.
2842         * modules/stpcpy (configure.ac): Likewise.
2843         * modules/stpncpy (configure.ac): Likewise.
2844         * modules/strcase (configure.ac): Likewise.
2845         * modules/strcasestr (configure.ac): Likewise.
2846         * modules/strchrnul (configure.ac): Likewise.
2847         * modules/strdup (configure.ac): Likewise.
2848         * modules/strndup (configure.ac): Likewise.
2849         * modules/strnlen (configure.ac): Likewise.
2850         * modules/strpbrk (configure.ac): Likewise.
2851         * modules/strsep (configure.ac): Likewise.
2852         * modules/strstr (configure.ac): Likewise.
2853         * modules/strtok_r (configure.ac): Likewise.
2854
2855 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
2856
2857         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
2858
2859 2007-01-30  Jim Meyering  <jim@meyering.net>
2860
2861         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
2862
2863 2007-01-29  Bruno Haible  <bruno@clisp.org>
2864
2865         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
2866         * lib/execute.c: Likewise.
2867         * lib/pipe.c: Likewise.
2868         * lib/printf-args.h: Likewise.
2869         * lib/printf-args.c: Likewise.
2870         * lib/printf-parse.c: Likewise.
2871         * lib/vasnprintf.c: Likewise.
2872
2873 2007-01-29  Eric Blake  <ebb9@byu.net>
2874
2875         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
2876         declaration.
2877
2878 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
2879
2880         * lib/strptime.h (strptime): Use 'restrict' for args where
2881         POSIX requires this.
2882         * lib/strptime.c (strptime): Likewise.
2883         Change license notice from LGPL to GPL, since gnulib-tool will
2884         change this as needed.
2885         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
2886         defined.
2887         Include "strptime.h" first, to check interface.
2888         Do not #undef _LIBC and _NL_CURRENT.
2889         Do not include <stdlib.h>; no longer needed.
2890         Include "time_r.h" and declare ptime_locale_status
2891         only if _LIBC is not defined.
2892         (__P): Remove unused macro.
2893         (match_string): Bring back glibc version, but use it only if _LIBC
2894         is defined.
2895         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
2896         Remove unnecessary assertion and abort() call.
2897         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
2898         * m4/strptime.m4: Fix serial number comment.
2899         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
2900         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
2901         (Depends-on): Add time_r.
2902
2903 2007-01-29  Bruno Haible  <bruno@clisp.org>
2904
2905         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
2906         strptime.
2907         * modules/strptime (Depends-on): Add stdbool.
2908         * lib/strptime.h: Include <time.h> always. Add comments.
2909
2910 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
2911
2912         * modules/strptime: New file.
2913         * lib/strptime.h: New file.
2914         * lib/strptime.c: New file.
2915         * m4/strptime.m4: New file.
2916
2917 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
2918
2919         * MODULES.html.sh: New module mpsort.
2920         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
2921
2922         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
2923         a circularity problem with HP-UX ia64 reported by Bob Proulx in
2924         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
2925         All uses changed.
2926         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
2927         All uses changed.
2928         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
2929         to _Restrict_.
2930         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
2931         the parameter matches the prototype.
2932
2933 2007-01-28  Jim Meyering  <jim@meyering.net>
2934
2935         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
2936         sys/time.h here, reverting that part of the previous patch:
2937         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
2938
2939 2007-01-28  Bruno Haible  <bruno@clisp.org>
2940
2941         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
2942         value of $(SYS_TIME_H).
2943         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
2944         remove it conditionally, too. [added by Jim Meyering]
2945         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
2946         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
2947         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
2948         GETTIMEOFDAY_REPLACEMENT to 1.
2949
2950 2007-01-28  Bruno Haible  <bruno@clisp.org>
2951
2952         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
2953         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
2954         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
2955         Set UNISTD_H instead of UNISTD_H2.
2956         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
2957
2958 2007-01-28  Bruno Haible  <bruno@clisp.org>
2959
2960         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
2961         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
2962
2963 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2964
2965         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
2966         (func_create_testdir): Ensure C locale for `grep' and `tr'
2967         character ranges.
2968         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
2969         ACLOCAL_AMFLAGS parsing state machine.
2970
2971 2007-01-27  Bruno Haible  <bruno@clisp.org>
2972
2973         * modules/unistr/base: Update.
2974
2975 2007-01-27  Bruno Haible  <bruno@clisp.org>
2976
2977         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
2978         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
2979         * modules/unistr/u32-mbtouc-unsafe: Renamed from
2980         modules/unistr/u32-mbtouc.
2981         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
2982         * lib/unistr.h: Update.
2983         * lib/linebreak.c: Update.
2984         * modules/unistr/u32-mbtouc: Renamed from
2985         modules/unistr/u32-mbtouc-safe.
2986         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
2987         * lib/unistr.h: Update.
2988         * lib/unistr/u32-to-u8.c: Update.
2989         * lib/unistr/u32-to-u16.c: Update.
2990
2991 2007-01-27  Bruno Haible  <bruno@clisp.org>
2992
2993         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
2994         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
2995         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
2996         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
2997         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
2998         * modules/unistr/u16-mbtouc-unsafe: Renamed from
2999         modules/unistr/u16-mbtouc.
3000         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
3001         * lib/unistr.h: Update.
3002         * lib/linebreak.c: Update.
3003         * modules/linebreak: Update.
3004         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
3005         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
3006         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
3007         * modules/unistr/u16-mbtouc: Renamed from
3008         modules/unistr/u16-mbtouc-safe.
3009         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
3010         * lib/unistr.h: Update.
3011         * lib/unistr/u16-to-u8.c: Update.
3012         * modules/unistr/u16-to-u8: Update.
3013         * lib/unistr/u16-to-u32.c: Update.
3014         * modules/unistr/u16-to-u32: Update.
3015
3016 2007-01-27  Bruno Haible  <bruno@clisp.org>
3017
3018         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
3019         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
3020         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
3021         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
3022         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
3023         * modules/unistr/u8-mbtouc-unsafe: Renamed from
3024         modules/unistr/u8-mbtouc.
3025         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
3026         * lib/unistr.h: Update.
3027         * lib/striconveh.c: Update.
3028         * modules/striconveh: Update.
3029         * lib/linebreak.c: Update.
3030         * modules/linebreak: Update.
3031         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
3032         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
3033         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
3034         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
3035         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
3036         * lib/unistr.h: Update.
3037         * lib/striconveh.c: Update.
3038         * modules/striconveh: Update.
3039         * lib/unistr/u8-to-u16.c: Update.
3040         * modules/unistr/u8-to-u16: Update.
3041         * lib/unistr/u8-to-u32.c: Update.
3042         * modules/unistr/u8-to-u32: Update.
3043
3044 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3045
3046         Sync from Libtool.
3047         * lib/argz.c: Do not include strings.h nor memory.h, include
3048         string.h unconditionally.  Patch by Simon Josefsson.
3049
3050 2007-01-27  Bruno Haible  <bruno@clisp.org>
3051
3052         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
3053         from gl_HEADER_STRING_H_BODY.
3054         (gl_HEADER_STRING_H_BODY): Require it.
3055         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
3056         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
3057         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
3058         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
3059         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
3060         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
3061         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
3062         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
3063         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
3064         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
3065         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
3066         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
3067         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
3068         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
3069         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
3070
3071 2007-01-27  Bruno Haible  <bruno@clisp.org>
3072
3073         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
3074         check_PROGRAMS into noinst_PROGRAMS.
3075         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
3076         check_PROGRAMS in this case.
3077         (func_import): Set for_test to false.
3078         (func_create_testdir): Set for_test to true.
3079
3080 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
3081             Bruno Haible  <bruno@clisp.org>
3082
3083         * modules/strcasestr (Files): Remove lib/strcasestr.h.
3084         (Depends-on): Add string.
3085         (Includes): Use <string.h> instead of strcasestr.h.
3086         * modules/string (Makefile.am): Also substitute the value of
3087         REPLACE_STRCASESTR.
3088         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
3089         assume strcasestr is declared in <string.h> not <strings.h>. Also
3090         set REPLACE_STRCASESTR.
3091         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
3092         REPLACE_STRCASESTR.
3093         * lib/strcasestr.h: Remove file.
3094         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
3095         * lib/string_.h (strcasestr): New declaration.
3096
3097 2007-01-27  Bruno Haible  <bruno@clisp.org>
3098
3099         * lib/string_.h: Use 'extern'.
3100
3101 2007-01-27  Jim Meyering  <jim@meyering.net>
3102
3103         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
3104         of set-but-not-used local, "q".
3105
3106         * lib/mempcpy.c: Include <config.h> before <string.h>.
3107         This fixes a compilation error on HP-UX, due to the system's
3108         "restrict"-using mempcpy prototype.
3109
3110 2007-01-26  Bruno Haible  <bruno@clisp.org>
3111
3112         Small optimization.
3113         * lib/javacomp.c: Include c-strstr.h.
3114          (is_envjavac_gcj): Use c_strstr instead of strstr.
3115         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
3116
3117 2007-01-26  Bruno Haible  <bruno@clisp.org>
3118
3119         * MODULES.html.sh (Unicode string functions): Add the new modules.
3120
3121         * modules/uniconv/u32-strconv-to-locale: New file.
3122         * lib/uniconv/u32-strconv-to-locale.c: New file.
3123
3124         * modules/uniconv/u16-strconv-to-locale: New file.
3125         * lib/uniconv/u16-strconv-to-locale.c: New file.
3126
3127         * modules/uniconv/u8-strconv-to-locale: New file.
3128         * lib/uniconv/u8-strconv-to-locale.c: New file.
3129
3130         * modules/uniconv/u32-strconv-from-locale: New file.
3131         * lib/uniconv/u32-strconv-from-locale.c: New file.
3132
3133         * modules/uniconv/u16-strconv-from-locale: New file.
3134         * lib/uniconv/u16-strconv-from-locale.c: New file.
3135
3136         * modules/uniconv/u8-strconv-from-locale: New file.
3137         * lib/uniconv/u8-strconv-from-locale.c: New file.
3138
3139         * modules/uniconv/u32-strconv-to-enc: New file.
3140         * lib/uniconv/u32-strconv-to-enc.c: New file.
3141         * modules/uniconv/u32-strconv-to-enc-tests: New file.
3142         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
3143
3144         * modules/uniconv/u16-strconv-to-enc: New file.
3145         * lib/uniconv/u16-strconv-to-enc.c: New file.
3146         * lib/uniconv/u-strconv-to-enc.h: New file.
3147         * modules/uniconv/u16-strconv-to-enc-tests: New file.
3148         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
3149
3150         * modules/uniconv/u8-strconv-to-enc: New file.
3151         * lib/uniconv/u8-strconv-to-enc.c: New file.
3152         * modules/uniconv/u8-strconv-to-enc-tests: New file.
3153         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
3154
3155         * modules/uniconv/u32-strconv-from-enc: New file.
3156         * lib/uniconv/u32-strconv-from-enc.c: New file.
3157         * modules/uniconv/u32-strconv-from-enc-tests: New file.
3158         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
3159
3160         * modules/uniconv/u16-strconv-from-enc: New file.
3161         * lib/uniconv/u16-strconv-from-enc.c: New file.
3162         * modules/uniconv/u16-strconv-from-enc-tests: New file.
3163         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
3164
3165         * modules/uniconv/u8-strconv-from-enc: New file.
3166         * lib/uniconv/u8-strconv-from-enc.c: New file.
3167         * lib/uniconv/u-strconv-from-enc.h: New file.
3168         * modules/uniconv/u8-strconv-from-enc-tests: New file.
3169         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
3170
3171         * modules/uniconv/u32-conv-from-enc: New file.
3172         * lib/uniconv/u32-conv-from-enc.c: New file.
3173         * modules/uniconv/u32-conv-from-enc-tests: New file.
3174         * tests/uniconv/test-u32-conv-from-enc.c: New file.
3175
3176         * modules/uniconv/u16-conv-from-enc: New file.
3177         * lib/uniconv/u16-conv-from-enc.c: New file.
3178         * lib/uniconv/u-conv-from-enc.h: New file.
3179         * modules/uniconv/u16-conv-from-enc-tests: New file.
3180         * tests/uniconv/test-u16-conv-from-enc.c: New file.
3181
3182         * modules/uniconv/u8-conv-from-enc: New file.
3183         * lib/uniconv/u8-conv-from-enc.c: New file.
3184         * modules/uniconv/u8-conv-from-enc-tests: New file.
3185         * tests/uniconv/test-u8-conv-from-enc.c: New file.
3186
3187         * modules/uniconv/base: New file.
3188         * lib/uniconv.h: New file.
3189
3190 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
3191
3192         * doc/gnulib-tool.texi (Initial import): Update to match current
3193         behavior with strdup module.
3194         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
3195         * lib/memmem.h: Remove; all uses removed.  This is now done
3196         by <string.h>.
3197         * lib/mempcpy.h: Likewise.
3198         * lib/memrchr.h: Likewise.
3199         * lib/stpcpy.h: Likewise.
3200         * lib/stpncpy.h: Likewise.
3201         * lib/strcase.h: Likewise.
3202         * lib/strchrnul.h: Likewise.
3203         * lib/strdup.h: Likewise.
3204         * lib/strndup.h: Likewise.
3205         * lib/strnlen.h: Likewise.
3206         * lib/strpbrk.h: Likewise.
3207         * lib/strsep.h: Likewise.
3208         * lib/strstr.h: Likewise.
3209         * lib/strtok_r.h: Likewise.
3210         * lib/string_.h: New file.
3211         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
3212         Rely on <string.h> instead.
3213         * lib/canon-host.c: Likewise.
3214         * lib/chdir-long.c: Likewise.
3215         * lib/concatpath.c: Likewise.
3216         * lib/exclude.c: Likewise.
3217         * lib/fchdir.c: Likewise.
3218         * lib/getaddrinfo.c: Likewise.
3219         * lib/getcwd.c: Likewise.
3220         * lib/getsubopt.c: Likewise.
3221         * lib/glob.c: Likewise.
3222         * lib/hard-locale.c: Likewise.
3223         * lib/iconvme.c: Likewise.
3224         * lib/javacomp.c: Likewise.
3225         * lib/mempcpy.c: Likewise.
3226         * lib/memrchr.c: Likewise.
3227         * lib/regex_internal.h: Likewise.
3228         * lib/stpncpy.c: Likewise.
3229         * lib/strcasecmp.c: Likewise.
3230         * lib/strchrnul.c: Likewise.
3231         * lib/strdup.c: Likewise.
3232         * lib/striconv.c: Likewise.
3233         * lib/striconveh.c: Likewise.
3234         * lib/striconveha.c: Likewise.
3235         * lib/strncasecmp.c: Likewise.
3236         * lib/strndup.c: Likewise.
3237         * lib/strnlen.c: Likewise.
3238         * lib/strsep.c: Likewise.
3239         * lib/strstr.c: Likewise.
3240         * lib/strtok_r.c: Likewise.
3241         * lib/userspec.c: Likewise.
3242         * lib/w32spawn.h: Likewise.
3243         * lib/xstrndup.c: Likewise.
3244         * lib/mountlist.c (strstr): Remove decl.
3245         * m4/string_h.m4: New file.
3246         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
3247         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
3248         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
3249         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
3250         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
3251         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
3252         Set REPLACE_STRCASECMP if necessary.
3253         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
3254         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
3255         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
3256         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
3257         HAVE_DECL_STRDUP if necessary.
3258         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
3259         since gl_FUNC_STRNDUP does that now.
3260         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
3261         Check for decl here...
3262         (gl_PREREQ_STRNLEN): ... not here.
3263         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
3264         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
3265         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
3266         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
3267         necessary.
3268         * modules/string: New file.
3269         * modules/memmem (Files): Remove special-purpose include file.
3270         (Depends-on): Add string.
3271         (Include): Include <string.h>, not the removed file.
3272         * modules/mempcpy: Likewise.
3273         * modules/memrchr: Likewise.
3274         * modules/stpcpy: Likewise.
3275         * modules/stpncpy: Likewise.
3276         * modules/strcase: Likewise.
3277         * modules/strchrnul: Likewise.
3278         * modules/strdup: Likewise.
3279         * modules/strndup: Likewise.
3280         * modules/strnlen: Likewise.
3281         * modules/strpbrk: Likewise.
3282         * modules/strsep: Likewise.
3283         * modules/strstr: Likewise.
3284         * modules/strtok_r: Likewise.
3285         * tests/test-dirname.c: Don't include "strdup.h", since
3286         <string.h> now suffices.
3287         * tests/test-memmem.c: Don't include "memmem.h", since
3288         <string.h> now suffices.
3289
3290 2007-01-25  Bruno Haible  <bruno@clisp.org>
3291
3292         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
3293         *resultp is 0.
3294
3295         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
3296         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
3297         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
3298         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
3299
3300         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
3301         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
3302         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
3303         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
3304         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
3305         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
3306
3307 2007-01-24  Bruno Haible  <bruno@clisp.org>
3308
3309         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
3310         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
3311         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
3312         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
3313         gl_FUNC_FTS_CORE.
3314         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
3315         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
3316         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
3317         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
3318         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
3319         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
3320         gl_FUNC_FCHOWNAT.
3321         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
3322         gl_FUNC_STRFTIME.
3323         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
3324         Reported by Ralf Wildenhues.
3325
3326 2007-01-24  Bruno Haible  <bruno@clisp.org>
3327
3328         Drop AC_REQUIRE calls that are redundant with the module dependencies.
3329         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
3330         gl_GETADDRINFO.
3331         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
3332         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
3333         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
3334
3335 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
3336
3337         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
3338         Don't use 'exit'; just return from 'main'.
3339         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
3340
3341         * lib/fnmatch_.h: Readjust white space and comments to match
3342         glibc, to avoid spurious diffs.
3343
3344 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
3345
3346         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
3347         2004-12-01 change by Jakub Jelinek, since this code won't compile
3348         if !LIBC.  Problem reported by Bob Proulx.
3349
3350 2007-01-23  Bruno Haible  <bruno@clisp.org>
3351
3352         * lib/striconveh.c: Include c-strcaseeq.h.
3353         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
3354         * modules/striconveh (Depends-on): Add c-strcaseeq.
3355
3356 2007-01-23  Bruno Haible  <bruno@clisp.org>
3357
3358         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
3359
3360         * modules/c-strcaseeq: New file.
3361         * lib/c-strcaseeq.h: New file.
3362
3363         * modules/streq: New file.
3364         * lib/streq.h: New file.
3365
3366 2007-01-23  Bruno Haible  <bruno@clisp.org>
3367
3368         * modules/striconveha-tests: New file.
3369         * tests/test-striconveha.c: New file.
3370
3371         * lib/striconveha.h: Include <stdbool.h>.
3372         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
3373         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
3374         (mem_iconveha_notranslit): Renamed from mem_iconveha.
3375         (mem_iconveha): New function.
3376         (str_iconveha_notranslit): Renamed from str_iconveha.
3377         (str_iconveha): New function.
3378         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
3379         c-strcase.
3380
3381 2007-01-23  Bruno Haible  <bruno@clisp.org>
3382
3383         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
3384         encodings without forgiving before trying any encoding with handler.
3385         (str_iconveha): Try all encodings without forgiving before trying any
3386         encoding with handler.
3387
3388 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
3389
3390         Import the following changes from libc.
3391
3392         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
3393
3394         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
3395
3396         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
3397
3398         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
3399         normal_bracket label.
3400
3401         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
3402
3403         [BZ #361]
3404         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
3405         to normal_bracket after fetching the next character.
3406
3407 2007-01-22  Bruno Haible  <bruno@clisp.org>
3408
3409         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
3410         argument.
3411         * lib/striconveh.c (iconv_carefully_1): New function.
3412         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
3413         argument.
3414         (str_cd_iconveh): Update.
3415         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
3416         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
3417         * tests/test-striconveh.c (MAGIC): New macro.
3418         (new_offsets): New function.
3419         (main): Test call with and without offsets.
3420
3421 2007-01-22  Bruno Haible  <bruno@clisp.org>
3422
3423         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
3424         * modules/sys_select (Makefile.am): Likewise.
3425         * modules/sys_socket (Makefile.am): Likewise.
3426         * modules/sys_time (Makefile.am): Likewise.
3427
3428 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
3429
3430         * modules/gettimeofday (License): Change from GPL to LGPL, since
3431         gettimeofday is a library function.
3432
3433 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
3434
3435         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
3436
3437 2007-01-21  Bruno Haible  <bruno@clisp.org>
3438
3439         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
3440
3441 2007-01-21  Bruno Haible  <bruno@clisp.org>
3442
3443         * modules/striconveha: New file.
3444         * lib/striconveha.h: New file.
3445         * lib/striconveha.c: New file.
3446         * MODULES.html.sh (Internationalization functions): Add striconveha.
3447         * lib/striconv.c (str_iconv): Optimize the case of an empty input
3448         string.
3449         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
3450
3451 2007-01-21  Bruno Haible  <bruno@clisp.org>
3452
3453         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
3454         * lib/striconveh.c (str_iconveh): Likewise.
3455
3456 2007-01-21  Bruno Haible  <bruno@clisp.org>
3457
3458         * lib/striconveh.h (mem_iconveh): New declaration.
3459         * lib/striconveh.c (mem_iconveh): New function.
3460         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
3461
3462 2007-01-21  Bruno Haible  <bruno@clisp.org>
3463
3464         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
3465
3466         * lib/striconveh.h (mem_cd_iconveh): Change specification.
3467         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
3468         original result buffer.
3469         (str_cd_iconveh): Update.
3470         * tests/test-striconveh.c (main): Update.
3471
3472         * lib/striconv.h (mem_cd_iconv): Change specification.
3473         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
3474         result buffer.
3475         (str_cd_iconv): Update.
3476         * tests/test-striconv.c (main): Update.
3477
3478 2007-01-21  Bruno Haible  <bruno@clisp.org>
3479
3480         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
3481
3482 2007-01-20  Jim Meyering  <jim@meyering.net>
3483
3484         * lib/userspec.c (parse_with_separator): If a user or group string
3485         starts with "+", skip the corresponding name-to-ID look-up, since
3486         such a look-up must fail: user and group names may not include "+".
3487
3488 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
3489
3490         * lib/poll.c: Include sys/time.h and time.h unconditionally,
3491         since we now assume the sys_time module.
3492         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
3493         check for sys/time.h; no longer needed.
3494         * modules/poll (Depends-on): Depend on sys_time.
3495
3496 2007-01-18  Bruno Haible  <bruno@clisp.org>
3497
3498         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
3499         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
3500
3501         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
3502         gettimeofday.
3503
3504         * tests/test-gettimeofday.c: Include <time.h>.
3505         (dummy): Remove variable.
3506
3507         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
3508         gl_HEADER_SYS_TIME_H.
3509         (gl_HEADER_SYS_TIME_H): New macro.
3510
3511         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
3512         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3513         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
3514         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
3515         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3516         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
3517         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
3518         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3519         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
3520         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
3521         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3522
3523         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
3524         last change; it caused a compilation error when cross-compiling to
3525         Cygwin.
3526
3527 2007-01-18  Jim Meyering  <jim@meyering.net>
3528
3529         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
3530         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
3531         than the race-prone "test -d sys || mkdir sys".
3532         (configure.ac): Use AC_PROG_MKDIR_P.
3533         * modules/sys_select: Likewise.
3534         * modules/sys_socket: Likewise.
3535         * modules/sys_time: Likewise.
3536
3537 2007-01-18  Eric Blake  <ebb9@byu.net>
3538
3539         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
3540         replace gettimeofday.
3541         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
3542         name, to avoid infinite recursion.
3543
3544 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
3545
3546         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
3547         module sys_time.
3548         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
3549         assume timespec.h defines struct timeval.
3550         * lib/settime.c: Likewise.
3551         * lib/utimens.c: Likewise.
3552         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
3553         since we now assume the gettimeofday module.
3554         * lib/tempname.c (__gen_tempname): Likewise.
3555         * lib/gettimeofday.h: Remove.
3556         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
3557         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
3558         Include <time.h>, for 'time()'.
3559         (localtime_buffer_addr): Also use this workaround if
3560         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
3561         to simplify the uses.  All uses changed.
3562         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
3563         that #undef is inside {}, and 'const' follows type name consistently.
3564         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
3565         (gettimeofday): Do not use the maximum possible value for
3566         tv->tv_usec, since that might break usages other than ls.c.
3567         Instead, we'll leave ls.c alone.  This undoes today's patch
3568         by Bruno.  Add a compile-time warning for 1s-clock resolution;
3569         we've never observed the problem but might as well keep the
3570         canary.
3571         * lib/nanosleep.c: Include timespec.h first, for interface check.
3572         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
3573         now assume the sys_time module.
3574         * lib/tempname.c: Likewise.
3575         * lib/timespec.h: Likewise.
3576         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
3577         needed.
3578         * lib/strftime.c: Likewise.
3579         * lib/timespec.h: Likewise.
3580         * lib/posixtm.c: Include posixtm.h first, for interface check.
3581         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
3582         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
3583         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
3584         * lib/sys_time_.h: New file.
3585         * lib/timespec.h (struct timespec): Use long int, not long.
3586         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
3587         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
3588         Remove obsolescent call to AC_HEADER_TIME.
3589         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
3590         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
3591         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
3592         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
3593         Likewise.
3594         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
3595         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
3596         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
3597         into the sys_time module.  Check for gettimeofday just once.
3598         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
3599         for gettimeofday signature to just check the signature.  Merely
3600         compile it, since linking doesn't test signature.  Improve test for
3601         whether gettimeofday.o is actually needed.
3602         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
3603         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
3604         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
3605         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3606         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
3607         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
3608         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
3609         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
3610         than worrying about sys/time.h.
3611         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
3612         Don't bother worrying about TIME_WITH_SYS_TIME.
3613         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
3614         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
3615         * m4/sys_time_h.m4: New file.
3616         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
3617         Don't include sys/time.h.  Return from main rather than exiting.
3618         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
3619         all uses changed.
3620         * modules/gethrxtime (Depends-on): Add sys_time.
3621         * modules/gettime (Depends-on): Likewise.
3622         * modules/gettimeofday (Depends-on): Likewise.
3623         * modules/nanosleep (Depends-on): Likewise.
3624         * modules/settime (Depends-on): Likewise.
3625         * modules/tempname (Depends-on): Likewise.
3626         * modules/utimens (Depends-on): Likewise.
3627         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
3628         (Include:) Change back to <sys/time.h>.
3629         (Maintainer:) Add self.
3630         * modules/sys_time: New file.
3631         * modules/tempname (Depends-on): Add gettimeofday.
3632         * tests/test-gettimeofday.c: Include <sys/time.h>
3633         rather than gettimeofday.h.
3634
3635 2007-01-17  Bruno Haible  <bruno@clisp.org>
3636
3637         * gnulib-tool (func_get_license): Revert last patch. Instead, let
3638         the license default to GPL.
3639         (func_create_testdir): Don't complain if a module is LGPL and its
3640         tests module depends on GPLed modules.
3641
3642 2007-01-17  Bruno Haible  <bruno@clisp.org>
3643
3644         * lib/gettimeofday.c (gettimeofday): Add code for the case
3645         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
3646         maximum possible value for tv->tv_usec, rather than the minimum one.
3647
3648 2005-10-08  Martin Lambers  <marlam@marlam.de>
3649 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
3650 2007-01-16  Bruno Haible  <bruno@clisp.org>
3651
3652         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
3653         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
3654         gl_FUNC_GETTIMEOFDAY.
3655         (Include): Add gettimeofday.h.
3656         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
3657         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
3658         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
3659         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
3660         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
3661         * lib/gettimeofday.h: New file.
3662         * lib/gettimeofday.c: Include <sys/timeb.h>.
3663         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
3664         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
3665         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
3666         fall back on time().
3667
3668         * tests/test-gettimeofday.c: New file.
3669         * modules/gettimeofday-tests: New file.
3670
3671 2007-01-16  Eric Blake  <ebb9@byu.net>
3672
3673         * modules/fnmatch (Depends-on): Depend on wchar.
3674         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
3675         * m4/fnmatch.m4: Likewise.
3676         * modules/mbchar (Makefile.am): Assume <wchar.h>.
3677         * m4/mbchar.m4: Likewise.
3678         * modules/mbswidth (Depends-on): Depend on wchar.
3679         * lib/mbswidth.c: Assume <wchar.h>.
3680         * m4/mbswidth.m4: Likewise.
3681         * modules/quotearg (Depends-on): Depend on wchar.
3682         * lib/quotearg.c: Assume <wchar.h>.
3683         * m4/quotearg.m4: Likewise.
3684         * modules/regex (Depends-on): Depend on wchar.
3685         * lib/regex_internal.h: Assume <wchar.h>.
3686         * m4/regex.m4: Likewise.
3687         * modules/stdint (Depends-on): Depend on wchar.
3688         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
3689         * m4/stdint.m4: Likewise.
3690         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
3691         * modules/strftime (Depends-on): Depend on wchar.
3692         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
3693         * modules/strtol (Depends-on): Depend on wchar.
3694         * lib/strtol.c: Assume <wchar.h>.
3695         * modules/wcwidth (Depends-on): Depend on wchar.
3696         * lib/wcwidth.h: Assume <wchar.h>.
3697         * m4/wcwidth.m4: Likewise.
3698
3699 2007-01-16  Bruno Haible  <bruno@clisp.org>
3700
3701         * modules/csharpexec-script: New, created from...
3702         * modules/csharpexec: ... this.
3703
3704 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
3705
3706         * modules/javaexec-script: New, created from...
3707         * modules/javaexec: ... this.
3708
3709 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
3710
3711         * modules/poll (Dependencies): Add sys_select.
3712
3713 2007-01-15  Jim Meyering  <jim@meyering.net>
3714
3715         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
3716         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
3717         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
3718         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
3719
3720 2007-01-15  Bruno Haible  <bruno@clisp.org>
3721
3722         * modules/striconveh: New file.
3723         * lib/striconveh.h: New file.
3724         * lib/striconveh.c: New file.
3725         * MODULES.html.sh (Internationalization functions): Add striconveh.
3726
3727         * modules/striconveh-tests: New file.
3728         * tests/test-striconveh.c: New file.
3729
3730 2007-01-15  Bruno Haible  <bruno@clisp.org>
3731
3732         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
3733         not from GNU libiconv or GNU libc.
3734
3735 2007-01-15  Bruno Haible  <bruno@clisp.org>
3736
3737         * doc/gnulib-intro.texi (Copyright): Explain the different license
3738         terms for module descriptions, autoconf macros, tests, documentation.
3739
3740 2007-01-14  Bruno Haible  <bruno@clisp.org>
3741
3742         * modules/striconv-tests: New file.
3743         * tests/test-striconv.c: New file.
3744
3745 2007-01-14  Bruno Haible  <bruno@clisp.org>
3746
3747         * modules/iconv-tests: New file.
3748         * tests/test-iconv.c: New file.
3749
3750 2007-01-14  Bruno Haible  <bruno@clisp.org>
3751
3752         * gnulib-tool (func_get_license): For test modules, use the license of
3753         the main module.
3754
3755 2007-01-14  Bruno Haible  <bruno@clisp.org>
3756
3757         * modules/iconv (Include): Clarify that <iconv.h> can only be included
3758         if iconv is found to exist.
3759
3760 2007-01-14  Bruno Haible  <bruno@clisp.org>
3761
3762         * modules/c-ctype-tests: New file.
3763         * tests/test-c-ctype.c: New file.
3764
3765 2007-01-14  Bruno Haible  <bruno@clisp.org>
3766
3767         * modules/binary-io-tests: New file.
3768         * tests/test-binary-io.sh: New file.
3769         * tests/test-binary-io.c: New file.
3770
3771 2007-01-14  Bruno Haible  <bruno@clisp.org>
3772
3773         * modules/array-oset-tests: New file.
3774         * tests/test-array_oset.c: New file.
3775
3776 2007-01-14  Bruno Haible  <bruno@clisp.org>
3777
3778         * modules/array-list-tests: New file.
3779         * tests/test-array_list.c: New file.
3780
3781 2007-01-14  Bruno Haible  <bruno@clisp.org>
3782
3783         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
3784         and make.
3785         Reported by Simon Josefsson in
3786         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
3787
3788 2007-01-14  Bruno Haible  <bruno@clisp.org>
3789
3790         * modules/allocsa-tests: New file.
3791         * tests/test-allocsa.c: New file.
3792
3793 2007-01-14  Bruno Haible  <bruno@clisp.org>
3794
3795         * modules/fchdir (Depends-on): Add absolute-header.
3796         * modules/unistd (Depends-on): Likewise.
3797
3798 2006-12-30  Bruno Haible  <bruno@clisp.org>
3799
3800         * modules/fchdir: New file.
3801         * modules/unistd (Files): Add lib/unistd_.h.
3802         (Makefile.am): Generate unistd.h from unistd_.h.
3803         * lib/fchdir.c: New file.
3804         * lib/dirent_.h: New file.
3805         * lib/unistd_.h: New file.
3806         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
3807         * m4/fchdir.m4: New file.
3808         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
3809         (gl_HEADER_UNISTD): Invoke it.
3810         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
3811         function.
3812         * lib/backupfile.c (opendir, closedir): Undefine.
3813         * lib/chown.c (open, close): Undefine.
3814         * lib/clean-temp.c (open, close): Undefine.
3815         * lib/copy-file.c (open, close): Undefine.
3816         * lib/execute.c (open, close): Undefine.
3817         * lib/fsusage.c (open, close): Undefine.
3818         * lib/gc-gnulib.c (open, close): Undefine.
3819         * lib/getcwd.c (opendir, closedir): Undefine.
3820         * lib/glob.c (opendir, closedir): Undefine.
3821         * lib/javacomp.c (open, close): Undefine.
3822         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
3823         * lib/openat-proc.c (open, close): Undefine.
3824         * lib/pagealign_alloc.c (open, close): Undefine.
3825         * lib/pipe.c (open, close): Undefine.
3826         * lib/progreloc.c (open, close): Undefine.
3827         * lib/savedir.c (opendir, closedir): Undefine.
3828         * lib/utime.c (open, close): Undefine.
3829         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
3830
3831 2007-01-10  Bruno Haible  <bruno@clisp.org>
3832
3833         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
3834
3835 2007-01-12  Eric Blake  <ebb9@byu.net>
3836
3837         Provide a robust <wchar.h>.  Further simplifications are now
3838         possible in other modules, but not included here.
3839         * modules/wchar: New module.
3840         * m4/wchar.m4: New file.
3841         * lib/wchar_.h: Likewise.
3842         * modules/mbchar (Depends-on): Depend on wchar, as the first use
3843         of the new module.
3844         * MODULES.html.sh (Extended multibyte and wide character utilities):
3845         New section.
3846
3847 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
3848
3849         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
3850         to a reasonable default for memory allocation.
3851         (xreadlink): Don't allocate a huge buffer, to work around a buggy
3852         file system that reports garbage st_size values for symlinks.
3853         Problem reported by Liyang Hu.
3854
3855 2007-01-11  Simon Josefsson  <simon@josefsson.org>
3856
3857         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
3858         Emacs .#* auto-save files).
3859
3860 2007-01-11  Bruno Haible  <bruno@clisp.org>
3861
3862         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
3863         directory.
3864
3865 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
3866
3867         Use @...@ consistently in lib/wctype_.h.
3868         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
3869         on it being set to 1 or 0.
3870         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
3871         go back to AC_SUBSTing it.
3872         * modules/wctype (Makefile.am): Undo previous change.
3873
3874 2007-01-10  Eric Blake  <ebb9@byu.net>
3875
3876         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
3877         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
3878         * modules/wctype (Makefile.am): Likewise.
3879         Reported by Chris McGuire.
3880
3881 2007-01-10  Jim Meyering  <jim@meyering.net>
3882
3883         fts.c: a small readability/maintainability improvement
3884         * lib/fts.c (fts_read): Make this code slightly more readable and
3885         maintainable by hoisting the "sp->fts_cur = p" assignments to
3886         immediately follow the statements that set P.  Derived from
3887         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
3888
3889 2007-01-10  Eric Blake  <ebb9@byu.net>
3890
3891         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
3892         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
3893         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
3894         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
3895         Reported by Chris McGuire.
3896
3897 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3898
3899         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
3900         in sed script.
3901
3902 2007-01-09  Bruno Haible  <bruno@clisp.org>
3903
3904         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
3905         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
3906         variables.
3907         (func_module): Use them.
3908
3909 2007-01-09  Bruno Haible  <bruno@clisp.org>
3910
3911         * modules/unistr/base: New file.
3912         * lib/unistr.h: New file.
3913
3914         * modules/unistr/u8-to-u16: New file.
3915         * lib/unistr/u8-to-u16.c: New file.
3916
3917         * modules/unistr/u8-to-u32: New file.
3918         * lib/unistr/u8-to-u32.c: New file.
3919
3920         * modules/unistr/u16-to-u8: New file.
3921         * lib/unistr/u16-to-u8.c: New file.
3922
3923         * modules/unistr/u16-to-u32: New file.
3924         * lib/unistr/u16-to-u32.c: New file.
3925
3926         * modules/unistr/u32-to-u8: New file.
3927         * lib/unistr/u32-to-u8.c: New file.
3928
3929         * modules/unistr/u32-to-u16: New file.
3930         * lib/unistr/u32-to-u16.c: New file.
3931
3932         * modules/unistr/u8-check: New file.
3933         * modules/unistr/u16-check: New file.
3934         * modules/unistr/u32-check: New file.
3935         * lib/unistr/u8-check.c: New file.
3936         * lib/unistr/u16-check.c: New file.
3937         * lib/unistr/u32-check.c: New file.
3938
3939         * modules/unistr/u8-chr: New file.
3940         * modules/unistr/u16-chr: New file.
3941         * modules/unistr/u32-chr: New file.
3942         * lib/unistr/u8-chr.c: New file.
3943         * lib/unistr/u16-chr.c: New file.
3944         * lib/unistr/u32-chr.c: New file.
3945
3946         * modules/unistr/u8-cmp: New file.
3947         * modules/unistr/u16-cmp: New file.
3948         * modules/unistr/u32-cmp: New file.
3949         * lib/unistr/u8-cmp.c: New file.
3950         * lib/unistr/u16-cmp.c: New file.
3951         * lib/unistr/u32-cmp.c: New file.
3952
3953         * modules/unistr/u8-cpy: New file.
3954         * modules/unistr/u16-cpy: New file.
3955         * modules/unistr/u32-cpy: New file.
3956         * lib/unistr/u8-cpy.c: New file.
3957         * lib/unistr/u16-cpy.c: New file.
3958         * lib/unistr/u32-cpy.c: New file.
3959         * lib/unistr/u-cpy.h: New file.
3960
3961         * modules/unistr/u8-cpy-alloc: New file.
3962         * modules/unistr/u16-cpy-alloc: New file.
3963         * modules/unistr/u32-cpy-alloc: New file.
3964         * lib/unistr/u8-cpy-alloc.c: New file.
3965         * lib/unistr/u16-cpy-alloc.c: New file.
3966         * lib/unistr/u32-cpy-alloc.c: New file.
3967         * lib/unistr/u-cpy-alloc.h: New file.
3968
3969         * modules/unistr/u8-endswith: New file.
3970         * modules/unistr/u16-endswith: New file.
3971         * modules/unistr/u32-endswith: New file.
3972         * lib/unistr/u8-endswith.c: New file.
3973         * lib/unistr/u16-endswith.c: New file.
3974         * lib/unistr/u32-endswith.c: New file.
3975         * lib/unistr/u-endswith.h: New file.
3976
3977         * modules/unistr/u8-mblen: New file.
3978         * modules/unistr/u16-mblen: New file.
3979         * modules/unistr/u32-mblen: New file.
3980         * lib/unistr/u8-mblen.c: New file.
3981         * lib/unistr/u16-mblen.c: New file.
3982         * lib/unistr/u32-mblen.c: New file.
3983
3984         * modules/unistr/u8-mbtouc: New file.
3985         * modules/unistr/u16-mbtouc: New file.
3986         * modules/unistr/u32-mbtouc: New file.
3987         * lib/unistr/u8-mbtouc.c: New file.
3988         * lib/unistr/u16-mbtouc.c: New file.
3989         * lib/unistr/u32-mbtouc.c: New file.
3990
3991         * modules/unistr/u8-mbtouc-safe: New file.
3992         * modules/unistr/u16-mbtouc-safe: New file.
3993         * modules/unistr/u32-mbtouc-safe: New file.
3994         * lib/unistr/u8-mbtouc-safe.c: New file.
3995         * lib/unistr/u16-mbtouc-safe.c: New file.
3996         * lib/unistr/u32-mbtouc-safe.c: New file.
3997
3998         * modules/unistr/u8-move: New file.
3999         * modules/unistr/u16-move: New file.
4000         * modules/unistr/u32-move: New file.
4001         * lib/unistr/u8-move.c: New file.
4002         * lib/unistr/u16-move.c: New file.
4003         * lib/unistr/u32-move.c: New file.
4004         * lib/unistr/u-move.h: New file.
4005
4006         * modules/unistr/u8-next: New file.
4007         * modules/unistr/u16-next: New file.
4008         * modules/unistr/u32-next: New file.
4009         * lib/unistr/u8-next.c: New file.
4010         * lib/unistr/u16-next.c: New file.
4011         * lib/unistr/u32-next.c: New file.
4012
4013         * modules/unistr/u8-prev: New file.
4014         * modules/unistr/u16-prev: New file.
4015         * modules/unistr/u32-prev: New file.
4016         * lib/unistr/u8-prev.c: New file.
4017         * lib/unistr/u16-prev.c: New file.
4018         * lib/unistr/u32-prev.c: New file.
4019
4020         * modules/unistr/u8-set: New file.
4021         * modules/unistr/u16-set: New file.
4022         * modules/unistr/u32-set: New file.
4023         * lib/unistr/u8-set.c: New file.
4024         * lib/unistr/u16-set.c: New file.
4025         * lib/unistr/u32-set.c: New file.
4026         * lib/unistr/u-set.h: New file.
4027
4028         * modules/unistr/u8-startswith: New file.
4029         * modules/unistr/u16-startswith: New file.
4030         * modules/unistr/u32-startswith: New file.
4031         * lib/unistr/u8-startswith.c: New file.
4032         * lib/unistr/u16-startswith.c: New file.
4033         * lib/unistr/u32-startswith.c: New file.
4034         * lib/unistr/u-startswith.h: New file.
4035
4036         * modules/unistr/u8-stpcpy: New file.
4037         * modules/unistr/u16-stpcpy: New file.
4038         * modules/unistr/u32-stpcpy: New file.
4039         * lib/unistr/u8-stpcpy.c: New file.
4040         * lib/unistr/u16-stpcpy.c: New file.
4041         * lib/unistr/u32-stpcpy.c: New file.
4042         * lib/unistr/u-stpcpy.h: New file.
4043
4044         * modules/unistr/u8-stpncpy: New file.
4045         * modules/unistr/u16-stpncpy: New file.
4046         * modules/unistr/u32-stpncpy: New file.
4047         * lib/unistr/u8-stpncpy.c: New file.
4048         * lib/unistr/u16-stpncpy.c: New file.
4049         * lib/unistr/u32-stpncpy.c: New file.
4050         * lib/unistr/u-stpncpy.h: New file.
4051
4052         * modules/unistr/u8-strcat: New file.
4053         * modules/unistr/u16-strcat: New file.
4054         * modules/unistr/u32-strcat: New file.
4055         * lib/unistr/u8-strcat.c: New file.
4056         * lib/unistr/u16-strcat.c: New file.
4057         * lib/unistr/u32-strcat.c: New file.
4058         * lib/unistr/u-strcat.h: New file.
4059
4060         * modules/unistr/u8-strchr: New file.
4061         * modules/unistr/u16-strchr: New file.
4062         * modules/unistr/u32-strchr: New file.
4063         * lib/unistr/u8-strchr.c: New file.
4064         * lib/unistr/u16-strchr.c: New file.
4065         * lib/unistr/u32-strchr.c: New file.
4066
4067         * modules/unistr/u8-strcmp: New file.
4068         * modules/unistr/u16-strcmp: New file.
4069         * modules/unistr/u32-strcmp: New file.
4070         * lib/unistr/u8-strcmp.c: New file.
4071         * lib/unistr/u16-strcmp.c: New file.
4072         * lib/unistr/u32-strcmp.c: New file.
4073
4074         * modules/unistr/u8-strcpy: New file.
4075         * modules/unistr/u16-strcpy: New file.
4076         * modules/unistr/u32-strcpy: New file.
4077         * lib/unistr/u8-strcpy.c: New file.
4078         * lib/unistr/u16-strcpy.c: New file.
4079         * lib/unistr/u32-strcpy.c: New file.
4080         * lib/unistr/u-strcpy.h: New file.
4081
4082         * modules/unistr/u8-strcspn: New file.
4083         * modules/unistr/u16-strcspn: New file.
4084         * modules/unistr/u32-strcspn: New file.
4085         * lib/unistr/u8-strcspn.c: New file.
4086         * lib/unistr/u16-strcspn.c: New file.
4087         * lib/unistr/u32-strcspn.c: New file.
4088         * lib/unistr/u-strcspn.h: New file.
4089
4090         * modules/unistr/u8-strdup: New file.
4091         * modules/unistr/u16-strdup: New file.
4092         * modules/unistr/u32-strdup: New file.
4093         * lib/unistr/u8-strdup.c: New file.
4094         * lib/unistr/u16-strdup.c: New file.
4095         * lib/unistr/u32-strdup.c: New file.
4096         * lib/unistr/u-strdup.h: New file.
4097
4098         * modules/unistr/u8-strlen: New file.
4099         * modules/unistr/u16-strlen: New file.
4100         * modules/unistr/u32-strlen: New file.
4101         * lib/unistr/u8-strlen.c: New file.
4102         * lib/unistr/u16-strlen.c: New file.
4103         * lib/unistr/u32-strlen.c: New file.
4104         * lib/unistr/u-strlen.h: New file.
4105
4106         * modules/unistr/u8-strmblen: New file.
4107         * modules/unistr/u16-strmblen: New file.
4108         * modules/unistr/u32-strmblen: New file.
4109         * lib/unistr/u8-strmblen.c: New file.
4110         * lib/unistr/u16-strmblen.c: New file.
4111         * lib/unistr/u32-strmblen.c: New file.
4112
4113         * modules/unistr/u8-strmbtouc: New file.
4114         * modules/unistr/u16-strmbtouc: New file.
4115         * modules/unistr/u32-strmbtouc: New file.
4116         * lib/unistr/u8-strmbtouc.c: New file.
4117         * lib/unistr/u16-strmbtouc.c: New file.
4118         * lib/unistr/u32-strmbtouc.c: New file.
4119
4120         * modules/unistr/u8-strncat: New file.
4121         * modules/unistr/u16-strncat: New file.
4122         * modules/unistr/u32-strncat: New file.
4123         * lib/unistr/u8-strncat.c: New file.
4124         * lib/unistr/u16-strncat.c: New file.
4125         * lib/unistr/u32-strncat.c: New file.
4126         * lib/unistr/u-strncat.h: New file.
4127
4128         * modules/unistr/u8-strncmp: New file.
4129         * modules/unistr/u16-strncmp: New file.
4130         * modules/unistr/u32-strncmp: New file.
4131         * lib/unistr/u8-strncmp.c: New file.
4132         * lib/unistr/u16-strncmp.c: New file.
4133         * lib/unistr/u32-strncmp.c: New file.
4134
4135         * modules/unistr/u8-strncpy: New file.
4136         * modules/unistr/u16-strncpy: New file.
4137         * modules/unistr/u32-strncpy: New file.
4138         * lib/unistr/u8-strncpy.c: New file.
4139         * lib/unistr/u16-strncpy.c: New file.
4140         * lib/unistr/u32-strncpy.c: New file.
4141         * lib/unistr/u-strncpy.h: New file.
4142
4143         * modules/unistr/u8-strnlen: New file.
4144         * modules/unistr/u16-strnlen: New file.
4145         * modules/unistr/u32-strnlen: New file.
4146         * lib/unistr/u8-strnlen.c: New file.
4147         * lib/unistr/u16-strnlen.c: New file.
4148         * lib/unistr/u32-strnlen.c: New file.
4149         * lib/unistr/u-strnlen.h: New file.
4150
4151         * modules/unistr/u8-strpbrk: New file.
4152         * modules/unistr/u16-strpbrk: New file.
4153         * modules/unistr/u32-strpbrk: New file.
4154         * lib/unistr/u8-strpbrk.c: New file.
4155         * lib/unistr/u16-strpbrk.c: New file.
4156         * lib/unistr/u32-strpbrk.c: New file.
4157         * lib/unistr/u-strpbrk.h: New file.
4158
4159         * modules/unistr/u8-strrchr: New file.
4160         * modules/unistr/u16-strrchr: New file.
4161         * modules/unistr/u32-strrchr: New file.
4162         * lib/unistr/u8-strrchr.c: New file.
4163         * lib/unistr/u16-strrchr.c: New file.
4164         * lib/unistr/u32-strrchr.c: New file.
4165
4166         * modules/unistr/u8-strspn: New file.
4167         * modules/unistr/u16-strspn: New file.
4168         * modules/unistr/u32-strspn: New file.
4169         * lib/unistr/u8-strspn.c: New file.
4170         * lib/unistr/u16-strspn.c: New file.
4171         * lib/unistr/u32-strspn.c: New file.
4172         * lib/unistr/u-strspn.h: New file.
4173
4174         * modules/unistr/u8-strstr: New file.
4175         * modules/unistr/u16-strstr: New file.
4176         * modules/unistr/u32-strstr: New file.
4177         * lib/unistr/u8-strstr.c: New file.
4178         * lib/unistr/u16-strstr.c: New file.
4179         * lib/unistr/u32-strstr.c: New file.
4180         * lib/unistr/u-strstr.h: New file.
4181
4182         * modules/unistr/u8-strtok: New file.
4183         * modules/unistr/u16-strtok: New file.
4184         * modules/unistr/u32-strtok: New file.
4185         * lib/unistr/u8-strtok.c: New file.
4186         * lib/unistr/u16-strtok.c: New file.
4187         * lib/unistr/u32-strtok.c: New file.
4188         * lib/unistr/u-strtok.h: New file.
4189
4190         * modules/unistr/u8-uctomb: New file.
4191         * modules/unistr/u16-uctomb: New file.
4192         * modules/unistr/u32-uctomb: New file.
4193         * lib/unistr/u8-uctomb.c: New file.
4194         * lib/unistr/u16-uctomb.c: New file.
4195         * lib/unistr/u32-uctomb.c: New file.
4196
4197         * MODULES.html.sh (Unicode string functions): Add the new modules.
4198
4199 2007-01-08  Bruno Haible  <bruno@clisp.org>
4200
4201         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
4202         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
4203         subdirectories.
4204
4205 2007-01-08  Karl Berry  <karl@gnu.org>
4206
4207         * doc/error.texi: mention that main() fns must set program_name
4208         when progname is used.
4209
4210 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
4211
4212         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
4213         WCTYPE_H is empty, for the benefit of builds from non-distclean
4214         directories.  Problem reported by Eric Blake in
4215         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
4216
4217 2007-01-08  Bruno Haible  <bruno@clisp.org>
4218
4219         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
4220         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
4221         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
4222         PROVIDE_CANONICALIZE_FILENAME_MODE.
4223         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
4224
4225 2007-01-08  Bruno Haible  <bruno@clisp.org>
4226
4227         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
4228         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
4229         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
4230         * lib/fts.c: Likewise.
4231         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
4232
4233 2006-12-25  Bruno Haible  <bruno@clisp.org>
4234
4235         * modules/utf8-ucs4-safe: New file.
4236         * lib/utf8-ucs4-safe.h: New file.
4237         * lib/unistr/utf8-ucs4-safe.c: New file.
4238
4239         * modules/utf16-ucs4-safe: New file.
4240         * lib/utf16-ucs4-safe.h: New file.
4241         * lib/unistr/utf16-ucs4-safe.c: New file.
4242
4243         * MODULES.html.sh (Unicode string functions): Add the new modules.
4244
4245 2007-01-08  Bruno Haible  <bruno@clisp.org>
4246
4247         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
4248         (Depends-on): Add unitypes.
4249         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
4250         (u8_mbtouc_aux): Move out to separate file.
4251         (u8_mbtouc): Use ucs4_t, uint8_t types.
4252         * lib/unistr/utf8-ucs4.c: New file.
4253
4254         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
4255         (Depends-on): Add unitypes.
4256         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
4257         (u16_mbtouc_aux): Move out to separate file.
4258         (u16_mbtouc): Use ucs4_t, uint16_t types.
4259         * lib/unistr/utf16-ucs4.c: New file.
4260
4261         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
4262         (Depends-on): Add unitypes.
4263         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
4264         (u8_uctomb_aux): Move out to separate file.
4265         (u8_uctomb): Use ucs4_t, uint8_t types.
4266         * lib/unistr/ucs4-utf8.c: New file.
4267
4268         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
4269         (Depends-on): Add unitypes.
4270         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
4271         (u16_uctomb_aux): Move out to separate file.
4272         (u16_uctomb): Use ucs4_t, uint16_t types.
4273         * lib/unistr/ucs4-utf16.c: New file.
4274
4275 2006-12-25  Bruno Haible  <bruno@clisp.org>
4276
4277         * modules/unitypes: New file.
4278         * lib/unitypes.h: New file.
4279         * MODULES.html.sh (func_all_modules): New section "Unicode string
4280         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
4281         this section. Add unitypes.
4282
4283 2007-01-08  Bruno Haible  <bruno@clisp.org>
4284
4285         Avoid variable names that conflict with those from libtool.
4286         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
4287         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
4288         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
4289         library_names_spec to acl_library_names_spec, hardcode_* to
4290         acl_hardcode_*.
4291         Reported by Ralf Wildenhues.
4292
4293 2007-01-08  Bruno Haible  <bruno@clisp.org>
4294
4295         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
4296         definition.
4297         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
4298         definition.
4299         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
4300         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
4301         definition.
4302         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
4303         definition.
4304         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
4305         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
4306         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
4307         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
4308         definition.
4309         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
4310         definition.
4311         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
4312         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
4313         GC_USE_<algorithm>.
4314         * lib/gc-libgcrypt.c: Likewise.
4315         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
4316         * modules/gc-arctwo (configure.ac): Likewise.
4317         * modules/gc-des (configure.ac): Likewise.
4318         * modules/gc-hmac-md5 (configure.ac): Likewise.
4319         * modules/gc-hmac-sha1 (configure.ac): Likewise.
4320         * modules/gc-md2 (configure.ac): Likewise.
4321         * modules/gc-md4 (configure.ac): Likewise.
4322         * modules/gc-md5 (configure.ac): Likewise.
4323         * modules/gc-random (configure.ac): Likewise.
4324         * modules/gc-rijndael (configure.ac): Likewise.
4325         * modules/gc-sha1 (configure.ac): Likewise.
4326
4327 2007-01-08  Bruno Haible  <bruno@clisp.org>
4328
4329         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
4330         macro definition.
4331         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
4332         definition.
4333         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
4334         definition.
4335         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
4336         * modules/fcntl-safer (configure.ac): Likewise.
4337         * modules/fopen-safer (configure.ac): Likewise.
4338         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
4339         GNULIB_FWRITEERROR macro definition.
4340
4341 2007-01-08  Bruno Haible  <bruno@clisp.org>
4342
4343         * m4/gnulib-common.m4: New file.
4344         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
4345         (func_get_filelist): Add m4/gnulib-common.m4.
4346
4347 2007-01-08  Bruno Haible  <bruno@clisp.org>
4348
4349         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
4350         command.
4351
4352 2007-01-08  Jim Meyering  <jim@meyering.net>
4353
4354         Use a more robust test for a "can't happen" condition.
4355         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
4356         narrowed the st_size value.  Presuming the "can't happen" condition
4357         is true, that narrowing could conceivably convert an invalid st_size
4358         value into a valid one.  Instead, use a change based on Matthew
4359         Woehlke's original patch.
4360
4361         Slight readability improvement: use an assert-like macro
4362         in place of literal "abort ()" uses.
4363         * lib/fts.c (fts_assert): Define.
4364         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
4365         Use this macro instead of a bare 'abort'.
4366
4367 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
4368
4369         Don't worry about using IRIX 5.3's wctype.h broken definitions;
4370         simply work around them.
4371         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
4372         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
4373         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
4374         declaring.
4375         Don't bother to define as macros, since the standard doesn't require it.
4376         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
4377         longer worry about IRIX 5.3.
4378         (HAVE_WCTYPE_CTMP_BUG): Remove.
4379
4380 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
4381
4382         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
4383         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
4384         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
4385         Problems reported by Georg Schwarz for IRIX 5.3.
4386
4387         * gnulib-tool (autoconf_minversion): Take the maximum version number
4388         found, not the minimum.  Problem reported by James Youngman.
4389
4390 2007-01-03  Karl Berry  <karl@gnu.org>
4391
4392         * doc/error.texi: new file, explaining interaction with progname.
4393         * doc/gnulib.texi: include it.  Update copyright.
4394
4395 2007-01-03  Simon Josefsson  <simon@josefsson.org>
4396
4397         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
4398         AC_CANONICAL_HOST, to improve autobuild outputs.
4399
4400 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
4401             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
4402
4403         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
4404         sockets, server sockets, and other file descriptors.  Count errors
4405         to compute the return value.  Reorder the code a bit to be easier
4406         to follow.  Don't set event bits that were not requested (except
4407         POLLERR and POLLHUP).
4408
4409 2007-01-01  Bruno Haible  <bruno@clisp.org>
4410
4411         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
4412
4413 2007-01-03  Jim Meyering  <jim@meyering.net>
4414
4415         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
4416
4417 2007-01-02  Bruno Haible  <bruno@clisp.org>
4418
4419         * modules/settime (Include): Require timespec.h.
4420         * modules/nanosleep (Include): Likewise.
4421
4422 2007-01-01  Bruno Haible  <bruno@clisp.org>
4423
4424         * gnulib-tool (func_emit_copyright_notice): Bump year.
4425         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
4426
4427 2007-01-01  Bruno Haible  <bruno@clisp.org>
4428
4429         Improve support for OpenBSD.
4430         * build-aux/config.rpath (libname_spec): Export.
4431         (library_names_spec): New variable. Export.
4432         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
4433         library_names_spec from the config.rpath output. Locate shared library
4434         through the name pattern in library_names_spec.
4435
4436 2007-01-01  Eric Blake  <ebb9@byu.net>
4437
4438         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
4439
4440 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
4441
4442         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
4443         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
4444         assume the C locale, and avoid an "eval" that could cause trouble.
4445         Problem with SORT reported by Bob Proulx.
4446
4447         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
4448         Define.  Trivial patch from Henning Nielsen Lund, originally
4449         sent to bug-grep@gnu.org today.
4450
4451 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
4452
4453         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
4454         struct stat.  Problem reported by Henning Nielsen Lund.
4455         * lib/acl.c: Include acl.h first, to check interface.  Don't
4456         bother to include sys/types.h and sys/stat.h again.
4457
4458 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
4459
4460         Import the following change from libc; problem reported by
4461         Sven Verdoolaege.
4462
4463         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
4464
4465         [BZ #1373]
4466         * lib/argp.h: Remove __NTH for __argp_usage inline function.
4467
4468 2006-12-28  Jim Meyering  <jim@meyering.net>
4469
4470         * build-aux/announce-gen: Do not assume that the package
4471         builds any of tar.gz, tar.bz2, and .xdelta files.
4472         Suggestion from Simon Josefsson.
4473
4474 2006-12-28  Simon Josefsson  <simon@josefsson.org>
4475
4476         * modules/announce-gen: New file.
4477
4478 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
4479
4480         * lib/mbchar.h: Just include <wctype.h>; the wctype module
4481         handles its gotchas now.
4482         * lib/mbswidth.c: Likewise.
4483         * lib/wcwidth.h: Likewise.
4484         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
4485         and iswcntrl; the wctype module does this stuff now.
4486         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
4487         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
4488         * modules/mbchar (Depends-on): Add wctype.
4489         * modules/mbswidth (Depends-on): Likewise.
4490         * modules/wcwidth (Depends-on): Likewise.
4491
4492 2006-12-27  Eric Blake  <ebb9@byu.net>
4493
4494         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
4495         module uses more than what <wctype.h> is required to provide.
4496
4497 2006-12-26  Eric Blake  <ebb9@byu.net>
4498
4499         * gnulib-tool (sed_extract_prog): Avoid space-tab.
4500
4501 2006-12-26  Eric Blake  <ebb9@byu.net>
4502
4503         * modules/absolute-header: New module.
4504         * modules/fcntl (Depends-on): Depend on it.
4505         * modules/inttypes (Depends-on): Likewise.
4506         * modules/stdint (Depends-on): Likewise.
4507         * modules/sys_stat (Depends-on): Likewise.
4508         * modules/wctype (Depends-on): Likewise.
4509         * MODULES.html.sh (Support for building libraries and
4510         executables): Document it.
4511
4512 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
4513
4514         * gnulib-tool (SED): Remove, undoing previous change.
4515         The problem was that it broke coreutils on Solaris, because
4516         "sed --posix" leaked into a makefile.
4517         (sed): New alias, if 'alias' and GNU sed.
4518
4519 2006-12-24  Jim Meyering  <jim@meyering.net>
4520
4521         Work around an fchownat bug in glibc-2.4:
4522         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
4523         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
4524         in spite of the -P option.
4525         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
4526         New macros.
4527         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
4528         * modules/openat (Files): Add lib/fchownat.c.
4529         * lib/openat.c (fchownat): Don't define here.  Move to...
4530         * lib/fchownat.c: ...this new file.
4531
4532 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
4533
4534         Fix bug reported by Bruno Haible in
4535         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
4536         where quotearg.c didn't compile on Mac OS X 10.2 because it
4537         lacks <wchar.h> and wint_t.
4538         * lib/wctype_.h (__wctype_wint_t): New type.
4539         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
4540         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
4541         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
4542         Arg is now of type __wctype_wint_t, not wint_t.
4543         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
4544         substitute HAVE_WINT_T.
4545         * modules/wctype (Files): Add m4/wint_t.m4.
4546         (wctype.h): Substitute HAVE_WINT_T.
4547
4548 2006-12-23  Bruno Haible  <bruno@clisp.org>
4549
4550         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
4551
4552 2006-12-23  Bruno Haible  <bruno@clisp.org>
4553
4554         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
4555         S_ISLNK.
4556         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
4557         mingw.
4558
4559 2006-12-22  Bruno Haible  <bruno@clisp.org>
4560
4561         * lib/copy-file.c: Include acl.h.
4562         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
4563         Close the file descriptors only after being done with copy_acl.
4564         * modules/copy-file (Depends-on): Add acl.
4565
4566 2006-12-22  Bruno Haible  <bruno@clisp.org>
4567
4568         * gnulib-tool (SED): New variable.
4569         Use $SED instead of sed everywhere.
4570
4571 2006-12-22  Bruno Haible  <bruno@clisp.org>
4572
4573         * modules/no-c++: New file.
4574         * m4/no-c++.m4: New file.
4575         * MODULES.html.sh (Support for building libraries and executables):
4576         Add no-c++.
4577
4578 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
4579
4580         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
4581         Include <limits.h>, and use its INT_MAX to rewrite the
4582         j loop so that it does not overflow 'int'.  Problem reported by
4583         Ralf Wildenhues in
4584         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
4585         Play it safe by shifting left by 1 rather than multiplying by 2,
4586         as GCC is less likely to optimize this away when the value
4587         is signed (when it assumes overflow leads to undefined behavior).
4588         Also, don't assume time_t uses two's complement.
4589
4590 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
4591
4592         * MODULES.html.sh: New module wctype.
4593         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
4594         * lib/fnmatch.c: Don't bother to include <wchar.h> before
4595         <wctype.h>, since the new wctype module should fix this.
4596         * lib/quotearg.c: Include <wctype.h> unconditionally, since
4597         the wctype module should arrange for it.
4598         * lib/regex_internal.h: Likewise.
4599         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
4600         since the wctype module should handle this now.
4601         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
4602         * modules/fnmatch (Depends-on): Add wctype.
4603         * modules/quotearg (Depends-on): Likewise.
4604         * modules/regex (Depends-on): Likewise.
4605
4606 2006-12-19  Bruno Haible  <bruno@clisp.org>
4607
4608         * lib/strdup.h [C++]: Wrap definitions in extern "C".
4609         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
4610
4611 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4612
4613         * modules/savewd (Depends-on): Fix dependency on fcntl.
4614
4615 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
4616
4617         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
4618         conforms to C99, rather than relying on the user's environment
4619         setting of STDINT_H.
4620
4621 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
4622         and Eric Blake  <ebb9@byu.net>
4623
4624         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
4625         This is more consistent with the other defines here.
4626         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
4627         Port to z/OS.  Problem reported by Paul Gilmartin.
4628         Change local vars to use gl_ prefix rather than ac_.
4629         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
4630         with other defines.
4631         * modules/double-slash-root: New module.
4632         * modules/dirname (Files): Remove m4/double-slash-root.m4.
4633         (Depends-on): Add double-slash-root.
4634         * MODULES.html.sh (File system functions): Mention new module.
4635
4636 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
4637
4638         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
4639         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
4640         This is for the benefit of gzip, which doesn't do i18n.
4641
4642 2006-12-12  Jim Meyering  <jim@meyering.net>
4643
4644         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
4645         Reported by Andreas Schwab <schwab@suse.de>.
4646
4647 2006-12-12  Bruno Haible  <bruno@clisp.org>
4648
4649         Merge these changes.
4650         2006-09-05  Bruno Haible  <bruno@clisp.org>
4651         * lib/iconvme.c (iconv_string): No need to save and restore errno when
4652         iconv_alloc succeeded.
4653         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
4654         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
4655         test for " && dest " at the end - dest is always != NULL there. Call
4656         iconv with 4xNULL arguments initially, to reset the state. Call iconv
4657         with 2xNULL arguments, also to flush the state storage. Handle the
4658         IRIX iconv behaviour. Realloc the final result, to throw away unused
4659         memory.
4660
4661 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
4662
4663         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
4664         and fchmodat unconditionally, since glibc 2.4 has them.
4665         Problem reported by Arkadiusz Miskiewicz.
4666
4667 2006-12-10  Bruno Haible  <bruno@clisp.org>
4668
4669         * gnulib-tool (func_import): Show the include files only for those
4670         modules that are copied and specified.
4671         Reported by Karl Berry.
4672
4673 2006-12-08  Jim Meyering  <jim@meyering.net>
4674
4675         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
4676         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
4677
4678         * build-aux/announce-gen: Add two new options, both optional:
4679         --bootstrap-tools=TOOL_LIST
4680               a comma-separated list of tools, e.g.,
4681               autoconf,automake,bison,gnulib
4682         --gnulib-snapshot-date=DATE
4683               if gnulib is in the bootstrap tool list,
4684               then report this as the snapshot date.
4685               If not specified, use the current date/time.
4686               If you specify a date here, be sure it's UTC.
4687
4688 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4689
4690         * tests/test-argp-2.sh: Fix test to match actual output.
4691         (func_compare): Fix sed script to be portable.
4692
4693 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
4694
4695         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
4696         workaround for this case.  It is not autoconfigured now; offhand
4697         it's hard to see how to autoconfigure it.
4698
4699 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
4700
4701         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
4702         a directory that is about to be chowned.  Such a directory's
4703         initial file permissions should permit the owner only and this
4704         should not be changed until after the chown, since the group and
4705         other bits would be incorrect if they granted permission before
4706         the chown.
4707
4708         Fix porting problem for iswctype reported by Georg Schwarz in:
4709         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
4710         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
4711         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
4712         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
4713         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
4714
4715 2006-12-03  Jim Meyering  <jim@meyering.net>
4716
4717         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
4718         p->fts_statp may not yet be defined.
4719         (fts_read): Instead, set it in the caller, once p->fts_statp is
4720         sure to be defined, and corresponds to a top-level directory.
4721         This bug made du -x fail.  Here's the coreutils test case:
4722         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
4723         Reported by Mike Frysinger.
4724
4725 2006-12-01  Jim Meyering  <jim@meyering.net>
4726
4727         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
4728         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
4729         Reported by Simon Josefsson.
4730
4731 2006-11-30  Jim Meyering  <jim@meyering.net>
4732
4733         * m4/warning.m4: Use the all-permissive copyright notice
4734         recommended by RMS (rather than LGPL).
4735         * m4/vararrays.m4: Likewise.
4736         * m4/flexmember.m4: Likewise.
4737
4738 2006-11-29  Bruno Haible  <bruno@clisp.org>
4739
4740         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4741         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
4742         using +=.
4743         Reported by Simon Josefsson <simon@josefsson.org>.
4744
4745 2006-11-28  James Youngman <jay@gnu.org>
4746
4747         * README: Advise users that they might find the bug-gnulib@gnu.org
4748         and autotools-announce@gnu.org mailing lists useful.
4749
4750 2006-11-28  Bruno Haible  <bruno@clisp.org>
4751
4752         * m4/ptrdiff_max.m4: Remove file.
4753
4754 2006-11-21  Bruno Haible  <bruno@clisp.org>
4755
4756         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
4757         _AC_COMPUTE_INT.
4758         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4759         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
4760         _AC_COMPUTE_INT.
4761         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4762         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
4763         _AC_COMPUTE_INT.
4764         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4765
4766 2006-11-28  Jim Meyering  <jim@meyering.net>
4767
4768         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
4769         warning from "gcc -Wshadow" about shadowing the builtin.
4770
4771 2006-11-27  Bruno Haible  <bruno@clisp.org>
4772
4773         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
4774         _AC_COMPUTE_INT.
4775         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
4776
4777 2006-11-27  Bruno Haible  <bruno@clisp.org>
4778             Paul Eggert  <eggert@cs.ucla.edu>
4779
4780         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
4781
4782 2006-11-26  Bruno Haible  <bruno@clisp.org>
4783
4784         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
4785         noinst_LTLIBRARIES.
4786
4787 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
4788             Bruno Haible  <bruno@clisp.org>
4789
4790         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
4791         if compiling with "gcc -ansi".
4792
4793 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
4794
4795         Fix some incompatibilities with gcc -ansi -pedantic.
4796         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
4797         if compiling pedantically with GCC, unless it's C99 or later.
4798         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
4799         it mishandles gcc -ansi -pedantic as well.
4800         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
4801         if gcc -pedantic.
4802         * lib/regexec.c (check_node_accept_bytes): Don't use auto
4803         initializers for struct if -pedantic, unless it's C99 or later.
4804
4805 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
4806
4807         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
4808         Don't close an fd more than once. Identical atimes indicate
4809         success, not failure.
4810
4811 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
4812
4813         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
4814
4815 2006-11-23  Jim Meyering  <jim@meyering.net>
4816
4817         * build-aux/announce-gen: New file.  From coreutils.
4818
4819 2006-11-22  Jim Meyering  <jim@meyering.net>
4820
4821         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
4822         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
4823         (fts_read): Use a temporary to narrow the overused st_size member
4824         before using it in a switch statement.  Reported by Matthew Woehlke.
4825
4826         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
4827         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
4828
4829 2006-11-20  Bruno Haible  <bruno@clisp.org>
4830
4831         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
4832         changequote instead of pairs of brackets.
4833         Reported by Andreas Schwab <schwab@suse.de>.
4834
4835 2006-11-21  Jim Meyering  <jim@meyering.net>
4836
4837         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
4838         so as to remain compatible with older compilers.
4839         Patch from Michael Deutschmann.
4840
4841 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
4842
4843         * MODULES.html.sh (File system functions): Add openat.
4844
4845         * lib/openat.h (rpl_fstatat): New macro, if
4846         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
4847         (fstatat): Define to rpl_fstatat under the same conditions,
4848         unless COMPILING_FSTATAT.
4849         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
4850         seems to have the bug.
4851         * lib/fstatat.c: New file.
4852         * modules/openat (Files): Add it.
4853
4854 2006-11-20  Bruno Haible  <bruno@clisp.org>
4855
4856         * Makefile: New file.
4857
4858 2006-11-20  Jim Meyering  <jim@meyering.net>
4859
4860         The beginnings of syntax-related checks for gnulib.
4861         * lib/Makefile: New file.
4862         * lib/t-idcache: New script.  Ensure that the two halves of
4863         idcache.c stay in sync.
4864
4865         * lib/idcache.c: Adjust comments in user- and group- portions to
4866         be more accurate, and to be consistent with one another.
4867
4868 2006-11-20  Jim Meyering  <jim@meyering.net>
4869
4870         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
4871         continue using the flexible array member (thus, this module performs
4872         half as many malloc calls), with the addition that...
4873         (getgroup, getuser): Consistently record a non-match via an empty
4874         "name" string, and map an empty string match to a NULL return value.
4875         * modules/idcache (Depends-on): Re-add flexmember.
4876
4877         * lib/idcache.c (getuser): Remove all uses of the register keyword.
4878         (getuidbyname, getgroup, getgidbyname): Likewise.
4879
4880         Use cleaner syntax: NULL rather than 0.
4881         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
4882
4883 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
4884
4885         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
4886         It mishandled the case where the group was missing.
4887         Problem reported by Greg Schafer.
4888         * modules/idcache: Likewise.
4889
4890 2006-11-18  Jim Meyering  <jim@meyering.net>
4891
4892         * check-module (%exempt_header): Add exception for some
4893         conditionally-included headers.
4894
4895         * modules/i-ring (Depends-on): Add verify.
4896         (License): Change to LGPL.
4897
4898 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
4899
4900         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
4901         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
4902         and inttostr.h.  Use snprintf rather than uinttostr, so that
4903         LGPLed code doesn't depend on GPLed.
4904
4905 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
4906
4907         * modules/inline (License): Change from GPL to LGPL.
4908
4909 2006-11-17  Jim Meyering  <jim@meyering.net>
4910
4911         * modules/d-type (License): Switch to LGPL.
4912
4913 2006-11-15  Bruno Haible  <bruno@clisp.org>
4914
4915         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
4916
4917 2006-11-15  Eric Blake  <ebb9@byu.net>
4918
4919         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
4920         the module dependency.
4921
4922 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4923             Bruno Haible  <bruno@clisp.org>
4924
4925         * gnulib-tool (func_create_testdir): Add license consistency check.
4926
4927 2006-11-15  Eric Blake  <ebb9@byu.net>
4928
4929         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
4930         random "(cached)" in configure output.
4931
4932 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4933
4934         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
4935         test for conforming inttypes.h is both announced and cached.
4936
4937         * MODULES.html.sh (seen_modules, seen_files): New variables.
4938         (func_module): Rewrite to use a few less gnulib-tool and sed
4939         invocations.  Avoid a couple of quadratic algorithms for ...
4940         (missed_modules, missed_files): ... these, with ...
4941         (func_append, func_tmpdir): ... these new functions, from
4942         gnulib-tool.  Analogously, install traps for cleanup.
4943
4944         * tests/test-gc.c (main): Remove unused variables.
4945         * tests/test-read-file.c: Include stdlib.h, for 'free'.
4946
4947 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
4948
4949         * modules/inttostr (License): Change to LGPL.
4950
4951 2006-11-14  Eric Blake  <ebb9@byu.net>
4952
4953         * modules/tempname (License): Change to LGPL.
4954
4955 2006-11-14  Eric Blake  <ebb9@byu.net>
4956
4957         * doc/functions.texi (Function Portability): *printf functions on
4958         Cygwin now understand all POSIX size specifiers.
4959
4960 2006-11-14  Bruno Haible  <bruno@clisp.org>
4961
4962         * modules/c-ctype (License): Change to LGPL.
4963
4964 2006-11-12  Bruno Haible  <bruno@clisp.org>
4965
4966         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
4967         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
4968         for GNOME libraries, for which the include files are installed in
4969         subdirectories of $prefix/include.
4970
4971 2006-11-12  Bruno Haible  <bruno@clisp.org>
4972
4973         * m4/lib-link.m4: Require at least autoconf-2.54.
4974         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
4975         name to underscores for the --with option.
4976
4977 2006-11-13  Bruno Haible  <bruno@clisp.org>
4978
4979         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
4980         the tests directory.
4981         Reported by Ralf Wildenhues.
4982
4983 2006-11-13  Bruno Haible  <bruno@clisp.org>
4984
4985         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
4986         (func_emit_initmacro_end): Undo the override here.
4987         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
4988         Works around the famous automake error in coreutils.
4989
4990 2006-11-13  Eric Blake  <ebb9@byu.net>
4991
4992         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
4993         element, not its node.
4994
4995 2006-11-12  Bruno Haible  <bruno@clisp.org>
4996
4997         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
4998         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
4999
5000 2006-11-12  Bruno Haible  <bruno@clisp.org>
5001
5002         * gnulib-tool: New option --local-symlink.
5003         (func_usage): Document it.
5004         (lsymbolic): New variable.
5005         (func_import, func_create_testdir): If --symlink was not specified,
5006         test whether --local-symlink was specified and the file comes from
5007         the local_gnulib_dir.
5008
5009 2006-11-12  Bruno Haible  <bruno@clisp.org>
5010
5011         * gnulib-tool (func_ln): New function.
5012         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
5013
5014 2006-11-12  Bruno Haible  <bruno@clisp.org>
5015
5016         Finish support for source files in subdirectories.
5017         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
5018         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
5019         AUTOMAKE_OPTIONS.
5020         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
5021
5022 2006-11-12  Bruno Haible  <bruno@clisp.org>
5023
5024         * gnulib-tool (func_get_automake_snippet): Synthesize also an
5025         EXTRA_lib_SOURCES augmentation.
5026         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
5027
5028 2006-11-12  Jim Meyering  <jim@meyering.net>
5029
5030         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
5031         file descriptors.  This also averts a failure on systems with
5032         native openat support when a traversed directory lacks "x" access.
5033         * lib/fts_.h: Include "i-ring.h"
5034         (struct FTS) [fts_fd_ring]: New member.
5035         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
5036         (FCHDIR): Add parentheses.
5037         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
5038         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
5039         When descending, rather than simply closing the previous
5040         fts_cwd_fd value, push that file descriptor onto the ring.
5041         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
5042         (fts_open): Initialize the new fd_ring member.
5043         (fts_close): Clear the ring.
5044         (fts_safe_changedir): When possible, use our new fd_ring to skip
5045         the diropen and fstat and dev/ino comparison that would normally
5046         accompany a virtual `chdir ("..")'.
5047
5048         * modules/fts (Depends-on): Add i-ring.
5049         * modules/i-ring: New module.
5050         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
5051         * m4/i-ring.m4: New file.
5052
5053 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5054
5055         * gnulib-tool (func_create_testdir): Fix replacement of
5056         `build-aux' in configure.ac.  Run autotools in gltests
5057         subdirectory.
5058         (func_create_testdir, func_create_megatestdir, test): There is
5059         no need for '--force' in most autotool invocations in a new
5060         tree.  Actually fail the whole test if any of the tools, or the
5061         configure or make stages fail.
5062
5063         Sync from Automake.
5064         * build-aux/gnupload: Revert last change.  Add pointer to upload
5065         instructions of the GNU Maintenance Instructions.
5066         Suggestion by Karl Berry.
5067
5068 2006-11-10  Jim Meyering  <jim@meyering.net>
5069
5070         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
5071
5072 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5073
5074         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
5075         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
5076         (bind_textdomain_codeset) [! ENABLE_NLS]:
5077         Evaluate all the arguments.  That way, callers get compatible behavior
5078         if the arguments have side effects.  Also, it avoids some GCC
5079         diagnostics in some cases; Joel E. Denny reported problems when Bison
5080         was configured with --enable-gcc-warnigs.
5081
5082 2006-11-10  Jim Meyering  <jim@meyering.net>
5083
5084         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
5085         relevant options in CFLAGS (like -O, -fno-inline) are taken into
5086         account.
5087
5088 2006-11-10  Jim Meyering  <jim@meyering.net>
5089
5090         * modules/inline: New file/module.
5091         * modules/xalloc (Files): Remove m4/inline.m4.
5092         (Depends-on): Add inline, instead.
5093         * modules/oset: Likewise.
5094         * modules/list: Likewise.
5095
5096 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5097
5098         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
5099         Problem reported by Matthew Woehlke.
5100
5101 2006-11-09  Bruno Haible  <bruno@clisp.org>
5102
5103         * lib/tempname.c (gen_tempname): Remove variant that invokes
5104         __gen_tempname.
5105         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
5106         __gen_tempname.
5107
5108 2006-11-08  Bruno Haible  <bruno@clisp.org>
5109
5110         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
5111         to 'yes' instead of 'cross-compiling'.
5112
5113 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
5114
5115         * lib/quotearg.h (quotearg_free): New decl.
5116         * lib/quotearg.c (quotearg_free): New function.
5117         (slot0, nslots, slotvec0, slotvec):
5118         Now file-scope so that quotearg_free can get at them.
5119
5120 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5121
5122         Sync from Automake.
5123         * build-aux/gnupload: Add missing 'gnu' to example URL.
5124         Report by Karl Berry.
5125
5126 2006-11-08  Bruno Haible  <bruno@clisp.org>
5127
5128         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
5129         Suggested by Paul Eggert.
5130
5131 2006-11-08  Jim Meyering  <jim@meyering.net>
5132
5133         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
5134         It's already included if !_LIBC.
5135         (fts_safe_changedir): Add a comment.
5136
5137 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5138
5139         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
5140         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
5141         Matthew Woehlke.
5142
5143         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
5144         definitions up, to avoid colliding with change below.
5145         (static_inline) [HAVE_INLINE]: New macro.
5146         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
5147         Provide extern decls when !HAVE_INLINE.  Do not define unless
5148         static_inline is defined, either by us or by xmalloc.c.  Use
5149         static_inline rather than static inline.
5150         (XCALLOC): Optimize sizeof(T) = 1 case.
5151         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
5152
5153 2006-11-07  Bruno Haible  <bruno@clisp.org>
5154
5155         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
5156         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
5157         AC_C_INLINE.
5158         * modules/xalloc (Files): Add m4/inline.m4.
5159
5160 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5161
5162         * README: Fix typo.
5163         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
5164         (Miscellanous Notes): ...from this.
5165
5166 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5167
5168         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
5169         Mention that offsetof should be used instead of sizeof.
5170         From Bruno Haible.
5171
5172 2006-11-07  Bruno Haible  <bruno@clisp.org>
5173
5174         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
5175
5176 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
5177
5178         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
5179         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
5180         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
5181         (gl_tree_add_before, gl_tree_add_after):
5182         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
5183         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
5184         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
5185         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
5186         (gl_linked_add_after, gl_linked_add_at): Likewise.
5187         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
5188         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
5189         (gl_tree_add_before, gl_tree_add_after): Likewise.
5190         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
5191         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
5192         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
5193
5194 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5195
5196         * lib/gl_oset.h: Use C comment style, not C++ comment style.
5197
5198 2006-11-06  Bruno Haible  <bruno@clisp.org>
5199
5200         * m4/inline.m4: New file.
5201         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
5202         * modules/list (Files): Add m4/inline.m4.
5203         * modules/oset (Files): Likewise.
5204
5205 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
5206
5207         * lib/idcache.c: Include <stddef.h>, for offsetof.
5208         (struct userid.name): Change from char * to a flexible array member.
5209         All uses changed.
5210         * modules/idcache (Depends-on): Add flexmember.
5211
5212         * MODULES.html.sh (Core language properties): New module flexmember.
5213         * modules/flexmember, m4/flexmember.m4: New files.
5214
5215         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
5216         inline functions that are identical with the old xnmalloc_inline,
5217         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
5218         that we can avoid some unnecessary integer multiplications and
5219         divisions in the common case where the element size is known at
5220         compile time.
5221         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
5222         needed.
5223         (xnboundedmalloc): Remove.
5224         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
5225         arguments, for consistency with rest of this header.
5226         (xcharalloc): Rewrite using XNMALLOC.
5227         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
5228         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
5229         versions have been moved to lib/xalloc.h and renamed to be the
5230         non-*_inline versions.
5231         (xmalloc, xrealloc): Implement without reference to the xnmalloc
5232         and xnrealloc functions, since those functions are now inline and
5233         now call us.
5234         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
5235         renaming described above.
5236         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
5237         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
5238         captures the dependency in AC_C_INLINE.
5239
5240         New module canonicalize-lgpl, proposed by Charles Wilson in
5241         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
5242         with a few small changes afterwards.
5243         * MODULES.html.sh (File system functions): New module
5244         canonicalize-lgpl.
5245         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
5246         and canonicalize_file_name.
5247         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
5248         * modules/canonicalize-lgpl: New files.
5249
5250 2006-11-05  Bruno Haible  <bruno@clisp.org>
5251
5252         * gnulib-tool (func_import, func_create_testdir): Create directories
5253         also for files in subdirectories of lib/.
5254
5255 2006-11-05  Bruno Haible  <bruno@clisp.org>
5256
5257         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
5258         ANSI C compliant.
5259
5260 2006-11-03  Bruno Haible  <bruno@clisp.org>
5261
5262         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
5263         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
5264         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
5265         (xnboundedmalloc): New inline function.
5266         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
5267         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
5268         xmalloc.
5269         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
5270         xmalloc.
5271         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
5272         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
5273         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
5274         xmalloc.
5275         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
5276         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
5277         xmalloc.
5278         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
5279         gl_tree_add_after): Use XMALLOC instead of xmalloc.
5280         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
5281         xmalloc.
5282         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
5283         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
5284         gl_tree_add_after): Use XMALLOC instead of xmalloc.
5285         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
5286         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
5287         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
5288         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
5289
5290 2006-11-03  Bruno Haible  <bruno@clisp.org>
5291
5292         * lib/c-ctype.h [C++]: Define functions without name mangling.
5293         * lib/fwriteerror.h [C++]: Likewise.
5294         * lib/gcd.h [C++]: Likewise.
5295         * lib/linebreak.h [C++]: Likewise.
5296
5297 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
5298
5299         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
5300         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
5301         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
5302         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
5303         Check for functions and headers just once.
5304         Check for declaration of canonicalize_file_name.
5305         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
5306
5307 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5308
5309         * gnulib-tool (func_import): Fix typo in actioncmd.
5310
5311 2006-11-02  Bruno Haible  <bruno@clisp.org>
5312
5313         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
5314         newline sequence in the Makefile.am snippet as a space, like "make"
5315         does.
5316         Reported by Roger Persson <perrog@gmail.com>.
5317
5318 2006-11-01  Bruno Haible  <bruno@clisp.org>
5319
5320         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
5321         already declared in <string.h>.
5322         * lib/strcase.h (strncasecmp): Don't declare it if yes.
5323
5324 2006-11-01  Bruno Haible  <bruno@clisp.org>
5325
5326         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
5327         * lib/strcase.h: Include <string.h>.
5328         (strcasecmp): Define to rpl_strcasecmp here.
5329
5330 2006-11-01  Bruno Haible  <bruno@clisp.org>
5331
5332         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
5333
5334 2006-11-01  Eric Blake  <ebb9@byu.net>
5335
5336         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
5337
5338         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
5339
5340 2006-10-29  Bruno Haible  <bruno@clisp.org>
5341
5342         Make it compile in C++ mode.
5343         * lib/full-write.c (full_rw): Add a cast.
5344
5345 2006-11-01  Bruno Haible  <bruno@clisp.org>
5346
5347         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
5348         be POSIX compliant.
5349         Reported by Roger Persson <perrog@gmail.com>.
5350
5351 2006-11-01  Eric Blake  <ebb9@byu.net>
5352
5353         * lib/getopt_.h: Fix comments.
5354
5355 2006-10-31  Eric Blake  <ebb9@byu.net>
5356
5357         * modules/tmpdir (Depends-on): Add sys_stat.
5358         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
5359         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
5360         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
5361         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
5362         tempname.
5363
5364 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
5365
5366         Avoid some C++ diagnostics reported by Bruno Haible.
5367         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
5368         xmalloc.
5369         (quotearg_alloc): Use xcharalloc rather than xmalloc.
5370         (struct slotvec): Move to top level.
5371         (quotearg_n_options): Rewrite to avoid xmalloc.
5372         * lib/xalloc.h (xcharalloc): New function.
5373         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
5374         [defined __cplusplus]: Add function template that provides result
5375         type propagation.  This part of the change is from Bruno Haible.
5376
5377 2006-10-29  Bruno Haible  <bruno@clisp.org>
5378
5379         Make it compile in C++ mode.
5380         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
5381         * lib/strnlen1.c (strnlen1): Cast memchr result.
5382         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
5383         * lib/clean-temp.c (string_equals, string_hash): Add casts.
5384         (create_temp_dir): Rename local variable 'template'.
5385         (compile_csharp_using_sscli): Add cast.
5386         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
5387         * lib/findprog.c (find_in_path): Likewise.
5388         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
5389         * lib/wait-process.c (register_slave_subprocess): Likewise.
5390
5391 2006-10-22  Bruno Haible  <bruno@clisp.org>
5392
5393         * modules/tsearch: New file.
5394         * lib/tsearch.h: New file.
5395         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
5396         * m4/tsearch.m4: New file.
5397         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
5398
5399 2006-10-29  Eric Blake  <ebb9@byu.net>
5400
5401         * lib/arcfour.c: Assume config.h.
5402         * lib/arctwo.c: Likewise.
5403         * lib/base64.c: Likewise.
5404         * lib/check-version.c: Likewise.
5405         * lib/crc.c: Likewise.
5406         * lib/des.c: Likewise.
5407         * lib/gc-gnulib.c: Likewise.
5408         * lib/gc-libgcrypt.c: Likewise.
5409         * lib/gc-pbkdf2-sha1.c: Likewise.
5410         * lib/getaddrinfo.c: Likewise.
5411         * lib/getdelim.c: Likewise.
5412         * lib/getline.c: Likewise.
5413         * lib/hmac-md5.c: Likewise.
5414         * lib/hmac-sha1.c: Likewise.
5415         * lib/iconvme.c: Likewise.
5416         * lib/md2.c: Likewise.
5417         * lib/md4.c: Likewise.
5418         * lib/memxor.c: Likewise.
5419         * lib/read-file.c: Likewise.
5420         * lib/readline.c: Likewise.
5421         * lib/rijndael-alg-fst.c: Likewise.
5422         * lib/rijndael-api-fst.c: Likewise.
5423         * lib/xgetdomainname.c: Likewise.
5424
5425 2006-10-28  Eric Blake  <ebb9@byu.net>
5426
5427         * lib/xstrndup.c: Assume config.h.
5428
5429 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
5430
5431         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
5432         stat-macros.h is now for our own macros, whereas stat_h is for
5433         macros in the <sys/stat.h> name space.
5434         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
5435         (STAT_MACROS_H): Remove.
5436         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
5437         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
5438         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
5439         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
5440         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
5441         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
5442         Move these macros to ...
5443         * lib/stat_.h: here.  Don't include stat-macros.h.
5444         * lib/canonicalize.c: Don't include stat-macros.h.
5445         * lib/chown.c: Likewise.
5446         * lib/euidaccess.c: Likewise.
5447         * lib/file-type.c: Likewise.
5448         * lib/filemode.c: Likewise.
5449         * lib/glob.c: Likewise.
5450         * lib/isapipe.c: Likewise.
5451         * lib/lchown.c: Likewise.
5452         * lib/lstat.c: Likewise.
5453         * lib/mkdir-p.c: Likewise.
5454         * lib/rmdir.c: Likewise.
5455         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
5456         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
5457         unless mkdir isn't declared, to speed up 'configure'.
5458         Always create sys/stat.h, since it's unlikely any real sys/stat.h
5459         would define all the S_* symbols.
5460         * modules/canonicalize (Depends-on):
5461         Depend on sys_stat, not stat-macros.
5462         * modules/chown: Likewise.
5463         * modules/euidaccess: Likewise.
5464         * modules/filemode: Likewise.
5465         * modules/file-type: Likewise.
5466         * modules/glob: Likewise.
5467         * modules/isapipe: Likewise.
5468         * modules/lchown: Likewise.
5469         * modules/lstat: Likewise.
5470         * modules/mkancesdirs: Likewise.
5471         * modules/rmdir: Likewise.
5472         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
5473         * modules/modechange: Likewise.
5474         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
5475         (configure.ac): Remove gl_STAT_MACROS.
5476         * modules/sys_stat (Depends-on): Remove stat-macros.
5477
5478 2006-10-27  Bruno Haible  <bruno@clisp.org>
5479
5480         * m4/signed.m4: Remove file.
5481         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
5482         invocation.
5483         * modules/vasnprintf (Files): Remove m4/signed.m4.
5484
5485 2006-10-27  Bruno Haible  <bruno@clisp.org>
5486
5487         Update to GNU gettext 0.16.
5488         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
5489         m4/inttypes-h.m4, m4/signed.m4.
5490         * m4/gettext.m4: Update to GNU gettext 0.16.
5491         * m4/intl.m4: New file, from GNU gettext.
5492         * m4/intldir.m4: New file, from GNU gettext.
5493         * config/srclist.txt: Update
5494
5495 2006-10-27  Eric Blake  <ebb9@byu.net>
5496
5497         * MODULES.html.sh: Document tempname.
5498         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
5499         dependencies.
5500         (Files): Move lib/tempname.c...
5501         * modules/tempname: ...to this new module.
5502         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
5503         (gl_PREREQ_TEMPNAME): Move...
5504         * m4/tempname.m4: ...to this new file.
5505         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
5506         * modules/sys_stat (Depends-on): Add stat-macros.
5507         * lib/stat_.h (includes): Pick up stat macros.
5508         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
5509         if stat macros are broken.
5510         * lib/tempname.c (includes): No need to include "stat-macros.h".
5511         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
5512         (direxists, __path_search) [!_LIBC]: Don't compile these in
5513         gnulib; the tmpdir module covers that.
5514         * lib/tempname.h: New file.
5515
5516 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
5517
5518         * COPYING: Explain how gnulib-tool converts licence headers.
5519         Almost all wording by Eric Blake.
5520
5521 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
5522
5523         * lib/mbchar.h (is_basic_table): Make read-only.
5524         * lib/mbchar.c (is_basic_table): Likewise.
5525         Reported by John Darrington.
5526
5527 2006-10-25  Bruno Haible  <bruno@clisp.org>
5528
5529         * lib/progname.h (set_program_name): Undefine before defining.
5530
5531 2006-10-25  Bruno Haible  <bruno@clisp.org>
5532
5533         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
5534         false for non-gcc C++ compilers.
5535         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
5536
5537 2006-10-24  Bruno Haible  <bruno@clisp.org>
5538
5539         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
5540         iconv implementations like Irix iconv.
5541
5542 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5543
5544         * modules/vararrays: New file.
5545         * m4/vararrays.m4: New file, taken from diffutils.
5546         * MODULES.html.sh: New module vararrays.
5547
5548 2006-10-24  Karl Berry  <karl@gnu.org>
5549
5550         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
5551         Don't call GNU Unix.
5552
5553 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5554
5555         * users.txt: Add Libtool.
5556
5557         Sync from Libtool:
5558
5559         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5560
5561         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
5562         to gnulib's policy of including config.h unconditionally.
5563
5564 2006-10-24  Bruno Haible  <bruno@clisp.org>
5565
5566         * modules/wcwidth (Files): Add m4/wint_t.m4.
5567         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
5568         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
5569
5570 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
5571
5572         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
5573         to pacify GCC with some -W flags enabled.  Problem reported by
5574         Bruno Haible.
5575
5576 2006-10-24  Jim Meyering  <jim@meyering.net>
5577
5578         * MODULES.html.sh: Remove uinttostr.  It's not a module.
5579         Reported by Karl Berry.
5580
5581 2006-10-23  Bruno Haible  <bruno@clisp.org>
5582
5583         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
5584
5585 2006-10-24  Bruno Haible  <bruno@clisp.org>
5586
5587         * lib/gl_list.h: Use C comment style, not C++ comment style.
5588
5589 2006-10-23  Eric Blake  <ebb9@byu.net>
5590
5591         * lib/getaddrinfo.c (includes): Add missing include.
5592
5593 2006-10-23  Bruno Haible  <bruno@clisp.org>
5594             Paul Eggert  <eggert@cs.ucla.edu>
5595
5596         Ability to rename obstack_free.
5597         * lib/obstack.h (__obstack_free): New macro. Declare instead of
5598         obstack_free.
5599         (obstack_free): Invoke the __obstack_free macro.
5600         * lib/obstack.c (obstack_free): Use __obstack_free macro.
5601
5602 2006-10-23  Bruno Haible  <bruno@clisp.org>
5603             Paul Eggert  <eggert@cs.ucla.edu>
5604
5605         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
5606         __argc, __argv from the declaration. (They are defined as macros on
5607         mingw.)
5608
5609 2006-10-22  Bruno Haible  <bruno@clisp.org>
5610
5611         * doc/gnulib-intro.texi: New file.
5612         * doc/gnulib.texi: Include it.
5613
5614 2006-10-21  Bruno Haible  <bruno@clisp.org>
5615
5616         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
5617         "Introduction", "Miscellanous Notes", "Particular Modules".
5618
5619 2006-10-21  Bruno Haible  <bruno@clisp.org>
5620
5621         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
5622         Change mostlyclean-local rule to avoid sh syntax error from bash
5623         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
5624
5625 2006-10-23  Jim Meyering  <jim@meyering.net>
5626
5627         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
5628         in place of snprintf.
5629
5630         * modules/inttostr (Files): Add lib/uinttostr.c.
5631         * lib/uinttostr.c (inttostr): New file/function.
5632         * lib/inttostr.h (uinttostr): Declare.
5633         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
5634         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
5635         Add uinttostr.
5636         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
5637
5638 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
5639
5640         * lib/canonicalize.c (ELOOP): Define if not already defined.
5641         Problem reported by Bruno Haible in
5642         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
5643
5644 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
5645
5646         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
5647         Problem reported by Perry Smith and Ville Laurikari.
5648
5649         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
5650         uses.
5651
5652 2006-10-19  Bruno Haible  <bruno@clisp.org>
5653
5654         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
5655         for mingw.
5656
5657 2006-10-19  Bruno Haible  <bruno@clisp.org>
5658
5659         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
5660         Needed for mingw.
5661
5662 2006-10-19  Bruno Haible  <bruno@clisp.org>
5663
5664         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
5665
5666 2006-10-19  Bruno Haible  <bruno@clisp.org>
5667
5668         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
5669         it.
5670
5671 2006-10-19  Bruno Haible  <bruno@clisp.org>
5672
5673         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
5674         invocation.
5675
5676 2006-10-19  Bruno Haible  <bruno@clisp.org>
5677
5678         * gnulib-tool (func_create_testdir): Don't include ftruncate and
5679         mountlist by default.
5680
5681 2006-10-16  Bruno Haible  <bruno@clisp.org>
5682
5683         * lib/c-strstr.c: Include c-strstr.h.
5684
5685 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5686
5687         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
5688         in a slash.
5689
5690 2006-10-18  Bruno Haible  <bruno@clisp.org>
5691
5692         * lib/lock.h [C++]: Wrap definitions in extern "C".
5693
5694 2006-10-18  Bruno Haible  <bruno@clisp.org>
5695
5696         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
5697         gl_LIBOBJS list.
5698
5699 2006-10-18  Bruno Haible  <bruno@clisp.org>
5700
5701         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
5702
5703 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
5704
5705         * lib/xstrtol.h: Include gettext.h.
5706         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
5707         Problem reported by Eric Blake.
5708         * modules/xstrtol (Depends-on): Add gettext-h.
5709
5710 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
5711
5712         * lib/strftime.c (advance): New macro.
5713         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
5714         incomplete type, so you can't add 0 to it.  Problem and patch
5715         reported by Eelco Dolstra for dietlibc.
5716
5717 2006-10-18  Jim Meyering  <jim@meyering.net>
5718
5719         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
5720         type for a local, and rename it: s/up/user_proc/.
5721
5722 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
5723
5724         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
5725         READ_UTMP_USER_PROCESS.
5726         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
5727
5728 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
5729
5730         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
5731         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
5732
5733 2006-10-17  Eric Blake  <ebb9@byu.net>
5734
5735         * lib/sigprocmask.c (sigprocmask): Fix typo.
5736
5737         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
5738
5739         * modules/clean-temp (Makefile.am): Don't add to make output...
5740         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
5741         config.h.
5742
5743 2006-10-17  Bruno Haible  <bruno@clisp.org>
5744
5745         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
5746         differently if DEFAULT_TEXT_DOMAIN is set.
5747
5748 2006-10-16  Bruno Haible  <bruno@clisp.org>
5749
5750         * lib/clean-temp.c: Include fwriteerror.h.
5751
5752 2006-10-16  Bruno Haible  <bruno@clisp.org>
5753
5754         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
5755
5756 2006-10-16  Bruno Haible  <bruno@clisp.org>
5757
5758         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
5759         * lib/sigprocmask.h: Include <sys/types.h>.
5760         (sigset_t): Use the system's definition if present.
5761
5762 2006-10-17  Eric Blake  <ebb9@byu.net>
5763
5764         * lib/xvasprintf.c (includes): Assume config.h.
5765         * lib/xasprintf.c (includes): Likewise.
5766
5767 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
5768
5769         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
5770         at least as wide as intmax_t.
5771
5772 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
5773
5774         (Imported from Automake.)
5775         * build-aux/gnupload: Update to version 1.1 of directive file.
5776
5777 2006-10-16  Eric Blake  <ebb9@byu.net>
5778
5779         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
5780         match Automake 1.10a.
5781
5782 2006-10-14  Bruno Haible  <bruno@clisp.org>
5783
5784         * modules/sigprocmask: New file.
5785         * lib/sigprocmask.h: New file.
5786         * lib/sigprocmask.c: New file.
5787         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
5788         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
5789         request sigprocmask.o.
5790         (gl_PREREQ_SIGPROCMASK): New macro.
5791         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
5792         (Depends-on): Add sigprocmask.
5793         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
5794         gt_SIGNALBLOCKING. Test for 'raise' only once.
5795         * lib/fatal-signal.c: Include sigprocmask.h.
5796         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
5797         unblock_fatal_signals): Define always.
5798         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
5799         sigprocmask.
5800
5801 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
5802
5803         Sync from Automake.
5804         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
5805         which incorrectly sets the mode of an existing destination
5806         directory.  In some cases the unpatched install-sh could do the
5807         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
5808         system.  We hope this is rare in practice, but it's clearly worth
5809         fixing.  Problem reported by Alex Unleashed in
5810         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
5811         Also, don't bother to check for -m bugs unless we're using -m;
5812         suggested by Stepan Kasal.
5813
5814 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5815
5816         Sync from Automake.
5817         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
5818         `-c' flag, so they appear at the same position as in %FASTDEP%
5819         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
5820         which ignores unknown options only after the first non-option.
5821         Bug report against M4 by Nelson H. F. Beebe.
5822
5823 2006-10-13  Jim Meyering  <jim@meyering.net>
5824
5825         Fix a bug in yesterday's change.
5826         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
5827         p->fts_statp->st_dev would be used uninitialized.
5828         Ensures that we always call fts_stat on the very first entry.
5829         Miklos Szeredi reported that find -xdev stopped working.
5830
5831 2006-10-12  Bruno Haible  <bruno@clisp.org>
5832
5833         * gnulib-tool (func_get_automake_snippet): Append an automatically
5834         computed EXTRA_DIST augmentation.
5835         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
5836         * modules/alloca-opt (Makefile.am): Likewise.
5837         * modules/allocsa (Makefile.am): Likewise.
5838         * modules/arcfour (Makefile.am): Likewise.
5839         * modules/arctwo (Makefile.am): Likewise.
5840         * modules/argmatch (Makefile.am): Likewise.
5841         * modules/argz (Makefile.am): Likewise.
5842         * modules/atexit (Makefile.am): Likewise.
5843         * modules/backupfile (Makefile.am): Likewise.
5844         * modules/byteswap (Makefile.am): Likewise.
5845         * modules/c-strtod (Makefile.am): Likewise.
5846         * modules/c-strtold (Makefile.am): Likewise.
5847         * modules/calloc (Makefile.am): Likewise.
5848         * modules/canon-host (Makefile.am): Likewise.
5849         * modules/canonicalize (Makefile.am): Likewise.
5850         * modules/chdir-long (Makefile.am): Likewise.
5851         * modules/chdir-safer (Makefile.am): Likewise.
5852         * modules/check-version (Makefile.am): Likewise.
5853         * modules/chown (Makefile.am): Likewise.
5854         * modules/cloexec (Makefile.am): Likewise.
5855         * modules/close-stream (Makefile.am): Likewise.
5856         * modules/closeout (Makefile.am): Likewise.
5857         * modules/crc (Makefile.am): Likewise.
5858         * modules/csharpexec (Makefile.am): Likewise.
5859         * modules/cycle-check (Makefile.am): Likewise.
5860         * modules/des (Makefile.am): Likewise.
5861         * modules/dev-ino (Makefile.am): Likewise.
5862         * modules/dirfd (Makefile.am): Likewise.
5863         * modules/dirname (Makefile.am): Likewise.
5864         * modules/dup2 (Makefile.am): Likewise.
5865         * modules/eealloc (Makefile.am): Likewise.
5866         * modules/error (Makefile.am): Likewise.
5867         * modules/euidaccess (Makefile.am): Likewise.
5868         * modules/exclude (Makefile.am): Likewise.
5869         * modules/exitfail (Makefile.am): Likewise.
5870         * modules/fcntl-safer (Makefile.am): Likewise.
5871         * modules/fcntl (Makefile.am): Likewise.
5872         * modules/file-type (Makefile.am): Likewise.
5873         * modules/fileblocks (Makefile.am): Likewise.
5874         * modules/filemode (Makefile.am): Likewise.
5875         * modules/filenamecat (Makefile.am): Likewise.
5876         * modules/fnmatch (Makefile.am): Likewise.
5877         * modules/fopen-safer (Makefile.am): Likewise.
5878         * modules/fpending (Makefile.am): Likewise.
5879         * modules/fprintftime (Makefile.am): Likewise.
5880         * modules/free (Makefile.am): Likewise.
5881         * modules/fsusage (Makefile.am): Likewise.
5882         * modules/ftruncate (Makefile.am): Likewise.
5883         * modules/fts (Makefile.am): Likewise.
5884         * modules/gc-arcfour (Makefile.am): Likewise.
5885         * modules/gc-des (Makefile.am): Likewise.
5886         * modules/gc-hmac-md5 (Makefile.am): Likewise.
5887         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
5888         * modules/gc-md4 (Makefile.am): Likewise.
5889         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
5890         * modules/gc-sha1 (Makefile.am): Likewise.
5891         * modules/gc (Makefile.am): Likewise.
5892         * modules/getaddrinfo (Makefile.am): Likewise.
5893         * modules/getcwd (Makefile.am): Likewise.
5894         * modules/getdelim (Makefile.am): Likewise.
5895         * modules/getdomainname (Makefile.am): Likewise.
5896         * modules/getgroups (Makefile.am): Likewise.
5897         * modules/gethostname (Makefile.am): Likewise.
5898         * modules/gethrxtime (Makefile.am): Likewise.
5899         * modules/getline (Makefile.am): Likewise.
5900         * modules/getloadavg (Makefile.am): Likewise.
5901         * modules/getlogin_r (Makefile.am): Likewise.
5902         * modules/getndelim2 (Makefile.am): Likewise.
5903         * modules/getopt (Makefile.am): Likewise.
5904         * modules/getpagesize (Makefile.am): Likewise.
5905         * modules/getpass-gnu (Makefile.am): Likewise.
5906         * modules/getpass (Makefile.am): Likewise.
5907         * modules/getsubopt (Makefile.am): Likewise.
5908         * modules/gettime (Makefile.am): Likewise.
5909         * modules/gettimeofday (Makefile.am): Likewise.
5910         * modules/getugroups (Makefile.am): Likewise.
5911         * modules/getusershell (Makefile.am): Likewise.
5912         * modules/glob (Makefile.am): Likewise.
5913         * modules/group-member (Makefile.am): Likewise.
5914         * modules/hard-locale (Makefile.am): Likewise.
5915         * modules/hash (Makefile.am): Likewise.
5916         * modules/hmac-md5 (Makefile.am): Likewise.
5917         * modules/hmac-sha1 (Makefile.am): Likewise.
5918         * modules/human (Makefile.am): Likewise.
5919         * modules/idcache (Makefile.am): Likewise.
5920         * modules/imaxabs (Makefile.am): Likewise.
5921         * modules/imaxdiv (Makefile.am): Likewise.
5922         * modules/inet_ntop (Makefile.am): Likewise.
5923         * modules/inet_pton (Makefile.am): Likewise.
5924         * modules/intprops (Makefile.am): Likewise.
5925         * modules/inttostr (Makefile.am): Likewise.
5926         * modules/inttypes (Makefile.am): Likewise.
5927         * modules/isapipe (Makefile.am): Likewise.
5928         * modules/javaversion (Makefile.am): Likewise.
5929         * modules/lchmod (Makefile.am): Likewise.
5930         * modules/lchown (Makefile.am): Likewise.
5931         * modules/localcharset (Makefile.am): Likewise.
5932         * modules/long-options (Makefile.am): Likewise.
5933         * modules/lstat (Makefile.am): Likewise.
5934         * modules/malloc (Makefile.am): Likewise.
5935         * modules/mathl (Makefile.am): Likewise.
5936         * modules/mbchar (Makefile.am): Likewise.
5937         * modules/md2 (Makefile.am): Likewise.
5938         * modules/md4 (Makefile.am): Likewise.
5939         * modules/md5 (Makefile.am): Likewise.
5940         * modules/memcasecmp (Makefile.am): Likewise.
5941         * modules/memchr (Makefile.am): Likewise.
5942         * modules/memcmp (Makefile.am): Likewise.
5943         * modules/memcoll (Makefile.am): Likewise.
5944         * modules/memcpy (Makefile.am): Likewise.
5945         * modules/memmem (Makefile.am): Likewise.
5946         * modules/memmove (Makefile.am): Likewise.
5947         * modules/mempcpy (Makefile.am): Likewise.
5948         * modules/memrchr (Makefile.am): Likewise.
5949         * modules/memset (Makefile.am): Likewise.
5950         * modules/memxor (Makefile.am): Likewise.
5951         * modules/mkancesdirs (Makefile.am): Likewise.
5952         * modules/mkdir-p (Makefile.am): Likewise.
5953         * modules/mkdir (Makefile.am): Likewise.
5954         * modules/mkdtemp (Makefile.am): Likewise.
5955         * modules/mkstemp (Makefile.am): Likewise.
5956         * modules/mktime (Makefile.am): Likewise.
5957         * modules/modechange (Makefile.am): Likewise.
5958         * modules/mountlist (Makefile.am): Likewise.
5959         * modules/nanosleep (Makefile.am): Likewise.
5960         * modules/obstack (Makefile.am): Likewise.
5961         * modules/openat (Makefile.am): Likewise.
5962         * modules/pagealign_alloc (Makefile.am): Likewise.
5963         * modules/pathmax (Makefile.am): Likewise.
5964         * modules/physmem (Makefile.am): Likewise.
5965         * modules/poll (Makefile.am): Likewise.
5966         * modules/posixtm (Makefile.am): Likewise.
5967         * modules/posixver (Makefile.am): Likewise.
5968         * modules/putenv (Makefile.am): Likewise.
5969         * modules/quote (Makefile.am): Likewise.
5970         * modules/quotearg (Makefile.am): Likewise.
5971         * modules/raise (Makefile.am): Likewise.
5972         * modules/read-file (Makefile.am): Likewise.
5973         * modules/readline (Makefile.am): Likewise.
5974         * modules/readlink (Makefile.am): Likewise.
5975         * modules/readtokens (Makefile.am): Likewise.
5976         * modules/readutmp (Makefile.am): Likewise.
5977         * modules/realloc (Makefile.am): Likewise.
5978         * modules/regex (Makefile.am): Likewise.
5979         * modules/rename-dest-slash (Makefile.am): Likewise.
5980         * modules/rename (Makefile.am): Likewise.
5981         * modules/rijndael (Makefile.am): Likewise.
5982         * modules/rmdir (Makefile.am): Likewise.
5983         * modules/rpmatch (Makefile.am): Likewise.
5984         * modules/safe-read (Makefile.am): Likewise.
5985         * modules/safe-write (Makefile.am): Likewise.
5986         * modules/same-inode (Makefile.am): Likewise.
5987         * modules/same (Makefile.am): Likewise.
5988         * modules/save-cwd (Makefile.am): Likewise.
5989         * modules/savedir (Makefile.am): Likewise.
5990         * modules/setenv (Makefile.am): Likewise.
5991         * modules/settime (Makefile.am): Likewise.
5992         * modules/sha1 (Makefile.am): Likewise.
5993         * modules/sig2str (Makefile.am): Likewise.
5994         * modules/snprintf (Makefile.am): Likewise.
5995         * modules/stat-macros (Makefile.am): Likewise.
5996         * modules/stat-time (Makefile.am): Likewise.
5997         * modules/stdbool (Makefile.am): Likewise.
5998         * modules/stdint (Makefile.am): Likewise.
5999         * modules/stdlib-safer (Makefile.am): Likewise.
6000         * modules/stpcpy (Makefile.am): Likewise.
6001         * modules/stpncpy (Makefile.am): Likewise.
6002         * modules/strcase (Makefile.am): Likewise.
6003         * modules/strcasestr (Makefile.am): Likewise.
6004         * modules/strchrnul (Makefile.am): Likewise.
6005         * modules/strcspn (Makefile.am): Likewise.
6006         * modules/strdup (Makefile.am): Likewise.
6007         * modules/strerror (Makefile.am): Likewise.
6008         * modules/strftime (Makefile.am): Likewise.
6009         * modules/strndup (Makefile.am): Likewise.
6010         * modules/strnlen (Makefile.am): Likewise.
6011         * modules/strpbrk (Makefile.am): Likewise.
6012         * modules/strsep (Makefile.am): Likewise.
6013         * modules/strstr (Makefile.am): Likewise.
6014         * modules/strtod (Makefile.am): Likewise.
6015         * modules/strtoimax (Makefile.am): Likewise.
6016         * modules/strtok_r (Makefile.am): Likewise.
6017         * modules/strtol (Makefile.am): Likewise.
6018         * modules/strtoll (Makefile.am): Likewise.
6019         * modules/strtoul (Makefile.am): Likewise.
6020         * modules/strtoull (Makefile.am): Likewise.
6021         * modules/strtoumax (Makefile.am): Likewise.
6022         * modules/strverscmp (Makefile.am): Likewise.
6023         * modules/sys_socket (Makefile.am): Likewise.
6024         * modules/sys_stat (Makefile.am): Likewise.
6025         * modules/sysexits (Makefile.am): Likewise.
6026         * modules/time_r (Makefile.am): Likewise.
6027         * modules/timegm (Makefile.am): Likewise.
6028         * modules/timespec (Makefile.am): Likewise.
6029         * modules/tmpfile-safer (Makefile.am): Likewise.
6030         * modules/trim (Makefile.am): Likewise.
6031         * modules/unistd-safer (Makefile.am): Likewise.
6032         * modules/unlinkdir (Makefile.am): Likewise.
6033         * modules/unlocked-io (Makefile.am): Likewise.
6034         * modules/userspec (Makefile.am): Likewise.
6035         * modules/utime (Makefile.am): Likewise.
6036         * modules/utimecmp (Makefile.am): Likewise.
6037         * modules/utimens (Makefile.am): Likewise.
6038         * modules/vasnprintf (Makefile.am): Likewise.
6039         * modules/vasprintf (Makefile.am): Likewise.
6040         * modules/vsnprintf (Makefile.am): Likewise.
6041         * modules/xalloc (Makefile.am): Likewise.
6042         * modules/xgetcwd (Makefile.am): Likewise.
6043         * modules/xnanosleep (Makefile.am): Likewise.
6044         * modules/xreadlink (Makefile.am): Likewise.
6045         * modules/xstrtod (Makefile.am): Likewise.
6046         * modules/xstrtol (Makefile.am): Likewise.
6047         * modules/xstrtold (Makefile.am): Likewise.
6048         * modules/yesno (Makefile.am): Likewise.
6049         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
6050
6051 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
6052
6053         * modules/error (Makefile.am): Distribute files through
6054         EXTRA_DIST, not lib_SOURCES.
6055
6056 2006-10-12  Eric Blake  <ebb9@byu.net>
6057
6058         * modules/error (Makefile.am): Distribute files in /lib.
6059         * modules/obstack (Makefile.am): Likewise.
6060
6061 2006-10-12  Bruno Haible  <bruno@clisp.org>
6062
6063         * modules/acl (Makefile.am): Distribute all files in lib/ through
6064         EXTRA_DIST.
6065         * modules/arcfour (Makefile.am): Likewise.
6066         * modules/arctwo (Makefile.am): Likewise.
6067         * modules/argmatch (Makefile.am): Likewise.
6068         * modules/argz (Makefile.am): Likewise.
6069         * modules/atexit (Makefile.am): Likewise.
6070         * modules/backupfile (Makefile.am): Likewise.
6071         * modules/c-strtod (Makefile.am): Likewise.
6072         * modules/c-strtold (Makefile.am): Likewise.
6073         * modules/calloc (Makefile.am): Likewise.
6074         * modules/canon-host (Makefile.am): Likewise.
6075         * modules/canonicalize (Makefile.am): Likewise.
6076         * modules/chdir-long (Makefile.am): Likewise.
6077         * modules/chdir-safer (Makefile.am): Likewise.
6078         * modules/check-version (Makefile.am): Likewise.
6079         * modules/chown (Makefile.am): Likewise.
6080         * modules/cloexec (Makefile.am): Likewise.
6081         * modules/close-stream (Makefile.am): Likewise.
6082         * modules/closeout (Makefile.am): Likewise.
6083         * modules/crc (Makefile.am): Likewise.
6084         * modules/cycle-check (Makefile.am): Likewise.
6085         * modules/des (Makefile.am): Likewise.
6086         * modules/dirfd (Makefile.am): Likewise.
6087         * modules/dirname (Makefile.am): Likewise.
6088         * modules/dup2 (Makefile.am): Likewise.
6089         * modules/euidaccess (Makefile.am): Likewise.
6090         * modules/exclude (Makefile.am): Likewise.
6091         * modules/exitfail (Makefile.am): Likewise.
6092         * modules/fcntl-safer (Makefile.am): Likewise.
6093         * modules/file-type (Makefile.am): Likewise.
6094         * modules/fileblocks (Makefile.am): Likewise.
6095         * modules/filemode (Makefile.am): Likewise.
6096         * modules/filenamecat (Makefile.am): Likewise.
6097         * modules/fnmatch (Makefile.am): Likewise.
6098         * modules/fopen-safer (Makefile.am): Likewise.
6099         * modules/fpending (Makefile.am): Likewise.
6100         * modules/fprintftime (Makefile.am): Likewise.
6101         * modules/free (Makefile.am): Likewise.
6102         * modules/fsusage (Makefile.am): Likewise.
6103         * modules/ftruncate (Makefile.am): Likewise.
6104         * modules/fts (Makefile.am): Likewise.
6105         * modules/gc (Makefile.am): Likewise.
6106         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
6107         * modules/getaddrinfo (Makefile.am): Likewise.
6108         * modules/getcwd (Makefile.am): Likewise.
6109         * modules/getdelim (Makefile.am): Likewise.
6110         * modules/getdomainname (Makefile.am): Likewise.
6111         * modules/getgroups (Makefile.am): Likewise.
6112         * modules/gethostname (Makefile.am): Likewise.
6113         * modules/gethrxtime (Makefile.am): Likewise.
6114         * modules/getline (Makefile.am): Likewise.
6115         * modules/getloadavg (Makefile.am): Likewise.
6116         * modules/getlogin_r (Makefile.am): Likewise.
6117         * modules/getopt (Makefile.am): Likewise.
6118         * modules/getpass (Makefile.am): Likewise.
6119         * modules/getpass-gnu (Makefile.am): Likewise.
6120         * modules/getsubopt (Makefile.am): Likewise.
6121         * modules/gettime (Makefile.am): Likewise.
6122         * modules/gettimeofday (Makefile.am): Likewise.
6123         * modules/getugroups (Makefile.am): Likewise.
6124         * modules/getusershell (Makefile.am): Likewise.
6125         * modules/glob (Makefile.am): Likewise.
6126         * modules/group-member (Makefile.am): Likewise.
6127         * modules/hard-locale (Makefile.am): Likewise.
6128         * modules/hash (Makefile.am): Likewise.
6129         * modules/hmac-md5 (Makefile.am): Likewise.
6130         * modules/hmac-sha1 (Makefile.am): Likewise.
6131         * modules/human (Makefile.am): Likewise.
6132         * modules/idcache (Makefile.am): Likewise.
6133         * modules/imaxabs (Makefile.am): Likewise.
6134         * modules/imaxdiv (Makefile.am): Likewise.
6135         * modules/inet_ntop (Makefile.am): Likewise.
6136         * modules/inet_pton (Makefile.am): Likewise.
6137         * modules/inttostr (Makefile.am): Likewise.
6138         * modules/isapipe (Makefile.am): Likewise.
6139         * modules/lchown (Makefile.am): Likewise.
6140         * modules/long-options (Makefile.am): Likewise.
6141         * modules/lstat (Makefile.am): Likewise.
6142         * modules/malloc (Makefile.am): Likewise.
6143         * modules/mathl (Makefile.am): Likewise.
6144         * modules/mbchar (Makefile.am): Likewise.
6145         * modules/md2 (Makefile.am): Likewise.
6146         * modules/md4 (Makefile.am): Likewise.
6147         * modules/md5 (Makefile.am): Likewise.
6148         * modules/memcasecmp (Makefile.am): Likewise.
6149         * modules/memchr (Makefile.am): Likewise.
6150         * modules/memcmp (Makefile.am): Likewise.
6151         * modules/memcoll (Makefile.am): Likewise.
6152         * modules/memcpy (Makefile.am): Likewise.
6153         * modules/memmem (Makefile.am): Likewise.
6154         * modules/memmove (Makefile.am): Likewise.
6155         * modules/mempcpy (Makefile.am): Likewise.
6156         * modules/memrchr (Makefile.am): Likewise.
6157         * modules/memset (Makefile.am): Likewise.
6158         * modules/memxor (Makefile.am): Likewise.
6159         * modules/mkancesdirs (Makefile.am): Likewise.
6160         * modules/mkdir (Makefile.am): Likewise.
6161         * modules/mkdir-p (Makefile.am): Likewise.
6162         * modules/mkdtemp (Makefile.am): Likewise.
6163         * modules/mkstemp (Makefile.am): Likewise.
6164         * modules/mktime (Makefile.am): Likewise.
6165         * modules/modechange (Makefile.am): Likewise.
6166         * modules/mountlist (Makefile.am): Likewise.
6167         * modules/nanosleep (Makefile.am): Likewise.
6168         * modules/openat (Makefile.am): Likewise.
6169         * modules/pagealign_alloc (Makefile.am): Likewise.
6170         * modules/physmem (Makefile.am): Likewise.
6171         * modules/poll (Makefile.am): Likewise.
6172         * modules/posixtm (Makefile.am): Likewise.
6173         * modules/posixver (Makefile.am): Likewise.
6174         * modules/putenv (Makefile.am): Likewise.
6175         * modules/quote (Makefile.am): Likewise.
6176         * modules/quotearg (Makefile.am): Likewise.
6177         * modules/raise (Makefile.am): Likewise.
6178         * modules/read-file (Makefile.am): Likewise.
6179         * modules/readline (Makefile.am): Likewise.
6180         * modules/readlink (Makefile.am): Likewise.
6181         * modules/readtokens (Makefile.am): Likewise.
6182         * modules/readutmp (Makefile.am): Likewise.
6183         * modules/realloc (Makefile.am): Likewise.
6184         * modules/regex (Makefile.am): Likewise.
6185         * modules/rename (Makefile.am): Likewise.
6186         * modules/rename-dest-slash (Makefile.am): Likewise.
6187         * modules/rijndael (Makefile.am): Likewise.
6188         * modules/rmdir (Makefile.am): Likewise.
6189         * modules/rpmatch (Makefile.am): Likewise.
6190         * modules/safe-read (Makefile.am): Likewise.
6191         * modules/safe-write (Makefile.am): Likewise.
6192         * modules/same (Makefile.am): Likewise.
6193         * modules/save-cwd (Makefile.am): Likewise.
6194         * modules/savedir (Makefile.am): Likewise.
6195         * modules/setenv (Makefile.am): Likewise.
6196         * modules/settime (Makefile.am): Likewise.
6197         * modules/sha1 (Makefile.am): Likewise.
6198         * modules/sig2str (Makefile.am): Likewise.
6199         * modules/snprintf (Makefile.am): Likewise.
6200         * modules/stdlib-safer (Makefile.am): Likewise.
6201         * modules/stpcpy (Makefile.am): Likewise.
6202         * modules/stpncpy (Makefile.am): Likewise.
6203         * modules/strcase (Makefile.am): Likewise.
6204         * modules/strcasestr (Makefile.am): Likewise.
6205         * modules/strchrnul (Makefile.am): Likewise.
6206         * modules/strcspn (Makefile.am): Likewise.
6207         * modules/strdup (Makefile.am): Likewise.
6208         * modules/strerror (Makefile.am): Likewise.
6209         * modules/strftime (Makefile.am): Likewise.
6210         * modules/strndup (Makefile.am): Likewise.
6211         * modules/strnlen (Makefile.am): Likewise.
6212         * modules/strpbrk (Makefile.am): Likewise.
6213         * modules/strsep (Makefile.am): Likewise.
6214         * modules/strstr (Makefile.am): Likewise.
6215         * modules/strtod (Makefile.am): Likewise.
6216         * modules/strtoimax (Makefile.am): Likewise.
6217         * modules/strtok_r (Makefile.am): Likewise.
6218         * modules/strtol (Makefile.am): Likewise.
6219         * modules/strtoll (Makefile.am): Likewise.
6220         * modules/strtoul (Makefile.am): Likewise.
6221         * modules/strtoull (Makefile.am): Likewise.
6222         * modules/strtoumax (Makefile.am): Likewise.
6223         * modules/strverscmp (Makefile.am): Likewise.
6224         * modules/time_r (Makefile.am): Likewise.
6225         * modules/timegm (Makefile.am): Likewise.
6226         * modules/tmpfile-safer (Makefile.am): Likewise.
6227         * modules/unistd-safer (Makefile.am): Likewise.
6228         * modules/unlinkdir (Makefile.am): Likewise.
6229         * modules/userspec (Makefile.am): Likewise.
6230         * modules/utime (Makefile.am): Likewise.
6231         * modules/utimecmp (Makefile.am): Likewise.
6232         * modules/utimens (Makefile.am): Likewise.
6233         * modules/vasnprintf (Makefile.am): Likewise.
6234         * modules/vasprintf (Makefile.am): Likewise.
6235         * modules/vsnprintf (Makefile.am): Likewise.
6236         * modules/xalloc (Makefile.am): Likewise.
6237         * modules/xgetcwd (Makefile.am): Likewise.
6238         * modules/xnanosleep (Makefile.am): Likewise.
6239         * modules/xreadlink (Makefile.am): Likewise.
6240         * modules/xstrtod (Makefile.am): Likewise.
6241         * modules/xstrtol (Makefile.am): Likewise.
6242         * modules/xstrtold (Makefile.am): Likewise.
6243         * modules/yesno (Makefile.am): Likewise.
6244
6245 2006-10-12  Jim Meyering  <jim@meyering.net>
6246
6247         * m4/getloadavg.m4: Revert the change below.
6248
6249         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
6250         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
6251         fail with a symlink, which is what coreutils' ./bootstrap now
6252         creates by default.
6253
6254 2006-10-12  Bruno Haible  <bruno@clisp.org>
6255
6256         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
6257         mingw.
6258         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
6259         MSVC and mingw explicitly.
6260
6261 2006-10-11  Simon Josefsson  <jas@extundo.com>
6262             Bruno Haible  <bruno@clisp.org>
6263
6264         Add support for multiple gnulib-tool invocations in the scope of a
6265         single configure.ac file.
6266         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
6267         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
6268         with the same contents as the _LIBADD variable.
6269         (func_emit_initmacro_start, func_emit_initmacro_end,
6270         func_emit_initmacro_done): New functions.
6271         (func_import, func_create_testdir): Invoke them. Allow the identifiers
6272         gl_LIBOBJS and gl_LTLIBOBJS.
6273
6274 2006-10-11  Bruno Haible  <bruno@clisp.org>
6275
6276         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
6277         (func_create_testdir): Don't create po/Makefile.am, don't invoke
6278         autoreconf. Instead, invoke autopoint explicitly but move back the
6279         *.m4 files from gnulib.
6280
6281 2006-10-11  Bruno Haible  <bruno@clisp.org>
6282
6283         * gnulib-tool (func_usage): Make module names after --create-testdir
6284         optional.
6285         (func_create_testdir): If no module was specified, use nearly all
6286         modules.
6287
6288 2006-10-12  Jim Meyering  <jim@meyering.net>
6289
6290         Big performance improvement for fts-based tools that use FTS_NOSTAT.
6291         Avoid spurious inode-mismatch problems on non-POSIX file systems.
6292         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
6293         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
6294         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
6295         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
6296         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
6297         (fts_set_stat_required): New function.
6298         (fts_open): Defer the calls to fts_stat, if possible or requested.
6299         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
6300         into fts_stat itself.
6301         (fts_read): Perform any required (deferred) fts_stat call.
6302         (fts_build): Likewise, for the directory we're about to open and read.
6303         In the readdir loop, carefully decide whether each entry will require
6304         an eventual call to fts_stat, using dirent.d_type info if available.
6305         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
6306         a command line argument into this function.  Update all callers.
6307         Map a return value of FTS_DOT to FTS_D for a command line argument.
6308         * modules/fts (Depends-on): Add d-type.  Alphabetize.
6309         Thanks to Miklos Szeredi for his tenacity and for the initial
6310         bug report about "find" failing on a FUSE-based file system.
6311
6312         * lib/fts.c (fts_open): Use consistent indentation.
6313
6314 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
6315
6316         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
6317         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
6318         reported by Jim Meyering.  All uses of cache variables renamed
6319         to match Autoconf's.
6320         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
6321         the other one.
6322
6323         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
6324         Fix misspelling in diagnostic.
6325
6326 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
6327
6328         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
6329         defined.  Problem reported by Matthew Woehlke.
6330
6331         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
6332         Add support for Tandem NonStop R series.
6333         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
6334         Use new macro.
6335
6336         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
6337         (has_trailing_slash): Omit size arg; all callers changed.
6338         Omit 'inline', since it doesn't help performance and we'd
6339         need to configure it.
6340         Don't count //, ///, etc. as having a trailing slash.
6341         As a side effect, this removes a C99ism reported by Matthew Woehlke.
6342         (rpl_rename_dest_slash): On failure, use rename's errno rather
6343         than (in some cases) an incorrect or junk errno.
6344         Simplify code by removing need to compute length; this does
6345         cause it to make two passes instead of one over the file name,
6346         but it's worth it.
6347
6348         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
6349         change, since Autoconf's version may no longer be appropriate now
6350         that we are using CVS Autoconf's version.  Add support for Tandem.
6351
6352 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
6353             Bruno Haible  <bruno@clisp.org>
6354
6355         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
6356         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
6357         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
6358         gl_AC_TYPE_LONG_LONG.
6359
6360         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
6361         instead of HAVE_LONG_LONG.
6362         * lib/printf-args.c (printf_fetchargs): Likewise.
6363         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
6364         * lib/vasnprintf.c (VASNPRINTF): Likewise.
6365         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
6366         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
6367         gl_AC_TYPE_LONG_LONG.
6368
6369 2006-10-11  Bruno Haible  <bruno@clisp.org>
6370
6371         * m4/longlong.m4: Add comments.
6372         * m4/ulonglong.m4: Likewise.
6373
6374 2006-10-10  Bruno Haible  <bruno@clisp.org>
6375
6376         Make it possible to #define stpcpy, strdup to aliases.
6377         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
6378         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
6379
6380 2006-10-10  Bruno Haible  <bruno@clisp.org>
6381
6382         Make it possible to #define gcd to an alias.
6383         * lib/gcd.c: Include config.h.
6384
6385 2006-10-10  Bruno Haible  <bruno@clisp.org>
6386
6387         Make it possible to #define c_isascii to an alias.
6388         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
6389         defined. Undefine the macros before defining them, to avoid gcc
6390         warnings.
6391         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
6392         define NO_C_CTYPE_MACROS early.
6393
6394 2006-10-10  Bruno Haible  <bruno@clisp.org>
6395
6396         Make it possible to #define set_program_name to an alias.
6397         * lib/progname.c: Don't undefine set_program_name; instead, undefine
6398         ENABLE_RELOCATABLE early.
6399
6400 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
6401
6402         Port to Tandem NSK OSS, which has 64-bit signed int but at most
6403         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
6404         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
6405         More generally, don't assume that 64-bit signed int is available
6406         if unsigned int is, and vice versa.
6407         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
6408         unsigned symbols, not on their signed counterparts.
6409         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
6410         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
6411         (UINT64_C, UINTMAX_C):
6412         Likewise.
6413         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
6414         unsigned counterparts.
6415         (Have_long_long, Unsigned): New macros.
6416         (Int): Renamed from INT.
6417         (strtoimax): Use the new macros.
6418         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
6419         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
6420         * modules/inttypes (inttypes.h): Substitute
6421         HAVE_UNSIGNED_LONG_LONG_INT.
6422         * modules/stdint (stdint.h): Likewise.
6423         (Files): Add m4/ulonglong.m4.
6424
6425 2006-10-10  Bruno Haible  <bruno@clisp.org>
6426
6427         Fix a gcc -Wshadow warning.
6428         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
6429         to 'bucket'.
6430         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
6431         gl_linked_indexof_from_to): Likewise.
6432         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
6433         Likewise.
6434         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
6435         Likewise.
6436         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
6437         Reported by Eric Blake.
6438
6439 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
6440
6441         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
6442         for NetBSD.  Problem reported by Bruno Haible.
6443
6444 2006-10-09  Jim Meyering  <jim@meyering.net>
6445
6446         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
6447         Patch from Bruno Haible.
6448
6449 2006-10-09  Jim Meyering  <jim@meyering.net>
6450
6451         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
6452         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
6453         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
6454
6455 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
6456
6457         Don't include <config.h> twice; this doesn't work in some cases,
6458         e.g., when config.h has "#define intmax_t long long int" and
6459         we include <config.h>, <inttypes.h>, <config.h> in that order.
6460         Problem reported by Matthew Woehlke in:
6461         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
6462         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
6463         * lib/fts-cycle.c: Don't include config.h.
6464         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
6465         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
6466         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
6467         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
6468         inttypes.h.
6469         * lib/xstrtoumax.c: Likewise.
6470         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
6471         __strtol and the like, so that this module is more like its siblings.
6472         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
6473         Remove; no longer needed now that we assume gnulib inttypes.h.
6474
6475 2006-10-08  Bruno Haible  <bruno@clisp.org>
6476
6477         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
6478         option.
6479
6480 2006-10-07  Jim Meyering  <jim@meyering.net>
6481
6482         * modules/inttypes (inttypes.h): Revert what seems to have been
6483         an inadvertent part of today's change: use "|", not "/" in the
6484         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
6485
6486 2006-10-07  Bruno Haible  <bruno@clisp.org>
6487
6488         * modules/sublist: New file.
6489
6490 2006-10-07  Bruno Haible  <bruno@clisp.org>
6491
6492         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
6493         * modules/argz (argz.h): Likewise.
6494         * modules/arpa_inet (arpa/inet.h): Likewise.
6495         * modules/byteswap (byteswap.h): Likewise.
6496         * modules/configmake (configmake.h): Likewise.
6497         * modules/fcntl (fcntl.h): Likewise.
6498         * modules/fnmatch (fnmatch.h): Likewise.
6499         * modules/getopt (getopt.h): Likewise.
6500         * modules/glob (glob.h): Likewise.
6501         * modules/inttypes (inttypes.h): Likewise.
6502         * modules/netinet_in (netinet/in.h): Likewise.
6503         * modules/poll (poll.h): Likewise.
6504         * modules/stdbool (stdbool.h): Likewise.
6505         * modules/stdint (stdint.h): Likewise.
6506         * modules/sys_select (sys/select.h): Likewise.
6507         * modules/sys_socket (sys/socket.h): Likewise.
6508         * modules/sys_stat (sys/stat.h): Likewise.
6509         * modules/sysexits (sysexits.h): Likewise.
6510         * modules/unistd (unistd.h): Likewise.
6511         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6512         Add a "DO NOT EDIT" comment to the generated file.
6513         (func_import): Likewise for gnulib-comp.m4.
6514
6515 2006-10-07  Bruno Haible  <bruno@clisp.org>
6516
6517         * lib/gl_sublist.h: New file.
6518         * lib/gl_sublist.c: New file.
6519
6520 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
6521
6522         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
6523         name (relative to the original working directory) and the file
6524         name component (relative to the temporary working directory).  All
6525         callers changed.
6526         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
6527         * lib/mkdir-p.c (make_dir_parents): Likewise.
6528         * lib/mkdir-p.h (make_dir_parents): Likewise.
6529
6530 2006-10-06  Eric Blake  <ebb9@byu.net>
6531
6532         Define several macros for use by the clean-temp module.
6533         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
6534         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
6535         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
6536
6537         * lib/clean-temp.h (close_stream_temp): New declaration.
6538         * lib/clean-temp.c (includes): Pull in headers according to what
6539         other modules are in use.
6540         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
6541
6542 2006-10-06  Bruno Haible  <bruno@clisp.org>
6543
6544         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
6545         instead of fopen, fwriteerror.
6546
6547 2006-10-06  Bruno Haible  <bruno@clisp.org>
6548
6549         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
6550         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
6551         int.
6552         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
6553         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
6554         Return an error indicator.
6555         Suggested by Eric Blake.
6556
6557 2006-10-06  Bruno Haible  <bruno@clisp.org>
6558
6559         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
6560         Reported by Eric Blake.
6561
6562 2006-10-06  Bruno Haible  <bruno@clisp.org>
6563
6564         * modules/closeout (Description): Mention stderr too.
6565
6566 2006-10-06  Bruno Haible  <bruno@clisp.org>
6567         and Paul Eggert  <eggert@cs.ucla.edu>
6568
6569         * lib/closeout.c (close_stdout): Also close stderr.
6570         * lib/closeout.h: Update comment.
6571
6572 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
6573
6574         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
6575         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
6576         * lib/dirchownmod.c: Include lchown.h.
6577         * lib/lchown.c: Don't include files that lchown.h now includes.
6578         Don't declare chown, since lchown.h now does that.
6579         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
6580         (lchown): Define to rpl_chown if lchown is declared but
6581         does not exist.  Declare using a prototype if lchown is not
6582         declared.  Add a copyright notice.
6583         * lib/mkstemp.h: Include <unistd.h>.
6584         * lib/openat.c: Include lchown.h.
6585
6586         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
6587         we now test for that separately.
6588         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
6589         rather than O_NOFOLLOW, when testing whether it's possible to
6590         avoid a race condition reliably.
6591         * lib/savewd.c (savewd_chdir): Likewise.
6592
6593         Remove macros that are no longer needed now that stdint.h is
6594         reliable.
6595         * lib/fsusage.c (UINTMAX_MAX): Remove.
6596         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
6597         * lib/utimecmp.c (SIZE_MAX): Remove.
6598
6599         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
6600
6601         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
6602         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
6603         O_NOATIME works.
6604
6605 2006-10-05  Bruno Haible  <bruno@clisp.org>
6606
6607         * lib/gl_list.h (gl_sortedlist_search_from_to,
6608         gl_sortedlist_indexof_from_to): New declarations.
6609         (gl_list_implementation): New fields sortedlist_search_from_to,
6610         sortedlist_indexof_from_to.
6611         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
6612         inline functions.
6613         * lib/gl_list.c (gl_sortedlist_search_from_to,
6614         gl_sortedlist_indexof_from_to): New functions.
6615         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
6616         function.
6617         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
6618         (gl_array_sortedlist_search_from_to): New function.
6619         (gl_array_list_implementation): Update.
6620         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
6621         function.
6622         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
6623         (gl_carray_sortedlist_search_from_to): New function.
6624         (gl_carray_list_implementation): Update.
6625         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
6626         gl_linked_sortedlist_indexof_from_to): New functions.
6627         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
6628         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
6629         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
6630         gl_tree_sortedlist_indexof_from_to): New functions.
6631         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
6632         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
6633         Update.
6634         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
6635         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
6636         Update.
6637
6638 2006-10-05  Bruno Haible  <bruno@clisp.org>
6639
6640         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
6641         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
6642         (struct gl_list_implementation): Add fields search_from_to,
6643         indexof_from_to. Remove fields search, indexof.
6644         (gl_list_search): Use the search_from_to method.
6645         (gl_list_search_from, gl_list_search_from_to): New functions.
6646         (gl_list_indexof): Use the indexof_from_to method.
6647         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
6648         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
6649         (gl_list_search_from, gl_list_search_from_to): New functions.
6650         (gl_list_indexof): Use the indexof_from_to method.
6651         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
6652         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
6653         gl_array_indexof. Add start_index, end_index arguments.
6654         (gl_array_search_from_to): Renamed from gl_array_search. Add
6655         start_index, end_index arguments.
6656         (gl_array_remove, gl_array_list_implementation): Update.
6657         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
6658         gl_carray_indexof. Add start_index, end_index arguments.
6659         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
6660         start_index, end_index arguments.
6661         (gl_carray_remove, gl_carray_list_implementation): Update.
6662         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
6663         gl_linked_search. Add start_index, end_index arguments.
6664         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
6665         start_index, end_index arguments.
6666         (gl_linked_remove): Update.
6667         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
6668         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
6669         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
6670         field to 'size_t'.
6671         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
6672         gl_tree_search. Add start_index, end_index arguments.
6673         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
6674         start_index, end_index arguments.
6675         (gl_tree_remove): Update.
6676         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
6677         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
6678         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
6679         function.
6680         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
6681         gl_tree_search. Add start_index, end_index arguments.
6682         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
6683         start_index, end_index arguments.
6684         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
6685         Update.
6686         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
6687
6688 2006-10-05  Bruno Haible  <bruno@clisp.org>
6689
6690         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
6691
6692         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
6693         fwriteerror_temp): New declarations.
6694         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
6695         (descriptors): New variable.
6696         (cleanup): First, close the descriptors.
6697         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
6698         fclose_temp, fwriteerror_temp): New functions.
6699
6700 2006-10-04  Jim Meyering  <jim@meyering.net>
6701
6702         * lib/fts.c (fts_open): Tiny comment change.
6703
6704 2006-10-04  Bruno Haible  <bruno@clisp.org>
6705
6706         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
6707         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
6708         gl_LOCK_BODY.
6709         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
6710         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
6711         gl_LOCK_EARLY_BODY.
6712         (gl_LOCK): Require gl_LOCK_BODY.
6713
6714 2006-10-04  Bruno Haible  <bruno@clisp.org>
6715
6716         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
6717         (gl_oset_search_atleast): New declaration.
6718         (struct gl_oset_implementation): Add field 'search_atleast'.
6719         (gl_oset_search_atleast): New inline function.
6720         * lib/gl_oset.c (gl_oset_search_atleast): New function.
6721         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
6722         (gl_array_oset_implementation): Update.
6723         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
6724         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
6725         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
6726
6727 2006-10-04  Bruno Haible  <bruno@clisp.org>
6728
6729         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
6730
6731 2006-10-03  Bruno Haible  <bruno@clisp.org>
6732
6733         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
6734         from gl_avltreehash_list_implementation.
6735
6736 2006-10-03  Bruno Haible  <bruno@clisp.org>
6737
6738         * lib/gl_oset.c (gl_oset_add): Fix return type.
6739
6740 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
6741
6742         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
6743
6744 2006-10-02  Eric Blake  <ebb9@byu.net>
6745
6746         * modules/strnlen (Depends-on): Add extensions.
6747
6748 2006-10-02  Eric Blake  <ebb9@byu.net>
6749
6750         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
6751         definition in 2.60+.
6752
6753 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
6754
6755         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
6756         checks.
6757
6758 2006-10-02  Bruno Haible  <bruno@clisp.org>
6759
6760         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
6761         to the AUTOMAKE_OPTIONS.
6762         Reported by Jim Meyering.
6763
6764 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
6765
6766         Work around bug in Solaris 10 /proc file system:
6767         /proc/self/fd/NNN/.. isn't the parent directory of
6768         the directory whose file descriptor is NNN.  This needs to
6769         be worked around at run time, not compile time, since a
6770         program might be built on Solaris 8, where things work, and
6771         run on Solaris 10.
6772         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
6773         to use the following interface instead:
6774         (OPENAT_BUFFER_SIZE): New macro.
6775         (openat_proc_name): New function.
6776         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
6777         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
6778         Likewise.
6779         * lib/openat-proc.c: New file.
6780         * modules/openat (Files): Add lib/openat-proc.c.
6781         (Depends-on): Add same-inode, stdbool.
6782         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
6783
6784 2006-09-29  Bruno Haible  <bruno@clisp.org>
6785
6786         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
6787         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
6788         argument. Set stdout_closed before testing for ferror, not after.
6789         (fwriteerror, fwriteerror_no_ebadf): New functions.
6790
6791 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6792
6793         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
6794
6795 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
6796
6797         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
6798         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
6799
6800 2006-09-28  Jim Meyering  <jim@meyering.net>
6801
6802         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
6803         Include <unistd.h>.
6804
6805 2006-09-28  Bruno Haible  <bruno@clisp.org>
6806
6807         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
6808         * modules/linkedhash-list (Depends-on): Likewise.
6809         * modules/rbtreehash-list (Depends-on): Likewise.
6810
6811 2006-09-28  Bruno Haible  <bruno@clisp.org>
6812
6813         * lib/strndup.h: Simplify the redefinition of strndup.
6814         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
6815         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
6816
6817 2006-09-28  Bruno Haible  <bruno@clisp.org>
6818
6819         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
6820         * lib/gl_linkedhash_list.c: Likewise.
6821         * lib/gl_rbtreehash_list.c: Likewise.
6822
6823 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
6824
6825         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
6826         getaddrinfo.
6827
6828         * lib/__fpending.h: Don't include <stdio_ext.h> unless
6829         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
6830         it causes <stdio_ext.h> to cause a compile-time error.
6831         Problem reported by Nelson H. F. Beebe.
6832         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
6833         of HAVE_DECL___PENDING.
6834
6835         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
6836         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
6837         declaration.
6838
6839 2006-09-27  Jim Meyering  <jim@meyering.net>
6840
6841         This file could end up with a definition for a function
6842         named __strndup, rather than rpl_strndup on a system with
6843         incomplete weak_alias support.
6844         * lib/strndup.c (strndup): Rename from __strndup.
6845         Remove #defines that used to map __strndup to strndup.
6846         Don't use K&R prototypes.
6847         Remove LIBC-related code, since this file is not sync'd with glibc.
6848         * lib/strndup.h: Revamp, accordingly.
6849         * m4/strndup.m4: Modernize.
6850
6851 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
6852
6853         * modules/savewd (Depends-on): Add 'raise'.
6854         * lib/savewd.c: Include <signal.h>, for 'raise'.
6855
6856 2006-09-26  Jim Meyering  <jim@meyering.net>
6857
6858         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
6859         when we detect Darwin 8.7.0's acl_get_file bug.
6860         Rearrange to perform the new (below) run-test while $LIBS
6861         contains any acl-related library.  Set USE_ACL at the end.
6862         (gl_ACL_GET_FILE): New function.
6863
6864 2006-09-26  Eric Blake  <ebb9@byu.net>
6865
6866         * lib/verror.c: Include <config.h> unconditionally.
6867
6868 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
6869
6870         * modules/clock-time (Maintainer): Add self.
6871         * modules/getlogin_r (Depends-on): Add extensions.
6872
6873 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6874
6875         * modules/clock-time: New module.
6876         * modules/nanosleep (Depends-on): Add clock-time.
6877         * modules/gethrxtime (Depends-on): Likewise.
6878         * modules/gettime (Depends-on): Likewise.
6879         * modules/settime (Depends-on): Likewise.
6880
6881         * modules/fts-lgpl: Depend on openat.
6882         * modules/mkancesdirs: Depend on savewd.
6883         * modules/mkdir-p: Likewise.
6884
6885 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6886
6887         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
6888
6889         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
6890         `gl_have_arbitrary_file_name_length_limit' to
6891         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
6892         actually works between configure runs.
6893
6894 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6895             Bruno Haible  <bruno@clisp.org>
6896
6897         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
6898
6899 2006-09-25  Jim Meyering  <jim@meyering.net>
6900
6901         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
6902         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
6903
6904 2006-09-25  Eric Blake  <ebb9@byu.net>
6905
6906         * gnulib-tool (func_import, func_create_testdir): Fix typos in
6907         exec's in 2006-09-18 patch when shuffling fds.
6908
6909 2006-09-25  Bruno Haible  <bruno@clisp.org>
6910
6911         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
6912         Reported by Jim Meyering.
6913
6914 2006-09-24  Jim Meyering  <jim@meyering.net>
6915
6916         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
6917         compare a pointer against a literal "0".  That caused failures with
6918         at least HP-UX's hpcc.
6919
6920 2006-09-22  Simon Josefsson  <jas@extundo.com>
6921
6922         * modules/gc-sha1:
6923         * modules/gc-md4:
6924         * modules/gc-hmac-sha1:
6925         * modules/gc-hmac-md5:
6926         * modules/gc-des:
6927         * modules/gc-arcfour: Distribute more files.
6928
6929 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6930
6931         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
6932         (gl_linked_iterator_from_to): Initialize struct completely.
6933         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
6934         (gl_tree_iterator_from_to): Likewise
6935         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
6936         * lib/gl_array_list.c [lint] (gl_array_iterator)
6937         (gl_array_iterator_from_to): Likewise.
6938         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
6939         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
6940         (gl_carray_iterator_from_to): Likewise.
6941
6942         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
6943         * lib/md4.c (md4_process_block): Remove unused variable.
6944         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
6945         parentheses for clarity.
6946
6947 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6948
6949         * modules/bison-i18n (Depends-on): Add gettext.
6950
6951 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6952
6953         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
6954         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
6955         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
6956         also add missing comma that caused broken test.
6957         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
6958         stdlib.h, for `abort'.
6959         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
6960         variables.
6961         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
6962         include unistd.h if present, for `rmdir'.
6963         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
6964         variables.
6965         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
6966         in the process include standard headers for prototypes.
6967         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
6968         gets declared on GNU/Linux.
6969         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
6970         unistd.h, for `rmdir'.
6971         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
6972
6973         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
6974         always true.
6975         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
6976
6977         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
6978
6979 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6980
6981         * gnulib-tool (func_version): Create output all at once.  This
6982         may help avoid triggering unnecessary SIGPIPEs, and at any
6983         rate it doesn't hurt.
6984
6985 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6986             Bruno Haible  <bruno@clisp.org>
6987
6988         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
6989         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
6990         * m4/signed.m4 (bh_C_SIGNED): Likewise.
6991
6992         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
6993         (gl_FUNC_VASPRINTF): Invoke it.
6994
6995 2006-09-22  Bruno Haible  <bruno@clisp.org>
6996
6997         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
6998         getloadavg.c as first argument.
6999
7000 2006-09-22  Bruno Haible  <bruno@clisp.org>
7001
7002         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
7003         at the beginning of the gl_INIT macro.
7004         * modules/getloadavg (configure.ac): Pass $gl_source_base to
7005         gl_GETLOADAVG.
7006
7007 2006-09-22  Bruno Haible  <bruno@clisp.org>
7008
7009         * gnulib-tool (func_create_megatestdir): Don't include the config-h
7010         module.
7011         Suggested by Ralf Wildenhues.
7012
7013 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
7014
7015         Import this patch from libc:
7016
7017         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
7018
7019         * lib/regex_internal.c (re_string_reconstruct): Handle
7020         offset < pstr->valid_raw_len && pstr->offsets_needed case.
7021         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
7022         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
7023         re_string_context_at.
7024
7025         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
7026         now requires it.
7027         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
7028         gl_REGEX now does it for us.
7029         (gl_REGEX): Add test taken from
7030         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
7031
7032         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
7033         Check that large offsets work.  Modernize Autoconf usages.
7034         Prefer "yes" to mean a good thing rather than a bad.
7035         Don't put "#define mkstemp" in config.h, as this might interfere
7036         with standard system headers that "#define mkstemp mkstemp64".
7037
7038         * modules/mkstemp (Depends-on): Add extensions, so that
7039         mkstemp is visible on some platforms.
7040         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
7041         (Include): Change to "mkstemp.h" from <stdlib.h>.
7042         (Files): Add mkstemp.h.
7043
7044         * lib/mkstemp.h: New file, since some standard headers
7045         #define mkstemp.
7046         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
7047         Include "mkstemp.h".
7048         Make the _LIBC code resemble glibc original more,
7049         e.g., use K&R style.
7050         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
7051         (mkstemp): Remove, since mkstemp.h does this for us.
7052         * lib/stdlib--.h: Include mkstemp.h.
7053
7054         Import this patch from libc:
7055
7056         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7057
7058         * lib/tempname.c (__gen_tempname): Change attempts_min
7059         into a macro.  Use preprocessor to decide how to initialize
7060         attempts [Coverity CID 67].
7061
7062 2006-09-20  Bruno Haible  <bruno@clisp.org>
7063
7064         * lib/mkdtemp.c: Import from libc.
7065         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7066                 * sysdeps/posix/tempname.c (__gen_tempname): Change
7067                 attempts_min into a macro.  Use preprocessor to decide how to
7068                 initialize attempts [Coverity CID 67].
7069         2001-11-27  Paul Eggert  <eggert@twinsun.com>
7070                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
7071                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
7072
7073 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7074
7075         * gnulib-tool (func_exit): New function, to allow to pass the
7076         exit status portably through the trap.  Use everywhere.
7077         (--help, --version): Signal a write error.
7078         (trap): catch SIGPIPE, for write errors.
7079         Exit at the end of the trap, with the correct exit status.
7080
7081 2006-09-19  Karl Berry  <karl@gnu.org>
7082
7083         * doc/gnulib.texi: note about the license texinfo files.
7084
7085 2006-09-19  Eric Blake  <ebb9@byu.net>
7086
7087         * gnulib-tool: Avoid space-tab.
7088
7089 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7090
7091         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
7092         that prevented coreutils 6.1 from building.  Problem reported
7093         by Petter Reinholdtsen.
7094
7095 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7096
7097         * gnulib-tool (avoidlist): Fix typo that broke options like
7098         --avoid=lock that are used by coreutils bootstrap.
7099
7100 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
7101
7102         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
7103         more systematically.
7104
7105 2006-09-18  Jim Meyering  <jim@meyering.net>
7106
7107         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
7108
7109 2006-09-18  Bruno Haible  <bruno@clisp.org>
7110
7111         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
7112
7113 2006-09-18  Bruno Haible  <bruno@clisp.org>
7114
7115         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
7116         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
7117         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
7118         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
7119         * m4/gettext.m4: Require autoconf >= 2.52.
7120         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
7121         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
7122         of gl_cv_header_inttypes_h.
7123
7124 2006-09-18  Bruno Haible  <bruno@clisp.org>
7125
7126         * lib/javaversion.c: Include configmake.h.
7127
7128 2006-09-18  Bruno Haible  <bruno@clisp.org>
7129
7130         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
7131         avoid that the while loops be executed in a subshell.
7132
7133 2006-09-18  Bruno Haible  <bruno@clisp.org>
7134
7135         * MODULES.html.sh (func_module): Break long lines.
7136         Suggested by Bruce Korb <bkorb@gnu.org>.
7137
7138 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7139
7140         Speed up by a factor of 1.12.
7141         * gnulib-tool (nl): New variable.
7142         (func_import): Rewrite include directive extraction to only read each
7143         directive once.
7144
7145 2006-09-17  Bruno Haible  <bruno@clisp.org>
7146
7147         * modules/javaversion (Makefile.am): Remove DEFS setting.
7148         (Depends-on): Add configmake, for PKGDATADIR definition.
7149
7150 2006-09-17  Bruno Haible  <bruno@clisp.org>
7151
7152         * gnulib-tool (func_create_testdir): Rewrite all files at once.
7153
7154 2006-09-17  Bruno Haible  <bruno@clisp.org>
7155
7156         * gnulib-tool (func_append): New function, stolen from libtool.m4.
7157         (func_modules_transitive_closure, func_modules_add_dummy,
7158         func_modules_to_filelist, func_import, func_create_testdir,
7159         func_create_megatestdir, ...): Use it wherever possible.
7160         Suggested by Ralf Wildenhues.
7161
7162 2006-09-16  Karl Berry  <karl@gnu.org>
7163
7164         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
7165         to avoid sectioning errors.
7166         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
7167         [ifinfo]: blank line after @center-ed titles.
7168         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
7169         Spell FSF address consistently with others.
7170         (These changes approved by rms.)
7171
7172 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7173
7174         Speed up by a factor of 1.61.
7175         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
7176         already checked module names again.
7177
7178 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7179
7180         Speed up by a factor of 1.13.
7181         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
7182         for new_files, and the input to func_add_or_update.
7183
7184 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7185
7186         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
7187         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
7188
7189 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7190
7191         * modules/mkancesdirs (Depends-on): Add fcntl.
7192         * modules/savewd: New file.
7193         * MODULES.html.sh (File system functions): Add savewd.
7194
7195         * modules/configmake (Makefile.am): Add support for the
7196         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
7197
7198 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7199
7200         * m4/savewd.m4: New file.
7201
7202 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7203
7204         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
7205         (dirchownmod): New arg FD.  All callers changed.
7206         Use FD rather than opening the directory ourself, as opening is
7207         now the caller's responsibility.
7208         * lib/dirchownmod.h: Likewise.
7209         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
7210         hosts that require <sys/types.h> before <sys/stat.h>.  Include
7211         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
7212         (test_dir): Remove.
7213         (mkancesdirs): Return length of prefix of FILE that has already
7214         been made, or -2 if there is a child doing the work.  Redo
7215         algorithm so that it is O(N) rather than O(N**2).  Optimize away
7216         ".", and treat ".." specially since it might stray back into
7217         already-created areas.  Use a subprocess if necessary.  New arg
7218         WD; all users changed.  MAKE_DIR function should now return 1
7219         if it creates a directory that is not readable.  Return -2 if
7220         a child process is spun off.
7221         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
7222         Adjust signature to match code.
7223         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
7224         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
7225         all users changed.
7226         * lib/savewd.c, lib/savewd.h: New files.
7227
7228 2006-09-15  Jim Meyering  <jim@meyering.net>
7229
7230         * modules/rename-dest-slash: New module.
7231         * MODULES.html.sh (posix_compat): Add it here.
7232
7233         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
7234
7235 2006-09-15  Jim Meyering  <jim@meyering.net>
7236
7237         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
7238         file.
7239
7240         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
7241
7242 2006-09-15  Jim Meyering  <jim@meyering.net>
7243
7244         * lib/rename-dest-slash.c (has_trailing_slash): Use
7245         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
7246         (rpl_rename_dest_slash): Perform the cheaper trailing slash
7247         test before testing whether SRC is a directory.
7248         Suggestions from Bruno Haible.
7249
7250         Avoid a warning about an unused variable.
7251         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
7252         into the #ifdef block where it's used.
7253
7254         * lib/rename-dest-slash.c: New file.
7255
7256 2006-09-14  Bruno Haible  <bruno@clisp.org>
7257
7258         * lib/allocsa.c: Include <config.h> unconditionally.
7259         * lib/asnprintf.c: Likewise.
7260         * lib/asprintf.c: Likewise.
7261         * lib/c-strcasecmp.c: Likewise.
7262         * lib/c-strcasestr.c: Likewise.
7263         * lib/c-strncasecmp.c: Likewise.
7264         * lib/c-strstr.c: Likewise.
7265         * lib/classpath.c: Likewise.
7266         * lib/clean-temp.c: Likewise.
7267         * lib/concatpath.c: Likewise.
7268         * lib/copy-file.c: Likewise.
7269         * lib/csharpcomp.c: Likewise.
7270         * lib/csharpexec.c: Likewise.
7271         * lib/execute.c: Likewise.
7272         * lib/fatal-signal.c: Likewise.
7273         * lib/findprog.c: Likewise.
7274         * lib/fwriteerror.c: Likewise.
7275         * lib/gl_array_list.c: Likewise.
7276         * lib/gl_array_oset.c: Likewise.
7277         * lib/gl_avltree_list.c: Likewise.
7278         * lib/gl_avltree_oset.c: Likewise.
7279         * lib/gl_avltreehash_list.c: Likewise.
7280         * lib/gl_carray_list.c: Likewise.
7281         * lib/gl_linked_list.c: Likewise.
7282         * lib/gl_linkedhash_list.c: Likewise.
7283         * lib/gl_list.c: Likewise.
7284         * lib/gl_oset.c: Likewise.
7285         * lib/gl_rbtree_list.c: Likewise.
7286         * lib/gl_rbtree_oset.c: Likewise.
7287         * lib/gl_rbtreehash_list.c: Likewise.
7288         * lib/imaxabs.c: Likewise.
7289         * lib/imaxdiv.c: Likewise.
7290         * lib/javacomp.c: Likewise.
7291         * lib/javaexec.c: Likewise.
7292         * lib/javaversion.c: Likewise.
7293         * lib/linebreak.c: Likewise.
7294         * lib/localcharset.c: Likewise.
7295         * lib/lock.c: Likewise.
7296         * lib/mbchar.c: Likewise.
7297         * lib/mbswidth.c: Likewise.
7298         * lib/mkdtemp.c: Likewise.
7299         * lib/pipe.c: Likewise.
7300         * lib/printf-args.c: Likewise.
7301         * lib/printf-parse.c: Likewise.
7302         * lib/progname.c: Likewise.
7303         * lib/progreloc.c: Likewise.
7304         * lib/readlink.c: Likewise.
7305         * lib/sh-quote.c: Likewise.
7306         * lib/stpcpy.c: Likewise.
7307         * lib/stpncpy.c: Likewise.
7308         * lib/strcasecmp.c: Likewise.
7309         * lib/strcasestr.c: Likewise.
7310         * lib/strcspn.c: Likewise.
7311         * lib/striconv.c: Likewise.
7312         * lib/strncasecmp.c: Likewise.
7313         * lib/strnlen1.c: Likewise.
7314         * lib/strstr.c: Likewise.
7315         * lib/strtok_r.c: Likewise.
7316         * lib/tls.c: Likewise.
7317         * lib/tmpdir.c: Likewise.
7318         * lib/unicodeio.c: Likewise.
7319         * lib/unsetenv.c: Likewise.
7320         * lib/vasnprintf.c: Likewise.
7321         * lib/vasprintf.c: Likewise.
7322         * lib/wait-process.c: Likewise.
7323         * lib/xallocsa.c: Likewise.
7324         * lib/xsetenv.c: Likewise.
7325         * lib/xstriconv.c: Likewise.
7326
7327 2006-09-13  Simon Josefsson  <jas@extundo.com>
7328
7329         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
7330         that internally, suggested by Ralf Wildenhues
7331         <Ralf.Wildenhues@gmx.de>.
7332
7333 2006-09-13  Simon Josefsson  <jas@extundo.com>
7334
7335         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
7336         @LIBOBJS@.
7337         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7338
7339 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
7340
7341         * lib/_fpending.c: Include <config.h> unconditionally, since we no
7342         longer worry about uses that don't define HAVE_CONFIG_H.
7343         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
7344         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
7345         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
7346         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
7347         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
7348         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
7349         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
7350         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
7351         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
7352         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
7353         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
7354         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
7355         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
7356         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
7357         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
7358         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
7359         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
7360         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
7361         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
7362         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
7363         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
7364         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
7365         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
7366         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
7367         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
7368         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
7369         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
7370         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
7371         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
7372         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
7373         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
7374         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
7375         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
7376         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
7377         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
7378         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
7379         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
7380         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
7381         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
7382         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
7383         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
7384         Likewise.
7385
7386 2006-09-13  Eric Blake  <ebb9@byu.net>
7387
7388         * lib/getopt.c: Fix typo in last commit.
7389
7390 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
7391
7392         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
7393         dgettext.
7394
7395 2006-09-12  Jim Meyering  <jim@meyering.net>
7396
7397         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
7398         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
7399         Reported by Nelson H. F. Beebe.
7400
7401 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
7402
7403         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
7404         program_invocation_name and program_invocation_short_name are
7405         initialized.
7406         * lib/argp-namefrob.h: Move declarations of program_invocation_name
7407         and program_invocation_short_name to argp.h, so they are visible
7408         to user programs.
7409         * lib/argp.h: Likewise
7410
7411 2006-09-10  Bruno Haible  <bruno@clisp.org>
7412
7413         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
7414         m4/inttypes_h.m4, m4/uintmax_t.m4.
7415
7416 2006-09-10  Bruno Haible  <bruno@clisp.org>
7417
7418         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
7419         gl_AC_TYPE_UINTMAX_T.
7420
7421 2006-09-10  Bruno Haible  <bruno@clisp.org>
7422
7423         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
7424
7425 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
7426
7427         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
7428         convention.  Text proposed by Bruno Haible.
7429         (struct argp_option): Document the use of N_() wrappers.
7430
7431         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
7432         '\v', and translate the two parts separately, instead of feeding
7433         the whole string to gettext.  This allows to exclude
7434         '\v' from the strings visible to the translator by writing doc
7435         strings as N_("..") "\v" N_("..").
7436
7437 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
7438
7439         * config/srclist.txt: Undo latest change; the bug was fixed.
7440
7441 2006-09-09  Bruno Haible  <bruno@clisp.org>
7442
7443         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
7444         assignments if building a library without libtool.
7445         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
7446         in func_emit_lib_Makefile_am.
7447         (func_import): When building a static library libfoo.a, arrange to
7448         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
7449         (func_create_testdir): Likewise.
7450         * modules/gc (configure.ac, Makefile.am): If building statically,
7451         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
7452         * modules/iconvme (configure.ac, Makefile.am): Likewise.
7453         * modules/striconv (configure.ac, Makefile.am): Likewise.
7454         Based on a suggestion by Ralf Wildenhues.
7455
7456 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7457
7458         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
7459         Check for unistd.h too, since Autoconf doesn't assume POSIX.
7460         Also:
7461
7462         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7463         Add year_2050_test to catch glibc bug 2821
7464         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
7465
7466         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
7467         Prefer #ifdef to #if.
7468
7469         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
7470         Return from 'main' instead of calling 'exit'.
7471
7472 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7473
7474         * lib/mktime.c (guess_time_tm): Fix bug where mktime
7475         returned the maximum time_t value rather than (time_t) -1.
7476         Problem originally reported by William Bardwell
7477         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
7478
7479         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
7480         Moved to here ...
7481         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
7482         ... from here.
7483
7484 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
7485
7486         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
7487         2821 is fixed.
7488
7489 2006-09-08  Jim Meyering  <jim@meyering.net>
7490
7491         Don't make generated files read-only.  That would bother too many
7492         people.  However, do retain the ability to work when targets are
7493         read-only: remove the destination and temporary files before writing
7494         them (when generated via sed or echo), or by using the -f option for
7495         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
7496         * modules/alloca-opt, modules/argz, modules/arpa_inet:
7497         * modules/byteswap, modules/configmake, modules/fcntl:
7498         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
7499         * modules/localcharset, modules/netinet_in, modules/poll:
7500         * modules/stdbool, modules/stdint, modules/sys_select:
7501         * modules/sys_socket, modules/sys_stat, modules/sysexits:
7502
7503 2006-09-08  Jim Meyering  <jim@meyering.net>
7504
7505         Avoid new build failure on FreeBSD 6.0.
7506         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
7507         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
7508         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
7509
7510 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7511
7512         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
7513
7514 2006-09-07  Jim Meyering  <jim@meyering.net>
7515
7516         Fix global typo in last change: use chmod u-w, not chmod u-x.
7517         Spotted by Paul Eggert and Bruce Korb.
7518         * modules/alloca-opt, modules/argz, modules/arpa_inet:
7519         * modules/byteswap, modules/configmake, modules/fcntl:
7520         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
7521         * modules/localcharset, modules/netinet_in, modules/poll:
7522         * modules/stdbool, modules/stdint, modules/sys_select:
7523         * modules/sys_socket, modules/sys_stat, modules/sysexits:
7524
7525 2006-09-06  Jim Meyering  <jim@meyering.net>
7526
7527         Make generated files be read-only.
7528         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
7529         Ensure that each generated file is now read-only.
7530         * modules/argz: Likewise.
7531         * modules/arpa_inet: Likewise.
7532         * modules/byteswap: Likewise.
7533         * modules/configmake: Likewise.
7534         * modules/fcntl: Likewise.
7535         * modules/fnmatch: Likewise.
7536         * modules/getopt: Likewise.
7537         * modules/glob: Likewise.
7538         * modules/inttypes: Likewise.
7539         * modules/netinet_in: Likewise.
7540         * modules/poll: Likewise.
7541         * modules/stdbool: Likewise.
7542         * modules/stdint: Likewise.
7543         * modules/sys_select: Likewise.
7544         * modules/sys_socket: Likewise.
7545         * modules/sys_stat: Likewise.
7546         * modules/sysexits: Likewise.
7547         * modules/localcharset: Same as above, but continue using temporary
7548         file named "t-$@" (why different?) rather than the "$@-t" used
7549         everywhere else.
7550
7551         * modules/sysexits (Makefile.am): Replace literal occurrences
7552         of "sysexit.h" more readable, and more consistent, "$@".
7553
7554 2006-09-06  Bruno Haible  <bruno@clisp.org>
7555
7556         * modules/striconv: New file.
7557         * modules/xstriconv: New file.
7558         * MODULES.html.sh (Internationalization functions): Add striconv,
7559         xstriconv.
7560
7561 2006-09-06  Bruno Haible  <bruno@clisp.org>
7562
7563         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
7564         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
7565         not using libtool correctly.
7566
7567 2006-09-06  Bruno Haible  <bruno@clisp.org>
7568
7569         * lib/striconv.h: New file.
7570         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
7571         iconvstring.c.
7572         * lib/xstriconv.h: New file.
7573         * lib/xstriconv.c: New file.
7574
7575 2006-09-06  Bruno Haible  <bruno@clisp.org>
7576
7577         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
7578         lib_..._LDFLAGS.
7579
7580 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7581
7582         * lib/argz_.h: Sync from Libtool.
7583
7584         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
7585                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
7586
7587         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
7588
7589 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
7590
7591         * modules/trim: New file.
7592
7593 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
7594
7595         * lib/trim.h: New file.
7596         * lib/trim.c: New file.
7597
7598 2006-09-05  Bruno Haible  <bruno@clisp.org>
7599
7600         * MODULES.html.sh (String handling): Add trim.
7601
7602 2006-09-04  Karl Berry  <karl@gnu.org>
7603
7604         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
7605         until next release.
7606
7607 2006-09-03  Bruno Haible  <bruno@clisp.org>
7608
7609         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
7610         correctly.
7611
7612 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7613
7614         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
7615         not gl_GETLOADAVG.  Omit unneeded semicolons.
7616         Problems reported by Ralf Wildenhues in
7617         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
7618         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
7619         at the end, which is the usual gnulib style.
7620
7621         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
7622         of doing all the work ourselves.
7623         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
7624         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
7625
7626 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7627
7628         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
7629         Problem reported by Ralf Wildenhues in
7630         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
7631
7632         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
7633         HAVE_STRUCT_STATFS_F_FSTYPENAME.
7634
7635 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
7636
7637         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
7638         yesterday's patch by changing test -n to test -z.
7639
7640 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7641
7642         * modules/getloadavg (Files): Add m4/getloadavg.m4.
7643         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
7644         the former is now obsolescent.
7645
7646         * modules/chdir-long (Depends-on): Add fcntl.
7647
7648 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7649
7650         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
7651         obsolescent, and programs should use gnulib instead.
7652         * m4/getloadavg.m4: New file, with contents taken from Autoconf
7653         but with prefixes changed.
7654
7655 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
7656
7657         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
7658         or stdbool.h, because they might not exist while configuring.
7659
7660         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
7661         Don't include unistd.h or limits.h; not needed, since chdir-long.h
7662         does that for us.
7663         (O_DIRECTORY): Remove.
7664
7665 2006-08-31  Eric Blake  <ebb9@byu.net>
7666
7667         * gnulib-tool: Don't let emacs change spaces to TAB.
7668
7669 2006-08-31  Bruno Haible  <bruno@clisp.org>
7670
7671         * gnulib-tool: When calling func_import more than once, do it in a
7672         subshell.
7673         Reported by Eric Blake <ebb9@byu.net>.
7674
7675 2006-08-31  Bruno Haible  <bruno@clisp.org>
7676
7677         * gnulib-tool (nl): Remove variable.
7678         (sed_transform_lib_file): Use more robust test for config-h module.
7679         (func_import): Fix typo in 2006-08-25 patch.
7680
7681 2006-08-31  Bruno Haible  <bruno@clisp.org>
7682
7683         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
7684         specified, augment Makefile.am variables instead of assigning them.
7685
7686 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7687
7688         Work around a bug in both the Linux and SunOS 64-bit kernels:
7689         nanosleep mishandles sleeps for longer than 2**31 seconds.
7690         Problem reported by Frank v Waveren in
7691         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
7692         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
7693         Check for nanosleep bug.
7694         (LIB_NANOSLEEP): Append clock_gettime library if needed.
7695
7696 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7697
7698         Work around a bug in both the Linux and SunOS 64-bit kernels:
7699         nanosleep mishandles sleeps for longer than 2**31 seconds.
7700         Problem reported by Frank v Waveren in
7701         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
7702         * lib/nanosleep.c (BILLION): New constant.
7703         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
7704         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
7705         implementation.
7706
7707 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7708
7709         * modules/nanosleep (Depends-on): Add gettime.
7710
7711 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7712         and Simon Josefsson  <jas@extundo.com>
7713         and Oskar Liljeblad  <oskar@osk.mine.nu>
7714
7715         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
7716         * gnulib-tool (func_import): New license type 'unmodifiable license
7717         text'.
7718         * modules/fdl: Use it.  Longer description.
7719         * module/gpl, module/lgpl: New files.
7720
7721 2006-08-30  Jim Meyering  <jim@meyering.net>
7722
7723         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
7724         shadowing the parameter.
7725
7726 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7727
7728         Sync from Libtool:
7729
7730         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7731
7732         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
7733         sharing with gnulib.  Report by Eric Blake.
7734
7735 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7736
7737         * modules/isapipe: New file.
7738         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
7739
7740 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7741
7742         * modules/configmake (Makefile.am): Add a comment, and omit
7743         the CONFIGMAKE_ prefix from generated macro names.  Suggested
7744         by Bruno Haible.
7745
7746 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7747
7748         * m4/isapipe.m4: New file.
7749
7750 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
7751
7752         * lib/isapipe.c, lib/isapipe.h: New files.
7753
7754 2006-08-29  Jim Meyering  <jim@meyering.net>
7755
7756         * modules/configmake (Makefile.am): Make configmake.h depend on
7757         Makefile.  Otherwise, a stale configmake.h could hang around.
7758
7759 2006-08-29  Eric Blake  <ebb9@byu.net>
7760
7761         * lib/error.c (error_at_line, print_errno_message): Match libc, after
7762         resolution of upstream bug 3044.
7763
7764 2006-08-29  Bruno Haible  <bruno@clisp.org>
7765
7766         * modules/localcharset (Depends-on): Add configmake.
7767         (Makefile.am): Remove setting of LIBDIR through DEFS.
7768
7769 2006-08-29  Bruno Haible  <bruno@clisp.org>
7770
7771         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
7772         defined.
7773
7774 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7775
7776         * modules/fcntl: New file.
7777         * modules/chdir-safer (Depends-on): Add fcntl.
7778         * modules/fts: Likewise.
7779         * modules/mkdir-p: Likewise.
7780
7781         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
7782         This undoes the most recent change, since we're now addressing the
7783         problem in a different way.
7784
7785         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
7786         into output, since the output might be called Makefile.am even
7787         if $makefile_name is something different.
7788         (func_import): Use $makefile_am rather than
7789         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
7790         empty.
7791
7792         * modules/inttypes (Files): Add m4/inttypes-h.m4.
7793
7794 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7795
7796         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
7797         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
7798         recent change to stdint.m4, since we're now addressing the problem in a
7799         different way.
7800
7801 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7802
7803         * m4/fcntl_h.m4: New file.
7804
7805 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
7806
7807         * lib/fcntl_.h: New file.
7808         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
7809         the fcntl module.
7810         * lib/dirchownmod.c: Likewise.
7811         * lib/fts.c: Likewise.
7812
7813         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
7814         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
7815         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
7816         just before including <inttypes.h>, to avoid circular inclusion.
7817
7818 2006-08-28  Jim Meyering  <jim@meyering.net>
7819
7820         * doc/visibility.texi: Actually read and correct the grammar of the
7821         sentence affected by yesterday's change.
7822
7823 2006-08-28  Eric Blake  <ebb9@byu.net>
7824
7825         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
7826         needs wrapper.
7827
7828 2006-08-28  Eric Blake  <ebb9@byu.net>
7829
7830         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
7831
7832 2006-08-28  Eric Blake  <ebb9@byu.net>
7833
7834         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
7835
7836 2006-08-28  Bruno Haible  <bruno@clisp.org>
7837
7838         * modules/c-strstr: New file, from GNU gettext.
7839         * MODULES.html.sh (String handling): Add c-strstr.
7840
7841 2006-08-28  Bruno Haible  <bruno@clisp.org>
7842
7843         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
7844         macros.
7845         Reported by Eric Blake.
7846
7847 2006-08-28  Bruno Haible  <bruno@clisp.org>
7848
7849         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
7850         (VASNPRINTF): Return a string of length > INT_MAX without failing.
7851         * lib/vasprintf.c: Include errno.h, limits.h.
7852         (EOVERFLOW): New fallback definition.
7853         (vasprintf): Test here whether the string length is > INT_MAX.
7854         * lib/vsnprintf.c: Include errno.h, limits.h.
7855         (EOVERFLOW): New fallback definition.
7856         (vsnprintf): Fix bug when generated string was too long for the buffer.
7857         Test here whether the string length is > INT_MAX.
7858
7859 2006-08-28  Bruno Haible  <bruno@clisp.org>
7860
7861         * lib/inttypes_.h (SCNX*): Remove definitions.
7862         Reported by Eric Blake.
7863
7864 2006-08-28  Bruno Haible  <bruno@clisp.org>
7865
7866         * lib/c-strstr.h: New file, from GNU gettext.
7867         * lib/c-strstr.c: New file, from GNU gettext.
7868
7869 2006-08-28  Bruno Haible  <bruno@clisp.org>
7870
7871         * gnulib-tool: Reorder some statements.
7872
7873 2006-08-28  Bruno Haible  <bruno@clisp.org>
7874
7875         * gnulib-tool: New option --makefile-name.
7876         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
7877         $makefile_name.
7878         (func_import): Write $makefile_name to the cache file, and read it from
7879         there unless explicitly specified. Use $makefile_name as file name
7880         instead of Makefile.am. Adjust the recommendations accordingly.
7881
7882 2006-08-28  Bruno Haible  <bruno@clisp.org>
7883
7884         * gnulib-tool (func_verify_module): Check against misapplying patch.
7885
7886 2006-08-28  Bruno Haible  <bruno@clisp.org>
7887
7888         * gnulib-tool (func_relativize, func_relconcat): New functions.
7889         Give an error if --local-dir is given with --update.
7890         Remove trailing slashes from $local_gnulib_dir.
7891         (func_import): Store the relativized $local_gnulib_dir in
7892         gnulib-cache.m4, and read it from there if not specified explicitly.
7893
7894 2006-08-28  Bruno Haible  <bruno@clisp.org>
7895
7896         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
7897         is the current directory. Respect also $local_gnulib_dir.
7898
7899 2006-08-28  Bruno Haible  <bruno@clisp.org>
7900             Simon Josefsson  <jas@extundo.com>
7901
7902         BeOS portability.
7903         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
7904
7905 2006-08-27  Jim Meyering  <jim@meyering.net>
7906
7907         * doc/visibility.texi: Remove duplicate word: "pointer".
7908
7909 2006-08-26  Bruno Haible  <bruno@clisp.org>
7910
7911         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
7912         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
7913         (Makefile.am): Create inttypes.h from inttypes_.h.
7914         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
7915
7916         * modules/imaxabs: New file.
7917
7918         * modules/imaxdiv: New file.
7919
7920 2006-08-26  Bruno Haible  <bruno@clisp.org>
7921
7922         * m4/inttypes.m4: New file.
7923         * m4/_inttypes_h.m4: Remove file.
7924         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
7925         PRI_MACROS_BROKEN.
7926         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
7927
7928         * m4/imaxabs.m4: New file.
7929
7930         * m4/imaxdiv.m4: New file.
7931
7932 2006-08-26  Bruno Haible  <bruno@clisp.org>
7933
7934         * lib/inttypes_.h: New file.
7935         * lib/inttypes.h: Remove file.
7936         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
7937
7938         * lib/imaxabs.c: New file.
7939
7940         * lib/imaxdiv.c: New file.
7941
7942 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
7943
7944         New config-h module, so that "make" output needn't be cluttered
7945         by -DHAVE_CONFIG_H.
7946         * MODULES.html.sh (Support for building libraries and executables):
7947         Add config-h.
7948         * modules/config-h: New file.
7949         * gnulib-tool (nl, sed_transform_lib_file): New vars.
7950         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
7951         the config-h module is used.
7952
7953         New configmake module, so that "make" output needn't be cluttered
7954         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
7955         * MODULES.html.sh (Support for building libraries and executables):
7956         Add configmake.
7957         * modules/configmake: New file.
7958
7959 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
7960
7961         * m4/config-h.m4: New file.
7962
7963 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
7964
7965         * config/srclist.txt: Add elisp-comp.
7966
7967 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
7968
7969         * MODULES.html.sh (Support for building libraries and executables):
7970         Add elisp-comp.
7971         * build-aux/elisp-comp: New file.
7972         * modules/elisp-comp: New file.
7973
7974 2006-08-24  Bruno Haible  <bruno@clisp.org>
7975
7976         * gnulib-tool (func_create_testdir): Use non-default values of
7977         sourcebase and m4base.
7978
7979 2006-08-24  Bruno Haible  <bruno@clisp.org>
7980
7981         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
7982         HTML structure.
7983
7984 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
7985
7986         * modules/openat (Depends-on): Add lchown.
7987
7988 2006-08-23  Bruno Haible  <bruno@clisp.org>
7989
7990         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
7991         of gl_LOCK_EARLY instead of gl_LOCK.
7992
7993 2006-08-23  Bruno Haible  <bruno@clisp.org>
7994
7995         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
7996         on OSF/1 to no.
7997         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
7998
7999 2006-08-23  Bruno Haible  <bruno@clisp.org>
8000
8001         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
8002         as unusable.
8003
8004         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
8005         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
8006         (gl_LOCK): New macro.
8007
8008 2006-08-22  Simon Josefsson  <jas@extundo.com>
8009
8010         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
8011         to md5 module.
8012
8013 2006-08-22  Simon Josefsson  <jas@extundo.com>
8014
8015         * MODULES.html.sh: Add "Support for maintaining and release
8016         projects".
8017
8018         * build-aux/gnupload: New file, from coreutils.
8019
8020 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8021
8022         Avoid the need for AC_LIBSOURCES in m4 macros.
8023         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
8024         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
8025         * modules/check-version (EXTRA_DIST): Add check-version.h.
8026         * modules/crc (EXTRA_DIST): Add crc.h.
8027         * modules/des (EXTRA_DIST): Add des.h.
8028         * modules/gc (EXTRA_DIST): Add gc.h.
8029         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
8030         * modules/getline (EXTRA_DIST): Add getline.h.
8031         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
8032         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
8033         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
8034         * modules/md2 (EXTRA_DIST): Add md2.h.
8035         * modules/md4 (EXTRA_DIST): Add md4.h.
8036         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
8037         * modules/read-file (EXTRA_DIST): Add read-file.h.
8038         * modules/readline (EXTRA_DIST): Add readline.h.
8039         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
8040         rijndael-api-fst.h.
8041
8042 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8043
8044         * m4/rijndael.m4 (gl_ARCFOUR):
8045         * m4/arctwo.m4 (gl_ARCTWO):
8046         * m4/check-version.m4 (gl_CHECK_VERSION):
8047         * m4/crc.m4 (gl_CRC):
8048         * m4/des.m4 (gl_DES):
8049         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
8050         * m4/gc.m4 (gl_GC):
8051         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
8052         * m4/getline.m4 (gl_FUNC_GETLINE):
8053         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
8054         * m4/hmac-md5.m4 (gl_HMAC_MD5):
8055         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
8056         * m4/md2.m4 (gl_MD2):
8057         * m4/md4.m4 (gl_MD4):
8058         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
8059         * m4/read-file.m4 (gl_FUNC_READ_FILE):
8060         * m4/readline.m4 (gl_FUNC_READLINE):
8061         * m4/rijndael.m4 (gl_RIJNDAEL):
8062         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
8063         to get the necessary .h files and whatnot.
8064
8065 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8066
8067         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
8068         gnulib rather than the other way around.
8069         * config/srclistvars.sh (COREUTILS): Remove.
8070
8071 2006-08-22  Jim Meyering  <jim@meyering.net>
8072
8073         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
8074
8075         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
8076
8077 2006-08-22  Eric Blake  <ebb9@byu.net>
8078
8079         * modules/regexprops-generic: New file.
8080         * MODULES.html.sh (Support for building documentation): List it.
8081
8082 2006-08-22  Eric Blake  <ebb9@byu.net>
8083
8084         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
8085         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
8086         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
8087         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
8088
8089 2006-08-22  Bruno Haible  <bruno@clisp.org>
8090
8091         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
8092         and lib_LTLIBRARIES like the other lib_* variables.
8093
8094 2006-08-22  Bruno Haible  <bruno@clisp.org>
8095
8096         * build-aux/x-to-1.in: New file, from GNU gettext.
8097
8098 2006-08-22  Bruno Haible  <bruno@clisp.org>
8099
8100         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
8101         <utmpx.h> exists.
8102
8103 2006-08-22  Bruno Haible  <bruno@clisp.org>
8104
8105         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
8106         <utmpx.h> exists.
8107
8108 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8109
8110         BeOS portability.
8111         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
8112         exist.
8113         Problem reported by Bruno Haible.
8114
8115 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8116
8117         Avoid the need for AC_LIBSOURCES in m4 macros.
8118         * modules/acl (EXTRA_DIST): Add acl.h.
8119         * modules/argmatch (Files): Add m4/argmatch.m4.
8120         (configure.ac): Add gl_ARGMATCH.
8121         (EXTRA_DIST): Renamed from lib_SOURCES, for
8122         consistency with the other modules.  Remove argmatch.c.
8123         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
8124         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
8125         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
8126         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
8127         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
8128         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
8129         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
8130         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
8131         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
8132         * modules/closeout (EXTRA_DIST): Add closeout.h.
8133         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
8134         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
8135         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
8136         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
8137         dirname.h; remove basename.c and stripslash.c.
8138         * modules/exclude (EXTRA_DIST): Add exclude.h.
8139         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
8140         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
8141         * modules/file-type (EXTRA_DIST): Add file-type.h.
8142         * modules/filemode (EXTRA_DIST): Add filemode.h.
8143         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
8144         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
8145         * modules/fpending (EXTRA_DIST): Add __fpending.h.
8146         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
8147         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
8148         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
8149         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
8150         * modules/getdate (EXTRA_DIST): Add getdate.c.
8151         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
8152         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
8153         * modules/getpass (EXTRA_DIST): Add getpass.h.
8154         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
8155         * modules/group-member (EXTRA_DIST): Add group-member.h.
8156         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
8157         * modules/hash (EXTRA_DIST): Add hash.h.
8158         * modules/human (EXTRA_DIST): Add human.h.
8159         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
8160         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
8161         * modules/lchown (EXTRA_DIST): Add lchown.h.
8162         * modules/long-options (EXTRA_DIST): Add long-options.h.
8163         * modules/lstat (EXTRA_DIST): Add lstat.h.
8164         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
8165         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
8166         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
8167         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
8168         * modules/memxor (EXTRA_DIST): Add memxor.h.
8169         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
8170         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
8171         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
8172         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
8173         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
8174         * modules/physmem (EXTRA_DIST): Add physmem.h.
8175         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
8176         * modules/posixver (EXTRA_DIST): Add posixver.h.
8177         * modules/quote (EXTRA_DIST): Add quote.h.
8178         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
8179         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
8180         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
8181         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
8182         regex_internal.h regexec.c.
8183         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
8184         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
8185         * modules/same (EXTRA_DIST): Add same.h.
8186         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
8187         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
8188         * modules/savedir (EXTRA_DIST): Add savedir.h.
8189         * modules/sha1 (EXTRA_DIST): Add sha1.h.
8190         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
8191         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
8192         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
8193         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
8194         * modules/strdup (EXTRA_DIST): Add strdup.h.
8195         * modules/strftime (EXTRA_DIST): Add strftime.h.
8196         * modules/strndup (EXTRA_DIST): Add strndup.h.
8197         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
8198         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
8199         * modules/time_r (EXTRA_DIST): Add time_r.h.
8200         * modules/timespec (EXTRA_DIST): Add timespec.h.
8201         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
8202         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
8203         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
8204         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
8205         * modules/userspec (EXTRA_DIST): Add userspec.h.
8206         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
8207         * modules/utimens (EXTRA_DIST): Add utimens.h.
8208         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
8209         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
8210         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
8211         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
8212         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
8213         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
8214         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
8215         * modules/yesno (EXTRA_DIST): Add yesno.h.
8216
8217 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8218
8219         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
8220
8221         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
8222         * m4/dev-ino.m4, same-inode.m4: Remove.
8223
8224         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
8225         * m4/acl.m4 (AC_FUNC_ACL):
8226         * m4/backupfile.m4 (gl_BACKUPFILE):
8227         * m4/c-strtod.m4 (gl_C99_STRTOLD):
8228         * m4/canon-host.m4 (gl_CANON_HOST):
8229         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
8230         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
8231         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
8232         * m4/cloexec.m4 (gl_CLOEXEC):
8233         * m4/close-stream.m4 (gl_CLOSE_STREAM):
8234         * m4/closeout.m4 (gl_CLOSEOUT):
8235         * m4/dirfd.m4 (gl_FUNC_DIRFD):
8236         * m4/dirname.m4 (gl_DIRNAME):
8237         * m4/exclude.m4 (gl_EXCLUDE):
8238         * m4/exitfail.m4 (gl_EXITFAIL):
8239         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
8240         * m4/file-type.m4 (gl_FILE_TYPE):
8241         * m4/filemode.m4 (gl_FILEMODE):
8242         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
8243         * m4/fpending.m4 (gl_FUNC_FPENDING):
8244         * m4/fprintftime.m4 (gl_FPRINTFTIME):
8245         * m4/fts.m4 (gl_FUNC_FTS):
8246         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
8247         * m4/getdate.m4 (gl_GETDATE):
8248         * m4/gethrxtime.m4 (gl_GETHRXTIME):
8249         * m4/getpagesize.m4 (gl_GETPAGESIZE):
8250         * m4/getpass.m4 (gl_FUNC_GETPASS):
8251         * m4/gettime.m4 (gl_GETTIME):
8252         * m4/getugroups.m4 (gl_GETUGROUPS):
8253         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
8254         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
8255         * m4/hard-locale.m4 (gl_HARD_LOCALE):
8256         * m4/hash.m4 (gl_HASH):
8257         * m4/idcache.m4 (gl_IDCACHE):
8258         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
8259         * m4/lchown.m4 (gl_FUNC_LCHOWN):
8260         * m4/long-options.m4 (gl_LONG_OPTIONS):
8261         * m4/lstat.m4 (gl_FUNC_LSTAT):
8262         * m4/md5.m4 (gl_MD5):
8263         * m4/memcasecmp.m4 (gl_MEMCASECMP):
8264         * m4/memcoll.m4 (gl_MEMCOLL):
8265         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
8266         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
8267         * m4/memxor.m4 (gl_MEMXOR):
8268         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
8269         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
8270         * m4/modechange.m4 (gl_MODECHANGE):
8271         * m4/mountlist.m4 (gl_MOUNTLIST):
8272         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
8273         * m4/openat.m4 (gl_FUNC_OPENAT):
8274         * m4/pathmax.m4 (gl_PATHMAX):
8275         * m4/physmem.m4 (gl_PHYSMEM):
8276         * m4/posixtm.m4 (gl_POSIXTM):
8277         * m4/posixver.m4 (gl_POSIXVER):
8278         * m4/quote.m4 (gl_QUOTE):
8279         * m4/quotearg.m4 (gl_QUOTEARG):
8280         * m4/readtokens.m4 (gl_READTOKENS):
8281         * m4/readutmp.m4 (gl_READUTMP):
8282         * m4/regex.m4 (gl_REGEX):
8283         * m4/safe-read.m4 (gl_SAFE_READ):
8284         * m4/safe-write.m4 (gl_SAFE_WRITE):
8285         * m4/same.m4 (gl_SAME):
8286         * m4/save-cwd.m4 (gl_SAVE_CWD):
8287         * m4/savedir.m4 (gl_SAVEDIR):
8288         * m4/settime.m4 (gl_SETTIME):
8289         * m4/sha1.m4 (gl_SHA1):
8290         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
8291         * m4/stat-macros.m4 (gl_STAT_MACROS):
8292         * m4/stat-time.m4 (gl_STAT_TIME):
8293         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
8294         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
8295         * m4/strdup.m4 (gl_FUNC_STRDUP):
8296         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
8297         * m4/strndup.m4 (gl_FUNC_STRNDUP):
8298         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
8299         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
8300         * m4/time_r.m4 (gl_TIME_R):
8301         * m4/timespec.m4 (gl_TIMESPEC):
8302         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
8303         * m4/unlinkdir.m4 (gl_UNLINKDIR):
8304         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
8305         * m4/userspec.m4 (gl_USERSPEC):
8306         * m4/utimecmp.m4 (gl_UTIMECMP):
8307         * m4/utimens.m4 (gl_UTIMENS):
8308         * m4/xalloc.m4 (gl_XALLOC):
8309         * m4/xgetcwd.m4 (gl_XGETCWD):
8310         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
8311         * m4/xreadlink.m4 (gl_XREADLINK):
8312         * m4/xstrtod.m4 (gl_XSTRTOD):
8313         * m4/yesno.m4 (gl_YESNO):
8314         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
8315         to get the necessary .h files and whatnot.
8316
8317 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
8318             Bruno Haible  <bruno@clisp.org>
8319
8320         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
8321         /bin/sh understanding of '!' conditional negation.
8322
8323 2006-08-21  Jim Meyering  <jim@meyering.net>
8324
8325         * modules/openat (Depends-on): Really alphabetize.
8326
8327         * modules/acl (Depends-on): Add error and quote.
8328
8329         * check-module (find_included_lib_files): Add at-func.c to the
8330         ok-to-include-more-than-once white list.
8331
8332         * modules/openat (Depends-on): Add lstat.  Alphabetize.
8333
8334 2006-08-21  Bruno Haible  <bruno@clisp.org>
8335
8336         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8337         Emit a pkgdata_DATA variable only if some snippets add contents to it.
8338         Reported by Martin Lambers <marlam@marlam.de>.
8339
8340 2006-08-21  Bruno Haible  <bruno@clisp.org>
8341
8342         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
8343         specify an installation location, don't emit a noinst_LIBRARIES or
8344         noinst_LTLIBRARIES assignment.
8345
8346 2006-08-21  Bruno Haible  <bruno@clisp.org>
8347
8348         BeOS portability.
8349         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
8350         BeOS has mbrtowc() but no <wctype.h>.
8351
8352 2006-08-21  Bruno Haible  <bruno@clisp.org>
8353
8354         BeOS portability.
8355         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
8356         exist.
8357
8358 2006-08-21  Bruno Haible  <bruno@clisp.org>
8359
8360         BeOS portability.
8361         * lib/mbchar.h: Include <wctype.h> only if it exists.
8362
8363 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8364
8365         Remove files that are no longer needed by their respective modules.
8366         * m4/obstack.m4: Remove.
8367         * m4/strerror_r.m4: Remove.
8368         * m4/uint32_t.m4: Remove.
8369         * m4/uintptr_t.m4: Remove.
8370         * m4/ullong_max.m4: Remove.
8371         * m4/xstrtoimax.m4: Remove.
8372         * m4/xstrtoumax.m4: Remove.
8373
8374         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
8375         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
8376         dependencies now capture this.
8377
8378         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
8379         Do not use AC_LIBSOURCES, since gnulib modules now do this.
8380         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
8381         * m4/human.m4 (gl_HUMAN): Likewise.
8382         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
8383         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
8384
8385         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
8386
8387         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
8388         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
8389         stdint.
8390         * m4/human.m4 (gl_HUMAN): Likewise.
8391         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
8392         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
8393         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
8394         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
8395         * m4/xstrtol (gl_XSTRTOL): Likewise.
8396
8397         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
8398         AC_TYPE_LONG_LONG_INT.
8399         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
8400         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
8401         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
8402         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
8403
8404         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
8405         on stdbool.
8406
8407         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
8408         (gl_PREREQ_XSTRTOUL): Remove.
8409
8410         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
8411
8412         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
8413         mode.
8414
8415 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8416
8417         Add and change modules to make it easier for coreutils to use
8418         gnulib-tool.
8419         * modules/backupfile (Files): Remove m4/d-ino.m4.
8420         (Depends-on): Add d-ino.
8421         * modules/cycle-check (Depends-on): Add stdint.
8422         (lib_SOURCES): Add cycle-check.h.
8423         * modules/d-ino: New module.
8424         * modules/d-type: New module.
8425         * modules/error (Files): Remove m4/strerror_r.m4.
8426         * modules/filemode (Files): Add m4/st_dm_mode.m4.
8427         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
8428         m4/inttypes_h.m4, m4/uintmax_t.m4.
8429         (Depends-on): Add stdint.
8430         (lib_SOURCES): Add fsusage.h.
8431         * modules/getcwd (Files): Remove d-ino.m4.
8432         (Depends-on): Add d-ino.
8433         * modules/getndelim2 (Depends-on): Add stdint.
8434         * modules/glob (Files): Remove m4/d-type.m4.
8435         (Depends-on): Add d-type.
8436         * modules/host-os: New module.
8437         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
8438         m4/inttypes_h.m4, m4/uintmax_t.m4.
8439         * Depends-on: Add stdint.
8440         (lib_SOURCES): Add human.h.
8441         * modules/inttostr (Files): Remove m4/intmax_t.m4,
8442         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
8443         m4/uintmax_t.m4, m4/ulonglong.m4.
8444         (Depends-on): Add stdint.
8445         (EXTRA_DIST): Add inttostr.h.
8446         * modules/lchmod: New module.
8447         * modules/link-follow: New module.
8448         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
8449         (Depends-on): Add lchmod.
8450         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
8451         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
8452         (Depends-on): Add stdint.
8453         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
8454         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
8455         (Depends-on): Add stdint.
8456         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
8457         * modules/perl: New module.
8458         * modules/regex (Depends-on): Add stdint.
8459         * modules/rmdir-errno: New module.
8460         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
8461         m4/intmax_t.m4.
8462         (Depends-on): Add stdint.
8463         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
8464         m4/uintmax_t.m4.
8465         (Depends-on): Add stdint.
8466         * modules/unlink-busy: New module.
8467         * modules/utimecmp (Depends-on): Add stdint.
8468         * modules/uptime: New module.
8469         * modules/winsz-ioctl: New module.
8470         * modules/winsz-termios: New module.
8471         * modules/xnanosleep (Depends-on): Add nanosleep.
8472         * modules/ullong_max: Remove.
8473         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
8474         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
8475         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
8476         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
8477         (Depends-on): Add inttypes.
8478         (lib_SOURCES): Add xstrtol.h.
8479         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
8480         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
8481         * MODULES.html.sh: Move 'assert' into the assert section.
8482         Move 'dummy' into the linking section.
8483         Remove ullong_max.
8484         Add section for compatibility checks for POSIX:2001 functions,
8485         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
8486         winsz-ioctl, and winsz-termios into it.
8487         Add lchmod.
8488         Add top-level Misc section and put host-os, perl, and uptime
8489         into it.
8490
8491 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8492
8493         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
8494         now assume the stdint module.  Do not include inttypes.h.
8495         * lib/fsusage.h: Likewise.
8496         * lib/getndelim2.c: Likewise.
8497         * lib/human.h: Likewise.
8498         * lib/inttostr.h: Likewise.
8499         * lib/obstack.c: Likewise.
8500         * lib/regex_internal.h: Likewise.
8501         * lib/tempname.c: Likewise.
8502         * lib/utimecmp.c: Likewise.
8503         * lib/xstrtol.h: Likewise.
8504
8505         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
8506
8507         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
8508         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
8509         * lib/xtime.h: Likewise.
8510
8511 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8512
8513         * modules/openat (Files): Add lib/fchmodat.c.
8514         Fixes problem reported by Jay Youngman.
8515
8516 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
8517
8518         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
8519         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
8520
8521 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
8522             Bruno Haible  <bruno@clisp.org>
8523
8524         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
8525         and is a script that invokes bison. Tighten the code. Add comments.
8526
8527 2006-08-18  Jim Meyering  <jim@meyering.net>
8528
8529         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
8530         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
8531         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
8532         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
8533
8534 2006-08-18  Bruno Haible  <bruno@clisp.org>
8535
8536         * modules/bison-i18n: New file.
8537         * MODULES.html.sh (Internationalization functions): Add it.
8538
8539 2006-08-18  Bruno Haible  <bruno@clisp.org>
8540
8541         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
8542         sys/statvfs.h. When getmntinfo was found, check its declaration and
8543         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
8544
8545 2006-08-18  Bruno Haible  <bruno@clisp.org>
8546
8547         * m4/bison-i18n.m4: New file, from bison.
8548
8549 2006-08-18  Bruno Haible  <bruno@clisp.org>
8550
8551         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
8552         (ME_DUMMY): Treat "kernfs" as a dummy.
8553         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
8554
8555 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
8556
8557         Update from coreutils.
8558
8559         2006-08-15  Jim Meyering  <jim@meyering.net>
8560
8561         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
8562
8563         2006-01-17  Jim Meyering  <jim@meyering.net>
8564
8565         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
8566
8567         2006-01-11  Jim Meyering  <jim@meyering.net>
8568
8569         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
8570         Check for the lchmod function.
8571
8572 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
8573
8574         Update from coreutils.
8575
8576         * lib/__fpending.h: Add copyright notice.
8577         * lib/fprintftime.h: Likewise.
8578         * lib/savedir.c: Use (C) in copyright notice.
8579         * lib/savedir.h: Likewise.
8580
8581         2006-08-15  Jim Meyering  <jim@meyering.net>
8582
8583         * lib/at-func.c: New file, with the logic of all emulated at-functions.
8584         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
8585         in support of the EXPECTED_ERRNO macro.
8586         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
8587         definitions.  Instead, define the appropriate symbols and include
8588         "at-func.c".
8589         * lib/mkdirat.c (mkdirat): Likewise.
8590         * lib/fchmodat.c (fchmodat): Likewise.
8591         (ENOSYS): Remove definition.
8592         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
8593         it.  Don't include "unistd--.h" -- it wasn't ever used.
8594
8595         2006-01-17  Jim Meyering  <jim@meyering.net>
8596
8597         Rewrite fts.c not to change the current working directory,
8598         by using openat, fstatat, fdopendir, etc..
8599
8600         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
8601         (HAVE_OPENAT_SUPPORT): Define.
8602         [_LIBC] (fchdir): Don't undef or define; no longer used.
8603         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
8604         Now, this `function' always succeeds, and consumes its file descriptor
8605         parameter -- so callers must not close such FDs.  Update callers.
8606         (diropen_fd, opendirat, cwd_advance_fd): New functions.
8607         (diropen): Add parameter, SP.  Adjust all callers.
8608         Implement using diropen_fd, rather than open.
8609         (fts_open): Initialize new member, fts_cwd_fd.
8610         Remove fts_rft-setting code.
8611         (fts_close): Close fts_cwd_fd, if necessary.
8612         (__opendir2): Define in terms of opendir or opendirat,
8613         depending on whether the FST_NOCHDIR flag is set.
8614         (fts_build): Since fts_safe_changedir consumes its FD, and since
8615         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
8616         and close the dup'd file descriptor upon failure.
8617         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
8618         (fts_safe_changedir): Tweak semantics to reflect that this function
8619         now calls cwd_advance_fd and hence consumes its FD argument.
8620         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
8621         [struct FTS] (fts_rft): Remove now-unused member.
8622         [struct FTS] (fts_cycle.state): Improve comment.
8623
8624         * lib/openat.c (openat_needs_fchdir): New function.
8625         * lib/openat.h (openat_needs_fchdir): Declare it.
8626
8627 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
8628
8629         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
8630         Problem and fix reported by Pádraig Brady in
8631         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
8632
8633 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8634
8635         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
8636
8637 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8638
8639         * lib/memcoll.c (memcoll): Optimize for the common case where the
8640         arguments are bytewise equal.
8641
8642 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8643
8644         * doc/regexprops-generic.texi: Add a copyright notice.
8645
8646 2006-08-15  Bruno Haible  <bruno@clisp.org>
8647
8648         * modules/tmpdir (License): Change to LGPL.
8649
8650 2006-08-15  Bruno Haible  <bruno@clisp.org>
8651
8652         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
8653         module.
8654
8655 2006-08-14  Simon Josefsson  <jas@extundo.com>
8656
8657         * config/srclist.txt: Add gnupload.
8658
8659 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8660
8661         Change copyright notice from LGPL 2 to GPL 2, since that's the
8662         standard form used in the gnulib repository.
8663         * tests/test-lock.c: Likewise.
8664         * tests/test-stdint.c: Likewise.
8665         * tests/test-tls.c: Likewise.
8666
8667         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
8668         prelude-manager.  User shorter URLs for GNU projects, without '?'.
8669         Add copyright notice.
8670
8671         * check-module: Add copyright notice.  Output a copyright
8672         notice if "--version" is specified.
8673         * modules/COPYING: New file.
8674         * tests/test-getaddrinfo.c: Add copyright notice.
8675         * tests/test-verify.c: Likewise.
8676
8677 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8678
8679         Change copyright notice from LGPL 2 to GPL 2, since that's the
8680         standard form used in the gnulib repository.
8681         * lib/lock.c: LGPL -> GPL.
8682         * lib/lock.h: Likewise.
8683         * lib/strnlen1.c: Likewise.
8684         * lib/strnlen1.h: Likewise.
8685         * lib/tls.c: Likewise.
8686         * lib/tls.h: Likewise.
8687         * lib/tmpdir.c: Likewise.
8688
8689         * lib/TODO: Remove; this belongs only in coreutils.
8690
8691 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8692
8693         Add copyright notices to long-enough files that lack them, since
8694         otherwise the files aren't clearly free.  Use the same notice that
8695         getdate.texi already uses.
8696         * doc/alloca-opt.texi: Add copyright notice.
8697         * doc/alloca.texi: Likewise.
8698         * doc/ctime.texi: Likewise.
8699         * doc/functions.texi: Likewise.
8700         * doc/gcd.texi: Likewise.
8701         * doc/gnulib-tool.texi: Likewise.
8702         * doc/inet_ntoa.texi: Likewise.
8703         * doc/visibility.texi: Likewise.
8704
8705         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
8706         * doc/quote.texi: Add copyright notice.
8707
8708         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
8709         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
8710         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
8711         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
8712         is now obsolete, and give a pointer to the Sun list.
8713         Add copyright notice.
8714
8715 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
8716
8717         * config/srclistvars.sh: Add copyright notice.
8718
8719 2006-08-14  Eric Blake  <ebb9@byu.net>
8720
8721         Import the following change from libc:
8722
8723         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
8724
8725         Upstream bug 2997.
8726         * lib/misc/error.c: Add space between program name and message if file
8727         name is missing.
8728
8729 2006-08-12  Karl Berry  <karl@gnu.org>
8730
8731         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
8732         remove, these originate in gnulib now.
8733
8734 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8735
8736         * doc/Makefile (standards.info standards.html standards.dvi):
8737         Also depend on make-stds.texi.
8738
8739 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
8740
8741         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
8742         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
8743
8744         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
8745         in wchar_t.  Problem reported by Eric Blake.
8746
8747         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
8748         LEN is smaller than SIZE.  Suggested by Bruno Haible.
8749         Also, help the compiler to keep LEN in a register.
8750
8751 2006-08-11  Eric Blake  <ebb9@byu.net>
8752
8753         * users.txt: Sort.  Add tar.
8754
8755 2006-08-11  Bruno Haible  <bruno@clisp.org>
8756
8757         * users.txt: New file.
8758
8759 2006-08-11  Bruno Haible  <bruno@clisp.org>
8760
8761         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
8762         before <wchar.h>. Needed for OSF/1 and BSD/OS.
8763
8764 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
8765
8766         * modules/snprintf (Depends-on): Remove minmax.
8767         (Maintainer): Add self and Bruno.
8768
8769 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
8770
8771         * lib/.cppi-disable: Add snprintf.h, socket_.h.
8772         * lib/snprintf.c: Include <errno.h> and <limits.h>.
8773         (EOVERFLOW): Define if the system does not.
8774         Do not include "minmax.h"; it wasn't used.
8775         (snprintf): Don't assume size_t promotes to an unsigned type.
8776         Fix bug when generated string was too long for the buffer: the
8777         buffer's contents are supposed to be the initial prefix of the
8778         output.  Don't assume vasnprintf returns EOVERFLOW if the size
8779         exceeds INT_MAX; do the check ourselves.
8780
8781         Import the following changes from libc:
8782
8783         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
8784
8785         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
8786         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
8787         set wc to the byte which couldn't be converted.
8788         (re_string_reconstruct): Don't clear valid_raw_len before calling
8789         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
8790         tip_context using re_string_context_at.
8791
8792         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
8793
8794         * lib/posix/regex.h: g++ still cannot handled [restrict].
8795
8796         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
8797
8798         * lib/posix/regex.h: Remove special handling for VMS.
8799
8800 2006-08-10  Jim Meyering  <jim@meyering.net>
8801
8802         * modules/same-inode: New module.
8803         * modules/dev-ino: New module.
8804         * modules/cycle-check: Depend on these modules, rather than simply
8805         including their .h files.
8806         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
8807         required via m4/cycle-check.m4.
8808         * modules/same: Depend on new same-inode module, rather than
8809         including same-inode.h.
8810         * modules/chdir-safer: New file.
8811
8812         * modules/chown (Depends-on): Add stat-macros.
8813
8814 2006-08-10  Jim Meyering  <jim@meyering.net>
8815
8816         * m4/cycle-check.m4: New file.
8817         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
8818         * m4/dev-ino.m4, m4/same-inode.m4: New files.
8819
8820 2006-08-10  Eric Blake  <ebb9@byu.net>
8821
8822         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
8823         in from original proposal.
8824
8825 2006-08-10  Eric Blake  <ebb9@byu.net>
8826         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
8827
8828         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
8829         namespace.
8830
8831 2006-08-10  Bruno Haible  <bruno@clisp.org>
8832
8833         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
8834         as well.
8835
8836 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8837
8838         Sync from coreutils.
8839
8840         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
8841
8842         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
8843         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
8844
8845 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8846
8847         * modules/restrict: Remove; no longer needed now that we assume
8848         Autoconf 2.59 or later.
8849         * MODULES.html.sh: Remove 'restrict'.
8850         * modules/argp (Depends-on): Remove 'restrict'.
8851         * modules/base64 (Depends-on): Likewise.
8852         * modules/gc (Depends-on): Likewise.
8853         * modules/getaddrinfo (Depends-on): Likewise.
8854         * modules/glob (Depends-on): Likewise.
8855         * modules/inet_ntop (Depends-on): Likewise.
8856         * modules/inet_pton (Depends-on): Likewise.
8857         * modules/memxor (Depends-on): Likewise.
8858         * modules/regex (Depends-on): Likewise.
8859         * modules/strtok_r (Depends-on): Likewise.
8860         * modules/time_r (Depends-on): Likewise.
8861
8862 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
8863
8864         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
8865         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
8866         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
8867         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
8868         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
8869         * m4/memxor.m4 (gl_MEMXOR): Likewise.
8870         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
8871         gl_C_RESTRICT replaced by AC_C_RESTRICT.
8872
8873         Merge from coreutils.
8874         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
8875         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
8876         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
8877         * m4/time_r.m4 (gl_TIME_R): Likewise.
8878
8879 2006-08-09  Karl Berry  <karl@gnu.org>
8880
8881         * config/srclist.txt: no more gettext-tools, per Bruno.
8882
8883 2006-08-08  Eric Blake  <ebb9@byu.net>
8884
8885         * modules/verror: New module.
8886         * MODULES.html.sh: Document it.
8887
8888 2006-08-08  Eric Blake  <ebb9@byu.net>
8889
8890         * lib/verror.h, lib/verror.c: New files.
8891
8892 2006-08-08  Eric Blake  <ebb9@byu.net>
8893
8894         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
8895         verror_at_line output complies with GNU Coding Standards even when
8896         file is NULL.
8897
8898 2006-08-07  Bruno Haible  <bruno@clisp.org>
8899
8900         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
8901         versions of AIX.
8902         Reported by Ralf Wildenhues.
8903
8904 2006-08-07  Bruno Haible  <bruno@clisp.org>
8905
8906         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
8907         in an AC_DEFUN. Needed so that the autoconf snippets can use
8908         AC_REQUIRE.
8909
8910 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8911
8912         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8913         Initialize pkgdata_DATA.
8914         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
8915         overriding it.
8916
8917 2006-08-06  Eric Blake  <ebb9@byu.net>
8918
8919         * lib/error.h: Fold in some upstream changes from glibc.
8920         * lib/error.c: Likewise.
8921
8922 2006-08-04  Bruno Haible  <bruno@clisp.org>
8923
8924         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8925         Make the mostlyclean-local rule depend on mostlyclean-generic.
8926         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
8927
8928 2006-07-31  Bruno Haible  <bruno@clisp.org>
8929
8930         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
8931         <stdlib.h>, <string.h>.
8932
8933 2006-07-30  Bruno Haible  <bruno@clisp.org>
8934
8935         * modules/readlink (License): Change to LGPL.
8936
8937 2006-07-30  Bruno Haible  <bruno@clisp.org>
8938
8939         * modules/javaversion (Makefile.am): Distribute javaversion.java and
8940         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
8941         set PKGDATADIR to point to it.
8942
8943 2006-07-30  Bruno Haible  <bruno@clisp.org>
8944
8945         * modules/csharpexec (configure.ac): Comment out macro invocation.
8946         * modules/javaexec (configure.ac): Likewise.
8947         * modules/javacomp-script (configure.ac): Likewise.
8948
8949         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
8950
8951 2006-07-30  Bruno Haible  <bruno@clisp.org>
8952
8953         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
8954         linked-list.
8955
8956 2006-07-30  Bruno Haible  <bruno@clisp.org>
8957
8958         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
8959
8960 2006-07-30  Bruno Haible  <bruno@clisp.org>
8961
8962         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8963         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
8964         get removed.
8965
8966 2006-07-29  Bruno Haible  <bruno@clisp.org>
8967
8968         Make it possible for gnulib-tool to work with locally modified or
8969         augmented gnulib repositories.
8970         * gnulib-tool (func_usage): Document --local-dir option.
8971         (local_gnulib_dir): New variable.
8972         Handle --local-dir option.
8973         (func_lookup_file): New function.
8974         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
8975         (func_get_description, func_get_filelist, func_get_description,
8976         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
8977         func_get_automake_snippet, func_get_include_directive,
8978         func_get_license, func_get_maintainer): Use func_lookup_file.
8979         (func_import, func_create_testdir): Use func_lookup_file.
8980
8981 2006-07-29  Bruno Haible  <bruno@clisp.org>
8982
8983         * modules/setenv (Depends-on): Add unistd.
8984
8985 2006-07-29  Bruno Haible  <bruno@clisp.org>
8986
8987         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
8988
8989 2006-07-29  Bruno Haible  <bruno@clisp.org>
8990
8991         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
8992
8993 2006-07-29  Bruno Haible  <bruno@clisp.org>
8994
8995         * gnulib-tool (import, update): If there is no Makefile.am, look at
8996         aclocal.m4, instead of bailing out.
8997
8998 2006-07-29  Bruno Haible  <bruno@clisp.org>
8999
9000         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
9001         Categorize the options by when they are useful.
9002
9003 2006-07-29  Bruno Haible  <bruno@clisp.org>
9004
9005         * gnulib-tool (func_usage): Document option --no-libtool.
9006         Handle option --no-libtool.
9007         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
9008         for changed semantics of $libtool variable.
9009         (func_import): Likewise. If libtool is not used, show this through
9010         an option --no-libtool.
9011         (func_create_testdir): Update.
9012
9013 2006-07-29  Bruno Haible  <bruno@clisp.org>
9014
9015         * gnulib-tool (func_import): Extend error message about missing
9016         --doc-base.
9017
9018 2006-07-29  Bruno Haible  <bruno@clisp.org>
9019
9020         * gnulib-tool (func_import): Don't create the $docbase directory if
9021         there is no file to store there.
9022
9023 2006-07-29  Bruno Haible  <bruno@clisp.org>
9024
9025         * gnulib-tool (autoconf_minversion): If a --dir option is given and
9026         relevant, look for configure.ac there, not in the current directory.
9027         Also use a simple search for AC_PREREQ, not "autoconf --trace".
9028
9029 2006-07-29  Bruno Haible  <bruno@clisp.org>
9030
9031         * gnulib-tool (SORT): New variable.
9032         (func_usage): Undocument --assume-autoconf option.
9033         Remove --assume-autoconf option handling.
9034         (autoconf_minversion): Determine from the contents of configure.ac.
9035         (func_import): Remove autoconf_minversion handling.
9036         Suggested by Eric Blake.
9037
9038 2006-07-29  Bruno Haible  <bruno@clisp.org>
9039
9040         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
9041
9042 2006-07-29  Bruno Haible  <bruno@clisp.org>
9043
9044         * config/srclist.txt (*setenv.[ch]): Remove rules.
9045
9046 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9047
9048         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
9049
9050 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9051
9052         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
9053         arpa/inet.h.
9054
9055 2006-07-28  Simon Josefsson  <jas@extundo.com>
9056
9057         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
9058         * modules/inet_pton (Depends-on): Likewise.
9059
9060 2006-07-28  Simon Josefsson  <jas@extundo.com>
9061
9062         * m4/netinet_in_h.m4: New file.
9063
9064 2006-07-28  Simon Josefsson  <jas@extundo.com>
9065
9066         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
9067         #include's.
9068
9069 2006-07-28  Simon Josefsson  <jas@extundo.com>
9070
9071         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
9072         #include's.
9073
9074 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
9075
9076         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
9077         setgid on directories only if they set these bits.
9078         * lib/modechange.h: Remove obsolete comment about masks.
9079
9080 2006-07-28  Eric Blake  <ebb9@byu.net>
9081
9082         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
9083         macro expansion.
9084
9085 2006-07-28  Bruno Haible  <bruno@clisp.org>
9086
9087         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
9088
9089 2006-07-28  Bruno Haible  <bruno@clisp.org>
9090
9091         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
9092
9093 2006-07-28  Bruno Haible  <bruno@clisp.org>
9094
9095         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
9096         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
9097         Define fallbacks.
9098         Avoids link error on FreeBSD 4.x.
9099         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
9100
9101         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
9102         encoding.
9103         * lib/mbswidth.c (iswcntrl): Likewise.
9104
9105 2006-07-27  Bruno Haible  <bruno@clisp.org>
9106
9107         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
9108         test.
9109
9110 2006-07-27  Bruno Haible  <bruno@clisp.org>
9111
9112         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
9113         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
9114         defined.
9115
9116 2006-07-26  Eric Blake  <ebb9@byu.net>
9117
9118         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
9119
9120 2006-07-26  Eric Blake  <ebb9@byu.net>
9121
9122         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
9123         like mingw that lack mkstemp.
9124         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
9125         avoid compilation warning on mingw.
9126
9127 2006-07-26  Bruno Haible  <bruno@clisp.org>
9128
9129         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
9130         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
9131         INT_FAST*_MIN, INTPTR_MIN.
9132
9133 2006-07-25  Bruno Haible  <bruno@clisp.org>
9134
9135         * modules/version-etc (Depends-on): Add stdarg.
9136
9137 2006-07-25  Bruno Haible  <bruno@clisp.org>
9138
9139         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
9140         complex commands.
9141
9142 2006-07-25  Bruno Haible  <bruno@clisp.org>
9143
9144         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
9145         defined in <stdarg.h> or config.h.
9146
9147 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9148
9149         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
9150         (gl_STDIO_SAFER): Remove.
9151
9152 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9153
9154         * MODULES.html.sh (File stream based Input/Output):
9155         Add fopen-safer, tmpfile-safer; remove stdio-safer.
9156         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
9157         * modules/fopen-safer, modules/tmpfile-safer: New files.
9158         * modules/stdio-safer: Remove.
9159
9160 2006-07-24  Bruno Haible  <bruno@clisp.org>
9161
9162         * modules/tmpdir: New file.
9163         * MODULES.html.sh (File system functions): Add it.
9164
9165 2006-07-24  Bruno Haible  <bruno@clisp.org>
9166
9167         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
9168         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
9169
9170 2006-07-24  Bruno Haible  <bruno@clisp.org>
9171
9172         * modules/clean-temp: New file.
9173
9174 2006-07-24  Bruno Haible  <bruno@clisp.org>
9175
9176         * m4/tmpdir.m4: New file, from GNU gettext.
9177
9178 2006-07-24  Bruno Haible  <bruno@clisp.org>
9179
9180         * lib/tmpdir.h: New file, from GNU gettext.
9181         * lib/tmpdir.c: New file, from GNU gettext.
9182
9183 2006-07-24  Bruno Haible  <bruno@clisp.org>
9184
9185         * lib/clean-temp.h: New file, from GNU gettext.
9186         * lib/clean-temp.c: New file, from GNU gettext.
9187
9188 2006-07-23  Eric Blake  <ebb9@byu.net>
9189
9190         * modules/stdio-safer (Files): Add tmpfile-safer.c.
9191         (Depends-on): Add binary-io.
9192
9193 2006-07-23  Eric Blake  <ebb9@byu.net>
9194
9195         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
9196
9197 2006-07-23  Eric Blake  <ebb9@byu.net>
9198
9199         * lib/tmpfile-safer.c: New file.
9200         * lib/stdio-safer.h (fopen_safer): Add prototype.
9201         * lib/stdio--.h (tmpfile): Make safer.
9202
9203 2006-07-23  Bruno Haible  <bruno@clisp.org>
9204
9205         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
9206         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
9207         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
9208         gl_linked_remove_at): Use it.
9209
9210 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9211         and Simon Josefsson <jas@extundo.com>
9212
9213         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
9214
9215         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
9216
9217 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9218
9219         * modules/close-stream: New file.
9220         * modules/closeout (Description): Make it clear that it exits
9221         with a diagnostic on error.
9222         (Depends-on): Add close-stream.  Remove fpending, stdbool.
9223         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
9224
9225 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9226
9227         * m4/close-stream.m4: New file.
9228
9229 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9230
9231         * lib/close-stream.c, lib/close-stream.h: New files.
9232
9233 2006-07-22  Bruno Haible  <bruno@clisp.org>
9234
9235         Merge from GNU gettext 0.15.
9236
9237         2006-05-01  Bruno Haible  <bruno@clisp.org>
9238
9239                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
9240
9241         2006-07-22  Bruno Haible  <bruno@clisp.org>
9242
9243                 * modules/javaversion: New file.
9244                 * MODULES.html.sh (Java): Add javaversion.
9245
9246         2006-03-12  Bruno Haible  <bruno@clisp.org>
9247
9248                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
9249
9250         2005-12-04  Bruno Haible  <bruno@clisp.org>
9251
9252                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
9253                 (untested).
9254
9255         2006-06-21  Bruno Haible  <bruno@clisp.org>
9256
9257                 Avoid warnings from recent versions of mcs.
9258                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
9259                 -o, -L, -r any more. Use options documented since mcs-1.0
9260                 instead. Similarly for -g.
9261
9262         2005-12-04  Bruno Haible  <bruno@clisp.org>
9263
9264                 * build-aux/csharpcomp.sh.in: Suffix for resources is
9265                 .resources, not .resource.
9266
9267         2005-07-09  Bruno Haible  <bruno@clisp.org>
9268
9269                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
9270                 add a .dll suffix.
9271                 Reported by Mark Junker <mjscod@gmx.de>.
9272
9273         2006-07-22  Bruno Haible  <bruno@clisp.org>
9274
9275                 * modules/gettext: Upgrade to gettext-0.15.
9276                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
9277                 m4/visibility.m4.
9278                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
9279
9280 2006-07-22  Bruno Haible  <bruno@clisp.org>
9281
9282         Merge from GNU gettext 0.15.
9283
9284         2006-03-25  Bruno Haible  <bruno@clisp.org>
9285
9286                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
9287
9288         2006-07-21  Bruno Haible  <bruno@clisp.org>
9289
9290                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
9291                 "1.1".
9292
9293         2006-05-09  Bruno Haible  <bruno@clisp.org>
9294
9295                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
9296                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
9297                 for the conftestver execution.
9298
9299         2006-05-01  Bruno Haible  <bruno@clisp.org>
9300
9301                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
9302                 optional target-version argument. Verify that the compiler
9303                 groks source of the specified source-version, or add -source
9304                 option as necessary. Verify that the compiler produces
9305                 bytecode in the specified target-version, or add -target and
9306                 -source options as necessary. Make the result of the test
9307                 available as variable CONF_JAVAC. Also log error output in
9308                 config.log.
9309
9310         2006-03-11  Bruno Haible  <bruno@clisp.org>
9311
9312                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
9313
9314         2006-05-09  Bruno Haible  <bruno@clisp.org>
9315
9316                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
9317                 CLASSPATH_SEPARATOR to a semicolon.
9318
9319         2006-03-12  Bruno Haible  <bruno@clisp.org>
9320
9321                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
9322                 available as variable CONF_JAVA, for subsequent autoconf
9323                 tests. Also log error output in config.log.
9324
9325         2006-07-19  Bruno Haible  <bruno@clisp.org>
9326
9327                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
9328                 that getline works on glibc2 systems. Needed to avoid trouble
9329                 in relocatable.c.
9330                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
9331
9332         2005-12-04  Bruno Haible  <bruno@clisp.org>
9333
9334                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
9335                 launcher (untested).
9336
9337         2005-12-04  Bruno Haible  <bruno@clisp.org>
9338
9339                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
9340
9341         2006-07-22  Bruno Haible  <bruno@clisp.org>
9342
9343                 * gettext.m4: Update from GNU gettext-0.15.
9344                 * nls.m4: Likewise.
9345                 * po.m4: Likewise.
9346                 * inttypes-pri.m4: Likewise.
9347                 * inttypes-h.m4: Renamed from inttypes.m4.
9348                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
9349
9350 2006-07-22  Bruno Haible  <bruno@clisp.org>
9351
9352         Merge from GNU gettext 0.15.
9353
9354         2005-07-05  Bruno Haible  <bruno@clisp.org>
9355
9356                 * printf-args.c (printf_fetchargs): Work around broken
9357                 definition of wint_t on mingw.
9358
9359         2005-02-12  Bruno Haible  <bruno@clisp.org>
9360
9361                 * xallocsa.h: Add extern "C" for C++.
9362
9363         2006-05-17  Bruno Haible  <bruno@clisp.org>
9364
9365                 Cygwin portability.
9366                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
9367
9368         2006-04-30  Bruno Haible  <bruno@clisp.org>
9369
9370                 * progreloc.c: Include <mach-o/dyld.h> if available.
9371                 (find_executable): Use _NSGetExecutablePath when possible.
9372
9373         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9374
9375                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
9376                 function.
9377
9378         2005-12-29  Bruno Haible  <bruno@clisp.org>
9379
9380                 * progreloc.c (set_program_name_and_installdir): Fix
9381                 compilation error.
9382
9383         2005-12-04  Bruno Haible  <bruno@clisp.org>
9384
9385                 Cygwin portability.
9386                 * progreloc.c: Include <windows.h> also on Cygwin.
9387                 (find_executable): Add support for Cygwin.
9388                 (set_program_name_and_installdir): Handle also platforms with
9389                 nonempty EXEEXT.
9390
9391         2006-07-11  Bruno Haible  <bruno@clisp.org>
9392
9393                 * javacomp.c: Fix a comment.
9394                 Reported by Jim Meyering.
9395
9396         2006-04-30  Bruno Haible  <bruno@clisp.org>
9397
9398                 * javacomp.h (compile_java_class): Add source_version,
9399                 target_version arguments.
9400                 * javacomp.c: Rewritten to choose only a compiler that
9401                 respects the specified source_version and target_version.
9402
9403         2006-06-27  Bruno Haible  <bruno@clisp.org>
9404
9405                 Assume correct S_ISDIR macro.
9406                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
9407
9408         2006-07-22  Bruno Haible  <bruno@clisp.org>
9409
9410                 * javaversion.h: New file, from GNU gettext.
9411                 * javaversion.c: New file, from GNU gettext.
9412                 * javaversion.java: New file, from GNU gettext.
9413                 * javaversion.class: New file, from GNU gettext.
9414
9415         2006-05-17  Bruno Haible  <bruno@clisp.org>
9416
9417                 Cygwin portability.
9418                 * javaexec.c (execute_java_class): Test for jview program
9419                 also on Cygwin.
9420
9421         2006-04-09  Bruno Haible  <bruno@clisp.org>
9422
9423                 * fatal-signal.c: Don't include string.h.
9424                 (at_fatal_signal): Use a copying loop instead of memcpy.
9425
9426         2005-12-04  Bruno Haible  <bruno@clisp.org>
9427
9428                 * csharpexec.c: Add support for 'clix' launcher (untested).
9429                 (execute_csharp_using_sscli): New function.
9430                 (execute_csharp_program): Call it.
9431
9432         2006-06-21  Bruno Haible  <bruno@clisp.org>
9433
9434                 Avoid warnings from recent versions of mcs.
9435                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
9436                 -o, -L, -r any more. Use options documented since mcs-1.0
9437                 instead. Similarly for -g.
9438
9439         2005-07-09  Bruno Haible  <bruno@clisp.org>
9440
9441                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
9442                 add a .dll suffix.
9443                 Reported by Mark Junker <mjscod@gmx.de>.
9444
9445         2006-06-17  Bruno Haible  <bruno@clisp.org>
9446
9447                 * config.charset: Update for NetBSD 3.0.
9448
9449         2006-05-17  Bruno Haible  <bruno@clisp.org>
9450
9451                 Cygwin portability.
9452                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
9453
9454         2006-05-16  Bruno Haible  <bruno@clisp.org>
9455
9456                 * localcharset.c [CYGWIN]: Include <windows.h>.
9457                 (get_charset_aliases): For Cygwin, return the same CPxxx
9458                 aliases list as under WIN32.
9459                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
9460                 the environment variables. Fall back to GetACP().
9461
9462         2006-04-05  Bruno Haible  <bruno@clisp.org>
9463
9464                 * config.charset: Update Juan Manuel Guerrero's address.
9465
9466         2005-02-12  Bruno Haible  <bruno@clisp.org>
9467
9468                 * allocsa.h: Add extern "C" for C++.
9469
9470         2005-02-10  Bruno Haible  <bruno@clisp.org>
9471
9472                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
9473                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
9474
9475         2006-07-22  Bruno Haible  <bruno@clisp.org>
9476
9477                 * gettext.h: Update to GNU gettext-0.15.
9478
9479 2006-07-22  Bruno Haible  <bruno@clisp.org>
9480
9481         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
9482         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
9483         lib-prefix.m4, longdouble.m4, ssize_t.m4.
9484
9485 2006-07-21  Eric Blake  <ebb9@byu.net>
9486
9487         * modules/stdlib-safer: New file.
9488         * MODULES.html.sh (File stream based Input/Output): Add
9489         stdlib-safer.
9490
9491 2006-07-21  Eric Blake  <ebb9@byu.net>
9492
9493         * lib/stdlib-safer.h: New file from coreutils, required by
9494         stdlib--.h.
9495
9496 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
9497
9498         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
9499
9500 2006-07-20  Bruno Haible  <bruno@clisp.org>
9501
9502         * gnulib-tool: Recognize new option --assume-autoconf.
9503         (autoconf_minversion): New variable.
9504         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
9505
9506 2006-07-20  Bruno Haible  <bruno@clisp.org>
9507
9508         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
9509
9510 2006-07-19  Derek R. Price  <derek@ximbiot.com>
9511
9512         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
9513         Reindent and repaginate.
9514
9515 2006-07-19  Derek Price  <derek@ximbiot.com>
9516
9517         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
9518         Correct grammar.
9519
9520 2006-07-17  Bruno Haible  <bruno@clisp.org>
9521
9522         * modules/list: New file.
9523         * modules/array-list: New file.
9524         * modules/carray-list, modules/carray-list-tests: New files.
9525         * modules/linked-list, modules/linked-list-tests: New files.
9526         * modules/avltree-list, modules/avltree-list-tests: New files.
9527         * modules/rbtree-list, modules/rbtree-list-tests: New files.
9528         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
9529         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
9530         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
9531         * modules/oset: New file.
9532         * modules/array-oset: New file.
9533         * modules/avltree-oset, modules/avltree-oset-tests: New files.
9534         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
9535         * tests/test-carray_list.c: New file.
9536         * tests/test-linked_list.c: New file.
9537         * tests/test-avltree_list.c: New file.
9538         * tests/test-rbtree_list.c: New file.
9539         * tests/test-linkedhash_list.c: New file.
9540         * tests/test-avltreehash_list.c: New file.
9541         * tests/test-rbtreehash_list.c: New file.
9542         * tests/test-avltree_oset.c: New file.
9543         * tests/test-rbtree_oset.c: New file.
9544         * MODULES.html.sh (Container data structures): New section.
9545
9546 2006-07-17  Bruno Haible  <bruno@clisp.org>
9547
9548         * m4/gl_list.m4: New file.
9549
9550 2006-07-17  Bruno Haible  <bruno@clisp.org>
9551
9552         * lib/gl_list.h: New file.
9553         * lib/gl_list.c: New file.
9554         * lib/gl_array_list.h: New file.
9555         * lib/gl_array_list.c: New file.
9556         * lib/gl_carray_list.h: New file.
9557         * lib/gl_carray_list.c: New file.
9558         * lib/gl_linked_list.h: New file.
9559         * lib/gl_linked_list.c: New file.
9560         * lib/gl_anylinked_list1.h: New file.
9561         * lib/gl_anylinked_list2.h: New file.
9562         * lib/gl_avltree_list.h: New file.
9563         * lib/gl_avltree_list.c: New file.
9564         * lib/gl_anyavltree_list1.h: New file.
9565         * lib/gl_anyavltree_list2.h: New file.
9566         * lib/gl_rbtree_list.h: New file.
9567         * lib/gl_rbtree_list.c: New file.
9568         * lib/gl_anyrbtree_list1.h: New file.
9569         * lib/gl_anyrbtree_list2.h: New file.
9570         * lib/gl_anytree_list1.h: New file.
9571         * lib/gl_anytree_list2.h: New file.
9572         * lib/gl_linkedhash_list.h: New file.
9573         * lib/gl_linkedhash_list.c: New file.
9574         * lib/gl_anyhash_list1.h: New file.
9575         * lib/gl_anyhash_list2.h: New file.
9576         * lib/gl_avltreehash_list.h: New file.
9577         * lib/gl_avltreehash_list.c: New file.
9578         * lib/gl_rbtreehash_list.h: New file.
9579         * lib/gl_rbtreehash_list.c: New file.
9580         * lib/gl_anytreehash_list1.h: New file.
9581         * lib/gl_anytreehash_list2.h: New file.
9582
9583         * lib/gl_oset.h: New file.
9584         * lib/gl_oset.c: New file.
9585         * lib/gl_array_oset.h: New file.
9586         * lib/gl_array_oset.c: New file.
9587         * lib/gl_avltree_oset.h: New file.
9588         * lib/gl_avltree_oset.c: New file.
9589         * lib/gl_rbtree_oset.h: New file.
9590         * lib/gl_rbtree_oset.c: New file.
9591         * lib/gl_anytree_oset.h: New file.
9592
9593 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9594
9595         * m4/mkancesdirs.m4: New file.
9596         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
9597         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
9598         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
9599         it.
9600
9601 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9602
9603         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
9604         * lib/mkancesdirs.h: New files.
9605         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
9606         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
9607         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
9608         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
9609         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
9610         callers changed.  Revamp internals significantly, by not
9611         attempting to create directories that are temporarily more
9612         permissive than the final results.  Do not attempt to use
9613         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
9614         This removes some race conditions, fixes some bugs, and simplifies
9615         things.  Use new dirchownmod function to do owner and mode changes.
9616         * lib/mkdir-p.h: Likewise.
9617         * lib/modechange.c (octal_to_mode): New function.
9618         (struct mode_change): New member mentioned.
9619         (make_node_op_equals): New arg mentioned.  All callers changed.
9620         (mode_compile): Keep track of which mode bits the user has explicitly
9621         mentioned.
9622         (mode_adjust): New arg DIR, so that we implement the X op correctly.
9623         New arg PMODE_BITS, to keep track of which mode bits the user
9624         mentioned; it treats S_ISUID and S_ISGID speciall.
9625         All callers changed.
9626         * lib/modechange.h: Likewise.
9627
9628 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
9629
9630         * MODULES.html.sh: Add mkancestors.
9631         * modules/mkancesdirs: New module.
9632         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
9633         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
9634         The chdir-safer and afs files are now orphans; I'll remove them
9635         unless someone speaks up.
9636         Add lib/dirchownmod.c, lib/dirchownmod.h.
9637         (Depends-on): Remove alloca, chown, save-cwd, dirname.
9638         Add lchown, mkancesdirs.
9639         (Maintainer): Add self.
9640
9641 2006-07-15  Karl Berry  <karl@gnu.org>
9642
9643         * gnulib-tool: help message wording/arrangement.
9644
9645 2006-07-14  Simon Josefsson  <jas@extundo.com>
9646
9647         * doc/gnulib.texi (Libtool and Windows): New section.
9648
9649 2006-07-12  Simon Josefsson  <jas@extundo.com>
9650
9651         * modules/gendocs (License): Fix license, approved by Karl.
9652
9653 2006-07-12  Eric Blake  <ebb9@byu.net>
9654
9655         * MODULES.html.sh: Add gendocs.
9656
9657 2006-07-11  Eric Blake  <ebb9@byu.net>
9658
9659         * modules/fdl: New module, to install doc/fdl.texi.
9660         * MODULES.html.sh: Add new section for documentation modules.
9661         * gnulib-tool: Avoid space-tab.
9662         (--doc-base): New option, to manage files from doc.
9663
9664 2006-07-11  Eric Blake  <ebb9@byu.net>
9665
9666         * m4/absolute-header.m4: Fix comments to match recent change.
9667
9668 2006-07-11  Eric Blake  <ebb9@byu.net>
9669
9670         * gnulib-tool: List --doc-base before --tests-base.
9671
9672 2006-07-11  Derek R. Price  <derek@ximbiot.com>
9673
9674         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
9675
9676 2006-07-11  Bruno Haible  <bruno@clisp.org>
9677
9678         * README: Mention where to put documentation.
9679
9680 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9681
9682         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
9683
9684 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
9685
9686         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
9687         to stdint.m4.
9688
9689 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
9690
9691         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
9692         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
9693         "no/such/file/stdint.h" when there is no such file, so that
9694         the resulting C code can be parsed by dodgy compilers.
9695         Problems reported by Bob Proulx.
9696
9697 2006-07-10  Derek R. Price  <derek@ximbiot.com>
9698
9699         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
9700         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
9701         macros into the GNU _D_EXACT_NAMLEN.
9702         * lib/savedir.c:  Likewise.
9703         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
9704
9705 2006-07-10  Derek R. Price  <derek@ximbiot.com>
9706         and Paul Eggert  <eggert@cs.ucla.edu>
9707
9708         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
9709         * m4/savedir.m4:
9710         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
9711         macros into the GNU _D_EXACT_NAMLEN.
9712
9713 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9714
9715         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
9716         around the absolute name, to work around a problem with the HP-UX
9717         11.23 native C compiler, reported by Bob Proulx.
9718
9719 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9720
9721         * doc/maintain.texi, make-stds.texi: Sync from
9722         <http://savannah.gnu.org/projects/gnustandards>.
9723
9724 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
9725
9726         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
9727
9728 2006-07-09  Jim Meyering  <jim@meyering.net>
9729
9730         * m4/glob.m4: Remove a doubled word in a comment.
9731
9732 2006-07-09  Jim Meyering  <jim@meyering.net>
9733
9734         * lib/argp-pv.c: Remove a doubled word in a comment.
9735         * lib/check-version.c (check_version): Likewise.
9736         * lib/javacomp.c (compile_java_class): Likewise.
9737
9738 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
9739
9740         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
9741         for the benefit of people using Autoconf 2.60.  If you want to
9742         support older Autoconf versions you can copy m4/onceonly_2_57.m4
9743         (or m4/onceonly.m4, if pre-2.57) manually.
9744
9745 2006-07-08  Jim Meyering  <jim@meyering.net>
9746
9747         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
9748         comment.
9749         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
9750         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
9751         comment.
9752
9753 2006-07-08  Jim Meyering  <jim@meyering.net>
9754
9755         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
9756
9757 2006-07-07  Simon Josefsson  <jas@extundo.com>
9758
9759         * tests/test-crc.c: Change expected crc value, the test vector
9760         were probably computed using the old broken crc.c?
9761
9762 2006-07-06  Simon Josefsson  <jas@extundo.com>
9763
9764         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
9765         now the canonical place for the M4 file).
9766
9767         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
9768         from the sys_socket dependency now.
9769
9770         * modules/inet_pton (Files): Ditto.
9771
9772         * modules/inet_ntop (Files): Ditto.
9773
9774 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
9775
9776         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
9777         not gl_PREREQ_GETUSERSHELL.
9778
9779 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9780
9781         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
9782         with only one argument, for Autoconf 2.60.
9783         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
9784         expand to nothing, so add a shell command to avoid syntax error.
9785         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
9786
9787 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9788
9789         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
9790
9791 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9792
9793         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
9794         no longer needed.  Check for isblank decl.
9795         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
9796         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
9797         of existence.
9798
9799 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9800
9801         * lib/getloadavg.c: Use __VMS, not VMS.
9802         * lib/getopt.c: Likewise.
9803         * lib/getpagesize.h: Likewise.
9804         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
9805         and probably does not work.
9806
9807 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
9808
9809         * lib/.cppi-disable: Add wcwidth.
9810         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
9811         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
9812         (ISGRAPH): Remove.  All uses changed to isgraph.
9813         (FOLD) [!defined _LIBC]: Remove special case.
9814         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
9815         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
9816         HAVE_ISBLANK.
9817         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
9818         case.
9819
9820 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
9821
9822         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
9823         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
9824         brackets.  Other minor changes to suppress some compiler
9825         warnings.
9826
9827 2006-07-06  Derek R. Price  <derek@ximbiot.com>
9828         and Paul Eggert  <eggert@cs.ucla.edu>
9829
9830         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
9831         of invoking obsolescent AC_HEADER_DIRENT macro.
9832         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
9833         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
9834         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
9835         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
9836         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
9837         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
9838         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
9839         * m4/readdir.m4: Remove; no longer needed.
9840
9841 2006-07-06  Derek R. Price  <derek@ximbiot.com>
9842         and Paul Eggert  <eggert@cs.ucla.edu>
9843
9844         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
9845         Don't worry about this obsolete case any more.
9846         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
9847         directories.
9848         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
9849         worry about this obsolete case any more.
9850         * lib/fts.c: Likewise.
9851         * lib/getcwd.c: Likewise.
9852         * lib/glob.h: Likewise.
9853         * lib/savedir.c: Likewise.
9854
9855 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
9856
9857         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
9858         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
9859         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
9860         needed.
9861         All uses removed.
9862         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9863         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
9864         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
9865         needed.
9866         * m4/getdate.m4 (gl_GETDATE): Likewise.
9867         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
9868         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
9869         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
9870         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9871         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
9872         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
9873         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
9874         needed.
9875
9876 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
9877
9878         * lib/memcasecmp.c: Include <limits.h>.
9879         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
9880         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
9881         Don't assume isdigit succeeds only on '0' through '9'.
9882
9883 2006-07-05  Eric Blake  <ebb9@byu.net>
9884
9885         * modules/getaddrinfo (Depends-on): Add snprintf.
9886
9887 2006-07-05  Eric Blake  <ebb9@byu.net>
9888
9889         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
9890         to avoid 'header present but could not be compiled' on cygwin.
9891
9892 2006-07-05  Eric Blake  <ebb9@byu.net>
9893
9894         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
9895         missing from netdb.h.
9896         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
9897
9898 2006-07-05  Derek R. Price  <derek@ximbiot.com>
9899
9900         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
9901         no longer needed.
9902         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
9903         * m4/getdate.m4 (gl_GETDATE): Likewise.
9904         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
9905         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
9906         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
9907         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
9908         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
9909
9910 2006-07-05  Derek R. Price  <derek@ximbiot.com>
9911
9912         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
9913         All uses of is_space replaced by isspace.
9914         * lib/exit.h: Don't talk about STDC_HEADERS.
9915         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
9916         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
9917         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
9918         replaced by isprint etc.
9919         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
9920         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
9921         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
9922         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
9923         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
9924         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
9925
9926 2006-07-05  Bruno Haible  <bruno@clisp.org>
9927
9928         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
9929         the function exists, before testing against AIX.
9930         Reported by Martin Lambers <marlam@marlam.de>.
9931
9932 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
9933
9934         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
9935         From Mark D. Baushke.
9936
9937 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
9938
9939         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
9940         to the absolute name, not just one, to bypass Sun C 5.8's
9941         "warning: #include of /usr/include/... may be non-portable".
9942
9943 2006-07-04  Eric Blake  <ebb9@byu.net>
9944
9945         * modules/dirname-tests: New test module.
9946         * tests/test-dirname.c: New file, replacing dirname.c
9947         TEST_DIRNAME section that was recently deleted.
9948
9949 2006-07-04  Bruno Haible  <bruno@clisp.org>
9950
9951         Assume ANSI C header files and <ctype.h> functions.
9952         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
9953         (mbsnwidth): Use isprint, iscntrl instead.
9954
9955 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9956
9957         Merge from coreutils.
9958         * MODULES.html.sh: Add xstrtold.
9959         * modules/xstrtold: New file.
9960         * modules/cycle-check (Files): Add lib/same-inode.h.
9961         * modules/dirname (Files): Add m4/double-slash-root.m4.
9962         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
9963         * modules/mkdir-p (Files): Add lib/same-inode.h.
9964         * modules/same (Files): Add lib/same-inode.h.
9965
9966 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
9967
9968         * m4/absolute-header.m4: Renamed from full-header-path.m4.
9969         This is to keep the terminology clean; POSIX talks about
9970         "absolute pathnames", not "full pathnames", but the GNU
9971         Coding Standards say to use "path" for something else;
9972         so use "absolute" to keep both sides happy.
9973         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
9974         Set gl_absolute_header, not gl_full_header_path.
9975         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
9976         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
9977         All uses changed.
9978
9979         Merge from coreutils.
9980
9981         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
9982
9983         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
9984         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
9985         want to require the building of c-strtod.o.
9986         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
9987         needs -lm directly.
9988         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
9989
9990         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
9991
9992         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
9993         --as-needed option if available.  Problem reported by Albert Chin in
9994         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
9995         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
9996         cc merely issues a bunch of annoying warnings for --as-needed
9997         (this problem was reported by Bob Proulx).  Also, try linking with
9998         -lm to detect a bug in binutils 2.16 (this problem was reported
9999         by Ralf Wildenhues).
10000
10001         2006-06-18  Jim Meyering  <jim@meyering.net>
10002
10003         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
10004         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
10005         macro.
10006         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
10007         also check for glibc-2.4's abort-inducing bug.
10008
10009         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
10010         Low-probability clean-up should be to use rmdir to get rid of
10011         the just-created directory, not unlink.
10012
10013         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
10014         configure fail, and request a bug report to inform us about it.
10015         Add a comment that, barring reports to the contrary, in 2007 we'll
10016         assume ftruncate is universally available.
10017
10018         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10019
10020         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
10021
10022         2006-03-12  Jim Meyering  <jim@meyering.net>
10023
10024         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
10025         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
10026         * m4/same.m4 (gl_SAME): Likewise.
10027         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
10028
10029         2006-03-11  Eric Blake  <ebb9@byu.net>
10030
10031         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
10032         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
10033         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
10034         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
10035
10036 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10037
10038         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
10039         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
10040         reported by Mark D. Baushke, one in
10041         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
10042
10043         Merge from coreutils.
10044
10045         * lib/.cppi-disable: Add stdint_.h.
10046         * lib/.cvsignore: Add stdint.h.
10047
10048         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
10049
10050         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
10051         both double and long double versions.
10052         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
10053         * lib/xstrtold.c: New file.
10054         * lib/xstrtod.h (xstrtold): New decl.
10055
10056         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
10057
10058         * lib/filemode.c (setst): Remove.
10059         (strmode): Rewrite to avoid setst.  This makes the code shorter,
10060         (arguably) clearer, and the generated code is a bit smaller on my
10061         Debian GNU/Linux stable x86 host.
10062
10063         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10064
10065         * lib/filemode.c: Include "filemode.h" first, to test the interface.
10066         Assume that filemode.h includes sys/types.h and sys/stat.h.
10067         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
10068         (ftypelet): Reorder to put common cases first, for efficiency.
10069         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
10070         to do 'M'.
10071         (strmode): Renamed from mode_string, and now stores 12 bytes instead
10072         of 10, for compatibility with FreeBSD.  All callers changed.
10073         (filemodestring): Now stores 12 bytes instead of 10, and sets file
10074         types that can't be deduced solely from st_mode.  First arg is now a
10075         const pointer.
10076         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
10077         (strmode): Renamed from mode_string.
10078         (filemodestring): New decl.
10079         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
10080         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
10081         needed.
10082         (S_ISPORT, S_ISWHT): New macros, if not already defined.
10083
10084         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
10085
10086         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
10087         fsusage.h now does that.  Include fsusage.h first, to test interface.
10088         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
10089         at most one method (the old code could have generated decls that
10090         didn't conform to C89, not that this was ever exercised).
10091         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
10092
10093         2006-03-19  Jim Meyering  <jim@meyering.net>
10094
10095         Work even in a chroot where d_ino values for entries in "/"
10096         don't match the stat.st_ino values for the same names.
10097         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
10098         number, iterate through all entries again, using lstat instead.
10099         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
10100         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
10101
10102         * lib/getcwd.c (__getcwd): Clarify a comment.
10103         Use memcpy in place of a call to strcpy.
10104
10105         2006-03-12  Jim Meyering  <jim@meyering.net>
10106
10107         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
10108         matches that of the current directory (which we're about to chdir ".."
10109         out of), then save the dev-ino of the parent, instead.
10110
10111         * lib/same-inode.h (SAME_INODE): New file/macro.
10112         * lib/chdir-safer.c (SAME_INODE): Remove definition.
10113         Include "same-inode.h", instead.
10114         * lib/same.c: Likewise.
10115         * lib/cycle-check.h: Include "same-inode.h".
10116         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
10117         * lib/cycle-check.c (SAME_INODE): Remove definition.
10118         * lib/root-dev-ino.h: Include "same-inode.h".
10119
10120         2006-03-11  Eric Blake  <ebb9@byu.net>
10121
10122         * lib/same.c (same_name): s/base_name/last_component/
10123         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
10124         * lib/filenamecat.c (file_name_concat): Likewise.
10125
10126         2006-03-11  Eric Blake  <ebb9@byu.net>,
10127                     Paul Eggert  <eggert@cs.ucla.edu>
10128
10129         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
10130         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
10131         drive prefix.
10132         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
10133         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
10134         (last_component): New method.
10135         * lib/dirname.c (dir_len): Determine when drive letters need a
10136         subsequent slash.  Preserve // when it is special.
10137         (dir_name): Don't append dot when drive letter is absolute.
10138         [TEST_DIRNAME]: Move into a full-blown gnulib test.
10139         * lib/basename.c (base_name): New semantics - malloc the result.
10140         Preserve // when it is special.  Preserve relative files that look
10141         like drive letters.
10142         (base_len): Preserve // when it is special.
10143         (last_component): New method, similar to old base_name semantics.
10144         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
10145         base_name.  Strip redundant slashes from ///.
10146
10147 2006-07-03  Jim Meyering  <jim@meyering.net>
10148
10149         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
10150         macro is used before the first cycle_check call.
10151
10152 2006-07-03  Eric Blake  <ebb9@byu.net>
10153
10154         * modules/dirname (Depends-on): Add xstrndup.
10155
10156 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10157
10158         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
10159         test cases, so that config.log is a bit easier to follow.
10160
10161 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10162
10163         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
10164         both are 64 bits, since this seems to be the tradition, and this
10165         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
10166         we ever run into a host that prefers long long to long in this
10167         case, we'll need another configure-time test.  Problem reported by
10168         Jim Meyering.
10169
10170 2006-07-02  Eric Blake  <ebb9@byu.net>
10171
10172         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
10173
10174 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10175
10176         * modules/inttypes (Depends-on): No longer depends on stdint.
10177         * modules/stdint (Description): Say more about assumptions.
10178         Say that the fast types might differ.  Say macros are used.
10179         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
10180         (Makefile.am): Revise list of substituted symbols to match
10181         new stdint.m4.
10182         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
10183         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
10184         * tests/test-stdint.c (verify_same_types)
10185         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
10186         the code conforms to C99/C89.
10187         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
10188         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
10189
10190 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10191
10192         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
10193         but fix a bug, by requiring at least 64 bits.
10194         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
10195         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
10196         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
10197         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
10198
10199         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
10200         changes.  Make 2.59 a prerequisite.  Check and substitute for
10201         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
10202         inttypes.h.  Do not use special include files; just use the
10203         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
10204         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
10205         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
10206         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
10207         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
10208         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
10209         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
10210         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
10211         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
10212         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
10213         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
10214         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
10215         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
10216         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
10217         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
10218         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
10219         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
10220         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
10221         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
10222         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
10223         WINT_MAX.  Check for C99 conformance more strictly, by detecting
10224         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
10225         not check for things that C99 does not require, e.g., int8_t.  If
10226         a test isn't needed unless <stdint.h> isn't working, and is
10227         unlikely to be needed for any other reason, then don't do it
10228         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
10229         size_t, since we assume C89 freestanding at least.  Do not check
10230         for sig_atomic_t, wchar_t, or wint_t, since the code now does
10231         the right thing even if the types are not defined.  Instead use:
10232         (gl_STDINT_TYPE_PROPERTIES): New macro.
10233         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
10234         testing whether <sys/types.h> clashes, as Autoconf does this for
10235         us now.  All uses removed.
10236         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
10237         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
10238         (gl_CHECK_TYPE_SAME):
10239         Remove; no longer needed.
10240         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
10241         exists, since we'll return 0 anyway in that case.
10242         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
10243
10244 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10245
10246         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
10247         possible collision with system files.
10248         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
10249         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
10250         WCHAR_MIN and WCHAR_MAX in this case.
10251         (<stddef.h>): Do not include; no longer needed.
10252         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
10253         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
10254         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
10255         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
10256         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
10257         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
10258         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
10259         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
10260         !defined(__c99))]: Include in this case too, since it's harmless
10261         now.
10262         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
10263         dangerous to do so.
10264         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
10265         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
10266         (_STDINT_MIN, _STDINT_MAX): New macros.
10267         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
10268         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
10269         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
10270         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
10271         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
10272         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
10273         macros, not typedefs; this simplifies things quite a bit.
10274         Use long int for all types narrower than int64_t.
10275         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
10276         Define in terms of long long int or int64_t or long int,
10277         not int64_t or int32_t.  This saves some compile-time testing.
10278         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
10279         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
10280         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
10281         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
10282         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
10283         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
10284         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
10285         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
10286         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
10287         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
10288         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
10289         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
10290         undef any previous version and define our own version, for
10291         simplicity and consistency with the new macros for types.
10292         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
10293         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
10294         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
10295         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
10296         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
10297         @WINT_T_SUFFIX@ to keep things simple here.
10298         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
10299         Simplify by assuming typical 8/16/32/64 host, since we're
10300         already doing that elsewhere anyway.
10301         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
10302         and assume long long int is 64 bits if available.  This
10303         speeds up 'configure'.
10304
10305 2006-07-01  Eric Blake  <ebb9@byu.net>
10306
10307         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
10308         Reported by Andreas Buening.
10309
10310 2006-07-01  Eric Blake  <ebb9@byu.net>
10311
10312         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
10313
10314 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
10315
10316         * lib/getaddrinfo.c: fixed typo
10317
10318 2006-06-29  Jim Meyering  <jim@meyering.net>
10319
10320         * modules/strftime (Maintainer): Add my name, since with the
10321         FPRINTFTIME changes strftime.c has forked from glibc.
10322
10323 2006-06-29  Eric Blake  <ebb9@byu.net>
10324
10325         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
10326
10327 2006-06-29  Eric Blake  <ebb9@byu.net>
10328
10329         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
10330
10331 2006-06-29  Eric Blake  <ebb9@byu.net>
10332
10333         * lib/stat_.h: New file.
10334
10335 2006-06-29  Eric Blake  <ebb9@byu.net>
10336
10337         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
10338         unused static function.
10339
10340 2006-06-29  Eric Blake  <ebb9@byu.net>
10341
10342         * doc/functions.texi (Function Portability): Document missing lstat
10343         on mingw.
10344
10345 2006-06-29  Eric Blake  <ebb9@byu.net>
10346
10347         * MODULES.html.sh: Add sys_stat.
10348         * modules/sys_stat: New module.
10349         * modules/mkstemp (Depends-on): Add sys_stat.
10350
10351 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10352
10353         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
10354
10355 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10356
10357         * m4/c-bs-a.m4: Removed.
10358
10359 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10360
10361         * lib/strftime.c: Assume strftime() exists.
10362
10363 2006-06-29  Derek Price  <derek@ximbiot.com>
10364
10365         * modules/c-bs-a: Removed - \a is C89.
10366         * MODULES.html.sh: Remove c-bs-a.
10367
10368 2006-06-29  Bruno Haible  <bruno@clisp.org>
10369
10370         * modules/wcwidth (License): Change to LGPL.
10371
10372 2006-06-28  Simon Josefsson  <jas@extundo.com>
10373
10374         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
10375         on _WIN32.
10376
10377         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
10378         getnameinfo.
10379
10380 2006-06-28  Simon Josefsson  <jas@extundo.com>
10381
10382         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
10383
10384 2006-06-28  Simon Josefsson  <jas@extundo.com>
10385
10386         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
10387         functions there.  It will succeed on Windows XP, but on Windows
10388         2000 and (presumably) earlier, it will fail, and use the internal
10389         re-implementation.
10390         (use_win32_p): New function.
10391         (getaddrinfo): Use strtoul on servname, to support numeric ports.
10392         Support AI_NUMERICSERV to disable getservbyname.
10393         (getnameinfo): New function, only supports
10394         NI_NUMERICHOST|NI_NUMERICSERV for now.
10395
10396         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
10397         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
10398         getnameinfo.
10399
10400 2006-06-28  Eric Blake  <ebb9@byu.net>
10401
10402         * modules/wcwidth: New file.
10403         * modules/mbchar (Depends-on): Add wcwidth.
10404         * modules/mbswidth (Depends-on): Add wcwidth.
10405         * MODULES.html.sh: Add wcwidth.
10406
10407 2006-06-28  Eric Blake  <ebb9@byu.net>
10408
10409         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
10410         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
10411
10412 2006-06-28  Eric Blake  <ebb9@byu.net>
10413
10414         * lib/xvasprintf.h: Fix comments.
10415
10416 2006-06-28  Eric Blake  <ebb9@byu.net>
10417
10418         * lib/mbchar.h (wcwidth): Include wcwidth.h.
10419         * lib/mbswidth.c (wcwidth): Move from here...
10420         * lib/wcwidth.h: ...to this new file.
10421
10422 2006-06-28  Derek R. Price  <derek@ximbiot.com>
10423
10424         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
10425
10426         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
10427         it's obsolete.
10428         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
10429
10430 2006-06-28  Derek R. Price  <derek@ximbiot.com>
10431
10432         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
10433         Autoconf 2.60 says this stuff was obsolete.
10434
10435 2006-06-28  Bruno Haible  <bruno@clisp.org>
10436
10437         * modules/wcwidth (Files): Add m4/wchar_t.m4.
10438
10439 2006-06-28  Bruno Haible  <bruno@clisp.org>
10440
10441         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
10442         gt_TYPE_WCHAR_T.
10443
10444 2006-06-28  Bruno Haible  <bruno@clisp.org>
10445
10446         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
10447         declaration for wcwidth.
10448         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
10449
10450 2006-06-28  Bruno Haible  <bruno@clisp.org>
10451
10452         * lib/mkdtemp.c [MINGW]: Include <io.h>.
10453         (mkdir): Define using _mkdir.
10454
10455 2006-06-28  Bruno Haible  <bruno@clisp.org>
10456
10457         * lib/getaddrinfo.h: Fix POSIX URL.
10458         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
10459         _WIN32.
10460         (use_win32_p): Make static.
10461         (getaddrinfo): Reject service name if it is empty or does not consist
10462         solely of decimal digits, or if its value is > 65535.
10463         (getnameinfo): Remove useless casts.
10464
10465 2006-06-27  Simon Josefsson  <jas@extundo.com>
10466
10467         * modules/sys_select: New file, suggested by Bruno Haible, Paul
10468         Eggert and Martin Lambers.
10469
10470 2006-06-27  Simon Josefsson  <jas@extundo.com>
10471
10472         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
10473         Eggert and Martin Lambers.
10474
10475 2006-06-27  Bruno Haible  <bruno@clisp.org>
10476
10477         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
10478         result to 0, not to empty.
10479         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
10480
10481 2006-06-27  Bruno Haible  <bruno@clisp.org>
10482
10483         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
10484
10485 2006-06-26  Simon Josefsson  <jas@extundo.com>
10486
10487         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
10488         present.
10489
10490 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
10491
10492         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
10493         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
10494         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
10495
10496 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
10497
10498         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
10499
10500 2006-06-26  Bruno Haible  <bruno@clisp.org>
10501
10502         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
10503
10504 2006-06-26  Bruno Haible  <bruno@clisp.org>
10505
10506         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
10507
10508 2006-06-26  Bruno Haible  <bruno@clisp.org>
10509
10510         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
10511         SGI C compiler in pre-C99 mode.
10512         Suggested by Mark D. Baushke and Larry Jones.
10513
10514 2006-06-26  Bruno Haible  <bruno@clisp.org>
10515
10516         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
10517         WCHAR_MAX.
10518         Reported by Mark D. Baushke and Larry Jones.
10519
10520 2006-06-26  Bruno Haible  <bruno@clisp.org>
10521
10522         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
10523         in pre-C99 mode.
10524         Suggested by Mark D. Baushke and Larry Jones.
10525
10526 2006-06-23  Simon Josefsson  <jas@extundo.com>
10527             Bruno Haible  <bruno@clisp.org>
10528
10529         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
10530         Emit mostlyclean-local rule.
10531         (func_emit_tests_Makefile_am): Likewise.
10532         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
10533
10534 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
10535
10536         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
10537
10538 2006-06-23  Bruno Haible  <bruno@clisp.org>
10539
10540         * tests/test-stdint.c: Update to match ISO C 99 Technical
10541         Corrigendum 1.
10542
10543 2006-06-23  Bruno Haible  <bruno@clisp.org>
10544
10545         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
10546
10547 2006-06-23  Bruno Haible  <bruno@clisp.org>
10548
10549         * lib/stdint_.h: Treat IRIX like OpenBSD.
10550
10551 2006-06-23  Bruno Haible  <bruno@clisp.org>
10552
10553         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
10554         ISO C 99 Technical Corrigendum 1.
10555
10556 2006-06-22  Simon Josefsson  <jas@extundo.com>
10557
10558         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
10559         MinGW.
10560
10561 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
10562
10563         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
10564         needed.  Some compiler complained about some of them.  Problem reported
10565         by Larry Jones in
10566         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
10567
10568 2006-06-21  Simon Josefsson  <jas@extundo.com>
10569
10570         * tests/test-getaddrinfo.c: New file.
10571
10572         * modules/getaddrinfo-tests: New file.
10573
10574         * MODULES.html.sh: Add inet_pton.
10575
10576         * modules/inet_pton: New file.
10577
10578 2006-06-21  Simon Josefsson  <jas@extundo.com>
10579
10580         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
10581         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
10582         of using the (limited) gnulib implementation on Windows XP.
10583
10584         * m4/inet_pton.m4: New file.
10585
10586 2006-06-21  Simon Josefsson  <jas@extundo.com>
10587
10588         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
10589         variable.
10590
10591         * lib/socket_.h: Don't define WINVER.
10592
10593         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
10594         slightly modified to work in gnulib.
10595
10596 2006-06-21  Simon Josefsson  <jas@extundo.com>
10597
10598         * doc/gnulib.texi (Windows sockets): Add.
10599
10600 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
10601
10602         * lib/read-file.c (fread_file): Start with buffer allocation of
10603         0 bytes rather than 1 byte; this simplifies the code.
10604         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
10605         code to free buffer and save/restore errno.
10606         (internal_read_file): Remove unused local.
10607
10608 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
10609
10610         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
10611         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
10612         Problem reported by Denis Excoffier in
10613         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
10614
10615 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10616
10617         * modules/sys_socket, modules/socklen: Include sys/types since
10618         FreeBSD 4.x's sys/socket.h needs it.
10619
10620 2006-06-19  Simon Josefsson  <jas@extundo.com>
10621
10622         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
10623
10624 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
10625
10626         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
10627
10628 2006-06-19  Bruno Haible  <bruno@clisp.org>
10629
10630         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
10631         and FULL_PATH_INTTYPES_H in angle brackets.
10632         Reported by Mark D. Baushke <mdb@gnu.org>.
10633
10634 2006-06-17  Eric Blake  <ebb9@byu.net>
10635
10636         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
10637         errno.
10638
10639 2006-06-17  Bruno Haible  <bruno@clisp.org>
10640
10641         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
10642         <sys/inttypes.h>.
10643
10644 2006-06-17  Bruno Haible  <bruno@clisp.org>
10645
10646         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
10647         whether errno is declared. Assume <errno.h> declares errno.
10648
10649 2006-06-17  Bruno Haible  <bruno@clisp.org>
10650
10651         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
10652
10653 2006-06-17  Bruno Haible  <bruno@clisp.org>
10654
10655         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
10656         problem on Solaris 2.5.1.
10657
10658 2006-06-16  Eric Blake  <ebb9@byu.net>
10659
10660         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
10661         * lib/unicodeio.c [!defined errno]: Likewise.
10662         * lib/strtol.c [!defined errno]: Likewise.
10663         * lib/strtod.c [!defined errno]: Likewise.
10664
10665 2006-06-15  Eric Blake  <ebb9@byu.net>
10666
10667         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
10668
10669 2006-06-15  Eric Blake  <ebb9@byu.net>
10670
10671         * config/srclist.txt (ssize_t.m4): Lose sync.
10672
10673 2006-06-15  Bruno Haible  <bruno@clisp.org>
10674
10675         * modules/stdint (Files): Include m4/full-header-path.m4,
10676         m4/size_max.m4, m4/wchar_t.m4.
10677         (Makefile.am): Many more substitutions.
10678         * modules/stdint-tests: New file.
10679         * tests/test-stdint.c: New file.
10680
10681 2006-06-15  Bruno Haible  <bruno@clisp.org>
10682
10683         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
10684         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
10685         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
10686         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
10687         gl_CHECK_TYPE_SAME): New macros.
10688
10689 2006-06-15  Bruno Haible  <bruno@clisp.org>
10690
10691         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
10692
10693 2006-06-15  Bruno Haible  <bruno@clisp.org>
10694
10695         * lib/stdint_.h: Rewritten to be fully auto-configured.
10696         Fixes bug on HP-UX/IA64.
10697
10698 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
10699
10700         * lib/getdate.y (__attribute__): Don't define if already defined.
10701         Problem reported by Larry Jones.
10702         * lib/utimens.c (__attribute__): Likewise.
10703
10704 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
10705
10706         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
10707         reported by Andreas Schwab.
10708
10709 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10710             Bruno Haible  <bruno@clisp.org>
10711
10712         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
10713         check for the declaration of strnlen and a run test that exposes the
10714         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
10715         rpl_strndup.
10716
10717 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10718             Bruno Haible  <bruno@clisp.org>
10719
10720         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
10721
10722 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10723
10724         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
10725         compile test, for Tru64 4.0D.
10726
10727 2006-05-28  Karl Berry  <karl@gnu.org>
10728
10729         * config/srclist.txt (printf-args.c): lose sync.
10730
10731 2006-05-26  Martin Lambers  <marlam@marlam.de>
10732
10733         * lib/getpass.c: Updates the test for the native W32 API, and adds
10734         missing includes, thus fixing compilation warnings.
10735
10736 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
10737
10738         * lib/exclude.c (exclude_fnmatch): New function.
10739         (excluded_file_name): Call exclude_fnmatch.
10740         * lib/exclude.h (excluded_file_name): New prototype
10741
10742 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
10743
10744         * lib/tempname.c (small_open, large_open): New macros.
10745         (__open, __open64) [!_LIBC]: Remove.
10746         (__gen_tempname): Use small_open and large_open instead of __open
10747         and __open64.  This fixes a portability bug on HP-UX 11.11i
10748         reported by Simon Wing-Tang in
10749         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
10750
10751 2006-05-24  Bruno Haible  <bruno@clisp.org>
10752
10753         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
10754         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
10755         Reported by Thorsten Maerz <torte@netztorte.de> via
10756         Aaron Stone <aaron@serendipity.cx>.
10757
10758 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
10759
10760         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
10761         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
10762         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
10763         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
10764         not really conditional on the cache.
10765         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
10766
10767 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
10768
10769         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
10770         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
10771         (my_usleep): Don't mishandle maximum value.
10772
10773 2006-05-19  Jim Meyering  <jim@meyering.net>
10774
10775         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
10776
10777 2006-05-17  Bruno Haible  <bruno@clisp.org>
10778
10779         Cygwin portability.
10780         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
10781
10782 2006-05-17  Bruno Haible  <bruno@clisp.org>
10783
10784         * lib/stdint_.h: Fix recognition of Cygwin.
10785
10786 2006-05-15  Bruno Haible  <bruno@clisp.org>
10787
10788         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
10789         on libtool patch by Ralf Wildenhues.
10790
10791 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
10792
10793         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
10794         test for C99 conformance; (bool) 0.5 is an integer constant
10795         expression, but (bool) -0.5 is not.  Problem reported by Fedor
10796         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
10797
10798 2006-05-11  Simon Josefsson  <jas@extundo.com>
10799
10800         * m4/xvasprintf.m4: Fix obvious typo.
10801
10802 2006-05-11  Jim Meyering  <jim@meyering.net>
10803
10804         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
10805         James Lemley.
10806
10807 2006-05-10  Simon Josefsson  <jas@extundo.com>
10808
10809         * lib/md4.c: Typo fix, update copyright years.
10810         (K1, K2): Don't use L because it turn computations into 64-bit on
10811         64-bit platforms.
10812
10813 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
10814
10815         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
10816         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
10817         unwanted sign propagation, e.g., on hosts with 64-bit int.
10818         There still are some problems with reeelly weird theoretical hosts
10819         (e.g., 33-bit int) but it's not worth worrying about now.
10820         * lib/sha1.c (rol): Likewise.
10821         (K1, K2, K3, K4): Remove unnecessary L suffix.
10822
10823 2006-05-10  Bruno Haible  <bruno@clisp.org>
10824
10825         * lib/des.c: Cast to avoid warnings.
10826
10827 2006-05-09  Bruno Haible  <bruno@clisp.org>
10828
10829         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
10830         (Depends-on): Depend also on xsize, stdarg.
10831         (configure.ac): Add gl_XVASPRINTF.
10832
10833 2006-05-09  Bruno Haible  <bruno@clisp.org>
10834
10835         * m4/xvasprintf.m4: New file.
10836
10837 2006-05-09  Bruno Haible  <bruno@clisp.org>
10838
10839         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
10840         (EOVERFLOW): Define fallback value.
10841         (xstrcat): New function.
10842         (xvasprintf): Recognize the special case of a string concatenation.
10843
10844 2006-05-08  Eric Blake  <ebb9@byu.net>
10845
10846         * gnulib-tool (func_version): Base copyright year on CVS date.
10847         (func_emit_copyright_notice): New function.
10848         (func_emit_lib_Makefile_am): Use it.
10849         (func_emit_tests_Makefile_am): Likewise.
10850         (func_import): Likewise.
10851
10852 2006-05-08  Bruno Haible  <bruno@clisp.org>
10853
10854         * modules/stdarg: New file.
10855         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
10856
10857 2006-05-08  Bruno Haible  <bruno@clisp.org>
10858
10859         * m4/stdarg.m4: New file, from GNU gettext.
10860
10861 2006-05-08  Bruno Haible  <bruno@clisp.org>
10862
10863         * config/srclist.txt (build-aux/config.rpath): different from latest
10864         release.
10865
10866 2006-05-08  Bruno Haible  <bruno@clisp.org>
10867
10868         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
10869
10870 2006-05-05  Jim Meyering  <jim@meyering.net>
10871
10872         * m4/warning.m4: New file, derived from bison's file by the same name.
10873
10874 2006-05-03  Bruno Haible  <bruno@clisp.org>
10875
10876         * lib/stdint_.h: Shorter URL.
10877         * lib/inttypes.h: Likewise.
10878
10879 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10880
10881         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
10882
10883 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10884
10885         * lib/verify.h: Document the internals better.  Most of this change
10886         was written by Bruno Haible.
10887
10888 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
10889
10890         * doc/verify.texi: New file, partly based on a proposal by
10891         Bruno Haible.
10892
10893 2006-05-02  Bruno Haible  <bruno@clisp.org>
10894
10895         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
10896         test from here...
10897         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
10898
10899 2006-04-29  Bruno Haible  <bruno@clisp.org>
10900
10901         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
10902         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
10903
10904 2006-04-29  Bruno Haible  <bruno@clisp.org>
10905
10906         * gnulib-tool: Make --update option actually work.
10907
10908 2006-04-29  Bruno Haible  <bruno@clisp.org>
10909
10910         * doc/gcd.texi: New file.
10911         * doc/gnulib.texi: Include it.
10912
10913 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
10914
10915         * lib/getdate.y (get_date): When adding relative date, start with the
10916         initial time, not with the result of the first mktime call.
10917
10918 2006-04-25  Bruno Haible  <bruno@clisp.org>
10919
10920         * gnulib-tool (func_import): Output the include directives in three
10921         blocks, sorted separately.
10922         Reported by Ben Pfaff <blp@cs.stanford.edu>.
10923
10924 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
10925
10926         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
10927         to define main with arguments, for C++.  Reported by Eric Blake.
10928         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
10929         Prefer 'int main ()' to 'int main (void)', for C++.
10930         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
10931         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
10932         for 'main', for C99 and C++.
10933
10934 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
10935
10936         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
10937         Don't assume that exit status -1 is valid.
10938         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
10939         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
10940         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
10941         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
10942         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
10943         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
10944         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
10945         functions can be used without declaring them, or that you can
10946         exit with status -1.
10947         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
10948
10949 2006-04-24  Karl Berry  <karl@gnu.org>
10950
10951         * config/srclist.txt (longdouble.m4): sync lost.
10952
10953 2006-04-24  Eric Blake  <ebb9@byu.net>
10954
10955         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
10956
10957 2006-04-24  Bruno Haible  <bruno@clisp.org>
10958
10959         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
10960         poll() implementation in AIX.
10961         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10962
10963 2006-04-24  Bruno Haible  <bruno@clisp.org>
10964
10965         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
10966         assigned exactly once.
10967
10968 2006-04-23  Claudio Fontana  <claudio@gnu.org>
10969             Bruno Haible  <bruno@clisp.org>
10970
10971         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
10972         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
10973         for AM_CPPFLAGS.
10974
10975 2006-04-23  Bruno Haible  <bruno@clisp.org>
10976
10977         * modules/copy-file: Depend on unistd.
10978         * modules/execute: Likewise.
10979         * modules/fatal-signal: Likewise.
10980         * modules/findprog: Likewise.
10981         * modules/mkdtemp : Likewise.
10982         * modules/pipe: Likewise.
10983         * modules/wait-process: Likewise.
10984
10985 2006-04-23  Bruno Haible  <bruno@clisp.org>
10986
10987         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
10988         condition was already detected.
10989         Reported by Ben Pfaff <blp@cs.stanford.edu>.
10990
10991 2006-04-23  Bruno Haible  <bruno@clisp.org>
10992
10993         * lib/copy-file.c: Include <unistd.h> unconditionally.
10994         * lib/execute.c: Likewise.
10995         * lib/fatal-signal.c: Likewise.
10996         * lib/findprog.c: Likewise.
10997         * lib/mkdtemp.c: Likewise.
10998         * lib/pipe.h: Likewise.
10999         * lib/pipe.c: Likewise.
11000         * lib/wait-process.h: Likewise.
11001
11002 2006-04-23  Bruno Haible  <bruno@clisp.org>
11003
11004         * gnulib-tool (func_usage): Fix --import description. Document
11005         --update.
11006         (func_import): Create temporary file in a temporary directory, if
11007         --dry-run is specified. Silence errors from 'grep' when there are no
11008         m4 files in $m4dir.
11009         (func_create_testdir): Silence errors from 'grep' when there are no
11010         m4 files in $m4dir.
11011         Reported by Karl Berry <karl@freefriends.org>.
11012
11013 2006-04-20  Bruno Haible  <bruno@clisp.org>
11014
11015         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
11016         one argument, so that the code will be portable to Autoconf 2.60.
11017         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
11018         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
11019         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
11020
11021 2006-04-19  Derek Price  <derek@ximbiot.com>
11022             Eric Blake  <ebb9@byu.net>
11023
11024         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
11025         rather than "/full/path.h".  Update comment to match.  Shorten &
11026         generalize m4_translit call via AS_TR_CPP.
11027
11028 2006-04-19  Derek Price  <derek@ximbiot.com>
11029             Eric Blake  <ebb9@byu.net>
11030
11031         * lib/inttypes.h: Correct grammar in comment.
11032
11033 2006-04-18  Derek Price  <derek@ximbiot.com>
11034             Paul Eggert  <eggert@cs.ucla.edu>
11035
11036         * modules/inttypes: New file.
11037         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
11038
11039 2006-04-18  Derek Price  <derek@ximbiot.com>
11040             Paul Eggert  <eggert@cs.ucla.edu>
11041
11042         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
11043         New files.
11044
11045 2006-04-18  Derek Price  <derek@ximbiot.com>
11046             Paul Eggert  <eggert@cs.ucla.edu>
11047
11048         * lib/inttypes.h: New file.
11049         * lib/strtoimax.c: Assume <inttypes.h>.
11050
11051 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
11052
11053         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
11054         isn't mounted.  Problem reported by Kir Kolyshkin.
11055
11056 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
11057
11058         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
11059         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
11060         Derek R. Price.
11061         * lib/regex.h (RE_DUP_MAX): Update comment to match current
11062         implementation.
11063
11064 2006-04-12  Eric Blake  <ebb9@byu.net>
11065
11066         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
11067         is now done automatically by the corresponding Autoconf macro.
11068
11069 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
11070
11071         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
11072         time_r.h.
11073
11074 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11075
11076         Merge regex changes from libc, removing some of our
11077         POSIX-conformance changes that were rejected and redoing them in a
11078         less-intrusive way.
11079
11080         * lib/regcomp.c (re_compile_internal, init_dfa):
11081         Length arg is now size_t, not Idx.  All uses changed.
11082         (peek_token): Forward decl now says internal_function.
11083         (__re_error_msgid, __re_error_msgid_idx):
11084         Now static rather than extern with attribute_hidden.
11085         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
11086         For some reason libc prefers K&R style defns for external functions.
11087         (regerror) [!defined _LIBC]: Likewise.
11088         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
11089         (seek_collating_symbol_entry, lookup_collation_sequence_value):
11090         (build_range_exp, build_collating_symbol):
11091         Use K&R-style defn.
11092         (re_compile_fastmap): Use '\0' to memset, not 0.
11093         (utf8_sb_map): Make the calculations more obvious.
11094         (init_dfa, parse_bracket_exp, build_charclass_op):
11095         Call calloc and cast result, as glibc does.
11096         (init_word_char, fetch_token, peek_token, peek_token_bracket):
11097         (build_range_exp, build_collating_symbol):
11098         Now internal functions.
11099
11100         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
11101
11102         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
11103         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
11104         Don't depend on VMS; depend on __VMS instead, for POSIX
11105         namespace cleanness.
11106         (regoff_t): Define to ssize_t, not long int.
11107
11108         Remove the REG_ macros named below.  Instead, make the old names
11109         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
11110         __USE_GNU_REGEX.
11111         (REG_BACKSLASH_ESCAPE_IN_LISTS):
11112         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
11113         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
11114         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
11115         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
11116         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
11117         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
11118         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
11119         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
11120         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
11121         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
11122         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
11123         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
11124         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
11125         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
11126         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
11127         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
11128         (REG_NREGS):
11129         Remove.  All uses replaced by the old RE_* names.
11130         (RE_BACKSLASH_ESCAPE_IN_LISTS):
11131         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
11132         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
11133         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
11134         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
11135         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
11136         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
11137         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
11138         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
11139         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
11140         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
11141         Don't bother having these macros be independent of each others'
11142         values, since they no longer exist in the POSIX name space.
11143
11144         Rename the following member names back to their old names,
11145         unless !__USE_GNU_REGEX.  All uses changed back.
11146         (buffer): Renamed from re_buffer.
11147         (allocated): Renamed from re_allocated.
11148         (used): Renamed from re_used.
11149         (syntax): Renamed from re_syntax.
11150         (fastmap): Renamed from re_fastmap.
11151         (translate): Renamed from re_translate.
11152         (can_be_null): Renamed from re_can_be_null.
11153         (regs_allocated): Renamed from re_regs_allocated.
11154         (fastmap_accurate): Renamed from re_fastmap_accurate.
11155         (no_sub): Renamed from re_no_sub.
11156         (not_bol): Renamed from re_not_bol.
11157         (not_eol): Renamed from re_not_eol.
11158         (newline_anchor): Renamed from re_newline_anchor.
11159         (num_regs): Renamed from rm_num_regs.
11160         (start): Renamed from rm_start.
11161         (end): Renamed from rm_end.
11162
11163         (free_state): Move up a bit.
11164
11165         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
11166         #define to be empty.
11167         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
11168         when that is what is intended.
11169         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
11170         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
11171         (MAX): New macro.
11172         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
11173         All uses changed back to re_malloc, etc.  It's now the caller's
11174         responsibility to check for overflow; all callers changed.
11175         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
11176         (re_x2nrealloc): Remove.
11177         (free_state): Remove decl.
11178
11179         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
11180         (re_set_registers, re_exec):
11181         Use K&R-style defn.
11182
11183         2006-01-31  Roland McGrath  <roland@redhat.com>
11184
11185         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
11186         Reported by Mike Frysinger <vapier@gentoo.org>.
11187
11188         2006-01-15  Andreas Jaeger  <aj@suse.de>
11189
11190         [BZ #1950]
11191         * lib/regex_internal.c (re_string_reconstruct): Adjust for
11192         build_wcs_upper_buffer change.
11193         (build_wcs_upper_buffer): Change return type.
11194
11195         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
11196
11197         * lib/regex_internal.h: Include <stdint.h> if available.
11198
11199         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
11200
11201         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
11202
11203         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
11204
11205         * lib/regcomp.c: Adjust for changed secondary hash function.
11206
11207         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
11208
11209         * lib/regex.h: Pretty printing.
11210         Clean up namespace a bit.
11211
11212         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
11213
11214         * lib/regexec.c (update_cur_sifted_state, check_arrival,
11215         check_arrival_add_next_nodes): Avoid using uninitialized variable.
11216
11217         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
11218                     Ulrich Drepper  <drepper@redhat.com>
11219
11220         [BZ #1302]
11221         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
11222         changed.
11223         (bitset_word_t): Renamed from bitset_word.  All uses changed.
11224
11225         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
11226
11227         [BZ #281]
11228         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
11229         * lib/regcomp.c: Remove unnecessary uses of
11230         unsigned RE_TRANSLATE_TYPE.
11231         * lib/regex_internal.h: Likewise.
11232         * lib/regex_internal.c: Likewise.
11233         * lib/regexec.c: Likewise.
11234         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
11235
11236         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
11237
11238         * lib/regexec.c (find_recover_state): Remove unnecessary
11239         initialization.
11240         (transit_state_bkref): Make DFA a const pointer.
11241         (get_subexp): Likewise.
11242         (check_arrival): Likewise.
11243         (update_cur_sifted_state): Likewise.
11244         (re_search_internal): Likewise.
11245         (prune_impossible_nodes): Likewise.
11246         (acquire_init_state_context): Likewise.
11247         (proceed_next_node): Likewise.
11248         (set_regs): Likewise.
11249         (free_fail_stack_return): Likewise.
11250         (check_arrival_expand_ecl): Mark DFA parameter as const.
11251         (check_arrival_expand_ecl_sub): Likewise.
11252         (check_subexp_limits): Likewise.
11253         (sub_epsilon_src_nodes):  Likewise.
11254         (add_epsilon_src_nodes):  Likewise.
11255         (merge_state_array): Likewise.
11256         (update_regs): Likewise.
11257         (build_trtable): Likewise.
11258         (sift_states_backward): Mark MCTX parameter as const.
11259         (build_sifted_states): Likewise.
11260         (update_cur_sifted_state): Likewise.
11261         (sift_states_mkref): Likewise.
11262         (check_arrival_expand_ecl): Mark eclosure as const.
11263         (check_dst_limits_calc_pos_1): Likewise.
11264         * lib/regex_internal.h (re_match_context_t): Make dfa a const
11265         pointer.
11266
11267         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
11268
11269         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
11270         (transit_state_sb): Likewise.
11271         (transit_state_mb): Likewise.
11272         (sift_states_iter_mb): Likewise.
11273         (check_arrival_add_next_nodes): Likewise.
11274         (check_node_accept_bytes): Change first parameter to pointer-to-const.
11275         [_LIBC] (re_search_2_stub): Use mempcpy.
11276
11277         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
11278         mbrtowc for very simple UTF-8 case.
11279
11280         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
11281         a pointer-to-const.
11282         (re_acquire_state_context): Likewise.
11283         * lib/regex_internal.h: Adjust prototypes.
11284
11285         * lib/regex.c: Prevent using C++ compilers.
11286
11287         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
11288         (re_acquire_state_context): Likewise.
11289
11290 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11291
11292         * modules/regex (Depends-on): Add ssize_t.
11293
11294 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11295
11296         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
11297         translation table.
11298
11299 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11300
11301         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
11302
11303 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
11304             Bruno Haible  <bruno@clisp.org>
11305
11306         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
11307         <sys/types.h> and <inttypes.h>.
11308
11309 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11310
11311         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
11312         `__error_t_defined', so argp.h will not typedef the former.
11313
11314 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
11315
11316         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
11317         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
11318         glibc names.  Even if glibc is changed to conform to POSIX, the
11319         traditional names will be available anyway, since regex depends on
11320         the extensions module.  Also, fix a longstanding typo in the
11321         implementation of Spencer ERE test #75 from grep 2.3.  Problems
11322         reported by Emanuele Giaquinta.  Also, change sense of cached
11323         variable, so that the message makes sense.
11324
11325 2006-03-24  Simon Josefsson  <jas@extundo.com>
11326
11327         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
11328         including some doc fixes.
11329         (base64_encode_alloc): Fix +1 bug on allocation failures.
11330
11331 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11332
11333         * lib/base64.c (base64_encode): Do not read past end of array with
11334         unsanitized input on systems with CHAR_BIT > 8.
11335
11336 2006-03-24  Eric Blake  <ebb9@byu.net>
11337
11338         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
11339
11340 2006-03-22  Karl Berry  <karl@gnu.org>
11341
11342         * config/srclist.txt (*setenv.[ch]): get from coreutils.
11343         * config/srclistvars.sh (COREUTILS): new var.
11344
11345 2006-03-17  Jim Meyering  <jim@meyering.net>
11346
11347         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
11348         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
11349
11350 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
11351
11352         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
11353         no longer needs it.  Instead, check that regoff_t is as least
11354         as wide as ptrdiff_t.
11355
11356         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
11357         so that our regex.h stays compatible with the installed regex.
11358         This is helpful for installers who configure --without-included-regex.
11359         Problem reported by Emanuele Giaquinta.
11360
11361 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
11362
11363         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
11364         Typedef to long int, not to off_, as POSIX will likely change
11365         in that direction.
11366
11367 2006-03-15  Eric Blake  <ebb9@byu.net>
11368
11369         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
11370
11371 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
11372
11373         * lib/argp-help.c (validate_uparams): Fix typo
11374         * lib/argp-parse.c (argp_default_options): Consistently begin help
11375         messages with a lowercase letter.
11376
11377 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
11378
11379         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
11380         overrun buffers and shouldn't be used (much as gets shouldn't be
11381         used).
11382         * lib/time_r.c (asctime_r, ctime_r): Likewise.
11383
11384 2006-03-08  Simon Josefsson  <jas@extundo.com>
11385
11386         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
11387         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11388
11389 2006-03-08  Simon Josefsson  <jas@extundo.com>
11390
11391         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
11392         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11393
11394 2006-03-08  Simon Josefsson  <jas@extundo.com>
11395
11396         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
11397         signal that configure disabled the device.
11398
11399 2006-03-08  Simon Josefsson  <jas@extundo.com>
11400
11401         * build-aux/maint.mk: Fix refresh-po, to handle no translated
11402         languages.
11403
11404 2006-03-07  Simon Josefsson  <jas@extundo.com>
11405
11406         * modules/getopt (Depends-on): Add unistd.
11407
11408         * modules/unistd: New file.
11409
11410 2006-03-07  Simon Josefsson  <jas@extundo.com>
11411
11412         * modules/gc-random: New file.
11413
11414 2006-03-07  Simon Josefsson  <jas@extundo.com>
11415
11416         * m4/unistd_h.m4: New file.
11417
11418 2006-03-07  Simon Josefsson  <jas@extundo.com>
11419
11420         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
11421         test to be side-effect free by storing the result in the cache
11422         variable gl_cv_lib_readline, and moving the assignment of
11423         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
11424         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11425
11426 2006-03-07  Simon Josefsson  <jas@extundo.com>
11427
11428         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
11429         error on missing devices (the functions will return an error).
11430
11431         * m4/gc.m4: Move random stuff to gc-random.m4
11432
11433 2006-03-07  Simon Josefsson  <jas@extundo.com>
11434
11435         * lib/unistd_.h: New file.
11436
11437 2006-03-07  Simon Josefsson  <jas@extundo.com>
11438
11439         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
11440
11441 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
11442
11443         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
11444         Problem reported by Juan Manuel Guerrero.
11445
11446 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
11447
11448         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
11449         the unistd module.
11450         * lib/getlogin_r.c: Likewise.
11451         * lib/getlogin_r.h: Likewise.
11452         * lib/glob.c: Likewise.
11453         * lib/pagealign_alloc.c: Likewise.
11454         * lib/unistd_.h: Remove; no longer needed.
11455
11456 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
11457
11458         * MODULES.html.sh (Support for systems lacking POSIX:2001):
11459         Add unistd.
11460         * modules/c-stack (Depends-on): Add unistd.
11461         * modules/getlogin_r: Likewise.
11462         * modules/glob: Likewise.
11463         * modules/pagealign_alloc: Likewise.
11464         * modules/unistd (Files): Remove lib/unistd_.h.
11465         (EXTRA_DIST): Remove.
11466         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
11467         need unistd_.h.
11468         (MOSTLYCLEANFILES): Remove unistd.h-t.
11469
11470 2006-03-03  Simon Josefsson  <jas@extundo.com>
11471
11472         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
11473
11474 2006-03-03  Simon Josefsson  <jas@extundo.com>
11475
11476         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
11477         libidn and bison.
11478
11479 2006-03-03  Simon Josefsson  <jas@extundo.com>
11480
11481         * build-aux/maint.mk: Add indent target.
11482
11483 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
11484
11485         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
11486         our replacement poll.h in any case, to avoid a differing
11487         declaration from a system header.  Seen on AIX.
11488
11489 2006-03-01  Simon Josefsson  <jas@extundo.com>
11490
11491         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
11492         <kasal@ucw.cz>.
11493
11494 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
11495
11496         * modules/gettime (Depends-on): Add extensions module.
11497         * modules/nanosleep (Depends-on): Likewise.
11498         * modules/settime (Depends-on): Likewise.
11499
11500 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
11501
11502         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
11503         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
11504         pedantically.
11505         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
11506         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
11507
11508         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
11509         not "==".  Reported by Ralf Wildenhues.
11510
11511 2006-03-01  Karl Berry  <karl@gnu.org>
11512
11513         * doc/Copyright/request-*: new files, synced from gnuorg.
11514
11515 2006-03-01  Karl Berry  <karl@gnu.org>
11516
11517         * config/srclist.txt (Copyright/*): new entries.
11518
11519 2006-02-28  Simon Josefsson  <jas@extundo.com>
11520
11521         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
11522
11523 2006-02-27  Simon Josefsson  <jas@extundo.com>
11524
11525         * lib/base64.h: Indent #define's.  From Jim Meyering
11526         <jim@meyering.net>.
11527
11528 2006-02-27  Jim Meyering  <jim@meyering.net>
11529
11530         Revert the change of 2006-02-24, so these files can continue
11531         to be sync'd from gettext.
11532         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
11533         of `config.h'.
11534
11535 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
11536
11537         * modules/intprops: New file.
11538         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
11539         Add intprops.
11540         * modules/getloadavg (Files): Remove lib/intprops.h.
11541         (Depends-on): Add intprops.
11542         * modules/human: Likewise.
11543         * modules/inttostr: Likewise.
11544         * modules/openat: Likewise.
11545         * modules/sig2str: Likewise.
11546         * modules/userspec: Likewise.
11547         * modules/utimecmp: Likewise.
11548         * modules/xnanosleep: Likewise.
11549         * modules/xstrtol: Likewise.
11550
11551 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
11552
11553         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
11554         * modules/lock-tests (TESTS): Use $(EXEEXT).
11555         * modules/tls-tests: Likewise.
11556         * modules/argp-tests: Likewise.
11557         (check_PROGRAMS): New var, replacing...
11558         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
11559
11560 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11561
11562         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
11563         `config.h'.
11564
11565 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
11566
11567         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
11568
11569 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11570
11571         Sync from coreutils.
11572         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
11573         gl_CHDIR_SAFER.
11574
11575 2006-02-22  Jim Meyering  <jim@meyering.net>
11576
11577         Sync from coreutils.
11578         * m4/chdir-safer.m4: New file.
11579
11580 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
11581
11582         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
11583         AT_FDCWD exceeds INT_MAX.
11584         * lib/openat.h (AT_FDCWD): Likewise.
11585
11586 2006-02-17  Eric Blake  <address@hidden>
11587
11588         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
11589
11590 2006-02-16  Simon Josefsson  <jas@extundo.com>
11591
11592         * modules/getaddrinfo (Depends-on): Add sys_socket.
11593
11594 2006-02-15  Simon Josefsson  <jas@extundo.com>
11595
11596         * build-aux/maint.mk: Add dsyntax-check rule.
11597
11598 2006-02-15  Eric Blake  <ebb9@byu.net>
11599
11600         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
11601         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
11602         'present but cannot compile' warnings on cygwin.
11603         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
11604         use ws2tcpip.h if sys/socket.h works.
11605         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
11606         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
11607
11608 2006-02-14  Simon Josefsson  <jas@extundo.com>
11609
11610         * modules/maintainer-makefile (Files): Rename.
11611
11612         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
11613         and (the local) Makefile.cfg to maint-cfg.mk.
11614
11615         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
11616         to the latter.
11617
11618         * modules/maintainer-makefile: New module.
11619
11620         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
11621         severaly stripped to make it possible to build it up from scratch
11622         with reliable tests.
11623
11624         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
11625         fixes to permit overriding the default actions when configure and
11626         makefile are not available.
11627
11628 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
11629
11630         Sync from coreutils.
11631         * modules/lstat (Depends-on): Don't depend on xalloc.
11632         (License): Change from GPL to LGPL, since this is now simply a
11633         replacement for a libc function.
11634
11635 2006-02-14  Jim Meyering  <jim@meyering.net>
11636
11637         Sync from coreutils.
11638
11639         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
11640         failure on deficient systems, and simplify gnulib lgpl dependencies.
11641         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
11642         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
11643
11644         * lib/xalloc-die.c: Remove unused definition of N_.
11645
11646 2006-02-14  Jim Meyering  <jim@meyering.net>
11647
11648         Sync from coreutils.
11649         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
11650         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
11651         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
11652         double-quote uses of that variable, to accommodate the rare case in
11653         which getmntent is available in none of the libraries checked.  This
11654         happens at least on FreeBSD 5.0.
11655
11656 2006-02-13  Simon Josefsson  <jas@extundo.com>
11657
11658         * gnulib-tool (Usage): Fix --import, from
11659         karl@freefriends.org (Karl Berry).
11660
11661 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
11662
11663         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
11664
11665 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
11666
11667         * lib/argp-namefrob.h: Restore changes accidentally lost during the
11668         "autoupdate" on 2005-12-12.
11669
11670 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
11671
11672         * modules/closeout (Depends-on): Remove atexit.
11673
11674 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
11675
11676         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
11677         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
11678
11679 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
11680
11681         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
11682         __EXTENSIONS__ if this causes compilation to fail.  Problem
11683         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
11684         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
11685
11686 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
11687
11688         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
11689         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
11690         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
11691         All uses changed.
11692
11693 2006-01-26  Simon Josefsson  <jas@extundo.com>
11694
11695         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
11696         prototype is visible on mingw32.
11697
11698         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
11699         for mingw32.
11700
11701         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
11702         mingw32).
11703
11704 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
11705
11706         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
11707         attempt to open for write; this always fails, at least on POSIX
11708         hosts.  This reinstates the 2006-01-09 change, which was
11709         inadvertently removed.
11710
11711 2006-01-26  Bruno Haible  <bruno@clisp.org>
11712
11713         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
11714         Reported by Paul Eggert.
11715
11716 2006-01-26  Bruno Haible  <bruno@clisp.org>
11717             Paul Eggert  <eggert@cs.ucla.edu>
11718
11719         * lib/stdbool_.h (_Bool)
11720         [(! (defined __cplusplus || defined __BEOS__)
11721           && !defined __GNUC__
11722           && !(defined __HP_cc || defined __xlc__
11723                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
11724                || defined __sgi))]:
11725         #define to signed char in these cases too; this simplifies
11726         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
11727         etc., separately) and makes it more conservative.
11728
11729 2006-01-25  Simon Josefsson  <jas@extundo.com>
11730
11731         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
11732         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
11733         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
11734
11735 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
11736
11737         * lib/argp-namefrob.h: Bugfix. Remove stray #
11738
11739 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
11740
11741         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
11742         so that we test the test.
11743         Check for yet another HP-UX cc bug involving *bool |= bool.
11744
11745 2006-01-25  Karl Berry  <karl@gnu.org>
11746
11747         * config/srclist.txt (vasnprintf.c): sync lost.
11748
11749 2006-01-25  Jim Meyering  <jim@meyering.net>
11750
11751         Sync from the stable (b5) branch of coreutils:
11752
11753         * lib/fts.c (fts_children): Don't let close() clobber errno from
11754         failed fchdir().
11755
11756         * lib/fts.c (fts_stat): When following a symlink-to-directory,
11757         don't necessarily interpret stat-fails+lstat-succeeds as indicating
11758         a dangling symlink.  That can also happen at least for ELOOP.
11759         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
11760         FYI, this bug predates the inclusion of fts.c in coreutils.
11761
11762         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
11763         in their own block, so pre-c99 compilers don't object.
11764
11765         Avoid the double-free (first in fts_read, second in fts_close) that
11766         would occur when an `active' directory is made inaccessible (e.g.,
11767         via chmod a-x) during a traversal.
11768         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
11769         before returning.  Reproduce this failure by
11770         mkdir -p a/b; cd a; chmod a-x . b
11771         Reported by Stavros Passas.
11772
11773 2006-01-25  Jim Meyering  <jim@meyering.net>
11774
11775         * lib/fileblocks.c: Remove more useless parentheses.
11776         * lib/readutmp.h: Likewise.
11777
11778 2006-01-25  Bruno Haible  <bruno@clisp.org>
11779
11780         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
11781         warnings.
11782         Reported by Paul Eggert.
11783
11784 2006-01-25  Bruno Haible  <bruno@clisp.org>
11785
11786         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
11787         rid of a trap command. For Solaris sh.
11788         Reported by Mark D. Baushke <mdb@gnu.org>.
11789
11790 2006-01-24  Simon Josefsson  <jas@extundo.com>
11791
11792         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
11793         Bruno.
11794
11795 2006-01-24  Karl Berry  <karl@gnu.org>
11796
11797         * config/srclist.txt (argp-namefrob.h): sync lost.
11798
11799 2006-01-24  Jim Meyering  <jim@meyering.net>
11800
11801         * modules/openat (Files): Add lib/intprops.h.
11802         From Mark D. Baushke.
11803
11804 2006-01-24  Jim Meyering  <jim@meyering.net>
11805
11806         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
11807         Reported by Mark D. Baushke.
11808
11809 2006-01-24  Jim Meyering  <jim@meyering.net>
11810
11811         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
11812
11813 2006-01-24  Bruno Haible  <bruno@clisp.org>
11814
11815         * modules/strnlen (Maintainer): Change from glibc to all.
11816
11817 2006-01-24  Bruno Haible  <bruno@clisp.org>
11818
11819         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
11820         Patch by Paul Eggert.
11821
11822 2006-01-24  Bruno Haible  <bruno@clisp.org>
11823
11824         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
11825         already has it.
11826         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
11827         2005-11-26.
11828
11829         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
11830         'signed char' to avoid problems with the built-in _Bool type.
11831         Reported by Paul Eggert on 2005-11-26.
11832
11833 2006-01-24  Bruno Haible  <bruno@clisp.org>
11834
11835         * gnulib-tool (func_import): Avoid constructing complicated sed
11836         expressions inside backquote.
11837         Report and solution by Mark D. Baushke <mdb@gnu.org>.
11838
11839 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
11840
11841         These changes imported from libc.
11842         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
11843         test and two separate function calls.
11844         * lib/strndup.c (__strndup): Add libc_hidden_def.
11845
11846 2006-01-23  Simon Josefsson  <jas@extundo.com>
11847
11848         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
11849         Remove the test_*_SOURCES variable: automake infers it by default.
11850         * modules/tls-tests: Likewise.
11851
11852 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11853
11854         Work around porting bugs reported by Dieter in
11855         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
11856         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
11857         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
11858         Include "getopt.h" first, to check interface.
11859         (getenv): Declare only if defined HAVE_DECL_GETENV &&
11860         !HAVE_DECL_GETENV.
11861         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
11862         (__strndup): Revert to K&R-style function dfns, the glibc style.
11863         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
11864         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
11865         Include strnlen.h first, to get prototype properly.
11866         (strnlen): Renamed from __strnlen.
11867         Remove weak alias.
11868
11869 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11870
11871         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
11872
11873 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
11874
11875         * config/srclist.txt: Adjust to reflect glibc reorganization.
11876         This affects only comments.
11877
11878 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11879
11880          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
11881          Reported by Bruce Korb <bkorb@gnu.org>.
11882
11883 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
11884
11885         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
11886         to pacify gcc -Wswitch-default.
11887
11888 2006-01-22  Bruno Haible  <bruno@clisp.org>
11889
11890         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
11891         temporary buffer for sprintf, take into account the precision also
11892         for 'd', 'i', 'u', 'o', 'x', 'X'.
11893
11894 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
11895
11896         * modules/argp-tests: New module
11897         * tests/test-argp.c: New file
11898         * tests/test-argp-2.sh: New file
11899
11900 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
11901
11902         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
11903         (__argp_base_name): Removed
11904         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
11905         typo.
11906         (__argp_base_name): Provide macro definition or extern declaration
11907         depending on the configuration
11908
11909 2006-01-20  Simon Josefsson  <jas@extundo.com>
11910
11911         * modules/inet_ntop (Depends-on): Depend on sys_socket.
11912
11913 2006-01-20  Simon Josefsson  <jas@extundo.com>
11914
11915         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
11916
11917 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
11918
11919         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
11920         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
11921         Suggested by Bruno Haible.
11922
11923 2006-01-20  Karl Berry  <karl@gnu.org>
11924
11925         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
11926         until changes propagate, I guess.
11927
11928 2006-01-19  Simon Josefsson  <jas@extundo.com>
11929
11930         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
11931
11932 2006-01-19  Simon Josefsson  <jas@extundo.com>
11933
11934         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
11935
11936 2006-01-19  Simon Josefsson  <jas@extundo.com>
11937
11938         * gnulib-tool: Set check_PROGRAMS.
11939
11940         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
11941         modules/des-tests, modules/gc-arcfour-tests,
11942         modules/gc-arctwo-tests, modules/gc-des-tests,
11943         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
11944         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
11945         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
11946         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
11947         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
11948         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
11949         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
11950         test_*_SOURCES.
11951
11952 2006-01-18  Simon Josefsson  <jas@extundo.com>
11953
11954         * modules/socklen (Depends-on): Depend on sys_socket.
11955
11956 2006-01-18  Simon Josefsson  <jas@extundo.com>
11957
11958         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
11959         modules/des-tests, modules/gc-arcfour-tests,
11960         modules/gc-arctwo-tests, modules/gc-des-tests,
11961         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
11962         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
11963         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
11964         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
11965         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
11966         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
11967         $(EXEEXT) to automake TESTS variable, for mingw32.
11968
11969 2006-01-17  Simon Josefsson  <jas@extundo.com>
11970
11971         * modules/socklen (Include): Need sys/socket.h.
11972
11973 2006-01-17  Bruno Haible  <bruno@clisp.org>
11974
11975         * modules/ssize_t (Include): Add <sys/types.h>.
11976
11977 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
11978
11979         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
11980         it's not portable and it doesn't work with cross-compiles.
11981         Problem reported by Bruno Haible.  Fix missing-$ typo in
11982         'test "gl_cv_ignore_unused_libraries" ...' that prevented
11983         -zignore from being used with Sun's C compiler.
11984
11985 2006-01-12  Simon Josefsson  <jas@extundo.com>
11986
11987         * lib/base64.c: Fix warning, reported by Bruno Haible
11988         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
11989
11990 2006-01-12  Bruno Haible  <bruno@clisp.org>
11991
11992         * modules/ldd: New file.
11993         * build-aux/ldd.sh.in: New file.
11994         * MODULES.html.sh (Support for building libraries and executables): Add
11995         ldd.
11996
11997 2006-01-12  Bruno Haible  <bruno@clisp.org>
11998
11999         * m4/ldd.m4: New file.
12000
12001 2006-01-12  Bruno Haible  <bruno@clisp.org>
12002
12003         * gnulib-tool (func_import, func_create_testdir): Don't go into an
12004         endless loop while replacing $auxdir with build-aux.
12005
12006 2006-01-11  Simon Josefsson  <jas@extundo.com>
12007
12008         * lib/stdint_.h (SIZE_MAX): Add missing (.
12009
12010 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
12011
12012         Sync from coreutils.
12013         * lib/md5.c: Fix commentary typos.
12014         (alignof, UNALIGNED_P): No need for a GCC-specific version.
12015         * lib/md5.h (__attribute__): Remove; unused.
12016         * lib/sha1.c: Fix commentary to match md5 better.
12017         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
12018         so that we don't need to worry about alignment.  All uses changed.
12019         This merges the 2005-10-28 md5 change into sha1.
12020
12021 2006-01-11  Jim Meyering  <jim@meyering.net>
12022
12023         Sync from coreutils.
12024         * lib/md5.c (OP): Fix spacing.
12025
12026 2006-01-11  Bruno Haible  <bruno@clisp.org>
12027
12028         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12029         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
12030         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
12031
12032 2006-01-11  Bruno Haible  <bruno@clisp.org>
12033
12034         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12035         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
12036         the "early" section as well.
12037
12038 2006-01-11  Bruno Haible  <bruno@clisp.org>
12039
12040         Avoid "ar: no archive members specified" error on MacOS X.
12041         * gnulib-tool (func_modules_add_dummy): New function.
12042         (func_import, func_create_testdir): Invoke it.
12043
12044 2006-01-11  Bruno Haible  <bruno@clisp.org>
12045
12046         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
12047         with $auxdir in AC_CONFIG_FILES statements.
12048
12049 2006-01-11  Bruno Haible  <bruno@clisp.org>
12050
12051         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12052         Initialize also noinst_HEADERS to empty.
12053
12054 2006-01-11  Bruno Haible  <bruno@clisp.org>
12055
12056         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
12057         variables.
12058         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
12059         autoreconf.
12060
12061 2006-01-11  Bruno Haible  <bruno@clisp.org>
12062
12063         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
12064         overridable by the user.
12065         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12066
12067 2006-01-10  Simon Josefsson  <jas@extundo.com>
12068
12069         * modules/sys_socket: New file.
12070
12071 2006-01-10  Simon Josefsson  <jas@extundo.com>
12072
12073         * m4/sys_socket_h.m4: New file.
12074
12075 2006-01-10  Simon Josefsson  <jas@extundo.com>
12076
12077         * lib/socket_.h: New file.
12078
12079 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12080
12081         * modules/readutmp (Maintainer): Add myself.
12082
12083 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12084
12085         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
12086         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
12087         People who are still concerned with buggy memcmp implementations
12088         can invoke gl_FUNC_MEMCMP themselves.
12089
12090 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12091
12092         * lib/regex_internal.h (BITSET_WORD_BITS):
12093         Work around a bug in 64-bit PGC (before version 6.1-2), where the
12094         preprocessor mishandles large unsigned values as if they were signed.
12095         Problem reported by Claudio Fontana in
12096         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
12097
12098 2006-01-10  Jim Meyering  <jim@meyering.net>
12099
12100         Avoid the double-free (first in fts_read, second in fts_close) that
12101         would occur when an `active' directory is made inaccessible (e.g.,
12102         via chmod a-x) during a traversal.
12103         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
12104         before returning.  Reproduce this failure by
12105         mkdir -p a/b; cd a; chmod a-x . b
12106         Reported by Stavros Passas.
12107
12108         Sync from coreutils.
12109         * lib/sha1.c: Tweak grammar in a comment.
12110
12111 2006-01-10  Jim Meyering  <jim@meyering.net>
12112
12113         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
12114         Patch by Joerg Sonnenberger.
12115
12116 2006-01-10  Bruno Haible  <bruno@clisp.org>
12117
12118         * modules/readutmp: Depend on module free.
12119         * modules/strtok_r: Depend on module restrict.
12120
12121 2006-01-10  Bruno Haible  <bruno@clisp.org>
12122
12123         * modules/gettext (configure.ac): Add an invocation of
12124         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
12125
12126 2006-01-10  Bruno Haible  <bruno@clisp.org>
12127
12128         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
12129         Reported by Werner Lemberg <wl@gnu.org>.
12130
12131 2006-01-10  Bruno Haible  <bruno@clisp.org>
12132
12133         * lib/localcharset.c: Update from GNU gettext.
12134
12135 2006-01-10  Bruno Haible  <bruno@clisp.org>
12136
12137         * lib/argp.h (__const): Remove macro. Use const instead.
12138         * lib/argp-fmtstream.h (__const): Likewise.
12139         * lib/glob_.h (__const): Remove macro.
12140         * lib/glob-libc.h: Use const instead of __const.
12141
12142 2006-01-10  Bruno Haible  <bruno@clisp.org>
12143
12144         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
12145         variable.
12146         Needed to avoid an automake error regarding the 'gettext' module.
12147
12148 2006-01-09  Simon Josefsson  <jas@extundo.com>
12149
12150         * modules/inet_ntop (Depends-on): Add restrict.
12151
12152 2006-01-09  Simon Josefsson  <jas@extundo.com>
12153
12154         * modules/gc-rijndael-tests (License): Put under LGPL.
12155
12156         * modules/gc-des-tests (License): Likewise.
12157
12158         * modules/gc-arcfour-tests (License): Likewise.
12159
12160         * modules/gc-arctwo-tests (License): Likewise.
12161
12162         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
12163
12164         * modules/gc-hmac-sha1-tests (Files): Likewise.
12165
12166         * modules/gc-hmac-md5-tests (License): Likewise.
12167
12168         * modules/gc-sha1-tests (License): Likewise.
12169
12170         * modules/gc-md5-tests (License): Likewise.
12171
12172         * modules/gc-md4-tests (License): Likewise.
12173
12174         * modules/gc-md2-tests (License): Likewise.
12175
12176         * modules/gc-tests (License): Likewise.
12177
12178         * modules/des-tests (License): Likewise.
12179
12180         * modules/md4-tests (License): Likewise.
12181
12182         * modules/md2-tests (License): Likewise.
12183
12184 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12185
12186         Sync from coreutils:
12187
12188         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
12189         * modules/lib-ignore: New file.
12190         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
12191         chdir-safer.m4, lchmod.m4.
12192         * modules/openat: Add mkdirat.c, openat-priv.h.
12193
12194 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12195
12196         Sync from coreutils.
12197         * m4/lib-ignore.m4: New file.
12198         * m4/lchmod.m4: New file.
12199
12200 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12201
12202         Sync from coreutils.
12203         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
12204         for write access: POSIX says that must fail.
12205         * lib/fts.c (diropen): Likewise.
12206         * lib/save-cwd.c (save_cwd): Likewise.
12207         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
12208         well, for minor improvements on hosts that lack O_DIRECTORY.
12209         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
12210         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
12211         Fall back on chown if open failed with EACCES.
12212
12213         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
12214         Report an error at compile-time if only a 1-second nominal clock
12215         resolution is found.
12216
12217         * lib/lchmod.h: New file.
12218         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
12219         (make_dir_parents): Use lchown rather than chown, and
12220         lchmod rather than chmod.
12221
12222         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
12223         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
12224         "proc" reported by n0dalus.
12225
12226         * lib/mountlist.c: Include <limits.h>.
12227         (dev_from_mount_options)
12228         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
12229         New function.  It no longer assumes "dev=" has the System V meaning
12230         on Linux (since it doesn't).  It also parses "dev=" more carefully.
12231         (read_file_system_list)
12232         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
12233         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
12234         dev= in that case.
12235
12236         * lib/posixtm.h (PDS_PRE_2000): New macro.
12237         * lib/posixtm.c (year): Arg is now syntax_bits rather than
12238         allow_century.  All usages changed.  Reject dates outside the range
12239         1969-1999 if PDS_PRE_2000 is used.
12240
12241 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12242
12243         Sync from coreutils.
12244         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
12245         (Time of day items): Mention the possibility of leap seconds.
12246         Problem reported by Dr. David Alan Gilbert.
12247
12248 2006-01-09  Jim Meyering  <jim@meyering.net>
12249
12250         Sync from coreutils.
12251
12252         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
12253
12254         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
12255
12256         * lib/modechange.c (mode_compile): Reject an invalid mode string
12257         that starts with an octal digit.  From Andreas Gruenbacher.
12258
12259         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
12260         and dup to open_safer and dup_safer, respectively.
12261         (openat_permissive): Fix typo in comment.
12262
12263         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
12264         "gettext.h"; either no longer needed or are guaranteed by openat.h.
12265         (_): Remove; no longer needed.
12266         (openat): Renamed from rpl_openat; no need for rpl_openat
12267         since openat.h renames openat for us.
12268         Replace most of the body with a call to openat_permissive,
12269         to avoid duplicate code.
12270         Port to (probably hypothetical) environments were mode_t is
12271         wider than int.
12272         (openat_permissive): Require mode arg, so that we can check
12273         types better.  Put it just after flags.  Change cwd failure
12274         indicator from pointer-to-bool to pointer-to-errno-value.
12275         All callers changed.
12276         Invoke openat_save_fail and/or openat_restore_fail if
12277         cwd_errno is null, so that openat can call us.
12278         (openat_permissive, fdopendir, fstatat, unlinkat):
12279         Simplify errno handling to avoid some duplicate code,
12280         as it's OK to set errno on success.
12281         * lib/openat.h: Revamp code so that function macros depend on
12282         __OPENAT_PREFIX only, not also on AT_FDCWD.
12283         (openat_ro): Remove.  Caller changed to use openat_permissive.
12284         (openat_permissive): Now a macro, if not a function.
12285         (openat_restore_fail, openat_save_fail): Now always functions,
12286         since mkdirat needs them even if __OPENAT_PREFIX is defined.
12287
12288         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
12289         and openat.c.
12290         * lib/mkdirat.c: Include openat-priv.h.
12291         Remove definitions of macros defined therein.
12292         * lib/openat.c: Likewise.
12293
12294         * lib/mkdirat.c (mkdirat): New file and function.
12295         * lib/openat.h (mkdirat): Declare.
12296
12297         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
12298
12299         * lib/openat.h (openat_permissive): Declare.
12300         (openat_ro): Define.
12301
12302         * lib/openat.c (EXPECTED_ERRNO): New macro.
12303         (openat_permissive): New function -- used in remove.c rewrite.
12304         (all functions): Set errno just before returning, only if there
12305         was an actual failure.
12306         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
12307
12308         Emulate openat-family functions using Linux's procfs, if possible.
12309         Idea and some code based on Ulrich Drepper's glibc changes.
12310
12311         * lib/openat.c: (BUILD_PROC_NAME): New macro.
12312         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
12313         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
12314         before falling back on save_cwd and restore_cwd.
12315         (fdopendir, fstatat, unlinkat): Likewise.
12316
12317         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
12318         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
12319
12320         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
12321         as second argument to va_arg.  Otherwise, some versions of gcc
12322         warn that `if this code is reached, the program will abort'.
12323
12324 2006-01-09  Jim Meyering  <jim@meyering.net>
12325
12326         Sync from coreutils.
12327         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
12328         Require openat-priv.h.
12329
12330 2006-01-09  Bruno Haible  <bruno@clisp.org>
12331
12332         * modules/strnlen (Include): Use strnlen.h.
12333
12334 2006-01-09  Bruno Haible  <bruno@clisp.org>
12335
12336         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
12337
12338 2006-01-09  Bruno Haible  <bruno@clisp.org>
12339
12340         * lib/sysexit_.h (EX_OK): New macro.
12341         Suggested by Martin Lambers <marlam@marlam.de>.
12342
12343 2006-01-09  Bruno Haible  <bruno@clisp.org>
12344
12345         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
12346         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
12347
12348 2006-01-09  Bruno Haible  <bruno@clisp.org>
12349
12350         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
12351         numbers.
12352
12353 2006-01-09  Bruno Haible  <bruno@clisp.org>
12354
12355         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
12356         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
12357         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
12358         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
12359
12360 2006-01-09  Bruno Haible  <bruno@clisp.org>
12361
12362         * build-aux/javacomp.sh.in: New file, moved from lib/.
12363         * modules/javacomp-script (Files): Update.
12364         (configure.ac): Add AC_CONFIG_FILES invocation.
12365         (EXTRA_DIST): Remove variable.
12366
12367         * build-aux/javaexec.sh.in: New file, moved from lib/.
12368         * modules/javaexec (Files): Update.
12369         (configure.ac): Add AC_CONFIG_FILES invocation.
12370         (EXTRA_DIST): Remove javaexec.sh.in.
12371
12372         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
12373         * modules/csharpcomp-script (Files): Update.
12374         (configure.ac): Add AC_CONFIG_FILES invocation.
12375         (EXTRA_DIST): Remove variable.
12376
12377         * build-aux/csharpexec.sh.in: New file, moved from lib/.
12378         * modules/csharpexec (Files): Update.
12379         (configure.ac): Add AC_CONFIG_FILES invocation.
12380         (EXTRA_DIST): Remove csharpexec.sh.in.
12381
12382 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
12383
12384         Sync from coreutils.
12385
12386         Add POSIX ACL support
12387         * lib/acl.h (copy_acl, set_acl): Add declarations.
12388         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
12389         systems other than Linux.
12390         (chmod_or_fchmod): New function: use fchmod when possible,
12391         and chmod otherwise.
12392         (file_has_acl): Add a POSIX ACL implementation, with a
12393         Linux-specific subcase.
12394         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
12395         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
12396         acls are unsupported.
12397         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
12398         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
12399         are unsupported.
12400
12401 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
12402
12403         Sync from coreutils.
12404         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
12405
12406 2006-01-07  Bruno Haible  <bruno@clisp.org>
12407
12408         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
12409         gl_EARLY.
12410
12411 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
12412
12413         * lib/strftime.c (tzname): Don't declare if it is already #defined.
12414         Problem reported for Mingw by Mark Junker.
12415
12416 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
12417
12418         * README: Gnulib normally doesn't generate a tarball.
12419
12420 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
12421
12422         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
12423         long int, not int, for nanosecond counts, so that people who are
12424         used to POSIX struct timespec won't be surprised.  Reported by Jim
12425         Meyering.
12426
12427 2005-12-28  Bruno Haible  <bruno@clisp.org>
12428
12429         * build-aux/config.rpath: Update from GNU gettext.
12430
12431 2005-12-16  Jim Meyering  <jim@meyering.net>
12432
12433         * modules/fprintftime: New module.
12434         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
12435
12436 2005-12-16  Jim Meyering  <jim@meyering.net>
12437
12438         * m4/fprintftime.m4: New file.
12439
12440 2005-12-16  Jim Meyering  <jim@meyering.net>
12441
12442         * lib/fprintftime.c, lib/fprintftime.h: New files.
12443
12444 2005-12-15  Simon Josefsson  <jas@extundo.com>
12445
12446         * modules/socklen (configure.ac): Fix M4 macro name, to align with
12447         new m4/socklen.m4.
12448
12449 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
12450
12451         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
12452         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
12453
12454 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
12455
12456         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
12457         * lib/argp-help.c (fill_in_uparams): Check if the constructed
12458         struct uparams is valid. Fall back to the default values if it is
12459         not.
12460
12461 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12462
12463         * modules/argp (Files): Add argp-pin.c
12464         (Depends-on): dirname
12465         (lib_SOURCES): Add argp-pin.c
12466
12467 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12468
12469         * m4/argp.m4:  Check if program_invocation_name and
12470         program_invocation_short_name are declared and define appropriate
12471         macros if they are not.
12472
12473 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
12474
12475         * lib/argp-help.c (__argp_base_name): New function
12476         (__argp_short_program_name): Rewrite using __argp_base_name
12477         * lib/argp-namefrob.h: Define program_invocation_name and
12478         program_invocation_short_name if requested
12479         (__argp_base_name): Add prototype
12480         * lib/argp-parse.c (argp_def): Use gettext wrappers
12481         (argp_default_parser): Use __argp_base_name
12482         * lib/argp-pin.c: New file. Defines program_invocation_name and
12483         program_invocation_short_name on systems that lack them.
12484
12485 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
12486
12487         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
12488         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
12489         porting problem reported by Georg Schwarz in
12490         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
12491
12492 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
12493
12494         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
12495         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
12496         porting problem reported by Georg Schwarz in
12497         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
12498
12499 2005-12-05  Bruno Haible  <bruno@clisp.org>
12500
12501         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
12502         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
12503         Reported by Mark Junker <mjscod@gmx.de>.
12504
12505 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
12506
12507         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
12508         Use implementation from Albert Chin, with some
12509         comments/corrections by Stepan Kasal and myself.
12510
12511 2005-12-02  Bruno Haible  <bruno@clisp.org>
12512
12513         * gnulib-tool (func_import): Accept GPLed build tool modules when
12514         --lgpl is given.
12515         * modules/csharpcomp-script: New file.
12516         * modules/csharpcomp: Depend on it.
12517         * modules/javacomp-script: New file.
12518         * modules/javacomp: Depend on it.
12519         Suggested by Simon Josefsson.
12520
12521 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
12522
12523         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
12524         statement, to work around an HP-UX 10.20 compiler bug reported by
12525         Peter O'Gorman.
12526
12527 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
12528
12529         * modules/savedir (Depends-on): Add openat.
12530
12531 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
12532
12533         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
12534         (uintmax_t) [defined uintmax_t]: Do not declare.
12535         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
12536         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
12537         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
12538         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
12539         sake of portability to weird hosts that C allows (though we don't
12540         know of any practical examples).
12541
12542         * lib/savedir.h (fdsavedir): New decl.
12543         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
12544         contains most of the former guts of savedir.
12545         (savedir): Use savedirstream.
12546         Include "openat.h".
12547
12548 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
12549
12550         * modules/obstack (Files): Add m4/ulonglong.m4.
12551         Problem reported by Davide Angelocola.
12552
12553 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
12554
12555         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
12556         coreutils no longer futzes with rounding modes.
12557
12558 2005-11-14  Jim Meyering  <jim@meyering.net>
12559
12560         * lib/mkstemp-safer.c: Include <config.h>, required for possible
12561         replacement of mkstemp.
12562
12563 2005-11-10  Simon Josefsson  <jas@extundo.com>
12564
12565         * lib/readline.c: Remove EOL.
12566
12567 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12568
12569         * modules/gethrxtime (Depends-on): Add gettime.
12570
12571 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12572
12573         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
12574         or gettimeofday; no longer needed.
12575
12576 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
12577
12578         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
12579         time business.
12580         (gethrxtime) [! (HAVE_NANOUPTIME
12581         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
12582         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
12583         our own approximation.
12584
12585 2005-11-08  Eric Blake  <ebb9@byu.net>
12586
12587         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
12588
12589 2005-11-08  Eric Blake  <ebb9@byu.net>
12590
12591         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
12592
12593 2005-11-04  Bruno Haible  <bruno@clisp.org>
12594
12595         * gnulib-tool: Implement --update mode.
12596
12597 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
12598
12599         Fix porting problem reported by Theodoros V. Kalamatianos.
12600         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
12601         Don't assume that futimes failing means we must fail.
12602
12603 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
12604
12605         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
12606         variables to suggest the intended function of the PATH_MAX check.
12607
12608 2005-10-30  Kean Johnston  <jkj@sco.com>
12609
12610         Trivial changes to support SCO systems.
12611         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
12612         as PATH_MAX.
12613         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
12614         where __ptr is null when no I/O is pending.
12615
12616 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
12617
12618         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
12619         leave errno alone.  Problem reported by Dmitry V. Levin.
12620
12621 2005-10-28  Simon Josefsson  <jas@extundo.com>
12622
12623         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
12624         Test more.
12625
12626         * tests/test-gc-md2.c, tests/test-md2.c: New files.
12627
12628         * modules/md2, modules/md2-tests: New files.
12629
12630 2005-10-28  Simon Josefsson  <jas@extundo.com>
12631
12632         * m4/inet_ntop.m4: More tests.
12633
12634         * m4/gc-md2.m4, md2.m4: New file.
12635
12636 2005-10-28  Simon Josefsson  <jas@extundo.com>
12637
12638         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
12639         "restrict" keywords, as per POSIX.  Protect the function
12640         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
12641         Don't use K&R prototypes.  Check the sprintf return values.
12642         Re-define EAFNOSUPPORT if not present.  Indent.
12643
12644         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
12645         suggested by Bruno Haible <bruno@clisp.org>.
12646
12647         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
12648
12649         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
12650
12651         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
12652         libgcrypt).
12653
12654         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
12655
12656         * lib/md2.h, lib/md2.c: New files.
12657
12658 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
12659
12660         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
12661         errno alone.  Problem reported by Frederic Jolliton.
12662
12663 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
12664
12665         * modules/verify (License): Change from GPL to LGPL.  This is a
12666         tiny module and there are apparently near-equivalents that are
12667         under the BSD license.
12668
12669 2005-10-24  Simon Josefsson  <jas@extundo.com>
12670
12671         * modules/sha1: Relicense to LGPL.
12672
12673 2005-10-24  Simon Josefsson  <jas@extundo.com>
12674
12675         * lib/md4.h: Shrink buffer size, now that we changed the type.
12676
12677 2005-10-23  Simon Josefsson  <jas@extundo.com>
12678
12679         * gnulib-tool (func_import): Fix --tests-base.
12680
12681 2005-10-22  Simon Josefsson  <jas@extundo.com>
12682
12683         * modules/arcfour (Depends-on): Need stdint.
12684
12685 2005-10-22  Simon Josefsson  <jas@extundo.com>
12686
12687         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
12688         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
12689
12690 2005-10-22  Simon Josefsson  <jas@extundo.com>
12691
12692         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
12693         suggested by Bruno Haible <bruno@clisp.org>.
12694
12695 2005-10-22  Simon Josefsson  <jas@extundo.com>
12696
12697         * lib/crc.h: Include stddef.h, for size_t.
12698
12699 2005-10-22  Simon Josefsson  <jas@extundo.com>
12700
12701         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
12702         arcfour_context struct (simplify test vector testing in GNU
12703         Shishi).
12704
12705 2005-10-21  Simon Josefsson  <jas@extundo.com>
12706
12707         * modules/des, modules/des-tests: New files.
12708
12709         * modules/gc-des, modules/gc-des-tests: New files.
12710
12711         * tests/test-des.c, tests/test-gc-des.c: New file.
12712
12713 2005-10-21  Simon Josefsson  <jas@extundo.com>
12714
12715         * modules/arctwo, modules/arctwo-tests: New files.
12716
12717         * tests/test-arctwo.c: New file.
12718
12719         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
12720
12721         * tests/test-gc-arctwo.c: New file.
12722
12723 2005-10-21  Simon Josefsson  <jas@extundo.com>
12724
12725         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
12726         Bruno Haible <bruno@clisp.org>.
12727
12728         * m4/gc-des.m4: New file.
12729
12730 2005-10-21  Simon Josefsson  <jas@extundo.com>
12731
12732         * m4/arctwo.m4: New file.
12733
12734         * m4/gc-arctwo.m4: New file.
12735
12736 2005-10-21  Simon Josefsson  <jas@extundo.com>
12737
12738         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
12739         block.
12740
12741 2005-10-21  Simon Josefsson  <jas@extundo.com>
12742
12743         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
12744         <bruno@clisp.org>.
12745
12746         * lib/hmac-sha1.c (hmac_sha1): Likewise.
12747
12748         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
12749         Bruno Haible <bruno@clisp.org>.
12750
12751         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
12752         <bruno@clisp.org>.
12753
12754 2005-10-21  Simon Josefsson  <jas@extundo.com>
12755
12756         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
12757
12758 2005-10-21  Simon Josefsson  <jas@extundo.com>
12759
12760         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
12761
12762 2005-10-21  Simon Josefsson  <jas@extundo.com>
12763
12764         * lib/des.h, lib/des.c: New files.
12765
12766         * lib/gc-gnulib.c: Support DES.c
12767
12768 2005-10-21  Simon Josefsson  <jas@extundo.com>
12769
12770         * lib/arctwo.h, lib/arctwo.c: New files.
12771
12772         * lib/gc-gnulib.c: Support ARCTWO.
12773
12774 2005-10-21  Simon Josefsson  <jas@extundo.com>
12775
12776         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
12777         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12778
12779 2005-10-21  Simon Josefsson  <jas@extundo.com>
12780
12781         * gnulib-tool (func_import, func_create_testdir): Define automake
12782         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
12783         Makefile.am snippet),
12784         suggested by Bruno Haible <bruno@clisp.org>.
12785
12786         * modules/gc (Makefile.am): Use it.
12787
12788 2005-10-21  Bruno Haible  <bruno@clisp.org>
12789
12790         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
12791         patch.
12792
12793 2005-10-19  Simon Josefsson  <jas@extundo.com>
12794
12795         * tests/test-gc-rijndael.c: New file.
12796
12797         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
12798
12799 2005-10-19  Simon Josefsson  <jas@extundo.com>
12800
12801         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
12802         interface too.
12803
12804 2005-10-19  Simon Josefsson  <jas@extundo.com>
12805
12806         * tests/test-gc-arcfour.c: New file.
12807
12808         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
12809
12810 2005-10-19  Simon Josefsson  <jas@extundo.com>
12811
12812         * modules/gc-md4, modules/gc-md4-tests: New file.
12813
12814         * tests/test-gc-md4.c: New file.
12815
12816 2005-10-19  Simon Josefsson  <jas@extundo.com>
12817
12818         * m4/gc-md4.m4: New file.
12819
12820 2005-10-19  Simon Josefsson  <jas@extundo.com>
12821
12822         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
12823         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
12824         <kasal@ucw.cz>.
12825
12826 2005-10-19  Simon Josefsson  <jas@extundo.com>
12827
12828         * m4/gc-arcfour.m4: New file.
12829
12830         * m4/gc-rijndael.m4: New file.
12831
12832 2005-10-19  Simon Josefsson  <jas@extundo.com>
12833
12834         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
12835
12836 2005-10-19  Simon Josefsson  <jas@extundo.com>
12837
12838         * lib/gc-gnulib.c: Support ARCFOUR.
12839
12840 2005-10-19  Simon Josefsson  <jas@extundo.com>
12841
12842         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
12843         support.
12844
12845         * lib/gc.h: Add ECB enum type.
12846
12847         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
12848
12849 2005-10-18  Simon Josefsson  <jas@extundo.com>
12850
12851         * tests/test-md5.c: New file.
12852
12853         * modules/md5-tests: New file.
12854
12855 2005-10-18  Simon Josefsson  <jas@extundo.com>
12856
12857         * tests/test-md4.c: New file.
12858
12859         * modules/md4, modules/md4-tests: New files.
12860
12861 2005-10-18  Simon Josefsson  <jas@extundo.com>
12862
12863         * m4/md4.m4: New file.
12864
12865 2005-10-18  Simon Josefsson  <jas@extundo.com>
12866
12867         * lib/md4.h, lib/md4.c: New files, based on md5.?.
12868
12869 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
12870
12871         * gnulib-tool (func_create_testdir): Omit the second check whether
12872         BUILT_SOURCES in nonempty.
12873
12874 2005-10-17  Simon Josefsson  <jas@extundo.com>
12875
12876         * tests/test-rijndael.c: New file.
12877
12878 2005-10-17  Simon Josefsson  <jas@extundo.com>
12879
12880         * modules/sha1: Depend on stdint instead of md5.
12881
12882         * modules/md5: Depend on stdint, remove uint32_t.
12883
12884 2005-10-17  Simon Josefsson  <jas@extundo.com>
12885
12886         * modules/gc-sha1-tests: New file.
12887
12888         * tests/test-gc-sha1.c: New file.
12889
12890 2005-10-17  Simon Josefsson  <jas@extundo.com>
12891
12892         * m4/md5.m4: Remove call to uint32_t.m4.
12893
12894 2005-10-17  Simon Josefsson  <jas@extundo.com>
12895
12896         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
12897
12898         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
12899         md5.h.
12900
12901         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
12902
12903         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
12904
12905 2005-10-17  Simon Josefsson  <jas@extundo.com>
12906
12907         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
12908
12909 2005-10-17  Simon Josefsson  <jas@extundo.com>
12910
12911         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
12912
12913 2005-10-17  Simon Josefsson  <jas@extundo.com>
12914
12915         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
12916
12917         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
12918
12919 2005-10-17  Bruno Haible  <bruno@clisp.org>
12920
12921         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
12922         that it can also be used in a test.
12923
12924 2005-10-16  Bruno Haible  <bruno@clisp.org>
12925
12926         * gnulib-tool (func_emit_tests_Makefile_am): Also define
12927         TESTS_ENVIRONMENT, so that individual tests can augment it.
12928
12929         * gnulib-tool (func_create_testdir): Use an intermediate target for
12930         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
12931         macros, like $(ALLOCA_H), which cannot be passed through the command
12932         line.
12933
12934 2005-10-15  Simon Josefsson  <jas@extundo.com>
12935
12936         * modules/rijndael-tests: New file.
12937
12938         * modules/rijndael: New file.
12939
12940 2005-10-15  Simon Josefsson  <jas@extundo.com>
12941
12942         * m4/rijndael.m4: New file.
12943
12944 2005-10-15  Simon Josefsson  <jas@extundo.com>
12945
12946         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
12947
12948         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
12949
12950 2005-10-14  Simon Josefsson  <jas@extundo.com>
12951
12952         * tests/test-arcfour.c: New file.
12953
12954         * modules/arcfour, modules/arcfour-tests: New files.
12955
12956 2005-10-14  Simon Josefsson  <jas@extundo.com>
12957
12958         * m4/arcfour.m4: New file.
12959
12960 2005-10-14  Simon Josefsson  <jas@extundo.com>
12961
12962         * lib/arcfour.h, lib/arcfour.c: New files.
12963
12964 2005-10-14  Roland McGrath  <roland@redhat.com>
12965
12966         Import from libc.  [BZ #1331]
12967         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
12968         macro argument.
12969         Reported by Matej Vela <vela@debian.org>.
12970
12971 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
12972
12973         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
12974         include <wchar.h>; no longer needed.
12975
12976 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
12977
12978         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
12979
12980 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
12981         and  Ulrich Drepper  <drepper@redhat.com>
12982
12983         Import from libc.
12984         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
12985         instead of inline stream orientation test and two separate
12986         function calls.  Pay no attention to USE_IN_LIBIO.
12987
12988 2005-10-13  Simon Josefsson  <jas@extundo.com>
12989
12990         * modules/gc-hmac-md5-tests: New file.
12991
12992         * tests/test-gc-hmac-sha1.c: New file.
12993
12994         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
12995
12996         * modules/gc-hmac-md5-tests: New file.
12997
12998         * tests/test-gc-md5.c: New file.
12999
13000         * modules/gc-md5-tests: New file.
13001
13002 2005-10-13  Simon Josefsson  <jas@extundo.com>
13003
13004         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
13005         Move memory allocation outside of loop.
13006
13007 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
13008
13009         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
13010         intermediate directory is in a read-only file system.  Problem
13011         reported by Eric Blake.
13012
13013 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
13014
13015         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
13016
13017 2005-10-12  Simon Josefsson  <jas@extundo.com>
13018
13019         * tests/test-hmac-sha1.c: New file.
13020
13021         * modules/hmac-sha1-tests: New file.
13022
13023         * modules/hmac-sha1: New file.
13024
13025 2005-10-12  Simon Josefsson  <jas@extundo.com>
13026
13027         * modules/gc-sha1: New file.
13028
13029 2005-10-12  Simon Josefsson  <jas@extundo.com>
13030
13031         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
13032
13033         * tests/test-gc-pbkdf2-sha1.c: New file.
13034
13035 2005-10-12  Simon Josefsson  <jas@extundo.com>
13036
13037         * modules/gc-md5, modules/gc-hmac-md5: New files.
13038
13039         * modules/gc (Files): Remove md5, memxor and hmac files.
13040
13041 2005-10-12  Simon Josefsson  <jas@extundo.com>
13042
13043         * m4/gc-pbkdf2-sha1.m4: New file.
13044
13045         * m4/gc-hmac-sha1.m4: New file.
13046
13047         * m4/gc-sha1: New file.
13048
13049         * m4/hmac-sha1.m4: New file.
13050
13051 2005-10-12  Simon Josefsson  <jas@extundo.com>
13052
13053         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
13054
13055         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
13056
13057 2005-10-12  Simon Josefsson  <jas@extundo.com>
13058
13059         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
13060         suggested by Bruno Haible <bruno@clisp.org>.
13061
13062 2005-10-12  Simon Josefsson  <jas@extundo.com>
13063
13064         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
13065
13066 2005-10-12  Simon Josefsson  <jas@extundo.com>
13067
13068         * lib/gc-pbkdf2-sha1.c: New file.
13069
13070         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
13071
13072 2005-10-12  Simon Josefsson  <jas@extundo.com>
13073
13074         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
13075
13076         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
13077
13078 2005-10-12  Simon Josefsson  <jas@extundo.com>
13079
13080         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
13081         GC_USE_HMAC_MD5, respectively.
13082
13083         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
13084         (gc_md5): Fix typo.
13085
13086         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
13087
13088         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
13089
13090         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
13091
13092 2005-10-12  Bruno Haible  <bruno@clisp.org>
13093
13094         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
13095         Reported by Stepan Kasal <kasal@ucw.cz>.
13096
13097 2005-10-11  Simon Josefsson  <jas@extundo.com>
13098
13099         * tests/test-crc.c: New file.
13100
13101         * modules/crc, modules/crc-tests: New files.
13102
13103 2005-10-11  Simon Josefsson  <jas@extundo.com>
13104
13105         * m4/crc.m4: New file.
13106
13107 2005-10-11  Simon Josefsson  <jas@extundo.com>
13108
13109         * lib/gc.h: Add gc_hash and gc_hash_buffer.
13110
13111         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
13112
13113         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
13114
13115 2005-10-11  Simon Josefsson  <jas@extundo.com>
13116
13117         * lib/crc.h, lib/crc.c: New files.
13118
13119         * lib/gc.h (gc_hash_buffer): Add doc.
13120
13121 2005-10-11  Bruno Haible  <bruno@clisp.org>
13122
13123         * modules/c-strcasestr: New file.
13124         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
13125
13126 2005-10-11  Bruno Haible  <bruno@clisp.org>
13127
13128         * modules/c-strcase: New file.
13129         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
13130
13131 2005-10-11  Bruno Haible  <bruno@clisp.org>
13132
13133         * lib/strcasecmp.c: Include limits.h.
13134         (strcasecmp): Avoid integer overflow on exotic platforms.
13135         * lib/strncasecmp.c: Include limits.h.
13136         (strncasecmp): Avoid integer overflow on exotic platforms.
13137         Reported by Paul Eggert.
13138
13139 2005-10-11  Bruno Haible  <bruno@clisp.org>
13140
13141         * lib/c-strcasestr.h: New file, from GNU gettext.
13142         * lib/c-strcasestr.c: New file, from GNU gettext.
13143
13144 2005-10-11  Bruno Haible  <bruno@clisp.org>
13145
13146         * lib/c-strcase.h: New file, from GNU gettext.
13147         * lib/c-strcasecmp.c: New file, from GNU gettext.
13148         * lib/c-strncasecmp.c: New file, from GNU gettext.
13149
13150 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
13151
13152         * modules/mempcpy (License): GPL -> LGPL.
13153         * modules/strchrnul (License): Likewise.
13154         * modules/sysexits (License): Likewise.
13155
13156 2005-10-08  Simon Josefsson  <jas@extundo.com>
13157
13158         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
13159
13160 2005-10-07  Simon Josefsson  <jas@extundo.com>
13161
13162         * m4/memxor.m4: Remove gl_C_RESTRICT call.
13163
13164 2005-10-06  Simon Josefsson  <jas@extundo.com>
13165
13166         * tests/test-hmac-md5.c: New file.
13167
13168         * modules/hmac-md5-tests: New file.
13169
13170         * modules/hmac-md5: New file.
13171
13172 2005-10-06  Simon Josefsson  <jas@extundo.com>
13173
13174         * m4/hmac-md5.m4: New file.
13175
13176         * m4/memxor.m4: Require gl_C_RESTRICT.
13177
13178 2005-10-06  Simon Josefsson  <jas@extundo.com>
13179
13180         * lib/memxor.c (memxor): Avoid casts and warnings.
13181
13182 2005-10-06  Simon Josefsson  <jas@extundo.com>
13183
13184         * lib/hmac-md5.c: New file.
13185
13186         * lib/hmac.h: New file.
13187
13188 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
13189
13190         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
13191         promotes to int, not unsigned int, to catch the AIX 5.3
13192         compiler bug.
13193
13194 2005-10-05  Simon Josefsson  <jas@extundo.com>
13195
13196         * modules/memxor: New file.
13197
13198         * modules/iconv (Files): Move config.rpath to havelib, it is used
13199         there.
13200
13201         * modules/havelib (Files): Add config.rpath.
13202
13203 2005-10-05  Simon Josefsson  <jas@extundo.com>
13204
13205         * m4/memxor.m4: New file.
13206
13207 2005-10-05  Simon Josefsson  <jas@extundo.com>
13208
13209         * lib/memxor.c (memxor): Fix compiler error.
13210
13211         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
13212         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
13213
13214         * lib/memxor.h, lib/memxor.c: New files.
13215
13216         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
13217         we assume all systems have it, suggested by Jim Meyering
13218         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
13219         any systems lack sys/socket.h; mingw32 is known to lack it, but we
13220         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
13221         same reasons.
13222
13223 2005-10-05  Simon Josefsson  <jas@extundo.com>
13224
13225         * config/srclist.txt: Add glibc bug 1423 for md5.h.
13226
13227 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
13228
13229         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
13230         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
13231         needed, since the source code now assumes these .h files.
13232
13233 2005-10-05  Derek Price  <derek@ximbiot.com>
13234
13235         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
13236
13237 2005-10-05  Bruno Haible  <bruno@clisp.org>
13238
13239         * modules/stdint (License): Change to LGPL.
13240
13241 2005-10-04  Simon Josefsson  <jas@extundo.com>
13242
13243         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
13244         D. Baushke" <mdb@gnu.org>.
13245
13246 2005-10-04  Bruno Haible  <bruno@clisp.org>
13247
13248         * lib/verify.h (verify_true): Provide alternative definition for C++.
13249
13250 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
13251
13252         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
13253         (SSIZE_MAX): New macro, if not already defined.
13254         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
13255         than 2 GiB.
13256
13257 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13258
13259         Sync from coreutils.
13260         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
13261         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
13262         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
13263         ULLONG_MAX doesn't work with 2.7.2.1.
13264
13265 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13266
13267         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
13268         From Ben Pfaff.
13269
13270         * modules/exclude (Depends-on): Depend on verify.
13271         * modules/strtoimax (Depends-on): Likewise.
13272         * modules/utimecmp (Depends-on): Likewise.
13273
13274 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13275
13276         * lib/exclude.c: Include verify.h.
13277         (verify): Remove.  All callers changed to use verify.h's version.
13278         * lib/strtoimax.c: Likewise.
13279         * lib/utimecmp.c: Likewis.e
13280
13281         Sync from coreutils.
13282         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
13283         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
13284         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
13285         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
13286         bother returning ENOSYS if settimeofday or stime fails; just let
13287         them return whatever errno they want to return.
13288         * lib/utimens.c: Include unistd.h, for dup2.
13289         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
13290         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
13291
13292 2005-10-02  Jim Meyering  <jim@meyering.net>
13293
13294         Sync from coreutils.
13295         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
13296         from glibc-2.2.5 that fails for read-only files.
13297
13298 2005-10-02  Jim Meyering  <jim@meyering.net>
13299
13300         Sync from coreutils.
13301         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
13302         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
13303         `#if HAVE_CONFIG_H'.
13304         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
13305         Remove AT_FDCWD test.
13306         Do not consume the fd unless successful.
13307         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
13308         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
13309         block, so that we don't even try to compile it if settimeofday is
13310         available.  This works around a compilation failure on OSF1 V5.1,
13311         due to stime requiring a `long int*' while tv_sec is `int'.
13312
13313 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
13314
13315         Sync from coreutils.
13316         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
13317         against `yes', rather than just testing for nonempty.
13318
13319 2005-10-01  Simon Josefsson  <jas@extundo.com>
13320
13321         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
13322         and Darwin.
13323
13324         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
13325         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
13326         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
13327         freeaddrinfo and gai_strerror are declared by the POSIX headers.
13328         Check if struct addrinfo is declared.
13329
13330 2005-10-01  Simon Josefsson  <jas@extundo.com>
13331
13332         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
13333         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
13334         AI_* and EAI_* definitions.  Protect function declarations.
13335
13336 2005-10-01  Jim Meyering  <jim@meyering.net>
13337
13338         Sync from coreutils.
13339
13340         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
13341         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
13342         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
13343         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
13344         in the inet and nsl libraries.  Required on Solaris 5.7.
13345
13346 2005-10-01  Jim Meyering  <jim@meyering.net>
13347
13348         Sync from coreutils.
13349         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
13350         in the inet and nsl libraries.  Required on Solaris 5.7.
13351
13352 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
13353
13354         * lib/getdelim.c (getdelim): Remove unused variables.
13355
13356 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
13357
13358         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
13359         so that the code works even with ancient cpp.  Portability problem
13360         with GCC 2.7.2.1 reported by Thomas M.Ott.
13361
13362 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
13363
13364         * modules/regex (Depends-on): Add strcase.
13365
13366         * modules/gethostname (Licence): Change from GPL to LGPL, since
13367         gethostname.c is a trivial implementation of a standard library
13368         function.
13369         * modules/poll (License): Change from GPL to LGPL, since it's
13370         derived from LGPL code.
13371
13372 2005-09-27  Jim Meyering  <jim@meyering.net>
13373
13374         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
13375         HAVE_CONFIG_H.
13376
13377         * lib/intprops.h (signed_type_or_expr__): Define.
13378         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
13379         for unsigned types.
13380
13381 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
13382
13383         * lib/verify.h (verify_expr): Remove, replacing with:
13384         (verify_true): New macro that returns true instead of void.
13385         (verify_type__): Remove.
13386         (verify): Use verify_true rather than verify_type__.
13387
13388 2005-09-26  Bruno Haible  <bruno@clisp.org>
13389
13390         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
13391         is necessary.
13392         (lib_SOURCES): Remove mbchar.c.
13393         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
13394         (Files): Add m4/mbrtowc.m4.
13395         * modules/mbiter: Likewise.
13396         * modules/mbuiter: Likewise.
13397
13398 2005-09-26  Bruno Haible  <bruno@clisp.org>
13399
13400         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
13401         compile mbchar.c if they are not both present.
13402         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
13403         * m4/mbiter.m4 (gl_MBITER): Likewise.
13404         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
13405         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
13406         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
13407
13408 2005-09-25  Jim Meyering  <jim@meyering.net>
13409
13410         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
13411         also uses socklen_t.
13412
13413 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
13414
13415         * lib/utimens.c (ENOSYS): Define if not already defined.
13416         (futimens): Support having a null PATH if the file descriptor
13417         is nonnegative.
13418
13419         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
13420         Remove.
13421         (__attribute): Define to empty unless GCC 3.1 or later.
13422         This works around a core dump on OpenBSD 3.4, which has GCC
13423         2.95.3, which dumps core when given __attribute__(()).  It also
13424         simplifies other tests, since we really don't want to bother with
13425         worrying about which ancient version of GCC supported what.
13426         Original problem reported by Yoann Vandoorselaere, with part of
13427         the fix suggested by Derek Price.
13428
13429 2005-09-24  Jim Meyering  <jim@meyering.net>
13430
13431         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
13432         so we can once again use a positive bitfield width of 1 -- now we
13433         don't have to explain why we were using a bitfield width of 2.
13434
13435 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
13436
13437         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
13438         and similarly for the other external symbols.  Problem reported
13439         by James Gallager.
13440
13441         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
13442         bug reported by Jim Meyering.
13443
13444         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
13445         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
13446         not needed, since socklen is a prerequisite module.
13447
13448 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
13449
13450         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
13451         Problem reported by Eric Blake.
13452         (getaddrinfo): Initialize se so that it's not garbage.
13453         Redo internal storage allocation so that it doesn't make unportable
13454         assumptions about alignment.
13455         Fix a memory leak.
13456
13457         * lib/utimens.c (futimens): Use futimesat if available.
13458         Prefer it to futimes since it doesn't have the futimes bug.
13459
13460         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
13461         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
13462         Instead, declare a function that returns a pointer to an array,
13463         and use verify_type__ to declare the size of the array.
13464         Problem and germ of a solution reported by Bruno Haible.
13465         (verify_type__): Use 2, not 1, for bitfield size, to avoid
13466         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
13467
13468 2005-09-23  Jim Meyering  <jim@meyering.net>
13469
13470         Sync from coreutils.
13471         Correct build failure (socklen_t not defined) on at least
13472         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
13473         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
13474
13475 2005-09-23  Jim Meyering  <jim@meyering.net>
13476
13477         * modules/getaddrinfo (Depends-on): Add socklen.
13478
13479 2005-09-23  Bruno Haible  <bruno@clisp.org>
13480
13481         * tests/test-verify.c: New file.
13482
13483 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13484
13485         Sync from coreutils.
13486
13487         * modules/argmatch (Depends-on): Add verify.
13488         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
13489         unistd-safer.
13490         * modules/save-cwd (Depends-on): Likewise.
13491
13492         * modules/openat (Files): Add lib/openat-die.c.
13493         (Depends-on): Remove error, exitfail.
13494         Add dirname.
13495
13496         * modules/verify: New file.
13497         * MODULES.html.sh (Diagnostics <assert.h>): New section,
13498         with "verify" module.
13499
13500 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13501
13502         Sync from coreutils.
13503
13504         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
13505         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
13506         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
13507         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
13508         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
13509         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
13510         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
13511         Don't bother checking for string.h, stdlib.h, unistd.h.
13512         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
13513         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
13514         module's job.
13515         * m4/jm-macros.m4 (gl_MACROS): Likewise.
13516         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
13517
13518         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
13519         (gl_GETDATE): Use it.
13520
13521         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
13522
13523 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13524
13525         Sync from coreutils.
13526
13527         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
13528         stat-time.h.
13529         * lib/argmatch.h: Include verify.h
13530         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
13531         (ARGMATCH_ASSERT): Remove; unused.
13532         * lib/canonicalize.c: Assume STDC_HEADERS.
13533         * lib/exclude.c: Include "strcase.h".
13534         * lib/regex_internal.h [!defined _LIBC]: Likewise.
13535         * lib/getusershell.c: Include stdio--.h rather than stdio.h
13536         and stdio-safer.h.
13537         (getusershell): Call fopen, not fopen_safer.
13538         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
13539         Do not include unistd-safer.h.
13540         (save_cwd): Don't call fd_safer; no longer needed
13541         now that we include fcntl--.h.
13542
13543         * lib/getdate.y (relative_time): New type.
13544         (RELATIVE_TIME_0): New constant.
13545         (parser_control): Use relative_time instead of doing it ourselves.
13546         (%union): Add new relative_time rel member.
13547         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
13548         Now typeless.
13549         (relunit, relunit_snumber): Now of type rel.
13550         (zone, rel, relunit, get_date): Adjust to above changes.
13551
13552         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
13553         Do not include unistd-safer.h.
13554         (getloadavg): Don't call fd_safer; no longer needed
13555         now that we include fcntl--.h.
13556
13557         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
13558         (make_dir_parents): Treat ENOSYS like EEXIST.
13559
13560         Improve quality of diagnostics on restore_cwd failure.
13561         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
13562         (make_dir_parents): Last arg is now int * (for errno), not bool *.
13563         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
13564         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
13565         each time through the loop.  Do not diagnose restore_cwd failure;
13566         that is the caller's job (and perhaps the caller does not care).
13567
13568         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
13569         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
13570         If the file already exists but is not a directory, don't bother
13571         to try to make its parents.
13572         Close potential file descriptor leak if we can't chdir("/") (!).
13573         Don't always return true if chdir($PWD) fails; return true only
13574         if the requested action was done successfully (except for the
13575         chdir($PWD)).
13576         Don't log final directory unless we actually made it.
13577         Refactor to avoid duplicate code to fix up permissions.
13578         Don't attempt to fix up parent permissions if chdir($PWD) fails.
13579
13580         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
13581         to make it a bit faster and (I hope) clearer.
13582         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
13583         Fix bug in formats like %2N.
13584
13585         * lib/verify.h: New file.
13586
13587 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
13588
13589         Sync from coreutils.
13590         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
13591
13592 2005-09-22  Jim Meyering  <jim@meyering.net>
13593
13594         Sync from coreutils.
13595
13596         * m4/lstat.m4 (gl_FUNC_LSTAT):
13597         Use AC_LIBSOURCES to require lstat.c and lstat.h.
13598         Remove obsolete comment.
13599         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
13600         * m4/xstrtod.m4: Likewise.
13601
13602         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
13603
13604 2005-09-22  Jim Meyering  <jim@meyering.net>
13605
13606         Sync from coreutils.
13607
13608         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
13609
13610         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
13611         the .tm_year member, since otherwise gcc-4.0 would now warn about
13612         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
13613
13614         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
13615         order to avoid an unsuppressible warning from gcc on 64-bit systems.
13616
13617         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
13618         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
13619         when run in a time zone for which daylight savings time is in effect
13620         for the starting date.
13621
13622         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
13623         stop us from restricting permissions of just-created absolute-named
13624         directories.
13625         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
13626         to restore initial working directory.
13627         * lib/mkdir-p.c (make_dir_parents): New parameter:
13628         different_working_dir, to tell caller if/when we change the working
13629         directory and are unable to return to the initial one.
13630         * lib/mkdir-p.h (make_dir_parents): Update prototype.
13631         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
13632         `return false'.  This fixes a bug introduced on 2004-07-30.
13633
13634         * lib/openat.c (fdopendir): Be sure to close the supplied
13635         file descriptor before returning.  This makes our replacement
13636         implementation a little closer to Solaris's, where fdopendir
13637         ties the file descriptor to the returned DIR* pointer.
13638         * lib/openat.c (unlinkat): New function.
13639         * lib/openat.h (unlinkat): Add prototype.
13640         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
13641         (openat_restore_fail): Rename from openat_restore_die.
13642         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
13643
13644         Provide an alternative to exiting immediately upon save_cwd or
13645         restore_cwd failure.  Now, an application can arrange e.g.,
13646         to perform a longjump in that case.
13647         * lib/openat.c: Include dirname.h.
13648         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
13649         (rpl_openat, fdopendir, fstatat): Call openat_save_die
13650         and openat_restore_die rather than calling error directly.
13651         Don't include "error.h" or "exitfail.h"; they're no longer needed.
13652
13653         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
13654         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
13655         define.
13656
13657         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
13658         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
13659                             int utc, int nanoseconds);
13660         Background:
13661         date should not have to allocate a megabyte of virtual memory to
13662         handle a format argument like +%1048575T.  When implemented with
13663         strftime, it must allocate such a buffer, use strftime to fill it
13664         in, print it, then free it.
13665         With fprintftime, it simply prints everything and exits.
13666         With no need for memory allocation, that's one fewer way to fail.
13667         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
13668         optional field width, not before, so we accept %9:z, not %:9z.
13669         (my_strftime): Be sure to use L_('x') for literals.
13670
13671         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
13672         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
13673         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
13674         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
13675         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
13676         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
13677         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
13678         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
13679         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
13680         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
13681         * lib/xgethostname.c, lib/xreadlink.c:
13682         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
13683
13684         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
13685         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
13686         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
13687         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
13688         and don't include <sys/file.h>).
13689
13690 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
13691
13692         Sync from coreutils.
13693
13694         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
13695         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
13696         [!LDAV_DONE]: Avoid unused variable warning.
13697
13698 2005-09-21  Bruno Haible  <bruno@clisp.org>
13699
13700         * lib/unicodeio.h (unicode_to_mb): New declaration.
13701
13702 2005-09-20  Derek Price  <derek@ximbiot.com>
13703
13704         * lib/getaddrinfo.c: Don't include <netdb.h> included from
13705         getaddrinfo.h.
13706
13707 2005-09-20  Bruno Haible  <bruno@clisp.org>
13708
13709         * gnulib-tool: Remove trailing slashes from the values specified for
13710         --source-base, --m4-base, --tests-base, --aux-dir.
13711         Suggested by Simon Josefsson <jas@extundo.com>.
13712
13713 2005-09-20  Bruno Haible  <bruno@clisp.org>
13714
13715         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
13716         func_modules_to_filelist, func_import, func_create_testdir): Make all
13717         sorting results locale-independent, so that gnulib-cache.m4 doesn't
13718         change when gnulib-tool is invoked in a different locale.
13719
13720 2005-09-19  Simon Josefsson  <jas@extundo.com>
13721
13722         * m4/socklen.m4: Fix typo.
13723
13724 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13725
13726         Use a consistent style for including <config.h>.
13727         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
13728         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
13729         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
13730         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
13731         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
13732         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
13733         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
13734         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
13735         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
13736         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
13737         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
13738         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
13739         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
13740         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
13741         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
13742         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
13743         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
13744         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
13745         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
13746         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
13747         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
13748         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
13749         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
13750         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
13751         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
13752         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
13753         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
13754         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
13755         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
13756         lib/xstrtoumax.c, lib/yesno.c:
13757         Standardize inclusion of config.h.
13758         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
13759         lib/inttostr.h:  Removed inclusion of config.h from header files.
13760         * lib/inttostr.c:  Adjusted in-tree users.
13761         * lib/timespec.h: Remove superfluous warning to include config.h.
13762         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
13763         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
13764         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
13765         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
13766         config.h with HAVE_CONFIG_H.
13767
13768 2005-09-19  Jim Meyering  <jim@meyering.net>
13769
13770         * modules/pathmax (License): Change to LGPL.
13771
13772 2005-09-19  Derek Price  <derek@ximbiot.com>
13773
13774         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
13775
13776 2005-09-19  Bruno Haible  <bruno@clisp.org>
13777
13778         * gnulib-tool (import): Provide default for --tests-base.
13779
13780 2005-09-19  Bruno Haible  <bruno@clisp.org>
13781
13782         * doc/quote.texi: New file, extracted from gnulib.texi.
13783         * doc/ctime.texi: New file, extracted from gnulib.texi.
13784         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
13785         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
13786         * doc/gnulib.texi: Include them.
13787
13788 2005-09-18  Bruno Haible  <bruno@clisp.org>
13789
13790         Portability fix.
13791         * gnulib-tool (func_readlink): New function.
13792         (func_ln_if_changed): Use it.
13793
13794 2005-09-18  Bruno Haible  <bruno@clisp.org>
13795
13796         * gnulib-tool: Support --with-tests also with --import.
13797         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
13798         (func_import): Use variables $testsbase and $inctests. Emit a
13799         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
13800         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
13801         SUBDIRS += $testsdir.
13802         (func_create_testdir): Update.
13803
13804 2005-09-18  Bruno Haible  <bruno@clisp.org>
13805
13806         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
13807         instead of $dry_run.
13808         (func_cp_if_changed, func_mv_if_changed): Remove functions.
13809         (func_ln_if_changed): Don't handle dry-run here.
13810         (func_import): In dry-run mode, detect more precisely which actions
13811         would be performed, and don't use "...ing" verbs.
13812
13813 2005-09-18  Bruno Haible  <bruno@clisp.org>
13814
13815         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
13816         (func_import): Use join on two temporary files instead of three nested
13817         loops, in order to determine which files are new or old.
13818
13819 2005-09-18  Bruno Haible  <bruno@clisp.org>
13820
13821         * gnulib-tool (func_import): Comment out code that spits out the
13822         new files with --dry-run.
13823
13824 2005-09-18  Bruno Haible  <bruno@clisp.org>
13825
13826         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
13827
13828 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13829
13830         * lib/stat-time.h: New file.
13831         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
13832         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
13833         in a different way.
13834         (timespec_cmp): New function.
13835         * lib/utimecmp.c: Include stat-time.h.
13836         (SYSCALL_RESOLUTION): Depend on whether various struct stat
13837         members exist, not on the obsolescent ST_MTIM_NSEC.
13838         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
13839
13840 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13841
13842         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
13843
13844 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
13845
13846         * MODULES.html.sh (File system functions): Add stat-time.
13847         * modules/stat-time: New file.
13848         * modules/timespec (Files): Remove m4/st_mtim.m4; this
13849         is now done in a different way, by the stat-time module.
13850         * modules/utimecmp (Depends-on): Add stat-time.
13851
13852 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
13853
13854         * m4/st_mtim.m4: Remove.  Superseded by...
13855         * m4/stat-time.m4: New file.
13856         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
13857         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
13858
13859 2005-09-15  Derek Price  <derek@ximbiot.com>
13860
13861         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
13862
13863 2005-09-15  Derek Price  <derek@ximbiot.com>
13864
13865         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
13866         * lib/regex_internal.c: Ditto, using this...
13867         (__GNUC_PREREQ): ...new macro.
13868         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
13869         using...
13870         (__GNUC_PREREQ): ...this new macro.
13871
13872         * lib/strstr.h: Include string.h. Define strstr as a macro here.
13873
13874 2005-09-15  Derek Price  <derek@ximbiot.com>
13875             Paul Eggert  <eggert@cs.ucla.edu>
13876
13877         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
13878         changes, consolidating in...
13879         * lib/regex_internal.h: ...this file.
13880
13881 2005-09-13  Jim Meyering  <jim@meyering.net>
13882
13883         * lib/canon-host.c: Filter through gnu indent and reword comments
13884         slightly.
13885         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
13886
13887 2005-09-13  Derek Price  <derek@ximbiot.com>
13888
13889         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
13890         failure.
13891         Reported by Jim Meyering  <jim@meyering.net>.
13892
13893 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13894
13895         * lib/base64.c: Typo.
13896         (base64_encode): Put b64str in initialized data section.
13897
13898 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
13899
13900         Merge glibc and coreutils changes into gnulib, plus a few
13901         extra fixes.
13902         * lib/md5.c: Use #error rather than a string.
13903         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
13904         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
13905         (__attribute__): Define to empty for non recent-GCC.
13906         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
13907         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
13908         Renamed from their non-__ counterparts, with new macros replacing
13909         them if not _LIBC.  Add __THROW attribute.
13910         (rol): Remove.
13911         (struct md5_ctx): Align buffer if using GCC.
13912         * lib/sha1.h (struct sha1_ctx): Likewise.
13913         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
13914         The old name was backwards.
13915         (NOTSWAP): Remove; not used.
13916         (rol): New macro, moved here from md5.h.
13917         (sha1_process_block): Remove a FIXME that doesn't make sense.
13918
13919 2005-09-12  Derek Price  <derek@ximbiot.com>
13920
13921         Return usable errors from canon-host.
13922         * lib/canon-host.h: New file.
13923         * lib/canon-host.c (canon_host): Wrap...
13924         (canon_host_r): ...this new function, which now relies exclusively on
13925         getaddrinfo.
13926         (ch_strerror): New function.
13927         (last_cherror): New global.
13928         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
13929         interface.
13930         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
13931         void *.
13932         (freeaddrinfo): Free ai->ai_canonname when set.
13933
13934 2005-09-12  Derek Price  <derek@ximbiot.com>
13935
13936         Make canon-host require getaddrinfo.
13937         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
13938         AC_LIBSOURCE canon-host.h.  Call...
13939         (gl_PREREQ_CANON_HOST): ...this new function, which requires
13940         gl_GETADDRINFO.
13941         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
13942
13943 2005-09-12  Derek Price  <derek@ximbiot.com>
13944
13945         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
13946         LGPL.
13947         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
13948
13949 2005-09-12  Derek Price  <derek@ximbiot.com>
13950
13951         * lib/gai_strerror.c: Include config.h when available.  Include
13952         getaddrinfo.h before other headers to test interface.
13953         Reported by Larry Jones <lawrence.jones@ugs.com>.
13954
13955 2005-09-12  Derek Price  <derek@ximbiot.com>
13956             Paul Eggert  <eggert@cs.ucla.edu>
13957
13958         * modules/glob (Files): Add glob-libc.h.
13959
13960 2005-09-12  Derek Price  <derek@ximbiot.com>
13961             Paul Eggert  <eggert@cs.ucla.edu>
13962
13963         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
13964         glob_.h, glob-libc.h.
13965         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
13966
13967 2005-09-12  Derek Price  <derek@ximbiot.com>
13968             Paul Eggert  <eggert@cs.ucla.edu>
13969
13970         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
13971         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
13972         protecting things that should be done only in gnulib contexts.
13973         * lib/glob_.h: New file, containing only the glob things needed for
13974         gnulib.
13975         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
13976         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
13977         (glob, globfree, glob_pattern_p): Now defined simply in terms of
13978         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
13979         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
13980         and to respect the namespace rules better.
13981
13982 2005-09-08  Simon Josefsson  <jas@extundo.com>
13983
13984         * modules/socklen: New file.
13985
13986 2005-09-08  Simon Josefsson  <jas@extundo.com>
13987
13988         * m4/socklen.m4: New file.
13989
13990 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
13991
13992         * modules/utimens (Files): Add m4/utimbuf.m4, since
13993         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
13994         Reported by Sergey Poznyakoff.
13995
13996 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
13997
13998         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
13999         definitions, since that's the preferred style in glibc.
14000         Fix a minor spacing issue, and update copyright notice to match
14001         glibc's.
14002
14003 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14004
14005         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
14006
14007 2005-09-06  Simon Josefsson  <jas@extundo.com>
14008
14009         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
14010         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
14011
14012 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14013
14014         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
14015         warning.
14016
14017 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14018
14019         * config/srclist.txt: Add glibc bug 1302.
14020
14021 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
14022
14023         Change bitset word type from unsigned int to unsigned long int,
14024         as this has better performance on typical 64-bit hosts.
14025         Port bitset code to hosts with unusual word sizes.
14026         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
14027         (build_collating_symbol):
14028         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
14029         argument is a bitset.  This is merely a style issue, but it makes
14030         it clearer that an entire array is expected.
14031         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
14032         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
14033         Port to the case where bitset_word is not the same as unsigned int.
14034         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
14035         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
14036         Likewise.
14037         * lib/regexec.c (check_dst_limits_calc_pos_1,
14038         check_subexp_matching_top):
14039         (build_trtable, group_nodes_into_DFAstates):
14040         Likewise.
14041         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
14042         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
14043         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
14044         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
14045         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
14046         * lib/regcomp.c (optimize_subexps, lower_subexp):
14047         Work even if bitset_word has holes in its bitwise representation.
14048         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
14049         * lib/regexec.c (check_dst_limits_calc_pos_1,
14050         check_subexp_matching_top):
14051         Likewise.
14052         * lib/regex_internal.c (re_string_reconstruct):
14053         Don't assume UCHAR_MAX == 255.
14054         * lib/regex_internal.h (bitset_set_all): Likewise.
14055         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
14056         All uses changed.
14057         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
14058         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
14059         All uses changed.
14060         (BITSET_WORD_MAX): New macro.
14061         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
14062         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
14063         (bitset_empty, bitset_copy):
14064         Prefer sizeof (bitset) to multiplying it out ourselves.
14065         (bitset_not_merge): Remove; unused.
14066         (bitset_contain): Return bool, not unsigned int with one bit on.
14067         All callers changed.
14068         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
14069         alignment than re_node_set; do this by defining a new internal
14070         type struct dests_alloc and using it to allocate memory.
14071
14072 2005-09-05  Bruno Haible  <bruno@clisp.org>
14073
14074         * gnulib-tool (func_import): Fix comparison in handling of symbolic
14075         links.
14076
14077 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
14078
14079         * modules/size_max (Makefile.am): Add size_max.h
14080
14081 2005-09-04  Derek Price  <derek@ximbiot.com>
14082
14083         * gnulib-tool (func_import): Fix reversed $symbolic logic.
14084
14085 2005-09-03  Simon Josefsson  <jas@extundo.com>
14086
14087         * gnulib-tool: Fix typo.
14088
14089 2005-09-03  Simon Josefsson  <jas@extundo.com>
14090
14091         * config/srclist.txt: Add glibc bug 1293.
14092
14093 2005-09-03  Derek Price  <derek@ximbiot.com>
14094
14095         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
14096         From Larry Jones <lawrence.jones@ugs.com>.
14097
14098 2005-09-02  Simon Josefsson  <jas@extundo.com>
14099
14100         * modules/socklen: New file.
14101
14102 2005-09-02  Simon Josefsson  <jas@extundo.com>
14103
14104         * modules/havelib: New module.
14105
14106         * modules/gettext, modules/iconv, modules/lock, modules/readline:
14107         Use havelib.
14108
14109 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14110
14111         Check for arithmetic overflow when calculating sizes, to prevent
14112         some buffer-overflow issues.  These patches are conservative, in the
14113         sense that when I couldn't determine whether an overflow was possible,
14114         I inserted a run-time check.
14115         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
14116         macros.
14117         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
14118         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
14119         (re_xnrealloc, re_x2nrealloc): New inline functions.
14120         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
14121         parse_bracket_exp):
14122         (build_equiv_class, build_charclass): Check for arithmetic overflow
14123         in size expression calculations.
14124         * lib/regex_internal.c (re_string_realloc_buffers):
14125         (build_wcs_upper_buffer, re_node_set_add_intersect):
14126         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
14127         (re_dfa_add_node, register_state): Likewise.
14128         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
14129         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
14130         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
14131         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
14132
14133 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14134
14135         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14136         m4/ulonglong.m4.  Problem reported by Martin Lambers.
14137
14138 2005-09-02  Bruno Haible  <bruno@clisp.org>
14139
14140         Support for lib vs. lib64 distinction on biarch platforms.
14141         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
14142         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
14143         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
14144
14145 2005-09-02  Bruno Haible  <bruno@clisp.org>
14146
14147         * gnulib-tool (import): In the other first-use case, provide defaults
14148         as well.
14149
14150 2005-09-02  Bruno Haible  <bruno@clisp.org>
14151
14152         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
14153         patches not yet found in the latest gettext release.
14154
14155 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
14156
14157         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
14158         to avoid a collision with bits/local_lim.h in glibc.
14159         All uses changed.  Problem reported by Dmitry V. Levin in
14160         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
14161
14162         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
14163         bugs in int versus size_t comparisons.
14164         (re_string_context_at): Fix bug where the code assumed that
14165         Idx is signed.
14166
14167         Use bool where appropriate.
14168         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
14169         All callers changed.
14170         (calc_eclosure_iter): Likewise, for ROOT arg.
14171         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
14172         (build_charclass_op): Likewise, for NON_MATCH arg.
14173         * lib/regex_internal.c (re_string_allocate, re_string_construct):
14174         (re_string_construct_common): Likewise, for ICASE arg.
14175         * lib/regexec.c (re_search_2_stub, re_search_stub):
14176         Likewise, for RET_LEN arg.
14177         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
14178         (set_regs): Likewise, for FL_BACKTRACK arg.
14179         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
14180         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
14181         (calc_eclosure_iter, parse_bracket_exp):
14182         Use bool for internal variables that are booleans.
14183         * lib/regexec.c (re_search_internal, check_matching,
14184         proceed_next_node):
14185         (set_regs, build_sifted_states, sift_states_bkref):
14186         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
14187         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
14188         (find_collation_sequence_value):
14189         Likewise.
14190         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
14191         (re_node_set_compare):
14192         Return bool, not int. All callers changed.
14193         * lib/regexec.c (check_halt_node_context, check_dst_limits):
14194         (build_trtable, check_node_accept): Likewise.
14195         * lib/regex_internal.h: Include stdbool.h.
14196
14197         Fix bugs uncovered when converting to bool.
14198         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
14199         failure instead of charging ahead blindly.
14200         * lib/regex_internal.c (register_state): Likewise.
14201         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
14202         for freeing internal storage.
14203         (group_nodes_into_DFA_states): Use unsigned int, not int, for
14204         bitset pieces used as boolean, to avoid undefined behavior
14205         on hosts that do int overflow checking.
14206
14207 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
14208
14209         * config/srclist.txt: Add glibc bugs 1285-1287.
14210
14211 2005-09-01  Jim Meyering  <jim@meyering.net>
14212
14213         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
14214         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
14215         Require gl_STAT_MACROS, too.
14216
14217 2005-09-01  Bruno Haible  <bruno@clisp.org>
14218
14219         * gnulib-tool (import): In the first-use case, provide defaults.
14220
14221 2005-09-01  Bruno Haible  <bruno@clisp.org>
14222
14223         * gnulib-tool (func_import): Remove the .tmp files.
14224
14225 2005-09-01  Bruno Haible  <bruno@clisp.org>
14226
14227         * gnulib-tool (func_import): Fix handling of symbolic links.
14228
14229 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14230
14231         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
14232         old glibc regex code mishandles strings longer than 2**31 bytes.
14233         This patch fixes this when the regex code is used in gnulib
14234         (i.e., outside glibc).
14235
14236         This patch should not affect the use of the regex code inside
14237         glibc.  No doubt this problem also needs to be handled for glibc
14238         as well, but the result will be an incompatible change to the
14239         glibc ABI, and the old ABI will have to be supported too.  That
14240         can be the the subject for another patch.
14241
14242         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
14243         governing whether the rest of this patch is active.  By default,
14244         the macro is disabled and the patch has no effect.
14245         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
14246         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
14247         (struct re_pattern_buffer, re_search, re_search_2, re_match):
14248         (re_match_2, re_set_registers): Use the new types.
14249         * lib/regex_internal.h (Idx, re_hashval_t): New types.
14250         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
14251         New macros.
14252         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
14253         (re_string_context_at, bin_tree_t, re_dfastate_t):
14254         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
14255         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
14256         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
14257         (re_string_char_size_at, re_string_wchar_at):
14258         (re_string_elem_size_at):
14259         Use the new types and macros to port to 64-bit hosts.
14260         Use unsigned types for internal values, so that the code
14261         mostly works even for arrays larger than SSIZE_MAX.
14262         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
14263         (search_duplicated_node, calc_eclosure_iter, fetch_number):
14264         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
14265         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
14266         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
14267         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
14268         (calc_inveclosure, parse_dup_op, build_range_exp):
14269         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
14270         (fetch_number, create_token_tree, mark_opt_subexp):
14271         Likewise.
14272         * lib/regex_internal.c (re_string_construct_common,
14273         create_ci_newstate):
14274         (create_cd_newstate, re_string_allocate, re_string_construct):
14275         (re_string_realloc_buffers, build_wcs_upper_buffer):
14276         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
14277         (re_string_reconstruct, re_string_peek_byte_case):
14278         (re_string_fetch_byte_case, re_string_context_at):
14279         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
14280         (re_node_set_init_copy, re_node_set_add_intersect):
14281         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14282         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14283         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
14284         (re_acquire_state, re_acquire_state_context, register_state):
14285         Likewise.
14286         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
14287         search_cur_bkref_entry):
14288         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
14289         (re_search_internal, re_search_2_stub, re_search_stub)
14290         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
14291         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
14292         (update_cur_sifted_state, check_dst_limits):
14293         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
14294         (check_subexp_limits, sift_states_bkref, merge_state_array):
14295         (check_subexp_matching_top, get_subexp, get_subexp_sub):
14296         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
14297         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
14298         (expand_bkref_cache, check_node_accept_bytes):
14299         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
14300         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
14301         (acquire_init_state_context, check_halt_node_context):
14302         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
14303         (sift_states_backward, clean_state_log_if_needed):
14304         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
14305         (find_recover_state, transit_state_sb, transit_state_mb):
14306         (transit_state_bkref, build_trtable, match_ctx_clean):
14307         Likewise.
14308         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
14309         to work around an assumption that REG_MISSING is negative.
14310
14311         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
14312         (seek_collating_symbol_entry) [defined _LIBC]:
14313         (lookup_collation_sequence_value) [defined _LIBC]:
14314         (build_range_exp, build_collating_symbol) [defined _LIBC]:
14315         Use prototypes rather than old-style function definitions.
14316         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
14317         (transit_state_sb) [0]:
14318         (find_collation_sequence_value) [defined _LIBC]: Likewise.
14319
14320         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
14321         rm_eo.
14322
14323         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
14324         (optimize_subexps, lower_subexp):
14325         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
14326         since the signed shift might overflow.  Use 1u<<31 instead.
14327         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
14328         Likewise.
14329         * lib/regexec.c (check_dst_limits_calc_pos_1,
14330         check_subexp_matching_top): Likewise.
14331
14332         * lib/regcomp.c (optimize_subexps, lower_subexp):
14333         Use CHAR_BIT rather than 8, for clarity.
14334         * lib/regexec.c (check_dst_limits_calc_pos_1):
14335         (check_subexp_matching_top): Likewise.
14336         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
14337         have to worry about portability issues when shifting it left.
14338         Remove no-longer-needed test for table_size > 0.
14339         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
14340         in a word, as the resulting behavior is undefined.
14341         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
14342         in one case, a <= should have been an <, and in another case the
14343         whole test was missing.
14344         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
14345         the standard name CHAR_BIT.
14346         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
14347         this is not true on one's complement and signed-magnitude hosts.
14348
14349         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
14350         next_last_offset.
14351         (struct re_dfa_t): Remove unused member states_alloc.
14352         * lib/regcomp.c (init_dfa): Don't initialize unused members.
14353
14354 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14355
14356         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
14357         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
14358         and large-file glibc and in 32-bit large-file Solaris.
14359
14360 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14361
14362         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
14363         lengths fit in regoff_t; this isn't true if regoff_t is the same
14364         width as size_t.
14365         * lib/regex.c (re_search_internal): 5th arg is LAST_START
14366         (= START + RANGE) instead of RANGE.  This avoids overflow
14367         problems when regoff_t is the same width as size_t.
14368         All callers changed.
14369         (re_search_2_stub): Check for overflow when adding the
14370         sizes of the two strings.
14371         (re_search_stub): Check for overflow when adding START
14372         to RANGE; if it occurs, substitute the extreme value.
14373
14374 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14375
14376         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
14377
14378 2005-08-31  Jim Meyering  <jim@meyering.net>
14379
14380         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
14381         a pointer-to-const.
14382         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
14383         (register_state): Likewise.
14384         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
14385         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
14386         (group_nodes_into_DFAstates): Likewise.
14387
14388 2005-08-31  Jim Meyering  <jim@meyering.net>
14389
14390         * check-module: Add a FIXME comment.
14391
14392 2005-08-31  Eric Blake  <ebb9@byu.net>
14393
14394         * modules/unistd-safer (Files): Add unistd--.h.
14395         * modules/stdio-safer (Files): Add stdio--.h.
14396
14397 2005-08-31  Derek Price  <derek@ximbiot.com>
14398
14399         * lib/getdelim.c (getdelim): Return EOF on EOF.
14400         Reported by Larry Jones <lawrence.jones@ugs.com>.
14401
14402 2005-08-31  Bruno Haible  <bruno@clisp.org>
14403
14404         Avoid unnecessary diffs in the generated lib/Makefile.am.
14405         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
14406         the generated files.
14407         (func_import): Don't set cmd.
14408
14409 2005-08-31  Bruno Haible  <bruno@clisp.org>
14410
14411         * lib/strstr.c: Include <stddef.h>, for NULL.
14412         * lib/strcasestr.c: Likewise.
14413         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
14414
14415 2005-08-31  Bruno Haible  <bruno@clisp.org>
14416
14417         * gnulib-tool: New option --macro-prefix.
14418         (func_import): Use macro_prefix.
14419         (import): Handle option --macro-prefix.
14420
14421 2005-08-31  Bruno Haible  <bruno@clisp.org>
14422
14423         * gnulib-tool (import): Rename most ac_* variables to cached_*.
14424         Also use new variables cached_lgpl, cached_libtool.
14425
14426 2005-08-31  Bruno Haible  <bruno@clisp.org>
14427
14428         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
14429         always instantiating them.
14430
14431 2005-08-31  Bruno Haible  <bruno@clisp.org>
14432
14433         * gnulib-tool (func_import): Read the previous cached settings
14434         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
14435         earlier added by gnulib but are now dropped. Warn when a gnulib file
14436         overwrites a non-gnulib file.
14437
14438 2005-08-31  Bruno Haible  <bruno@clisp.org>
14439
14440         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
14441         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
14442         projects that don't keep autogenerated files in CVS. Put into
14443         actioncmd only the specified modules, not the transitive closure.
14444
14445 2005-08-31  Bruno Haible  <bruno@clisp.org>
14446
14447         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
14448         Create directories that shall be filled.
14449         (import): Don't look for gl_* macros in configure.ac. Recurse across
14450         all directories containing a gnulib-cache.m4 files, if meaningful.
14451
14452 2005-08-31  Bruno Haible  <bruno@clisp.org>
14453
14454         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
14455         (import): Set seen_libtool when we see gl_LIBTOOL.
14456
14457 2005-08-31  Bruno Haible  <bruno@clisp.org>
14458
14459         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
14460         declaration macro definitions from generated gnulib.m4.
14461
14462 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
14463
14464         * lib/iconvme.h: Add prototype for iconv_alloc.
14465
14466 2005-08-29  Simon Josefsson  <jas@extundo.com>
14467
14468         * lib/iconvme.c: Fix errno.
14469
14470 2005-08-29  Bruno Haible  <bruno@clisp.org>
14471
14472         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
14473         that it works when the directory contains spaces.
14474
14475 2005-08-29  Bruno Haible  <bruno@clisp.org>
14476
14477         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
14478
14479 2005-08-29  Bruno Haible  <bruno@clisp.org>
14480
14481         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
14482         Emit more advice.
14483
14484 2005-08-29  Bruno Haible  <bruno@clisp.org>
14485         and Stepan Kasal  <kasal@ucw.cz>
14486
14487         * check-module: If more parameters are given, check each of them
14488         separately; add more exceptions, as noted by Jim Meyering.
14489         (check_module): New procedure.
14490         (%exempt_header): Now contains all exceptions.
14491
14492 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
14493
14494         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
14495
14496 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
14497
14498         * lib/iconvme.c: Split iconv_string into iconv_alloc.
14499
14500 2005-08-28  Bruno Haible  <bruno@clisp.org>
14501
14502         * m4/gnulib-tool.m4: New file.
14503
14504 2005-08-27  Jim Meyering  <jim@meyering.net>
14505
14506         * modules/unistd-safer (Files): Add pipe-safer.c.
14507         * modules/fcntl-safer (Files): Add creat-safer.c.
14508
14509 2005-08-27  Jim Meyering  <jim@meyering.net>
14510
14511         * m4/stdlib-safer.m4: New file.  From coreutils.
14512         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
14513         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
14514         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
14515         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
14516         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
14517
14518 2005-08-27  Jim Meyering  <jim@meyering.net>
14519
14520         * lib/fopen-safer.c: Merge minor changes from coreutils.
14521         * lib/dup-safer.c: Likewise.
14522         * lib/fd-safer.c: Likewise.
14523
14524         Merge from coreutils.
14525         * lib/stdio--.h: New file.
14526         * lib/stdlib--.h: New file.
14527         * lib/mkstemp-safer.c: New file.
14528
14529         GNU tar needs these.
14530         * lib/pipe-safer.c: New file.
14531         * lib/creat-safer.c: New file.
14532         * lib/fcntl--.h (creat): Define to creat_safer.
14533         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
14534         * lib/unistd--.h (pipe): Define to pipe_safer.
14535         * lib/unistd-safer.h: Declare pipe_safer.
14536
14537 2005-08-26  Simon Josefsson  <jas@extundo.com>
14538
14539         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
14540         Haible <bruno@clisp.org>.
14541
14542 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
14543
14544         * lib/regex_internal.h: Remove all references to
14545         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
14546         or better.
14547         (bitset_not, bitset_merge, bitset_not_merge):
14548         (bitset_mask, re_string_allocate, re_string_construct):
14549         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
14550         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
14551         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
14552         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
14553         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14554         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14555         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
14556         (re_acquire_state_context):
14557         Remove unnecessary forward decls.
14558         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
14559         Put __attribute at function definition,
14560         now that the function decl has been removed.
14561         * lib/regex_internal.c (re_string_peek_byte_case):
14562         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
14563         Likewise.
14564
14565 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
14566
14567         * m4/regex.m4: Add AC_PREREQ(2.50).
14568         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
14569
14570 2005-08-25  Simon Josefsson  <jas@extundo.com>
14571
14572         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
14573         __fsetlocking.
14574
14575 2005-08-25  Simon Josefsson  <jas@extundo.com>
14576
14577         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
14578         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
14579         GLIBC specific code.
14580
14581 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14582
14583         Make regex safe for g++.  This fixes one real bug (an "err"
14584         that should have been "*err").  g++ problem reported by
14585         Sam Steingold.
14586         * lib/regex_internal.h (re_calloc): New macro, consistent with
14587         re_malloc etc.  All callers of calloc changed to use re_calloc.
14588         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
14589         not int.  All callers changed.
14590         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
14591         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
14592         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
14593         (find_recover_state): Change "err" to "*err"; this fixes what
14594         appears to be a real bug.
14595         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
14596         versus int.
14597
14598 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14599
14600         * modules/regex (Depends-on): Add malloc, since the code
14601         assumes that !malloc(0) means failure.
14602
14603 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14604
14605         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
14606
14607         alloca modernization/simplification for regex.
14608         * lib/regex.c: Remove portability cruft for alloca.  This no longer
14609         needs to be at the start of the file, and can be moved into
14610         regex_internal.h and simplified.
14611         * lib/regex_internal.h: Include <alloca.h>.
14612         (__libc_use_alloca) [!defined _LIBC]: New macro.
14613         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
14614         now works outside glibc.
14615
14616 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
14617
14618         * config/srclist.txt: Add glibc bugs 1241, 1245.
14619
14620 2005-08-25  Jim Meyering  <jim@meyering.net>
14621
14622         * lib/open-safer.c: Include <config.h>.
14623         Otherwise, we'd lose LARGEFILE support in any file using
14624         e.g. "fcntl--.h"
14625
14626 2005-08-25  Bruno Haible  <bruno@clisp.org>
14627
14628         * m4/minmax.m4: Require autoconf 2.52.
14629         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
14630         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
14631         alternatives of translit over the alphabet.
14632         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
14633
14634 2005-08-24  Simon Josefsson  <jas@extundo.com>
14635
14636         * tests/test-getpass.c: New file.
14637
14638 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14639
14640         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
14641         for GNU regex features.
14642
14643 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14644
14645         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
14646         * lib/regex.h (regerror): Likewise.
14647
14648         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
14649         requires this.  (The code never needed it.)
14650
14651         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
14652         All uses of recently-renamed identifiers changed to use the new,
14653         POSIX-compliant names.  The code will build and run just fine
14654         without these changes, but it's better to eat our own dog food
14655         and use the standard-conforming names.
14656
14657         * lib/regex.h: Fix a multitude of POSIX name space violations.
14658         These changes have an effect only for programs that define
14659         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
14660         do not change anything for programs compiled in the normal way.
14661         Also, there is no effect on the ABI.
14662
14663         (_REGEX_SOURCE): New macro.
14664         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
14665         defined and _GNU_SOURCE is not; this fixes a name space violation.
14666
14667         Rename the following macros to obey POSIX requirements.
14668         The old names are still visible as macros if _REGEX_SOURCE is defined.
14669         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
14670         RE_BACKSLASH_ESCAPE_IN_LISTS.
14671         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
14672         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
14673         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
14674         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
14675         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
14676         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
14677         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
14678         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
14679         (REG_INTERVALS): renamed from RE_INTERVALS.
14680         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
14681         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
14682         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
14683         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
14684         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
14685         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
14686         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
14687         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
14688         RE_UNMATCHED_RIGHT_PAREN_ORD.
14689         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
14690         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
14691         (REG_DEBUG): renamed from RE_DEBUG.
14692         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
14693         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
14694         unusual, since we can't clash with the POSIX REG_ICASE.
14695         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
14696         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
14697         (REG_NO_SUB): renamed from RE_NO_SUB.
14698         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
14699         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
14700         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
14701         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
14702         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
14703         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
14704         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
14705         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
14706         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
14707         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
14708         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
14709         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
14710         RE_SYNTAX_POSIX_MINIMAL_BASIC.
14711         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
14712         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
14713         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
14714         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
14715         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
14716         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
14717         (REG_FIXED): Renamed from REGS_FIXED.
14718         (REG_NREGS): Renamed from RE_NREGS.
14719
14720         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
14721         of other REG_* macros, since POSIX says the user is allowed to
14722         #undef these macros selectively.
14723
14724         (reg_errcode_t): Update comment stating what other tables need
14725         to be consistent.
14726
14727         Rename the following enum values to obey POSIX requirements.
14728         The old names are still visible as macros.
14729         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
14730         is not defined, since GNU is supposed to be a superset of POSIX as
14731         much as possible, and since we want reg_errcode_t to be a signed
14732         type for implementation consistency.
14733         (_REG_NOERROR): Renamed from REG_NOERROR.
14734         (_REG_NOMATCH): Renamed from REG_NOMATCH.
14735         (_REG_BADPAT): Renamed from REG_BADPAT.
14736         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
14737         (_REG_ECTYPE): Renamed from REG_ECTYPE.
14738         (_REG_EESCAPE): Renamed from REG_EESCAPE.
14739         (_REG_ESUBREG): Renamed from REG_ESUBREG.
14740         (_REG_EBRACK): Renamed from REG_EBRACK.
14741         (_REG_EPAREN): Renamed from REG_EPAREN.
14742         (_REG_EBRACE): Renamed from REG_EBRACE.
14743         (_REG_BADBR): Renamed from REG_BADBR.
14744         (_REG_ERANGE): Renamed from REG_ERANGE.
14745         (_REG_ESPACE): Renamed from REG_ESPACE.
14746         (_REG_BADRPT): Renamed from REG_BADRPT.
14747         (_REG_EEND): Renamed from REG_EEND.
14748         (_REG_ESIZE): Renamed from REG_ESIZE.
14749         (_REG_ERPAREN): Renamed from REG_ERPAREN.
14750         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
14751         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
14752         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
14753         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
14754
14755         (_REG_RE_NAME, _REG_RM_NAME): New macros.
14756         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
14757         changed.  But support the old name if the new one is not defined
14758         and if _REGEX_SOURCE.
14759
14760         Change the following member names in struct re_pattern_buffer.
14761         The old names are still supported if !_REGEX_SOURCE.
14762         The new names are always supported, regardless of _REGEX_SOURCE.
14763         (re_buffer): Renamed from buffer.
14764         (re_allocated): Renamed from allocated.
14765         (re_used): Renamed from used.
14766         (re_syntax): Renamed from syntax.
14767         (re_fastmap): Renamed from fastmap.
14768         (re_translate): Renamed from translate.
14769         (re_can_be_null): Renamed from can_be_null.
14770         (re_regs_allocated): Renamed from regs_allocated.
14771         (re_fastmap_accurate): Renamed from fastmap_accurate.
14772         (re_no_sub): Renamed from no_sub.
14773         (re_not_bol): Renamed from not_bol.
14774         (re_not_eol): Renamed from not_eol.
14775         (re_newline_anchor): Renamed from newline_anchor.
14776
14777         Change the following member names in struct re_registers.
14778         The old names are still supported if !_REGEX_SOURCE.
14779         The new names are always supported, regardless of _REGEX_SOURCE.
14780         (rm_num_regs): Renamed from num_regs.
14781         (rm_start): Renamed from start.
14782         (rm_end): Renamed from end.
14783
14784         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
14785         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
14786         Prepend __ to parameter names.
14787
14788         Undo yesterday's changes.
14789
14790 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
14791
14792         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
14793         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
14794         lib/regex.c.
14795
14796 2005-08-24  Jim Meyering  <jim@meyering.net>
14797
14798         Sync from coreutils.
14799         * m4/fcntl-safer.m4: New file.
14800
14801         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
14802         and object files for this module.
14803
14804 2005-08-24  Jim Meyering  <jim@meyering.net>
14805
14806         Sync from coreutils.
14807         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
14808
14809 2005-08-24  Jim Meyering  <jim@meyering.net>
14810
14811         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
14812         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
14813
14814 2005-08-24  Jim Meyering  <jim@meyering.net>
14815
14816         * modules/fcntl-safer: New module.
14817         * modules/fts (Depends-on): Add fcntl-safer.
14818         * MODULES.html.sh (File descriptor based Input/Output):
14819         Add fcntl-safer.
14820
14821 2005-08-24  Bruno Haible  <bruno@clisp.org>
14822
14823         Support for unit test modules.
14824         * modules/README: Mention tests modules.
14825         * modules/TEMPLATE-TESTS: New file.
14826         * gnulib-tool: New options --extract-tests-module, --with-tests and
14827         --tests-base (unused for the moment).
14828         (testsbase, inctests): New variables.
14829         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
14830         (func_verify_module): Exclude TEMPLATE-TESTS.
14831         (func_verify_nontests_module, func_verify_tests_module): New functions.
14832         (func_get_dependencies): Add implicit dependency for tests modules.
14833         (func_get_tests_module): New function.
14834         (func_modules_transitive_closure): When --with-tests was specified,
14835         include the unit tests as well, unless explicitly avoided.
14836         (func_emit_lib_Makefile_am): Ignore the tests modules here.
14837         (func_emit_tests_Makefile_am): New function.
14838         (func_create_testdir): When --with-tests was specified, emit a
14839         tests/ directory.
14840         * MODULES.html.sh (Future developments): Update.
14841
14842 2005-08-24  Bruno Haible  <bruno@clisp.org>
14843
14844         * modules/tls-tests: New file.
14845         * tests/test-tls.c: New file, from GNU gettext.
14846
14847 2005-08-24  Bruno Haible  <bruno@clisp.org>
14848
14849         * modules/lock-tests: New file.
14850         * tests/test-lock.c: New file, from GNU gettext.
14851
14852 2005-08-24  Bruno Haible  <bruno@clisp.org>
14853
14854         * lib/lock.h: Add multiple inclusion guard.
14855         * lib/tls.h: Add multiple inclusion guard.
14856
14857 2005-08-24  Bruno Haible  <bruno@clisp.org>
14858
14859         * gnulib-tool: Add support for the --aux-dir option to
14860         --create-testdir, --create-megatestdir, --test, --megatest.
14861         (func_create_testdir, func_create_megatestdir): Optionally emit a
14862         AC_CONFIG_AUX_DIR directive.
14863         (create-testdir, create-megatestdir, test, megatest): Provide a
14864         default value for $auxdir.
14865
14866 2005-08-24  Bruno Haible  <bruno@clisp.org>
14867
14868         * gnulib-tool (import): Use compound statement instead of subshell
14869         where possible.
14870
14871 2005-08-24  Bruno Haible  <bruno@clisp.org>
14872
14873         * gnulib-tool (import): Change --aux-dir default to "build-aux".
14874
14875 2005-08-24  Bruno Haible  <bruno@clisp.org>
14876
14877         * gnulib-tool (func_version): Update.
14878
14879 2005-08-24  Bruno Haible  <bruno@clisp.org>
14880
14881         * gnulib-tool (func_import, func_create_testdir,
14882         func_create_megatestdir): Quote all autoconf macro arguments.
14883
14884 2005-08-24  Bruno Haible  <bruno@clisp.org>
14885
14886         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
14887         option --force, because --force causes the aclocal.m4 of each
14888         subdirectory to be newer than the corresponding config.h.in.
14889
14890 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14891
14892         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
14893         All contents moved to gl_REGEX.
14894         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
14895         assume that it does.
14896
14897 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14898
14899         * lib/regex.h (REG_NOSYS)
14900         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
14901         Define, since POSIX requires it as of 2001.
14902         (_REG_ENOSYS)
14903         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
14904         New private symbol, used to keep the enum signed in all cases.
14905         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
14906         Youngman in
14907         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
14908
14909         * lib/regex_internal.c (re_string_skip_chars, register_state):
14910         (calc_state_hash):
14911         Remove forward decls; no longer needed now that we use prototypes.
14912         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
14913         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
14914         (clean_state_log_if_needed): Likewise.
14915
14916 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
14917
14918         * config/srclist.txt: Add glibc bugs 1231-1233.
14919
14920 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
14921
14922         Fix problems reported by Sam Steingold in
14923         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
14924         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
14925         assumed that reg_errcode_t is a signed type, which is not
14926         necessarily true if _XOPEN_SOURCE is not defined.
14927         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
14928         since some compilers warn about it otherwise.
14929
14930 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
14931
14932         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
14933         (init_word_char, create_initial_state, duplicate_node_closure):
14934         (fetch_token, peek_token_bracket, build_range_exp):
14935         (build_collating_symbol): Remove forward decls; no longer needed
14936         now that we use prototypes.
14937
14938         * lib/regcomp.c:
14939         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
14940         (re_compile_fastmap_iter, regcomp, regerror, regfree):
14941         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
14942         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
14943         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
14944         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
14945         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
14946         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
14947         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
14948         (build_range_exp, build_collating_symbol, parse_bracket_exp):
14949         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
14950         (build_charclass, build_charclass_op, fetch_number, create_tree):
14951         (create_token_tree, mark_opt_subexp, duplicate_tree):
14952         Use prototypes rather than old-style definitions.
14953
14954         * lib/regex_internal.c:
14955         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
14956         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
14957         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
14958         (re_string_reconstruct, re_string_peek_byte_case):
14959         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
14960         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
14961         (re_node_set_init_copy, re_node_set_add_intersect):
14962         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14963         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14964         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
14965         (re_acquire_state, re_acquire_state_context, register_state):
14966         (create_ci_newstate, create_cd_newstate, free_state):
14967         Likewise.
14968         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
14969         re_search_2):
14970         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
14971         (re_search_internal, prune_impossible_nodes):
14972         (acquire_init_state_context, check_matching, static):
14973         (check_halt_node_context, check_halt_state_context, proceed_next_node):
14974         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
14975         (update_regs, sift_states_backward, build_sifted_states):
14976         (clean_state_log_if_needed, merge_state_array):
14977         (update_cur_sifted_state, add_epsilon_src_nodes):
14978         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
14979         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
14980         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
14981         (find_recover_state, check_subexp_matching_top, transit_state_mb):
14982         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
14983         (check_arrival, check_arrival_add_next_nodes):
14984         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
14985         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
14986         (check_node_accept_bytes, check_node_accept, extend_buffers):
14987         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
14988         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
14989         (sift_ctx_init):
14990         Likewise.
14991
14992         * lib/regex_internal.h:
14993         (re_string_allocate, re_string_construct, re_string_reconstruct):
14994         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
14995         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
14996         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
14997         (re_string_context_at, re_string_peek_byte_case):
14998         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
14999         is defined, since we now use prototypes always.
15000
15001         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
15002         C89 or better.  All uses removed.
15003
15004 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15005
15006         * config/srclist.txt: Add glibc bugs 1220-1227.
15007
15008 2005-08-20  Jim Meyering  <jim@meyering.net>
15009
15010         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
15011         of unused local, dfa.
15012
15013 2005-08-20  Bruno Haible  <bruno@clisp.org>
15014
15015         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
15016
15017 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15018
15019         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
15020         (re_node_set_insert_last, re_dfa_add_node):
15021         Rename local variables to avoid GCC shadowing warnings.
15022
15023 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15024
15025         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
15026         [defined lint]: Suppress bogus uninitialized-variable warnings.
15027
15028         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
15029         and let the caller return REG_ESPACE if out of space.  This
15030         removes an uninitialied-variable warning with GCC 4.0.1, and also
15031         avoids taking the address of a local variable.  All callers
15032         changed.
15033
15034 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15035
15036         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
15037         $LIBCSRC/posix/regexec.c.
15038         Add glibc bug 1217 for regcomp.c.
15039
15040 2005-08-19  Jim Meyering  <jim@meyering.net>
15041
15042         * lib/regexec.c (proceed_next_node): Redo local variables to
15043         avoid GCC shadowing warnings.
15044
15045 2005-08-18  Bruno Haible  <bruno@clisp.org>
15046
15047         * lib/strstr.c (strstr): Fix return value in multibyte case.
15048         * lib/strcasestr.c (strcasestr): Likewise.
15049
15050 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
15051
15052         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
15053
15054 2005-08-17  Jim Meyering  <jim@meyering.net>
15055
15056         Make the %s format (seconds since the epoch) work for a negative
15057         number and when used with a zero-padded field width, e.g. %015s.
15058
15059         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
15060         label so that it precedes the code to set `digits'.  Otherwise,
15061         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
15062         print `00-22'.  Now, it prints `-0022', as it should.
15063
15064 2005-08-17  Bruno Haible  <bruno@clisp.org>
15065
15066         * modules/strstr (Files): Add m4/mbrtowc.m4.
15067         (Depends-on): Add mbuiter.
15068
15069 2005-08-17  Bruno Haible  <bruno@clisp.org>
15070
15071         * modules/strcasestr: New file.
15072         * MODULES.html.sh (String handling, based on ANSI C 89): Add
15073         strcasestr.
15074
15075 2005-08-17  Bruno Haible  <bruno@clisp.org>
15076
15077         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
15078
15079 2005-08-17  Bruno Haible  <bruno@clisp.org>
15080
15081         * modules/mbuiter: New file.
15082         * MODULES.html.sh (Extended multibyte and wide character utilities):
15083         Add mbuiter.
15084
15085 2005-08-17  Bruno Haible  <bruno@clisp.org>
15086
15087         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
15088         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
15089
15090 2005-08-17  Bruno Haible  <bruno@clisp.org>
15091
15092         * m4/strcasestr.m4: New file.
15093
15094 2005-08-17  Bruno Haible  <bruno@clisp.org>
15095
15096         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
15097         * lib/strstr.c: Completely rewritten, with multibyte locale support.
15098
15099 2005-08-17  Bruno Haible  <bruno@clisp.org>
15100
15101         * lib/strcasestr.h: New file.
15102         * lib/strcasestr.c: New file.
15103
15104 2005-08-17  Bruno Haible  <bruno@clisp.org>
15105
15106         * lib/strcasecmp.c: Use mbuiter.h.
15107
15108 2005-08-17  Bruno Haible  <bruno@clisp.org>
15109
15110         * lib/mbuiter.h: New file.
15111
15112 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
15113
15114         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
15115         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
15116         and gl_GETOPT are both invoked via different paths (as happens
15117         with GNU tar CVS because it uses both argp and getopt), the former
15118         wins.
15119
15120 2005-08-16  Bruno Haible  <bruno@clisp.org>
15121
15122         * modules/tls: New file.
15123         * MODULES.html.sh (Multithreading): Add tls.
15124
15125 2005-08-16  Bruno Haible  <bruno@clisp.org>
15126
15127         * modules/strnlen1: New file.
15128         * MODULES.html.sh (String handling): Add strnlen1.
15129
15130 2005-08-16  Bruno Haible  <bruno@clisp.org>
15131
15132         * modules/strcase (Files): Add m4/mbrtowc.m4.
15133         (Depends-on): Add strnlen1, mbchar.
15134
15135 2005-08-16  Bruno Haible  <bruno@clisp.org>
15136
15137         * modules/mbiter: New file.
15138         * MODULES.html.sh (Extended multibyte and wide character utilities):
15139         Add mbiter.
15140
15141 2005-08-16  Bruno Haible  <bruno@clisp.org>
15142
15143         * modules/mbfile: New file.
15144         * MODULES.html.sh (Extended multibyte and wide character utilities):
15145         Add mbfile.
15146
15147 2005-08-16  Bruno Haible  <bruno@clisp.org>
15148
15149         * modules/mbchar: New file.
15150         * MODULES.html.sh (Extended multibyte and wide character utilities):
15151         New section.
15152
15153 2005-08-16  Bruno Haible  <bruno@clisp.org>
15154
15155         * m4/tls.m4: New file, from GNU gettext.
15156
15157 2005-08-16  Bruno Haible  <bruno@clisp.org>
15158
15159         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
15160         always.
15161         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
15162
15163 2005-08-16  Bruno Haible  <bruno@clisp.org>
15164
15165         * m4/mbiter.m4: New file.
15166
15167 2005-08-16  Bruno Haible  <bruno@clisp.org>
15168
15169         * m4/mbfile.m4: New file.
15170
15171 2005-08-16  Bruno Haible  <bruno@clisp.org>
15172
15173         * m4/mbchar.m4: New file.
15174
15175 2005-08-16  Bruno Haible  <bruno@clisp.org>
15176
15177         * lib/tls.h: New file, from GNU gettext.
15178         * lib/tls.c: New file, from GNU gettext.
15179
15180 2005-08-16  Bruno Haible  <bruno@clisp.org>
15181
15182         * lib/strnlen1.h: New file.
15183         * lib/strnlen1.c: New file.
15184
15185 2005-08-16  Bruno Haible  <bruno@clisp.org>
15186
15187         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
15188         (mbi_init): Update.
15189         (mbi_avail, mbi_advance): Let the iteration end before the terminating
15190         NUL byte, not after it.
15191
15192 2005-08-16  Bruno Haible  <bruno@clisp.org>
15193
15194         * lib/strcase.h (strcasecmp): Add note in comments.
15195         * lib/strncasecmp.c: Use code from strcasecmp.c.
15196         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
15197         (strcasecmp): Work correctly in multibyte locales.
15198
15199 2005-08-16  Bruno Haible  <bruno@clisp.org>
15200
15201         * lib/mbiter.h: New file.
15202
15203 2005-08-16  Bruno Haible  <bruno@clisp.org>
15204
15205         * lib/mbfile.h: New file.
15206
15207 2005-08-16  Bruno Haible  <bruno@clisp.org>
15208
15209         * lib/mbchar.h: New file.
15210         * lib/mbchar.c: New file.
15211
15212 2005-08-16  Bruno Haible  <bruno@clisp.org>
15213
15214         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
15215         the valid ones. Makes the comparison operations transitive:
15216         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
15217         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
15218
15219 2005-08-15  Simon Josefsson  <jas@extundo.com>
15220
15221         * modules/ssize_t (License): Change to 'unlimited'.
15222
15223         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
15224
15225 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
15226
15227         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
15228         Add comments for each pending glibc patch.
15229
15230 2005-08-15  Bruno Haible  <bruno@clisp.org>
15231
15232         * lib/regex.h (__restrict_arr): Don't define to __restrict if
15233         __cplusplus is defined.
15234
15235 2005-08-14  Jim Meyering  <jim@meyering.net>
15236
15237         Sync from coreutils.
15238
15239         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
15240         Use the hash-table-based cycle-detection code not just when
15241         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
15242         Reported by James Youngman in
15243         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
15244         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
15245         FTS_TIGHT_CYCLE_CHECK.
15246         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
15247         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
15248         once again.
15249         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
15250         * lib/fts.c (fd_safer): Remove decl.
15251         Include fcntl--.h rather than unistd-safer.h
15252         (fts_safe_changedir): Don't call fd_safer; no longer needed
15253         now that we include fcntl--.h.
15254
15255 2005-08-12  Simon Josefsson  <jas@extundo.com>
15256
15257         * modules/getndelim2: Use ssize_t module.
15258         * modules/getnline: Likewise.
15259         * modules/safe-read: Likewise.
15260         * modules/xreadlink: Likewise.
15261
15262         * modules/ssize_t: New file.
15263
15264 2005-08-12  Simon Josefsson  <jas@extundo.com>
15265
15266         * m4/readline.m4: Look for termcap, curses or ncurses if required.
15267
15268 2005-08-12  Simon Josefsson  <jas@extundo.com>
15269
15270         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15271         ssize_t.
15272
15273 2005-08-12  Simon Josefsson  <jas@extundo.com>
15274
15275         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
15276         readline, getdelim and check_version.
15277         (Support for systems lacking ISO C 99: Sizes of integer types):
15278         Add size_max.
15279
15280 2005-08-12  Bruno Haible  <bruno@clisp.org>
15281
15282         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
15283
15284 2005-08-11  Simon Josefsson  <jas@extundo.com>
15285
15286         * modules/readline: New file.
15287
15288         * modules/strnlen (Files): Add strnlen.h.
15289
15290 2005-08-11  Simon Josefsson  <jas@extundo.com>
15291
15292         * m4/readline.m4: New file.
15293
15294 2005-08-11  Simon Josefsson  <jas@extundo.com>
15295
15296         * lib/readline.h, readline.c: New file.
15297
15298 2005-08-11  Simon Josefsson  <jas@extundo.com>
15299
15300         * doc/gnulib.texi (Initial import, Finishing touches): Mention
15301         gl_AVOID.
15302
15303 2005-08-11  Bruno Haible  <bruno@clisp.org>
15304
15305         * lib/strnlen.h (strnlen): Change parameter name to match comment.
15306
15307 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
15308
15309         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
15310
15311 2005-08-10  Simon Josefsson  <jas@extundo.com>
15312
15313         * tests/test-iconvme.c: New file.
15314
15315 2005-08-10  Simon Josefsson  <jas@extundo.com>
15316
15317         * m4/strnlen.m4: New file.
15318
15319         * m4/strndup.m4: Don't check for strnlen declaration, done in
15320         strnlen.m4.
15321
15322 2005-08-10  Simon Josefsson  <jas@extundo.com>
15323
15324         * lib/strndup.c: Use strnlen.h.
15325
15326         * lib/strnlen.h: New file.
15327
15328 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15329
15330         * README: Typos.
15331
15332 2005-08-02  Simon Josefsson  <jas@extundo.com>
15333
15334         * modules/readline: New file.
15335
15336 2005-08-02  Simon Josefsson  <jas@extundo.com>
15337
15338         * modules/getdelim: New file.
15339
15340         * modules/getline: Rewrite, don't use getndelim2.
15341
15342 2005-08-02  Simon Josefsson  <jas@extundo.com>
15343
15344         * m4/getline.m4: Separate out getdelim stuff into separate module.
15345
15346         * m4/getdelim.m4: New file.
15347
15348 2005-08-02  Simon Josefsson  <jas@extundo.com>
15349
15350         * lib/getline.h, getline.c: Rewrite.
15351
15352         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
15353
15354 2005-07-31  Bruno Haible  <bruno@clisp.org>
15355
15356         * lib/lock.h (gl_lock_initializer): New macro.
15357         (gl_lock_define_initialized): Use it.
15358         (gl_rwlock_initializer): New macro.
15359         (gl_rwlock_define_initialized): Use it.
15360         (gl_recursive_lock_initializer): New macro.
15361         (gl_recursive_lock_define_initialized): Use it.
15362
15363 2005-07-30  Karl Berry  <karl@gnu.org>
15364
15365         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
15366         Report from Ben Pfaff, regarding getopt.
15367
15368 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
15369
15370         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
15371         normal way.
15372         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
15373         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
15374         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
15375         (gl_GETOPT): Use the new macros.  Most of the implementation
15376         is moved to the new macros.  This is for programs like Emacs
15377         that don't want all the functionality of gl_GETOPT.
15378
15379 2005-07-26  Bruno Haible  <bruno@clisp.org>
15380
15381         * m4/lock.m4: Update from GNU gettext.
15382
15383 2005-07-26  Bruno Haible  <bruno@clisp.org>
15384
15385         * lib/lock.h: Update from GNU gettext.
15386         * lib/lock.c: Update from GNU gettext.
15387
15388 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
15389
15390         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
15391         obsolescent AC_TRY_RUN.  Include the default includes files, for
15392         'exit'.
15393
15394 2005-07-24  Bruno Haible  <bruno@clisp.org>
15395
15396         * modules/visibility: New file.
15397         * MODULES.html.sh (Misc): Add visibility.
15398
15399 2005-07-24  Bruno Haible  <bruno@clisp.org>
15400
15401         * m4/visibility.m4: New file.
15402
15403 2005-07-24  Bruno Haible  <bruno@clisp.org>
15404
15405         * doc/visibility.texi: New file.
15406
15407 2005-07-22  Bruno Haible  <bruno@clisp.org>
15408
15409         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
15410         $(ALLOCA_H), redundant through BUILT_SOURCES.
15411         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
15412         redundant through BUILT_SOURCES.
15413         * modules/byteswap (Makefile.am): Remove explicit dependency on
15414         $(BYTESWAP_H), redundant through BUILT_SOURCES.
15415         * modules/fnmatch (Makefile.am): Remove explicit dependency on
15416         $(FNMATCH_H), redundant through BUILT_SOURCES.
15417         * modules/getopt (Makefile.am): Remove explicit dependency on
15418         $(GETOPT_H), redundant through BUILT_SOURCES.
15419         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
15420         redundant through BUILT_SOURCES.
15421         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
15422         redundant through BUILT_SOURCES.
15423         * modules/stdbool (Makefile.am): Remove explicit dependency on
15424         $(STDBOOL_H), redundant through BUILT_SOURCES.
15425         * modules/stdint (Makefile.am): Remove explicit dependency on
15426         $(STDINT_H), redundant through BUILT_SOURCES.
15427         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
15428         Remove explicit dependency on $(SYSEXITS_H).
15429         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
15430
15431 2005-07-18  Simon Josefsson  <jas@extundo.com>
15432
15433         * lib/check-version.c (check_version): Accept identical versions too.
15434
15435 2005-07-18  Bruno Haible  <bruno@clisp.org>
15436
15437         * modules/lock: New file.
15438         * MODULES.html.sh (Multithreading): New section.
15439
15440 2005-07-18  Bruno Haible  <bruno@clisp.org>
15441
15442         * m4/lock.m4: New file, from GNU gettext.
15443
15444 2005-07-18  Bruno Haible  <bruno@clisp.org>
15445
15446         * lib/lock.h: New file, from GNU gettext.
15447         * lib/lock.c: New file, from GNU gettext.
15448
15449 2005-07-18  Bruno Haible  <bruno@clisp.org>
15450
15451         * lib/lock.h (gl_once_t): New type.
15452         (gl_once_define, gl_once): New macros.
15453         * lib/lock.c (fresh_once): New variable.
15454         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
15455         functions.
15456
15457 2005-07-16  Simon Josefsson  <jas@extundo.com>
15458
15459         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
15460         workaround, suggested by Bruno.
15461
15462 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
15463
15464         * modules/xalloc (Depends-on): Add xalloc-die.
15465         * modules/xvasprintf (Depends-on): Add xalloc-die.
15466
15467 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
15468
15469         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
15470         with a minor change.
15471
15472 2005-07-15  Bruno Haible  <bruno@clisp.org>
15473
15474         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
15475         When using lib/poll.c, define poll as rpl_poll.
15476
15477 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
15478
15479         * modules/argp (Depends-on): Remove unlocked-io.
15480
15481 2005-07-14  Derek Price  <derek@ximbiot.com>
15482
15483         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
15484         for glob symlink bug.
15485
15486 2005-07-14  Bruno Haible  <bruno@clisp.org>
15487
15488         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
15489         Instead, test for *_unlocked function declarations directly.
15490
15491 2005-07-11  Simon Josefsson  <jas@extundo.com>
15492
15493         * modules/size_max: New file.
15494
15495         * modules/xsize: Depend on size_max module for size_max.m4.
15496
15497 2005-07-11  Simon Josefsson  <jas@extundo.com>
15498
15499         * lib/size_max.h: New file.
15500
15501 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
15502
15503         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
15504         copyright symbol and the year.
15505         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
15506         (version_etc_va): Use parameterized copyright notice.
15507         Reword to conform to the current GNU coding standards.
15508
15509 2005-07-11  Karl Berry  <karl@gnu.org>
15510
15511         * doc/gnulib.texi (Quoting): new node.
15512         (Initial import): more info, from Patrice.
15513
15514 2005-07-11  Bruno Haible  <bruno@clisp.org>
15515
15516         * gnulib-tool (func_usage): Document option --avoid.
15517         (Command line options): Handle --avoid.
15518         (func_acceptable): New function.
15519         (func_modules_transitive_closure): Use it.
15520
15521 2005-07-11  Bruno Haible  <bruno@clisp.org>
15522
15523         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
15524         Reported by Jim Meyering.
15525
15526 2005-07-10  Bruno Haible  <bruno@clisp.org>
15527
15528         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
15529         Needed when size_t is smaller than 'unsigned int'.
15530         Reported by Paul Eggert.
15531
15532 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15533
15534         * modules/argp (Depends-on): Add unlocked-io
15535
15536 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
15537
15538         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
15539         block of defines.
15540
15541 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
15542
15543         * config/srclist.txt: Comment out regcomp.c, since we have a porting
15544         fix now.
15545
15546 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
15547         and Paul Eggert  <eggert@cs.ucla.edu>
15548
15549         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
15550         in wint_t, not wchar_t.  Remove now-unnecessary cast.
15551
15552 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15553
15554         * modules/regex (Files): Add lib/regex_internal.c,
15555         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
15556         (Depends-on): Add extensions.
15557         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
15558
15559 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15560
15561         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
15562         pathconf.
15563         * m4/same.m4 (gl_SAME): Likewise.
15564         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
15565
15566         * m4/regex.m4: Adjust to new libc regex implementation.
15567         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
15568         all the .c and .h parts of (the new) regex.
15569         Quote the m4 stuff better.
15570         Check for RE_ICASE bug of old gnulib.
15571         Check for REG_STARTEND of recent libc.
15572         Rename local variables from jm_* to gl_*.
15573         Quote operand of "test -f".
15574         Say "recent enough" version of libc, not "version 2".
15575         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
15576         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
15577         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
15578         Remove check for btowc, isascii.
15579         Require AM_LANGINFO_CODESET.
15580
15581 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15582
15583         * lib/regex.c, regex.h: Sync from libc.
15584         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
15585         * lib/regexec.c:
15586         New files, synced from libc, except that regex_internal.h
15587         currently has a small porting fix.
15588
15589 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
15590
15591         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
15592         regex_internal.c, regexec.c.
15593         Add regex_internal.h too, but as a comment, since the libc version
15594         is currently broken in gnulib mode.
15595
15596 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
15597
15598         Support programs like Emacs that use gnulib but not gettext.
15599         * MODULES.html.sh (Internationalization functions): Add gettext-h.
15600         * modules/gettext-h: New file.
15601         * modules/gettext (Files): Remove lib/gettext.h.
15602         (Depends-on): Add gettext-h.
15603         (Makefile.am): Remove lib_SOURCES.
15604         * modules/argmatch, modules/c-stack, modules/closeout:
15605         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
15606         * modules/execute, modules/file-type, modules/getaddrinfo:
15607         * modules/getopt, modules/human, modules/javacomp:
15608         * modules/javaexec, modules/mkdir-p, modules/obstack:
15609         * modules/openat, modules/pagealign_alloc, modules/pipe:
15610         * modules/quotearg, modules/regex, modules/rpmatch:
15611         * modules/unicodeio, modules/userspec, modules/version-etc:
15612         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
15613         * modules/xsetenv:
15614         Depend on gettext-h, not gettext.
15615
15616 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
15617
15618         * gnulib-tool (func_import): Add support for 'public domain' license.
15619         * modules/alloca, modules/atexit, modules/memmove:
15620         Now public domain, not GPL.
15621         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
15622         * modules/realloc, modules/strerror, modules/strtod:
15623         Now LGPL, not GPL.
15624
15625 2005-07-05  Bruno Haible  <bruno@clisp.org>
15626
15627         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
15628         autoconf CVS. Needed for mingw.
15629
15630 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15631
15632         Remove the dependency of the strftime module on the tzset module.
15633         * modules/strftime (Depends-on): Remove dependency on tzset.
15634
15635 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15636
15637         Remove the dependency of the strftime module on the tzset module.
15638         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
15639         gl_FUNC_TZSET_CLOBBER.
15640
15641 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
15642
15643         Remove the dependency of the strftime module on the tzset module.
15644         * lib/strftime.c (my_strftime)
15645         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
15646         Copy the input structure, to work around some of the bug with
15647         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
15648         Solaris releases, you should also use the tzset module, but we won't
15649         require it as a dependency any more since we don't want LGPLed code
15650         to depend on GPLed code.
15651
15652 2005-07-02  Jim Meyering  <jim@meyering.net>
15653
15654         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
15655         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
15656         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
15657         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
15658
15659 2005-07-02  Jim Meyering  <jim@meyering.net>
15660
15661         * lib/backupfile.c (backup_args): Change a `0' to NULL.
15662
15663 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
15664
15665         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
15666         declares only 'struct timespec;' (!).
15667
15668 2005-07-01  Jim Meyering  <jim@meyering.net>
15669
15670         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
15671         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
15672         * lib/save-cwd.c, tempname.c:
15673         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
15674         and don't include <sys/file.h>).
15675
15676 2005-06-29  Jim Meyering  <jim@meyering.net>
15677
15678         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
15679         type name.  Use the variable name instead.
15680         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
15681         Likewise.
15682
15683 2005-06-28  Simon Josefsson  <jas@extundo.com>
15684
15685         * modules/check-version (Files): Add check-version.m4.
15686
15687 2005-06-28  Simon Josefsson  <jas@extundo.com>
15688
15689         * m4/check-version.m4: New file, suggested by Jim Meyering
15690         <jim@meyering.net>.
15691
15692 2005-06-28  Simon Josefsson  <jas@extundo.com>
15693
15694         * lib/check-version.h, lib/check-version.c: New files.
15695
15696 2005-06-28  Simon Josefsson  <jas@extundo.com>
15697
15698         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
15699         collision with global variable.  Better indentation.  Don't
15700         increment buffer pointer beyond buffer end.  Based on comments
15701         from Paul Eggert <eggert@cs.ucla.edu>.
15702
15703         * lib/base64.h: Indent.
15704
15705 2005-06-28  Simon Josefsson  <jas@extundo.com>
15706
15707         * doc/gnulib.texi (Library version handling): New section.
15708
15709 2005-06-28  Jim Meyering  <jim@meyering.net>
15710
15711         * check-module (find_included_lib_files): Hard-code another
15712         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
15713         but modules/fts-lgpl (correctly) does not list those files.
15714
15715         * modules/canonicalize (Files): Add lib/pathmax.h.
15716
15717 2005-06-25  Simon Josefsson  <jas@extundo.com>
15718
15719         * modules/check-version: New file.
15720
15721 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
15722
15723         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
15724         initializer of struct addrinfo, as an indication that we don't
15725         care how many members the structure has.
15726
15727 2005-06-24  Derek Price  <derek@ximbiot.com>
15728         and Bruno Haible  <bruno@clisp.org>
15729
15730         Remove stat module & update lstat.
15731         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
15732         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
15733         * m4/stat.m4: Remove this file.
15734
15735 2005-06-24  Derek Price  <derek@ximbiot.com>
15736         and Bruno Haible  <bruno@clisp.org>
15737
15738         Remove stat module & update lstat.
15739         * lib/stat.c: Remove this file...
15740         (slash_aware_lstat): ...moving this content and its support...
15741         * lib/lstat.c (rpl_lstat): ...into here.
15742         * lib/lstat.h: New file.
15743
15744 2005-06-24  Derek Price  <derek@ximbiot.com>
15745         and Bruno Haible  <bruno@clisp.org>
15746
15747         Remove stat module & update lstat.
15748         * config/srclist.txt (libc sources): Remove stat.
15749
15750 2005-06-24  Derek Price  <derek@ximbiot.com>
15751         and Bruno Haible  <bruno@clisp.org>
15752
15753         Remove stat module & update lstat.
15754         * MODULES.html.sh (stat): Remove.
15755         * MODULES.html: Regenerated.
15756         * modules/lstat (Description): Correct function name.
15757         (Files): Add "lstat.h".
15758         (Depends-on): Remove stat, add xalloc, stat-macros.
15759         * modules/stat: Remove this file.
15760         (Include): Add "lstat.h", remove <sys/stat.h>.
15761
15762 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
15763
15764         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
15765         (ranged_convert): Don't save conversion in a temporary struct.
15766         This causes a warning with GCC 4.0.0, and anyway in the typical
15767         case it's not worth the extra 100 bytes or so of code.
15768         (ranged_convert, __mktime_internal): When calling a function via a
15769         pointer P, use P () rather than (*P) (), as we now assume C89 or
15770         better.
15771
15772 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
15773
15774         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
15775         "who -r" failed to give output.  Problem reported by Tim Waugh.
15776
15777         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
15778         (xcalloc): Use it to avoid needless tests.
15779         Problem reported by Jim Meyering.
15780
15781 2005-06-20  Derek Price  <derek@ximbiot.com>
15782
15783         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
15784         unnecessary for Autoconfs > 2.59c.
15785
15786 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
15787
15788         * lib/argp.h (__option_is_short): Check upper limit of
15789         __key. Isprint() requires its argument to have the value
15790         of an unsigned char or EOF.
15791
15792 2005-06-16  Jim Meyering  <jim@meyering.net>
15793
15794         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
15795         when either N or S is zero.
15796
15797 2005-06-16  Derek Price  <derek@ximbiot.com>
15798
15799         * m4/bison.m4: Declare YACC & YFLAGS precious.
15800
15801 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
15802
15803         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
15804         multibyte string or pattern, fall back on unibyte matching.
15805         Problem reported by James Youngman.
15806
15807 2005-06-08  Bruno Haible  <bruno@clisp.org>
15808
15809         * modules/csharpcomp: New file.
15810         * MODULES.html.sh (C#): Add csharpcomp.
15811
15812 2005-06-08  Bruno Haible  <bruno@clisp.org>
15813
15814         * m4/csharpcomp.m4: New file, from GNU gettext.
15815
15816 2005-06-08  Bruno Haible  <bruno@clisp.org>
15817
15818         * lib/csharpcomp.h: New file, from GNU gettext.
15819         * lib/csharpcomp.c: New file, from GNU gettext.
15820         * lib/csharpcomp.sh.in: New file, from GNU gettext.
15821
15822 2005-06-08  Bruno Haible  <bruno@clisp.org>
15823
15824         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
15825         warning on mingw.
15826
15827 2005-06-07  Derek Price  <derek@ximbiot.com>
15828
15829         Sync from CVS.
15830         * lib/glob_.h: Indent nested #ifdef.
15831
15832 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15833
15834         Sync from coreutils.
15835         Use "file name" when talking about file names, instead of "filename"
15836         or "path", as per the GNU coding standards.
15837         * lib/mkdir-p.c: Renamed from makepath.c.
15838         (make_dir_parents): Renamed from make_path.  All callers changed.
15839         * lib/mkdir-p.h: Likewise.  All includers changed.
15840         * lib/filenamecat.c: Renamed from path-concat.c.
15841         (file_name_concat): Renamed from path_concat.  All callers changed.
15842         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
15843         * lib/filenamecat.h: Likewise.  All includers changed.
15844         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
15845         in comments or local variable names.
15846         * lib/basename.c: Likewise.
15847         * lib/canonicalize.c, canonicalize.h: Likewise.
15848         * lib/dirname.c, dirname.h: Likewise.
15849         * lib/euidaccess.c: Likewise.
15850         * lib/exclude.c: Likewise
15851         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
15852         * lib/fsusage.c, fsuage.h: Likewise.
15853         * lib/fts.c, fts_.h: Likewise.
15854         * lib/getcwd.c: Likewise.
15855         * lib/getloadavg.c: Likewise.
15856         * lib/mkstemp.c: Likewise.
15857         * lib/mountlist.c, mountlist.h: Likewise.
15858         * lib/openat.c, openat.h: Likewise.
15859         * lib/readlink-stub.c: Likewise.
15860         * lib/readutmp.c, readutmp.h: Likewise.
15861         * lib/rename.c: Likewise.
15862         * lib/rmdir.c: Likewise.
15863         * lib/same.c: Likewise.
15864         * lib/savedir.c: Likewise.
15865         * lib/stripslash.c: Likewise.
15866         * lib/tempname.c: Likewise.
15867         * lib/xreadlink.c: Likewise.
15868         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
15869         All uses changed.
15870         * lib/exclude.h: Likewise.
15871
15872         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
15873         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15874         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
15875         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15876         * lib/pathmax.h: Include <limits.h> unconditionally, since other
15877         files have been getting away with it for years (MORE/BSD 4.3
15878         is extinct now).
15879         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
15880         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
15881
15882         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
15883         Define to 256, not 255, as per modern POSIX.
15884
15885 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15886
15887         Sync from coreutils.
15888         Use "file name" when talking about file names, instead of "filename"
15889         or "path", as per the GNU coding standards.
15890         * MODULES.html.sh: mkdir-p renamed from makepath.
15891         filenamecat renamed from path-concat.
15892         * modules/filenamecat: Renamed from modules/path-concat.
15893         (Files): filenamecat.h and filenamecat.c renamed from
15894         path-concat.h and path-concat.c.
15895         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
15896         (Include): filenamecat.h, not path-concat.h.
15897         * modules/mkdir-p: Renamed from modules/makepath.
15898         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
15899         makepath.c.
15900         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
15901         (Include): mkdir-p.h, not makepath.h.
15902
15903 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
15904
15905         Sync from coreutils.
15906         * m4/mkdir-p.m4: Renamed from makepath.m4.
15907         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
15908         Rename files from makepath.c to mkdir-p.c, and from
15909         makepath.h to mkdir-p.h.
15910         * m4/filenamecat.m4: Renamed from path-concat.m4.
15911         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
15912         Rename files from path-concat.c to filenamecat.c,
15913         and from path-concat.h to filenamecat.h.
15914         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
15915         "file name" in local variables or comments.
15916         * m4/rename.m4: Likewise.
15917
15918 2005-06-01  Bruno Haible  <bruno@clisp.org>
15919
15920         * modules/csharpexec: New file.
15921         * MODULES.html.sh (C#): New section.
15922
15923 2005-06-01  Bruno Haible  <bruno@clisp.org>
15924
15925         * m4/csharp.m4: New file, from GNU gettext.
15926         * m4/csharpexec.m4: New file, from GNU gettext.
15927
15928 2005-06-01  Bruno Haible  <bruno@clisp.org>
15929
15930         * lib/csharpexec.h: New file, from GNU gettext.
15931         * lib/csharpexec.c: New file, from GNU gettext.
15932         * lib/csharpexec.sh.in: New file, from GNU gettext.
15933
15934 2005-05-31  Derek Price  <derek@ximbiot.com>
15935             Paul Eggert  <eggert@cs.ucla.edu>
15936
15937         Sync from cvs.
15938         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
15939
15940 2005-05-31  Derek Price  <derek@ximbiot.com>
15941             Paul Eggert  <eggert@cs.ucla.edu>
15942
15943         Sync from cvs.
15944         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
15945
15946 2005-05-29  Derek Price  <derek@ximbiot.com>
15947
15948         * config/srclist.txt (glob_.h, glob.c): Add these files.
15949
15950 2005-05-29  Derek Price  <derek@ximbiot.com>
15951
15952         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
15953         * modules/glob: New file.
15954         * modules/getlogin_r: Add link to POSIX spec in description.
15955
15956 2005-05-29  Derek Price  <derek@ximbiot.com>
15957             Paul Eggert  <eggert@cs.ucla.edu>
15958
15959         * m4/glob.m4: New file.
15960
15961 2005-05-29  Derek Price  <derek@ximbiot.com>
15962             Paul Eggert  <eggert@cs.ucla.edu>
15963
15964         * lib/glob_.h, lib/glob.c: New files.
15965
15966 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
15967
15968         * modules/fts (Files): Remove m4/inttypes-pri.m4.
15969         * modules/fts-lgpl (Depends-on): Remove gettext.
15970
15971 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
15972
15973         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
15974         and don't require gt_INTTYPES_PRI.
15975
15976 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
15977
15978         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
15979
15980         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
15981         the configuration hassle isn't worth it.
15982         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
15983         (LONGEST_MODIFIER, PRIuMAX): Remove.
15984
15985 2005-05-27  Bruno Haible  <bruno@clisp.org>
15986
15987         * lib/getlogin_r.h: Remove second include of <stddef.h>.
15988
15989 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
15990
15991         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
15992         _POSIX_PTHREAD_SEMANTICS for Solaris.
15993
15994 2005-05-25  Derek Price  <derek@ximbiot.com>
15995
15996         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
15997
15998 2005-05-25  Derek Price  <derek@ximbiot.com>
15999             Paul Eggert  <eggert@cs.ucla.edu>
16000
16001         * modules/getlogin_r, m4/getlogin_r.m4: New files.
16002         * lib/getlogin_r.c, getlogin_r.h: New files.
16003
16004 2005-05-25  Bruno Haible  <bruno@clisp.org>
16005             Derek Price  <derek@ximbiot.com>
16006
16007         * lib/getlogin_r.h: Simplify API documentation.
16008
16009 2005-05-23  Derek Price  <derek@ximbiot.com>
16010
16011         * modules/minmax (Files): Add m4/minmax.m4.
16012         (configure.ac): Add gl_MINMAX.
16013
16014 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
16015
16016         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
16017         so that unistd-safer.h (GPL'ed code) need not be included.
16018
16019 2005-05-22  Bruno Haible  <bruno@clisp.org>
16020
16021         * m4/minmax.m4: New file.
16022         Based on a patch by Derek Price <derek@ximbiot.com>.
16023
16024 2005-05-22  Bruno Haible  <bruno@clisp.org>
16025
16026         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
16027         (INT64_MIN): Fix definition.
16028         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
16029
16030         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
16031         NEED_SIGNED_INT_TYPES.
16032
16033         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
16034         HAVE_SYSTEM_INTTYPES.
16035
16036 2005-05-22  Bruno Haible  <bruno@clisp.org>
16037
16038         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
16039         Also include <sys/param.h> if it defines MIN, MAX.
16040         Based on a patch by Derek Price <derek@ximbiot.com>.
16041
16042 2005-05-21  Jim Meyering  <jim@meyering.net>
16043
16044         * modules/fts (Files): Add m4/inttypes-pri.m4.
16045         (Depends-on): Add lstat and remove gettext.  Alphabetize.
16046
16047 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16048
16049         New fts module.
16050         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
16051         (setup_dir, free_dir): New functions.
16052         (enter_dir, leave_dir): Define trivial
16053         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
16054         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
16055         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
16056         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
16057         Move to fts-cycle.c.
16058         (fts_open): Use setup_dir.
16059         (fts_close): Use free_dir.
16060         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
16061         This adds a label and some gotos, but the alternatives were messier.
16062         Check for memory allocation failure when entering a dir.
16063         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
16064         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
16065         (FTS): New member fts_cycle, that is a union that contains the
16066         old active_dir_ht and cycle_state.  All uses changed to mention
16067         fts_cycle.ht and fts_cycle.state.
16068         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
16069         fts.c, with the following changes:
16070         (setup_dir, free_dir): New functions.
16071         (enter_dir): Now returns bool.  Return true if successful, false
16072         if memory exhausted.  All callers changed.
16073         Do not bother partly cleaning up on
16074         memory allocation failure; that is free_dir's job.
16075         However, free ad if hash_insert fails, to avoid memory leak.
16076         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
16077         fts->fts_options to see which union member to use.
16078
16079 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16080
16081         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
16082         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
16083
16084 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16085
16086         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
16087
16088 2005-05-20  Jim Meyering  <jim@meyering.net>
16089
16090         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
16091         Now a macro, to pacify GCC.
16092
16093 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16094
16095         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
16096         of -1.
16097
16098 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16099
16100         * lib/chown.c (rpl_chown): Return -1 on failure.
16101
16102 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16103
16104         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
16105         Don't check for stddef.h.
16106         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
16107         don't use its results.
16108         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
16109         since we include them unconditionally.  Don't require
16110         AM_STDBOOL_H, since stdbool is a prerequisite.
16111         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
16112         since we assume C89 or better.
16113         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
16114         as we don't use their results.
16115         Don't check for fchdir, memmove, memset, strrchr, as we use
16116         them unconditionally.
16117         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
16118         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
16119
16120 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16121
16122         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
16123         Include <stddef.h> unconditionally, since we assume C89 now.
16124         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
16125         * lib/fts.c: Include fts_.h first, to check interface.
16126         Do not include intprops.h; no longer needed.
16127         Include cycle-check.h and hash.h, since fts_.h no longer does.
16128         Remove unnecessary casts of closedir to void.
16129         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
16130         decide whether to decrement nlinks.
16131         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
16132         (FTS): Use struct hash_table * instead of Hash_table, so that
16133         we no longer need to include hash.h here.
16134
16135 2005-05-18  Jim Meyering  <jim@meyering.net>
16136
16137         * modules/dirfd (License): Change to LGPL.  Most of the code
16138         is already in the public domain.
16139
16140 2005-05-18  Jim Meyering  <jim@meyering.net>
16141
16142         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
16143         Reported by Yoann Vandoorselaere.
16144
16145 2005-05-17  Jim Meyering  <jim@meyering.net>
16146
16147         * m4/fts.m4: New file, from coreutils.
16148
16149 2005-05-17  Jim Meyering  <jim@meyering.net>
16150
16151         * lib/fts.c, lib/fts_.h: New files, from coreutils.
16152
16153 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16154
16155         Sync from coreutils.
16156         * m4/unlinkdir.m4: New file.
16157
16158 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16159
16160         Sync from coreutils.
16161         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
16162         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
16163         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
16164         White space changes only.
16165         * lib/makepath.c (make_path): Port to hosts where leading "//" is
16166         special.
16167         * lib/yesno.c: Include getline.h, not ctype.h.
16168         (yesno): Don't remove leading white space; POSIX doesn't allow it.
16169         Use getline to remove arbitrary restriction on response length.
16170
16171 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16172
16173         * config/srclist-update: Spell out "Street" in FSF postal
16174         mail address; this is the style the FSF seems to prefer.
16175
16176         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
16177         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
16178         this updates FSF postal mail address.
16179
16180         Sync from coreutils.
16181         * modules/unlinkdir: New file.
16182         * modules/yesno (Depends-on): Add getline.
16183         * MODULES.html.sh (File system functions): Add unlinkdir.
16184
16185 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16186
16187         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
16188         lib/strsep.h:
16189         Change the initial comment to refer to GPL, not LGPL.
16190         gnulib-tool will change it to LGPL as needed.
16191
16192         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
16193         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
16194         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
16195         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
16196         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
16197         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
16198         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
16199         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
16200         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
16201         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
16202         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
16203         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
16204         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
16205         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
16206         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
16207         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
16208         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
16209         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
16210         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
16211         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
16212         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
16213         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
16214         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
16215         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
16216         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
16217         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
16218         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
16219         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
16220         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
16221         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
16222         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
16223         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
16224         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
16225         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
16226         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
16227         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
16228         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
16229         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
16230         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
16231         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
16232         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
16233         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
16234         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
16235         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
16236         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
16237         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
16238         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
16239         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
16240         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
16241         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
16242         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
16243         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
16244         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
16245         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
16246         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
16247         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
16248         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
16249         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
16250         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
16251         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
16252         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
16253         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
16254         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
16255         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
16256         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
16257         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
16258         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
16259         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
16260         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
16261         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
16262         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
16263         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
16264         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
16265         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
16266         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
16267         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
16268         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
16269         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
16270         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
16271         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
16272         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
16273         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
16274         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
16275         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
16276         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
16277         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
16278         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
16279         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
16280         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
16281         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
16282         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
16283         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
16284         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
16285         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
16286         lib/yesno.c, lib/yesno.h:
16287         Update FSF postal mail address.
16288
16289 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16290
16291         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
16292         tests/test-memmem.c, tests/test-stpncpy.c:
16293         Update FSF postal mail address.
16294
16295 2005-05-13  Bruno Haible  <bruno@clisp.org>
16296
16297         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
16298         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
16299         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
16300         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
16301         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
16302         Add support for 64-bit integers in the MSVC compiler.
16303
16304 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16305
16306         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
16307
16308 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
16309
16310         * gnulib-tool (func_import): Sort and uniquify recommended includes.
16311
16312 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
16313
16314         * doc/getdate.texi (General date syntax): Don't say that date
16315         date --iso-8601=ns generates acceptable dates; it doesn't yet.
16316         Problem reported by Nic Ferrier.
16317
16318 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16319
16320         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
16321         specified in ai_socktype. Fix invalid ai_protocol
16322         check. ai_protocol is usually set to 0 or depending on
16323         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
16324         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
16325         ai_socktype / ai_protocol in the returned addrinfo structure.
16326
16327 2005-05-10  Simon Josefsson  <jas@extundo.com>
16328
16329         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
16330         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
16331
16332 2005-05-10  Karl Berry  <karl@gnu.org>
16333
16334         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
16335         (from http://www.gnu.org/licenses).
16336         * doc/COPYING.LIB: also rename to COPYING.LESSER.
16337         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
16338         fdl.texi suffices.
16339
16340 2005-05-10  Karl Berry  <karl@gnu.org>
16341
16342         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
16343         (COPYING.DOC): remove.
16344
16345         * config/srclist-update: new FSF address.
16346
16347 2005-05-10  Derek Price  <derek@ximbiot.com>
16348
16349         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
16350         possible.
16351
16352 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16353             Bruno Haible  <bruno@clisp.org>
16354
16355         * modules/inet_ntop: New file.
16356         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16357         inet_ntop.
16358
16359 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16360             Bruno Haible  <bruno@clisp.org>
16361
16362         * m4/inet_ntop.m4: New file.
16363
16364 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16365             Bruno Haible  <bruno@clisp.org>
16366
16367         * lib/inet_ntop.h: New file.
16368         * lib/inet_ntop.c: New file, from glibc with modifications.
16369
16370 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
16371
16372         * modules/time_r (License): Change to LGPL.
16373         * modules/extensions (License): Change to LGPL.  Actually,
16374         the license is more permissive than that, but currently gnulib-tool
16375         doesn't know how to handle more-permissive licenses.
16376
16377         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
16378         Problem reported by Dave Love.
16379
16380 2005-05-08  Jim Meyering  <jim@meyering.net>
16381
16382         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
16383         blank.
16384
16385 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
16386
16387         * modules/argmatch (Depends-on): Add stdbool.
16388         * modules/backupfile (Depends-on): Likewise.
16389         * modules/chdir-long (Depends-on): Likewise.
16390         * modules/closeout (Depends-on): Likewise.
16391         * modules/cycle-check (Depends-on): Likewise.
16392         * modules/dirname (Depends-on): Likewise.
16393         * modules/fnmatch (Depends-on): Likewise.
16394         * modules/fsusage (Depends-on): Likewise.
16395         * modules/fwriteerror (Depends-on): Likewise.
16396         * modules/getcwd (Depends-on): Likewise.
16397         * modules/getloadavg (Depends-on): Likewise.
16398         * modules/hard-locale (Depends-on): Likewise.
16399         * modules/makepath (Depends-on): Likewise.
16400         * modules/mountlist (Depends-on): Likewise.
16401         * modules/nanosleep (Depends-on): Likewise.
16402         * modules/posixtm (Depends-on): Likewise.
16403         * modules/quotearg (Depends-on): Likewise.
16404         * modules/readtokens (Depends-on): Likewise.
16405         * modules/readtokens0 (Depends-on): Likewise.
16406         * modules/readutmp (Depends-on): Likewise.
16407         * modules/save-cwd (Depends-on): Likewise.
16408         * modules/strftime (Depends-on): Likewise.
16409         * modules/userspec (Depends-on): Likewise.
16410         * modules/utimecmp (Depends-on): Likewise.
16411         * modules/xgetcwd (Depends-on): Likewise.
16412         * modules/xnanosleep (Depends-on): Likewise.
16413         * modules/xstrtod (Depends-on): Likewise.
16414         * modules/yesno (Depends-on): Likewise.
16415
16416 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
16417
16418         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
16419         needless checks.
16420
16421 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16422
16423         Merge from coreutils.  Among other things,
16424         add bulletproofing for cases where stdin, stdout, or stderr are closed.
16425         * lib/fd-safer.c: New file.
16426         * lib/fcntl-safer.h, open-safer.c: Remove.
16427         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
16428         * lib/dup-safer.c: Include unistd-safer.h first.
16429         Don't include errno.h.
16430         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
16431         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
16432         * lib/file-type.c: Rely on file-type.h change.
16433         * lib/getloadavg.c: Include unistd-safer.h.
16434         (getloadavg): Use safer open.
16435         * lib/getusershell.c: Include "stdio-safer.h".
16436         (getusershell): Use safer fopen.
16437         * lib/long-options.c (long_options): Use NULL rather than 0.
16438         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
16439         'free'.
16440         * lib/modechange.c: Likewise.
16441         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
16442         (MODE_DONE): New constant.
16443         (struct mode_change): Remove 'next' member.
16444         (make_node_op_equals): New function; like the old one of the
16445         same name, except it allocates an array.
16446         (mode_compile, mode_create_from_ref): Use it.
16447         (mode_compile): Allocate result as an array, not a linked list.
16448         Parse octal string ourself, so that we catch mistakes like "+0".
16449         (mode_adjust): Arg is an array, not a linked list.
16450         * lib/modechange.c: Include stat-macros.h, xalloc.h.
16451         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
16452         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
16453         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
16454         Remove.  This is now stat-macros.h's job.
16455         (talloc): Remove.  All callers replaced by xalloc, so that
16456         our invokers don't have to worry about reporting memory failures.
16457         (make_node_op_equals): Remove.
16458         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
16459         New constants.
16460         (struct mode_change): Moved here from modechange.h.
16461         (mode_append_entry): Remove.
16462         (mode_compile): Remove MASKED_OPS arg, since it encouraged
16463         apps to have incorrect behavior.  Use simpler algorithm for head
16464         and tail.  Don't futz with umask; that's now the job of mode_adjust.
16465         Detect more invalid usages rather than having somewhat-random behavior.
16466         Don't insert an "a=" action, as that leads to incorrect behavior.
16467         (mode_compile, mode_create_from_ref): Return NULL on error instead
16468         of an enum, since now there's only one way to have an error.  All
16469         callers changed.
16470         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
16471         at the correct time.  Simplify calculation of "+u" and its ilk.
16472         Don't mishandle "+X".
16473         (mode_free): Remove "register" and localize decls.
16474         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
16475         (struct mode_change): Move to modechange.c; callers don't
16476         need to see this stuff.
16477         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
16478         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
16479         (mode_change, mode_adjust): Reflect the new signatures noted above.
16480         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
16481         that might redefine system include files.
16482         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
16483         (my_usleep): Use NULL rather than (void *) 0.
16484         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
16485         Use siginterrupt to specify that system calls should be interrupted.
16486         (rpl_nanosleep): Move initialization of suspended closer to call of
16487         my_usleep.
16488         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
16489         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
16490         (desirable_utmp_entry): New function.
16491         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
16492         using x2nrealloc, to simplify logic.
16493         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
16494         size calculation.  Do not assume utmp file is a regular file.
16495         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
16496         (READ_UTMP_CHECK_PIDS): New constant.
16497         * lib/save-cwd.c: Include unistd-safer.h.
16498         (save_cwd): Use fd_safer.
16499         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
16500         [!_LIBC] Include "stat-macros.h" instead.
16501         * lib/unistd-safer.h (fd_safer): New decl.
16502
16503 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16504
16505         * modules/getloadavg (Depends-on): Add unistd-safer.
16506         * modules/getusershell (Depends-on): Add stdio-safer.
16507         * modules/lstat (Depends-on): Remove xalloc.
16508         * modules/mkstemp (Depends-on): Add stat-macros.
16509         * modules/modechange (Depends-on): Remove xstrtol.
16510         Add stat-macros, xalloc.
16511         * modules/save-cwd (Depends-on): Add unistd-safer.
16512         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
16513         * modules/unistd-safer (Files): Add lib/fd-safer.c
16514         (Makefile.am): Remove lib_SOURCES.
16515
16516         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
16517         Remove fcntl-safer; unistd-safer supersedes it.
16518
16519 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16520
16521         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
16522         AC_HEADER_STAT.
16523         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
16524         (gl_PREREQ_CHOWN): Remove.
16525         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
16526         it.  Don't require AC_HEADER_STAT.
16527         (gl_PREREQ_LSTAT): Remove.
16528         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
16529         Don't require AC_HEADER_STAT.
16530         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
16531         (gl_PREREQ_RMDIR): Remove.
16532         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
16533         mention stat-macros.h or AC_HEADER_STAT, since we'll make
16534         the stat-macros module a prerequisite.
16535         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
16536         * m4/filemode.m4 (gl_FILEMODE): Likewise.
16537         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
16538         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
16539         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
16540         variable names.
16541         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
16542         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
16543         variable prefixes.
16544         * m4/fcntl-safer.m4: Remove.
16545         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
16546         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
16547         Invoke gl_PREREQ_FD_SAFER.
16548         (gl_PREREQ_FD_SAFER): New macro.
16549         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
16550         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
16551         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
16552         Remove duplicate call to AC_LIBOBJ(readutmp).
16553         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
16554
16555         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
16556         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
16557
16558 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
16559
16560         * MODULES.html.sh (Misc): Add byteswap.
16561
16562 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16563
16564         * modules/getcwd (Depends-on): Add extensions.
16565         * modules/openat (Depends-on): Likewise.
16566
16567 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16568
16569         * modules/byteswap: New file.
16570
16571 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16572
16573         * m4/byteswap.m4: New file.
16574
16575 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
16576
16577         * lib/byteswap_.h: New file.
16578
16579 2005-04-25  Karl Berry  <karl@gnu.org>
16580
16581         * m4/gettext.m4: Update from GNU gettext 0.14.4.
16582
16583 2005-04-25  Albert Chin  <china@thewrittenword.com>
16584
16585         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
16586         Toolkit C bug.
16587
16588 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
16589
16590         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
16591         (func_ln_if_changed) Remove forcibly for no error message
16592         in case file does not exist.
16593
16594 2005-04-19  Simon Josefsson  <jas@extundo.com>
16595
16596         * gnulib-tool (Options): Make --symlink mean --symbolic.
16597
16598 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
16599
16600         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
16601
16602 2005-04-16  Simon Josefsson  <jas@extundo.com>
16603
16604         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
16605
16606 2005-04-15  Simon Josefsson  <jas@extundo.com>
16607
16608         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
16609
16610 2005-04-15  Simon Josefsson  <jas@extundo.com>
16611
16612         * gnulib-tool: Rename --symlink to --symbolic.
16613
16614 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
16615
16616         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
16617         symbolic links to files instead of copying/moving.  Add --aux-dir,
16618         specifying directory relative --dir where auxiliary build tools
16619         are placed.
16620
16621 2005-04-14  Bruno Haible  <bruno@clisp.org>
16622
16623         * modules/allocsa (License): Change to LGPL.
16624         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
16625
16626 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
16627
16628         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
16629         that "UTC +1 second" continues to work.  Problem reported
16630         by Dmitry V. Levin.
16631         (relunit_snumber): New rule.
16632         (relunit): Use it.
16633
16634 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
16635
16636         * lib/getdate.y (universal_time_zone_table): New constant.
16637         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
16638         universal_time_zone_table.
16639         (lookup_zone): Prefer universal_time_zone_table to
16640         local_time_zone_table, so that "GMT" time stamps are allowed in
16641         London during the summer.  Problem reported by Ian Abbott.
16642
16643 2005-04-12  Jim Meyering  <jim@meyering.net>
16644
16645         * lib/human.c (humblock): Set *options even when returning due to
16646         xstrtoumax conversion failure.  Thanks to a used-uninitialized
16647         warning from gcc-4.
16648
16649 2005-04-09  Jim Meyering  <jim@meyering.net>
16650
16651         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
16652         -Wuninitialized: initialize tm0.tm_year.
16653
16654 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
16655
16656         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
16657         count, since there's no maximum.  All uses changed.
16658         Add member dsts_seen.
16659         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
16660         not being INT_MAX.
16661         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
16662         Use pc_rels_seen to decide whther a date is absolute.
16663
16664         * lib/getdate.y (number): Don't overwrite year.
16665         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
16666         check.
16667
16668 2005-04-02  Simon Josefsson  <jas@extundo.com>
16669
16670         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
16671         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
16672
16673 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
16674
16675         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
16676         where no absolute path name can be longer than PATH_MAX.
16677
16678 2005-03-27  Jim Meyering  <jim@meyering.net>
16679
16680         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
16681
16682 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
16683
16684         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
16685         "one's complement" -> "ones' complement" in comment, as per Knuth.
16686         "value of type" -> "type or expression" in comment.
16687         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
16688
16689 2005-03-26  Jim Meyering  <jim@meyering.net>
16690
16691         Comment nits.
16692         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
16693         Correct typos: s/or/of/.
16694
16695 2005-03-26  Jim Meyering  <jim@meyering.net>
16696
16697         * modules/check-include-files: Move to ../ and rename to...
16698         * check-module: ...this.
16699
16700 2005-03-25  Jim Meyering  <jim@meyering.net>
16701
16702         * modules/xvasprintf (Files): Add xalloc.h.
16703
16704 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
16705
16706         * modules/gettext (Files): config/config.rpath ->
16707         build-aux/config.rpath
16708         * modules/iconv (Files): Likewise.
16709         Problem reported by Oskar Liljeblad.
16710
16711 2005-03-23  Jim Meyering  <jim@meyering.net>
16712
16713         * modules/check-include-files: New script to check for
16714         missing dependencies, multiple includes, etc.
16715
16716         * modules/c-strtold (Depends-on): Add xalloc.
16717         * modules/c-strtod (Depends-on): Add xalloc.
16718         * modules/hash (Depends-on): Add xalloc.
16719         (Files): Remove lib/xalloc.h.
16720
16721         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
16722         * modules/userspec (Files): Add lib/inttostr.h.
16723
16724 2005-03-23  Jim Meyering  <jim@meyering.net>
16725
16726         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
16727
16728 2005-03-22  Jim Meyering  <jim@meyering.net>
16729
16730         * modules/stat-macros: New module.
16731         * modules/canonicalize, modules/euidaccess, modules/file-type,
16732         * modules/filemode, modules/lchown, modules/makepath,
16733         * modules/rmdir, modules/stat: Depend on new stat-macros module
16734         rather than listing lib/stat-macros.h manually.
16735         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
16736
16737 2005-03-22  Jim Meyering  <jim@meyering.net>
16738
16739         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
16740
16741 2005-03-22  Bruno Haible  <bruno@clisp.org>
16742
16743         * config/srclist.txt: Replace target directory 'config' with
16744         'build-aux'.
16745         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
16746         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
16747         ../build-aux/.
16748
16749 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
16750
16751         * modules/chdir-long (Depends-on): Add mempcpy.
16752
16753         * modules/acl, modules/backupfile, modules/c-strtod,
16754         modules/c-strtold, modules/canon-host, modules/canonicalize,
16755         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
16756         modules/exclude, modules/exitfail, modules/file-type,
16757         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
16758         modules/getdate, modules/getline, modules/getpagesize,
16759         modules/getpass, modules/getugroups, modules/group-member,
16760         modules/hard-locale, modules/hash, modules/human, modules/idcache,
16761         modules/inttostr, modules/long-options, modules/makepath,
16762         modules/md5, modules/memcasecmp, modules/memcoll,
16763         modules/modechange, modules/mountlist, modules/path-concat,
16764         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
16765         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
16766         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
16767         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
16768         modules/strftime, modules/strndup, modules/strverscmp,
16769         modules/timespec, modules/unlocked-io, modules/userspec,
16770         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
16771         modules/yesno:
16772         Remove lib_SOURCES line from Makefile.am section, as this is now
16773         done automatically by the corresponding Autoconf macro.
16774
16775 2005-03-21  Jim Meyering  <jim@meyering.net>
16776
16777         Changes imported from coreutils.
16778
16779         * lib/cycle-check.c: Don't include xalloc.h.
16780
16781         * lib/path-concat.c: Don't include assert.h.
16782         (path_concat): Remove assertion that would have triggered
16783         for ABASE starting with more than one slash.
16784         Reported by Andreas Schwab.
16785
16786         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
16787         properly when ABASE is an absolute file name.
16788         Correct the description of this function.
16789         Include <assert.h>.
16790         Add an assertion and a test driver.
16791         This fixes a bug introduced on 2004-07-02.
16792         Andreas Schwab reported the resulting failure of cp --parents:
16793         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
16794
16795 2005-03-21  Jim Meyering  <jim@meyering.net>
16796
16797         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
16798         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
16799
16800 2005-03-21  Jim Meyering  <jim@meyering.net>
16801         and  Paul Eggert  <eggert@cs.ucla.edu>
16802
16803         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
16804         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
16805         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
16806         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
16807         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
16808         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
16809         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
16810         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
16811         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
16812         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
16813         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
16814         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
16815         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
16816         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
16817         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
16818         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
16819         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
16820         for these modules.
16821
16822 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
16823
16824         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
16825         (which shouldn't happen), generate nothing instead of returning 0
16826         immediately, so that nstrftime (NULL, ...) doesn't return 0.
16827
16828 2005-03-16  Bruno Haible  <bruno@clisp.org>
16829
16830         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
16831         HAVE_LONGLONG_64BIT.
16832
16833 2005-03-16  Bruno Haible  <bruno@clisp.org>
16834
16835         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
16836         HAVE_LONGLONG_64BIT.
16837
16838 2005-03-16  Bruno Haible  <bruno@clisp.org>
16839
16840         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
16841         HAVE_LONGLONG_64BIT.
16842
16843 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
16844
16845         * lib/strftime.c (my_strftime): Prepend space to format so that we can
16846         reliably distinguish strftime failure from empty output on POSIX
16847         hosts.
16848
16849 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
16850
16851         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
16852         (iconv_string): Don't guess a size-zero buffer, as that might cause
16853         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
16854         result would be 'too large', where 'too large' is (heuristically)
16855         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
16856         overflow concerns.  This will prevent some unwanted malloc failures
16857         when the inputs are very large.
16858
16859 2005-03-15  Karl Berry  <karl@gnu.org>
16860
16861         * config/srclist.txt (config.rpath): from gettext.
16862         * config/config.rpath: update.
16863
16864 2005-03-15  Bruno Haible  <bruno@clisp.org>
16865
16866         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
16867         to 'negate'.
16868
16869         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
16870         variable.
16871
16872         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
16873         results.
16874
16875 2005-03-14  Simon Josefsson  <jas@extundo.com>
16876
16877         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
16878         <fx@gnu.org>.
16879
16880 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
16881
16882         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
16883         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
16884         intprops.h.
16885         * lib/strtol.c: Likewise.
16886
16887 2005-03-14  Jim Meyering  <jim@meyering.net>
16888
16889         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
16890         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
16891         to be nonzero so that we (and caller) can detect the difference
16892         between a valid zero-length expansion and an error return, even
16893         when the underlying strftime fails before writing anything into
16894         that location.
16895
16896 2005-03-14  Bruno Haible  <bruno@clisp.org>
16897
16898         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
16899         Update from GNU gettext 0.14.3.
16900
16901 2005-03-10  Jim Meyering  <jim@meyering.net>
16902
16903         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
16904
16905 2005-03-10  Jim Meyering  <jim@meyering.net>
16906
16907         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
16908         so that this module works on systems without fchdir.
16909
16910 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
16911
16912         Factor int-properties macros into a single file, except for
16913         glibc-related files.
16914         * lib/intprops.h: New file.
16915         * lib/getloadavg.c: Include it instead of limits.h.
16916         (INT_STRLEN_BOUND): Remove.
16917         * lib/human.c: Include intprops.h.
16918         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
16919         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
16920         302/1000.
16921         * lib/inttostr.h: Include intprops.h instead of limits.h.
16922         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
16923         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
16924         for consistency with intprops.h.
16925         (time_t_is_integer, twos_complement_arithmetic): Use them.
16926         * lib/sig2str.h: Include <signal.h>, intprops.h.
16927         (INT_STRLEN_BOUND): Remove.
16928         * lib/strftime.c (TYPE_SIGNED): Remove.
16929         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
16930         * lib/strtol.c: Adjust comments to match intprops.h.
16931         * lib/userspec.c: Include intprops.h.
16932         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
16933         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
16934         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
16935         instead of rolling our own expressions.
16936         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
16937
16938         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
16939         instead of int.
16940         (my_strftime): Do not mishandle years close to INT_MAX, by doing
16941         the right thing even if adding 1900 would overflow.  Similarly
16942         for tm_mon + 1 and tm_yday + 1.
16943         Make %Y always equivalent to %C%y, and similarly for %G and %g.
16944         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
16945         (DO_SIGNED_NUMBER): New macro.
16946         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
16947
16948 2005-03-07  Bruno Haible  <bruno@clisp.org>
16949
16950         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
16951
16952 2005-03-07  Bruno Haible  <bruno@clisp.org>
16953
16954         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
16955
16956 2005-03-04  Derek R. Price  <derek@ximbiot.com>
16957
16958         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
16959         (func_import): Only replace files via --import when they have actually
16960         changed.
16961
16962 2005-03-03  Derek R. Price  <derek@ximbiot.com>
16963
16964         * m4/mmap-anon.m4: New file.
16965         * m4/pagealign_alloc.m4: New file.
16966
16967 2005-03-03  Derek R. Price  <derek@ximbiot.com>
16968             Bruno Haible  <bruno@clisp.org>
16969
16970         * modules/pagealign_alloc: New file.
16971         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
16972
16973 2005-03-03  Derek R. Price  <derek@ximbiot.com>
16974             Bruno Haible  <bruno@clisp.org>
16975
16976         * lib/pagealign_alloc.h: New file.
16977         * lib/pagealign_alloc.c: New file.
16978
16979 2005-03-03  Bruno Haible  <bruno@clisp.org>
16980
16981         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
16982         Use an all-permissive copyright notice, recommended by RMS.
16983
16984 2005-03-02  Bruno Haible  <bruno@clisp.org>
16985
16986         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
16987         of AIX, the replacement has to be done only after <string.h> is
16988         included, therefore not in config.h. stpncpy.h does the replacement,
16989         and stpncpy.c uses it.
16990
16991 2005-03-02  Bruno Haible  <bruno@clisp.org>
16992
16993         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
16994         stpncpy.c uses it.
16995
16996 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
16997
16998         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
16999         The workaround isn't strictly needed for POSIX conformance, and
17000         it's too much of a pain to configure and maintain.  We'll ask
17001         people to fix their kernels instead.
17002         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
17003         (NANOSLEEP_BUG_WORKAROUND): Remove.
17004         (xnanosleep): Remove the workaround.
17005
17006 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17007
17008         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
17009         Reported by Derek Price.
17010         (Include): Add "timespec.h".
17011
17012         * modules/xnanosleep (Depends-on): Remove gethrxtime.
17013
17014 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17015
17016         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
17017         to detect nanosleep bug.
17018
17019 2005-03-01  Bruno Haible  <bruno@clisp.org>
17020
17021         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
17022
17023 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
17024
17025         * modules/gethrxtime: New file.
17026         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
17027         (Depends-on): Add gethrxtime.
17028         (configure.ac): Add gl_XNANOSLEEP.
17029         (Makefile.am): Remove lib_SOURCES line.
17030
17031 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17032
17033         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
17034         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
17035
17036 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17037
17038         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
17039         * lib/timespec.h (gettime): Return void, since it always
17040         succeeds now.  All uses changed.
17041         * lib/gettime.c (gettime) Likewise.
17042         [HAVE_NANOTIME]: Prefer nanotime.
17043         Assume gettimeofday succeeds, as POSIX requires.
17044         Assime time () succeeds, since other code already does.
17045         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
17046         (timespec_subtract): Remove.
17047         (NANOSLEEP_BUG_WORKAROUND): New constant.
17048         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
17049         things considerably.  Use it only on GNU/Linux hosts, since the
17050         workaround shouldn't be needed elsewhere.
17051
17052 2005-02-24  Bruno Haible  <bruno@clisp.org>
17053
17054         * modules/gettext (Files): Add m4/glibc2.m4.
17055
17056 2005-02-24  Bruno Haible  <bruno@clisp.org>
17057
17058         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
17059         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
17060         * m4/progtest.m4:
17061         Update from GNU gettext 0.14.2.
17062         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
17063
17064 2005-02-24  Bruno Haible  <bruno@clisp.org>
17065
17066         * lib/localcharset.c: Update from GNU gettext 0.14.2.
17067         * lib/config.charset: Update from GNU gettext 0.14.2.
17068
17069 2005-02-24  Bruno Haible  <bruno@clisp.org>
17070
17071         * lib/gettext.h: Update from GNU gettext 0.14.2.
17072
17073 2005-02-23  Simon Josefsson  <jas@extundo.com>
17074
17075         * m4/iconvme.m4: New file.
17076
17077 2005-02-23  Jim Meyering  <jim@meyering.net>
17078
17079         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
17080         change.
17081         Thanks to Bruno Haible for catching it.
17082
17083 2005-02-22  Simon Josefsson  <jas@extundo.com>
17084
17085         * modules/iconvme: New file.
17086
17087         * MODULES.html.sh: Add iconvme.
17088
17089 2005-02-22  Simon Josefsson  <jas@extundo.com>
17090
17091         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
17092
17093 2005-02-22  Simon Josefsson  <jas@extundo.com>
17094
17095         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
17096
17097 2005-02-22  Jim Meyering  <jim@meyering.net>
17098
17099         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
17100         s/ifndef/ifdef/.
17101
17102 2005-02-20  Neil Conway  <neilc@samurai.com>
17103
17104         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
17105         returned by OSX/Darwin if the specified buffer is not large
17106         enough for the hostname.
17107
17108 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17109
17110         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
17111         pass it to _help, otherwise the latter coredumps trying to
17112         dereference state.root_argp.
17113
17114 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17115
17116         * modules/chdir-long (Depends-on): Add memrchr.
17117         * modules/memrchr (Files): Add lib/memrchr.h.
17118         (Include): "memrchr.h".
17119
17120 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17121
17122         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
17123
17124 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17125
17126         * lib/memrchr.h: New file.
17127         * lib/chdir-long.c: Include it.
17128         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
17129         Don't bother including stddef.h.
17130
17131 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
17132
17133         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
17134         inclusion.
17135         Include <sys/types.h>, for dev_t.
17136         (ME_DUMMY, ME_REMOTE): Move from here....
17137         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
17138         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
17139         Dmitry V. Levin.
17140         Include mountlist.h first, to test the interface.
17141
17142 2005-01-29  Bruno Haible  <bruno@clisp.org>
17143
17144         * lib/progname.c (program_name): Initialize.
17145         Needed when linking statically on MacOS X.
17146
17147 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17148
17149         Sync from coreutils.
17150         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
17151         (Depends-on): Add c-strtod.
17152         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
17153
17154 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17155
17156         Sync from coreutils.
17157         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
17158
17159         Remove files that are specific to coreutils.
17160         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
17161
17162 2005-01-28  Bruno Haible  <bruno@clisp.org>
17163
17164         * modules/javacomp: New file.
17165         * MODULES.html.sh (Java): Add javacomp.
17166
17167 2005-01-28  Bruno Haible  <bruno@clisp.org>
17168
17169         * m4/javacomp.m4: New file, from GNU gettext.
17170
17171 2005-01-28  Bruno Haible  <bruno@clisp.org>
17172
17173         * lib/javacomp.sh.in: New file, from GNU gettext.
17174         * lib/javacomp.h: New file, from GNU gettext.
17175         * lib/javacomp.c: New file, from GNU gettext.
17176
17177 2005-01-26  Simon Josefsson  <jas@extundo.com>
17178
17179         * lib/gai_strerror.c: Use GPL in header.
17180
17181 2005-01-26  Bruno Haible  <bruno@clisp.org>
17182
17183         * modules/javaexec: New file.
17184         * MODULES.html.sh (Java): Add javaexec.
17185
17186 2005-01-26  Bruno Haible  <bruno@clisp.org>
17187
17188         * m4/javaexec.m4: New file, from GNU gettext.
17189
17190 2005-01-26  Bruno Haible  <bruno@clisp.org>
17191
17192         * lib/javaexec.sh.in: New file, from GNU gettext.
17193         * lib/javaexec.h: New file, from GNU gettext.
17194         * lib/javaexec.c: New file, from GNU gettext.
17195
17196 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17197
17198         * modules/lchown (Depends-on): Remove lchown.h
17199
17200 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17201
17202         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
17203         must be defined if the header file was not found, in order
17204         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
17205
17206 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17207
17208         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
17209         initializers for struct pentry_state.
17210         (__argp_error): Check return value of __asprintf
17211         (__argp_failure): Translate error message
17212
17213         * lib/argp-parse.c: Removed braces around the expansion of N_()
17214
17215 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
17216
17217         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
17218         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
17219         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
17220         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
17221         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
17222         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
17223         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
17224         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
17225         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
17226         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
17227         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
17228         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
17229         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
17230         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
17231         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
17232         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
17233         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
17234         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
17235         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
17236         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
17237         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
17238         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
17239         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
17240         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
17241         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
17242         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
17243         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
17244         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
17245         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
17246         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
17247         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
17248         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
17249         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
17250         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
17251         xstrtol.m4, xstrtoumax.m4, yesno.m4:
17252         Use an all-permissive copyright notice, recommended by RMS.
17253
17254 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
17255
17256         * modules/chdir-long (Depends-on): Remove mempcpy.
17257
17258 2005-01-21  Jim Meyering  <jim@meyering.net>
17259
17260         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
17261         same value as for Solaris 9.
17262
17263         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
17264         component length.  This included changing the parameter to be
17265         of type `char *' rather than `char const *'.
17266         * lib/chdir-long.h (chdir_long): Update prototype.
17267
17268         * lib/openat.c (fdopendir, fstatat): New functions.
17269         * lib/openat.h: Include headers required for use of DIR and struct
17270         stat.
17271         [AT_SYMLINK_NOFOLLOW]: Define.
17272         (fdopendir, fstatat): Add prototypes.
17273
17274 2005-01-21  Bruno Haible  <bruno@clisp.org>
17275
17276         * modules/classpath: New file.
17277         * MODULES.html.sh (Java): Add classpath.
17278
17279 2005-01-21  Bruno Haible  <bruno@clisp.org>
17280
17281         * lib/classpath.h: New file, from GNU gettext.
17282         * lib/classpath.c: New file, from GNU gettext.
17283
17284 2005-01-20  Simon Josefsson  <jas@extundo.com>
17285
17286         * modules/version-etc-fsf: New file.
17287
17288 2005-01-20  Simon Josefsson  <jas@extundo.com>
17289
17290         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
17291         * lib/version-etc.c: Remove version_etc_copyright.
17292         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
17293         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
17294
17295 2005-01-20  Simon Josefsson  <jas@extundo.com>
17296
17297         * lib/base64.h (isbase64): Add.
17298
17299         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
17300         using a unsigned prototype, don't inline.
17301         (base64_decode): Use it.
17302
17303 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17304
17305         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
17306         it.
17307
17308 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17309
17310         * lib/save-cwd.c (save_cwd): Remove code to support the case
17311         where fchdir is missing or flaky.
17312
17313 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17314
17315         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
17316
17317 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
17318
17319         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
17320         AC_LIBSOURCES now does this.
17321         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
17322         with new ullong_max module.
17323
17324 2005-01-19  Bruno Haible  <bruno@clisp.org>
17325
17326         * modules/sh-quote: New file.
17327         * MODULES.html.sh (Executing programs): Add sh-quote.
17328
17329 2005-01-19  Bruno Haible  <bruno@clisp.org>
17330
17331         * lib/sh-quote.h: New file, from GNU gettext.
17332         * lib/sh-quote.c: New file, from GNU gettext.
17333
17334 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17335
17336         Merge from coreutils.
17337         * m4/ullong_max.m4: New file.
17338         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
17339         (gl_MACROS): Assume localeconv exists.
17340
17341 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17342
17343         Merge changes from coreutils, as described below in several
17344         changelogs dated today.
17345
17346         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
17347         (O_DIRECTORY): Remove; not needed here, since "." must be
17348         a directory.  All uses removed.
17349         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
17350         universal on Suns, and we also need to test for IRIX.
17351         Revamp code to use 'if' rather than '#if'.
17352         Avoid unnecessary comparison of cwd->desc to 0.
17353
17354         * lib/utimens.c (futimens): Robustify the previous patch, by checking
17355         for known valid error numbers rather than observed invalid ones.
17356
17357 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17358
17359         * modules/ullong_max: New file.
17360
17361         * modules/chdir-long, modules/openat: New files.
17362         * modules/save-cwd (Depends-on): Depend on chdir-long.
17363         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
17364
17365 2005-01-18  Jim Meyering  <jim@meyering.net>
17366
17367         Merge from coreutils.
17368         * m4/chdir-long.m4, m4/openat.m4: New files.
17369         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
17370         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
17371         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
17372         is sane and DOES follow symlinks.  Besides, testing 20 different
17373         systems found no broken chown implementations.
17374         Prompted by a change in rsync's copy of this macro.
17375         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
17376
17377         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
17378
17379         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
17380         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
17381         NULL-means-set-to-current-time semantics.
17382         Remove temporary file immediately, rather than waiting
17383         for configure's at-exit trap code to do it.
17384
17385 2005-01-18  Jim Meyering  <jim@meyering.net>
17386
17387         * lib/version-etc.c (version_etc_copyright): Update copyright date.
17388
17389         * lib/utimens.c (futimens): Account for the fact that futimes
17390         can also fail with errno == ENOSYS or errno == ENOENT.
17391         Patch from Dmitry V. Levin.
17392
17393         Change the name of the robust chdir function from chdir to chdir_long.
17394         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
17395         (restore_cwd): Use chdir_long, not chdir.
17396         * lib/chdir-long.c: Renamed from chdir.c.
17397         * lib/chdir-long.h: Renamed from chdir.h.
17398         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
17399         Hurd.
17400
17401 2005-01-18  Bruno Haible  <bruno@clisp.org>
17402
17403         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
17404         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
17405         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
17406         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
17407         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
17408         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
17409         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
17410         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
17411         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
17412         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
17413         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
17414         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
17415         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
17416         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
17417         Use an all-permissive copyright notice, recommended by RMS.
17418
17419 2005-01-18  Bob Proulx  <bob@proulx.com>
17420
17421         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
17422         simplify offsetof() macro construct to avoid compile failure with
17423         native HP-UX 11.0 ANSI C compiler.
17424
17425 2005-01-17  Bruno Haible  <bruno@clisp.org>
17426
17427         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
17428         redundant because stpncpy.m4 takes care of it.
17429
17430 2005-01-17  Bruno Haible  <bruno@clisp.org>
17431
17432         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
17433
17434 2005-01-17  Bruno Haible  <bruno@clisp.org>
17435
17436         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
17437         used.
17438
17439 2005-01-17  Bruno Haible  <bruno@clisp.org>
17440
17441         * lib/fwriteerror.h (fwriteerror): Change specification to include
17442         fclose.
17443         * lib/fwriteerror.c: Include <stdbool.h>.
17444         (fwriteerror): At the end, close the file stream. Record whether
17445         stdout was already closed.
17446
17447 2005-01-17  Bruno Haible  <bruno@clisp.org>
17448
17449         * lib/execute.c (environ): Declare if needed.
17450         * lib/pipe.c (environ): Likewise.
17451         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
17452
17453 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17454
17455         * modules/argp: Depend on vsnprintf
17456
17457 2005-01-10  Jim Meyering  <jim@meyering.net>
17458
17459         * modules/closeout (Depends-on): Add atexit.
17460
17461 2005-01-06  Bruno Haible  <bruno@clisp.org>
17462
17463         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
17464
17465 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
17466
17467         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
17468         definitions to be after all include files, to avoid collisions.
17469         Problem reported by Bob Proulx.
17470
17471 2005-01-04  Jim Meyering  <jim@meyering.net>
17472
17473         Changes imported from coreutils.
17474         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
17475         as the mkstemp template, use a temporary directory and an
17476         8.3-friendly template to avoid trouble on systems like DJGPP.
17477         Reported by Juan M. Guerrero via Stepan Kasal.
17478         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
17479         close. Remove the temporary directory right away, rather than waiting
17480         for configure's at-exit trap code to do it.
17481         Suggestion from Stepan Kasal.
17482
17483 2005-01-01  Simon Josefsson  <jas@extundo.com>
17484
17485         * gnulib-tool: Print #include directives when --import'ing.
17486
17487 2004-12-28  Simon Josefsson  <jas@extundo.com>
17488
17489         * tests/test-base64.c: Include required header files.  Remove
17490         unused variables.
17491
17492 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
17493
17494         * modules/error (Depends-on): Remove gettext.
17495
17496 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
17497
17498         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
17499         not needed.  This removes a dependency on the gettext module.
17500         [defined _LIBC]: Do not include <libintl.h>; not needed.
17501
17502 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
17503
17504         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
17505         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
17506
17507 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
17508
17509         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
17510         HAVE_DECL_STRTOLD.
17511
17512 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17513
17514         * modules/getdate (Depends-on): Remove alloca-opt.
17515
17516 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17517
17518         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
17519
17520 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17521
17522         * lib/argp-parse.c: Include <stddef.h>.
17523         (alignof, alignto): New macros.
17524         (parser_init): Don't assume that void * is aligned sufficiently
17525         for struct option.
17526
17527         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
17528         need to extend the stack.
17529         (YYINITDEPTH): New macro, so that the initial stack isn't overly
17530         large.
17531
17532 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17533
17534         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
17535
17536 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
17537
17538         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
17539         (2004-10-24) change.  Apparently this was a false alarm.
17540
17541         * modules/getdate: Depend on alloca-opt, not alloca.
17542
17543 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
17544
17545         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
17546         Remove now-obsolete comment about AIX.
17547         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
17548         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
17549         (YYMAXDEPTH): New macro.
17550
17551 2004-12-18  Simon Josefsson  <jas@extundo.com>
17552
17553         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
17554
17555 2004-12-18  Bruno Haible  <bruno@clisp.org>
17556
17557         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
17558
17559 2004-12-18  Bruno Haible  <bruno@clisp.org>
17560
17561         * lib/fatal-signal.c (fatal_signals): Make non-const.
17562         (init_fatal_signals): New function.
17563         (uninstall_handlers, install_handlers): Ignore signals that were set to
17564         SIG_IGN.
17565         (at_fatal_signal): Call init_fatal_signals.
17566         (init_fatal_signal_set): Likewise. Ignore signals that were set to
17567         SIG_IGN.
17568         Reported by Paul Eggert.
17569
17570 2004-12-18  Bruno Haible  <bruno@clisp.org>
17571
17572         * doc/alloca.texi: New file.
17573         * doc/alloca-opt.texi: New file.
17574
17575 2004-12-17  Jim Meyering  <jim@meyering.net>
17576
17577         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
17578         Otherwise, install-sh could exit with improper exit status when
17579         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
17580
17581 2004-12-16  Simon Josefsson  <jas@extundo.com>
17582
17583         * tests/test-base64.c: Add license.
17584
17585 2004-12-15  Stepan Kasal  <address@hidden>
17586
17587         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
17588
17589 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
17590
17591         * modules/getcwd (Files): Add m4/d-ino.m4.
17592         Suggested by Mark D. Baushke.
17593
17594 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
17595
17596         * lib/getdate.y (textint): New member "negative".
17597         (time_zone_hhmm): New function.
17598         Expect 14 shift-reduce conflicts, not 13.
17599         (o_colon_minutes): New rule.
17600         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
17601         (yylex): Set the "negative" member of signed numbers.
17602
17603 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
17604
17605         * doc/getdate.texi (Time of day items, Time zone items):
17606         Describe new formats +00:00, UTC+00:00.
17607
17608 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
17609
17610         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
17611         spurious "-l"s.  Problem reported by Stepan Kasal.
17612
17613 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
17614
17615         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
17616         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
17617
17618 2004-12-04  Simon Josefsson  <jas@extundo.com>
17619
17620         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
17621         Vandoorselaere <yoann@prelude-ids.org>.
17622
17623 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17624
17625         Changes imported from coreutils.
17626         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
17627         exist.
17628         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
17629
17630 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17631
17632         Changes imported from coreutils.
17633         * lib/hard-locale.c: Assume <locale.h> exists.
17634         Include "strdup.h".
17635         (GLIBC_VERSION): New macro.
17636         (hard_locale): Assume setlocale exists.
17637         Rewrite to avoid #ifdef.
17638         Use strdup rather than malloc + strcpy.
17639         * lib/human.c: Assume <locale.h> exists.
17640         (human_readable): Assume localeconv exists.
17641
17642 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
17643
17644         * modules/hard-locale (Depends-on): Add strdup.
17645
17646 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
17647
17648         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
17649         convert T2, not T.  (Imported from libc.)
17650
17651 2004-11-30  Simon Josefsson  <jas@extundo.com>
17652
17653         * modules/restrict (License): Change to LGPL.
17654
17655 2004-11-30  Simon Josefsson  <jas@extundo.com>
17656
17657         * m4/restrict.m4: Add copyright and copying conditions.
17658
17659 2004-11-30  Simon Josefsson  <jas@extundo.com>
17660
17661         * m4/base64.m4: New file.
17662
17663 2004-11-30  Simon Josefsson  <jas@extundo.com>
17664
17665         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
17666         base64.
17667
17668         * tests/test-base64.c: New file.
17669
17670         * modules/base64: New file.
17671
17672 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
17673
17674         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
17675         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
17676
17677         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
17678
17679 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
17680
17681         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
17682         (__getcwd.c): Don't restore errno; glibc doesn't.
17683         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
17684         first, falling back to our code only if its results look suspicious.
17685         Ensure that the resulting buffer is only as large as necessary.
17686
17687         * lib/readutmp.c: Include readutmp.h first.
17688         Include <errno.h>, since readutmp.h no longer does that.
17689         * lib/readutmp.h: Don't include <errno.h>,
17690         <sys/param.h>, <time.h>; not needed to establish interface.
17691         (errno): Remove decl.
17692         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
17693         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
17694         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
17695
17696 2004-11-28  Simon Josefsson  <jas@extundo.com>
17697
17698         * lib/base64.h, base64.c: New file.
17699
17700 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
17701
17702         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
17703
17704 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
17705
17706         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
17707         (Depends-on): Remove pathmax, same.  Add mempcpy.
17708         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
17709         (Makefile.am): Append getcwd.h to lib_SOURCES.
17710         (Include): Add getcwd.h.
17711         (Maintainer): Change from Jim Meyering to "all, glibc",
17712         since getdate now uses intended-for-glibc code.
17713         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
17714         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
17715
17716 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
17717
17718         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
17719         HP's ANSI C compiler.
17720         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
17721         Declaring int functions causes warnings on some modern systems and
17722         shouldn't be needed to compile on ancient ones.
17723         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
17724         defined.
17725
17726         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
17727         with the following changes.
17728         (__set_errno): Parenthesize properly.
17729         Include <stdbool.h>.
17730         (MIN, MAX, MATCHING_INO): New macros.
17731         (__getcwd): Define with prototype, not K&R form.
17732         Use heuristics to allocate default buffer on stack if possible.
17733         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
17734         behavior, and to avoid the PATH_MAX limit when computing
17735         ../../../../...
17736         Use MATCHING_INO to compare inode number to file.
17737         Check for arithmetic overflow in size calculations.
17738         Fix bug in reallocation of dot array that caused getcwd to fail
17739         on directories nested deeper than 75.
17740         Be more careful about saving errno on error.
17741         Do not use realloc; use only free+malloc, as this is a bit
17742         more flexible and avoids a needless copy operation.
17743         Do not inspect st_dev and st_ino for symbolic links; POSIX
17744         doesn't specify the latter.
17745         Check for closedir errors.
17746         Avoid needless casts.
17747         Use "#ifdef weak_alias" around weak_alias, to be like other
17748         glibc code.
17749         The following changes to getcwd.c have effect only when used in
17750         gnulib; they have no effect inside glibc proper.
17751         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
17752         as alloca isn't used.
17753         (alloca, __alloca): Likewise.
17754         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
17755         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
17756         unconditionally, as gnulib assumes C89 or better.
17757         Do not include <sys/param.h>.
17758         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
17759         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
17760         better.
17761         (NULL) [!defined NULL]: Remove; we assume C89 or better.
17762         Include <dirent.h> in a way that is compatible with modern Autoconf.
17763         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
17764         New macros, if not already defined.
17765         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
17766         Use "_LIBC", not "defined _LIBC", for consistency.
17767         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
17768         a mempcpy module.
17769         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
17770         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
17771         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
17772         credit only to Jim Meyering and adjust the copyright dates.
17773         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
17774         <stdlib.h>, <unistd.h>, "pathmax.h".
17775         Instead, include "xgetcwd.h" (first) and "getcwd.h".
17776         (INITIAL_BUFFER_SIZE): Remove.
17777         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
17778
17779 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
17780
17781         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
17782         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
17783         Use the _ONCE methods, for efficiency.
17784         Check for fcntl.h.  In test program, include <errno.h>
17785         and <fcntl.h> if available.  Remove old K&R cruft from
17786         test program.  Check for common errors in GNU/Linux,
17787         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
17788         don't do AC_LIBOBJ, as that's getcwd.m4's job.
17789         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
17790         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
17791         name accordingly.
17792         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
17793         accommodate new getcwd.c.
17794         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
17795         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
17796         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
17797         that's all we need now.
17798
17799 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17800
17801         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
17802         argp-parse.c depends on getopt internals, that means we should
17803         always use our getopt, to be on the safe side.
17804         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
17805         order not to spoil the result of an eventual previous invocation
17806         of gl_GETOPT_SUBSTITUTE.
17807
17808 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17809
17810         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
17811         redefinition warnings. To avoid them, include the defines
17812         in `#if !defined __need_getopt ... #endif'. The only place
17813         where __getopt_argv_const is used is in definitions
17814         of getopt_long and getopt_long_only below, which are as well
17815         protected by `#ifndef __need_getopt'.
17816         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
17817         __need_getopt after including <stdio.h> and <unistd.h> These
17818         headers might have defined it.
17819
17820 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
17821
17822         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
17823
17824 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
17825
17826         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
17827         (futimens): New function, which uses futimes if available.
17828         (futimens, utimens): Support timespec==NULL, with same semantics
17829         as utime and utimens.
17830         * lib/utimens.h (futimens): New decl.
17831
17832 2004-11-23  Jim Meyering  <jim@meyering.net>
17833
17834         * lib/getopt_.h: Remove trailing blanks.
17835
17836 2004-11-23  Jim Meyering  <jim@meyering.net>
17837
17838         * lib/__fpending.c: Add comment.
17839
17840 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
17841
17842         * modules/canonicalize (Depends-on): Add xreadlink.
17843         Problem reported by James Youngman.
17844
17845 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
17846
17847         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
17848         New macros.
17849         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
17850         optopt): Use them instead of invoking ## directly; otherwise, the
17851         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
17852
17853 2004-11-19  Bruno Haible  <bruno@clisp.org>
17854
17855         * lib/strtok_r.c: Move comments from here...
17856         * lib/strtok_r.h: ... to here.
17857
17858 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
17859
17860         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
17861         implementations that mishandle size_t overflow.
17862
17863 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
17864
17865         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
17866         might fail.  Problem reported by Yoann Vandoorselaere.
17867         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
17868         implementations that mishandle size_t overflow.
17869
17870 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17871
17872         * modules/canon-host (Depends-on): Add strdup.
17873
17874 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17875
17876         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
17877
17878 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17879
17880         * lib/canon-host.c: Include "strdup.h".
17881         (canon_host): Use getaddrinfo if available, so that IPv6 works.
17882         Use strdup instead of malloc/strcpy to duplicate strings.
17883
17884         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
17885         (human_space_before_unit): New constant.
17886         * lib/human.c (human_readable): Support it.
17887
17888         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
17889         (xgetcwd): Set errno correctly when failing.
17890         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
17891         the failure is actually due to a PATH_MAX problem.
17892
17893         Further getopt changes to make it more likely that glibc will
17894         buy the changes back.
17895         * lib/getopt.c (POSIXLY_CORRECT): New constant.
17896         (getopt): Use it, so to preserve glibc semantic
17897         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
17898         when compiling for libc.
17899         * lib/getopt_.h (__getopt_argv_const): Bring it back.
17900         (getopt_long, getopt_long_only): Use it.
17901
17902         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
17903         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
17904         (getopt): Argv is now char * const *, as per standard.
17905         (_getopt_internal_r, _getopt_internal): Argv is now char **,
17906         not char *__getopt_argv_const *.
17907         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
17908         _getopt_long_only_r): Likewise.
17909         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
17910         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
17911         _getopt_long_r, _getopt_long_only_r): Likewise.
17912         * lib/getopt_.h (__getopt_argv_const): Remove.
17913         (getopt): Argv is now char * const *, as per standard.
17914
17915         * lib/getdate.y (tORDINAL): New token.
17916         (day, relunit): Allow it for relative times.
17917         (relative_time_table): Use tORDINAL for ordinals.
17918
17919 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
17920
17921         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
17922         Document that "second" isn't allowed as an ordinal number.
17923
17924 2004-11-16  Jim Meyering  <jim@meyering.net>
17925
17926         * modules/closeout (Depends-on): Add fpending.
17927
17928 2004-11-15  Jim Meyering  <jim@meyering.net>
17929
17930         * lib/closeout.c: Include "__fpending.h" once again.
17931         Include <stdbool.h>.
17932         (close_stdout): Don't fail just because stdout was closed initially,
17933         since some programs don't write to stdout in the normal course of
17934         operation (other than --version and --help), and we don't want this
17935         function to make e.g. `touch file >&-' fail.
17936         But do fail if it was closed and someone has tried to write to it.
17937         E.g., `printf foo >&-' must fail.
17938
17939 2004-11-13  Jim Meyering  <jim@meyering.net>
17940
17941         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
17942
17943 2004-11-12  Simon Josefsson  <jas@extundo.com>
17944
17945         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
17946         small doc fix is still pending.
17947
17948 2004-11-11  Simon Josefsson  <jas@extundo.com>
17949
17950         * modules/strtok_r: New file.
17951
17952         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
17953         strtok_r.
17954
17955 2004-11-11  Simon Josefsson  <jas@extundo.com>
17956
17957         * m4/strtok_r.m4: New file.
17958
17959         * m4/getopt.m4: Replace opterr.
17960
17961 2004-11-11  Simon Josefsson  <jas@extundo.com>
17962
17963         * lib/strtok_r.h, strtok_r.c: New file.
17964
17965 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
17966
17967         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
17968         of replacing opterr, getopt, etc.  This should handle the
17969         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
17970
17971 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
17972
17973         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
17974         we can stop lying to compilers about the constness of argv when we
17975         are compiled outside glibc.
17976         (getopt, getopt_long, getopt_long_only): Use it.
17977         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
17978         _getopt_internal, getopt): Likewise.
17979         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
17980         _getopt_long_only_r): Likewise.
17981         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
17982         _getopt_long_r, _getopt_long_only_r): Likewise.
17983
17984         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
17985         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
17986         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
17987         the other external symbols.
17988         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
17989         declaration, since the above renaming now works around collisions.
17990
17991 2004-11-11  Jim Meyering  <jim@meyering.net>
17992
17993         * lib/linebreak.c: Remove trailing blanks.
17994         * lib/alloca_.h: Likewise.
17995         * lib/acosl.c: Likewise.
17996         * lib/euidaccess.c: Likewise.
17997         * lib/allocsa.h: Likewise.
17998
17999 2004-11-10  Simon Josefsson  <jas@extundo.com>
18000
18001         * m4/getaddrinfo.m4: New file.
18002
18003 2004-11-10  Simon Josefsson  <jas@extundo.com>
18004
18005         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
18006
18007 2004-11-10  Simon Josefsson  <jas@extundo.com>
18008
18009         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18010         getaddrinfo.
18011
18012         * modules/getaddrinfo: New file.
18013
18014 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18015
18016         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
18017
18018 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18019
18020         * lib/mktime.c (SHR): New macro, which is a portable
18021         substitute for >> that should work even on Crays.
18022         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
18023         Problem reported by Mark D. Baushke in
18024         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
18025         * lib/getdate.y (SHR): Likewise.
18026         (tm_diff): Use it.
18027         * lib/strftime.c (SHR): Likewise.
18028         (tm_diff): Use it.
18029         * lib/quotearg.c (struct quoting_options): Use unsigned int for
18030         quote_these_too, so that right shifts are well defined.  All uses
18031         changed.
18032
18033 2004-11-10  Jim Meyering  <jim@meyering.net>
18034
18035         Ensure that no close failure goes unreported.
18036         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
18037         return early when it seems there's nothing to flush.
18038         Don't include __fpending.h.
18039
18040 2004-11-10  Jim Meyering  <jim@meyering.net>
18041
18042         * modules/closeout (Depends-on): Remove fpending.
18043
18044 2004-11-10  Jim Meyering  <jim@meyering.net>
18045
18046         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
18047
18048 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18049
18050         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
18051         gl_FUNC_STRFTIME.
18052         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
18053         and AC_REQUIRE when possible, to avoid duplicate checks.
18054         Check for <wchar.h>.
18055
18056 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18057
18058         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
18059
18060 2004-11-09  Bruno Haible  <bruno@clisp.org>
18061
18062         * m4/sockpfaf.m4: New file.
18063
18064 2004-11-05  Bruno Haible  <bruno@clisp.org>
18065
18066         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
18067         Reported by Mark D. Baushke <mdb@cvshome.org>.
18068
18069 2004-11-04  Bruno Haible  <bruno@clisp.org>
18070
18071         2004-09-11  Bruno Haible  <bruno@clisp.org>
18072                 * allocsa.valgrind: New file.
18073         2004-02-06  Bruno Haible  <bruno@clisp.org>
18074                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
18075                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
18076                 Reported by Christopher Seip <chris.seip@hp.com>.
18077
18078 2004-11-04  Bruno Haible  <bruno@clisp.org>
18079
18080         * modules/allocsa (Files): Add lib/allocsa.valgrind.
18081         (Makefile.am): Distribute it.
18082
18083 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
18084
18085         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
18086         with errno == ERANGE if the buffer is too small.
18087         Problem reported by Mark D. Baushke.
18088
18089 2004-11-03  Albert Chin  <china@thewrittenword.com>
18090             Paul Eggert  <eggert@cs.ucla.edu>
18091
18092         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
18093         equivalent, substitute $ac_type for equivalent type rather than
18094         blindly using uint32_t *always* which won't work if uint32_t is not
18095         available.  Define _UINT32_T to work around typedef of uint32_t if
18096         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
18097         2.5.1.
18098
18099 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18100
18101         * m4/jm-macros.m4: Sync from coreutils.
18102         (gl_MACROS): Check for mbrlen, for pathchk.
18103         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
18104
18105 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18106
18107         * lib/xreadlink.c (MAXSIZE): New macro.
18108         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
18109         size does not exceed MAXSIZE.  Avoid cast.
18110         As suggested by Mark D. Baushke in
18111         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
18112         if readlink fails with buffer size just under MAXSIZE, try again
18113         with MAXSIZE.
18114
18115 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18116
18117         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
18118
18119 2004-11-02  Derek R. Price  <derek@ximbiot.com>
18120         and  Paul Eggert  <eggert@cs.ucla.edu>
18121
18122         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
18123         (get_date): Overparenthesize to avoid GCC warning.
18124
18125 2004-11-02  Bruno Haible  <bruno@clisp.org>
18126
18127         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
18128         returns void.
18129
18130 2004-11-02  Bruno Haible  <bruno@clisp.org>
18131
18132         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
18133         function returns void.
18134
18135 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18136
18137         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
18138         fflush_unlocked, flockfile, funlockfile, funlockfile,
18139         fputs_unlocked, putc_unlocked.
18140
18141 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18142
18143         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
18144         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
18145         already declared.
18146
18147 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18148
18149         * modules/getdate (Files): Add doc/getdate.texi.
18150         (Depends-on): Add setenv, xalloc.
18151
18152 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18153
18154         * lib/getdate.y: Add support for TZ="foo" within a date string.
18155         Fix some bugs near time_t boundaries.  Reject dates with
18156         out-of-range components, e.g., "Sept 31".
18157         Include <stdlib.h>, "setenv.h", "xalloc.h".
18158         (ISDIGIT_LOCALE): Remove; unused.
18159         Note that the TZ and time functions used here are not reentrant.
18160         (mktime_ok, get_tz): New functions.
18161         (TZBUFSIZE): New constant.
18162         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
18163         This requires that we sometimes generate our own TZ="XXX..." setting.
18164
18165 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18166
18167         * doc/getdate.texi: New file, from coreutils with modifications for
18168         the new TZ parsing.
18169
18170 2004-10-27  Derek R. Price  <derek@ximbiot.com>
18171
18172         * lib/mktime.c (not_equal_tm): Remove redundant check.
18173
18174 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18175
18176         * modules/regex (lib_SOURCES): Add regex.c.
18177         Reported by James Youngman in
18178         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
18179
18180 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18181
18182         * lib/getdate.y: Use Bison 1.875 features, and some minor
18183         code cleanups.  This change does not affect semantics.
18184         Don't include <stdlib.h>; no longer needed.
18185         Don't include unlocked-io.h; only the "#if TEST" code uses
18186         stdio, and performance isn't crucial there.
18187         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
18188         Bison 1.875 features as described below.
18189         All uses of "PC." replaced by "pc->".
18190         (YYSTYPE): Add a forward declaration.
18191         (yylex, yyerror): Use full prototypes in forward decls.
18192         Use "%pure-parser" rather than obsolescent "%pure_parser".
18193         Use %parse-param and %lex-param instead of obsolescent
18194         YYPARSE_PARAM and YYLEX_PARAM.
18195         (meridian_table, month_and_day_table, time_units_table,
18196         relative_time_table, time_zone_table, military_table,
18197         lookup_zone, lookup_word, get_date):
18198         Use NULL instead of 0 where appropriate.
18199         (to_hour): Avoid abort (), to avoid a dependency on
18200         stdlib.h.
18201         (yyerror, yylex): Now accepts parser_control * arg.
18202         (main) [TEST]: Use '\0' rather than 0 for char.
18203
18204 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
18205
18206         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
18207
18208 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
18209
18210         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
18211         It's now the caller's responsibility to handle the case where
18212         !HAVE_GETPAGESIZE && !defined getpagesize.
18213
18214         * lib/mktime.c (leapyear): Arg is long int, not int.
18215
18216 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
18217
18218         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
18219
18220 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
18221
18222         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
18223         missing.  Problem reported by James Youngman.
18224
18225 2004-10-16  Simon Josefsson  <jas@extundo.com>
18226
18227         * gnulib-tool: Fix comments.  Fix parse problem.
18228         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
18229
18230 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
18231
18232         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
18233         implementation of getopt_long.  Problem reported by Alexander Taler in:
18234         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
18235
18236 2004-10-15  Bruno Haible  <bruno@clisp.org>
18237
18238         * gnulib-tool: Untabify. Initialize supplied_libname.
18239         (func_usage): More homogenous output.
18240         (func_modules_transitive_closure, func_modules_to_filelist,
18241         func_emit_lib_Makefile_am): New functions.
18242         (func_import): New function, extracted from big case statement. Use
18243         func_get_license, func_modules_transitive_closure,
18244         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
18245         opt_lgpl. Don't use test -a, as it's not portable.
18246         (func_create_testdir): Use func_modules_transitive_closure,
18247         func_modules_to_filelist, func_emit_lib_Makefile_am.
18248
18249 2004-10-15  Bruno Haible  <bruno@clisp.org>
18250
18251         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
18252
18253 2004-10-15  Bruno Haible  <bruno@clisp.org>
18254
18255         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
18256         the portions belonging to each module.
18257         Suggested by Derek Robert Price <derek@ximbiot.com>.
18258
18259 2004-10-12  Simon Josefsson  <jas@extundo.com>
18260
18261         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
18262         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
18263         to real functions.
18264
18265 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18266
18267         * modules/vsnprintf: New file.
18268
18269 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18270
18271         * m4/vsnprintf.m4: New file.
18272
18273 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18274
18275         * lib/vsnprintf.h: New file.
18276         * lib/vsnprintf.c: New file.
18277
18278 2004-10-11  Bruno Haible  <bruno@clisp.org>
18279
18280         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
18281         vsnprintf.
18282
18283 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
18284
18285         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
18286
18287 2004-10-07  Bruno Haible  <bruno@clisp.org>
18288
18289         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
18290         fits into the provided buffer.
18291
18292 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
18293
18294         * lib/diacrit.c, diacrit.h: Add GPL notice.
18295
18296         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
18297         notice.
18298         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
18299         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
18300         This avoids a potential constant-folding bug.
18301
18302 2004-10-05  Bruno Haible  <bruno@clisp.org>
18303
18304         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
18305         for the declaration of strsep.
18306
18307 2004-10-05  Bruno Haible  <bruno@clisp.org>
18308
18309         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
18310
18311 2004-10-04  Simon Josefsson  <jas@extundo.com>
18312
18313         * modules/memmem: New file.
18314         * tests/test-memmem.c: New file.
18315         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
18316
18317 2004-10-04  Simon Josefsson  <jas@extundo.com>
18318
18319         * m4/memmem.m4: New file.
18320
18321 2004-10-04  Simon Josefsson  <jas@extundo.com>
18322
18323         * lib/memmem.h: New file.
18324         * lib/memmem.c: New file, taken from glibc.
18325
18326 2004-10-04  Simon Josefsson  <jas@extundo.com>
18327
18328         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
18329         '#ifdef USE_UNLOCKED_IO'.
18330
18331 2004-10-04  Simon Josefsson  <jas@extundo.com>
18332
18333         * config/srclist.txt: Add memmem from glibc.
18334
18335 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18336
18337         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
18338
18339         * modules/argmatch, modules/argp, modules/closeout, modules/error,
18340         modules/exclude, modules/getdate, modules/getline,
18341         modules/getndelim2, modules/getpass, modules/getpass-gnu,
18342         modules/getusershell, modules/linebuffer, modules/md5,
18343         modules/mountlist, modules/posixtm, modules/readtokens,
18344         modules/readutmp, modules/regex, modules/sha1,
18345         modules/version-etc, modules/yesno:
18346         Remove dependency on unlocked-io.
18347
18348 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18349
18350         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
18351
18352         * m4/unlocked-io.m4: Add copyright notice.
18353         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
18354
18355 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18356
18357         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
18358         * lib/xmalloc.c (xmemdup): Likewise.
18359         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
18360         XFREE): Remove these long-obsolescent macros.
18361         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
18362         * lib/xstrdup.c: Remove.
18363
18364         * lib/regex.c (re_comp): Cast gettext return value to char *,
18365         Problem reported by Martin Neitzel via Mark D. Baushke.
18366
18367 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18368
18369         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
18370         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
18371         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
18372         regex.c, sha1.c, version-etc.c, yesno.c:
18373         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
18374         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
18375         the includer's responsibility.
18376
18377         Sync from coreutils.
18378
18379         * lib/modechange.c (mode_compile): Don't decrement a pointer that
18380         points to the start of a string, as the C Standard says the
18381         resulting behavior is undefined.
18382
18383         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
18384         simple -> simple_backups, numbered_existing ->
18385         numbered_existing_backups, numbered -> numbered_backups
18386         to avoid shadowing problems.  All uses changed.
18387         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
18388         * lib/backupfile.c (check_extension, numbered_backup):
18389         Rename locals to avoid shadowing 'basename'.
18390         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
18391         once.
18392
18393         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
18394         * lib/.cvsignore: Add getopt.h.
18395
18396 2004-10-04  Bruno Haible  <bruno@clisp.org>
18397
18398         * modules/README: New file.
18399         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
18400         not a module.
18401
18402 2004-10-02  Jim Meyering  <jim@meyering.net>
18403
18404         * lib/dirfd.h, getpagesize.h: Add copyright notice.
18405
18406 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18407
18408         * modules/strsep: New file.
18409
18410 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18411
18412         * m4/strsep.m4: New file.
18413
18414 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18415
18416         * lib/strsep.h: New file.
18417         * lib/strsep.c: New file.
18418
18419 2004-10-01  Simon Josefsson  <jas@extundo.com>
18420
18421         * lib/snprintf.c (snprintf): Handle size==0.
18422
18423 2004-10-01  Simon Josefsson  <jas@extundo.com>
18424             Bruno Haible  <bruno@clisp.org>
18425
18426         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
18427         (snprintf): Declare 'args'.
18428
18429 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
18430
18431         * lib/snprintf.c: Remove comments as to why each header is needed.
18432
18433 2004-10-01  Bruno Haible  <bruno@clisp.org>
18434
18435         * MODULES.html.sh: Add strsep.
18436
18437 2004-09-30  Simon Josefsson  <jas@extundo.com>
18438
18439         * modules/snprintf: New file.
18440
18441 2004-09-30  Simon Josefsson  <jas@extundo.com>
18442
18443         * m4/snprintf.m4: New file.
18444
18445 2004-09-30  Simon Josefsson  <jas@extundo.com>
18446
18447         * lib/snprintf.h, lib/snprintf.c: New files.
18448
18449 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18450
18451         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
18452         (hol_entry_help): Never translate an empty string.
18453         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
18454         * lib/argp.h (OPTION_NO_TRANS): New option.
18455
18456 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
18457
18458         * modules/argp (Maintainer): Replace Simon Josefsson
18459         by Sergey Poznyakoff.
18460
18461 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
18462
18463         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
18464         changes merged back into glibc.
18465
18466 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
18467
18468         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
18469
18470 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
18471
18472         * lib/xvasprintf.c: Include xalloc.h.
18473         (xvasprintf): Use xalloc_die, not xmalloc_die.
18474
18475 2004-09-29  Bruno Haible  <bruno@clisp.org>
18476
18477         * modules/alloca-opt: New file, derived from modules/alloca.
18478         * modules/allocsa: Depend on alloca-opt instead of alloca.
18479         * modules/setenv: Likewise.
18480         * modules/vasnprintf: Likewise.
18481         * MODULES.html.sh: Add alloca-opt.
18482
18483 2004-09-28  Simon Josefsson  <jas@extundo.com>
18484
18485         * gnulib-tool: New parameter --lgpl, to asseert that modules are
18486         LGPL, and to replace license template from GPL to LGPL.
18487
18488 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
18489
18490         * modules/dummy: Change license to LGPL.
18491
18492 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
18493
18494         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
18495
18496 2004-09-24  Simon Josefsson  <jas@extundo.com>
18497
18498         * modules/minmax (License): Change from GPL to LGPL.
18499
18500 2004-09-23  Simon Josefsson  <jas@extundo.com>
18501
18502         * gnulib-tool (--import): Typo.
18503
18504 2004-09-23  Simon Josefsson  <jas@extundo.com>
18505
18506         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
18507
18508 2004-09-22  Bruno Haible  <bruno@clisp.org>
18509
18510         * modules/*: Add 'License' field.
18511         * gnulib-tool: Accept --extract-license option.
18512         (func_get_license): New function.
18513
18514 2004-09-21  Bruno Haible  <bruno@clisp.org>
18515
18516         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
18517         Reported by Simon Josefsson.
18518
18519 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
18520
18521         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
18522         gl_AC_TYPE_LONG_LONG.
18523
18524 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
18525
18526         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
18527
18528 2004-09-18  Simon Josefsson  <jas@extundo.com>
18529         and  Paul Eggert  <eggert@cs.ucla.edu>
18530
18531         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
18532         calls with autoreconf.  Define GL_LIB.
18533
18534 2004-09-14  Karl Berry  <karl@gnu.org>
18535
18536         * config/srclist.txt: unsync setenv.c, sigh.
18537
18538 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
18539
18540         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
18541         Problem reported by Bruno Haible in:
18542         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
18543
18544 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
18545
18546         * config/srclist.txt: Comment out argp-pvh.c.
18547
18548 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
18549
18550         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
18551         in case some system header has #define'd it.  Problem reported by
18552         Soeren D. Schulze in
18553         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
18554
18555 2004-09-09  Karl Berry  <karl@gnu.org>
18556
18557         * regex.[ch]: delete from the root.  These were supposed to be
18558                 synced with emacs cvs, but this has not happened for about
18559                 a year, and anyway nothing else uses emacs regex.[ch].
18560                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
18561                 lib/regex[.ch] is untouched.
18562
18563 2004-09-09  Bruno Haible  <bruno@clisp.org>
18564
18565         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
18566
18567 2004-09-09  Bruno Haible  <bruno@clisp.org>
18568
18569         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
18570         modifications.
18571         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
18572
18573 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
18574
18575         * modules/xvasprintf: New file.
18576         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
18577
18578 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
18579
18580         * lib/xvasprintf.h: New file.
18581         * lib/xvasprintf.c: New file.
18582         * lib/xasprintf.c: New file.
18583
18584 2004-09-08  Bruno Haible  <bruno@clisp.org>
18585
18586         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
18587
18588 2004-09-08  Bruno Haible  <bruno@clisp.org>
18589
18590         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
18591         length is > INT_MAX.
18592         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
18593         more.
18594
18595 2004-09-08  Bruno Haible  <bruno@clisp.org>
18596
18597         * lib/stdint_.h: New file, taken from GNU clisp.
18598
18599 2004-09-08  Bruno Haible  <bruno@clisp.org>
18600             Oskar Liljeblad  <oskar@osk.mine.nu>
18601
18602         * modules/stdint: New file.
18603         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
18604
18605 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18606
18607         Import from coreutils.
18608         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
18609         strings on unbounded length.  alloca's performance benefits aren't
18610         that important here.
18611         (V_STRDUP): Remove.
18612         (parse_with_separator): New function, with most of the internals
18613         of the old parse_user_spec.  Allow user to omit both user and group,
18614         for compatibility with FreeBSD.
18615         Clone only the user name, not the entire spec.
18616         Do not set *uid, *gid unless entirely successful.
18617         Avoid memory leak in some failing cases.
18618         Fix regression for USER.GROUP reported by Dmitry V. Levin in
18619         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
18620         (parse_user_spec): Rewrite to use parse_with_separator.
18621
18622 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18623
18624         * modules/userspec: Don't depend on alloca.
18625
18626 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18627
18628         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
18629
18630 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18631
18632         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
18633         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
18634         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
18635
18636 2004-08-16  Simon Josefsson  <jas@extundo.com>
18637
18638         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
18639         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
18640         Add --dry-run for --import.
18641         Let user provided command line parameters override configure.ac
18642         settings.
18643
18644 2004-08-12  Simon Josefsson  <jas@extundo.com>
18645
18646         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
18647         as discussed with Paul Eggert in threads rooted at
18648         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
18649         and
18650         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
18651         Before, the test was empty, and relied on ELIDE_CODE in source
18652         code.)
18653         (gl_PREREQ_GETOPT): New macro.
18654         (gl_GETOPT): Use them.
18655
18656 2004-08-12  Simon Josefsson  <jas@extundo.com>
18657
18658         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
18659         * lib/getopt_.h: Renamed from getopt.h.
18660
18661 2004-08-12  Simon Josefsson  <jas@extundo.com>
18662
18663         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
18664         Change default library name from libfoo to libgnu.
18665         Now, if you have a configure.ac that says:
18666                 gl_SOURCE_BASE(gl)
18667                 gl_M4_BASE(gl/m4)
18668                 gl_MODULES(error getopt etcetera)
18669                 gl_INIT
18670         you can import all you need by running:
18671                 ../gnulib/gnulib-tool --import
18672
18673         * modules/getopt (Files): Rename getopt.h to getopt_.h.
18674         (Makefile.am): Rewrite, use logic from argz.
18675         (Include): Use <getopt.h> instead of "getopt.h".
18676
18677 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18678
18679         * modules/argp (Files): Add m4/unlocked-io.m4.
18680         (Depends-on): Add extensions.
18681
18682 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18683
18684         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
18685         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
18686         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
18687         Check for program_invocation_name, program_invocation_short_name,
18688         flockfile, funlockfile, features.h, _getopt_long_only_r.
18689
18690 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18691
18692         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
18693         its complicated substitute.
18694         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
18695         and program_invocation_name.
18696         (__argp_basename) [!_LIBC]: Remove; the only use was
18697         replaced by its body.
18698         (__argp_short_program_name): Change condition from
18699         !defined __argp_short_program_name to
18700         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
18701         to match argp-namefrob.h.
18702         (__argp_failure): Don't assume strerror_r returns char *.
18703         * lib/argp-parse.c (N_): Define unconditionally.
18704         (argp_default_options): Fill out initializers with 0 to avoid
18705         gcc warnings.
18706
18707 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
18708
18709         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
18710         getopt1.c.
18711
18712 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18713
18714         Merge from coreutils.
18715
18716         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
18717
18718         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
18719         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
18720
18721 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18722
18723         Merge from coreutils.
18724
18725         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
18726         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
18727         for Reliant Unix 5.43.
18728
18729         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
18730         (union fooround): Use uintmax_t, not long int.
18731         The rest is a merge from libc:
18732         [defined _LIBC]: Include <shlib-compat.h>.
18733         (_obstack) [defined _LIBC]: Remove after 2.3.4.
18734
18735         * lib/settime.c (settime): Recode to avoid warning with
18736         Sun Forte C 6U2.
18737
18738         * lib/strverscmp.c: Convert to UTF-8.
18739
18740 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
18741
18742         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
18743         m4/uintmax_t.m4.
18744
18745 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18746
18747         * modules/xalloc-die: New file.
18748         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
18749
18750         * modules/md5 (Files): Add m4/uint32_t.m4.
18751         * modules/sha1: Renamed from modules/sha.
18752         (Files):
18753         Rename lib/sha.h to lib/sha1.h.
18754         Rename lib/sha.c to lib/sha1.c.
18755         Rename m4/sha.m4 to m4/sha1.m4.
18756         (lib_SOURCES): Likewise.
18757         (configure.ac): Rename gl_SHA to gl_SHA1.
18758         (Include): sha.h -> sha1.h.
18759
18760 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18761
18762         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
18763         * m4/sha1.m4: Renamed from sha.m4.
18764         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
18765
18766 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18767
18768         * lib/obstack.h (obstack_empty_p):
18769         Don't assume that chunk->contents is suitably aligned.
18770         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
18771         Likewise. Problem reported by Benno in
18772         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
18773
18774         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
18775         readable.  This could be improved further but it'd take some work.
18776
18777 2004-08-08  Simon Josefsson  <jas@extundo.com>
18778
18779         * modules/xgethostname (Depends-on): Remove exit and error (not
18780         used).
18781
18782         * modules/getpass-gnu: Add getpass.h.
18783         (Depends-on): Add stdbool.
18784         * modules/getpass: Add getpass.h.
18785
18786 2004-08-08  Simon Josefsson  <jas@extundo.com>
18787
18788         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
18789         Check getpass declaration.
18790
18791 2004-08-08  Simon Josefsson  <jas@extundo.com>
18792
18793         * lib/xgethostname.c: Don't include error.h (not used).
18794
18795         * lib/getpass.h: Add.
18796         * lib/getpass.c: Include getpass.h first.
18797
18798 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
18799
18800         * lib/xalloc-die.c: New file.
18801         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
18802         All uses removed.
18803         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
18804         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
18805         xalloc-die.c.
18806         (_, N_, xalloc_die): Move to xalloc-die.c.
18807         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
18808         so that we needn't mess with xalloc_msg_memory_exhausted.
18809
18810         * lib/sha1.h: Renamed from sha.h.
18811         (SHA1_H): Renamed from _SHA_H.
18812         (sha1_ctx): Renamed from sha_ctx.
18813         (sha1_init_ctx): Renamed from sha_init_ctx.
18814         (sha1_process_block): Renamed from sha_process_block.
18815         (sha1_process_bytes): Renamed from sha_process_bytes.
18816         (sha1_finish_ctx): Renamed from sha_finish_ctx.
18817         (sha1_read_ctx): Renamed from sha_read_ctx.
18818         (sha1_stream): Renamed from sha_stream.
18819         (sha1_buffer): Renamed from sha_buffer.
18820         * lib/sha1.c: Likewise; renamed from sha.c.
18821         Do not include <sys/types.h>.
18822         Include <stddef.h> rather than <stdlib.h>.
18823
18824 2004-08-08  Bruno Haible  <bruno@clisp.org>
18825
18826         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
18827         FILESYSTEM_PREFIX_LEN.
18828         * lib/progreloc.c: Likewise.
18829         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
18830
18831 2004-08-06  Simon Josefsson  <jas@extundo.com>
18832
18833         * modules/progname (Depends-on): Don't depend on stdbool.
18834
18835 2004-08-06  Simon Josefsson  <jas@extundo.com>
18836
18837         * modules/getsubopt: New file.
18838         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18839         getsubopt.
18840
18841 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18842
18843         More merge from coreutils.
18844
18845         * m4/utimens.m4, m4/utimecmp.m4: New files.
18846         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
18847         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
18848         prereq.m4, sha.m4: Import changes from coreutils.
18849
18850 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18851
18852         More merge from coreutils.
18853         * modules/raise, modules/readtokens0, modules/utimens:
18854         * modules/utimecmp, module/xnanosleep: New files.
18855         * modules/strftime: Add lib/strftime.h.
18856         Change include from <time.h> to "strftime.h".
18857         * modules/yesno: Add lib/yesno.h.
18858         * modules/backupfile: Remove lib/addext.c.
18859         * modules/euidaccess: Add stat-macros.h.
18860         * modules/canonicalize, modules/euidaccess,
18861         modules/filemode, modules/lchown, modules/makepath,
18862         modules/rmdir, modules/stat: Likewise.
18863
18864 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
18865
18866         Merge from tar.
18867         * lib/argp-help.c (make_hol, hol_append): Don't assume that
18868         SIZE_MAX is a valid preprocessor constant.
18869         (__argp_basename): Change from "#ifndef _LIBC"
18870         to "#ifndef __argp_short_program_name", so that
18871         we don't compile these functions for tar.
18872
18873         More merges from coreutils.
18874         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
18875         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
18876         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
18877         * lib/addext.c: Remove; no longer needed.
18878         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
18879         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
18880         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
18881         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
18882         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
18883         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
18884         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
18885         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
18886         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
18887         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
18888         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
18889         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
18890         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
18891         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
18892         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
18893         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
18894         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
18895         Import changes from coreutils.
18896
18897 2004-08-05  Simon Josefsson  <jas@extundo.com>
18898
18899         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
18900
18901 2004-08-05  Simon Josefsson  <jas@extundo.com>
18902
18903         * m4/getsubopt.m4: New file.
18904
18905 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
18906
18907         Merge from coreutils.
18908
18909         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
18910         * m4/getcwd-path-max.m4: New files.
18911
18912         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
18913         FILESYSTEM_PREFIX_LEN ->
18914         FILE_SYSTEM_PREFIX_LEN.
18915         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
18916         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
18917         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
18918         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
18919
18920         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
18921         prerequisite modules now handle the DOS stuff.
18922         Don't check for unistd.h.
18923
18924 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
18925
18926         Merge from coreutils.
18927
18928         * lib/.gdb-history: Remove; this doesn't belong here.
18929
18930         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
18931         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
18932         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
18933         * lib/getcwd.c: New files.
18934
18935         * lib/dirname.h: Include <stdbool.h>.
18936         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
18937         for consistency with POSIX terminology.  All uses changed.
18938         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
18939         (strip_trailing_slashes): Use bool for booleans.
18940         * lib/stripslash.c (strip_trailing_slashes): Likewise.
18941
18942         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
18943         sometimes returns a positive errno value even when it succeeds.
18944         (print_errno_message) [!LIBC]: Fall back on strerror if
18945         __strerror_r fails.
18946
18947         * lib/path-concat.c (mempcpy): Don't define if a system header defines
18948         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
18949         (longest_relative_suffix): New function.
18950         (path_concat): Use it.  Assume first argument is not NULL.
18951         Port to DOS.  Omit redundant separators.
18952         Report an error instead of returning NULL.
18953         Use mempcpy instead of memcpy.
18954         (xpath_concat): Remove: not declared or used.
18955
18956         * lib/same.h: Include <stdbool.h>
18957         (same_name): Return bool, not int.
18958         * lib/same.c (same_name): Likewise.
18959         (errno): Don't declare; we assume C89 or better now.
18960
18961         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
18962         if not already defined.
18963
18964         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
18965         * lib/dup-safer.c (errno): Likewise.
18966
18967 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
18968
18969         Merge from coreutils.
18970         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
18971         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
18972         * modules/path-concat: Don't depend on strdup.
18973
18974 2004-08-03  Simon Josefsson  <jas@extundo.com>
18975
18976         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
18977         * lib/progname.h: Don't include stdbool.h.
18978
18979 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
18980
18981         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
18982         * MODULES.html.sh (func_all_modules): Remove fatal.
18983
18984 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
18985
18986         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
18987
18988 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
18989
18990         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
18991         working.
18992
18993 2004-08-02  Simon Josefsson  <jas@extundo.com>
18994
18995         * lib/getsubopt.h: New file, with comments from Bruno Haible.
18996         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
18997         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
18998
18999 2004-08-01  Simon Josefsson  <jas@extundo.com>
19000
19001         * lib/xgetdomainname.c: Include stdlib.h, for free().
19002
19003 2004-07-19  Bruno Haible  <bruno@clisp.org>
19004
19005         * MODULES.html.sh (func_all_modules): Add dummy.
19006
19007 2004-07-16  Simon Josefsson  <jas@extundo.com>
19008
19009         * modules/dummy: New file.
19010
19011 2004-07-16  Simon Josefsson  <jas@extundo.com>
19012
19013         * lib/dummy.c: New file.
19014
19015 2004-07-16  Bruno Haible  <bruno@clisp.org>
19016
19017         * lib/backupfile.h: Add extern "C" for C++.
19018         * lib/closeout.h: Likewise.
19019         * lib/copy-file.h: Likewise.
19020         * lib/findprog.h: Likewise.
19021         * lib/full-write.h: Likewise.
19022         * lib/pathname.h: Likewise.
19023         * lib/progname.h: Likewise.
19024         * lib/stpcpy.h: Likewise.
19025         * lib/stpncpy.h: Likewise.
19026         * lib/strcase.h: Likewise.
19027         * lib/strstr.h: Likewise.
19028         * lib/xalloc.h: Likewise.
19029
19030         * lib/mbswidth.h: Add extern "C" for C++.
19031         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
19032
19033 2004-07-13  Robert Millan  <robertmh@gnu.org>
19034
19035         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
19036
19037 2004-07-09  Simon Josefsson  <jas@extundo.com>
19038
19039         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
19040         failed without this.)
19041
19042 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19043
19044         * modules/chown (Files): Add lib/fchown-stub.c, since
19045         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
19046
19047 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19048
19049         * lib/fchown-stub.c: New file.
19050
19051 2004-06-24  Jim Meyering  <jim@meyering.net>
19052
19053         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
19054
19055 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19056
19057         * modules/argz: Omit "#include".
19058
19059         * MODULES.html.sh (func_all_modules): Add calloc, to match
19060         2004-06-01 addition of calloc module.
19061
19062 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19063
19064         * m4/argz.m4: New file, which is autoupdated from libtool.
19065
19066 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19067
19068         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
19069         libtool.
19070
19071 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19072
19073         * config/srclist-update: Don't insist on "USA." before the
19074         close-comment, as libtool omits the period and puts the */ on a
19075         separate line.
19076         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
19077         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
19078
19079 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
19080
19081         * modules/argz: New file.
19082         * MODULES.html.sh (func_all_modules): Add argz.
19083
19084 2004-06-12  Jim Meyering  <jim@meyering.net>
19085         and  Paul Eggert  <eggert@cs.ucla.edu>
19086
19087         * modules/hash (Files): Add lib/xalloc.h.
19088         * modules/pipe (Depends-on): Add wait-process.
19089         * modules/stat (Depends-on): Add xalloc.
19090         * modules/userspec (Files): Add lib/userspec.h.
19091         * modules/xstrto
19092
19093         Upgrade from gettext-0.13.
19094         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
19095         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
19096         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
19097
19098 2004-06-10  Jim Meyering  <jim@meyering.net>
19099
19100         * lib/calloc.c: New file.
19101
19102 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
19103
19104         * lib/getdate.y (yylex): Allow space between sign and number.
19105         Problem reported by Dan Jacobson.
19106
19107 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19108
19109         Merge from coreutils CVS.
19110
19111         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
19112         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
19113         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
19114         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
19115         xstrtol.m4: Fix copyright date and/or serial number.
19116
19117         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
19118         See if we need an fchown replacement.
19119         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
19120         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
19121         and use the replacement function if we detect either defect.
19122
19123         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
19124         gl_UTIMECMP.
19125
19126 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19127         and  Jim Meyering  <jim@meyering.net>
19128
19129         Merge from coreutils CVS.
19130
19131         * lib/stat-macros.h: New file, with contents from file-type.h
19132         and coreutils' system.h.
19133         * lib/file-type.c: Include "stat-macros.h".
19134         * lib/file-type.h (file_type): Move all macro definitions to new file,
19135         stat-macros.h.
19136
19137         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
19138         Wrap old code with this conditional.
19139         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
19140         function that does not dereference symlinks.
19141         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
19142
19143         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
19144         dependency problems.
19145         (xreadlink): Accept new arg SIZE, for efficiency.
19146         All decls and uses changed.
19147         * lib/xreadlink.h: Include <stddef.h>, for size_t.
19148
19149         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
19150         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
19151
19152         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
19153         sysexits.h.
19154
19155 2004-06-01  Jim Meyering  <jim@meyering.net>
19156
19157         * m4/calloc.m4: New file.
19158
19159 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
19160
19161         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
19162         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
19163         Also, fix a typo in a diagnostic.
19164
19165 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19166
19167         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
19168         or AC_FUNC_REALLOC.
19169
19170 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19171
19172         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
19173         macros to be defined.
19174         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
19175         the allocator returns NULL because the requested size is zero.
19176
19177 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19178
19179         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
19180         var.  Add comment explaining why libc still defines it.  This
19181         merges the following patch from glibc:
19182         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
19183
19184 2004-05-20  Andreas Schwab  <schwab@suse.de>
19185
19186         * m4/free.m4: Replace free if it not known to work, not the other
19187         way round.
19188
19189 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
19190
19191         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
19192         present in glibc since revision 1.1 of this file.
19193         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
19194         obstack_alignment_mask, obstack_alloc, obstack_base,
19195         obstack_blank, obstack_blank_fast, obstack_chunk_size,
19196         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
19197         obstack_grow0, obstack_init, obstack_int_grow,
19198         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
19199         obstack_next_free, obstack_object_size, obstack_ptr_grow,
19200         obstack_ptr_grow_fast, obstack_room): Remove declarations of
19201         nonexistent functions.
19202
19203 2004-05-18  Karl Berry  <karl@gnu.org>
19204
19205         * config/srclist.txt: break link for vasnprintf.c.
19206
19207 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
19208
19209         Port obstack to the AS/400, where pointers are 16 bytes wide and
19210         you cannot cast an integer to a valid pointer.  This patch is
19211         currently waiting to be integrated into glibc; see
19212         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
19213
19214         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
19215         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
19216         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
19217         (struct obstack): temp member is now a union of a pointer and
19218         an integer, instead of an integer.  All integer uses changed.
19219         This does not affect the physical layout of struct obstack,
19220         except on hosts (like the AS/400) where the size or alignment of
19221         void * is greater than that of ptrdiff_t.
19222         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
19223         __STDC__)]: Store temporary in pointer member of union, not
19224         integer member.
19225         * lib/obstack.c: Include <stddef.h>, for offsetof.
19226         (struct fooalign): Remove; it doesn't need a name.
19227         (union fooround): Change double to long double, and add void *.
19228         (DEFAULT_ALIGNMENT): Use offsetof to compute.
19229         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
19230         not a macro.  Hence the values are always int; so remove all
19231         casts-to-int in uses.
19232
19233 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
19234
19235         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
19236         we can get this patch merged into glibc.
19237
19238 2004-05-17  Derek R. Price  <derek@ximbiot.com>
19239             Paul Eggert  <eggert@cs.ucla.edu>
19240
19241         * m4/argp: Depend on alloca.
19242
19243 2004-05-17  Derek R. Price  <derek@ximbiot.com>
19244             Paul Eggert  <eggert@cs.ucla.edu>
19245
19246         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
19247         freecoding.
19248
19249 2004-05-17  Bruno Haible  <bruno@clisp.org>
19250
19251         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
19252         precision that consists of a '.' followed by an empty digit string.
19253         Patch by Tor Lillqvist <tml@iki.fi>.
19254
19255 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
19256
19257         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
19258         for backward compatibility with older code.  We need our own
19259         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
19260         it under some other name, and our alloca.h will define it.
19261
19262 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
19263             Derek Price  <derek@ximbiot.com>
19264
19265         * lib/alloca.c: Include <alloca.h>, to get our interface.
19266         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
19267         include <alloca.h> first.  Use C89 prototype for alloca; this
19268         requires including <stddef.h> for size_t.  Use extern "C" if C++.
19269         Use #elif for simplicity, since we can assume C89 now.
19270         Don't try to source the system alloca.h since it will not be found
19271         and to prevent recursively including its replacement.
19272         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
19273         * lib/regex.c: Likewise.
19274
19275 2004-05-16  Derek Price  <derek@ximbiot.com>
19276             Paul Eggert  <eggert@cs.ucla.edu>
19277
19278         getline cleanup.  This changes the getndelim2 API: both order of
19279         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
19280         no delimiter).
19281
19282         * lib/getline.c: Don't include stddef.h or stdio.h, since our
19283         interface does that.
19284         (getline): Always use getdelim, so that we don't have two
19285         copies of this code.
19286         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
19287         if available.
19288         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
19289         (GETNDELIM2_MAXIMUM): New macro.
19290         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
19291         instead of the old practice of delim2==0.  All callers changed.
19292         Return -1 on overflow, instead of returning junk.
19293         Do not set *linesize unless allocation succeeds.
19294         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
19295         that we include sys/types.h.
19296         * lib/getnline.h: Likewise.
19297         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
19298         (getndelim2): Reorder arguments.
19299         * lib/getnline.c (getnline, getndelim):
19300         Don't discard the NMAX argument.
19301         (getnline): Invoke getndelim, to avoid code duplication.
19302         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
19303         of (size_t) -1 by callers of the getnline family.
19304
19305 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19306
19307         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
19308         Check for gettimeofday.
19309         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
19310         Check for settimeofday, stime.
19311
19312 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19313
19314         * lib/nanosleep.c (suspended): Change its type from int to
19315         sig_atomic_t volatile.
19316         (first_call): Make it private to rpl_nanosleep, and have it
19317         be zero initially as that's a bit faster.
19318         (my_usleep): Round up fractional times instead of truncating them,
19319         as this is the usual meaning for 'sleep'.
19320
19321         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
19322         doesn't work.
19323         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
19324         (ENOSYS): Define if not defined.
19325         (settime): Fall back on stime if it exists and settimeofday fails.
19326         But don't bother with fallbacks if a method fails with errno == EPERM.
19327
19328 2004-05-11  Jim Meyering  <jim@meyering.net>
19329
19330         Prior to this change, the save_cwd caller required read access to the
19331         current directory on most systems (ones with the fchdir function).
19332
19333         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
19334         fails, try write-only, and finally, resort to using xgetcwd.
19335
19336 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
19337
19338         * lib/obstack.c, obstack.h: Import changes from libc.
19339
19340 2004-04-28  Bruno Haible  <bruno@clisp.org>
19341
19342         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
19343         also implicitly appends .exe to executables.
19344         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
19345         accepts Windows pathnames.
19346         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
19347         Treat Cygwin like Windows, since it now accepts Windows pathnames.
19348         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
19349         Treat Cygwin like Windows, since it now accepts Windows pathnames.
19350         Reported by Derek Robert Price <derek@ximbiot.com>.
19351
19352 2004-04-21  Karl Berry  <karl@gnu.org>
19353
19354         * config/srclist.txt (localcharset.c): break sync.
19355
19356 2004-04-20  Paul Eggert  <eggert@twinsun.com>
19357
19358         * m4/host-os.m4: Add a copyright notice.
19359
19360 2004-04-20  Jim Meyering  <jim@meyering.net>
19361
19362         Change UTILS_ to gl_ in AC_DEFINE'd names.
19363         Change utils_- and jm_-prefixed variables, too.
19364         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
19365         UTILS_FUNC_MKDIR_TRAILING_SLASH.
19366         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
19367
19368         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
19369         Don't emit trailing blanks.
19370         Also rename jm_-prefixed variables to have gl_ prefix.
19371
19372         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
19373         Also rename jm_-prefixed variables to have gl_ prefix.
19374
19375         * m4/jm-macros.m4: Reflect the renamings.
19376         * m4/prereq.m4: Likewise.
19377
19378 2004-04-20  Jim Meyering  <jim@meyering.net>
19379
19380         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
19381         memory.
19382
19383 2004-04-20  Jim Meyering  <jim@meyering.net>
19384             Bruno Haible  <bruno@clisp.org>
19385
19386         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
19387         memory when realloc fails.
19388
19389 2004-04-19  Jim Meyering  <jim@meyering.net>
19390
19391         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
19392         now that readutmp.c may call `free (0)'.
19393
19394 2004-04-19  Bruno Haible  <bruno@clisp.org>
19395
19396         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
19397         * m4/inttypes_h.m4: Likewise.
19398         * m4/stdint_h.m4: Likewise.
19399         * m4/intmax_t.m4: Likewise.
19400         * m4/uintmax_t.m4: Likewise.
19401
19402 2004-04-18  Jim Meyering  <jim@meyering.net>
19403
19404         * m4/prereq.m4: Don't forbid jm_ prefix.
19405
19406         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
19407         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
19408         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
19409         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
19410         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
19411         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
19412         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
19413         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
19414         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
19415         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
19416         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
19417         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
19418         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
19419         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
19420         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
19421         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
19422         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
19423         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
19424         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
19425
19426 2004-04-18  Jim Meyering  <jim@meyering.net>
19427
19428         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
19429         failure, don't leak memory and do call END_UTMP_ENT.
19430
19431 2004-04-16  Jim Meyering  <jim@meyering.net>
19432
19433         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
19434         coreutils' stat program.
19435         (gl_PREREQ): Don't require jm_PREREQ_STAT.
19436
19437 2004-04-11  Paul Eggert  <eggert@twinsun.com>
19438
19439         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
19440         C89.
19441         (CHAR_BIT): Remove, since we assume C89.
19442         Include <stdint.h> if available, as per current Autoconf CVS advice.
19443
19444 2004-03-31  Jim Meyering  <jim@meyering.net>
19445
19446         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
19447         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
19448         * m4/xalloc.m4: Likewise.
19449
19450 2004-03-30  Paul Eggert  <eggert@twinsun.com>
19451
19452         Merge from coreutils.
19453
19454         * m4/inttostr.m4: New file.
19455         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
19456         Require AM_STDBOOL_H and gl_TIMESPEC instead.
19457         Require gl_CLOCK_TIME.
19458         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
19459
19460 2004-03-30  Paul Eggert  <eggert@twinsun.com>
19461
19462         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
19463         not bool, to be more consistent with Unix conventions.
19464         Suggested by Bruno Haible.
19465
19466         Merge from coreutils.
19467
19468         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
19469         * lib/umaxtostr.c: New files.
19470
19471         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
19472         the usual <time.h> dance.
19473         (get_date): Change signature to support fractional time stamps.
19474         All callers changed.
19475         * lib/getdate.y: Include "getdate.h" first, as we can now
19476         assume C89 and don't need to worry about 'const'.
19477         Similarly, include "unlocked-io.h" near start, not in middle.
19478         Include <limits.h>.
19479         (textint.value): Use long int rather than int.
19480         (textint.digits): Use size_t rather than int.
19481         (BILLION, LOG10_BILLION): New constants.
19482         (parser_control): New member rel_ns.  Members day_ordinal,
19483         time_zone, month, day, hour, minutes, rel_year, rel_month,
19484         rel_day, rel_hour, rel_minutes, rel_seconds
19485         are now long int, not int.  Member seconds is now struct timespec,
19486         not int.  New member timespec_seen.  Members dates_seen, days_seen,
19487         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
19488         not int.
19489         (%union.intval): Now long int, not int.
19490         New member timespec.
19491         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
19492         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
19493         (spec): Now is a timespec or an item list.
19494         (timespec, items): New nonterminals.
19495         (time, rel, relunit, number, get_date):
19496         Add support for fractional seconds.
19497         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
19498         (gmtime, localtime, mktime): Remove decls; not needed with C89.
19499         (to_hour): First arg is now long int, not int.
19500         (to_year): Returns long int, not int.
19501         Don't treat year -70 like 70.
19502         (tm_diff): Returns long int, not int.
19503         (lookup_word): Use bool instead of int when appropriate.
19504         (yylex): Use size_t for count, not int.
19505         Detect overflow when parsing large integer constants.
19506         Add support for fractions.
19507         (get_date): Make pointers 'const' if possible.
19508         Use more-portable code to detect integer overflow.
19509         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
19510         Don't use ctime; it's not reliable if the year has >4 digits.
19511
19512         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
19513         This is for compatibility with BSD.
19514
19515         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
19516         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
19517         From coreutils' system.h.
19518
19519         * lib/userspec.c: Don't include "posixver.h".
19520         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
19521         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
19522         compatible extension.  Simplify code by removing a boolean int
19523         that was always nonzero if a string was nonnull.
19524
19525 2004-03-30  Jim Meyering  <jim@meyering.net>
19526
19527         Merge from coreutils.
19528
19529         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
19530         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
19531         on some systems one must include <grp.h> before it.
19532         Reported by Christian Krackowizer.
19533
19534 2004-03-30  Jim Meyering  <jim@meyering.net>
19535
19536         Merge from coreutils.
19537
19538         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
19539
19540         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
19541         an empty input stream.
19542
19543         * lib/readtokens.c: Include <stdbool.h>.
19544         (readtoken): Use `size_t' rather than int/long.
19545         All callers adjusted.
19546         Use `bool' rather than `int' where appropriate.
19547         Use memset rather than an explicit loop.
19548         Use x2nrealloc rather than xrealloc.
19549         Allow the use of `\0' as a delimiter.
19550         (readtokens): Likewise.
19551         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
19552
19553 2004-03-30  Jim Meyering  <jim@meyering.net>
19554
19555         * m4/realloc.m4: Remove file, since now it does no more than
19556         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
19557         the `configure.ac' section of module/realloc.
19558         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
19559
19560 2004-03-30  Bruno Haible  <bruno@clisp.org>
19561
19562         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
19563         nonnull.
19564
19565 2004-03-29  Paul Eggert  <eggert@twinsun.com>
19566
19567         Merge changes to getloadavg.c from coreutils and Emacs.
19568
19569         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
19570         Define to an expression, not to the empty string.
19571         Include cloexec.h and xalloc.h.
19572         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
19573         Use set_cloexec_flag rather than rolling our own.
19574         * lib/cloexec.c, lib/cloexec.h: New files.
19575
19576 2004-03-29  Paul Eggert  <eggert@twinsun.com>
19577
19578         * m4/cloexec.m4: New file.
19579
19580 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19581
19582         * lib/getopt.h: Sync with libc CVS.
19583
19584 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19585             Bruno Haible  <bruno@clisp.org>
19586
19587         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
19588         mbswidth.
19589
19590 2004-03-18  Paul Eggert  <eggert@twinsun.com>
19591             Bruno Haible  <bruno@clisp.org>
19592
19593         * lib/mbswidth.h: Include <wchar.h> only if
19594         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
19595         <wchar.h>.
19596         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
19597
19598 2004-03-09  Paul Eggert  <eggert@twinsun.com>
19599
19600         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
19601         Sync with libc CVS.
19602         * lib/getopt_int.h: New file, also synced from libc.
19603
19604 2004-03-09  Paul Eggert  <eggert@twinsun.com>
19605
19606         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
19607         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
19608         Bring back getopt.c, getopt.h, getopt1.c.
19609
19610 2004-03-07  Paul Eggert  <eggert@twinsun.com>
19611
19612         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
19613         All uses changed.  Check for sa_sigaction member; this fixes
19614         a bug first reported by Jason Andrade in
19615         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
19616
19617 2004-03-07  Paul Eggert  <eggert@twinsun.com>
19618
19619         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
19620         '#if' expressions.  Unlike the code it replaces, it does not
19621         depend on (defined _SC_PAGESIZE).  However, it does depend on
19622         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
19623         first reported by Jason Andrade in
19624         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
19625
19626 2004-02-25  Simon Josefsson  <jas@extundo.com>
19627
19628         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
19629
19630 2004-02-25  Simon Josefsson  <jas@extundo.com>
19631
19632         * lib/strdup.h: New file.
19633         * lib/strdup.c: Include it.
19634         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
19635         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
19636
19637 2004-02-23  Karl Berry  <karl@gnu.org>
19638
19639         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
19640         (from fencepost.gnu.org:/gd/gnuorg).
19641
19642 2004-02-23  Karl Berry  <karl@gnu.org>
19643
19644         * config/srclistvars.sh (GNUORG) [karl]: redefine.
19645         * config/srclist.txt: add maintain/standards documents.
19646
19647 2004-02-18  Bruno Haible  <bruno@clisp.org>
19648
19649         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
19650         Reported by Derek Robert Price <derek@ximbiot.com>.
19651
19652 2004-02-16  Karl Berry  <karl@gnu.org>
19653
19654         * config/mkinstalldirs, install-sh: update from automake.
19655
19656 2004-02-06  Karl Berry  <karl@gnu.org>
19657
19658         * m4/po.m4: update from gettext 0.14.1.
19659
19660 2004-02-06  Karl Berry  <karl@gnu.org>
19661
19662         * lib/config.charset: update from gettext 0.14.1.
19663
19664 2004-02-05  Paul Eggert  <eggert@twinsun.com>
19665
19666         Add comments and code, prompted by suggestions from Bruno Haible
19667         for sh-quote.
19668         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
19669         describing the enum quoting_style values.
19670         * lib/quotearg.c (quotearg_alloc): New function.
19671         (quotearg_buffer_restyled): Treat lone { and } as special.
19672         Treat = as special.  Work around bug with older shells
19673         that "see" a '\' that is really the 2nd byte of a multibyte char.
19674         Quote empty string with shell_quoting_style.
19675
19676 2004-02-03  Bruno Haible  <bruno@clisp.org>
19677
19678         * m4/pipe.m4: New file, from GNU gettext.
19679
19680 2004-02-03  Bruno Haible  <bruno@clisp.org>
19681
19682         * lib/pipe.h: New file, from GNU gettext.
19683         * lib/pipe.c: New file, from GNU gettext.
19684
19685 2004-01-27  Bruno Haible  <bruno@clisp.org>
19686
19687         * m4/execute.m4: New file, from GNU gettext.
19688
19689 2004-01-27  Bruno Haible  <bruno@clisp.org>
19690
19691         * lib/execute.h: New file, from GNU gettext.
19692         * lib/execute.c: New file, from GNU gettext.
19693         * lib/w32spawn.h: New file, from GNU gettext.
19694
19695 2004-01-24  Paul Eggert  <eggert@twinsun.com>
19696
19697         Merge from diffutils.
19698
19699         * lib/file-type.c (file_type): Add typed memory objects.
19700         * lib/file-type.h (S_TYPEISTMO): New macro.
19701
19702         * lib/c-stack.h (c_stack_action): Remove argv argument.
19703         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
19704         (die): Don't calculate message unless segv_action returns.
19705         (get_stack_location, min_address_from_argv, max_address_from_argv,
19706         volatile stack_base, volatile_stack_size): Remove.
19707         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
19708         that every segmentation violation is a stack overflow.  (Ouch!)
19709         See Debian bug 136249 (still outstanding) for more info about why
19710         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
19711
19712 2004-01-24  Paul Eggert  <eggert@twinsun.com>
19713
19714         Exit-status fix from coreutils.
19715
19716         Use exit_failure consistently in place of EXIT_FAILURE,
19717         so that program exit statuses are consistent on failure.
19718
19719         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
19720         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
19721         * lib/argmatch.h: Comment fix to match the above.
19722         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
19723         Now a macro referring to exit_failure, instead of a separate
19724         variable.  Include "exitfail.h" to get it.
19725         * lib/xstrtol.h: Include "exitfail.h".
19726         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
19727
19728         * lib/long-options.c (parse_long_options): Use prototype
19729         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
19730         for clarity.
19731
19732 2004-01-21  Jim Meyering  <jim@meyering.net>
19733
19734         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
19735         so as not to conflict with a different-sized __mktime_internal
19736         function in GNU libc.
19737         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
19738         Problem building statically-linked `ls' reported by Michael Brunnbauer.
19739
19740 2004-01-20  Karl Berry  <karl@gnu.org>
19741
19742         * config/config.guess: update from config.
19743
19744         * config/srclistvars.sh: GNUWWWLICENSES for karl.
19745
19746 2004-01-20  Bruno Haible  <bruno@clisp.org>
19747
19748         Safer stack allocation.
19749         * lib/setenv.c: Include allocsa.h.
19750         (alloca): Remove fallback definition.
19751         (freea): Remove macro.
19752         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
19753         instead of freea.
19754
19755 2004-01-20  Bruno Haible  <bruno@clisp.org>
19756
19757         * m4/eealloc.m4: New file, from GNU gettext.
19758
19759 2004-01-20  Bruno Haible  <bruno@clisp.org>
19760
19761         * m4/allocsa.m4: New file, from GNU gettext.
19762
19763 2004-01-20  Bruno Haible  <bruno@clisp.org>
19764
19765         * lib/xallocsa.h: New file, from GNU gettext.
19766         * lib/xallocsa.c: New file, from GNU gettext.
19767
19768 2004-01-20  Bruno Haible  <bruno@clisp.org>
19769
19770         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
19771
19772 2004-01-20  Bruno Haible  <bruno@clisp.org>
19773
19774         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
19775         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
19776         specially.
19777
19778 2004-01-20  Bruno Haible  <bruno@clisp.org>
19779
19780         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
19781         patch.
19782
19783 2004-01-20  Bruno Haible  <bruno@clisp.org>
19784
19785         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
19786
19787 2004-01-20  Bruno Haible  <bruno@clisp.org>
19788
19789         * lib/eealloc.h: New file.
19790
19791 2004-01-20  Bruno Haible  <bruno@clisp.org>
19792
19793         * lib/binary-io.h: Avoid warnings on Cygwin.
19794
19795 2004-01-20  Bruno Haible  <bruno@clisp.org>
19796
19797         * lib/allocsa.h: New file, from GNU gettext.
19798         * lib/allocsa.c: New file, from GNU gettext.
19799
19800 2004-01-18  Karl Berry  <karl@gnu.org>
19801
19802         * doc/gpl.texi, doc/lgpl.texi: new files.
19803
19804 2004-01-18  Karl Berry  <karl@gnu.org>
19805
19806         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
19807         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
19808
19809 2004-01-15  Paul Eggert  <eggert@twinsun.com>
19810
19811         Merge from coreutils.
19812
19813         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
19814         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
19815         (gl_DEFAULT_POSIX2_VERSION): Move
19816         the documentation from 'configure' into 'config.hin',
19817         so that 'configure --help' isn't burdened by it and
19818         we don't have to worry about its formatting there.
19819         Reword the documentation so that it's more succinct
19820         and can be run together into a single paragraph.
19821         * m4/same.m4 (gl_SAME): Check for pathconf.
19822
19823 2004-01-15  Paul Eggert  <eggert@twinsun.com>
19824
19825         Merge from coreutils.
19826
19827         * lib/posixver.c: Include posixver.h.
19828
19829         * lib/same.c: Include <stdbool.h>, <limits.h>.
19830         (_POSIX_NAME_MAX): Define if not defined.
19831         (MIN): New macro.
19832         (same_name): If file names are silently truncated, report
19833         that the file names are the same if they are the same after
19834         the silent truncation.
19835
19836         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
19837         conversion function.
19838         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
19839         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
19840         longer needed.
19841
19842 2004-01-15  Jim Meyering  <jim@meyering.net>
19843
19844         Merge from coreutils.
19845
19846         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
19847         if no library is required.
19848         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
19849         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
19850         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
19851         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
19852         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
19853         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
19854         value, $ac_cv_search_crypt, if it's "none required".
19855         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
19856         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
19857         not gl_FUNC_GETLOADAVG.
19858         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
19859         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
19860
19861 2004-01-15  Jim Meyering  <jim@meyering.net>
19862
19863         Merge from coreutils.
19864
19865         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
19866         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
19867         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
19868
19869         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
19870         optional configure-time default.
19871
19872         * lib/version-etc.c (version_etc_copyright): Update copyright date.
19873
19874         * lib/xreadlink.c (xreadlink): Correct outdated comment.
19875
19876 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
19877
19878         Merge from coreutils.
19879
19880         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
19881         value, $ac_cv_search_nanosleep, if it's "none required".
19882
19883 2004-01-14  Paul Eggert  <eggert@twinsun.com>
19884
19885         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
19886         with like-named macro in fnmatch.c.
19887         (EXT): Use an internal constant instead.
19888
19889         Merge fnmatch patches from glibc.
19890         * lib/fnmatch.c (mbsinit): Remove define.
19891         Add libc_hidden_ver (__fnmatch, fnmatch).
19892         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
19893         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
19894
19895 2004-01-14  Karl Berry  <karl@gnu.org>
19896
19897         * config/install-sh: update from automake.
19898
19899 2004-01-13  Karl Berry  <karl@gnu.org>
19900
19901         * config/install-sh: update from automake.
19902
19903 2004-01-09  Karl Berry  <karl@gnu.org>
19904
19905         * config/install-sh: update from automake.
19906
19907 2004-01-05  Karl Berry  <karl@gnu.org>
19908
19909         * config/config.{sub,guess}: update from config.
19910
19911 2003-12-31  Karl Berry  <karl@gnu.org>
19912
19913         * config/depcomp: update from automake.
19914
19915 2003-12-14  Karl Berry  <karl@gnu.org>
19916
19917         * lib/config.charset: update from gettext-runtime.
19918
19919 2003-12-03  Paul Eggert  <eggert@twinsun.com>
19920
19921         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
19922         Bug reported by Alfred M. Szmidt.
19923
19924 2003-12-03  Bruno Haible  <bruno@clisp.org>
19925
19926         * m4/gettext.m4: Upgrade from gettext-0.13.
19927         * m4/po.m4: Upgrade from gettext-0.13.
19928         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
19929         * m4/intmax.m4: New file, from gettext-0.13.
19930         * m4/printf-posix.m4: New file, from gettext-0.13.
19931
19932 2003-11-29  Karl Berry  <karl@gnu.org>
19933
19934         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
19935
19936 2003-11-25  Paul Eggert  <eggert@twinsun.com>
19937             Bruno Haible  <bruno@clisp.org>
19938
19939         * lib/printf-parse.h: Don't include sys/types.h.
19940         (ARG_NONE): New macro.
19941         (char_directive): Change type of *arg_index fields to size_t.
19942         * lib/printf-parse.c: Don't include sys/types.h.
19943         (SSIZE_MAX): Remove macro.
19944         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
19945         Remove unnecessary overflow check.
19946         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
19947         fields.
19948
19949 2003-11-25  Bruno Haible  <bruno@clisp.org>
19950
19951         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
19952
19953 2003-11-25  Bruno Haible  <bruno@clisp.org>
19954
19955         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
19956         gt_TYPE_SSIZE_T.
19957
19958 2003-11-24  Paul Eggert  <eggert@twinsun.com>
19959
19960         * modules/alloca: Remove dependency on xalloc.
19961
19962 2003-11-24  Paul Eggert  <eggert@twinsun.com>
19963
19964         * lib/alloca.c: Remove dependency on xalloc module.
19965         (xalloc_die): Remove.
19966         (memory_full) [!defined emacs]: New macro.
19967         [!defined emacs]: Don't include xalloc.h.
19968         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
19969         address arithmetic overflows.  Change datatypes a bit to avoid
19970         unnecessary casts.
19971
19972 2003-11-22  Jim Meyering  <jim@meyering.net>
19973
19974         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
19975         s/size/size_t/.
19976
19977 2003-11-21  Karl Berry  <karl@gnu.org>
19978
19979         * config/config.{sub,guess}: update from config.
19980
19981 2003-11-18  Karl Berry  <karl@gnu.org>
19982
19983         * config/config.{sub,guess}: update from config.
19984
19985         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
19986
19987 2003-11-17  Paul Eggert  <eggert@twinsun.com>
19988
19989         * README: Mention that S+T cannot overflow if S is the size of
19990         an existing object and T is sufficiently small.
19991
19992 2003-11-17  Jim Meyering  <jim@meyering.net>
19993
19994         On systems without utime and without a utimes function capable of
19995         dealing with a NULL struct utimbuf* argument, this utime replacement
19996         could -- in unusual circumstances -- leak a file descriptor.
19997         * lib/utime.c: Include <unistd.h> and <errno.h>.
19998         (utime_null): Be sure to close `fd' and to preserve errno.
19999         Reported by Geoff Collyer via Arnold Robbins.
20000
20001 2003-11-17  Bruno Haible  <bruno@clisp.org>
20002
20003         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
20004         (Depends-on): Add xsize.
20005
20006 2003-11-17  Bruno Haible  <bruno@clisp.org>
20007
20008         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
20009
20010 2003-11-17  Bruno Haible  <bruno@clisp.org>
20011
20012         * lib/vasnprintf.c (alloca): Remove fallback definition.
20013         (freea): Remove definition.
20014         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
20015         Reported by Paul Eggert.
20016
20017 2003-11-16  Paul Eggert  <eggert@twinsun.com>
20018             Bruno Haible  <bruno@clisp.org>
20019
20020         Protect against address arithmetic overflow.
20021         * lib/printf-args.h: Include stddef.h.
20022         (arguments): Change type of field 'count' to size_t.
20023         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
20024         'unsigned int' where appropriate.
20025         * lib/printf-parse.h: Include sys/types.h.
20026         (char_directive): Change type of *arg_index fields to ssize_t.
20027         (char_directives): Change type of fields 'count', max_*_length to
20028         size_t.
20029         * lib/printf-parse.c: Include sys/types.h and xsize.h.
20030         (SSIZE_MAX): Define fallback value.
20031         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
20032         instead of 'int' where appropriate. Check a_allocated, d_allocated
20033         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
20034         * lib/vasnprintf.c: Include xsize.h.
20035         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
20036         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
20037         overflow. Avoid wraparound when converting a width or precision from
20038         decimal to binary.
20039
20040 2003-11-16  Bruno Haible  <bruno@clisp.org>
20041
20042         Update from GNU gettext.
20043         * lib/printf-parse.c: Generalize to it can be compiled for wide
20044         strings.
20045         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
20046         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
20047         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
20048         SNPRINTF): New macros.
20049         Don't include <alloca.h> if the file is used inside libintl.
20050         (local_wcslen): New function, for Solaris 2.5.1.
20051         (VASNPRINTF): Use it instead of wcslen.
20052
20053 2003-11-16  Bruno Haible  <bruno@clisp.org>
20054
20055         * lib/xsize.h (xmax): New function.
20056         (xsum, xsum3, xsum4): Declare as "pure" functions.
20057
20058 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20059
20060         * modules/xalloc (Files): Undo latest change, since xalloc.h
20061         no longer needs SIZE_MAX or PTRDIFF_MAX.
20062
20063 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20064
20065         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
20066         gl_PTRDIFF_MAX.
20067
20068 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20069
20070         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
20071         "return", to pacify some unknown compiler.  Problem reported
20072         by Joerg Schilling.
20073
20074 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20075
20076         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
20077         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
20078         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
20079         heuristic is just as accurate as far as we know, and it removes a
20080         dependency on size_max.m4 and ptrdiff_max.m4.
20081
20082 2003-11-11  Bruno Haible  <bruno@clisp.org>
20083
20084         * modules/xsize (Files): Add m4/size_max.m4.
20085         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
20086
20087 2003-11-11  Bruno Haible  <bruno@clisp.org>
20088
20089         * m4/size_max.m4: New file.
20090         * m4/ptrdiff_max.m4: New file.
20091         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
20092         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
20093         (gl_XALLOC): Invoke it.
20094
20095 2003-11-11  Bruno Haible  <bruno@clisp.org>
20096
20097         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
20098         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
20099         defined.
20100
20101 2003-11-10  Paul Eggert  <eggert@twinsun.com>
20102
20103         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
20104         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
20105         rejected some allocations of exactly SIZE_MAX - 2 bytes.
20106         From Bruno Haible.
20107         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
20108         not (size_t) -1, since it's defined here.
20109
20110 2003-11-09  Karl Berry  <karl@gnu.org>
20111
20112         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
20113
20114 2003-11-06  Paul Eggert  <eggert@twinsun.com>
20115
20116         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
20117         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
20118         Reject sizes of exactly SIZE_MAX bytes.
20119         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
20120         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
20121
20122 2003-11-05  Bruno Haible  <bruno@clisp.org>
20123
20124         * lib/xsize.h: Include limits.h, to avoid a possible collision with
20125         SIZE_MAX defined in <limits.h> on Solaris.
20126
20127 2003-11-04  Jim Meyering  <jim@meyering.net>
20128
20129         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
20130         variable names, rather than @VAR@.
20131         * modules/poll: Likewise.
20132
20133 2003-11-04  Bruno Haible  <bruno@clisp.org>
20134
20135         * modules/xsize: New file.
20136         * modules/linebreak: Depend on xsize.
20137         * MODULES.html.sh (func_all_modules): Add xsize.
20138
20139 2003-11-04  Bruno Haible  <bruno@clisp.org>
20140
20141         * m4/xsize.m4: New file.
20142
20143 2003-11-04  Bruno Haible  <bruno@clisp.org>
20144
20145         * lib/xsize.h: New file.
20146         * lib/linebreak.c: Include xsize.h.
20147         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
20148         argument for overflow.
20149         Suggested by Paul Eggert.
20150
20151 2003-11-03  Karl Berry  <karl@gnu.org>
20152
20153         * config/config.{guess,sub}: update from config.
20154
20155 2003-11-03  Jim Meyering  <jim@meyering.net>
20156
20157         * modules/userspec (lib_SOURCES): Add userspec.h.
20158         (Include): Add "userspec.h".
20159         Improve description.
20160
20161 2003-11-03  Jim Meyering  <jim@meyering.net>
20162
20163         * lib/userspec.c: Include "userspec.h".
20164         * lib/userspec.h: New file.
20165
20166 2003-11-03  Bruno Haible  <bruno@clisp.org>
20167
20168         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
20169
20170 2003-11-03  Bruno Haible  <bruno@clisp.org>
20171
20172         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
20173         available, to avoid (extremely rare) race condition.
20174         Suggested by Paul Eggert.
20175
20176 2003-11-02  Karl Berry  <karl@gnu.org>
20177
20178         * config/srclist.txt (vasprintf.c): sync broken, sigh.
20179
20180 2003-10-31  Paul Eggert  <eggert@twinsun.com>
20181
20182         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
20183         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
20184         (read_filesystem_list): Set and use me_type_malloced.
20185         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
20186         whatever the type happens to be), for brevity and consistency.
20187         Check for size calculation overflow on Alphas running OSF/1.
20188
20189 2003-10-31  Jim Meyering  <jim@meyering.net>
20190
20191         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
20192
20193         * lib/linebuffer.c: Include <string.h> for declaration of memset.
20194
20195 2003-10-30  Paul Eggert  <eggert@twinsun.com>
20196             Bruno Haible  <bruno@clisp.org>
20197
20198         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
20199         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
20200
20201 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
20202
20203         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
20204         netbsd*-gnu*.  Suggested by Robert Millan.
20205
20206 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20207
20208         * modules/group-member: Depend on stdbool.
20209
20210 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20211
20212         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
20213
20214 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20215
20216         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
20217         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
20218         after the 'gnu' in these cases.  This fixes some bugs in the
20219         previous change, and is based on suggestions by Robert Millan.
20220
20221 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20222
20223         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
20224         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
20225         no longer needed.
20226         * lib/quotearg.c (quotearg_n_options): Use it.
20227         * lib/group-member.c: Include <stdbool.h>.
20228         (free_group_info): Arg is now const *; don't free arg.
20229         (get_group_info): Now returns bool and accepts struct group_info *,
20230         rather than returning a malloc'ed struct group_info *.
20231         All uses changed.  Check for overflow in internal size calculation.
20232
20233         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
20234         rather than xmalloc/xrealloc.
20235         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
20236         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
20237         conformance bug: the old code used a pointer after freeing the
20238         storage that it addressed.
20239         * lib/hash.c (hash_initialize): Simplify the code by using
20240         xalloc_oversized rather than doing it by hand.
20241         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
20242         the buffer preserved.  Use free and xmalloc instead.
20243         * lib/quotearg.c (quotearg_n_options): Likewise.
20244         Use a simpler test for size overflow.  Don't use xalloc_oversized
20245         because unsigned int might be wider than size_t (!); this suggests
20246         that we should switch from unsigned int to size_t for slot numbers.
20247
20248 2003-10-28  Paul Eggert  <eggert@twinsun.com>
20249
20250         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
20251         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
20252         NetBSD kernels.  Requested by Richard Stallman.
20253
20254 2003-10-27  Paul Eggert  <eggert@twinsun.com>
20255
20256         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
20257         to allocate the returned structure.  Do not allocate a subarray,
20258         as x2nrealloc will do that.
20259         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
20260         instead of xnrealloc.
20261         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
20262
20263 2003-10-27  Bruno Haible  <bruno@clisp.org>
20264
20265         * lib/stdbool_.h: Better support for BeOS.
20266
20267 2003-10-26  Paul Eggert  <eggert@twinsun.com>
20268
20269         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
20270         now uses inline.
20271
20272 2003-10-26  Paul Eggert  <eggert@twinsun.com>
20273
20274         * lib/xalloc.h (xalloc_oversized): New static inline function, for
20275         callers that want to do their own size-overflow checking.  Include
20276         <stdbool.h>, since xalloc_oversized returns bool.
20277         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
20278         to use xalloc_oversized.
20279
20280         Add two functions x2realloc, x2nrealloc, for programs that grow
20281         arrays dynamically by doubling their sizes.
20282         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
20283         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
20284         New functions.
20285
20286         Port to C99 semantics for 'inline' of external functions.
20287         Bug reported by Bruno Haible.
20288         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
20289         with the old contents of xnmalloc.
20290         (xnmalloc, xmalloc): Use it.
20291         (xnrealloc_inline): New static inline function,
20292         with the old contents of xnrealloc.
20293         (xnrealloc, xrealloc): Use it.
20294
20295         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
20296         that.
20297
20298 2003-10-26  Karl Berry  <karl@gnu.org>
20299
20300         * config/srclist.txt (COPYING.DOC): no longer available from
20301         /gd/gnuorg; don't know where the ultimate source is.
20302
20303 2003-10-25  Paul Eggert  <eggert@twinsun.com>
20304
20305         Fix several address-calculation bugs in the hash modules,
20306         plus some minor code cleanup.
20307
20308         * lib/hash.h: Include <stdbool.h>, for bool.
20309         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
20310         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
20311         hash_get_n_entries, hash_get_max_bucket_length,
20312         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
20313         hash_rehash): Use size_t rather than unsigned.
20314         * lib/hash.c (struct hash_table, hash_get_n_buckets,
20315         hash_get_n_buckets_used, hash_get_n_entries,
20316         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
20317         hash_get_entries, hash_do_for_each, hash_string, is_prime,
20318         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
20319         Likewise.
20320         (SIZE_MAX): Define if not defined.
20321         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
20322         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
20323         hash_print):
20324         Use const * when possible.
20325         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
20326         (check_tuning): Fix bug: if tuning parameters were very close to
20327         0 or 1, rounding errors could have caused subscript violations.
20328         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
20329         (hash_initialize): Add 'fail:' label
20330         to free table and return NULL, and use it to simplify code.
20331         Use calloc rather than clearing the storage ourself.
20332         (hash_initialize, hash_rehash): Check for arithmetic overflow in
20333         buffer size calculations.
20334         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
20335         Include <stddef.h>, for size_t.
20336         * lib/hash-pjw.c (hash_pjw): Likewise.
20337         Switch to method described by Bruno Haible.
20338         Include <limits.h>, for CHAR_BIT.
20339         (SIZE_BITS): New macro.
20340
20341 2003-10-23  Paul Eggert  <eggert@twinsun.com>
20342
20343         * m4/getline.m4 (AM_FUNC_GETLINE):
20344         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
20345         hosts.  Problem reported by Derek Robert Price in
20346         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
20347         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
20348         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
20349
20350 2003-10-21  Paul Eggert  <eggert@twinsun.com>
20351
20352         * lib/getndelim2.c (getndelim2): When size calculation overflows,
20353         ceiling the allocation at NMAX bytes rather than silently
20354         discarding input bytes before NMAX is reached.  This makes
20355         a difference only if NMAX exceeds SIZE_MAX / 2.
20356
20357         * lib/obstack.c: Merge from glibc.
20358         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
20359         Add libc_hidden_def (_obstack_newchunk).
20360         (_obstack_free) [! defined _LIBC]: Remove.
20361         [defined _LIBC]: Make a strong alias from obstack_free, rather than
20362         a clone of the function body.
20363         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
20364         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
20365
20366         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
20367         glibc.
20368         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
20369         arg to memcpy.
20370
20371         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
20372         (obstack_ptr_grow_fast, obstack_int_grow_fast):
20373         Don't use lvalue casts, as GCC plans to remove support for them
20374         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
20375         was also present in the non-GCC version, indicating that this
20376         code had always been buggy and had never been widely used.
20377         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
20378         Use the fast variant of each macro, rather than copying the
20379         definiens of the fast variant; that way, we'll be more likely to
20380         catch future bugs in the fast variants.
20381
20382 2003-10-20  Bruno Haible  <bruno@clisp.org>
20383
20384         * modules/wait-process: New file.
20385         * MODULES.html.sh (func_all_modules): Add wait-process.
20386
20387 2003-10-20  Bruno Haible  <bruno@clisp.org>
20388
20389         * m4/wait-process.m4: New file.
20390
20391 2003-10-20  Bruno Haible  <bruno@clisp.org>
20392
20393         * lib/wait-process.h: New file, from GNU gettext.
20394         * lib/wait-process.c: New file, from GNU gettext.
20395
20396 2003-10-19  Jim Meyering  <jim@meyering.net>
20397
20398         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
20399         HPUX 10.20.
20400
20401 2003-10-18  Karl Berry  <karl@gnu.org>
20402
20403         * config/config.guess: update from config.
20404
20405 2003-10-16  Paul Eggert  <eggert@twinsun.com>
20406
20407         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
20408         (getgroups): First arg is int, not size_t.
20409         Don't let 'free' mangle errno.
20410
20411 2003-10-16  Paul Eggert  <eggert@twinsun.com>
20412
20413         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
20414
20415 2003-10-16  Karl Berry  <karl@gnu.org>
20416
20417         * config/config.{guess,sub}: update from config.
20418
20419 2003-10-16  Jim Meyering  <jim@meyering.net>
20420
20421         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
20422         memcpy.
20423
20424 2003-10-15  Paul Eggert  <eggert@twinsun.com>
20425
20426         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
20427         (SIZE_MAX): Remove.
20428         (new_exclude, add_exclude_file): Initial size no longer needs to
20429         be a power of 2.
20430         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
20431         our own address arithmetic overflow checking.
20432
20433         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
20434         (fnmatch): Do not alloca more than 2000 wide characters;
20435         instead, use malloc for large buffers.
20436         Check for address arithmetic overflow, and return -1
20437         with errno set to ENOMEM in that case.
20438         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
20439         (NEW_PATTERN): Do not alloca more than 8000 bytes;
20440         instead, return -1.  Check for address arithmetic overflow.
20441
20442 2003-10-14  Paul Eggert  <eggert@twinsun.com>
20443
20444         Handle invalid suffixes and overflow independently, so that
20445         callers can treat them independently as needed.  Fix some bugs in
20446         suffix handling, e.g., "100k@" was not diagnosed as an invalid
20447         suffix for a human-readable blocksize.  The major caller-visible
20448         change is the addition of a new
20449         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
20450         that both overflow and suffix chars were found.
20451
20452         * lib/human.c (humblock): Don't check separately for invalid suffix
20453         char; that is xstrtoumax's job (now that its bug is fixed).
20454         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
20455         INTMAX_MAX]: New macros.
20456         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
20457         TYPE_MAXIMUM): New macros.
20458         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
20459         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
20460         if overflow occurs, as it's what __strtol does and it's more useful
20461         in practice.
20462         (__xstrtol): If __strtol reports some error other than ERANGE,
20463         reflect it to the caller as LONGINT_INVALID.  If it reports
20464         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
20465         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
20466         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
20467         value.
20468         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
20469         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
20470         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
20471         [defined UINTMAX_MAX]: New macros.
20472
20473 2003-10-14  Bruno Haible  <bruno@clisp.org>
20474
20475         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
20476
20477 2003-10-14  Bruno Haible  <bruno@clisp.org>
20478
20479         * m4/sig_atomic_t: New file, from GNU gettext.
20480         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
20481
20482 2003-10-14  Bruno Haible  <bruno@clisp.org>
20483
20484         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
20485         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
20486         Also use volatile where needed.
20487
20488 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20489
20490         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
20491         Change maintainer from Bruno Haible to 'all'.
20492
20493 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20494
20495         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
20496
20497 2003-10-12  Paul Eggert  <eggert@twinsun.com>
20498
20499         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
20500         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
20501         and define in terms of the other primitives.
20502         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
20503         (SIZE_MAX): Define if not already defined.
20504         (array_size_overflow): New function.
20505         (xalloc_die): Abort instead of exiting if 'error' returns.
20506         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
20507         (xmalloc, xrealloc): Use them.
20508         (xcalloc): Check for address arithmetic overflow.
20509         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
20510         a bit faster than strcpy.
20511
20512 2003-10-10  Simon Josefsson  <jas@extundo.com>
20513
20514         * modules/argp (Depends-on): Add restrict and strcase.
20515
20516 2003-10-10  Simon Josefsson  <jas@extundo.com>
20517
20518         * m4/argp.m4: Add AC_C_INLINE.
20519
20520 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20521
20522         Merge getpass from libc, plus a few fixes.
20523
20524         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
20525         Include <stdbool.h>.
20526         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
20527         __fsetlocking to empty.
20528         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
20529         do include <bits/libc-lock.h>.
20530         Do not include <fcntl.h>; not needed.
20531         [_LIBC]: Include <wchar.h>.
20532         (NOTCANCEL_MODE): New macro.
20533         (flockfile, funlockfile) [_LIBC]: New macros.
20534         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
20535         [!_LIBC]: New macros.
20536         (call_fclose): New function.
20537         (getpass): Use it.  Save tty stream separately; this simplifies the
20538         code and makes it more reliable if stdin happens to equal stdout.
20539         Invoke __fsetlocking on tty.
20540         Handle thread cancellation if needed.
20541         Namespace cleanup (use __tcgetattr, __getline).
20542         Use bool for Booleans.
20543         [USE_IN_LIBIO]: Handle wide streams.
20544         [!_LIBC]: Unconditionally do the fseek, since we don't know what
20545         stream might go where.
20546
20547         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
20548         doesn't have to include <stdio.h> before us.
20549         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
20550         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
20551         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
20552         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
20553         if not declared, so that we can use getpass.c code from libc without
20554         rewriting it.
20555         (flockfile, ftrylockfile, funlockfile): New macros.
20556
20557 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20558
20559         * modules/getpass: Depend on stdbool.
20560
20561 2003-10-08  Paul Eggert  <eggert@twinsun.com>
20562
20563         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
20564
20565 2003-10-07  Karl Berry  <karl@gnu.org>
20566
20567         * config/config.{guess,sub}: update from config.
20568
20569 2003-10-06  Jim Meyering  <jim@meyering.net>
20570             Bruno Haible  <bruno@clisp.org>
20571
20572         This lets translators provide better translations for the
20573         "Written by ..." part of --version output.
20574         * lib/version-etc.h: Include stdarg.h.
20575         (version_etc_copyright): Declare as readonly.
20576         (version_etc): Make this function variadic with a NULL-terminated list
20577         of author name strings.
20578         (version_etc_va): New declaration.
20579         * lib/version-etc.c: Include stdarg.h, stdlib.h.
20580         (version_etc_copyright): Declare as readonly.
20581         (version_etc_va): New function. Provide a different translatable string
20582         for each possible number of authors < 10. Abbreviate when there are 10
20583         authors or more.
20584         (version_etc): Make this function variadic. Call version_etc_va.
20585         Suggestion from Gary V. Vaughan.
20586
20587         * lib/long-options.h (parse_long_options): Change prototype: the
20588         authors string is moved to the end and becomes variadic.
20589         * lib/long-options.c: Include stdarg.h.
20590         (parse_long_options): Make this function variadic, too.
20591         Call version_etc_va, not version_etc.
20592
20593 2003-10-06  Bruno Haible  <bruno@clisp.org>
20594
20595         * modules/version-etc-2: Remove file.
20596         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
20597
20598 2003-10-06  Bruno Haible  <bruno@clisp.org>
20599
20600         * modules/fatal-signal: New file.
20601         * MODULES.html.sh (func_all_modules): Add fatal-signal.
20602
20603 2003-10-06  Bruno Haible  <bruno@clisp.org>
20604
20605         * m4/fatal-signal.m4: New file.
20606         * m4/signalblocking.m4: New file, from GNU gettext.
20607
20608 2003-10-06  Bruno Haible  <bruno@clisp.org>
20609
20610         * lib/version-etc-2.h: Remove file.
20611         * lib/version-etc-2.c: Remove file.
20612
20613 2003-10-06  Bruno Haible  <bruno@clisp.org>
20614
20615         * lib/fatal-signal.h: New file, from GNU gettext.
20616         * lib/fatal-signal.c: New file, from GNU gettext.
20617
20618 2003-10-05  Paul Eggert  <eggert@twinsun.com>
20619
20620         * README: Rework advice for preventing empty .o files.
20621         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
20622         not <sys/types.h>.
20623
20624 2003-10-04  Karl Berry  <karl@gnu.org>
20625
20626         * lib/argp*: update from libc.
20627
20628 2003-10-04  Karl Berry  <karl@gnu.org>
20629
20630         * config/config.{guess,sub}: update from config.
20631
20632 2003-10-02  Bruno Haible  <bruno@clisp.org>
20633
20634         * modules/lchown (Include): Add lchown.h.
20635         * modules/time_r (Include): Use "..." syntax.
20636         * modules/xgetdomainname (Include): Add xgetdomainname.h.
20637
20638 2003-10-01  Simon Josefsson  <jas@extundo.com>
20639
20640         * MODULES.html.sh (func_all_modules): Move gethostname from section
20641         'based on' to section 'lacking' POSIX:2001.
20642
20643 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
20644
20645         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
20646         to output mode on the same stream.
20647
20648 2003-09-29  Paul Eggert  <eggert@twinsun.com>
20649
20650         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
20651         Fix arg typo in previous patch.
20652
20653 2003-09-28  Jim Meyering  <jim@meyering.net>
20654
20655         * lib/error.c: Correct cpp indentation.
20656
20657 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20658
20659         * modules/free: New file.
20660
20661 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20662
20663         * m4/free.m4: New file.
20664
20665 2003-09-27  Paul Eggert  <eggert@twinsun.com>
20666
20667         * lib/minmax.h (MIN, MAX)
20668         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
20669         Omit the special code that used __typeof__, since we worry that
20670         it could be more trouble than it's worth.  See:
20671         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
20672         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
20673
20674         * lib/free.c: New file.
20675
20676 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
20677
20678         Trivial fixes to Makefile.am parts of module listings.
20679         * modules/strstr: Append strstr.h to lib_SOURCES.
20680         * modules/strcase: Likewise, for strcase.h.
20681
20682 2003-09-27  Karl Berry  <karl@gnu.org>
20683
20684         * config/mkinstalldirs: update from automake.
20685
20686 2003-09-26  Paul Eggert  <eggert@twinsun.com>
20687
20688         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
20689         (error_tail): Do not loop, reallocating temporary buffer, since
20690         the output cannot contain more wide characters than the input
20691         contains bytes, the size must be big enough already.  This avoids
20692         one potential size overflow calculation.  Check for size overflow
20693         when calculating temporary buffer size.  Free temporary buffer
20694         when done, if it was allocated with malloc; this plugs a memory
20695         leak.  Remove casts from void * to pointers, that are no longer
20696         needed now that we're assuming C89 or better.
20697
20698         Merge error changes from glibc.
20699
20700         * lib/error.c, error.h: Update copyright notice header to match glibc.
20701         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
20702         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
20703         Disable cancellation while printing error.
20704         * lib/error.h: Prepend __ to parameter names.
20705
20706 2003-09-26  Jim Meyering  <jim@meyering.net>
20707
20708         * lib/error.c (error_tail): Move some declarations
20709         into inner scope where the local variables are used.
20710
20711 2003-09-26  Bruno Haible  <bruno@clisp.org>
20712
20713         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
20714         stpncpy().
20715         Don't define stpncpy through config.h; it's now done through stpncpy.h.
20716
20717 2003-09-26  Bruno Haible  <bruno@clisp.org>
20718
20719         * lib/stpncpy.h (gnu_stpncpy): New declaration.
20720         (stpncpy): Define as alias for gnu_stpncpy.
20721         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
20722
20723 2003-09-25  Simon Josefsson  <jas@extundo.com>
20724
20725         * lib/xgetdomainname.h: New file.
20726         * lib/xgetdomainname.c: New file.
20727
20728 2003-09-25  Simon Josefsson  <jas@extundo.com>
20729             Bruno Haible  <bruno@clisp.org>
20730
20731         * modules/getdomainname: New file.
20732         * modules/xgetdomainname: New file.
20733         * MODULES.html.sh (func_all_modules): Add getdomainname,
20734         xgetdomainname.
20735
20736 2003-09-25  Simon Josefsson  <jas@extundo.com>
20737             Bruno Haible  <bruno@clisp.org>
20738
20739         * m4/getdomainname.m4: New file.
20740
20741 2003-09-25  Simon Josefsson  <jas@extundo.com>
20742             Bruno Haible  <bruno@clisp.org>
20743
20744         * lib/getdomainname.h: New file.
20745         * lib/getdomainname.c: New file.
20746
20747 2003-09-25  Karl Berry  <karl@gnu.org>
20748
20749         * lib/argp-fmtstream.c, argp-help.c: update from libc.
20750
20751 2003-09-25  Karl Berry  <karl@gnu.org>
20752
20753         * config/install-sh: update from automake.
20754
20755 2003-09-25  Bruno Haible  <bruno@clisp.org>
20756
20757         * modules/version-etc-2: New file, from modules/version-etc with
20758         modifications.
20759         * MODULES.html.sh (func_all_modules): Add version-etc-2.
20760
20761 2003-09-25  Bruno Haible  <bruno@clisp.org>
20762
20763         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
20764         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
20765
20766 2003-09-24  Simon Josefsson  <jas@extundo.com>
20767
20768         * modules/xgethostname: Add xgethostname.h.
20769
20770 2003-09-24  Paul Eggert  <eggert@twinsun.com>
20771
20772         * lib/linebuffer.c (freebuffer): Don't free the argument, just
20773         the buffer associated with the argument.  Bug reported by
20774         Simon Josefsson.
20775
20776 2003-09-24  Paul Eggert  <eggert@twinsun.com>
20777
20778         * README: Document assumptions that 'int' is at least 32 bits
20779         wide, that integer arithmetic is 2's complement without overflow,
20780         that there are no holes in integer values, that adding sizes of
20781         two nonoverlapping objects can't overflow, and that all-bits-zero
20782         yields scalar zero.  Fix spelling and capitalization typos.
20783
20784 2003-09-19  Karl Berry  <karl@gnu.org>
20785
20786         * lib/argp.h: update from libc.
20787
20788 2003-09-17  Paul Eggert  <eggert@twinsun.com>
20789
20790         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
20791         to avoid spurious warnings like "AC_RUN_IFELSE was called before
20792         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
20793
20794 2003-09-17  Paul Eggert  <eggert@twinsun.com>
20795
20796         * gnulib-tool: Use "test -h", not "test -L", for portability
20797         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
20798         (tags_regexp): Remove, since \| doesn't conform to POSIX.
20799         (sed_extract_prog): Issue s commands one-by-one, rather than
20800         using \| in one s command.
20801
20802 2003-09-16  Paul Eggert  <eggert@twinsun.com>
20803
20804         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
20805         input error, instead of returning NULL the next time we are called
20806         (and therefore losing track of errno).
20807
20808 2003-09-16  Bruno Haible  <bruno@clisp.org>
20809
20810         * gnulib-tool (func_create_testdir): Warn about duplicated
20811         dependencies.
20812
20813 2003-09-15  Paul Eggert  <eggert@twinsun.com>
20814
20815         * modules/argmatch, modules/fatal, modules/obstack,
20816         modules/xalloc, modules/xgethostname: Sort dependencies by
20817         importance, not alphabetically.
20818
20819 2003-09-15  Paul Eggert  <eggert@twinsun.com>
20820
20821         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
20822         fails, so that the caller gets the proper errno.
20823
20824         * lib/readutmp.c (read_utmp): Likewise.
20825         Check for fstat error.  Close stream and free storage
20826         when failing.
20827
20828 2003-09-14  Karl Berry  <karl@gnu.org>
20829
20830         * config/srclist.txt (strdup.c): disable for c89 changes.
20831
20832 2003-09-14  Jim Meyering  <jim@meyering.net>
20833
20834         * lib/getloadavg.c: Correct cpp indentation.
20835         * lib/strdup.c: Likewise.
20836         * lib/vasnprintf.c: Likewise.
20837
20838 2003-09-14  Bruno Haible  <bruno@clisp.org>
20839
20840         * modules/fwriteerror: New file.
20841         * MODULES.html.sh (func_all_modules): Add fwriteerror.
20842
20843 2003-09-14  Bruno Haible  <bruno@clisp.org>
20844
20845         * lib/fwriteerror.h: New file.
20846         * lib/fwriteerror.c: New file.
20847
20848 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20849
20850         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
20851         modules/xgethostname, modules/xalloc: Depend on exit.
20852
20853 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20854
20855         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
20856
20857         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
20858         and AC_MINIX, too, so that their extensions are available.
20859
20860         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
20861         This macro has been superseded by gl_BACKUPFILE.
20862
20863         More patches to assume C89 or better.
20864
20865         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
20866
20867         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
20868         unconditionally.
20869         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
20870         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
20871         Include <string.h>, <stdlib.h> unconditionally.
20872         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
20873         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
20874         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
20875         headers or for string.h.
20876         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
20877         or strtoul.
20878
20879         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
20880         headers.
20881         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
20882         * m4/userspec.m4 (gl_USERSPEC): Likewise.
20883         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
20884         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
20885         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
20886         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
20887         memcpy, memset.
20888         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
20889         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
20890         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
20891         strtol.
20892         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
20893         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
20894         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
20895         strtoul.
20896
20897 2003-09-12  Paul Eggert  <eggert@twinsun.com>
20898
20899         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
20900         * lib/obstack.c [!defined _LIBC]: Likewise.
20901         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
20902         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
20903         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
20904
20905         More changes to assume C89 or better.
20906
20907         * lib/error.c (error_tail): Assume vprintf.
20908
20909         * lib/argmatch.c (getenv): Remove decl.
20910         * lib/progreloc.c (get_full_program_name): Define via prototype.
20911         * lib/setenv.c (clearenv): Likewise.
20912         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
20913         needed.
20914         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
20915         (malloc, memcpy): Remove decls.
20916         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
20917         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
20918         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
20919         (memcpy): Remove macro.
20920         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
20921         (__P): Remove.  All uses removed.
20922         (PTR): Remove.  All uses changed to void *.
20923         (CHAR_BIT, NULL): Remove.
20924         (spaces, zeros, memset_space, memset_zero)
20925         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
20926         Remove.
20927         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
20928         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
20929         Define with prototype.
20930         Remove now-unnecessary prototype decl.
20931         (extra_args_spec): Assume ANSI C.  All uses changed.
20932         (extra_args_spec_iso): Remove.
20933         (my_strftime, emacs_strftimeu): Define via prototype.
20934         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
20935         unconditionally.
20936         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
20937         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
20938         (strtoul, strtol): Remove decls.
20939         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
20940         LONG_MAX): Remove.
20941         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
20942         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
20943         (LOCALE_PARAM_PROTO): New macro.
20944         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
20945         (INTERNAL (strtol), strtol): Define with a prototype.
20946         (PARAMS): Remove.  All uses removed.
20947         * lib/tempname.c: Include <string.h> unconditionally.
20948         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
20949         * lib/xgethostname.c (main): Define with a prototype.
20950         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
20951         Include <stdlib.h> unconditionally.
20952         (calloc, malloc, realloc, free): Remove decls.
20953         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
20954         Include <stdlib.h> unconditionally.  Sort include file names.
20955         (strtod): Remove.
20956         (xstrtod): Define with a prototype.
20957         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
20958         (strtol, strtoul): Remove decls.
20959
20960 2003-09-11  Paul Eggert  <eggert@twinsun.com>
20961
20962         More patches to assume C89 or better.
20963         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
20964         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
20965         string.h, memchr, STDC_HEADERS.
20966
20967 2003-09-11  Paul Eggert  <eggert@twinsun.com>
20968
20969         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
20970         Include <stdlib.h>, <string.h> unconditionally.
20971         Remove now-unnecessary cast to char *.
20972         * lib/strnlen.c: Include <string.h> unconditionally.
20973         * lib/yesno.c (yesno): Define with a prototype.
20974
20975 2003-09-11  Bruno Haible  <bruno@clisp.org>
20976
20977         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
20978
20979 2003-09-10  Jim Meyering  <jim@meyering.net>
20980
20981         * lib/error.c: Correct indentation of cpp directives.
20982
20983 2003-09-10  Bruno Haible  <bruno@clisp.org>
20984
20985         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
20986         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
20987         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
20988         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
20989         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
20990         <stdlib.h> and <string.h> checks.
20991         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
20992         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
20993
20994 2003-09-10  Bruno Haible  <bruno@clisp.org>
20995
20996         * lib/strcspn.c: Include <string.h> unconditionally.
20997         * lib/strpbrk.c: Include <string.h> unconditionally.
20998         * lib/strstr.c: Include <string.h> unconditionally.
20999         * lib/unicodeio.c: Include <string.h> unconditionally.
21000         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
21001         * lib/unsetenv.c: Likewise.
21002         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
21003         * lib/yesno.c: Include <stdlib.h> unconditionally.
21004         (rpmatch): Add prototype.
21005
21006 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21007
21008         More patches to assume C89 or better.
21009         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
21010         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
21011         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
21012         or for string.h.
21013         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
21014         stdlib.h.
21015         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
21016         C headers.
21017         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
21018         string.h.
21019         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
21020         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
21021         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
21022         or for string.h.
21023         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
21024         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
21025         C headers.
21026         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
21027         memcpy.
21028         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
21029         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
21030         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
21031         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
21032         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
21033         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
21034         string.h, free.
21035         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
21036         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
21037         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
21038         C headers, or for string.h.
21039         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
21040         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
21041         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
21042         headers, memory.h, stdlib.h, string.h, strings.h.
21043         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
21044         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
21045         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
21046         strchr.
21047         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
21048         headers, memory.h, string.h.
21049         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
21050         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
21051         free.
21052         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
21053         headers.
21054         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
21055         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
21056         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
21057         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
21058         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
21059
21060 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21061
21062         More K&R removal.
21063
21064         * lib/acosl.c (main): Use a prototype.
21065         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
21066         tanl.c: Likewise.
21067
21068         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
21069
21070         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
21071         (getopt, etopt_long, getopt_long_only, _getopt_internal)
21072         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
21073         with a prototype.
21074         * lib/getopt.c (const): Remove macro.
21075         Include <string.h> unconditionally.
21076         (my_index): Remove; all uses changed to strchr.
21077         (strlen): Remove decl.
21078         (exchange): Remove forward decl; no longer needed.
21079         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
21080         Define with prototype.
21081         * lib/getopt1.c (const): Remove macro.
21082         (getopt_long, getopt_long_only, main): Define with prototype.
21083
21084         * lib/getugroups.c: Include <string.h> unconditionally.
21085
21086         * lib/getusershell.c: Include <stdlib.h> unconditionally.
21087         (getusershell, setusershell, endusershell, readname, main):
21088         Define with prototypes.
21089
21090         * lib/group-member.c: Include group-member.h first.
21091         Include <stdlib.h> unconditionally.
21092
21093         * lib/hard-locale.c: Include hard-locale.h first.
21094         Include <stdlib.h>, <string.h> unconditionally.
21095
21096         * lib/hash.c (free, malloc): Remove decls.
21097         Include <stdlib.h> unconditionally.
21098
21099         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
21100         (getenv): Do not declare.
21101
21102         * lib/idcache.c: Include <string.h> unconditionally.
21103
21104         * lib/long-options.c: Include long-options.h first, to test interface.
21105         Include <stdlib.h> unconditionally.
21106
21107         * lib/makepath.c: Include makepath.h first, to test interface.
21108         Include <stdlib.h> and <string.h> unconditionally.
21109
21110         * lib/linebuffer.c: Include <stdlib.h>.
21111         (free): Remove decl.
21112
21113         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
21114         stddef.h. rpl_malloc returns void *, not char *.
21115         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
21116         prototype.
21117
21118         * lib/md5.h: Include <limits.h> unconditionally.
21119         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
21120         (__P): Remove; all uses removed.
21121         * lib/md5.c: Include "md5.h" first.
21122         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
21123         md5_buffer, md5_process_bytes, md5_process_block):
21124         Define with prototypes.
21125         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
21126         * lib/sha.c: Include "sha.h" first.
21127         Include <stdlib.h>, <string.h> unconditionally.
21128
21129         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
21130         * lib/memcmp.c (__ptr_t): Likewise.
21131         * lib/memrchr.c (__ptr_t): Likewise.
21132         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
21133         Include <string.h> unconditionally.
21134         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
21135         * lib/memchr.c: Include <stdlib.h> unconditionally.
21136         * lib/memchr.c (LONG_MAX): Remove.
21137         * lib/memrchr.c (LONG_MAX): Likewise.
21138         * lib/memchr.c (__memchr): Define via a prototype.
21139         * lib/memrchr.c (__memrchr): Likewise.
21140         * lib/memcmp.c (__P): Remove, and remove all uses.
21141         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
21142         Remove forward decls; no longer needed.
21143         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
21144         Use types required by C89 in prototype.
21145
21146         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
21147         * lib/savedir.c: Likewise.
21148         * lib/mkdir.c (free): Remove decl.
21149         * lib/rmdir.c (rmdir): Define with a prototype.
21150         * lib/savedir.c: Include savedir.h first, to test interface.
21151
21152         * lib/mktime.c (STDC_HEADERS): Remove.
21153         Include <stdlib.h>, <string.h> unconditionally.
21154
21155         * lib/modechange.c: Include <stdlib.h> unconditionally.
21156         (malloc): Remove decl.
21157
21158         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
21159         (free): Remove decl.
21160
21161         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
21162         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
21163         (This type really should be intptr_t, but that's a C99ism.)
21164         (_obstack_memcpy): Remove: all uses changed to memcpy.
21165         Include <string.h> unconditionally.
21166         (struct obstack): Assume __STDC__ for types of members
21167         chunkfun, freefun, extra_arg.
21168         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
21169         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
21170         obstack_begin, obstack_specify_allocation,
21171         obstack_specify_allocation_with_arg, obstack_chunkfun,
21172         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
21173         Remove unprototyped decls and the macros that use them.
21174         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
21175         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
21176         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
21177         (defined __STDC__ && __STDC__)]:
21178         Remove nonprototyped code.
21179         Include <stdlib.h> unconditionally.
21180         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
21181         _obstack_allocated_p, _obstack_free, obstack_free,
21182         _obstack_memory_used, print_and_abort):
21183         Define using prototypes.
21184         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
21185         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
21186         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
21187         obstack_next_free, obstack_object_size, obstack_room) [0]:
21188         Remove unused, unprototyped code.
21189
21190         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
21191
21192         * lib/physmem.c (physmem_total, physmem_available, main): Define
21193         with prototypes.
21194
21195         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
21196         (main): Define with a prototype.
21197
21198         * lib/posixver.c (getenv): Remove decl.
21199
21200         * lib/putenv.c (malloc): Returns void *, not char *.
21201         Include <string.h> unconditionally.
21202         (strchr, memcpy, NULL): Do not define.
21203
21204         * lib/readtokens.c: Include readtokens.h first, to test interface.
21205         Include <stdlib.h>, <string.h> unconditionally.
21206         (init_tokenbuffer): Define with a prototype.
21207
21208         * lib/regex.c (PARAMS): Remove.  All uses removed.
21209         All uses of _RE_ARGS removed, too.
21210         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
21211         unconditionally.
21212         (bzero): Assume memset exists.
21213         (memcmp, memcpy, NULL): Remove.
21214         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
21215         char, or assignments to local vars of type signed char.
21216         (init_syntax_once, PREFIX(extract_number_and_incr),
21217         PREFIX(print_partial_compiled_pattern),
21218         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
21219         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
21220         PREFIX(regex_grow_registers), PREFIX(regex_compile),
21221         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
21222         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
21223         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
21224         wcs_compile_range, byte_compile_range, truncate_wchar,
21225         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
21226         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
21227         count_mbs_length, wcs_re_match_2_internal,
21228         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
21229         PREFIX(alt_match_null_string_p),
21230         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
21231         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
21232         regfree, PREFIX(extract_number)): Define with prototype.  Remove
21233         now-unnecessary declaration, if any.
21234         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
21235         regcomp, regexec):
21236         Remove now-unnecessary casts among pointer types.
21237         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
21238
21239         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
21240         (free): Remove decl.
21241
21242         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
21243
21244         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
21245         (free): Remove decl.
21246
21247         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
21248         * lib/xgetcwd.c: Likewise.
21249
21250         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
21251         (free): Remove decl.
21252
21253         * lib/strchrnul.c (strchrnul): Define with a prototype.
21254         Fix bug: c_in was not converted to char before searching.
21255
21256         The following changes are not K&R related:
21257
21258         * lib/group-member.h: Include <sys/types.h>, so that this file is
21259         self-contained.
21260         * lib/makepath.h: Likewise.
21261
21262         * lib/getusershell.c (readname, default_index, line_size, readname):
21263         Use size_t, not int, for sizes.
21264         (readname): If the size overflows, report an error instead of
21265         looping forever.
21266
21267 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21268
21269         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
21270         libc.
21271
21272 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21273
21274         * README: New section: portability guidelines.
21275
21276 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
21277
21278         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
21279         C89 spec.
21280
21281 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
21282
21283         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
21284
21285 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21286
21287         Assume C89 or better; remove K&R cruft.
21288         A few of these changes were first proposed by Derek Robert Price
21289         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
21290
21291         * lib/addext.c: Include <string.h> unconditionally.
21292         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
21293         Don't declare getenv or malloc.
21294
21295         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
21296         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
21297         (NULL): Remove.
21298         (find_stack_direction, alloca): Use prototypes.
21299
21300         * lib/atexit.c (atexit): Define using a prototype.
21301
21302         * lib/basename.c, dirname.c, stripslash.c:
21303         Include <string.h> unconditionally.
21304
21305         * lib/bcopy.c: Include <stddef.h>.
21306         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
21307
21308         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
21309
21310         * lib/error.h (error, error_at_line, error_print_progname)
21311         [! (defined (__STDC__) && __STDC__)]: Remove decls.
21312         * lib/error.c: Include error.h first, to check interface.
21313         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
21314         (VA_START): Remove; all uses changeed to va_start.
21315         (exit, strerror): Remove decls.
21316         (error_print_progname): Prototype uncondionally.
21317         Don't include <errno.h>; no longer needed.
21318         (private_strerror): Remove.
21319         (error_tail): Always define.
21320         (error, error_at_line): Assume C89 or better; always use prototypes.
21321         * lib/fatal.c: Include "fatal.h" first, to test interface.
21322         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
21323         (VA_START): Remove; all uses changed to va_start.
21324         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
21325         this case.
21326         (exit): Remove decl.
21327         (fatal): Prototype unconditionally.  Assume va_start works.
21328         Abort at end, to pacify gcc.
21329
21330         * lib/euidaccess.c (main): Define with a prototype.
21331
21332         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
21333
21334         * lib/exitfail.c: Include <stdlib.h> unconditionally.
21335
21336         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
21337         prototypes.
21338         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
21339         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
21340         (getenv): Remove decl.
21341         (fnmatch): Define using a prototype.
21342         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
21343         (FCT): Define using a prototype.
21344
21345         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
21346
21347         * lib/gethostname.c: Include <stddef.h>.
21348         (gethostname): Define with prototype.  Length is size_t, not int.
21349
21350 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21351
21352         Assume C89 or better; remove K&R cruft.
21353         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
21354         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
21355         string.h, getenv, malloc.
21356         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
21357         headers.
21358         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
21359         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
21360         do not check for strerror.
21361         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
21362         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
21363         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
21364         do not check for doprnt or vprintf.
21365         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
21366         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
21367
21368 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21369
21370         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
21371         getversion.c should have been removed then, but was accidentally
21372         preserved.
21373
21374         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
21375         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
21376
21377 2003-09-08  Karl Berry  <karl@gnu.org>
21378
21379         * config/config.sub, config.guess, srclistvars.sh: update from savannah
21380                 config, forget about prep.
21381
21382         * config/depcomp, missing: update from automake.
21383
21384 2003-09-07  Paul Eggert  <eggert@twinsun.com>
21385
21386         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
21387         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
21388
21389 2003-09-07  Paul Eggert  <eggert@twinsun.com>
21390
21391         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
21392         copy_tm_result.  Bug reported by Simon Josefsson in
21393         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
21394
21395 2003-09-06  Paul Eggert  <eggert@twinsun.com>
21396
21397         * m4/time_r.m4: New file.
21398         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
21399         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
21400         is. Check for timegm declaration.
21401         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
21402         Do not check for gmtime_r.
21403         Replace mktime if __mktime_internal does not exist and if mktime
21404         hasn't been replaced already.
21405
21406 2003-09-06  Paul Eggert  <eggert@twinsun.com>
21407
21408         * lib/time_r.c, lib/time_r.h: New files.
21409
21410         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
21411         __localtime_r.
21412         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
21413         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
21414
21415         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
21416         __gmtime_r.
21417         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
21418         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
21419         Include <time_r.h>.
21420
21421         * lib/timegm.c: Switch to glibc implementation, with the following
21422         changes:
21423         [defined HAVE_CONFIG_H]: Include <config.h>.
21424         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
21425         (__mktime_internal) [!defined _LIBC]: New decl.
21426         (__gmtime_r) [!defined _LIBC]: New macro and function.
21427         (timegm): Use a prototype, since gnulib assumes C89.
21428         Do not bother declaring tmp to be const, as it's not really usefu.
21429         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
21430         (timegm): Declare only if HAVE_DECL_TIMEGM.
21431
21432 2003-09-06  Paul Eggert  <eggert@twinsun.com>
21433
21434         * MODULES.html.sh (func_all_modules): Add time_r.
21435         * modules/time_r: New file.
21436         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
21437         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
21438
21439 2003-09-03  Paul Eggert  <eggert@twinsun.com>
21440
21441         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
21442         Bug reported by Lute Kamstra in
21443         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
21444
21445         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
21446         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
21447         course with correspondingly smaller numbers for tomorrow and
21448         yesterday.  From Tadayoshi Funaba.  Originally installed into
21449         sh-utils on 1999-08-07, but the patch got lost (I guess during the
21450         coreutils merge?).
21451
21452 2003-08-31  Simon Josefsson  <jas@extundo.com>
21453
21454         * modules/timegm: New file.
21455         * MODULES.html.sh (func_all_modules): Add timegm.
21456
21457 2003-08-31  Simon Josefsson  <jas@extundo.com>
21458
21459         * m4/timegm.m4: New file.
21460
21461 2003-08-31  Simon Josefsson  <jas@extundo.com>
21462
21463         * lib/timegm.h: New file.
21464         * lib/timegm.c: New file.  Based on
21465         wget-1.8.2/src/http.c:mktime_from_utc.
21466
21467 2003-08-31  Karl Berry  <karl@gnu.org>
21468
21469         * lib/argp.h: update from libc.
21470
21471 2003-08-28  Bruno Haible  <bruno@clisp.org>
21472
21473         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
21474         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
21475         followed by '#define fnmatch fnmatch_posix' gives an error.
21476
21477 2003-08-28  Bruno Haible  <bruno@clisp.org>
21478
21479         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
21480         warning on QNX, which defines O_BINARY to 000000.
21481
21482 2003-08-27  Jim Meyering  <jim@meyering.net>
21483
21484         * m4/mkstemp.m4: Require that the system mkstemp be able to create
21485         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
21486         would fail after 32.  Reported by Danny Levinson.  Details here:
21487         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
21488
21489 2003-08-24  Bruno Haible  <bruno@clisp.org>
21490
21491         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
21492         MSVC7 <stdio.h> is included later.
21493
21494 2003-08-22  Simon Josefsson  <jas@extundo.com>
21495
21496         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
21497
21498 2003-08-20  Karl Berry  <karl@gnu.org>
21499
21500         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
21501
21502 2003-08-20  Bruno Haible  <bruno@clisp.org>
21503
21504         * modules/progname: New file.
21505         * MODULES.html.sh (func_all_modules): Add progname.
21506
21507 2003-08-20  Bruno Haible  <bruno@clisp.org>
21508
21509         * lib/progname.h: New file, from GNU gettext.
21510         * lib/progname.c: New file, from GNU gettext.
21511         * lib/progreloc.c: New file, from GNU gettext.
21512
21513 2003-08-19  Jim Meyering  <jim@meyering.net>
21514
21515         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
21516         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
21517
21518 2003-08-19  Bruno Haible  <bruno@clisp.org>
21519
21520         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
21521         more.
21522
21523 2003-08-19  Bruno Haible  <bruno@clisp.org>
21524
21525         * lib/xstrdup.c: Assume <string.h> exists.
21526
21527 2003-08-18  Paul Eggert  <eggert@twinsun.com>
21528
21529         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
21530         in makefile rules.
21531
21532 2003-08-18  Jim Meyering  <jim@meyering.net>
21533
21534         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
21535         * m4/lib-ld.m4: Likewise.
21536
21537 2003-08-18  Jim Meyering  <jim@meyering.net>
21538
21539         * lib/setenv.h: Indent nested cpp directive.
21540         * lib/vasnprintf.c: Remove trailing blanks.
21541
21542 2003-08-17  Simon Josefsson  <jas@extundo.com>
21543
21544         * modules/xstrndup: New file.
21545         * MODULES.html.sh (func_all_modules): Add xstrndup.
21546
21547 2003-08-17  Simon Josefsson  <jas@extundo.com>
21548
21549         * modules/argp: Fix autoconf macro name. Add more dependencies.
21550
21551 2003-08-17  Simon Josefsson  <jas@extundo.com>
21552
21553         * m4/xstrndup.m4: New file.
21554
21555 2003-08-17  Simon Josefsson  <jas@extundo.com>
21556
21557         * m4/argp.m4: New file.
21558
21559 2003-08-17  Simon Josefsson  <jas@extundo.com>
21560             Bruno Haible  <bruno@clisp.org>
21561
21562         * lib/xstrndup.h: New file.
21563         * lib/xstrndup.c: New file.
21564
21565 2003-08-17  Bruno Haible  <bruno@clisp.org>
21566
21567         * modules/strndup (Files, Include): Add lib/strndup.h.
21568
21569 2003-08-17  Bruno Haible  <bruno@clisp.org>
21570
21571         * modules/euidaccess (Files): Add lib/euidaccess.h.
21572
21573 2003-08-17  Bruno Haible  <bruno@clisp.org>
21574
21575         * lib/strndup.h: New file.
21576
21577 2003-08-17  Bruno Haible  <bruno@clisp.org>
21578
21579         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
21580         like AC_GNU_SOURCE.
21581         * modules/extensions (configure.ac): Comment out the invocation of
21582         gl_USE_SYSTEM_EXTENSIONS.
21583
21584 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21585
21586         Merges from coreutils, etc.
21587         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
21588         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
21589         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
21590         fixing a typo.
21591         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
21592         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
21593
21594 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21595
21596         Document merge from coreutils.
21597         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
21598         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
21599         * modules/utime: Add m4/utimes-null.m4.
21600
21601 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21602
21603         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
21604         space, undoing this 2003-08-12 change:
21605         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
21606
21607 2003-08-16  Paul Eggert  <eggert@twinsun.com>
21608
21609         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
21610         strtoul.c from libc, undoing this 2003-08-12 change:
21611         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
21612
21613 2003-08-16  Jim Meyering  <jim@meyering.net>
21614
21615         Merges from coreutils.
21616         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
21617         prefix.  Adjust cache variables similarly.  Create 500 rather than
21618         just 300 files, to exercise bug on Darwin6.5, too.
21619         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
21620         $missing_dir.
21621         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
21622         AM_SYS_POSIX_TERMIOS.
21623         Reported by mkc@mathdogs.com.
21624         Also change use of $am_cv_sys_posix_termios
21625         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
21626         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
21627         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
21628         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
21629         in /proc/mounts until it finds one with matching device number.  This
21630         is unnecessary when the FILE argument *is* a mount point.  No stat call
21631         is necessary in that case.  So, disable the statvfs-testing code on
21632         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
21633         as RedHat bug# 84846.
21634         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
21635         to 1MB, so as not to render systems with no stack size limit (e.g.,
21636         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
21637         Include <unistd.h>.  On some systems,
21638         it is required for the definition of _SC_PAGESIZE.
21639
21640 2003-08-16  Jim Meyering  <jim@meyering.net>
21641
21642         Merge from coreutils.
21643         * lib/xstrtoimax.c: #else #if -> #elif.
21644         * lib/xstrtoumax.c: Likewise.
21645
21646 2003-08-16  Jim Meyering  <jim@meyering.net>
21647
21648         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
21649         * m4/utimes.m4: Removed.
21650         * m4/utimes-null.m4: Renamed from utimes.m4.
21651
21652         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
21653         to 1MB, so as not to render systems with no stack size limit (e.g.,
21654         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
21655         Include <unistd.h>.  On some systems,
21656         it is required for the definition of _SC_PAGESIZE.
21657
21658 2003-08-16  Jim Meyering  <jim@meyering.net>
21659         and Paul Eggert  <eggert@cs.ucla.edu>
21660
21661         Merges from coreutils, etc.
21662
21663         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
21664         using the latest version from cvs.  This avoids problems with #line
21665         directives using a vendor (Sun) compiler.
21666         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
21667         Don't set GETGROUPS_LIB here; now it's
21668         done via getgroups.m4's wrapper function.
21669         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
21670         rather than just in sh-util/configure.in, so that the
21671         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
21672         same.
21673         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
21674         AC_FUNC_GETLOADAVG where to find getloadavg.c.
21675         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
21676         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
21677         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
21678         Remove code that is now done by the newly-required macros.
21679         Append $(EXEEXT) to DF_PROG.
21680         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
21681         Do not invoke or require the following here,
21682         since prereq.m4 or some gnulib .m4 now does this for us:
21683         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
21684         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
21685         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
21686         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
21687         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
21688         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
21689         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
21690         AC_FUNC_OBSTACK.
21691         Do not replace the following functions, as this is now the job
21692         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
21693         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
21694         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
21695         atexit getpass, strdup, getpagesize.
21696         Replace 'raise'.
21697         Do not check for the following functions, as this is now the job
21698         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
21699         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
21700         setregid.
21701         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
21702         Check for sys/sysctl.h.
21703         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
21704         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
21705         of checking for ssize_t ourselves.
21706
21707         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
21708         Require every macro that gnulib/modules/* suggests for us.
21709         (jm_PREREQ_ADDEXT): New macro.
21710         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
21711         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
21712
21713         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
21714         (gl_PHYSMEM): Use it.
21715         Also check for `table' function.
21716         Check for new headers and functions.
21717         Add check for sys/sysmp.h.
21718         With suggestions from Kaveh Ghazi.
21719         Ignore headers that are present but cannot be compiled.  This
21720         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
21721         C 5.4.
21722
21723 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21724
21725         Document merge from coreutils.
21726         * modules/userspec: Depend on posixver.
21727         * modules/strftime: Depend on tzset.
21728
21729 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21730
21731         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
21732         rather than tab, after '#' in shell-script copyright notices.
21733         Suggested by Bruno Haible.
21734
21735 2003-08-15  Paul Eggert  <eggert@twinsun.com>
21736
21737         * config/srclist-update: Use three spaces, rather than tab, after '#'
21738         in shell-script copyright notices.  Suggested by Bruno Haible.
21739         Remove unnecessary parenthesization in regular expression.
21740
21741 2003-08-15  Jim Meyering  <jim@meyering.net>
21742
21743         Merge from coreutils.
21744         * lib/xgethostname.c: Include <stdlib.h>.
21745         (xghostname): Don't exit for anything other than memory-related
21746         failure; just return NULL.
21747         * lib/userspec.c: Include "posixver.h".
21748         (parse_user_spec): Accept `.' as a separator only
21749         in pre-POSIX-200112 mode.
21750         * lib/strtoimax.c: Use #elif rather than #else #if.
21751         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
21752         Remove function, now that we can rely on a working tzset function.
21753         [!_LIBC]: Ensure that the required autoconf test has been run.
21754         [!defined _NL_CURRENT && HAVE_STRFTIME]:
21755         Use underlying_strftime for %r.
21756         * lib/sha.c: Merge in some clean-up and optimization changes from
21757         glibc.
21758         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
21759         Ensure that it is a multiple of 64.
21760         Rearrange loop exit tests so as to avoid performing an
21761         additional fread after encountering an error or EOF.
21762         * lib/realloc.c: Update copyright date.
21763
21764 2003-08-15  Jim Meyering  <jim@meyering.net>
21765         and Paul Eggert  <eggert@twinsun.com>
21766
21767         Merge from coreutils.
21768         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
21769         member but strut utmpx does not.  Needed for AIX 4.3.3.
21770         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
21771
21772 2003-08-15  Jim Meyering  <jim@meyering.net>
21773         and Paul Eggert  <eggert@cs.ucla.edu>
21774
21775         Merges from coreutils, etc.
21776         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
21777         Require gl_FUNC_TZSET_CLOBBER.
21778         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
21779         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
21780         members.
21781
21782 2003-08-14  Paul Eggert  <eggert@twinsun.com>
21783
21784         Help the merge from coreutils.
21785         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
21786         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
21787         * m4/tzset.m4: Use it too.
21788
21789 2003-08-14  Paul Eggert  <eggert@twinsun.com>
21790
21791         * modules/tzset: New file.
21792
21793 2003-08-14  Jim Meyering  <jim@meyering.net>
21794
21795         Merges from coreutils.
21796         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
21797         variable names, rather than @FNMATCH_H@.
21798         * modules/alloca: Likewise for $(ALLOCA_H).
21799
21800         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
21801         the three copies of the literal target, `fnmatch.h'.
21802         * modules/alloca (alloca.h): Likewise.
21803
21804 2003-08-14  Jim Meyering  <jim@meyering.net>
21805
21806         Merge from coreutils.
21807         * m4/tzset.m4: New file.
21808         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
21809         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
21810         otherwise, AIX 5.1 systems would end up using the latter.
21811         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
21812         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
21813         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
21814         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
21815
21816 2003-08-14  Jim Meyering  <jim@meyering.net>
21817
21818         Merge from coreutils.
21819         * lib/obstack.h: Whitespace changes.
21820         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
21821         and xcalloc return values.
21822         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
21823         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
21824         hang on OSF/1 5.1 for DIR on both local and remote file systems.
21825         Reported by (and fix confirmed by) Nelson H. F. Beebe.
21826         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
21827         error from mntctl.
21828         Use mntctl's return value to drive the entry-processing loop, since
21829         we can't rely on the value of the vmt_length member in the last
21830         entry.  On some systems doing so could result in exhausting
21831         virtual memory.  Based in part on a patch from Mike Jetzer.
21832
21833 2003-08-14  Jim Meyering  <jim@meyering.net>
21834         and Paul Eggert  <eggert@twinsun.com>
21835
21836         Merges from coreutils, plus other fixes.
21837         * lib/physmem.c: Merge in portability changes from gcc/libiberty
21838         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
21839         for credits and details.  Thanks to Kaveh Ghazi for helping
21840         to keep these files in sync.
21841         (ARRAY_SIZE): Define it.
21842         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
21843         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
21844         (memcasecmp): Don't assume size_t fits in unsigned int.
21845         Remove casts and duplicate code.
21846         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
21847         (memcpy): Remove definition.
21848         Merge in some clean-up and optimization changes from glibc.
21849         [BLOCKSIZE]: Move definition to top of file.
21850         Ensure that it is a multiple of 64.
21851         Rearrange loop exit tests so as to avoid performing an
21852         additional fread after encountering an error or EOF.
21853         * lib/md5.h (md5_uintptr): Define.
21854         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
21855         return to the initial working directory.  Preserve errno
21856         for caller.
21857         * lib/idcache.c: Include "xalloc.h".
21858         (xmalloc, xrealloc): Remove decls.
21859         (getuser): Remove casts no longer required in C89.
21860         * lib/human.c: Include stdio.h, for sprintf.
21861         * lib/group-member.c: Include "xalloc.h".
21862         (xmalloc, xrealloc): Remove decls.
21863         (get_group_info): Remove casts no longer required in C89.
21864         * lib/getusershell.c (readname): Remove casts no longer required in
21865         C89.
21866         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
21867         * lib/getline.c: Whitespace fix, from coreutils.
21868
21869 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21870
21871         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
21872         Check for isascii.
21873
21874         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
21875         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
21876         Undo previous (whitespace-only) change.
21877
21878 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21879
21880         * lib/exclude.c: Include <ctype.h>
21881         (IN_CTYPE_DOMAIN): New macro.
21882         (is_space): New fn.
21883         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
21884         and empty lines.
21885
21886         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
21887         Undo previous (whitespace-only) change.
21888
21889 2003-08-13  Paul Eggert  <eggert@twinsun.com>
21890
21891         * config/srclist-update: Change update back to the old behavior,
21892         leaving whitespace alone.  Use one 'sed' command rather than a
21893         pipeline.
21894         (fixlicense): Now a variable, not a function.
21895         (remove_trailing_blanks): Remove.
21896         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
21897         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
21898         Undo previous (whitespace-only) change.
21899
21900 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21901
21902         Merge from coreutils.
21903         * modules/euidaccess: Add lib_SOURCES, include for new
21904         file euidaccess.h
21905
21906 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21907
21908         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
21909         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
21910         Normalize leading white space and remove trailing white space.
21911
21912         Merge from coreutils
21913         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
21914
21915         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
21916         0.12.1.  These files are now being upgraded automatically by
21917         ../config/srclist-update.
21918
21919 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21920
21921         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
21922         Normalize leading white space and remove trailing white space.
21923         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
21924         notice, as per ../config/srclist-update.
21925
21926         Merge from coreutils.
21927         * lib/euidaccess.h: New file.
21928         * lib/euidaccess.c: Include it.
21929         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
21930         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
21931         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
21932
21933 2003-08-12  Paul Eggert  <eggert@twinsun.com>
21934
21935         * config/srclist-update: Add copyright notice.
21936         (remove_id_lines, remove_trailing_blanks): New constants.
21937         (fixfile): Use them to normalize spacing a bit in copied files.
21938         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
21939         Normalize leading white space and remove trailing white space.
21940
21941         * config/texinfo.tex: Sync with texinfo.
21942
21943         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
21944         strtoul.c from libc, to merge coreutils whitespace changes.
21945
21946         * config/srclist.txt: Get the following m4 files from gettext:
21947         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
21948         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
21949         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
21950         wint_t.m4.
21951
21952 2003-08-12  Karl Berry  <karl@gnu.org>
21953
21954         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
21955         been made.
21956
21957 2003-08-11  Paul Eggert  <eggert@twinsun.com>
21958
21959         * modules/gnu-source, m4/gnu-source.m4:
21960         Remove; we're assuming Autoconf 2.54 or later now.
21961         Suggested by Bruno Haible.
21962         * MODULES.html.sh (func_all_modules): Remove gnu-source.
21963
21964 2003-08-11  Bruno Haible  <bruno@clisp.org>
21965
21966         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
21967
21968 2003-08-11  Bruno Haible  <bruno@clisp.org>
21969
21970         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
21971         (vasnprintf): Use it instead of wcslen.
21972
21973 2003-08-11  Bruno Haible  <bruno@clisp.org>
21974
21975         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
21976         value to ensure that _Bool promotes to int. Use #define for _Bool when
21977         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
21978
21979 2003-08-10  Karl Berry  <karl@gnu.org>
21980
21981         * lib/regex.h: update from libc (whitespace fix).
21982
21983 2003-08-09  Paul Eggert  <eggert@twinsun.com>
21984
21985         Merge some files from coreutils.  These changes were
21986         originally made by Jim Meyering.
21987         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
21988         many older Unixes require this.
21989         * lib/alloca.c (alloca): Remove cast to argument of free;
21990         no longer needed in C89.
21991         * lib/alloca_.h, regex.h: Fix white space to match
21992         what GNU indent does.
21993
21994 2003-08-09  Paul Eggert  <eggert@twinsun.com>
21995
21996         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
21997         apparently Emacs's Unicode mode got confused before my 2003-08-05
21998         checkin.
21999
22000 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22001
22002         * m4/extensions.m4: New file.
22003         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
22004         Require gl_USE_SYSTEM_EXTENSIONS.
22005         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
22006         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
22007
22008 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22009
22010         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
22011         * modules/extensions, modules/gnu-source: New files.
22012         * modules/timespec, modules/unlocked-io: Depend on extensions.
22013
22014 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22015
22016         * modules/restrict: New file.
22017         * MODULES.html.sh (func_all_modules): Add restrict.
22018         * modules/regex: Depend on restrict.
22019
22020 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22021
22022         * m4/restrict.m4: New file.
22023         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
22024
22025 2003-08-07  Bruno Haible  <bruno@clisp.org>
22026
22027         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
22028         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
22029
22030 2003-08-07  Bruno Haible  <bruno@clisp.org>
22031
22032         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
22033         makes the module 'getndelim2' compatible with the module 'getline'.
22034
22035 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22036
22037         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
22038         byte with "\201" to avoid glitches when editing that source file
22039         with multi-gnome-terminal.
22040
22041 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22042
22043         * lib/bumpalloc.h: Remove.
22044
22045 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22046
22047         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
22048         * modules/bumpalloc: Remove.
22049
22050 2003-08-04  Paul Eggert  <eggert@twinsun.com>
22051
22052         * lib/getloadavg.c: Change copyright notice and spacing to conform to
22053         GNU coding style.
22054
22055         Merge from coreutils.
22056         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
22057         1. From glibc.
22058         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
22059         from Karl Berry, implemented by Jim Meyering.
22060         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
22061         from Dmitry V. Levin.
22062         Remove anachronistic cast of xrealloc.
22063         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
22064         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
22065         type. Otherwise, it wouldn't compile with at least /bin/cc on
22066         ymp-cray-unicos9.0.2.X.
22067         Combine two mostly-identical uses of alloca into one.
22068         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
22069
22070 2003-08-04  Dave Love  <d.love@dl.ac.uk>
22071
22072         [From Emacs.]
22073
22074         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
22075         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
22076         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
22077         obsolete NLIST_NAME_UNION.
22078         [__GNU__]: Undef BSD and FSCALE.
22079         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
22080
22081 2003-08-03  Paul Eggert  <eggert@twinsun.com>
22082
22083         * lib/stdbool_.h (_Bool): Make it signed char, instead of
22084         an enum type, so that it's guaranteed to promote to int.  See:
22085         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
22086
22087 2003-08-03  Karl Berry  <karl@gnu.org>
22088
22089         * config/depcomp: update from automake.
22090
22091 2003-07-31  Paul Eggert  <eggert@twinsun.com>
22092
22093         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
22094         (strerror): Don't assume that a printable int fits in 14 bytes.
22095
22096 2003-07-31  Bruno Haible  <bruno@clisp.org>
22097
22098         * modules/getpass-gnu: New file.
22099         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
22100
22101 2003-07-31  Bruno Haible  <bruno@clisp.org>
22102
22103         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
22104
22105 2003-07-24  Karl Berry  <karl@gnu.org>
22106
22107         * config/missing: update from automake.
22108
22109 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
22110             Bruno Haible  <bruno@clisp.org>
22111
22112         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
22113         * lib/getline.c (getline, getdelim): Likewise.
22114         Remove _GNU_SOURCE define; now it's defined in config.h through
22115         m4/getline.m4.
22116
22117 2003-07-23  Karl Berry  <karl@gnu.org>
22118
22119         * config/config.sub: update from prep.
22120
22121 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22122
22123         * modules/xalloc (Depends-on): Add exitfail.
22124         * modules/xmemcoll: Likewise.
22125
22126 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22127
22128         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
22129         over-parenthesization in macros.
22130
22131         Sync with coreutils.
22132
22133         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
22134         required by C99.
22135
22136         Use `exit_failure' for xalloc and xmemcoll instead of their own
22137         private exit-failure variables.
22138         * lib/xalloc.h (xalloc_exit_failure): Remove.
22139         * lib/xmalloc.c: Likewise.  Include exitfail.h.
22140         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
22141         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
22142         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
22143         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
22144
22145 2003-07-20  Jim Meyering  <jim@meyering.net>
22146
22147         * modules/closeout (Depends-on): Add exitfail.
22148         Suggestion from Bruno Haible.
22149
22150 2003-07-19  Karl Berry  <karl@gnu.org>
22151
22152         * config/config.sub: update from prep.
22153
22154 2003-07-18  Paul Eggert  <eggert@twinsun.com>
22155
22156         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
22157         Remove.
22158         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
22159         to test that it can stand by itself.  Include "exitfail.h".
22160         Clients should set exit_failure instead.
22161         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
22162
22163 2003-07-18  Bruno Haible  <bruno@clisp.org>
22164
22165         * modules/getndelim2: New file.
22166         * modules/getline: Share files with module getndelim2.
22167         * modules/getnline: Depend on getndelim2 instead of sharing files with
22168         it. Add getnline.c to lib_SOURCES.
22169         * MODULES.html.sh (func_all_modules): Add getndelim2.
22170
22171 2003-07-18  Bruno Haible  <bruno@clisp.org>
22172
22173         * m4/getndelim2.m4: New file.
22174         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
22175         invoke gl_PREREQ_GETNDELIM2.
22176         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
22177         gl_PREREQ_GETNDELIM2.
22178         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
22179         gl_GETNDELIM2.
22180
22181 2003-07-18  Bruno Haible  <bruno@clisp.org>
22182
22183         * lib/getndelim2.h: New file.
22184         * lib/getndelim2.c: Make into a module of its own. Include config.h,
22185         getndelim2.h.
22186         (getndelim2): Make non-static. Change return type to ssize_t.
22187         * lib/getline.h: Change argument names.
22188         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
22189         * lib/getnline.c: Include getndelim2.h.
22190
22191 2003-07-18  Andreas Schwab  <schwab@suse.de>
22192
22193         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
22194
22195 2003-07-17  Karl Berry  <karl@gnu.org>
22196
22197         * config/config.sub: update from prep.
22198
22199 2003-07-17  Bruno Haible  <bruno@clisp.org>
22200
22201         * modules/getnline: New file.
22202         * modules/getline: Add lib/getndelim2.c to source file list.
22203         * MODULES.html.sh (func_all_modules): Add getnline.
22204
22205 2003-07-17  Bruno Haible  <bruno@clisp.org>
22206
22207         * m4/getnline.m4: New file.
22208
22209 2003-07-17  Bruno Haible  <bruno@clisp.org>
22210
22211         * m4/Makefile.am.in: Remove file.
22212         * m4/Makefile.am: Remove file.
22213         * m4/Makefile.in: Remove file.
22214
22215 2003-07-17  Bruno Haible  <bruno@clisp.org>
22216
22217         * lib/getnline.h: New file.
22218         * lib/getnline.c: New file.
22219         * lib/getndelim2.c: New file, extracted from getline.c.
22220         (getndelim2): Renamed from getdelim2, with added nmax argument.
22221         * lib/getline.c: Include getndelim2.c.
22222         (getdelim2): Moved out to getndelim2.c.
22223         (getline, getdelim): Update.
22224
22225 2003-07-17  Bruno Haible  <bruno@clisp.org>
22226
22227         * lib/Makefile.am: Remove file.
22228         * lib/Makefile.in: Remove file.
22229
22230 2003-07-17  Bruno Haible  <bruno@clisp.org>
22231
22232         * configure.in: Remove file.
22233         * Makefile.in: Remove file.
22234
22235 2003-07-17  Bruno Haible  <bruno@clisp.org>
22236
22237         * MODULES.html.sh: Put the </BODY> right before </HTML>.
22238
22239 2003-07-16  Karl Berry  <karl@gnu.org>
22240
22241         * config/srclist-update: was running fixlicense twice, which caused
22242                 texinfo.tex to be nullified for some reason.  Simplify,
22243                 $gplsrc is no longer needed as far as I can see?
22244
22245 2003-07-16  Jim Meyering  <jim@meyering.net>
22246
22247         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
22248
22249 2003-07-15  Paul Eggert  <eggert@twinsun.com>
22250
22251         * config/srclist.txt: Get the following files from gettext-runtime/intl
22252         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
22253         ref-del.sin.  From Bruno Haible.
22254         * config/srclist-update (fixfile): Change grep pattern again, since the
22255         previous fix didn't work (there was another trailing $).  Use
22256         '[$]' to escape the $s.
22257
22258 2003-07-15  Karl Berry  <karl@gnu.org>
22259
22260         * lib/vasnprintf.c: update from gettext.
22261
22262 2003-07-15  Karl Berry  <karl@gnu.org>
22263
22264         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
22265         gets expanded when surrounded by '$'.
22266
22267 2003-07-15  Jim Meyering  <jim@meyering.net>
22268
22269         * modules/save-cwd: Don't depend on error.  From Derek Price.
22270
22271 2003-07-15  Jim Meyering  <jim@meyering.net>
22272
22273         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
22274
22275 2003-07-14  Simon Josefsson  <jas@extundo.com>
22276
22277         * modules/mempcpy: New file.
22278         * MODULES.html.sh (func_all_modules): Add mempcpy.
22279
22280 2003-07-14  Simon Josefsson  <jas@extundo.com>
22281
22282         * m4/mempcpy.m4: New file.
22283
22284 2003-07-14  Simon Josefsson  <jas@extundo.com>
22285
22286         * lib/mempcpy.h: New file.
22287         * lib/mempcpy.c: New file.
22288
22289 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22290
22291         * modules/getdate, modules/posixtm: Depend on mktime.
22292
22293 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22294
22295         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
22296         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
22297         unicodeio.c, unicodeio.h, unlocked-io.h:
22298         Switch from LGPL to GPL.
22299
22300 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22301
22302         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
22303         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
22304         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
22305         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
22306         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
22307         updated automatically by ../config/srclist-update.  This changes
22308         their license from LPGL to GPL.
22309
22310 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22311
22312         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
22313         assumed to refer to the root of the most recent stable gettext version.
22314         * config/srclistvars.sh: Add defaults for eggert.
22315         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
22316         Match "This program" as well as "The program".  This is needed
22317         for gettext.
22318
22319 2003-07-14  Jim Meyering  <jim@meyering.net>
22320
22321         Don't emit diagnostics.  Let callers do that.
22322         * lib/save-cwd.c: Don't include "error.h".
22323         (save_cwd): Don't call error.  Ensure that errno is valid
22324         when returning nonzero.
22325
22326         * lib/save-cwd.h (restore_cwd): Update prototype.
22327         * lib/save-cwd.c (restore_cwd): Remove two parameters.
22328         Simplify.  Don't call error upon failure.  Let callers do that.
22329         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
22330         when auditing is enabled.  But don't bother updating the #if.
22331
22332 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
22333
22334         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
22335         it breaks C++ compilation.
22336         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
22337
22338 2003-07-10  Simon Josefsson  <jas@extundo.com>
22339
22340         * modules/strchrnul (Makefile.am): Add strchrnul.h.
22341
22342 2003-07-10  Jim Meyering  <jim@meyering.net>
22343
22344         * m4/clock_time.m4: Remove trailing blank.
22345         * m4/intmax_t.m4: Likewise.
22346
22347 2003-07-10  Jim Meyering  <jim@meyering.net>
22348
22349         * lib/vasnprintf.c: Remove trailing blanks.
22350         Make cpp indentation consistent.
22351
22352 2003-07-09  Paul Eggert  <eggert@twinsun.com>
22353
22354         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
22355         posixver.c, strftime.c, strnlen.c, strverscmp.c:
22356         Switch from LGPL to GPL.
22357
22358 2003-07-09  Paul Eggert  <eggert@twinsun.com>
22359
22360         * config/srclist.txt: Sort sublists.  Add
22361         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
22362         that differ from gnulib for one reason or another; we'd like this list
22363         to be smaller but for now let's document what we have.
22364
22365 2003-07-08  Paul Eggert  <eggert@twinsun.com>
22366
22367         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
22368         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
22369         and sweeter "eval x=$x".
22370         * config/srclist.txt: Get lib/argp* from glibc.
22371
22372 2003-07-07  Paul Eggert  <eggert@twinsun.com>
22373
22374         * lib/mktime.c: Fix some boundary cases and remove need for floating
22375         point.
22376
22377         Issue a compile-time diagnostic if time_t is floating point, or if
22378         two's complement arithmetic is not in effect, or if arithmetic
22379         right shift does not propagate the sign.  These assumptions were
22380         all in the original code but they weren't checked.
22381
22382         (TIME_T_MIDPOINT, verify): New macros.
22383         (__isleap): Remove; it has integer overflow problems.
22384         (leapyear): New function, without those problems.
22385         (ydhms_tm_diff): Remove; splitting into two parts.
22386         (ydhms_diff): New function, containing the arithmetic part of
22387         the old ydhms_tm_diff function.  Issue a compile-time
22388         diagnostic if we are not using C99 integer division.
22389         Avoid casts when possible.
22390         (guess_time_tm): New function, containing the checking part of
22391         the old ydhms_tm_diff function.  Return the new value, rather than
22392         the difference between it and the old.  Accept a new argument T
22393         so that *T specifies the old value.  Check for overflow in the result.
22394
22395         (__mktime_internal): Use a time_t offset, not a long int offset.
22396         This undoes the 2003-06-04 change, which is no longer needed now
22397         that we have better overflow checking.
22398         (localtime_offset): Likewise.
22399
22400         (__mktime_internal): Avoid harmful overflow on hosts where time_t
22401         and long are 64-bit but int is only 32-bit.
22402         (ydhms_diff): Use long int to store year1 and yday1.
22403         Issue a compile-time diagnostic if long int is not wide enough.
22404
22405         (__mktime_internal): Use long int to store adjusted year and yday.
22406         Use plain C rather than preprocessor commands, if that doesn't
22407         affect efficiency.
22408         Check for overflow (and try to repair) after each probe
22409         rather than checking only at the very end.  This avoids some bugs
22410         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
22411         does not equal GMT offset at maximum time).
22412         Use integer to check for overflow rather than floating point; this
22413         is more portable to non-IEEE hosts, and is a tad faster.
22414         When we detect that we are oscillating between two values,
22415         don't check whether tm_isdst has the requested value, since
22416         we already know the answer.  When tm_isdst has the wrong value,
22417         use a different heuristic to find the right one, based on the
22418         extreme values actually observed in practice in tz2003a,
22419         rather than the (overly optimistic) "previous 3 calendar quarters".
22420
22421         (not_equal_tm, print_tm, check_result): Use "const T" rather than
22422         "T const" to accommodate glibc style.
22423         (check_result): Use less-confusing report format.  "long" -> "long int.
22424         (main): Likewise.
22425         Don't loop if the iteration overflows time_t.
22426         Allow a negative step in the iteration.
22427
22428 2003-07-06  Karl Berry  <karl@gnu.org>
22429
22430         * config/depcomp: update from automake.
22431         * config/config.sub: update from prep.
22432
22433 2003-07-03  Karl Berry  <karl@gnu.org>
22434
22435         * config/config.guess: update from prep.
22436
22437 2003-07-01  Paul Eggert  <eggert@twinsun.com>
22438
22439         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
22440         xreadlink.c now includes it unconditionally.
22441
22442 2003-07-01  Paul Eggert  <eggert@twinsun.com>
22443
22444         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
22445         having it depend on HAVE_SYS_TYPES_H.
22446
22447 2003-07-01  Bruno Haible  <bruno@clisp.org>
22448
22449         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
22450         <sys/types.h> should be sufficient.
22451         Reported by Paul Eggert.
22452
22453 2003-06-26  Karl Berry  <karl@gnu.org>
22454
22455         * config/depcomp: update from automake.
22456
22457 2003-06-26  Bruno Haible  <bruno@clisp.org>
22458
22459         * modules/human: Depend on module stdbool.
22460
22461 2003-06-25  Bruno Haible  <bruno@clisp.org>
22462
22463         * modules/readlink: New file.
22464         * modules/xreadlink: Depend on it.
22465         * MODULES.html.sh (func_all_modules): Add readlink.
22466
22467 2003-06-25  Bruno Haible  <bruno@clisp.org>
22468
22469         * m4/readlink.m4: New file.
22470
22471 2003-06-25  Bruno Haible  <bruno@clisp.org>
22472
22473         * lib/readlink.c: New file.
22474
22475 2003-06-22  Karl Berry  <karl@gnu.org>
22476
22477         * config/srclist.txt: update mkinstalldirs from automake.
22478         * config/mkinstalldirs: update.
22479
22480 2003-06-22  Bruno Haible  <bruno@clisp.org>
22481
22482         Portability to mingw32.
22483         * m4/ssize_t.m4: New file, from GNU gettext.
22484         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
22485         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
22486
22487 2003-06-22  Bruno Haible  <bruno@clisp.org>
22488
22489         * modules/safe-read: Add m4/ssize_t.m4.
22490         * modules/xreadlink: Add m4/ssize_t.m4.
22491
22492 2003-06-20  Bruno Haible  <bruno@clisp.org>
22493
22494         Assume C89, so PARAMS isn't needed.
22495         * lib/unicodeio.h (PARAMS): Remove.
22496         * lib/unicodeio.c: Don't use PARAMS.
22497
22498 2003-06-18  Karl Berry  <karl@gnu.org>
22499
22500         * config/config.{guess,sub}: update from prep.
22501
22502 2003-06-18  Jim Meyering  <jim@meyering.net>
22503
22504         Merge changes from coreutils.
22505         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
22506         Remove explicit declarations of xmalloc and realloc.
22507         Include xalloc.h.
22508         (read_utmp): Remove anachronistic cast of xmalloc.
22509
22510 2003-06-17  Paul Eggert  <eggert@twinsun.com>
22511
22512         Assume C89, so PARAMS isn't needed.
22513         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
22514         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
22515         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
22516         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
22517         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
22518         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
22519         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
22520         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
22521         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
22522         lib/xstrtod.h, lib/xstrtol.h: Likewise.
22523         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
22524         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
22525         no longer needed. Anyway, config.h should always be included before any
22526         other file.
22527
22528 2003-06-11  Simon Josefsson  <jas@extundo.com>
22529
22530         * modules/sysexits: New file.
22531         * MODULES.html.sh (func_all_modules): Add sysexits.
22532
22533 2003-06-11  Simon Josefsson  <jas@extundo.com>
22534
22535         * lib/sysexit_.h: New file.
22536
22537 2003-06-11  Derek Price  <derek@ximbiot.com>
22538
22539         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
22540         necessary.
22541
22542 2003-06-11  Bruno Haible  <bruno@clisp.org>
22543
22544         * m4/sysexits.m4: New file.
22545
22546 2003-06-10  Simon Josefsson  <jas@extundo.com>
22547
22548         * lib/argp.h: New file, from glibc.
22549         * lib/argp-ba.c: New file, from glibc.
22550         * lib/argp-eexst.c: New file, from glibc.
22551         * lib/argp-fmtstream.c: New file, from glibc.
22552         * lib/argp-fmtstream.h: New file, from glibc.
22553         * lib/argp-fs-xinl.c: New file, from glibc.
22554         * lib/argp-help.c: New file, from glibc.
22555         * lib/argp-namefrob.h: New file, from glibc.
22556         * lib/argp-parse.c: New file, from glibc.
22557         * lib/argp-pv.c: New file, from glibc.
22558         * lib/argp-pvh.c: New file, from glibc.
22559         * lib/argp-xinl.c: New file, from glibc.
22560
22561 2003-06-10  Simon Josefsson  <jas@extundo.com>
22562
22563         * modules/strchrnul: New file.
22564
22565 2003-06-10  Simon Josefsson  <jas@extundo.com>
22566
22567         * modules/argp: New file.
22568
22569 2003-06-10  Simon Josefsson  <jas@extundo.com>
22570
22571         * m4/strchrnul.m4: New file.
22572
22573 2003-06-10  Simon Josefsson  <jas@extundo.com>
22574
22575         * lib/strchrnul.h: New file.
22576         * lib/strchrnul.c: New file.
22577
22578 2003-06-10  Bruno Haible  <bruno@clisp.org>
22579
22580         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
22581
22582 2003-06-07  Karl Berry  <karl@gnu.org>
22583
22584         * config/config.{guess,sub}: update from prep.
22585
22586 2003-06-07  Jim Meyering  <jim@meyering.net>
22587
22588         * modules/strtod: Use $(...) notation, not @...@ for
22589         AC_REPLACE'd variables.
22590         * modules/localcharset: Likewise.
22591
22592 2003-06-07  Jim Meyering  <jim@meyering.net>
22593
22594         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
22595         in place of my name in the copyright comment.
22596         Remove definition and uses of __P.
22597
22598         From coreutils.
22599         * lib/stat.c: Don't declare xmalloc explicitly.
22600         Instead, include "xalloc.h".
22601         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
22602         xrealloc, and xcalloc return values.
22603         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
22604         Improve comment.
22605         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
22606
22607 2003-06-07  Bruno Haible  <bruno@clisp.org>
22608
22609         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
22610         avoid AC_CONFIG_LINKS.
22611         * modules/fnmatch (Makefile.am): Use explicit creation rule for
22612         fnmatch.h, to avoid AC_CONFIG_LINKS.
22613         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
22614
22615 2003-06-07  Bruno Haible  <bruno@clisp.org>
22616
22617         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
22618         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
22619         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
22620         directory.
22621         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
22622         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
22623         directory.
22624
22625 2003-06-06  Jim Meyering  <jim@meyering.net>
22626
22627         Merge from coreutils.
22628         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
22629         Consolidate declarations and initializations of *_base* locals.
22630
22631         Merge from coreutils.
22632         This avoids a core dump on systems without GNU putenv,
22633         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
22634         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
22635         (unsetenv): New static function, from GNU libc.
22636         (rpl_putenv): Use it.
22637
22638         * lib/modechange.c: Remove trailing blanks.
22639
22640         Merge from coreutils.
22641         * lib/fsusage.c: Remove declaration of statfs.
22642         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
22643
22644         * lib/posixtm.c: Include <stdbool.h> unconditionally.
22645
22646 2003-06-06  Jim Meyering  <jim@meyering.net>
22647
22648         * lib/stdbool_.h: Renamed from stdbool.h.in.
22649
22650 2003-06-06  Jim Meyering  <jim@meyering.net>
22651             Bruno Haible  <bruno@clisp.org>
22652
22653         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
22654         Adjust Makefile.am snippet not to redirect directly to target.
22655         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
22656
22657 2003-06-05  Paul Eggert  <eggert@twinsun.com>
22658
22659         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
22660         mismatch, look in future quarters as well as past.  This fixes a
22661         bug when processing fall-backwards gaps immediately after a long
22662         period of daylight-saving time.
22663
22664         * lib/mktime.c: Assume freestanding C89 or better.
22665         (HAVE_LIMITS_H): Remove.  Assume it's 1.
22666         (__P): Remove; not used.
22667         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
22668         (mktime, not_equal_tm, print_tm, check_result,
22669         main): Use prototypes.  Use const * where appropriate.
22670         (main): Fix typo in testing code that uncovered by above changes.
22671         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
22672
22673 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22674
22675         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
22676         locale.h, localeconv.  This merges changes from coreutils.
22677
22678         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
22679         It can be removed after the next Autoconf is released.
22680         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
22681         needed.
22682
22683 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22684
22685         * lib/mktime.c: Fix Debian bug 177940
22686         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
22687         (localtime_offset): Now long int, not time_t, because we want it
22688         to be guaranteed to be signed.  All uses changed.
22689         (__mktime_internal): If overflow would occur when adding offset,
22690         don't add it.
22691
22692         Merge 'human' changes from coreutils.  Rewrite to support
22693         locale-specific notations like thousands separators.
22694         * lib/human.c: Simplify authorship notice.
22695         Include human.h immediately after config.h.
22696         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
22697         <limits.h>: Do not include, since human.h does.
22698         (SIZE_MAX, UINTMAX_MAX): New macros.
22699         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
22700         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
22701         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
22702         (power_letter): Renamed from suffixes.
22703         (generate_suffix_backwards): Remove.
22704         (adjust_value): Now takes int style (because of human.h changes)
22705         and long double value (for greater precision on some platforms).
22706         (group_number): New function.
22707         (human_readable): Use it.  Use integer options, not enum.
22708         Put the options before the sizes in the arg list.
22709         Support all the new options.
22710         The old human_readable function has been removed;
22711         use inttostr.h instead.
22712         (human_readable, default_block_size, humblock):
22713         Use uintmax_t, not int, for block sizes.
22714         (human_readable_inexact, block_size_types): Remove.
22715         (block_size_opts): New constant.
22716         (human_options): Renamed from human_block_size, with new signature
22717         that allows block sizes up to UINTMAX_MAX.  All callers changed.
22718         * lib/human.h: Add copyright and authorship notice.
22719         Include <limits.h> and <stdbool.h> unconditionally.
22720         (PARAMS): Remove.  All uses removed.
22721         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
22722         (enum human_inexact_style): Remove tag; now a nameless enum.
22723         (human_floor, human_ceiling, human_round_to_even): Now have
22724         values 2, 0, 1 rather than -1, 1, 0.
22725         (human_group_digits, human_suppress_point_zero, human_autoscale,
22726         human_base_1024, human_SI, human_B): New constants.
22727         (human_readable_inexact, human_block_size): Remove.
22728         (human_readable): Size args are now uintmax_t, not int.
22729         (human_options): New decl.
22730
22731         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
22732         unnecessary now that we assume C89 or better.  This change
22733         imported from coreutils.
22734
22735         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
22736         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
22737         in the 2003-05-30 sync from glibc.
22738
22739         .h files should stand alone, but we shouldn't include <sys/types.h>
22740         if we can get away with just <stddef.h>.
22741
22742         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
22743         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
22744         rather than <sys/types.h>, as we merely need size_t.
22745         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
22746         to get size_t.
22747         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
22748         Include <stdio.h>, to get FILE.
22749         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
22750         memcasecmp.h has included <stddef.h> and all we need is size_t.
22751         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
22752         our interface, instead of including <sys/types.h>
22753
22754 2003-06-04  Paul Eggert  <eggert@twinsun.com>
22755
22756         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
22757         now, as glibc mktime is buggy on non-glibc systems.
22758
22759 2003-06-03  Karl Berry  <karl@gnu.org>
22760
22761         * config/config.sub: update from prep.
22762
22763 2003-06-02  Paul Eggert  <eggert@twinsun.com>
22764
22765         [from coreutils]
22766         Fix some minor time-related bugs with POSIX time arguments.
22767         Some valid time stamps were being rejected (notably -1, and
22768         time stamps before 1900 on 64-bit hosts).  And some invalid
22769         time stamps were being accepted, e.g. September 31.
22770
22771         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
22772         that we can return (time_t) -1 successfully.
22773         * lib/posixtm.c: Likewise.
22774         [HAVE_STDBOOL_H]: Include <stdbool.h>.
22775         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
22776         (t): Remove static var.
22777         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
22778         of static var.  All uses changed.
22779         (year): Do not reject years before 1900; they can occur with
22780         64-bit time_t.
22781         (posix_time_parse): Do not check for out-of-range components;
22782         that is now the caller's responsibility, since our checks were
22783         only approximations.
22784         (posixtime): Use mktime to check for out-of-range components,
22785         since it knows them exactly.
22786         If mktime returns (time_t) -1, check whether an error actually occurred
22787         by invoking localtime on -1.
22788         (main) [TEST_POSIXTIME]: Check for input data errors, and report
22789         posixtime failures better.
22790         Improve the test data (in comments only).
22791
22792 2003-06-02  Karl Berry  <karl@gnu.org>
22793
22794         * config/mkinstalldirs (version): new variable.
22795         (--version): new option.
22796         (usage): improve message.
22797
22798 2003-05-30  Karl Berry  <karl@gnu.org>
22799
22800         * lib/mktime.c: update from libc.
22801
22802 2003-05-30  Bruno Haible  <bruno@clisp.org>
22803
22804         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
22805         * config/config.rpath: Upgrade to gettext-0.12.1.
22806
22807 2003-05-30  Bruno Haible  <bruno@clisp.org>
22808
22809         * m4/gettext.m4: Upgrade to gettext-0.12.1.
22810         * m4/nls.m4: New file, from gettext-0.12.1.
22811         * m4/po.m4: New file, from gettext-0.12.1.
22812         * m4/progtest.m4: Upgrade to gettext-0.12.1.
22813
22814 2003-05-30  Bruno Haible  <bruno@clisp.org>
22815
22816         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
22817         * lib/localcharset.h: Likewise.
22818         * lib/localcharset.c: Likewise.
22819
22820 2003-05-29  Karl Berry  <karl@gnu.org>
22821
22822         * config/config.rpath: update from gettext.
22823
22824 2003-05-28  Paul Eggert  <eggert@twinsun.com>
22825
22826         Assume the headers required for C89 freestanding compilers.
22827         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
22828         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
22829         * m4/human.m4 (gl_HUMAN): Likewise.
22830         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
22831         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
22832         * m4/userspec.m4 (gl_USERSPEC): Likewise.
22833         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
22834         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
22835         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
22836
22837 2003-05-28  Paul Eggert  <eggert@twinsun.com>
22838
22839         Assume the headers required for C89 freestanding compilers.
22840         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
22841         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
22842         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
22843         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
22844         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
22845         define, since <limits.h> is guaranteed to do that.
22846         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
22847         * lib/exclude.c: Include <stdbool.h> unconditionally.
22848         * lib/tempname.c: Include <stddef.h> unconditionally.
22849         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
22850         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
22851         <stddef.h> does that.
22852         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
22853         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
22854         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
22855         needed.
22856         * lib/xstrtol.c: Likewise.
22857         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
22858         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
22859
22860         * lib/addext.c (addext): Use assignment rather than cast, to avoid
22861         warnings on some platforms.
22862
22863         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
22864         arbitrarily.
22865
22866 2003-05-26  Jim Meyering  <jim@meyering.net>
22867
22868         Merge in a change from coreutils:
22869         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
22870         that is guaranteed to be `no'.  Use `no_such_member' to indicate
22871         that condition, rather than `-1' which is slightly misleading.
22872         Change the name of the cache variable to have the gl_ prefix.
22873         Prompted by a patch from Richard Dawe for DJGPP.
22874
22875 2003-05-24  Karl Berry  <karl@gnu.org>
22876
22877         * config/config.guess: update from prep.
22878
22879 2003-05-22  Karl Berry  <karl@gnu.org>
22880
22881         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
22882
22883 2003-05-20  Karl Berry  <karl@gnu.org>
22884
22885         * config/config.guess: update from prep.
22886
22887 2003-05-18  Karl Berry  <karl@gnu.org>
22888
22889         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
22890         might actually be set by the user.
22891
22892         * config/depcomp, install-sh, mdate-sh: update from automake.
22893
22894 2003-05-17  Bruno Haible  <bruno@clisp.org>
22895
22896         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
22897         invalid expansion for AC_EGREP_CPP.
22898         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
22899         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
22900         Suggested by Akim Demaille <akim@epita.fr> in
22901         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
22902
22903 2003-05-12  Jim Meyering  <jim@meyering.net>
22904
22905         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
22906         the space-padded-by-default conversion specifiers, %e, %k, %l.
22907
22908 2003-05-12  Bruno Haible  <bruno@clisp.org>
22909
22910         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
22911         the string is longer than 4 KB.
22912
22913 2003-05-11  Karl Berry  <karl@gnu.org>
22914
22915         * config/config.{guess,sub}: update from prep.
22916
22917 2003-05-09  Bruno Haible  <bruno@clisp.org>
22918
22919         * modules/error: Add m4/strerror_r.m4 to file list.
22920
22921 2003-05-03  Bruno Haible  <bruno@clisp.org>
22922
22923         Upgrade to Unicode-4.0.
22924         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
22925         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
22926         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
22927         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
22928         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
22929         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
22930         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
22931         Change width of U+E0100..U+E01EF from 1 to 0.
22932
22933 2003-04-25  Jim Meyering  <jim@meyering.net>
22934
22935         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
22936         of type size_t, not int.
22937
22938 2003-04-25  Bruno Haible  <bruno@clisp.org>
22939
22940         * lib/copy-file.c: Include <stddef.h>, for size_t.
22941
22942 2003-04-21  Paul Eggert  <eggert@twinsun.com>
22943
22944         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
22945         code which expansion is under static control.  Patch imported from
22946         Akim Demaille's patch to Bison; see
22947         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
22948
22949 2003-04-14  Bruno Haible  <bruno@clisp.org>
22950
22951         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
22952
22953 2003-04-11  Jim Meyering  <jim@meyering.net>
22954
22955         Merge changes from Coreutils.
22956
22957         2003-03-22  Jim Meyering  <jim@meyering.net>
22958
22959         * lib/strftime.c (widen): Cast alloca return value to proper type.
22960
22961         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
22962
22963         From GNU libc.
22964         * lib/strftime.c (my_strftime): Handle very large width
22965         specifications for numeric values correctly.  Improve checks for
22966         overflow.
22967
22968         2003-01-19  Jim Meyering  <jim@meyering.net>
22969
22970         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
22971         definitions.
22972         (nl_get_alt_digit) [! defined my_strftime]: Define.
22973         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
22974         _nl_get_alt_digit and _nl_get_walt_digit.
22975
22976         * lib/strftime.c (my_strftime): Merge in locale-related changes from
22977         libc. These changes have no effect outside of _LIBC.
22978
22979 2003-04-10  Bruno Haible  <bruno@clisp.org>
22980
22981         * modules/findprog: New file.
22982         * MODULES.html.sh (func_all_modules): Add it.
22983
22984 2003-04-10  Bruno Haible  <bruno@clisp.org>
22985
22986         * m4/findprog.m4: New file.
22987         * m4/eaccess.m4: New file.
22988
22989 2003-04-10  Bruno Haible  <bruno@clisp.org>
22990
22991         * lib/findprog.h: New file, from GNU gettext.
22992         * lib/findprog.c: New file, from GNU gettext.
22993
22994 2003-04-05  Jim Meyering  <jim@meyering.net>
22995
22996         Merge changes from Coreutils.
22997
22998         * lib/exclude.h (PARAMS): Remove definition and uses.
22999         * lib/exclude.c: Remove uses of `PARAMS'.
23000
23001         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
23002         Add test-cases for DOS filenames. Declare program_name.
23003         (main): Set up program_name.  Patch by Rich Dawe.
23004
23005         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
23006         error from mntctl.
23007         Use mntctl's return value to drive the entry-processing loop, since
23008         we can't rely on the value of the vmt_length member in the last
23009         entry.  On some systems doing so could result in exhausting
23010         virtual memory.  Based in part on a patch from Mike Jetzer.
23011
23012 2003-04-04  Bruno Haible  <bruno@clisp.org>
23013
23014         * modules/linebreak: New file.
23015         * MODULES.html.sh (func_all_modules): Add it.
23016
23017 2003-04-04  Bruno Haible  <bruno@clisp.org>
23018
23019         * m4/linebreak.m4: New file.
23020
23021 2003-04-04  Bruno Haible  <bruno@clisp.org>
23022
23023         * lib/linebreak.h: New file, from GNU gettext.
23024         * lib/linebreak.c: New file, from GNU gettext with slight
23025         modifications.
23026         * lib/lbrkprop.h: New file, from GNU gettext.
23027
23028 2003-04-03  Bruno Haible  <bruno@clisp.org>
23029
23030         * modules/utf8-ucs4: New file.
23031         * modules/utf16-ucs4: New file.
23032         * modules/ucs4-utf8: New file.
23033         * modules/ucs4-utf16: New file.
23034         * MODULES.html.sh (func_all_modules): Add them.
23035
23036 2003-04-03  Bruno Haible  <bruno@clisp.org>
23037
23038         * m4/utf-ucs4.m4: New file.
23039         * m4/ucs4-utf.m4: New file.
23040
23041 2003-04-03  Bruno Haible  <bruno@clisp.org>
23042
23043         * lib/utf8-ucs4.h: New file, from GNU gettext.
23044         * lib/utf16-ucs4.h: New file, from GNU gettext.
23045         * lib/ucs4-utf8.h: New file, from GNU gettext.
23046         * lib/ucs4-utf16.h: New file, from GNU gettext.
23047
23048 2003-04-02  Bruno Haible  <bruno@clisp.org>
23049
23050         * modules/binary-io: New file.
23051         * MODULES.html.sh (func_all_modules): Add it.
23052
23053 2003-04-02  Bruno Haible  <bruno@clisp.org>
23054
23055         * lib/binary-io.h: New file, from GNU gettext.
23056
23057 2003-04-01  Bruno Haible  <bruno@clisp.org>
23058
23059         * modules/pathname: New file.
23060         * MODULES.html.sh (func_all_modules): Add it.
23061
23062 2003-04-01  Bruno Haible  <bruno@clisp.org>
23063
23064         * lib/pathname.h: New file, from GNU gettext.
23065         * lib/concatpath.c: New file, from GNU gettext.
23066
23067 2003-03-30  Bruno Haible  <bruno@clisp.org>
23068
23069         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
23070
23071 2003-03-30  Bruno Haible  <bruno@clisp.org>
23072
23073         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
23074         function chown() doesn't exist.
23075
23076 2003-03-28  Bruno Haible  <bruno@clisp.org>
23077
23078         * modules/copy-file: New file.
23079         * MODULES.html.sh (func_all_modules): Add it.
23080
23081 2003-03-28  Bruno Haible  <bruno@clisp.org>
23082
23083         * m4/copy-file.m4: New file.
23084
23085 2003-03-28  Bruno Haible  <bruno@clisp.org>
23086
23087         * lib/copy-file.h: New file, from GNU gettext.
23088         * lib/copy-file.c: New file, from GNU gettext.
23089
23090 2003-03-18  Jim Meyering  <jim@meyering.net>
23091
23092         * lib/quote.c (quote_n): Fix typo in comment.
23093
23094 2003-03-18  Bruno Haible  <bruno@clisp.org>
23095
23096         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
23097         checking.
23098         * m4/onceonly_2_57.m4: Likewise.
23099
23100 2003-03-17  Bruno Haible  <bruno@clisp.org>
23101
23102         * m4/onceonly.m4: Require autoconf 2.54 or newer.
23103         (m4_quote): Remove macro.
23104         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
23105
23106 2003-03-14  Jim Meyering  <jim@meyering.net>
23107
23108         Merge changes from Coreutils.
23109         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
23110         to be const, in order to avoid warnings.
23111         (obstack_room): Likewise.
23112         (obstack_empty_p): Likewise.
23113
23114 2003-03-14  Bruno Haible  <bruno@clisp.org>
23115
23116         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
23117         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
23118
23119 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23120
23121         Merge changes from Bison.
23122         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
23123         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
23124         when compiling Bison 1.875's `bitset bset = obstack_alloc
23125         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
23126         * lib/hash.c: Include <stdbool.h> unconditionally.
23127
23128 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23129
23130         * m4/onceonly.m4 (m4_quote): New macro.
23131         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
23132         Quote AC_FOREACH variable-expansions properly.
23133
23134 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23135
23136         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
23137
23138 2003-03-09  Paul Eggert  <eggert@twinsun.com>
23139
23140         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
23141         Reported by Bruce Becker; see:
23142         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
23143
23144 2003-03-03  Paul Eggert  <eggert@twinsun.com>
23145             Bruno Haible  <bruno@clisp.org>
23146
23147         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
23148         Reported by John Hughes, see
23149         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
23150
23151 2003-02-20  Bruno Haible  <bruno@clisp.org>
23152
23153         * MODULES.html.sh (func_all_modules): Add poll.
23154
23155 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23156
23157         * modules/poll: New file.
23158
23159 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23160
23161         * lib/poll_.h: New file.
23162         * lib/poll.c: New file.
23163
23164 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23165
23166         * m4/poll.m4: New file.
23167
23168 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23169
23170         * modules/mathl: New file.
23171
23172 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23173
23174         * lib/mathl.h: New file.
23175         * lib/acosl.c: New file.
23176         * lib/asinl.c: New file.
23177         * lib/atanl.c: New file.
23178         * lib/ceill.c: New file.
23179         * lib/cosl.c: New file.
23180         * lib/expl.c: New file.
23181         * lib/floorl.c: New file.
23182         * lib/frexpl.c: New file.
23183         * lib/ldexpl.c: New file.
23184         * lib/logl.c: New file.
23185         * lib/sincosl.c: New file.
23186         * lib/sinl.c: New file.
23187         * lib/sqrtl.c: New file.
23188         * lib/tanl.c: New file.
23189         * lib/trigl.c: New file.
23190         * lib/trigl.h: New file.
23191
23192 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23193
23194         * m4/mathl.m4: New file.
23195
23196 2003-02-18  Bruno Haible  <bruno@clisp.org>
23197
23198         * MODULES.html.sh (func_all_modules): Add mathl.
23199
23200 2003-02-17  Bruno Haible  <bruno@clisp.org>
23201
23202         * modules/mkdtemp: New module.
23203         * MODULES.html.sh (func_all_modules): Add it.
23204
23205 2003-02-17  Bruno Haible  <bruno@clisp.org>
23206
23207         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
23208
23209 2003-02-17  Bruno Haible  <bruno@clisp.org>
23210
23211         * lib/mkdtemp.h: New file, from GNU gettext.
23212         * lib/mkdtemp.c: New file, from GNU gettext.
23213
23214 2003-02-02  Jim Meyering  <jim@meyering.net>
23215
23216         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
23217         e.g. glibc-2.2.93.
23218
23219 2003-01-31  Bruno Haible  <bruno@clisp.org>
23220
23221         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
23222         'rpl_rename'.
23223         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
23224         'rpl_strnlen'.
23225         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
23226         'rpl_strtod'.
23227         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
23228         'rpl_utime'.
23229
23230 2003-01-31  Bruno Haible  <bruno@clisp.org>
23231
23232         * lib/rename.c: #undef rename before defining rpl_rename.
23233         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
23234
23235 2003-01-30  Bruno Haible  <bruno@clisp.org>
23236
23237         * modules/vasnprintf, modules/vasprintf: New modules.
23238         * MODULES.html.sh (func_all_modules): Add them.
23239
23240 2003-01-30  Bruno Haible  <bruno@clisp.org>
23241
23242         * m4/signed.m4: New file, from GNU gettext.
23243         * m4/longdouble.m4: New file, from GNU gettext.
23244         * m4/wchar_t.m4: New file, from GNU gettext.
23245         * m4/wint_t.m4: New file, from GNU gettext.
23246         * m4/vasnprintf.m4: New file.
23247         * m4/vasprintf.m4: New file.
23248
23249 2003-01-30  Bruno Haible  <bruno@clisp.org>
23250
23251         * lib/printf-args.h: New file, from GNU gettext.
23252         * lib/printf-args.c: New file, from GNU gettext.
23253         * lib/printf-parse.h: New file, from GNU gettext.
23254         * lib/printf-parse.c: New file, from GNU gettext.
23255         * lib/vasnprintf.h: New file, from GNU gettext.
23256         * lib/vasnprintf.c: New file, from GNU gettext.
23257         * lib/asnprintf.c: New file, from GNU gettext.
23258         * lib/vasprintf.h: New file, from GNU gettext with modifications.
23259         * lib/vasprintf.c: New file, from GNU gettext.
23260         * lib/asprintf.c: New file, from GNU gettext.
23261
23262 2003-01-29  Bruno Haible  <bruno@clisp.org>
23263
23264         * modules/stpncpy: New module.
23265         * MODULES.html.sh (func_all_modules): Add it.
23266
23267 2003-01-29  Bruno Haible  <bruno@clisp.org>
23268
23269         * m4/stpncpy.m4: New file.
23270
23271 2003-01-29  Bruno Haible  <bruno@clisp.org>
23272
23273         * lib/stpncpy.h: New file, from GNU gettext with modifications.
23274         * lib/stpncpy.c: New file, from GNU gettext with modifications.
23275
23276 2003-01-28  Bruno Haible  <bruno@clisp.org>
23277
23278         * modules/c-ctype: New module.
23279         * MODULES.html.sh (func_all_modules): Add it.
23280
23281 2003-01-28  Bruno Haible  <bruno@clisp.org>
23282
23283         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
23284         Paul Eggert.
23285         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
23286         Paul Eggert.
23287
23288 2003-01-27  Bruno Haible  <bruno@clisp.org>
23289
23290         * modules/xsetenv: New module.
23291         * MODULES.html.sh (func_all_modules): Add it.
23292
23293 2003-01-27  Bruno Haible  <bruno@clisp.org>
23294
23295         * lib/xsetenv.h: New file, from GNU gettext.
23296         * lib/xsetenv.c: New file, from GNU gettext.
23297
23298 2003-01-23  Jim Meyering  <jim@meyering.net>
23299
23300         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
23301         from working on systems without dirfd (at least Irix and OSF1/Tru64).
23302
23303 2003-01-23  Bruno Haible  <bruno@clisp.org>
23304
23305         * modules/minmax: New module.
23306         * MODULES.html.sh (func_all_modules): Add it.
23307
23308 2003-01-23  Bruno Haible  <bruno@clisp.org>
23309
23310         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
23311         Eggert.
23312
23313 2003-01-22  Bruno Haible  <bruno@clisp.org>
23314
23315         * modules/exit: New module.
23316         * MODULES.html.sh (func_all_modules): Add it.
23317
23318 2003-01-22  Bruno Haible  <bruno@clisp.org>
23319
23320         * lib/exit.h: New file, from GNU gettext.
23321
23322 2003-01-19  Bruno Haible  <bruno@clisp.org>
23323
23324         * gnulib-tool: Recognize option --extract-maintainer.
23325         (func_get_maintainer): New function.
23326         * modules/*: Add Maintainer entry.
23327
23328 2003-01-16  Jim Meyering  <jim@meyering.net>
23329
23330         * m4/regex.m4: The `regex' struct is both input and output.
23331         Initialize it before each use.  Patch by Tim Waugh.
23332
23333 2003-01-16  Bruno Haible  <bruno@clisp.org>
23334
23335         * MODULES.html.sh: Add a table of contents. Add the module name as
23336         leftmost column. Add hyperlinks.
23337
23338 2003-01-15  Bruno Haible  <bruno@clisp.org>
23339
23340         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
23341
23342 2003-01-15  Bruno Haible  <bruno@clisp.org>
23343
23344         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
23345         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
23346         suffix.
23347
23348 2003-01-15  Bruno Haible  <bruno@clisp.org>
23349
23350         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
23351
23352 2003-01-15  Bruno Haible  <bruno@clisp.org>
23353
23354         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
23355         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
23356
23357 2003-01-14  Jim Meyering  <jim@meyering.net>
23358
23359         * lib/same.c (same_name): Tweak a comment.
23360
23361 2003-01-14  Bruno Haible  <bruno@clisp.org>
23362
23363         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
23364         when a string comparison is sufficient.
23365
23366 2003-01-14  Bruno Haible  <bruno@clisp.org>
23367
23368         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
23369         'unsigned int'.
23370
23371 2003-01-14  Bruno Haible  <bruno@clisp.org>
23372
23373         * lib/hash-pjw.c: Add comment about low quality of this function.
23374
23375 2003-01-13  Bruno Haible  <bruno@clisp.org>
23376
23377         * modules/stpcpy: Distribute lib/stpcpy.h.
23378         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
23379
23380 2003-01-13  Bruno Haible  <bruno@clisp.org>
23381
23382         * modules/*: Add a description.
23383         * modules/strpbrk: Fix Makefile.am snippet.
23384         * modules/strtoimax: Fix dependencies.
23385         * modules/strtoumax: Likewise.
23386
23387 2003-01-13  Bruno Haible  <bruno@clisp.org>
23388
23389         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
23390         * modules/alloca (Makefile.am): All object files depend on alloca.h.
23391         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
23392
23393 2003-01-13  Bruno Haible  <bruno@clisp.org>
23394
23395         * gnulib-tool (func_create_testdir): Store config/* files in the main
23396         directory.
23397         * config.rpath: Move to ...
23398         * config/config.rpath: ... here.
23399         * modules/gettext: Contains config/config.rpath, not config.rpath.
23400         * modules/iconv: Likewise.
23401
23402 2003-01-12  Paul Eggert  <eggert@twinsun.com>
23403
23404         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
23405         to avoid collisions with libcurses and libreadline.
23406
23407         * m4/getstr.m4: Remove.
23408         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
23409
23410 2003-01-12  Paul Eggert  <eggert@twinsun.com>
23411
23412         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
23413         to avoid collisions with libcurses and libreadline.
23414
23415         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
23416         * lib/getstr.h, getstr.c: Remove.
23417         * lib/getline.c: Include "getline.h", to check interface.
23418         Move body of old getstr.c here: this defines MIN_CHUNK and
23419         declares getdelim2, which is renamed from getstr.
23420         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
23421
23422         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
23423         All uses changed.
23424         * lib/linebuffer.h: Likewise.
23425         (readline): Remove backward-compatibility macro.
23426
23427 2003-01-12  Paul Eggert  <eggert@twinsun.com>
23428
23429         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
23430         to avoid collisions with libcurses and libreadline.
23431         * getstr: Remove.
23432         * MODULES.html.sh: Remove getstr.
23433         * modules/getline: Depend on unlocked-io, not getstr.
23434
23435 2003-01-12  Jim Meyering  <jim@meyering.net>
23436
23437         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
23438
23439 2003-01-10  Bruno Haible  <bruno@clisp.org>
23440
23441         * modules/alloca: Change Makefile.am requirements. Simplify Include
23442         requirements. Add lib/alloca_.h to file list.
23443
23444 2003-01-10  Bruno Haible  <bruno@clisp.org>
23445
23446         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
23447
23448 2003-01-10  Bruno Haible  <bruno@clisp.org>
23449
23450         * lib/alloca_.h: New file.
23451         * lib/getdate.y: Unconditionally include alloca.h.
23452         * lib/makepath.c: Likewise.
23453         * lib/setenv.c: Likewise.
23454         * lib/userspec.c: Likewise.
23455
23456 2003-01-09  Karl Berry  <karl@gnu.org>
23457
23458         * MODULES.html.sh: include `dirname $0` in PATH, to find
23459         gnulib-tool.
23460
23461 2003-01-09  Bruno Haible  <bruno@clisp.org>
23462
23463         * modules/stdbool: Change configure.ac, Makefile.am requirements.
23464         Simplify Include requirements. Add lib/stdbool.h.in to file list.
23465
23466 2003-01-09  Bruno Haible  <bruno@clisp.org>
23467
23468         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
23469
23470 2003-01-09  Bruno Haible  <bruno@clisp.org>
23471
23472         * lib/stdbool.h.in: New file.
23473
23474 2003-01-09  Bruno Haible  <bruno@clisp.org>
23475
23476         * gnulib-tool (func_all_modules): Ignore files ending in ~.
23477         * MODULES.html.sh: Likewise.
23478
23479 2003-01-08  Jim Meyering  <jim@meyering.net>
23480
23481         * lib/full-write.c: Undefine and define-away `const' after inclusion
23482         of errno.h, not before.  Suggestion from Bruno Haible.
23483
23484 2003-01-08  Bruno Haible  <bruno@clisp.org>
23485
23486         * modules/full-read: Depend on full-write.
23487
23488 2003-01-08  Bruno Haible  <bruno@clisp.org>
23489
23490         * lib/safe-read.c: Include specification header first, to ensure its
23491         selfcontainedness.
23492         * lib/full-write.c: Likewise.
23493
23494 2003-01-07  Jim Meyering  <jim@meyering.net>
23495
23496         * lib/full-write.c: Rework so that it may serve to define full_read,
23497         too.
23498         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
23499
23500 2003-01-07  Bruno Haible  <bruno@clisp.org>
23501
23502         * lib/strtoimax.c: Include <stdint.h> as an alternative to
23503         <inttypes.h>.
23504         * lib/xstrtol.h: Likewise.
23505         * lib/xstrtoimax.c: Likewise.
23506         * lib/xstrtoumax.c: Likewise.
23507         * lib/human.h: Likewise.
23508
23509         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
23510         on systems that have <inttypes.h> but not <stdint.h>.
23511
23512 2003-01-07  Bruno Haible  <bruno@clisp.org>
23513
23514         * MODULES.html.sh: Add copyright notice.
23515         (missed_files): Omit CVS directory entries.
23516         (func_module): Make it work with sed-3.02.
23517         * MODULES.txt: Remove file.
23518
23519 2003-01-06  Jim Meyering  <jim@meyering.net>
23520
23521         * lib/version-etc.c: Update year in translatable copyright string.
23522
23523 2003-01-03  Karl Berry  <karl@gnu.org>
23524
23525         * config/config.{guess,sub}: update from prep.
23526
23527 2003-01-02  Karl Berry  <karl@gnu.org>
23528
23529         * doc/COPYING.DOC: belatedly updated to 1.2.
23530
23531 2003-01-01  Karl Berry  <karl@gnu.org>
23532
23533         * gnulib-tool (func_verify_module): report module name $module in
23534         error message, not $1.
23535         * gnulib-tool (create-testdir): don't complain if destdir couldn't
23536         be created, only if it doesn't exist.
23537         * gnulib-tool (last_checkin_date): don't expand the $Date here.
23538
23539 2002-12-31  Paul Eggert  <eggert@twinsun.com>
23540
23541         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
23542
23543 2002-12-31  Paul Eggert  <eggert@twinsun.com>
23544
23545         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
23546         memcmp if strcoll doesn't work.
23547
23548 2002-12-31  Bruno Haible  <bruno@clisp.org>
23549
23550         * lib/utime.c (utime_null): No need to call ftruncate if the file was
23551         nonempty.
23552
23553 2002-12-31  Bruno Haible  <bruno@clisp.org>
23554
23555         * lib/memcoll.c (STRCOLL): New macro.
23556         (memcoll): Use it.
23557
23558 2002-12-31  Bruno Haible  <bruno@clisp.org>
23559
23560         * lib/localcharset.h: New file.
23561         * lib/localcharset.c: Include it.
23562         * lib/unicodeio.c: Likewise.
23563
23564 2002-12-31  Bruno Haible  <bruno@clisp.org>
23565
23566         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
23567         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
23568
23569 2002-12-31  Bruno Haible  <bruno@clisp.org>
23570
23571         * lib/getline.h: Include <stddef.h>, for size_t.
23572
23573         * lib/unicodeio.h: Include <stddef.h>, for size_t.
23574         * lib/unicodeio.c: Don't include <stddef.h>.
23575
23576 2002-12-31  Bruno Haible  <bruno@clisp.org>
23577
23578         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
23579         HAVE_TM_ZONE.
23580
23581 2002-12-24  Karl Berry  <karl@gnu.org>
23582
23583         * config/config.guess: update from prep.
23584
23585 2002-12-24  Bruno Haible  <bruno@clisp.org>
23586
23587         General infrasructure.
23588         * m4/README: Rewritten.
23589         * m4/onceonly.m4: New file.
23590         * m4/onceonly_2_57.m4: New file.
23591
23592         Module atexit.
23593         * m4/atexit.m4: New file.
23594
23595         Module strtod.
23596         * m4/strtod.m4: New file.
23597
23598         Module strtol.
23599         * m4/strtol.m4: New file.
23600
23601         Module strtoul.
23602         * m4/strtoul.m4: New file.
23603
23604         Module memchr.
23605         * m4/memchr.m4: New file.
23606
23607         Module memcmp.
23608         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
23609         (jm_FUNC_MEMCMP): Invoke it.
23610
23611         Module memcpy.
23612         * m4/memcpy.m4: New file.
23613
23614         Module memmove.
23615         * m4/memmove.m4: New file.
23616
23617         Module memset.
23618         * m4/memset.m4: New file.
23619
23620         Module strcspn.
23621         * m4/strcspn.m4: New file.
23622
23623         Module strpbrk.
23624         * m4/strpbrk.m4: New file.
23625
23626         Module strstr.
23627         * m4/strstr.m4: New file.
23628
23629         Module strerror.
23630         * m4/strerror.m4: New file.
23631
23632         Module mktime.
23633         * m4/mktime.m4: Renamed from jm-mktime.m4.
23634         (gl_PREREQ_MKTIME): New macro.
23635         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
23636
23637         Module malloc.
23638         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
23639         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
23640         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
23641
23642         Module realloc.
23643         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
23644         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
23645         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
23646
23647         Module strftime.
23648         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
23649         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
23650         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
23651         gl_TM_GMTOFF.
23652         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
23653
23654         Module xalloc.
23655         * m4/xalloc.m4: New file.
23656
23657         Module alloca.
23658         * m4/alloca.m4: New file.
23659
23660         Module putenv.
23661         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
23662         (jm_FUNC_PUTENV): Invoke it.
23663
23664         Module setenv.
23665         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
23666         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
23667         when invoked twice.
23668         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
23669         gt_FUNC_SETENV.
23670
23671         Module memrchr.
23672         * m4/memrchr.m4: New file.
23673
23674         Module stpcpy.
23675         * m4/stpcpy.m4: New file.
23676
23677         Module strcase.
23678         * m4/strcase.m4: New file.
23679
23680         Module strdup.
23681         * m4/strdup.m4: New file.
23682
23683         Module strnlen.
23684         * m4/strnlen.m4: New file.
23685
23686         Module strndup.
23687         * m4/strndup.m4: New file.
23688
23689         Module xstrtod.
23690         * m4/xstrtod.m4: New file.
23691
23692         Module xstrtol.
23693         * m4/xstrtol.m4: New file.
23694
23695         Module getdate.
23696         * m4/getdate.m4: New file.
23697
23698         Module unlocked-io.
23699         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
23700         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
23701         * m4/jm-glibc-io.m4n: Remove file.
23702
23703         Module long-options.
23704         * m4/long-options.m4: New file.
23705
23706         Module md5.
23707         * m4/md5.m4: New file.
23708
23709         Module sha.
23710         * m4/sha.m4: New file.
23711
23712         Module getstr.
23713         * m4/getstr.m4: New file.
23714
23715         Module getline.
23716         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
23717         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
23718         <sys/types.h>, for size_t. Use the function name gnu_getline, not
23719         simply getline. Infoke gl_PREREQ_GETLINE.
23720
23721         Module obstack.
23722         * m4/obstack.m4: New file.
23723
23724         Module hash.
23725         * m4/hash.m4: New file.
23726
23727         Module readtokens.
23728         * m4/readtokens.m4: New file.
23729
23730         Module strverscmp.
23731         * m4/strverscmp.m4: New file.
23732
23733         Module stdbool.
23734         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
23735         OSF/1.
23736
23737         Module strtoll.
23738         * m4/strtoll.m4: New file.
23739
23740         Module strtoull.
23741         * m4/strtoull.m4: New file.
23742
23743         Module strtoimax.
23744         * m4/strtoimax.m4: New file.
23745
23746         Module strtoumax.
23747         * m4/strtoumax.m4: New file.
23748
23749         Module xstrtoimax.
23750         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
23751         jm_AC_PREREQ_XSTRTOIMAX.
23752         Moved the strtol prerequisites to strtol.m4.
23753         Moved the strtoll prerequisites to strtoll.m4.
23754         Moved the strtoimax prerequisites to strtoimax.m4.
23755
23756         Module xstrtoumax.
23757         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
23758         jm_AC_PREREQ_XSTRTOUMAX.
23759         Moved the strtoul prerequisites to strtoul.m4.
23760         Moved the strtoull prerequisites to strtoull.m4.
23761         Moved the strtoumax prerequisites to strtoumax.m4.
23762
23763         Module chown.
23764         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
23765         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
23766
23767         Module dup2.
23768         * m4/dup2.m4: New file.
23769
23770         Module ftruncate.
23771         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
23772         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
23773
23774         Module getgroups.
23775         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
23776         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
23777
23778         Module gettimeofday.
23779         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
23780         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
23781         gl_PREREQ_GETTIMEOFDAY.
23782
23783         Module mkdir.
23784         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
23785         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
23786
23787         Module mkstemp.
23788         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
23789         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
23790         jm_AC_TYPE_UINTMAX_T.
23791         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
23792
23793         Module stat.
23794         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
23795         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
23796
23797         Module lstat.
23798         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
23799         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
23800
23801         Module timespec.
23802         * m4/timespec.m4 (gl_TIMESPEC): New macro.
23803         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
23804         * m4/st_mtim.m4: Indentation.
23805
23806         Module nanosleep.
23807         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
23808         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
23809         gl_PREREQ_NANOSLEEP.
23810
23811         Module regex.
23812         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
23813         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
23814         (gl_REGEX): New macro.
23815
23816         Module rename.
23817         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
23818         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
23819
23820         Module rmdir.
23821         * m4/rmdir.m4: New file.
23822
23823         Module utime.
23824         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
23825         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
23826         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
23827
23828         Module dirname.
23829         * m4/dirname.m4: New file.
23830
23831         Module getopt.
23832         * m4/getopt.m4: New file.
23833
23834         Module unistd-safer.
23835         * m4/unistd-safer.m4: New file.
23836
23837         Module fnmatch.
23838         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
23839         declaration.
23840         (gl_PREREQ_FNMATCH_EXTRA): New macro.
23841         (gl_FUNC_FNMATCH_POSIX): New macro.
23842         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
23843         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
23844         simply fnmatch.
23845
23846         Module exclude.
23847         * m4/exclude.m4: New file.
23848
23849         Module human.
23850         * m4/human.m4: New file.
23851
23852         Module acl.
23853         * m4/acl.m4: Nop.
23854
23855         Module backupfile.
23856         * m4/backupfile.m4: New file.
23857         * m4/d-ino.m4: Indentation.
23858
23859         Module fsusage.
23860         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
23861         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
23862         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
23863
23864         Module dirfd.
23865         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
23866         requirements.
23867
23868         Module euidaccess.
23869         * m4/euidaccess.m4: New file.
23870
23871         Module file-type.
23872         * m4/file-type.m4: New file.
23873
23874         Module fileblocks.
23875         * m4/fileblocks.m4: New file.
23876
23877         Module filemode.
23878         * m4/filemode.m4: New file.
23879
23880         Module isdir.
23881         * m4/isdir.m4: New file.
23882
23883         Module lchown.
23884         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
23885         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
23886
23887         Module makepath.
23888         * m4/makepath.m4: New file.
23889
23890         Module modechange.
23891         * m4/modechange.m4: New file.
23892
23893         Module mountlist.
23894         * m4/mountlist.m4: New file.
23895         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
23896         Indentation.
23897
23898         Module path-concat.
23899         * m4/path-concat.m4: New file.
23900
23901         Module pathmax.
23902         * m4/pathmax.m4: New file.
23903
23904         Module same.
23905         * m4/same.m4: New file.
23906
23907         Module save-cwd.
23908         * m4/save-cwd.m4: New file.
23909
23910         Module savedir.
23911         * m4/savedir.m4: New file.
23912
23913         Module xgetcwd.
23914         * m4/xgetcwd.m4: New file.
23915         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
23916
23917         Module xreadlink.
23918         * m4/xreadlink.m4: New file.
23919
23920         Module safe-read.
23921         * m4/safe-read.m4: New file.
23922
23923         Module safe-write.
23924         * m4/safe-write.m4: New file.
23925
23926         Module closeout.
23927         * m4/closeout.m4: New file.
23928
23929         Module stdio-safer.
23930         * m4/stdio-safer.m4: New file.
23931
23932         Module getpass.
23933         * m4/getpass.m4: New file.
23934
23935         Module getugroups.
23936         * m4/getugroups.m4: New file.
23937
23938         Module group-member.
23939         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
23940         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
23941
23942         Module idcache.
23943         * m4/idcache.m4: New file.
23944
23945         Module userspec.
23946         * m4/userspec.m4: New file.
23947
23948         Module gettime.
23949         * m4/clock_time.m4: New file.
23950         * m4/gettime.m4: New file.
23951
23952         Module settime.
23953         * m4/settime.m4: New file.
23954
23955         Module posixtm.
23956         * m4/posixtm.m4: New file.
23957
23958         Module gethostname.
23959         * m4/gethostname.m4: New file.
23960
23961         Module canon-host.
23962         * m4/canon-host.m4: New file.
23963
23964         Module gettext.
23965         * m4/codeset.m4: New file, from gettext-0.11.5.
23966         * m4/gettext.m4: New file, from gettext-0.11.5.
23967         * m4/glibc21.m4: New file, from gettext-0.11.5.
23968         * m4/iconv.m4: New file, from gettext-0.11.5.
23969         * m4/intdiv0.m4: New file, from gettext-0.11.5.
23970         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
23971         * m4/inttypes.m4: New file, from gettext-0.11.5.
23972         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
23973         * m4/isc-posix.m4: New file, from gettext-0.11.5.
23974         * m4/lcmessage.m4: New file, from gettext-0.11.5.
23975         * m4/lib-ld.m4: New file, from gettext-0.11.5.
23976         * m4/lib-link.m4: New file, from gettext-0.11.5.
23977         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
23978         * m4/progtest.m4: New file, from gettext-0.11.5.
23979         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
23980         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
23981         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
23982
23983         Module localcharset.
23984         * m4/localcharset.m4: New file.
23985
23986         Module hard-locale.
23987         * m4/hard-locale.m4: New file.
23988
23989         Module mbswidth.
23990         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
23991         onceonly macros.
23992         * m4/mbrtowc.m4: Add comment.
23993
23994         Module memcasecmp.
23995         * m4/memcasecmp.m4: New file.
23996
23997         Module memcoll.
23998         * m4/memcoll.m4: New file.
23999
24000         Module unicodeio.
24001         * m4/unicodeio.m4: New file.
24002
24003         Module rpmatch.
24004         * m4/rpmatch.m4: New file.
24005
24006         Module yesno.
24007         * m4/yesno.m4: New file.
24008
24009         Module exitfail.
24010         * m4/exitfail.m4: New file.
24011
24012         Module c-stack.
24013         * m4/c-stack.m4 (gl_C_STACK): New macro.
24014         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
24015
24016         Module error.
24017         * m4/error.m4 (gl_ERROR): New macro.
24018         (jm_PREREQ_ERROR): Use onceonly macros.
24019
24020         Module fatal.
24021         * m4/fatal.m4: New file.
24022
24023         Module getloadavg.
24024         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
24025         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
24026
24027         Module getpagesize.
24028         * m4/getpagesize.m4: New file.
24029
24030         Module getusershell.
24031         * m4/getusershell.m4: New file.
24032
24033         Module physmem.
24034         * m4/physmem.m4: New file.
24035
24036         Module posixver.
24037         * m4/posixver.m4: New file.
24038
24039         Module quotearg.
24040         * m4/quotearg.m4: New file.
24041
24042         Module quote.
24043         * m4/quote.m4: New file.
24044
24045         Module readutmp.
24046         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
24047
24048         Module sig2str.
24049         * m4/sig2str.m4: New file.
24050
24051         Other.
24052         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
24053         ulonglong.m4.
24054         * m4/intmax_t.m4: New file.
24055         * m4/d-type.m4: Indentation.
24056         * m4/jm-macros.m4: Update.
24057         * m4/prereq.m4 (jm_PREREQ): Update.
24058         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
24059         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
24060         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
24061         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
24062         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
24063         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
24064         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
24065         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
24066         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
24067         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
24068         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
24069         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
24070         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
24071         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
24072         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
24073         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
24074         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
24075         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
24076         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
24077
24078 2002-12-24  Bruno Haible  <bruno@clisp.org>
24079
24080         * MODULES.txt: Update according to m4/ changes.
24081
24082         Module gettext.
24083         * config.rpath: New file, from gettext-0.11.5.
24084
24085         * modules/*: New module descriptions.
24086         * gnulib-tool: New file.
24087         * MODULES.html.sh: New file.
24088
24089 2002-12-21  Karl Berry  <karl@gnu.org>
24090
24091         * doc/fdl.texi: update to version 1.2.
24092
24093 2002-12-19  Karl Berry  <karl@gnu.org>
24094
24095         * config/config.guess: update from prep.
24096
24097 2002-12-18  Bruno Haible  <bruno@clisp.org>
24098
24099         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
24100         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
24101
24102 2002-12-17  Bruno Haible  <bruno@clisp.org>
24103
24104         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
24105         stdlib.h, string.h.
24106
24107 2002-12-17  Bruno Haible  <bruno@clisp.org>
24108
24109         * lib/canon-host.c (strdup): Remove unused declaration.
24110
24111         * lib/fsusage.c: Include full_read.h.
24112         (get_fs_usage): Use full_read instead of safe_read.
24113
24114         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
24115
24116 2002-12-12  Karl Berry  <karl@gnu.org>
24117
24118         * config/config.guess: update from prep.
24119
24120 2002-12-11  Bruno Haible  <bruno@clisp.org>
24121
24122         * m4/setenv.m4: New file, from gettext-0.11.5.
24123
24124 2002-12-11  Bruno Haible  <bruno@clisp.org>
24125
24126         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
24127         not unsetenv().
24128         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
24129         modifications:
24130
24131         2002-12-11  Bruno Haible  <bruno@clisp.org>
24132
24133                 * setenv.c (alloca): Fall back to malloc.
24134                 (freea): New macro.
24135                 (setenv): Use freea() to free memory allocated with alloca().
24136
24137         2002-11-13  Bruno Haible  <bruno@clisp.org>
24138
24139                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
24140                 function declarations.
24141                 * unsetenv.c (unsetenv): Likewise.
24142
24143         2002-03-04  Bruno Haible  <bruno@clisp.org>
24144
24145                 Portability to AIX 4.3.3.
24146                 * unsetenv.c: New file, extracted from setenv.c.
24147                 * setenv.c: Move the unsetenv() function to unsetenv.c.
24148
24149         2001-12-20  Bruno Haible  <bruno@clisp.org>
24150
24151                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
24152                 use malloc instead. For SunOS 4.
24153
24154         2001-12-11  Bruno Haible  <bruno@clisp.org>
24155
24156                 * setenv.c: Declare alloca.
24157                 (compar_fn_t): New typedef.
24158                 (KNOWN_VALUE, STORE_VALUE): Use it.
24159
24160         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
24161         setenv.h.
24162
24163 2002-12-10  Paul Eggert  <eggert@twinsun.com>
24164
24165         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
24166         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
24167         Choose values that are less likely to collide with system fnmatch
24168         options.
24169         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
24170         defined (e.g., a pure POSIX system).
24171         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
24172         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
24173
24174 2002-12-06  Paul Eggert  <eggert@twinsun.com>
24175
24176         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
24177         a pain in practice to deal with generated m4 files.  This change
24178         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
24179
24180         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
24181         and jm-glibc-io.m4, as they are no longer a special case.
24182         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
24183         kludge and the auto-generation stuff.  Check only whether the
24184         functions are declared, not whether they exist, since older hosts
24185         that don't declare the functions can't use the optimization anyway.
24186
24187 2002-12-06  Jim Meyering  <jim@meyering.net>
24188
24189         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
24190
24191         Merge in changes from libc's misc/error.c, in preparation
24192         for the merge of gnulib's changes back into libc.
24193
24194         * lib/error.c (_): Define only if not already defined.
24195         Move definition to follow all #include directives.
24196         Include unlocked-io.h only if !_LIBC.
24197         [_LIBC]: Include <libio/libioP.h>.
24198         [USE_IN_LIBIO]: Include <libio/iolibio.h>
24199         (fflush): Tweak definition to use INTUSE.
24200         (putc): Define.
24201
24202 2002-12-05  Paul Eggert  <eggert@twinsun.com>
24203
24204         * lib/alloca.c [defined emacs]: Include "lisp.h".
24205         (xalloc_die) [defined emacs]: New macro.
24206         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
24207         [! defined emacs]: Include <xalloc.h>.
24208         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
24209         (pointer): Typedef to POINTER_TYPE *.
24210         (malloc): Remove decl; we now always use xmalloc.
24211         (alloca): Use old-style definition, since Emacs needs this.
24212         Check for arithmetic overflow when computing combined size.
24213
24214 2002-12-04  Paul Eggert  <eggert@twinsun.com>
24215
24216         Do not generate unlocked-io.h automatically, since it's easier to
24217         maintain it by hand.
24218
24219         * lib/unlocked-io.h: New file, from GNU diffutils,
24220         but with proper copyright notice and attribution.
24221         * lib/gen-uio: Remove.
24222         * lib/Makefile.am: Add copyright notice.
24223         (libfetish_a_SOURCES): Add unlocked-io.h.
24224         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
24225         (DISTCLEANFILES, io_functions): Remove macros.
24226         (EXTRA_DIST): Remove gen_uio.
24227         (unlocked-io.h): Remove rule.
24228
24229 2002-12-04  Jim Meyering  <jim@meyering.net>
24230
24231         Reflect the fact that stat.c and lstat.c are no longer generated.
24232         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
24233         (DISTCLEANFILES): Likewise.
24234         (EXTRA_DIST): Likewise.
24235         (all_local): Don't depend on stat.c or lstat.c.
24236         (stat.c, lstat.c): Remove rules.
24237         (EXTRA_DIST): Remove xstat.in.
24238
24239         * lib/xstat.in: Remove file.  Contents moved into stat.c.
24240         * lib/stat.c: New file.  Contents mostly from xstat.in.
24241         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
24242         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
24243
24244         * lib/safe-read.c: Rework so that it may serve to define safe_write,
24245         too.
24246         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
24247
24248 2002-12-03  Jim Meyering  <jim@meyering.net>
24249
24250         * lib/safe-read.c, safe-write.c: Change variable names and comments,
24251         but not semantics, to minimize the differences between these two files.
24252         (safe_read): Change comment to mention SAFE_READ_ERROR.
24253
24254         * lib/safe-read.c (IS_EINTR): Define.
24255         (safe_read): Use IS_EINTR in place of in-function cpp directives.
24256
24257 2002-12-02  Jim Meyering  <jim@meyering.net>
24258
24259         * lib/safe-read.c (EINTR): Define.
24260         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
24261         (INT_MAX): Provide fallback.
24262         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
24263
24264         * lib/safe-read.h (SAFE_READ_ERROR): Define.
24265
24266 2002-12-02  Bruno Haible  <bruno@clisp.org>
24267
24268         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
24269         Define, taken from safe-read.c.
24270         (INT_MAX): Provide fallback.
24271         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
24272         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
24273
24274         * lib/safe-read.c (EINTR): Remove definition.
24275         (safe_read): Don't use EINTR if it is absent.
24276
24277 2002-12-01  Jim Meyering  <jim@meyering.net>
24278
24279         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
24280         zero.
24281         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
24282
24283 2002-11-27  Paul Eggert  <eggert@twinsun.com>
24284
24285         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
24286         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
24287         with `if (! (value < limit)) abort ();', for readability.
24288
24289 2002-11-26  Karl Berry  <karl@gnu.org>
24290
24291         * lib/strdup.c: copy from libc again, with jim's ok.
24292         * lib/.cppi-disable: re-add strdup.c
24293
24294 2002-11-25  Karl Berry  <karl@gnu.org>
24295
24296         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
24297         instead of "strtol.c".
24298
24299 2002-11-25  Karl Berry  <karl@gnu.org>
24300
24301         * config/install-sh: update from automake for variable quoting, $0 in
24302         error msgs, etc.
24303
24304         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
24305         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
24306         entry.
24307
24308 2002-11-25  Jim Meyering  <jim@meyering.net>
24309
24310         * lib/mktime.c: Sync from libc, now that it has the latest fix.
24311
24312 2002-11-24  Karl Berry  <karl@gnu.org>
24313
24314         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
24315         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
24316
24317 2002-11-24  Jim Meyering  <jim@meyering.net>
24318
24319         Update from coreutils:
24320
24321         * lib/mktime.c: Merge in changes from libc.
24322
24323         Avoid a link-time failure on some Linux systems.
24324         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
24325         (otherwise).
24326         (__mon_yday): Declare with the STATIC attribute.
24327         (__mktime_internal): Likewise.
24328         Based on a report from Greg Schafer.
24329
24330 2002-11-23  Jim Meyering  <jim@meyering.net>
24331
24332         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
24333         Use `unsigned', not `int', as type of index.
24334
24335         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
24336
24337         * lib/fsusage.c: Remove unneeded parentheses around operands of
24338         `defined'.
24339
24340 2002-11-22  Paul Eggert  <eggert@twinsun.com>
24341
24342         * lib/quotearg.h: Allow multiple inclusion by surrounding with
24343         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
24344         so that we can be included first.
24345         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
24346         * lib/quotearg.c: Include quotearg.h immediately after config.h.
24347         No need to include stddef.h or sys/types.h any more.
24348         Surround local include files with "", not "<>".
24349         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
24350         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
24351         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
24352         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
24353         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
24354         (ISPRINT): Remove; no longer needed now that we assume C89.
24355
24356         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
24357         Preserve errno.
24358
24359         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
24360         quotearg_char): Use SIZE_MAX rather than
24361         (size_t) -1 when we are talking about "infinity".
24362
24363         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
24364
24365 2002-11-22  Paul Eggert  <eggert@twinsun.com>
24366
24367         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
24368         hint that one should use `if (! x) abort ();' rather than `assert
24369         (x);', and anyway it's one less thing to worry about configuring.
24370         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
24371         hash_rehash, hash_insert): Use abort rather than assert.
24372
24373 2002-11-22  Bruno Haible  <bruno@clisp.org>
24374
24375         * lib/safe-read.h: Assume C89. Add comments.
24376         (safe_read): Change return type to size_t.
24377         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
24378         byte counts > SSIZE_MAX correctly.
24379         * lib/safe-write.h: New file.
24380         * lib/safe-write.c: New file.
24381         * lib/full-read.h: New file.
24382         * lib/full-read.c: New file.
24383         * lib/full-write.h: Assume C89. Add comments.
24384         * lib/full-write.c: Include safe-write.h.
24385         (full_write): Rewritten to use safe_write.
24386         Suggested by Jim Meyering and Paul Eggert.
24387
24388 2002-11-21  Jim Meyering  <jim@meyering.net>
24389
24390         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
24391
24392         Merge in changes from the coreutils.
24393
24394         2002-09-25  Paul Eggert  <eggert@twinsun.com>
24395         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
24396         <stdint.h>.
24397         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
24398         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
24399         int.  Work more efficiently if X is the same width as uintmax_t.
24400         Do not compare X to -1, to avoid bogus compiler warning.
24401         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
24402         Don't assume that f_frsize and f_bsize are the same type.
24403
24404         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
24405         warning on FreeBSD.
24406
24407         * lib/makepath.c (make_path): Restore umask *before* creating the final
24408         component.
24409         (make_path): Minor reformatting.
24410
24411         * lib/xmalloc.c: Adjust to work with new autoconf macros,
24412         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
24413         HAVE_MALLOC/HAVE_REALLOC.
24414
24415         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
24416         dummy ones.  At least on GNU/Linux systems, `auto' means something
24417         else.
24418         From Michael Stone.
24419
24420 2002-11-21  Bruno Haible  <bruno@clisp.org>
24421
24422         Remove case insensitive option matching.
24423         * lib/argmatch.h (argcasematch): Remove declaration.
24424         (ARGCASEMATCH): Remove macro.
24425         (__xargmatch_internal): Remove case_sensitive argument.
24426         (XARGMATCH): Update.
24427         (XARGCASEMATCH): Remove macro.
24428         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
24429         case_sensitive argument.
24430         (argcasematch): Remove function.
24431         (__xargmatch_internal): Remove case_sensitive argument.
24432         (main): Use XARGMATCH instead of XARGCASEMATCH.
24433
24434         * lib/xmalloc.c: Change compile-time error message. Add comment about
24435         required autoconf version.
24436
24437 2002-11-20  Paul Eggert  <eggert@twinsun.com>
24438
24439         Merge argmatch cleanups from Bison.  Assume C89.
24440
24441         * lib/argmatch.c: Include config.h here, not in argmatch.h.
24442         Include stdlib.h, for EXIT_FAILURE.
24443         Always include <string.h>, since we assume C89.
24444         (EXIT_FAILURE): Remove pre-C89 bug workaround.
24445         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
24446         Include <stddef.h> instead, since it's all we need for size_t.
24447         (PARAMS): Remove.  All uses removed.
24448         (ARRAY_CARDINALITY): Do not bother to #undef.
24449         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
24450         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
24451         Remove unnecessary parentheses.
24452         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
24453         Insert necessary parentheses.
24454         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
24455         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
24456
24457 2002-11-19  Bruno Haible  <bruno@clisp.org>
24458
24459         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
24460         * lib/mbswidth.h: Include <stddef.h>, for size_t.
24461
24462         * lib/mbswidth.h (PARAMS): Remove macro.
24463         (mbswidth, mbsnwidth): Use ANSI C function declarations.
24464         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
24465
24466         * lib/gcd.h (PARAMS): Remove macro.
24467         (gcd): Use ANSI C function declarations.
24468         * lib/gcd.c (gcd): Likewise.
24469
24470 2002-11-15  Bruno Haible  <bruno@clisp.org>
24471
24472         * lib/strcspn.c: Include <stddef.h>.
24473         (strcspn): Use ANSI C function declaration. Change return type to
24474         size_t. Use NULL.
24475         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
24476         (strpbrk): Use NULL.
24477         * lib/strpbrk.h (PARAMS): Remove macro.
24478         (strpbrk): Use ANSI C function declaration.
24479         * lib/strstr.c: Don't include <sys/types.h>.
24480         * lib/strstr.h (PARAMS): Remove macro.
24481         (strstr): Use ANSI C function declarations.
24482
24483 2002-11-14  Karl Berry  <karl@gnu.org>
24484
24485         * config/mkinstalldirs: `do' on separate line, instead of
24486         `for var; do'.
24487
24488 2002-11-06  Bruno Haible  <bruno@clisp.org>
24489
24490         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
24491         * lib/gcd.c (gcd): Likewise.
24492
24493 2002-11-05  Bruno Haible  <bruno@clisp.org>
24494
24495         * lib/gcd.h: New file, from gettext-0.11.5.
24496         * lib/gcd.c: New file, from gettext-0.11.5.
24497
24498 2002-11-05  Bruno Haible  <bruno@clisp.org>
24499
24500         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24501         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24502         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24503         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
24504
24505         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
24506         <libintl.h>.
24507         * lib/makepath.c: Include gettext.h instead of <locale.h> and
24508         <libintl.h>.
24509
24510         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
24511         * lib/human.c: Include gettext.h instead of <libintl.h>.
24512         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
24513         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
24514         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
24515         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
24516         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
24517         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
24518         (textdomain): Remove definition.
24519         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
24520
24521         * lib/long-options.c: Remove include of <libintl.h> and definition of
24522         _.
24523         * lib/same.c: Remove include of <libintl.h> and definition of _.
24524
24525 2002-11-04  Owen Taylor  <otaylor@redhat.com>
24526
24527         * lib/config.charset: A few additions for Solaris.
24528
24529 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
24530
24531         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
24532         * lib/localcharset.c (locale_charset): Declare as extern "C".
24533
24534 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
24535
24536         * lib/config.charset: msdos in uk_UA uses CP1125.
24537
24538 2002-11-04  Bruno Haible  <bruno@clisp.org>
24539
24540         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
24541         * lib/strcase.h: New file, from GNU gettext-0.11.5.
24542         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
24543         * lib/strstr.h: New file, from GNU gettext-0.11.5.
24544         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
24545
24546 2002-11-04  Bruno Haible  <bruno@clisp.org>
24547
24548         * lib/localcharset.c (locale_charset): Don't return an empty string.
24549
24550 2002-11-04  Bruno Haible  <bruno@clisp.org>
24551
24552         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
24553         aliases.
24554
24555 2002-11-04  Bruno Haible  <bruno@clisp.org>
24556
24557         * lib/config.charset: Update for newest glibc. Add canonical names
24558         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
24559
24560 2002-11-04  Bruno Haible  <bruno@clisp.org>
24561
24562         * lib/config.charset: Add support for NetBSD.
24563
24564 2002-11-04  Bruno Haible  <bruno@clisp.org>
24565
24566         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
24567
24568 2002-11-01  Bruno Haible  <bruno@clisp.org>
24569
24570         * configure.in: Add AC_CONFIG_AUX_DIR call.
24571         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
24572         test/Makefile.
24573         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
24574
24575 2002-09-28  Karl Berry  <karl@gnu.org>
24576
24577         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
24578         installed automake until the next release, since changes have been
24579         made.
24580
24581 2002-09-25  Karl Berry  <karl@gnu.org>
24582
24583         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
24584         * lib/getopt*: copy from libc/posix.
24585         * lib/gettext.h: copy from gettext.
24586         * lib/.cppi-disable: add strdup.c, gettext.h.
24587
24588 2002-09-25  Karl Berry  <karl@gnu.org>
24589
24590         * config/srclist.txt: enable gettext.h check.
24591         * config/config.{guess,sub}: update from prep.
24592         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
24593                 from automake 1.6.3.
24594         See srclist*.
24595
24596 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
24597
24598         * regex.c (PATFETCH): Remove the translating fetch.
24599         (PATFETCH_RAW): Rename to PATFETCH.
24600         (set_image_of_range): New fun.
24601         (SET_RANGE_TABLE_WORK_AREA): Use it.
24602         (regex_compile): Don't translate the pattern chars so eagerly.
24603         Only do it when inserting an `exactn' bytecode or when handling
24604         a char-range.
24605         (mutually_exclusive_p): Avoid empty statement.
24606
24607 2002-07-06  Jim Meyering  <meyering@lucent.com>
24608
24609         * m4/README: Don't mention Makefile.am.in.
24610         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
24611
24612 2002-07-01  Jim Meyering  <meyering@lucent.com>
24613
24614         * lib/c-stack.c: Include sys/time.h.
24615         From Volker Borchert.
24616
24617 2002-06-26  Paul Eggert  <eggert@twinsun.com>
24618
24619         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
24620
24621 2002-06-26  Paul Eggert  <eggert@twinsun.com>
24622
24623         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
24624         New macro.  Use it uniformly instead of
24625         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
24626         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
24627         reported by Vin Shelton.
24628
24629 2002-06-22  Paul Eggert  <eggert@twinsun.com>
24630
24631         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
24632         Do not assume SA_SIGINFO behavior.
24633         Bug reported by Jim Meyering on NetBSD 1.5.2.
24634
24635 2002-06-22  Jim Meyering  <meyering@lucent.com>
24636
24637         * m4/c-stack.m4: New file, from diffutils-2.8.2.
24638         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
24639
24640         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
24641         now that configure.ac uses AC_GNU_SOURCE.
24642         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
24643         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
24644
24645         Update to latest tools.  Suggestions from Paul Eggert.
24646         * m4/stdbool.m4: New file, from diffutils-2.8.2.
24647         * m4/gnu-source.m4: Update from diffutils-2.8.2.
24648         * m4/fnmatch.m4: Likewise.
24649         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
24650         to AC_HEADER_STDBOOL
24651
24652 2002-06-22  Jim Meyering  <meyering@lucent.com>
24653
24654         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
24655         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
24656
24657 2002-06-22  Jim Meyering  <meyering@lucent.com>
24658
24659         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
24660
24661         * lib/exitfail.c, exitfail.h: Likewise.
24662         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
24663
24664         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
24665         of fnmatch.h.
24666         (EXTRA_DIST): Add fnmatch_loop.c.
24667         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
24668
24669         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
24670         * lib/fnmatch.c: Update from diffutils-2.8.2.
24671         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
24672         * lib/fnmatch.h: Remove file.
24673
24674 2002-06-21  Jim Meyering  <meyering@lucent.com>
24675
24676         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
24677         * m4/mbrtowc.m4: Likewise.
24678
24679         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
24680         * m4/mbswidth.m4: Reflect name change:
24681         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
24682         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
24683
24684         * m4/lib-link.m4: Update from gettext-0.11.2.
24685         * m4/gettext.m4: Likewise.
24686
24687         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
24688         From Alfred M. Szmidt.
24689
24690 2002-06-18  Paul Eggert  <eggert@twinsun.com>
24691
24692         * lib/file-type.h: Report an error if neither S_ISREG nor
24693         S_IFREG is defined, instead of using a test specific to glibc
24694         2.2.  This should be safe, since POSIX requires S_ISREG and
24695         Unix Version 7 had S_IFREG.  We don't need to check for
24696         <sys/types.h> since we don't use any symbols that it defines.
24697
24698 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
24699
24700         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
24701         $@-t, so that each temporary file name is unique and valid in the first
24702         8 characters, for operation under DOS.
24703
24704 2002-06-15  Paul Eggert  <eggert@twinsun.com>
24705
24706         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
24707
24708 2002-06-15  Jim Meyering  <meyering@lucent.com>
24709
24710         Work even with DJGPP 2.03, which lacks support for symlinks.
24711         From Richard Dawe.
24712         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
24713         is defined.
24714         * lib/lchown.c (S_ISLNK): Likewise.
24715
24716 2002-06-15  Jim Meyering  <meyering@lucent.com>
24717
24718         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
24719         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
24720         have been included before this file.
24721
24722 2002-06-14  Jim Meyering  <meyering@lucent.com>
24723
24724         * lib/file-type.h: Use the version from diffutils-2.8.2.
24725         * lib/file-type.c: Likewise.
24726
24727 2002-06-07  Jim Meyering  <meyering@lucent.com>
24728
24729         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
24730         They're needed at least for NetBSD 1.5.2.
24731         ($statxfs_includes): Include those same headers.
24732         ($statxfs_includes): Include sys/vfs.h if available.
24733         ($statxfs_includes): Likewise for sys/statvfs.h.
24734         Check for the following members in both structs statfs and statvfs:
24735         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
24736
24737 2002-06-01  Jim Meyering  <meyering@lucent.com>
24738
24739         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
24740         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
24741
24742 2002-05-28  Jim Meyering  <meyering@lucent.com>
24743
24744         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
24745         Reported by Volker Borchert.
24746
24747 2002-05-27  Jim Meyering  <meyering@lucent.com>
24748
24749         Fix a problem seen only on nonconforming systems whereby ls.c's
24750         use of localtime, and then of gettimeofday would cause trouble:
24751         the localtime call used to initialize rpl_gettimeofday's save
24752         mechanism would clobber ls's current local time information so
24753         that in any long listing the first file would always be listed
24754         with date 1970-01-01.  Analysis by Volker Borchert.
24755
24756         * lib/gettimeofday.c (localtime): Undefine.
24757         (rpl_localtime): New function.
24758
24759 2002-05-27  Jim Meyering  <meyering@lucent.com>
24760
24761         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
24762         localtime.
24763
24764         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
24765         use the replacement function; it wouldn't resolve at link time.
24766         Reported by Volker Borchert.
24767
24768 2002-05-22  Jim Meyering  <meyering@lucent.com>
24769
24770         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
24771         file-type.h.
24772         * lib/file-type.h: New file.
24773         * lib/file-type.c (file_type): New file/function.  Extracted from
24774         diffutils.
24775
24776 2002-04-30  Jim Meyering  <meyering@lucent.com>
24777
24778         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
24779
24780 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24781
24782         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
24783
24784 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24785
24786         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
24787         Do not check for alloca.h (no longer used) or stdbool.h (was never
24788         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
24789
24790 2002-04-29  Paul Eggert  <eggert@twinsun.com>
24791
24792         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
24793
24794 2002-04-29  Jim Meyering  <meyering@lucent.com>
24795
24796         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
24797         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
24798         Use AC_FUNC_STRNLEN here instead.
24799
24800         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
24801         With autoconf-2.53a, it's part of AC_PROG_CC.
24802
24803 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24804
24805         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
24806         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
24807
24808 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24809
24810         * lib/sig2str.h, lib/sig2str.c: New files.
24811         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
24812
24813 2002-04-28  Paul Eggert  <eggert@twinsun.com>
24814
24815         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
24816         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
24817         of 127, since 64 is the largest conceivable number for ancient
24818         nonstandard hosts.
24819         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
24820
24821 2002-04-28  Jim Meyering  <meyering@lucent.com>
24822
24823         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
24824
24825 2002-04-24  Jim Meyering  <meyering@lucent.com>
24826
24827         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
24828         (jm_PREREQ): Use it.
24829
24830         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
24831         mach/mach.h fcntl.h.
24832         Check for this function: setlocale.
24833
24834 2002-04-24  Jim Meyering  <meyering@lucent.com>
24835
24836         * lib/gettext.h: New file, from Gettext.
24837         * lib/Makefile.am (INCLUDES): Remove -I../intl.
24838         (libfetish_a_SOURCES): Add gettext.h.
24839
24840 2002-04-16  Jim Meyering  <meyering@lucent.com>
24841
24842         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
24843         ut_pid, ut_id, ut_exit.
24844
24845 2002-04-16  Jim Meyering  <meyering@lucent.com>
24846
24847         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
24848         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
24849         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
24850
24851 2002-04-12  Jim Meyering  <meyering@lucent.com>
24852
24853         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
24854         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
24855         existence of the getmntinfo function.  Needed for Darwin 5.3.
24856
24857         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
24858         This is necessary at least on Darwin 5.3.
24859
24860         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
24861         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
24862         strnlen.o in the library, and that makes some versions of ranlib
24863         object.
24864
24865 2002-04-12  Jim Meyering  <meyering@lucent.com>
24866
24867         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
24868
24869 2002-04-09  Jim Meyering  <meyering@lucent.com>
24870
24871         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
24872         to be more precise.  Rather than saying we're checking whether the
24873         function `works', say what we're testing.
24874         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
24875         Reported by Bruno Haible.
24876
24877 2002-03-10  Jim Meyering  <meyering@lucent.com>
24878
24879         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
24880         Suggestion from Santiago Vila.
24881
24882 2002-03-08  Jim Meyering  <meyering@lucent.com>
24883
24884         * lib/rename.c: Mention that this wrapper is needed also on
24885         mips-dec-ultrix4.4 systems.
24886
24887 2002-03-02  Jim Meyering  <meyering@lucent.com>
24888
24889         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
24890         not HAVE_CLOCK_SETTIME.
24891
24892 2002-02-27  Paul Eggert  <eggert@twinsun.com>
24893
24894         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
24895         Check for clock_settime.
24896
24897 2002-02-27  Paul Eggert  <eggert@twinsun.com>
24898
24899         * lib/nanosleep.h: Rename to....
24900         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
24901
24902         * lib/gettime.c: New file.
24903         * lib/settime.c: New file.
24904         * lib/stime.c: Remove.
24905
24906         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
24907         timespec.h.  Remove nanosleep.h.
24908
24909 2002-02-25  Paul Eggert  <eggert@twinsun.com>
24910
24911         * m4/acl.m4: New file.
24912         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
24913         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
24914
24915 2002-02-25  Paul Eggert  <eggert@twinsun.com>
24916
24917         * lib/acl.c, lib/acl.h: New files.
24918         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
24919
24920 2002-02-24  Jim Meyering  <meyering@lucent.com>
24921
24922         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
24923         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
24924         cause trouble.  Reported by Nelson Beebe.
24925
24926 2002-02-23  Paul Eggert  <eggert@twinsun.com>
24927
24928         * lib/path-concat.c (xpath_concat): Reorder code to pacify
24929         compilers that don't know that xalloc_die never returns.
24930
24931 2002-02-20  Jim Meyering  <meyering@lucent.com>
24932
24933         * lib/getdate.c: Regenerate using bison-1.33.
24934
24935 2002-02-17  Jim Meyering  <meyering@lucent.com>
24936
24937         * config/config.guess (main): Don't use `head -1'; it's no longer
24938         portable. Use `sed 1q' instead.
24939
24940 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
24941
24942         * m4/codeset.m4: Upgrade to gettext-0.11.
24943         * m4/gettext.m4: Upgrade to gettext-0.11.
24944         * m4/glibc21.m4: Upgrade to gettext-0.11.
24945         * m4/iconv.m4: Upgrade to gettext-0.11.
24946         * m4/isc-posix.m4: Upgrade to gettext-0.11.
24947         * m4/lcmessage.m4: Upgrade to gettext-0.11.
24948         * m4/lib-ld.m4: New file, from gettext-0.11.
24949         * m4/lib-link.m4: New file, from gettext-0.11.
24950         * m4/lib-prefix.m4: New file, from gettext-0.11.
24951         * m4/progtest.m4: Upgrade to gettext-0.11.
24952
24953 2002-02-15  Paul Eggert  <eggert@twinsun.com>
24954
24955         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
24956         (jm_PREREQ): Use it.
24957
24958 2002-02-15  Paul Eggert  <eggert@twinsun.com>
24959
24960         * lib/posixver.c, lib/posixver.h: New files.
24961         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
24962
24963 2002-02-02  Paul Eggert  <eggert@twinsun.com>
24964             Bruno Haible  <bruno@clisp.org>
24965
24966         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
24967         (fwrite_success_callback): New declaration.
24968         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
24969         print_unicode_char. Call failure callback instead of error.
24970         (fwrite_success_callback): New function.
24971         (exit_failure_callback): New function.
24972         (fallback_failure_callback): New function.
24973         (print_unicode_char): Call unicode_to_mb.
24974
24975 2002-01-26  Jim Meyering  <meyering@lucent.com>
24976
24977         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
24978         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
24979
24980 2002-01-26  Jim Meyering  <meyering@lucent.com>
24981
24982         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
24983
24984 2002-01-22  Paul Eggert  <eggert@twinsun.com>
24985
24986         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
24987
24988 2002-01-22  Jim Meyering  <meyering@lucent.com>
24989
24990         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
24991         Otherwise, some versions of automake would omit the rule that makes
24992         Makefile from Makefile.in.
24993
24994 2002-01-21  Paul Eggert  <eggert@twinsun.com>
24995
24996         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
24997         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
24998         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
24999         (memcoll): Set errno to zero if there is no error.
25000
25001         * lib/quotearg.c (quotearg_buffer_restyled):
25002         Fix bug with quoting buffers containing NUL when backslashing escapes.
25003         This bug was exposed by the other changes in this patch.
25004         (quotearg_n_options): New arg ARGSIZE.
25005         All callers changed.
25006         (quoting_options_from_style): New function.
25007         (quotearg_n_style): Use it.
25008         (quotearg_n_style_mem): New function.
25009
25010         * lib/quotearg.h (quotearg_n_style_mem): New function.
25011
25012 2002-01-19  Jim Meyering  <meyering@lucent.com>
25013
25014         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
25015         Remove useless quotes: DF_PROG="df".
25016         * m4/strnlen.m4: New file.
25017
25018 2002-01-16  Paul Eggert  <eggert@twinsun.com>
25019
25020         * lib/backupfile.c (ISDIGIT): Comment fix.
25021         * lib/getdate.y (ISDIGIT): Likewise.
25022         * lib/posixtm.c (ISDIGIT, year): Likewise.
25023         * lib/strverscmp.c (ISDIGIT): Likewise.
25024         * lib/userspec.c (ISDIGIT): Likewise.
25025
25026 2002-01-16  Jim Meyering  <meyering@lucent.com>
25027
25028         * lib/getdate.y: Add three semicolons, each just before a closing
25029         brace. Bison (as of version 1.31) no longer papers over that mistake.
25030
25031 2002-01-05  Jim Meyering  <meyering@lucent.com>
25032
25033         * lib/version-etc.c (version_etc_copyright): Update copyright year.
25034
25035 2001-12-19  Paul Eggert  <eggert@twinsun.com>
25036
25037         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
25038         not silently exit merely because the output buffer happens to
25039         have nothing pending.
25040
25041 2001-12-18  Paul Eggert  <eggert@twinsun.com>
25042
25043         See the big note in ../ChangeLog.
25044         * lib/human.c (suffixes): Prefer K to k for 1024.
25045         (generate_suffix_backwards): New function.
25046         (human_readable_inexact): Use it.
25047         * lib/xstrtol.c (__xstrtol): If there is no number but there
25048         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
25049         Accept 'K' as well as 'k'.
25050
25051 2001-12-15  Jim Meyering  <meyering@lucent.com>
25052
25053         * lib/regex.h (__restrict_arr): Update from libc.
25054
25055         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
25056         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
25057         (STREQ): Define.
25058
25059 2001-12-14  Jim Meyering  <meyering@lucent.com>
25060
25061         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
25062         Suggestion from Bruno Haible.
25063
25064 2001-12-10  Jim Meyering  <meyering@lucent.com>
25065
25066         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
25067         xrealloc, Instead, include "xalloc.h".
25068         (initbuffer): Don't cast xmalloc return value to char*.
25069         (readline): Reword comment.
25070         Don't cast xrealloc return value to char*
25071         Return NULL, not 0.
25072
25073 2001-12-09  Jim Meyering  <meyering@lucent.com>
25074
25075         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
25076         about `signed and unsigned type in conditional expression'.
25077         * lib/posixtm.c (posix_time_parse): Likewise.
25078
25079         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
25080
25081         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
25082         to avoid a pedantic warning.
25083
25084         * lib/getstr.c: Don't include assert.h.
25085         (getstr): Remove warning-evoking assertions.
25086         Return -1 if offset parameter is out of bounds.
25087         Change the type of a local from int to size_t.
25088
25089         * lib/strftime.c (my_strftime_localtime_r): Include this function
25090         definition in the `#if ! HAVE_TM_GMTOFF' block.
25091
25092         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
25093         Include xalloc.h instead.
25094
25095 2001-12-02  Jim Meyering  <meyering@lucent.com>
25096
25097         * lib/tempname.c: Don't declare getenv, thus reverting the change of
25098         2001-11-18.  It's no longer necessary, now that stdlib.h is always
25099         included.
25100
25101         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
25102         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
25103
25104 2001-11-30  Akim Demaille  <akim@epita.fr>
25105
25106         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
25107         before being defined.
25108
25109 2001-11-27  Paul Eggert  <eggert@twinsun.com>
25110
25111         * lib/quotearg.h (quotearg_n, quotearg_n_style):
25112         First arg is int, not unsigned.
25113         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
25114         (SIZE_MAX, UINT_MAX): New macros.
25115         (quotearg_n_options): Abort if N is negative.
25116         Avoid overflow check on hosts where size_t is 64 bits and int
25117         is 32 bits, as overflow is impossible there.
25118         Fix off-by-one typo that caused unnecessary reallocation.
25119
25120 2001-11-27  Jim Meyering  <meyering@lucent.com>
25121
25122         * lib/tempname.c: Merge with version from libc.
25123         * lib/regex.c: Likewise.
25124
25125         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
25126         systems for which STDC_HEADERS is 0, it was not included, resulting in
25127         a warning about an integer-to-pointer conversion problem with getenv.
25128         Reported by Volker Borchert.
25129
25130 2001-11-26  Jim Meyering  <meyering@lucent.com>
25131
25132         * lib/gtod.h: Remove file.
25133         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
25134         * lib/gettimeofday.c: Don't include gtod.h.
25135         (GTOD_init): Remove function.
25136         (rpl_gettimeofday): Do its job here instead, rather than aborting.
25137         Suggestion from Volker Borchert.
25138
25139 2001-11-23  Jim Meyering  <meyering@lucent.com>
25140
25141         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
25142         it.
25143         * lib/hash.c (struct hash_table): Define it here instead.
25144
25145 2001-11-22  Jim Meyering  <meyering@lucent.com>
25146
25147         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
25148
25149 2001-11-20  Jim Meyering  <meyering@lucent.com>
25150
25151         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
25152         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
25153
25154 2001-11-19  Jim Meyering  <meyering@lucent.com>
25155
25156         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
25157         directory.  Use "conftestXXXXXX" as the template.
25158         Suggestion from Paul Eggert.
25159
25160         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
25161         immediately, so the test doesn't mistakenly hit the max-open-files
25162         limit.
25163
25164 2001-11-18  Paul Eggert  <eggert@twinsun.com>
25165
25166         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
25167         (TEMPORARIES): New macro.
25168         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
25169         removes an artificial limitation (e.g. HP-UX 10.20, where
25170         TMP_MAX is 17576).
25171
25172 2001-11-18  Jim Meyering  <meyering@lucent.com>
25173
25174         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
25175
25176 2001-11-18  Jim Meyering  <meyering@lucent.com>
25177
25178         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
25179         on SunOS 4.
25180
25181         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
25182         files will be created before anything else.
25183
25184 2001-11-17  Paul Eggert  <eggert@twinsun.com>
25185
25186         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
25187         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
25188
25189 2001-11-17  Jim Meyering  <meyering@lucent.com>
25190
25191         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
25192         Prompted by a report from Bob Proulx.
25193
25194         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
25195         Instead, require UTILS_FUNC_MKSTEMP.
25196
25197 2001-11-17  Jim Meyering  <meyering@lucent.com>
25198
25199         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
25200         Now, that's done as part of AC_FUNC_STRTOD.
25201
25202 2001-11-17  Jim Meyering  <meyering@lucent.com>
25203
25204         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
25205         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
25206         rather than group writable.  Patch by Juan F. Codagnone.
25207
25208         * lib/readtokens.c: Remove explicit declarations of xmalloc and
25209         xrealloc, Instead, include "xalloc.h".
25210
25211         * lib/mountlist.c: Include unlocked-io.h after all system headers.
25212         Remove explicit declarations of xmalloc, xrealloc,
25213         and xstrdup.  Instead, include "xalloc.h".
25214
25215         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
25216         unlocked-io.h.
25217         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
25218         Likewise.
25219         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
25220
25221         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
25222         Reported by Padraig Brady.
25223
25224         * lib/mkstemp.c: #undef mkstemp.
25225         Include config.h.
25226         (rpl_mkstemp): Rename from mkstemp.
25227         Protoize.
25228
25229 2001-11-16  Jim Meyering  <meyering@lucent.com>
25230
25231         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
25232         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
25233         determine the amount of total physical memory, use pstat_getstatic.
25234         HPUX-11 doesn't define _SC_PHYS_PAGES.
25235         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
25236         If sysconf couldn't be used to determine the amount of available
25237         physical memory, use both pstat_getstatic and pstat_getdynamic.
25238         Based on a patch from Bob Proulx.
25239
25240 2001-11-10  Jim Meyering  <meyering@lucent.com>
25241
25242         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
25243         (jm_PREREQ): Use it.
25244
25245 2001-11-09  Jim Meyering  <meyering@lucent.com>
25246
25247         * m4/jm-macros.m4: Require autoconf-2.52f.
25248         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
25249         Use these AC_-prefixed names, not the AM_-prefixed ones.
25250
25251         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
25252
25253 2001-11-05  Jim Meyering  <meyering@lucent.com>
25254
25255         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
25256
25257 2001-11-04  Jim Meyering  <meyering@lucent.com>
25258
25259         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
25260         $DEFS.
25261
25262 2001-11-03  Jim Meyering  <meyering@lucent.com>
25263
25264         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
25265         of AC_DEFUN.
25266
25267         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
25268         know the name of the variable in the macro definition.
25269
25270 2001-11-03  Jim Meyering  <meyering@lucent.com>
25271
25272         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
25273         in argmatch_to_argument call.
25274
25275         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
25276         argument.
25277
25278         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
25279         e.g., a fault due to an attempt to free a NULL pointer.
25280
25281 2001-11-01  Jim Meyering  <meyering@lucent.com>
25282
25283         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
25284         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
25285
25286 2001-11-01  Jim Meyering  <meyering@lucent.com>
25287
25288         * lib/dirfd.c, lib/dirfd.h: New files.
25289         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
25290
25291         * lib/hash.c (hash_print) [TESTING]: Clean up.
25292
25293 2001-10-22  Paul Eggert  <eggert@twinsun.com>
25294
25295         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
25296         to avoid a warning if -Wall.
25297
25298 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
25299
25300         * README: New file
25301         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
25302         (per RMS's instructions, this is now the canonical source)
25303         * lgpl/, gpl/: New directories.
25304
25305 2001-10-21  Paul Eggert  <eggert@twinsun.com>
25306
25307         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
25308
25309 2001-10-21  Jim Meyering  <meyering@lucent.com>
25310
25311         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
25312         this code would end up calling gettext even in packages built
25313         with --disable-nls.
25314         * lib/getopt.c (_): Likewise.
25315         * lib/regex.c (_): Likewise.
25316
25317 2001-10-20  Paul Eggert  <eggert@twinsun.com>
25318
25319         * m4/error.m4 (jm_PREREQ_ERROR):
25320         Do not invoke AC_CHECK_FUNCS with strerror_r, as
25321         AC_FUNC_STRERROR_R does that.
25322         Check for strerror declaration.
25323
25324         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
25325         are supposed to have them these days.
25326         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
25327         Merge changes from latest Autoconf CVS.
25328         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
25329         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
25330         POSIX decided to standardize on the int flavor of strerror_r.
25331
25332 2001-10-20  Paul Eggert  <eggert@twinsun.com>
25333
25334         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
25335         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
25336         Use strerror_r that is only a macro, even if it is not a function.
25337         (strerror): Check for HAVE_DECL_STRERROR before declaring.
25338         (private_strerror): Use prototypes, not old-style function definition.
25339         (print_errno_message): New function.
25340         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
25341         char*-flavored one.
25342         (error_tail, error, error_at_line): Use it.
25343
25344 2001-10-11  Jim Meyering  <meyering@lucent.com>
25345
25346         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
25347         and quote_n (1, ... to avoid clobbering a buffer.
25348
25349 2001-10-05  Jim Meyering  <meyering@lucent.com>
25350
25351         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
25352         hash-pjw.h.
25353         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
25354         * lib/hash-pjw.h: New file.
25355
25356 2001-09-30  Jim Meyering  <meyering@lucent.com>
25357
25358         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
25359         `struct fsstat' has the `f_fstypename' member.
25360         Use that to define FS_TYPE, which is now used to make
25361         the getfsstat link test tighter.
25362
25363 2001-09-30  Jim Meyering  <meyering@lucent.com>
25364
25365         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
25366         Include <sys/ucred.h>, for Apple Darwin.
25367         Include sys/mount.h and sys/fs_types.h only if available.
25368         (FS_TYPE): Define.
25369         (read_filesystem_list): Use FS_TYPE.
25370
25371 2001-09-29  Paul Eggert  <eggert@twinsun.com>
25372
25373         * lib/exclude.c (excluded_filename): 0 -> false, since it's
25374         a boolean context.
25375
25376 2001-09-29  Jim Meyering  <meyering@lucent.com>
25377
25378         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
25379         [one-argument getmntent function]): Include stdio.h before mntent.h.
25380         SunOS 4.1.x needs it for the declaration of `FILE'.
25381         Patch by Volker Borchert.
25382
25383         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
25384         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
25385         sys/fs_types.h, and make the link-test for getfsstat guard #include
25386         directives with appropriate #if HAVE_*_H tests so that we can
25387         detect getfsstat on Apple Darwin1.3.7 systems.
25388         Reported by Nelson Beebe.
25389         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
25390
25391 2001-09-28  Paul Eggert  <eggert@twinsun.com>
25392
25393         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
25394         #defines strtoimax.  Also treat the other strto* functions
25395         like strtoimax.
25396
25397         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
25398         Check for strtoul and strtoumax,
25399         as those declarations are made even in the signed case.
25400         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
25401         Likewise, for strtol and strtoimax.
25402
25403 2001-09-28  Paul Eggert  <eggert@twinsun.com>
25404
25405         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
25406         #defines strtoimax.  Also treat the other strto* functions
25407         like strtoimax.
25408
25409         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
25410         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
25411         (strtoimax, strtoumax): Do not declare if already defined as a macro.
25412
25413 2001-09-26  Jim Meyering  <meyering@lucent.com>
25414
25415         Most macros in unlocked-io.h had the wrong number of arguments.
25416         * lib/gen-uio: New script.
25417         (USE_UNLOCKED_IO): Define to 1 if not already defined.
25418         * lib/unlocked-io.hin: Remove file.
25419         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
25420         rather than trying to embed it here.
25421         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
25422         Reported by Padraig Brady.
25423
25424 2001-09-25  Volker Borchert  <bt@teknon.de>
25425
25426         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
25427         `result'.
25428
25429 2001-09-24  Jim Meyering  <meyering@lucent.com>
25430
25431         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
25432
25433 2001-09-23  Jim Meyering  <meyering@lucent.com>
25434
25435         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
25436         instead of the mere test for existence of mntent.h.  The latter
25437         would get a false-positive on AIX 3.4 systems.
25438         In the outer getmntent if-block, don't die if neither of the getmntent
25439         tests succeeds.  Instead, just fall through and continue with the
25440         remaining tests.
25441
25442 2001-09-23  Jim Meyering  <meyering@lucent.com>
25443
25444         * lib/mountlist.c: Remove useless parentheses in #if directives.
25445         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
25446         the deprecated MOUNTED symbol is no longer defined in mntent.h.
25447
25448 2001-09-22  Jim Meyering  <meyering@lucent.com>
25449
25450         * m4/gettext.m4: New file.  From gettext.
25451         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
25452         * m4/progtest.m4: Likewise
25453         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
25454         * m4/glibc21.m4: Likewise.
25455
25456         * m4/libintl.m4: Remove.  No longer used.
25457
25458 2001-09-22  Jim Meyering  <meyering@lucent.com>
25459
25460         * lib/localcharset.c: Update from latest gettext.
25461         * lib/config.charset: Likewise.
25462
25463 2001-09-20  Jim Meyering  <meyering@lucent.com>
25464
25465         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
25466         strtoimax.
25467         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
25468         strtoumax.
25469
25470 2001-09-20  Jim Meyering  <meyering@lucent.com>
25471
25472         * lib/xstrtol.c (strtoimax): Guard declaration with
25473         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
25474         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
25475         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
25476         (strtoumax): Likewise, for completeness (it wasn't necessary).
25477
25478 2001-09-17  Paul Eggert  <eggert@twinsun.com>
25479
25480         * lib/strtoimax.c (HAVE_LONG_LONG):
25481         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
25482         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
25483         to work around bug in IBM C compiler.
25484
25485 2001-09-17  Jim Meyering  <meyering@lucent.com>
25486
25487         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
25488         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
25489         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
25490         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
25491         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
25492         whenever the right hand side need not be expanded by the shell.
25493
25494 2001-09-16  Paul Eggert  <eggert@twinsun.com>
25495
25496         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
25497         library.  It's not correct, as some older glibcs are buggy.
25498         fnmatch wasn't fixed until glibc 2.2.
25499
25500         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
25501         special shell magic here.
25502
25503 2001-09-16  Jim Meyering  <meyering@lucent.com>
25504
25505         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
25506         * m4/jm-macros.m4: Require it.
25507
25508 2001-09-16  Jim Meyering  <meyering@lucent.com>
25509
25510         * lib/mkdir.c: New file.
25511
25512 2001-09-15  Jim Meyering  <meyering@lucent.com>
25513
25514         * m4/jm-macros.m4: Check for help2man.
25515
25516 2001-09-11  Jim Meyering  <meyering@lucent.com>
25517
25518         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
25519         The body, by Paul Eggert, was moved here from configure.in.
25520         * m4/jm-macros.m4: Require UTILS_HOST_OS.
25521
25522 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25523
25524         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
25525         (jm_PREREQ): Use it.
25526
25527 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25528
25529         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
25530         Use ssize_t, not int, to store result of readlink.
25531         Check for ssize_t overflow as well as size_t overflow,
25532         as POSIX says the result of readlink is implementation-defined
25533         when ssize_t overflows.
25534         Remove unnecessary cast to char*.
25535         Use free+malloc instead of realloc, as the storage doesn't need
25536         to be preserved and it's clearer and can be more efficient that way.
25537         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
25538         * lib/xreadlink.h (xreadlink): Update prototype.
25539
25540 2001-09-04  Paul Eggert  <eggert@twinsun.com>
25541
25542         * lib/xgetcwd.c: Revert some of the previous change; intead,
25543         fix the HAVE_GETCWD_NULL code to behave more like the
25544         !HAVE_GETCWD_NULL code used to.
25545
25546         Include "xalloc.h".
25547         (xgetcwd): Do not return NULL when memory is exhausted; instead,
25548         invoke xalloc_die.
25549
25550 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25551
25552         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
25553         sys/param.h, as pathmax.h includes them.
25554
25555 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25556
25557         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
25558         (jm_PREREQ_XGETCWD): New macro.
25559
25560         * m4/getcwd.m4: New file.
25561
25562 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25563
25564         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
25565         like the HAVE_GETCWD_NULL code.
25566         Include pathmax.h if not HAVE_GETCWD.
25567         Do not include xalloc.h.
25568         (INITIAL_BUFFER_SIZE): New symbol.
25569         Do not use xmalloc / xrealloc, since the caller is responsible for
25570         handling errors.  Preserve errno around `free' during failure.
25571         Do not overrun buffer when using getwd.
25572
25573 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25574
25575         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
25576         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
25577         getcwd (NULL, 0).
25578
25579 2001-09-03  Paul Eggert  <eggert@twinsun.com>
25580
25581         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
25582         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
25583         spotted by Jim Meyering.
25584
25585 2001-09-03  Jim Meyering  <meyering@lucent.com>
25586
25587         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
25588         failure.
25589
25590 2001-09-02  Jim Meyering  <meyering@lucent.com>
25591
25592         * lib/error.c: Update from GNU libc.
25593
25594 2001-09-01  Jim Meyering  <meyering@lucent.com>
25595
25596         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
25597         Used by df.
25598
25599 2001-09-01  Jim Meyering  <meyering@lucent.com>
25600
25601         * lib/xreadlink.c: New file.
25602         * lib/xreadlink.h: New file.
25603         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
25604         xreadlink.h.
25605
25606         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
25607         doesn't conflict with sparc Solaris 7's definition in
25608         /usr/include/sys/int_types.h.
25609
25610         * lib/exclude.c: Use `""', not `<>' to #include non-system header
25611         files.
25612         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
25613         and strncasecmp as r-values.  Unixware didn't have declarations.
25614
25615 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25616
25617         * lib/xstrtol.h: Add copyright notice.
25618         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
25619         LONGINT_INVALID_SUFFIX_CHAR.
25620
25621 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25622
25623         * lib/xstrtol.c (strtoimax): New decl.
25624
25625 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25626
25627         * lib/xgetcwd.c: Don't include pathmax.h.
25628         Include stdlib.h and unistd.h if available.
25629         Include xalloc.h.
25630         (xmalloc, xstrdup, free): Remove decls.
25631         (xgetcwd): Don't assume sizes fit in unsigned.
25632         Check for overflow when computing sizes.
25633         Simplify reallocation code.
25634
25635 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25636
25637         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
25638         a directory's st_size can have an arbitrary value, so the old
25639         usage could waste an arbitrary amount of memory.  All uses
25640         changed.
25641         * lib/savedir.h: Update prototype.
25642
25643 2001-08-31  Paul Eggert  <eggert@twinsun.com>
25644
25645         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
25646
25647         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
25648         old strtoimax.c.
25649
25650         Also, make the following further changes to make this file's
25651         configuration more similar to that of strtol.c:
25652         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
25653         (strtoumax, uintmax_t, strtoull, strtol): Remove.
25654         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
25655         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
25656         changed to signed values.
25657
25658         And make the following changes as well:
25659         Fix copyright notice, as 1999 was missing.
25660         (verify): New macro.
25661         (strtoimax): Check sizes at compile-time, not run-time.
25662         Prefer strtol to strtoll if both work.
25663         (main): Remove; it was not that useful and was a pain to maintain.
25664
25665         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
25666
25667 2001-08-31  Jim Meyering  <meyering@lucent.com>
25668
25669         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
25670         Use an initial, malloc'd, buffer of length 128 rather than
25671         a statically allocated one of length 1024.
25672
25673 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25674
25675         Simplify code, partly by assuming autoconf 2.52 semantics.
25676
25677         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
25678
25679         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
25680         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
25681         All uses removed.
25682         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
25683         Move AC_REQUIRE to next-to-top level, to avoid confusion.
25684         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
25685         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
25686         jm_AC_HEADER_INTTYPES_H.
25687         * m4/jm-macros.m4 (jm_MACROS): Likewise.
25688
25689         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
25690
25691         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
25692         Quote first arg of AC_DEFUN.
25693         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
25694         since they are needed to parse the include file even if we need
25695         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
25696         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
25697         but with opposite signedness.
25698
25699 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25700
25701         Merge 'exclude' changes from tar 1.13.22.
25702         This fixes one or two unlikely storage allocation overflow bugs,
25703         but doesn't change user-visible behavior otherwise.
25704
25705 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25706
25707         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
25708         (jm_PREREQ_EXCLUDE): New macro.
25709
25710 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25711
25712         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
25713         tm to be declared.
25714
25715 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25716
25717         * lib/hash.c: Remove '2001' from copyright notice.
25718
25719 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25720
25721         * lib/full-write.h: New file.
25722         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
25723         * lib/full-write.c: Correct credits, as cccp.c no longer
25724         exists and anyway it was so heavily changed from the old cccp
25725         code as to be unrecognizable.  Include full-write.h.
25726         (full_write) Return size_t, with short writes meaning failure.
25727         All callers changed.  This fixes a bug with large buffers
25728         on 64-bit hosts.
25729         * lib/utime.c: Include full-write.h.
25730
25731 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25732
25733         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
25734         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
25735         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
25736         Include if available.
25737         (<xalloc.h>): Include
25738         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
25739         (verify): New macro.  Use it to verify that EXCLUDE macros do not
25740         collide with FNM macros.
25741         (struct patopts): New struct.
25742         (struct exclude): Use it, as exclude patterns now come with options.
25743         (new_exclude): Support above changes.
25744         (new_exclude, add_exclude_file):
25745         Initial size must now be a power of two to simplify overflow checking.
25746         (free_exclude, fnmatch_no_wildcards): New function.
25747         (excluded_filename): No longer requires options arg, as the options
25748         are determined by add_exclude.  Now returns bool, not int.
25749         (excluded_filename, add_exclude):
25750         Add support for the fancy new exclusion options.
25751         (add_exclude, add_exclude_file): Now takes int options arg.
25752         Check for arithmetic overflow when computing sizes.
25753         (add_exclude_file): xrealloc might modify errno, so don't
25754         realloc until after errno might be used.
25755
25756         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
25757         New macros.
25758         (free_exclude): New decl.
25759         (add_exclude, add_exclude_file): Now takes int options arg.
25760         (excluded_filename): No longer requires options arg, as the options
25761         are determined by add_exclude.  Now returns bool, not int.
25762
25763 2001-08-30  Paul Eggert  <eggert@twinsun.com>
25764
25765         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
25766
25767 2001-08-27  Jim Meyering  <meyering@lucent.com>
25768
25769         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
25770
25771         * lib/version-etc.c (N_): Remove definition.
25772         Revert most of last change.
25773         Instead, simply don't mark the `Copyright...' string for translation.
25774         Based on advice from Paul Eggert.
25775
25776         * lib/strtoxmax.c: Tweak comment.
25777
25778 2001-08-26  Jim Meyering  <meyering@lucent.com>
25779
25780         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
25781
25782         * m4/xstrtoimax.m4: New file.
25783         * m4/xstrtoumax.m4: Add comments explaining why we
25784         AC_REPLACE_FUNCS(strtol).
25785
25786 2001-08-26  Jim Meyering  <meyering@lucent.com>
25787
25788         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
25789         of copyright with `%s' so translators don't get an untranslated
25790         message in 2002.
25791         (COPYRIGHT_YEAR): Define.
25792         (version_etc): Use fprintf rather than fputs.
25793         Suggestion from Ulrich Drepper.
25794
25795         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
25796
25797         * lib/strtoll.c: New file, from GNU libc.
25798         * lib/xstrtoimax.c: New file.
25799
25800         * lib/xstrtol.h: Add xstrtoimax.
25801         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
25802         * lib/strtoimax.c: New file.  Likewise, but first define
25803         STRTOUXMAX_SIGNED.
25804
25805         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
25806         ...
25807         * lib/strtoxmax.c: ... then renamed to this.
25808
25809 2001-08-18  Paul Eggert  <eggert@twinsun.com>
25810
25811         * m4/inttypes.m4: Add AC_PREREQ(2.13).
25812         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
25813         (jm_AC_TYPE_INTMAX_T): New macro.
25814         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
25815
25816         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
25817
25818         * m4/longlong.m4: Renamed from ulonglong.m4.
25819         * m4/inttypes.m4: Renamed from inttypes_h.m4.
25820         * m4/uintmax_t.m4: Removed.
25821
25822 2001-08-13  Paul Eggert  <eggert@twinsun.com>
25823
25824         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
25825         Port to Solaris 8, where 'sed' requires a space after the 'r'
25826         command, and where sh dislikes "$/".  Clean up the spacing a bit.
25827         Redirect output to $tmp just once.
25828
25829 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
25830
25831         * lib/addext.c (<errno.h>): Include.
25832         (errno): Declare if not defined.
25833         (addext): Work correctly when pathconf returns -1 and leaves
25834         errno alone because there is no limit.  Also, work even if
25835         pathconf returns a value greater than SIZE_MAX.
25836
25837 2001-08-12  Jim Meyering  <meyering@lucent.com>
25838
25839         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
25840         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
25841         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
25842         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
25843         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
25844         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
25845         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
25846         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
25847         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
25848         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
25849         utime.m4, utimes.m4, xstrtoumax.m4:
25850         Quote the first argument in each use of AC_DEFUN.
25851
25852 2001-08-12  Jim Meyering  <meyering@lucent.com>
25853
25854         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
25855         Simply `return getcwd (NULL, 0);'.
25856         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
25857         Use 1300 as initial value for length, not PATH_MAX.
25858
25859         * lib/pathmax.h: Clean up cpp syntax.
25860
25861 2001-08-12  Jim Meyering  <meyering@lucent.com>
25862
25863         * lib/gettimeofday.c: New file.
25864         * lib/gtod.h: New file.
25865         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
25866
25867 2001-08-05  Jim Meyering  <meyering@lucent.com>
25868
25869         * m4/jm-macros.m4: Require autoconf-2.52.
25870
25871 2001-08-04  Jim Meyering  <meyering@lucent.com>
25872
25873         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
25874         stmt, to get in sync with glibc.
25875
25876 2001-08-03  Paul Eggert  <eggert@twinsun.com>
25877
25878         The following changes are from gettext 0.10.39 as maintained by
25879         Bruno Haible.
25880
25881         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
25882         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
25883         with inverted sense.  All uses changed.
25884
25885         * lib/mbswidth.c: Don't include <limits.h>.
25886         Include <stdlib.h> and <string.h> unconditionally.
25887         (iswcntrl, mbsinit, ISCNTRL): New macros.
25888         (mbsnwidth): Use K&R style function declarations.
25889         Don't bother checking for MB_LEN_MAX == 1, since the compiler
25890         can optimize it when MB_CUR_MAX == 1.
25891         The width of control characters is zero, not 1.
25892
25893 2001-08-03  Paul Eggert  <eggert@twinsun.com>
25894
25895         The following changes are from gettext 0.10.39 as maintained by
25896         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
25897
25898         * m4/codeset.m4: Upgrade to serial AM1.
25899         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
25900         all uses changed.  Quote first arg of AC_DEFUN.
25901         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
25902
25903         * m4/iconv.m4: Upgrade to serial AM2.
25904         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
25905         Add --with-libconv-prefix.
25906         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
25907         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
25908         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
25909         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
25910         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
25911
25912         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
25913         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
25914         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
25915         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
25916         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
25917         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
25918         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
25919         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
25920         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
25921
25922         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
25923         string.h any more.
25924
25925         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
25926         not the default value.
25927
25928         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
25929         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
25930         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
25931         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
25932         Also check for iswcntrl, used for wcwidth fallback.
25933         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
25934         to Autoconf 2.13.
25935
25936 2001-08-03  Jim Meyering  <meyering@lucent.com>
25937
25938         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
25939         as it was in the original.  Reported by Paul Eggert.
25940
25941 2001-07-16  Jim Meyering  <meyering@lucent.com>
25942
25943         * m4/gettimeofday.m4: New file.
25944         Prompted by a report from Bernhard Baehr.
25945
25946 2001-07-15  Jim Meyering  <meyering@lucent.com>
25947
25948         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
25949         stuff. Now it's in ../Makefile.cfg.
25950
25951 2001-07-15  Jim Meyering  <meyering@lucent.com>
25952
25953         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
25954         (BUILT_SOURCES): Add unlocked-io.h.
25955         (io_functions): Define.
25956         (unlocked-io.h): New rule.
25957         (DISTCLEANFILES): Add unlocked-io.h.
25958         (all-local): Depend on unlocked-io.h, to ensure it is created.
25959
25960         * lib/unlocked-io.hin: New file
25961
25962         * lib/regex.c: Update from glibc.
25963
25964 2001-07-05  Jim Meyering  <meyering@lucent.com>
25965
25966         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
25967         recommendation.
25968         (libfetish_a_SOURCES): Put all .h files here instead.
25969         Remove a thus-exposed (better checks in automake) duplicate and
25970         two unnecessary .h files.
25971
25972 2001-07-04  Jim Meyering  <meyering@lucent.com>
25973
25974         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
25975         that generates jm-glibc-io.m4 so that it doesn't trigger any make
25976         distcheck failure.
25977
25978 2001-07-02  Jim Meyering  <meyering@lucent.com>
25979
25980         The following changes were prompted by suggestions from Bruno Haible.
25981
25982         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
25983         is now generated.
25984         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
25985         definition of EXTRA_DIST.
25986         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
25987         ensure that the generated file is created/updated whenever the list
25988         of $(unlocked_functions) is changed.
25989         (jm-glibc-io.m4): New rule.
25990         (unlocked-io.h): New rule -- currently unused.
25991
25992 2001-06-24  Jim Meyering  <meyering@lucent.com>
25993
25994         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
25995         unmatched right bracket, rather than kludging it with an extra,
25996         falsely-matching quote in a comment.  Patch by Akim Demaille.
25997
25998 2001-06-11  Jim Meyering  <meyering@lucent.com>
25999
26000         * lib/regex.c: Update from GNU libc.
26001
26002 2001-05-27  Jim Meyering  <meyering@lucent.com>
26003
26004         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
26005         Check for ut_type in struct utmp.
26006
26007 2001-05-27  Jim Meyering  <meyering@lucent.com>
26008
26009         * lib/readutmp.h (UT_TYPE): Define.
26010
26011 2001-05-24  Jim Meyering  <meyering@lucent.com>
26012
26013         * lib/argmatch.c: Include "quote.h".
26014         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
26015         quote function.  Reported by Göran Uddeborg.
26016
26017 2001-05-22  Jim Meyering  <meyering@lucent.com>
26018
26019         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
26020         now that we use the package-supplied version unconditionally.
26021         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
26022
26023 2001-05-21  Jim Meyering  <meyering@lucent.com>
26024
26025         * m4/regex.m4: Change a couple backticks to single quotes to avoid
26026         shell syntax errors.
26027
26028 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26029
26030         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
26031
26032 2001-05-20  Paul Eggert  <eggert@twinsun.com>
26033
26034         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
26035         Don't bother to check library strftime, since
26036         we'll be using our own my_strftime function anyway.
26037         Define my_strftime instead of strftime.
26038
26039 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
26040
26041         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
26042         which is not yet declared.
26043
26044 2001-05-15  Jim Meyering  <meyering@lucent.com>
26045
26046         * m4/regex.m4: Use proper quoting so brackets appear in the test
26047         program.
26048         Reported by, and with help from, Bruno Haible.
26049
26050 2001-05-13  Jim Meyering  <meyering@lucent.com>
26051
26052         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
26053         undefined.
26054
26055 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26056
26057         dirname code cleanup.  base_name now behaves more compatibly
26058         with POSIX basename when given file names that have trailing
26059         slashes, and similarly for dir_name.  Add new primitives
26060         base_len and dir_len.  Put the directory-name-related decls
26061         into dirname.h.
26062
26063         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
26064         * lib/backupfile.c (base_name): Likewise.
26065         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
26066         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
26067         * lib/makepath.c (strip_trailing_slashes): Likewise.
26068         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
26069         ISSLASH): Likewise.
26070         * lib/rename.c (strip_trailing_slashes): Likewise.
26071         * lib/same.c (base_name): Likewise.
26072         * lib/stripslash.c (ISSLASH): Likewise.
26073
26074         * lib/addext.c: Include <dirname.h> after size_t is defined.
26075         * lib/backupfile.c: Likewise.
26076
26077         * lib/addext.c (addext): Use base_len to trim redundant
26078         trailing slashes instead of doing it ourselves.
26079         But do not trim the last slash if it is not redundant.
26080
26081         * lib/backupfile.c (find_backup_file_name,
26082         max_backup_version): Use base_len instead of rolling it ourselves.
26083         Handle the case of "" and (on DOS) "C:" correctly.
26084
26085         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
26086         needed. Include <string.h>, <dirname.h>.
26087         (base_name): Allow file names ending in slashes, other than names
26088         that are all slashes.  In this case, return the basename followed
26089         by the slashes.  This is more general, and can be used in places
26090         where the original base_name purposely had an assertion failure.
26091         (base_len): New function.
26092
26093         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
26094         Do not include <assert.h>; no longer needed.
26095         Include xalloc.h.
26096         (memrchr): Remove decl.
26097         (dir_name_r): Remove.
26098         (dir_len): Renamed from dirlen.  All callers changed.
26099         Rewrite in terms of base_name, for simplicity and consistency.
26100         (dir_name): Never return NULL.  All callers changed.
26101         Do not include <stdlib.h> in test program; no longer needed.
26102         return 0; is fine for test program.
26103
26104         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
26105         New macros.
26106         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
26107
26108         * lib/path-concat.c (path_concat): Use base_len to compute
26109         base length, not strlen; this means we cannot rely on memcpy
26110         to null-terminate.
26111
26112         * lib/same.c (STREQ): Remove.
26113         (same_name): Handle the case where the basename ends in trailing '/'.
26114
26115         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
26116         a slash was stripped.  Do not strip the last slash after a
26117         file system prefix.
26118
26119 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26120
26121         * lib/Makefile.am (libfetish_a_SOURCES):
26122         Add strftime.c, since we now compile it on all hosts.
26123
26124         * lib/strftime.c (my_strftime):
26125         Define to nstrftime if emacs, but only if my_strftime is not defined.
26126         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
26127         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
26128         Add one more extra argument: a nanoseconds value.
26129         All uses changed.
26130         (ns): New macro.
26131         (my_strftime function): Add %N format.
26132         (emacs_strftimeu): Renamed from emacs_strftime,
26133         with extra ut argument.
26134
26135 2001-05-09  Paul Eggert  <eggert@twinsun.com>
26136
26137         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
26138
26139 2001-04-21  Jim Meyering  <meyering@lucent.com>
26140
26141         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
26142         doesn't interfere.
26143
26144 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26145
26146         * m4/ftruncate.m4: Check for chsize.
26147         Link with ftruncate.o unconditionally if ftruncate is missing.
26148         This was required when cross-compiling to i586-mingw32msvc.
26149
26150 2001-04-08  Jim Meyering  <meyering@lucent.com>
26151
26152         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
26153         recomputed; that's necessary when the offset spans a DST transition.
26154         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
26155
26156 2001-04-02  Jim Meyering  <meyering@lucent.com>
26157
26158         * lib/regex.h, regex.c: Update from GNU libc.
26159
26160 2001-03-24  Jim Meyering  <meyering@lucent.com>
26161
26162         * m4/jm-macros.m4: Require autoconf-2.49d.
26163
26164 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
26165
26166         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
26167
26168 2001-03-19  Paul Eggert  <eggert@twinsun.com>
26169
26170         * lib/version-etc.c (version_etc_copyright): Update to 2001.
26171
26172 2001-03-17  Jim Meyering  <meyering@lucent.com>
26173
26174         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
26175         now that the version in autoconf is equivalent.
26176         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
26177
26178         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
26179         Suggestion from Akim Demaille.
26180
26181         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
26182         (jm_PREREQ_TEMPNAME): New function.
26183
26184 2001-03-16  Paul Eggert  <eggert@twinsun.com>
26185
26186         * lib/tempname.c (uint64_t): Define to uintmax_t if
26187         not defined, and if UINT64_MAX is not defined.
26188         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
26189         Reported by John David Anglin.
26190
26191 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
26192
26193         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
26194         resolve alias if codeset is empty.
26195         * lib/config.charset (BeOS): Use wildcard syntax.
26196
26197 2001-03-13  Jim Meyering  <meyering@lucent.com>
26198
26199         * lib/path-concat.c (path_concat)
26200         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
26201         concatenating e.g., `C:' and `foo'.
26202         From Bruno Haible.
26203
26204 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
26205
26206         * lib/localcharset.c (locale_charset): Don't use
26207         setlocale(LC_CTYPE,NULL). Don't return NULL.
26208         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
26209
26210 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
26211
26212         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
26213         support for DOS/DJGPP.
26214
26215 2001-03-01  Paul Eggert  <eggert@twinsun.com>
26216
26217         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
26218         lacks mkstemp.  Compile our own tempname.c if we compile our own
26219         mkstemp.c, as mkstemp relies on tempname.
26220
26221 2001-03-01  Jim Meyering  <meyering@lucent.com>
26222
26223         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
26224         AH_VERBATIM really does output its argument verbatim.
26225
26226 2001-02-28  Paul Eggert  <eggert@twinsun.com>
26227
26228         * lib/Makefile.am (libfetish_a_SOURCES):
26229         Add dup-safer.c, fopen-safer.c.
26230         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
26231
26232         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
26233         * lib/unistd-safer.h: New files.
26234
26235 2001-02-25  Paul Eggert  <eggert@twinsun.com>
26236
26237         The mkstemp replacement is taken from glibc 2.2.2, with some
26238         portability fixes for use outside glibc, as follows:
26239
26240         * lib/tempname.c (struct_stat64): New macro.
26241         (direxists, __gen_tempname): Use it.
26242         This avoids a portability problem with Solaris 8.
26243
26244         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
26245         (<stddef.h>, <stdint.h>, <string.h>):
26246         Include only if STDC_HEADERS || _LIBC.
26247         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
26248         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
26249         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
26250         (__set_errno): Define this macro if <errno.h> doesn't.
26251         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
26252         Define these macros if <stdio.h> doesn't.
26253         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
26254         Define these macros if <sys/stat.h>
26255         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
26256         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
26257         __xstat64): Define if not _LIBC.
26258         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
26259         (__gen_tempname): Invoke gettimeofday only if
26260         HAVE_GETTIMEOFDAY || _LIBC;
26261         otherwise, fall back on plain "time".
26262         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
26263
26264         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
26265
26266         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
26267
26268 2001-02-18  Paul Eggert  <eggert@twinsun.com>
26269
26270         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
26271
26272 2001-02-17  Paul Eggert  <eggert@twinsun.com>
26273
26274         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
26275         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
26276         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
26277         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
26278
26279 2001-02-17  Paul Eggert  <eggert@twinsun.com>
26280
26281         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
26282         Remove workaround macros for hosts that have mbrtowc but not
26283         mbstate_t, as we now insist on proper declarations for both
26284         before using mbrtowc.
26285
26286 2001-02-17  Jim Meyering  <meyering@lucent.com>
26287
26288         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
26289         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
26290         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
26291         UnixWare 7.1.1.
26292
26293         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
26294         rather than AC_CACHE_VAL.
26295
26296 2001-02-17  Jim Meyering  <meyering@lucent.com>
26297
26298         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
26299         around included file name.
26300
26301         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
26302
26303         * lib/strftime.c: Update from GNU libc (the only changes were to
26304         comments).
26305
26306 2001-02-17  Jim Meyering  <meyering@lucent.com>
26307
26308         * lib/regex.c: Update from libc.
26309
26310 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
26311
26312         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
26313         clash.
26314
26315 2001-02-16  Paul Eggert  <eggert@twinsun.com>
26316
26317         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
26318         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
26319         Reported by Mark Hounschell via Paul Eggert.
26320
26321 2001-02-07  Jim Meyering  <meyering@lucent.com>
26322
26323         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
26324
26325 2001-02-05  Jim Meyering  <meyering@lucent.com>
26326
26327         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
26328         it includes the patch required for `large file' support with at least
26329         HP-UX's 10.20 /bin/cc.
26330
26331 2001-02-03  Jim Meyering  <meyering@lucent.com>
26332
26333         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
26334         AS_IF, now that it works once again (mysteriously).
26335         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
26336
26337 2001-01-30  Jim Meyering  <meyering@lucent.com>
26338
26339         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
26340         * m4/chown.m4: Rename conftestchown to conftest.chown.
26341         * m4/rename.m4: s/conftestdir/conftest.d1/ and
26342         s/conftestdir2/conftest.d2/.
26343         * m4/utimes.m4: s/conftestdata/conftest.data/
26344         Inspired by Pavel Roskin's change in autoconf.
26345
26346 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
26347
26348         * lib/config.charset: Update for FreeBSD 4.2.
26349
26350 2001-01-27  Jim Meyering  <meyering@lucent.com>
26351
26352         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
26353         a use of AS_IF.
26354         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
26355
26356 2001-01-26  Jim Meyering  <meyering@lucent.com>
26357
26358         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
26359         quotearg.c includes it.
26360
26361 2001-01-26  Jim Meyering  <meyering@lucent.com>
26362
26363         * lib/quotearg.c: Include stddef.h.
26364         * lib/quote.c: Include stddef.h.
26365         Reported by Axel Kittenberger.
26366
26367         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
26368         line in double quotes so that it evokes a better diagnostic.
26369         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
26370         Reported by Axel Kittenberger.
26371
26372 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
26373
26374         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
26375         as if it was a `charset'.
26376
26377 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
26378
26379         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
26380         has const.
26381
26382 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
26383
26384         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
26385         to avoid a warning.  Add back 'const' to inptr.
26386
26387 2001-01-20  Jim Meyering  <meyering@lucent.com>
26388
26389         Be sure that headers are checked before used in code compiled
26390         for the type checks.
26391         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
26392         In place of that, invoke jm_CHECK_ALL_TYPES.
26393         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
26394         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
26395         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
26396         The check for ssize_t was mistakenly run before the test for unistd.h.
26397
26398         The configure-time check for stdbool.h was missing.
26399         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
26400         (jm_PREREQ_HASH): New function.
26401
26402 2001-01-17  Jim Meyering  <meyering@lucent.com>
26403
26404         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
26405         for autoconf-2.49c.
26406         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
26407
26408 2001-01-16  Jim Meyering  <meyering@lucent.com>
26409
26410         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
26411         From Bruno Haible.
26412
26413 2001-01-14  Jim Meyering  <meyering@lucent.com>
26414
26415         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
26416         foo and bar.  Create conftestdir/ in the script, not in the C code.
26417         Remove directories in the script, not in the C code.
26418         Remove conftestdir{,2} before trying to create the directory.
26419         Make the entire configure script fail if the mkdir fails.
26420
26421 2001-01-14  Jim Meyering  <meyering@lucent.com>
26422
26423         * lib/rename.c: New file.  From Volker Borchert.
26424         Include stdlib.h, string.h or strings.h, and xalloc.h.
26425         Use strip_trailing_slashes rather than open-coding it.
26426
26427 2001-01-03  Paul Eggert  <eggert@twinsun.com>
26428
26429         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
26430
26431 2001-01-03  Jim Meyering  <meyering@lucent.com>
26432
26433         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
26434         of local `inptr' to avoid warning with some system declarations of
26435         iconv.
26436
26437 2001-01-02  Volker Borchert  <bt@teknon.de>
26438
26439         * m4/rename.m4: New file.
26440         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
26441
26442 2001-01-01  Jim Meyering  <meyering@lucent.com>
26443
26444         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
26445         even on systems with utmpx.h.  It's necessary for the declaration of
26446         utmp's ut_user member.  Reported by Andreas Jaeger.
26447
26448         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
26449         available. They are required for the declarations of getgrgid and
26450         getpwuid resp.
26451         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
26452         Reported by Andreas Jaeger.
26453
26454 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
26455
26456         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
26457         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
26458         so `make install' also works in VPATH builds.
26459
26460 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
26461
26462         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
26463         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
26464         can be used in subdirectories.
26465
26466 2000-12-29  Paul Eggert  <eggert@twinsun.com>
26467
26468         * lib/modechange.c: Do not assume that mode_t uses the
26469         traditional octal encoding.  E.g. "chmod 1 FOO" should set
26470         the other-execute bit of FOO even if S_IXOTH != 1.
26471
26472         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
26473         WOTH, XOTH, ALLM): New macros.
26474         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
26475          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
26476         Use them.
26477         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
26478         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
26479         (mode_compile):
26480         No need to use uintmax_t; unsigned long is long enough.
26481         Don't bother to get suffix since we don't use it.
26482
26483 2000-12-26  Jim Meyering  <meyering@lucent.com>
26484
26485         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
26486         better with autoheader.
26487
26488 2000-12-24  Jim Meyering  <meyering@lucent.com>
26489
26490         * lib/hash.c (is_prime): Return explicit boolean values.
26491         (hash_get_first): Return NULL to appease Irix5.6's 89.
26492         Reported by Nelson Beebe.
26493
26494 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
26495
26496         * lib/localcharset.c (locale_charset): Add support for Win32.
26497
26498 2000-12-18  Paul Eggert  <eggert@twinsun.com>
26499
26500         * lib/physmem.h, lib/physmem.c: New files.
26501
26502         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
26503         (noinst_HEADERS): Add physmem.h.
26504
26505         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
26506         't' for compatibility with Solaris 8 sort.
26507
26508 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
26509
26510         * lib/config.charset: Add support for BeOS.
26511
26512 2000-12-17  Jim Meyering  <meyering@lucent.com>
26513
26514         * m4/dos.m4 (jm_AC_DOS): New file and macro.
26515         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
26516
26517 2000-12-16  Jim Meyering  <meyering@lucent.com>
26518
26519         This bug had a serious impact on chown: `chown N:M FILE' (for integer
26520         N and M) would have treated it like `chown N:N FILE'.
26521
26522         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
26523
26524 2000-12-16  Jim Meyering  <meyering@lucent.com>
26525
26526         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
26527         SHELLS_FILE to a file name that's useful on djgpp systems.
26528         Include stdlib.h.
26529         (ADDITIONAL_DEFAULT_SHELLS): Define.
26530         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
26531         Based mostly on a patch from Prashant TR.
26532
26533 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
26534
26535         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
26536         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
26537         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
26538
26539 2000-12-08  Andreas Schwab  <schwab@suse.de>
26540
26541         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
26542         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
26543
26544 2000-12-07  Jim Meyering  <meyering@lucent.com>
26545
26546         * lib/stripslash.c (ISSLASH): Define.
26547         (strip_trailing_slashes): Use ISSLASH rather than comparing against
26548         `/'.
26549         From Prashant TR.
26550
26551         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
26552         (dir_name_r): Declare this function as static.
26553         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
26554         manifest itself on a name containing a mix of slashes and
26555         backslashes.
26556         Make this function work with names starting with a DOS-style
26557         drive letter and colon prefix.
26558         (dir_name): Append `.' if necessary.
26559         Based mostly on patches from Prashant TR and Eli Zaretskii.
26560
26561         * lib/dirname.h (dir_name_r): Remove prototype.
26562
26563 2000-12-06  Paul Eggert  <eggert@twinsun.com>
26564
26565         * m4/off_t-format.m4: Remove this file.
26566         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
26567
26568 2000-12-06  Jim Meyering  <meyering@lucent.com>
26569
26570         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
26571         replacement strtoull, we may well need the replacement strtoul, too.
26572         Check for declarations of strtoul and strtoull.
26573         Check for strtol.  Mainly as a cue to cause automake to include
26574         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
26575         Check for limits.h -- strtol.c needs it.
26576
26577 2000-12-05  Jim Meyering  <meyering@lucent.com>
26578
26579         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
26580
26581 2000-12-04  Jim Meyering  <meyering@lucent.com>
26582
26583         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
26584         Also include memory.h, stdlib.h, unistd.h if appropriate.
26585         Reported by Andreas Jaeger (conflicting declaration of malloc).
26586
26587 2000-12-02  Jim Meyering  <meyering@lucent.com>
26588
26589         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
26590         * m4/jm-macros.m4 (jm_MACROS): require it.
26591
26592 2000-12-02  Jim Meyering  <meyering@lucent.com>
26593
26594         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
26595
26596 2000-12-01  Paul Eggert  <eggert@twinsun.com>
26597
26598         * lib/memrchr.c: Include <config.h> before any system include file.
26599
26600 2000-11-30  Jim Meyering  <meyering@lucent.com>
26601
26602         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
26603
26604 2000-11-30  Jim Meyering  <meyering@lucent.com>
26605
26606         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
26607
26608 2000-11-29  Paul Eggert  <eggert@twinsun.com>
26609
26610         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
26611
26612 2000-11-26  Jim Meyering  <meyering@lucent.com>
26613
26614         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
26615
26616 2000-11-22  Paul Eggert  <eggert@twinsun.com>
26617
26618         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
26619         size of (size_t) -1; it's not portable.
26620
26621 2000-11-17  Jim Meyering  <meyering@lucent.com>
26622
26623         * lib/strstr.c: Update from GNU libc.
26624
26625 2000-11-17  Akim Demaille  <akim@epita.fr>
26626
26627         * lib/obstack.h: Formatting changes.
26628         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
26629         prevent type checking.
26630         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
26631         cast the value to (void *): assigning a `foo *' to a `void *'
26632         variable is valid.
26633         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
26634
26635 2000-11-16  Jim Meyering  <meyering@lucent.com>
26636
26637         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
26638
26639 2000-11-11  Jim Meyering  <meyering@lucent.com>
26640
26641         * lib/error.c: Add a couple #includes, merging from GNU libc version.
26642
26643 2000-11-10  Jim Meyering  <meyering@lucent.com>
26644
26645         * lib/obstack.h: Update from GNU libc.
26646         * lib/obstack.c: Likewise.
26647
26648 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
26649
26650         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
26651
26652 2000-11-06  Paul Eggert  <eggert@twinsun.com>
26653
26654         * lib/getusershell.c (setusershell): Use rewind rather than
26655         fseek/fseeko, to avoid configuration hassles with fseeko.
26656         Don't bother opening SHELLS_FILE if shellstream is NULL;
26657         it's not necessary.
26658
26659 2000-11-05  Jim Meyering  <meyering@lucent.com>
26660
26661         * lib/makepath.h (make_dir): Declare.
26662         * lib/makepath.c (make_dir): Remove `static' attribute.
26663         Tweak a comment.
26664
26665 2000-11-04  Jim Meyering  <meyering@lucent.com>
26666
26667         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
26668
26669 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
26670
26671         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
26672         last one in a bucket, advance to the next bucket.
26673
26674 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
26675
26676         * lib/fnmatch.c: Do not comment out all the code if we are using
26677         the GNU C library, because in some cases we are replacing buggy
26678         code in the GNU C library itself.
26679
26680 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
26681
26682         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
26683         (regex_compile): Catch bogus \(\1\).
26684
26685 2000-10-30  Paul Eggert  <eggert@twinsun.com>
26686
26687         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
26688         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
26689         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
26690
26691 2000-10-30  Paul Eggert  <eggert@twinsun.com>
26692
26693         * lib/error.h, getline.h, modechange.h:
26694         Remove "2000" from Copyright line, as the file hasn't been
26695         changed this year other than in the copyright notice.
26696
26697         * lib/xalloc.h: Add "2000" to Copyright line, as this file
26698         was changed this year.
26699
26700 2000-10-29  Jim Meyering  <meyering@lucent.com>
26701
26702         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
26703         renaming.
26704         * m4/ls-mntd-fs.m4: Likewise
26705
26706 2000-10-29  Jim Meyering  <meyering@lucent.com>
26707
26708         * lib/xstat.in: Fix grammar in comment.
26709
26710 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
26711
26712         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
26713         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
26714         doesn't define __restrict_arr.
26715
26716 2000-10-28  Jim Meyering  <meyering@lucent.com>
26717
26718         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
26719         (jm_PREREQ_MEMCHR): New function.
26720
26721 2000-10-28  Jim Meyering  <meyering@lucent.com>
26722
26723         * lib/memchr.c: Update from libc.
26724         Adjust for portability:
26725         [HAVE_STDLIB_H]: Include stdlib.h.
26726         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
26727         Undef __memchr, too.
26728         [!weak_alias]: Define __memchr to memchr.
26729
26730         * lib/regex.c: Update from libc.
26731         * lib/regex.h: Likewise.
26732         * lib/getopt1.c: Likewise.
26733         * lib/memcmp.c: Likewise.
26734
26735         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
26736         Avoid using fseek, when possible -- it's broken by design.
26737         Patch by Ulrich Drepper.
26738
26739 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
26740
26741         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
26742         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
26743         Giving in to popular pressure to shut up the compiler with casts.
26744
26745 2000-10-26  Jim Meyering  <meyering@lucent.com>
26746
26747         * lib/strftime.c: Update from libc.
26748
26749 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
26750
26751         * regex.c: More `unsigned char' -> `re_char' changes.
26752         Also change several `int' into `re_wchar_t'.
26753         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
26754         (PUSH_FAILURE_POINTER): Don't cast any more.
26755         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
26756         We want GCC to complain, since this piece of code makes
26757         re_match non-reentrant, which *should* be fixed.
26758         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
26759         (EXTEND_BUFFER): Use RETALLOC.
26760         (SET_LIST_BIT): Don't cast.
26761         (re_wchar_t): New type.
26762         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
26763         that those two functions will always properly return.
26764         (IMMEDIATE_QUIT_CHECK): Cast to void.
26765         (analyse_first): Use recursion rather than an explicit stack.
26766         (re_compile_fastmap): Can't fail anymore.
26767         (re_search_2): Don't check re_compile_fastmap for failure.
26768         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
26769         Now also sets the new value (passed in a new argument).
26770         (re_match_2_internal): Use it.
26771         Also, use a new var `reg' of type size_t when looping through regs
26772         rather than reuse the inappropriate `mcnt'.
26773
26774 2000-10-25  Jim Meyering  <meyering@lucent.com>
26775
26776         * lib/obstack.c: Update from libc.
26777
26778 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
26779
26780         * regex.c (regex_compile): Change the way of handling a range from
26781         a char less than 256 to a char not less than 256.
26782
26783 2000-10-24  Andrew Innes  <andrewi@gnu.org>
26784
26785         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
26786         NT-Emacs only.
26787         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
26788         so that re_search functions only quit when callers expect them to.
26789
26790 2000-10-23  Jim Meyering  <meyering@lucent.com>
26791
26792         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
26793         wrong.  That set_locale call must not have any side effects.
26794         From Paul Eggert.
26795
26796 2000-10-22  Jim Meyering  <meyering@lucent.com>
26797
26798         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
26799         [CYCLIC]: Remove now-unused definition.
26800
26801         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
26802         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
26803         Suggestion from Ulrich Drepper.
26804
26805 2000-10-21  Jim Meyering  <meyering@lucent.com>
26806
26807         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
26808         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
26809         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
26810
26811 2000-10-21  Jim Meyering  <meyering@lucent.com>
26812
26813         * lib/dirname.c (memrchr): Declare if necessary.
26814         (dir_name): Remove the restriction that there be no
26815         trailing slashes.  Now, this code skips past them, effectively
26816         ignoring them.
26817         [TEST_DIRNAME] (main): New unit tests.
26818
26819         * lib/memrchr.c: New file from GNU libc.
26820         Undef __memrchr, too.
26821         [!weak_alias]: Define __memrchr to memrchr.
26822         Guard weak_alias use with `#ifdef weak_alias'.
26823
26824 2000-10-21  Jim Meyering  <meyering@lucent.com>
26825
26826         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
26827         (dir_name): Use dir_name_r.
26828         * lib/dirname.h (dir_name_r): Declare it.
26829
26830 2000-10-17  Jim Meyering  <meyering@lucent.com>
26831
26832         * lib/quote.h (PARAMS): Define and use.
26833         Reported by Akim Demaille.
26834
26835         * lib/getopt.c: Update from libc.
26836
26837 2000-10-16  Jim Meyering  <meyering@lucent.com>
26838
26839         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
26840         setlocale.
26841         From Jan Fedak.
26842
26843 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
26844
26845         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
26846
26847 2000-09-25  Jim Meyering  <meyering@lucent.com>
26848
26849         * lib/md5.h (rol): Define (from GnuPG).
26850
26851         * lib/sha.c: Give credit (GnuPG) where due.
26852         (M): Use rol rather than open-coding it.
26853         Add a FIXME comment.
26854
26855 2000-09-21  Jim Meyering  <meyering@lucent.com>
26856
26857         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
26858         Reported by Michael Stone.
26859
26860 2000-09-20  Jim Meyering  <meyering@lucent.com>
26861
26862         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
26863         (noinst_HEADERS): Add sha.h.
26864         Based on code from Scott G. Miller and from GnuPG.
26865
26866 2000-09-18  Jim Meyering  <meyering@lucent.com>
26867
26868         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
26869         LIBS. Otherwise, everyone ends up linking with -lelf for some
26870         configurations.
26871         Reported by Mike Stone.
26872
26873 2000-09-15  Jim Meyering  <meyering@lucent.com>
26874
26875         * lib/regex.c: Update from libc.
26876
26877 2000-09-10  Jim Meyering  <meyering@lucent.com>
26878
26879         * lib/getopt.c (_getopt_internal): Update from glibc.
26880
26881 2000-09-09  Jim Meyering  <meyering@lucent.com>
26882
26883         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
26884         think it should be used as a general replacement for isascii.
26885         * lib/fnmatch.c: Likewise.
26886         * lib/mbswidth.c: Likewise
26887         * lib/regex.c: Likewise.
26888
26889         Don't use atoi.
26890         * lib/userspec.c: Include sys/param.h and limits.h.
26891         Include xstrtol.h.
26892         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
26893         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
26894         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
26895         UID, GID.  Check range.
26896
26897 2000-09-06  Jim Meyering  <meyering@lucent.com>
26898
26899         * lib/getopt.c (_getopt_internal): Update from glibc.
26900
26901 2000-08-30  Jim Meyering  <meyering@lucent.com>
26902
26903         * lib/strftime.c: Merge in changes from GNU libc.
26904
26905 2000-08-26  Jim Meyering  <meyering@lucent.com>
26906
26907         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
26908         * m4/fpending.m4: New file.
26909
26910 2000-08-26  Jim Meyering  <meyering@lucent.com>
26911
26912         * lib/closeout.c: Include "__fpending.h".
26913         (close_stdout_status): Return right away if there's nothing to flush.
26914
26915         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
26916         * lib/__fpending.c: New file.
26917         * lib/__fpending.h: New file.
26918
26919 2000-08-20  Jim Meyering  <meyering@lucent.com>
26920
26921         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
26922         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
26923         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
26924
26925 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
26926
26927         Improve fileutils installation on systems where running
26928         programs (like install) can't be unlinked.
26929         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
26930         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
26931
26932 2000-08-07  Paul Eggert  <eggert@twinsun.com>
26933
26934         Standardize on "memory exhausted" instead of "Memory exhausted"
26935         or "virtual memory exhausted".
26936         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
26937         "virtual memory exhausted".
26938         * lib/same.c (same_name): Invoke xalloc_die instead of printing
26939         our own message.
26940         * lib/userspec.c (parse_user_spec): Likewise.
26941         * lib/bumpalloc.h: comment fix
26942         * lib/same.c, userspec.c: Include xalloc.h.
26943
26944         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
26945         not char *const and pointing to a constant array.
26946         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
26947         (xrealloc): Comment fix.
26948
26949         * lib/userspec.c (parse_user_spec):
26950         Don't translate a message until just before returning,
26951         to avoid unnecessary translation.
26952
26953 2000-08-07  Jim Meyering  <meyering@lucent.com>
26954
26955         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
26956         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
26957         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
26958         getgroups.c, gethostname.c, getopt.h, group-member.c,
26959         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
26960         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
26961         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
26962         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
26963         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
26964         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
26965         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
26966         yesno.c: Back out Copyright date changes for each file with no change
26967         this year.  This eases coordination with other programs using the same
26968         source code modules.  From Paul Eggert.
26969
26970 2000-08-06  Paul Eggert  <eggert@twinsun.com>
26971
26972         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
26973         not char, for compatibility with glibc 2.1.3 strftime.c.
26974
26975 2000-08-03  Greg McGary  <greg@mcgary.org>
26976
26977         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
26978         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
26979         (EXTEND_BUFFER): Use them.
26980
26981 2000-08-01  Jim Meyering  <meyering@lucent.com>
26982
26983         * lib/dirname.c (ISSLASH): Define.
26984         (BACKSLASH_IS_PATH_SEPARATOR): Define.
26985         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
26986         both `\' and `/' may be use as path separators.
26987         Based on a patch from Prashant TR.
26988
26989 2000-07-31  Paul Eggert  <eggert@twinsun.com>
26990
26991         * lib/quotearg.c (quotearg_n_options): Don't make the initial
26992         slot vector a constant, since it might get modified.
26993
26994 2000-07-31  Jim Meyering  <meyering@lucent.com>
26995
26996         * lib/xmalloc.c: Use `virtual memory exhausted', not
26997         `Memory exhausted'.
26998         * lib/obstack.c (print_and_abort): Likewise.
26999
27000 2000-07-30  Paul Eggert  <eggert@twinsun.com>
27001
27002         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
27003         buffer, so that the caller can always quote one small
27004         component of a "memory exhausted" message in slot 0.
27005         From a suggestion by Jim Meyering.
27006
27007 2000-07-30  Jim Meyering  <meyering@lucent.com>
27008
27009         * lib/makepath.c (make_path): Quote the other instance, too.
27010
27011         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
27012         (STATIC_BUF_SIZE): Define.
27013         (quotearg_n_options): Use only statically allocated storage when
27014         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
27015         than STATIC_BUF_SIZE.
27016
27017 2000-07-29  Jim Meyering  <meyering@lucent.com>
27018
27019         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
27020         * lib/dirname.c (dir_name): Likewise.
27021
27022         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
27023         `/'.
27024
27025         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
27026         (dir_name): Assert that there are no trailing slashes.
27027
27028 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
27029
27030         * lib/mbswidth.h (mbswidth): Add a flags argument.
27031         (mbswidth): New declaration.
27032         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
27033         * lib/mbswidth.c (mbswidth): Add a flags argument.
27034         (mbsnwidth): New function.
27035
27036 2000-07-24  Jim Meyering  <meyering@lucent.com>
27037
27038         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
27039
27040 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27041
27042         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
27043
27044 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27045
27046         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
27047         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
27048         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
27049         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
27050         invoke multibyte primitives.
27051
27052 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27053
27054         * lib/quotearg.c:
27055         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
27056         so that mbstate_t is always defined.
27057
27058         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
27059         be 1 in at least one GCC installation, and this configuration
27060         error is likely to be common.  Ignoring MB_LEN_MAX hurts
27061         performance on hosts that have mbrtowc but have only unibyte
27062         locales, but I assume these hosts are rare.
27063
27064 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27065
27066         * lib/mbswidth.c (_XOPEN_SOURCE):
27067         Don't define; this causes problems on Solaris 7.
27068         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
27069
27070 2000-07-23  Jim Meyering  <meyering@lucent.com>
27071
27072         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
27073         too: getgrgid, getpwuid, getuid.
27074
27075 2000-07-23  Jim Meyering  <meyering@lucent.com>
27076
27077         * lib/basename.c (base_name): Add an assertion.
27078
27079 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
27080
27081         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
27082         shadow its mbsinit function.
27083
27084 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27085
27086         * lib/mbswidth.h: New file.
27087         * lib/mbswidth.c: New file.
27088         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
27089         (noinst_HEADERS): Add mbswidth.h.
27090
27091 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27092
27093         * lib/config.charset: Add support for FreeBSD. Improve support for
27094         HP-UX and IRIX 6.
27095
27096 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
27097
27098         * m4/mbswidth.m4: New file.
27099         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
27100
27101 2000-07-15  Jim Meyering  <meyering@lucent.com>
27102
27103         * lib/makepath.c: Include quote.h.
27104         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
27105         corresponding argument in a `quote (...)' call.
27106         Give better diagnostics.
27107
27108         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
27109         (noinst_HEADERS): Add quote.h.
27110
27111         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
27112         from tar's src/misc.c.
27113         * lib/quote.h: New file.  Prototypes for same.
27114
27115 2000-07-14  Paul Eggert  <eggert@twinsun.com>
27116
27117         From a suggestion by Bruno Haible.
27118         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
27119         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
27120         to decide whether to define the BeOS workaround macro;
27121         this adjusts to the change to AC_MBSTATE_T.
27122
27123 2000-07-14  Jim Meyering  <meyering@lucent.com>
27124
27125         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
27126         jm_AC_TYPE_UINTMAX_T.
27127
27128 2000-07-13  Paul Eggert  <eggert@twinsun.com>
27129
27130         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
27131
27132         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
27133         quotearg_buffer_restyled): Add support for
27134         clocale_quoting_style.  Undo previous change to
27135         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
27136         and "{RIGHT QUOTATION MARK}" msgids.
27137
27138 2000-07-10  Paul Eggert  <eggert@twinsun.com>
27139
27140         From a suggestion by Bruno Haible.
27141         * m4/mbstate_t.m4 (AC_MBSTATE_T):
27142         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
27143         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
27144         and mbstate_t, to a single-part test that simply defines mbstate_t.
27145         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
27146         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
27147
27148 2000-07-10  Jim Meyering  <meyering@lucent.com>
27149
27150         * m4/strerror_r.m4: Mirror the correction made in autoconf.
27151
27152         * m4/gnu-source.m4: Output to confdefs.h directly.
27153         Suggestion from Akim Demaille.
27154
27155 2000-07-09  Paul Eggert  <eggert@twinsun.com>
27156
27157         The old behavior of quoting `like this' doesn't look good with
27158         newer, ISO-style fonts.  See:
27159         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
27160
27161         Instead, quote "like this" by default.  Let the translator
27162         tailor the locale-specific quoting behavior by providing
27163         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
27164
27165         * lib/quotearg.c (N_): New macro.
27166         (gettext_default): New function.
27167         (quotearg_buffer_restyled): Use
27168         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
27169         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
27170
27171 2000-07-09  Jim Meyering  <meyering@lucent.com>
27172
27173         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
27174         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
27175
27176         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
27177         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
27178
27179 2000-07-09  Jim Meyering  <meyering@lucent.com>
27180
27181         * lib/Most files: Update copyright dates to include 2000.
27182
27183 2000-07-08  Jim Meyering  <meyering@lucent.com>
27184
27185         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
27186         if not defined.
27187         (xgethostname): Remove now-unnecessary #ifdef.
27188         Move declaration of `err' into loop where it's used.
27189
27190 2000-07-05  Paul Eggert  <eggert@twinsun.com>
27191         and Bruno Haible  <haible@clisp.cons.org>
27192
27193         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
27194         only if the test for an object-type mbstate_t fails.  This
27195         prevents us from mistakenly reporting that mbstate_t is a
27196         system object type after we "#define mbstate_t int" to work
27197         around its lack.
27198
27199 2000-07-05  Paul Eggert  <eggert@twinsun.com>
27200         and Bruno Haible  <haible@clisp.cons.org>
27201
27202         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
27203
27204 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27205
27206         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
27207         to strerror_r.
27208         Include <ctype.h> for use of isalpha.
27209
27210 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27211
27212         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
27213         by allocating a larger buffer. Test the gethostname return value for
27214         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
27215         returns an error and ENAMETOOLONG isn't defined.
27216
27217 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27218
27219         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
27220         dimension.
27221
27222 2000-07-04  Jim Meyering  <meyering@lucent.com>
27223
27224         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
27225         of the deprecated AC_CHECKING.
27226
27227 2000-07-04  Jim Meyering  <meyering@lucent.com>
27228
27229         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
27230         Reported by Bruno Haible.
27231
27232 2000-07-04  Jim Meyering  <meyering@lucent.com>
27233
27234         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
27235         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
27236         lacks mbrtowc.
27237
27238 2000-07-03  Paul Eggert  <eggert@twinsun.com>
27239
27240         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
27241         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
27242
27243 2000-07-03  Paul Eggert  <eggert@twinsun.com>
27244         and Bruno Haible  <haible@clisp.cons.org>
27245
27246         * lib/quotearg.c (mbrtowc):
27247         Assign to *pwc, and return 1 only if result is nonzero.
27248         (iswprint): Use ISPRINT when substituting our own mbrtowc.
27249
27250 2000-07-03  Jim Meyering  <meyering@lucent.com>
27251
27252         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
27253
27254 2000-07-03  Jim Meyering  <meyering@lucent.com>
27255
27256         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
27257         This is necessary to get a definition of e.g., UTMP_FILE on
27258         HP-UX 10.20.
27259         From Bob Proulx.
27260
27261 2000-07-02  Jim Meyering  <meyering@lucent.com>
27262
27263         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
27264
27265         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
27266         AC_LIBOBJ(function_name).
27267         * m4/chown.m4: Likewise.
27268         * m4/fnmatch.m4: Likewise.
27269         * m4/ftruncate.m4: Likewise.
27270         * m4/getgroups.m4: Likewise.
27271         * m4/getline.m4: Likewise.
27272         * m4/group-member.m4: Likewise.
27273         * m4/jm-macros.m4: Likewise.
27274         * m4/lstat.m4: Likewise.
27275         * m4/malloc.m4: Likewise.
27276         * m4/memcmp.m4: Likewise.
27277         * m4/nanosleep.m4: Likewise.
27278         * m4/putenv.m4: Likewise.
27279         * m4/realloc.m4: Likewise.
27280         * m4/regex.m4: Likewise.
27281         * m4/stat.m4: Likewise.
27282         * m4/strftime.m4: Likewise.
27283
27284 2000-07-02  Jim Meyering  <meyering@lucent.com>
27285
27286         * lib/quotearg.c (mbstate_t): Don't define here.
27287
27288 2000-07-02  Jim Meyering  <meyering@lucent.com>
27289
27290         * lib/nanosleep.c (SIGCONT): Define if not already defined.
27291
27292 2000-07-01  Jim Meyering  <meyering@lucent.com>
27293
27294         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
27295
27296 2000-07-01  Jim Meyering  <meyering@lucent.com>
27297
27298         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
27299         problem.
27300
27301 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
27302
27303         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
27304         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
27305
27306 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
27307
27308         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
27309         per change in ../m4/ls-mntd-fs.m4.
27310         (read_filesystem_list): Ignore symbolic links.
27311
27312 2000-06-29  Jim Meyering  <meyering@lucent.com>
27313
27314         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
27315         for declaration of strcmp.
27316
27317         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
27318
27319         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
27320         Avoid warning by casting result to `char *' to remove `const'.
27321
27322 2000-06-28  Jim Meyering  <meyering@lucent.com>
27323
27324         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
27325         included by quotearg.c, for which we perform this test.  From
27326         Bruno Haible.
27327
27328 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
27329
27330         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
27331         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
27332         <utmpx.h> exists, put readutmp.o into LIBOBJS.
27333
27334 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
27335
27336         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
27337
27338 2000-06-26  Paul Eggert  <eggert@twinsun.com>
27339
27340         savedir now sets errno on failure and invokes xmalloc to get memory.
27341         Fix a couple of other minor bugs while we're at it.
27342
27343         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
27344         (NAMLEN): Remove macro.
27345         (malloc, realloc): Remove decls.
27346         (stpcpy): Likewise.
27347         ("xalloc.h"): Include.
27348         (NAME_SIZE_DEFAULT): New macro.
27349         (savedir): Use xmalloc / xrealloc to allocate memory.
27350         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
27351         Skip "" directory entries.
27352         Use strlen to calculate directory entry length, since the old method
27353         is rarely used these days and isn't worth supporting.
27354         Don't use a pointer after freeing it.
27355         Check for integer overflow when calculating allocation size.
27356         Use memcpy to copy entries, instead of stpcpy.
27357         Set errno properly when returning NULL.
27358         Check for readdir error.
27359
27360 2000-06-26  Jim Meyering  <meyering@lucent.com>
27361
27362         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
27363
27364 2000-06-25  Jim Meyering  <meyering@lucent.com>
27365
27366         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
27367         Linux header bug when _XOPEN_SOURCE is defined to 500.
27368
27369 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
27370
27371         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
27372         deficiency.
27373
27374 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
27375
27376         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
27377         Include xalloc.h.
27378         Don't include <stdlib.h>.  Don't declare malloc, realloc.
27379
27380 2000-06-24  Jim Meyering  <meyering@lucent.com>
27381
27382         * m4/strerror_r.m4: Revive this file -- to try out an experimental
27383         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
27384         for which strerror does return char*, but which lacks a conveniently
27385         accessible declaration of the function.  If the compile-test says
27386         strerror_r doesn't work, then resort to a `run'-test that works on
27387         BeOS and segfaults on DEC Unix.
27388
27389 2000-06-24  Jim Meyering  <meyering@lucent.com>
27390
27391         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
27392
27393 2000-06-23  Paul Eggert  <eggert@twinsun.com>
27394
27395         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
27396         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
27397
27398 2000-06-23  Paul Eggert  <eggert@twinsun.com>
27399
27400         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
27401         (mbrtowc, mbstate_t): Define substitutes if
27402         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
27403         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
27404         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
27405
27406 2000-06-23  Jim Meyering  <meyering@lucent.com>
27407
27408         * m4/afs.m4: Add missing AC_MSG_RESULT.
27409         Reported by Bruno Haible.
27410
27411         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
27412         Suggestion from Bruno Haible.
27413
27414 2000-06-23  Jim Meyering  <meyering@lucent.com>
27415
27416         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
27417
27418 2000-06-21  Jim Meyering  <meyering@lucent.com>
27419
27420         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
27421
27422 2000-06-21  Jim Meyering  <meyering@lucent.com>
27423
27424         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
27425         (noinst_HEADERS): Add getstr.h.
27426
27427         * lib/getline.c (getstr): Move into a separate file.
27428         * lib/getstr.c (getstr): New file, extracted from getline.c, with
27429         the following changes: new parameter, delim2; both delim[12]
27430         parameters have type `int', not `char'.  The latter would lose
27431         with 8-bit delimiters.
27432         * lib/getstr.h: New file.
27433
27434 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
27435
27436         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
27437         than 1024, return a memory chunk of least possible size, instead
27438         of size PATH_MAX + 2. In the loop, increment the size proportionally.
27439         Use free/xmalloc instead of xrealloc to avoid copying for very long
27440         paths.
27441
27442 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
27443
27444         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
27445         the empty string.
27446
27447 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
27448
27449         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
27450         address, not strdup.  Include <stdlib.h> and don't declare free().
27451
27452 2000-06-19  Jim Meyering  <meyering@lucent.com>
27453
27454         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
27455
27456 2000-06-18  Jim Meyering  <meyering@lucent.com>
27457
27458         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
27459
27460         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
27461         `checking whether...' message to be consistent with that of the
27462         lstat test.
27463
27464 2000-06-18  Jim Meyering  <meyering@lucent.com>
27465
27466         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
27467         Besides, these days every porting target provides a mkdir function.
27468
27469         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
27470         needed. (this snippet comes from src/system.h).
27471
27472 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
27473
27474         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
27475
27476 2000-06-15  Paul Eggert  <eggert@twinsun.com>
27477
27478         * lib/human.c (adjust_value): New function.
27479         (human_readable_inexact): Apply rounding style even when
27480         printing approximate values.
27481
27482 2000-06-14  Paul Eggert  <eggert@twinsun.com>
27483
27484         * lib/human.c (human_readable_inexact): Allow an input block
27485         size that is not a multiple of the output block size, and vice versa.
27486         Reported by Piergiorgio Sartor.
27487
27488 2000-06-14  Paul Eggert  <eggert@twinsun.com>
27489
27490         * lib/getdate.y (get_date): Apply relative times after time
27491         zone indicator, not before.  Reported by Todd A. Jacobs.
27492
27493 2000-06-13  Jim Meyering  <meyering@lucent.com>
27494
27495         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
27496
27497         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
27498
27499 2000-06-12  Paul Eggert  <eggert@twinsun.com>
27500
27501         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
27502
27503 2000-06-12  Jim Meyering  <meyering@lucent.com>
27504
27505         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
27506         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
27507         optional argument.
27508         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
27509         the optional argument, `lib'.
27510
27511 2000-06-08  Jim Meyering  <meyering@lucent.com>
27512
27513         * m4/largefile.m4: Remove file (now that it's part of autoconf).
27514
27515 2000-06-04  Paul Eggert  <eggert@twinsun.com>
27516
27517         Rewrite largefile configuration so that we don't need to run
27518         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
27519         AC_CANONICAL_HOST in configure.in -- jmm]
27520
27521         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
27522         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
27523         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
27524         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
27525         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
27526         All uses changed.
27527         Instead of inspecting the output of getconf, try to compile the
27528         test program without and with the macro definition.
27529         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
27530         for getconf.  Instead, check for the needed flags by compiling
27531         test programs.
27532
27533 2000-06-04  Paul Eggert  <eggert@twinsun.com>
27534
27535         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
27536
27537 2000-06-04  Jim Meyering  <meyering@lucent.com>
27538
27539         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
27540         SunOS 4.1.4 for which gid_t is an unsigned type.
27541
27542 2000-06-03  Jim Meyering  <meyering@lucent.com>
27543
27544         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
27545         now that autoconf requires that.
27546
27547         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
27548         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
27549         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
27550
27551 2000-06-03  Jim Meyering  <meyering@lucent.com>
27552
27553         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
27554
27555 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
27556
27557         * m4/glibc21.m4: New file.
27558         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
27559
27560 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
27561
27562         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
27563         newer, don't install charset.alias.
27564         * lib/config.charset: Change the Linux/glibc rules so they become empty
27565         on glibc-2.1 or newer.
27566
27567 2000-06-02  Jim Meyering  <meyering@lucent.com>
27568
27569         * lib/mountlist.c: Back out last change.  Instead, do this...
27570         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
27571         me_dummy member using the same `ignore'-testing code.
27572         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
27573         fs_type strings.
27574         From Mark D. Roth.
27575
27576 2000-05-29  Jim Meyering  <meyering@lucent.com>
27577
27578         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
27579         mounts with the `ignore' attribute.  Based on a patch from
27580         Mark D. Roth.
27581
27582 2000-05-28  Jim Meyering  <meyering@lucent.com>
27583
27584         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
27585         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
27586         * m4/stat.m4: Likewise.
27587         * m4/lstat.m4: Likewise.
27588         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
27589
27590         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
27591         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
27592
27593 2000-05-26  Jim Meyering  <meyering@lucent.com>
27594
27595         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
27596
27597 2000-05-24  Jim Meyering  <meyering@lucent.com>
27598
27599         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
27600         autoconf requires that.
27601         * m4/lib-check.m4: Likewise.
27602         * m4/jm-macros.m4: Likewise.
27603         * m4/strftime.m4: Likewise.
27604
27605         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
27606         AC_CHECK_DECLS, now that autoconf requires that.
27607
27608 2000-05-22  Jim Meyering  <meyering@lucent.com>
27609
27610         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
27611         * m4/lstat.m4: Likewise.
27612
27613 2000-05-22  Jim Meyering  <meyering@lucent.com>
27614
27615         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
27616
27617 2000-05-20  Jim Meyering  <meyering@lucent.com>
27618
27619         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
27620         (jm_PREREQ): Use it.
27621
27622 2000-05-18  Jim Meyering  <meyering@lucent.com>
27623
27624         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
27625         back, too, since it may have been modified by allocate_entry.
27626         (hash_delete): Rewrite to use neither the assignment operator
27627         nor the comma operator in an if-expression.
27628
27629 2000-05-15  Paul Eggert  <eggert@twinsun.com>
27630
27631         * lib/closeout.c:
27632         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
27633         Remove; no longer needed.
27634         "quotearg.h": Add include.
27635         (file_name): Do not bother to explicitly initialize to NULL; it's less
27636         efficient on some hosts.
27637         (close_stdout_status): Remove test as to whether stdout was already
27638         closed; it breaks for the case "echo x | sort >&-".
27639         Quote file name colons.
27640         Do not assume that _("write error") lacks format strings.
27641
27642 2000-05-15  Jim Meyering  <meyering@lucent.com>
27643
27644         * lib/version-etc.c (version_etc_copyright): Update the copyright
27645         string used in all --version output.
27646
27647 2000-05-14  Jim Meyering  <meyering@lucent.com>
27648
27649         * lib/closeout.c (close_stdout_set_file_name): New function.
27650         (close_stdout_status): Use new file-scoped global.
27651         Return right away if fstat says the stdout file descriptor is invalid.
27652         * lib/closeout.h (close_stdout_set_file_name): Declare.
27653
27654 2000-05-10  Jim Meyering  <meyering@lucent.com>
27655
27656         * lib/closeout.c [default_exit_status]: New file-scoped variable.
27657         (close_stdout_set_status): New function.
27658         * lib/closeout.h (close_stdout_set_status): Declare.
27659
27660 2000-05-09  Jim Meyering  <meyering@lucent.com>
27661
27662         * m4/gettext.m4: Rename this...
27663         * m4/libintl.m4: ...to this.
27664
27665 2000-05-08  Jim Meyering  <meyering@lucent.com>
27666
27667         * lib/long-options.c: Don't include closeout.h.
27668         (parse_long_options): Don't call close_stdout for --version.
27669
27670 2000-05-06  Paul Eggert  <eggert@twinsun.com>
27671
27672         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
27673         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
27674         2.1.3 bug.  This avoids a clash when files like regex.c define
27675         _GNU_SOURCE.
27676
27677 2000-05-06  Jim Meyering  <meyering@lucent.com>
27678
27679         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
27680         (AC_REPLACE_FUNCS): Add strnlen.
27681
27682         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
27683         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
27684
27685         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
27686         AC_SEARCH_LIBS call for nanosleep.
27687         (LIB_NANOSLEEP): Set and AC_SUBST.
27688
27689 2000-05-06  Jim Meyering  <meyering@lucent.com>
27690
27691         * lib/strnlen.c: Undefine __strnlen and strnlen.
27692         [!weak_alias]: Define __strnlen to strnlen.
27693
27694         * lib/atexit.c: New file, from libiberty.
27695
27696 2000-05-06  Jim Meyering  <meyering@lucent.com>
27697
27698         * lib/closeout.c (close_stdout_status): Also check for errors on the
27699         stderr stream.
27700
27701 2000-05-05  Jim Meyering  <meyering@lucent.com>
27702
27703         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
27704         AC_SEARCH_LIBS call for clock_gettime.
27705         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
27706
27707         * m4/search-libs.m4: Update from autoconf.
27708
27709         su doesn't work on Solaris 2.6.
27710         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
27711         <shadow.h>.  Reported by Dragos Harabor.
27712
27713 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
27714
27715         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
27716         memcpy instead of xmalloc, xrealloc, path_concat.
27717         (locale_charset): Treat empty environment variables as absent.
27718         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
27719
27720 2000-05-04  Jim Meyering  <meyering@lucent.com>
27721
27722         * lib/getopt.c: Update from glibc.
27723         * lib/obstack.c: Likewise.
27724         * lib/obstack.h: Likewise.
27725         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
27726         file
27727
27728         * lib/regex.h: Likewise.
27729         * lib/strndup.c: Likewise.
27730         * lib/strnlen.c: New file, from glibc.
27731
27732 2000-05-03  Jim Meyering  <meyering@lucent.com>
27733
27734         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
27735
27736 2000-05-02  Paul Eggert  <eggert@twinsun.com>
27737
27738         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
27739         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
27740         compile-time test, rather than inspecting host and OS, to
27741         decide whether to define _LARGEFILE_SOURCE.
27742
27743 2000-05-01  Jim Meyering  <meyering@lucent.com>
27744
27745         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
27746
27747         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
27748         Based on a patch from Bruno Haible.
27749
27750 2000-05-01  Jim Meyering  <meyering@lucent.com>
27751
27752         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
27753
27754 2000-04-29  Jim Meyering  <meyering@lucent.com>
27755
27756         * lib/path-concat.c: Declare strdup only if it's not defined.
27757         * lib/canon-host.c: Likewise.
27758
27759 2000-04-28  Jim Meyering  <meyering@lucent.com>
27760
27761         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
27762         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
27763         is included first, then limits.h is included by locale.h by libintl.h.
27764         From John David Anglin.
27765
27766 2000-04-25  Jim Meyering  <meyering@lucent.com>
27767
27768         * lib/makepath.c (S_IRWXUGO): Define.
27769         (make_path): Always perform explicit chmod if MODE specifies any
27770         of the `special' permission bits.  Prompted by a bug report against
27771         install from Mate Wierdl and Joost van Baal.
27772
27773 2000-04-18  Jim Meyering  <meyering@lucent.com>
27774
27775         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
27776         (jm_PREREQ): Use it.
27777
27778 2000-04-18  Jim Meyering  <meyering@lucent.com>
27779
27780         * lib/README: New file.
27781
27782         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
27783         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
27784
27785 2000-04-17  Jim Meyering  <meyering@lucent.com>
27786
27787         Get it right :-)
27788         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
27789         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
27790         Suggestion from Akim Demaille.
27791
27792 2000-04-17  Jim Meyering  <meyering@lucent.com>
27793
27794         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
27795         the definition of it to rpl_strftime also defined-away the system's
27796         declaration.
27797
27798 2000-04-15  Jim Meyering  <meyering@lucent.com>
27799
27800         Use `C' to denote so-called `contiguous' files, the same way
27801         that tar does.
27802         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
27803         (ftypelet): Use S_ISCTG.
27804         From Michael Deutschmann.
27805
27806 2000-04-14  Jim Meyering  <meyering@lucent.com>
27807
27808         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
27809         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
27810         clobbered.
27811
27812 2000-04-14  Jim Meyering  <meyering@lucent.com>
27813
27814         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
27815
27816 2000-04-13  Jim Meyering  <meyering@lucent.com>
27817
27818         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
27819         AH_VERBATIM to insert required #ifndef into config.h.in.
27820         Suggestion from Akim Demaille.
27821
27822 2000-04-12  Jim Meyering  <meyering@lucent.com>
27823
27824         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
27825         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
27826         Christian Krackowizer.
27827
27828         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
27829         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
27830         (AC_SYS_LARGEFILE): Require.
27831         (AM_C_PROTOTYPES): Require.
27832
27833 2000-04-08  Jim Meyering  <meyering@lucent.com>
27834
27835         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
27836         names don't conflict.  Reported by Eli Zaretskii.
27837
27838 2000-04-07  Jim Meyering  <meyering@lucent.com>
27839
27840         * lib/putenv.c: Move inclusion of errno.h so it follows that of
27841         sys/types.h, to work around system header problems on AIX 3.2.5.
27842         From Bruno Haible.
27843
27844 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
27845
27846         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
27847         bug.  Deal with the different error behavior of Irix iconv.
27848
27849 2000-04-05  Paul Eggert  <eggert@twinsun.com>
27850
27851         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
27852         IRIX if the installer said otherwise.
27853
27854 2000-04-05  Jim Meyering  <meyering@lucent.com>
27855
27856         Portability tweaks required for ultrix4.3.
27857         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
27858         (jm_CHECK_DECLS): Add getutent to the list of functions.
27859         (_jm_DECL_HEADERS): Add utmpx.h.
27860         From John David Anglin.
27861
27862         * m4/strftime.m4: Back out the 2000-04-02 change.
27863         Instead of that change, simply undefine putenv in the test program.
27864
27865 2000-04-05  Jim Meyering  <meyering@lucent.com>
27866
27867         Portability tweaks required for ultrix4.3.
27868         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
27869         getutent.
27870         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
27871         * lib/canon-host.c: Declare strdup.
27872         * lib/path-concat.c: Likewise.
27873         From John David Anglin.
27874
27875 2000-04-04  Jim Meyering  <meyering@lucent.com>
27876
27877         Be more DOS 8.3-friendly.
27878         * lib/ref-add.sin: Renamed from ref-add.sed.in.
27879         * lib/ref-del.sin: Renamed from ref-del.sed.in.
27880         * lib/Makefile.am: Reflect renaming.
27881         Reported by Eli Zaretskii.
27882
27883         Use a temporary file name that won't clash with `charset.alias'
27884         in the DOS 8.3 name space.
27885         * lib/Makefile.am (charset_tmp): Define.
27886         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
27887         (uninstall-local): Likewise.
27888         Reported by Eli Zaretskii.
27889
27890 2000-04-03  Jim Meyering  <meyering@lucent.com>
27891
27892         * m4/gettext.m4: Fix typo in comment.
27893
27894         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
27895         textutils/configure.in).  Suggestion from Paul Eggert.
27896         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
27897
27898 2000-04-02  Paul Eggert  <eggert@twinsun.com>
27899
27900         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
27901         variable in the shell rather than using putenv, which isn't
27902         portable.  This avoids the configure-time inter-test dependency
27903         on the potentially-renamed putenv function.
27904
27905 2000-03-30  Paul Eggert  <eggert@twinsun.com>
27906
27907         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
27908         before checking struct stat.st_blksize, so that
27909         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
27910
27911 2000-03-29  Paul Eggert  <eggert@twinsun.com>
27912
27913         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
27914         since strftime.c uses HAVE_STRFTIME to decide whether to use
27915         the underlying strftime.
27916
27917 2000-03-29  Paul Eggert  <eggert@twinsun.com>
27918
27919         * lib/time/strftime.c (my_strftime): Make sure we call the system
27920         strftime, not ourselves, when invoking the underlying strftime.
27921
27922 2000-03-24  Jim Meyering  <meyering@lucent.com>
27923
27924         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
27925         (charset_alias): Define.
27926         (install-exec-local): Factor out common code.
27927         (uninstall-local): Split lines longer than 80.
27928         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
27929         (SUFFIXES): Define.
27930         (.sed.in.sed): New rule.  Don't redirect directly to $@.
27931         (CLEANFILES): Add ref-add.sed and ref-del.sed.
27932
27933 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
27934
27935         * lib/config.charset: Output a line containing "Packages using this
27936         file".
27937         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
27938         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
27939         ref-del.sed): New rules.
27940
27941 2000-03-17  Jim Meyering  <meyering@lucent.com>
27942
27943         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
27944         Otherwise, include <strings.h>
27945
27946 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
27947
27948         * lib/unicodeio.c (utf8_wctomb): New function.
27949         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
27950         format instead of in UCS-4 with platform dependent endianness.
27951
27952 2000-03-10  Jim Meyering  <meyering@lucent.com>
27953
27954         * m4/lib-check.m4: Look for getspnam in -lgen, too.
27955         From Marco Franzen.
27956
27957 2000-03-07  Paul Eggert  <eggert@twinsun.com>
27958
27959         * lib/savedir.c (savedir): Work even if directory size is
27960         negative; this can happen with some screwy NFS configurations.
27961
27962 2000-03-06  Jim Meyering  <meyering@lucent.com>
27963
27964         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
27965         if it's NULL (because we ran out of memory).  From Bruno Haible.
27966
27967 2000-03-05  Jim Meyering  <meyering@lucent.com>
27968
27969         * lib/localcharset.c ("path-concat.h"): Include.
27970         (get_charset_aliases): Use path_concat instead of ANSI string
27971         concatenation.
27972
27973         * lib/unicodeio.h (PARAMS): Define.
27974         Use it to guard prototype.
27975
27976 2000-03-04  Jim Meyering  <meyering@lucent.com>
27977
27978         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
27979         for lib/localcharset.c.
27980
27981 2000-03-04  Jim Meyering  <meyering@lucent.com>
27982
27983         * lib/Makefile.am (install-exec-local): Create $(libdir) before
27984         installing into it.
27985         (uninstall-local): Uncomment this rule so `make distcheck' works
27986         once again.
27987
27988         * lib/unicodeio.c (<errno.h>): Include it.
27989         (errno): Declare if not defined.
27990
27991         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
27992
27993         * lib/config.charset: New version, incorporating remarks from a linux
27994         i18n mailing list.  From Bruno Haible.
27995
27996 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
27997
27998         * m4/codeset.m4: New file.
27999         * m4/iconv.m4: New file.
28000         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
28001
28002 2000-03-03  Jim Meyering  <meyering@lucent.com>
28003
28004         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
28005
28006 2000-03-02  Jim Meyering  <meyering@lucent.com>
28007
28008         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
28009         the messages come out on separate lines.
28010
28011         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
28012         rather than jm_CHECK_DECLARATIONS.
28013         * m4/decl.m4: Remove now-unused file.
28014
28015         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
28016         geteuid.
28017
28018 2000-03-02  Jim Meyering  <meyering@lucent.com>
28019
28020         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
28021
28022 2000-03-01  Jim Meyering  <meyering@lucent.com>
28023
28024         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
28025         * lib/unicodeio.c: Likewise.
28026
28027 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
28028
28029         * lib/config.charset: New file.
28030         * lib/localcharset.c: New file.
28031         * lib/unicodeio.h, lib/unicodeio.c: New files.
28032         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
28033         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
28034         (noinst_HEADERS): Add unicodeio.h.
28035         (all-local, install-exec-local, charset.alias): New targets.
28036
28037 2000-02-28  Paul Eggert  <eggert@twinsun.com>
28038
28039         * lib/quotearg.c (ALERT_CHAR): New macro.
28040         (quotearg_buffer_restyled): Use it.
28041
28042 2000-02-27  Jim Meyering  <meyering@lucent.com>
28043
28044         * m4/check-decl.m4: Add getenv to the list.
28045
28046 2000-02-27  Jim Meyering  <meyering@lucent.com>
28047
28048         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
28049         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
28050
28051         * lib/backupfile.c: Guard inclusion of stdlib.h with
28052         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
28053         Declare malloc if needed.
28054
28055         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
28056         `#ifndef HAVE_DECL..'
28057         now that autoconf always defines the HAVE_DECL_ symbols.
28058         * lib/human.c: Likewise.
28059         * lib/same.c: Likewise.
28060         * lib/strtoumax.c: Likewise.
28061
28062         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
28063         declaration check was not run.
28064         * lib/hash.c: Likewise.
28065         * lib/human.c: Likewise.
28066         * lib/same.c: Likewise.
28067         * lib/strtoumax.c: Likewise.
28068
28069         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
28070         `.', then first look up the entire `.'-containing string as a login
28071         name.
28072
28073 2000-02-23  Jim Meyering  <meyering@lucent.com>
28074
28075         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
28076         in place of my hack.
28077
28078 2000-02-18  Paul Eggert  <eggert@twinsun.com>
28079
28080         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
28081         (textint): New typedef.
28082         (parser_control): Member year changed from int to textint.
28083         All uses changed.
28084         (YYSTYPE): Removed; replaced by %union with int and textint members.
28085         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
28086         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
28087         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
28088         (tSNUMBER, tUNUMBER): Now of type <textintval>.
28089         (date, number, to_year): Use width of number in digits, not its value,
28090         to determine whether it's a 2-digit year, or a 2-digit time.
28091         (yylex): Store number of digits of numeric tokens.
28092         Reported by John Kendall.
28093
28094         (parser_control): Changed from struct parser_control to typedef (for
28095         consistency).  All uses changed.
28096
28097         (tID): Removed; not used.
28098         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
28099
28100 2000-02-14  Paul Eggert  <eggert@twinsun.com>
28101
28102         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
28103         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
28104
28105 2000-02-12  Jim Meyering  <meyering@lucent.com>
28106
28107         * lib/userspec.c (ISDIGIT): Define it.
28108         (isdigit): Remove definition.
28109         (is_number): Use ISDIGIT, not isdigit.
28110         <libintl.h>: Include.
28111         (_ and N_): Define.
28112         (parse_user_spec): Mark translatable strings.
28113
28114 2000-02-10  Jim Meyering  <meyering@lucent.com>
28115
28116         With these changes, nanosleep.[ch] are finally enough like the other
28117         lib/* replacement files to compile on a few more losing systems.
28118
28119         * lib/nanosleep.h: Don't include config.h.
28120         Remove prototype from declaration of nanosleep.
28121         (PARAMS): Remove now-unneeded definition.
28122         * lib/nanosleep.c: #undef nanosleep.
28123         (rpl_nanosleep): Rename from nanosleep.
28124
28125 2000-02-10  Jim Meyering  <meyering@lucent.com>
28126
28127         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
28128         gnu_nanosleep to rpl_nanosleep.
28129
28130 2000-02-09  Jim Meyering  <meyering@lucent.com>
28131
28132         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
28133         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
28134
28135 2000-02-08  Akim Demaille  <akim@epita.fr>
28136
28137         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
28138         `[' and `]' and remove uses of `changequote'.
28139         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
28140         (AC_SYS_LARGEFILE): Likewise.
28141         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
28142         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
28143         of changequote.
28144         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
28145         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
28146         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
28147         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
28148
28149 2000-02-05  Jim Meyering  <meyering@lucent.com>
28150
28151         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
28152         Remove explicit use of AC_HEADER_TIME.  It is required by
28153         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
28154         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
28155         in autoconf whereby the expansion of the latter ended up preceding
28156         the expansion of its prerequisite, AC_HEADER_TIME.
28157         Reported by Volker Borchert.
28158
28159 2000-02-03  Jim Meyering  <meyering@lucent.com>
28160
28161         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
28162
28163 2000-02-03  Jim Meyering  <meyering@lucent.com>
28164
28165         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
28166         rather than with `#if HAVE_UTMPNAME'.
28167
28168 2000-02-02  Jim Meyering  <meyering@lucent.com>
28169
28170         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
28171         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
28172         Reported by Eli Zaretskii.
28173
28174 2000-02-01  Jim Meyering  <meyering@lucent.com>
28175
28176         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
28177
28178 2000-01-31  Jim Meyering  <meyering@lucent.com>
28179
28180         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
28181         functions.  Add the time.h and sys/time.h headers along with the
28182         AC_REQUIRE'ment of AC_HEADER_TIME.
28183
28184 2000-01-31  Jim Meyering  <meyering@lucent.com>
28185
28186         * lib/nanosleep.h (nanosleep): Guard declaration with
28187         `#if ! HAVE_DECL_NANOSLEEP'.
28188         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
28189         the declaration in that vendor's sys/timers.h.
28190         Reported by Christian Krackowizer.
28191
28192         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
28193         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
28194         (ISPRINT): Likewise.
28195         Reported by Tom Tromey.
28196
28197 2000-01-30  Jim Meyering  <meyering@lucent.com>
28198
28199         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
28200
28201         * m4/prereq.m4 (utmp_includes): Define.
28202         Check for ut_user and ut_name members in both struct utmpx
28203         and struct utmp.
28204
28205 2000-01-30  Jim Meyering  <meyering@lucent.com>
28206
28207         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
28208         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
28209         header files where only utmpx.ut_user is declared.
28210
28211         * lib/readutmp.h (UT_USER): Define.
28212
28213 2000-01-29  Jim Meyering  <meyering@lucent.com>
28214
28215         * m4/lib-check.m4: New file containing library-related checks from
28216         fileutils and sh-utils (textutils had none).
28217
28218 2000-01-28  Jim Meyering  <meyering@lucent.com>
28219
28220         * m4/perl.m4: Change format of warning message to look more like that
28221         from the missing script.  Suggestion from François Pinard.
28222
28223 2000-01-25  Jim Meyering  <meyering@lucent.com>
28224
28225         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
28226         well as time.h in the compile check.
28227         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
28228         Fix typo in cross-compiling case: s/yes/no/.
28229
28230 2000-01-23  Jim Meyering  <meyering@lucent.com>
28231
28232         * m4/jm-macros.m4: Move df-related tests here from
28233         fileutils/configure.in
28234
28235         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
28236         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
28237
28238         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
28239         s/space/ac_fsusage_space/.
28240         (jm_FILE_SYSTEM_USAGE): Take two parameters.
28241
28242         * m4/ftruncate.m4: New file (derived from part of
28243         fileutils/configure.in).
28244         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
28245         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
28246
28247         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
28248         AC_SUBST these here, rather than just in sh-util/configure.in, so
28249         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
28250         all the same.
28251         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
28252         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
28253         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
28254         (AC_SUBST(POW_LIBM)): Likewise.
28255         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
28256
28257 2000-01-23  Jim Meyering  <meyering@lucent.com>
28258
28259         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
28260         obstack.c.
28261
28262 2000-01-22  Jim Meyering  <meyering@lucent.com>
28263
28264         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
28265
28266         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
28267
28268         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
28269         configure.in
28270         (AC_CHECK_HEADERS): Likewise for sh-utils.
28271         (AC_CHECK_HEADERS): Likewise for textutils.
28272         Merge the three lists of headers.
28273
28274         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
28275         from fileutils' configure.in.
28276
28277         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
28278         code. Moved tests into their own function (_jm_DECL_HEADERS) in
28279         check-decl.m4.
28280
28281         * m4/check-decl.m4: Use #if rather than #ifdef.
28282         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
28283         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
28284         (_jm_DECL_HEADERS): Define new function.
28285         (jm_CHECK_DECLARATIONS): Require it.
28286
28287 2000-01-22  Jim Meyering  <meyering@lucent.com>
28288
28289         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
28290         [! HAVE_DECL_STRTOULL]: Declare strtoull.
28291         Required for some AIX systems.  Reported by Christian Krackowizer.
28292         [TESTING] (main): New function.
28293
28294         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
28295         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
28296         letters.
28297
28298         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
28299         iswprint.
28300
28301         * lib/strverscmp.c (ISDIGIT): Define.
28302         (strverscmp): Use ISDIGIT, not isdigit.
28303
28304 2000-01-19  Jim Meyering  <meyering@lucent.com>
28305
28306         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
28307         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
28308         defines `struct timespec' in <sys/time.h>
28309
28310         * m4/c-bs-a.m4: Remove uses of changequote altogether.
28311         Thanks to Akim for explaining.
28312
28313 2000-01-17  Paul Eggert  <eggert@twinsun.com>
28314
28315         * lib/nanosleep.c (nanosleep):
28316         Don't use SA_INTERRUPT to decide whether to call sigaction, as
28317         POSIX.1 doesn't require SA_INTERRUPT and some systems
28318         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
28319         it's been part of POSIX.1 since day 1 (in 1988).
28320
28321 2000-01-17  Jim Meyering  <meyering@lucent.com>
28322
28323         * lib/interlock: Remove unused file.  Reported by François Pinard.
28324
28325 2000-01-16  Paul Eggert  <eggert@twinsun.com>
28326
28327         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
28328         alert, backslash, formfeed, and vertical tab unnecessarily in
28329         shell quoting style.
28330
28331 2000-01-16  Jim Meyering  <meyering@lucent.com>
28332
28333         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
28334         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
28335         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
28336         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
28337
28338 2000-01-16  Jim Meyering  <meyering@lucent.com>
28339
28340         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
28341         because the latter didn't work.
28342
28343 2000-01-15  Jim Meyering  <meyering@lucent.com>
28344
28345         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
28346         (AC_REPLACE_FUNCS): Add memcpy and memset.
28347         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
28348         Add strpbrk.
28349         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
28350
28351 2000-01-12  Jim Meyering  <meyering@lucent.com>
28352
28353         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
28354         (jm_PREREQ): Use it.
28355         (jm_PREREQ_READUTMP): New macro.
28356         (jm_PREREQ): Use it.
28357
28358 2000-01-11  Paul Eggert  <eggert@twinsun.com>
28359
28360         Quote multibyte characters correctly.
28361         * m4/c-bs-a.m4: New file.
28362         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
28363         (jm_PREREQ): Use it.
28364
28365 2000-01-11  Paul Eggert  <eggert@twinsun.com>
28366
28367         * m4/uintmax_t.m4: Port to autoconf 2.13.
28368
28369 2000-01-08  Jim Meyering  <meyering@ascend.com>
28370
28371         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
28372         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
28373
28374 2000-01-04  Jim Meyering  <meyering@ascend.com>
28375
28376         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
28377         jm_STRUCT_DIRENT_D_TYPE.
28378         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
28379         jm_STRUCT_DIRENT_D_INO.
28380         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
28381         jm_STRUCT_UTIMBUF.
28382         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
28383         renamings.
28384         * m4/utime.m4: Likewise.
28385
28386         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
28387         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
28388
28389 2000-01-03  Paul Eggert  <eggert@twinsun.com>
28390
28391         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
28392         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
28393
28394 2000-01-02  Jim Meyering  <meyering@ascend.com>
28395
28396         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
28397         remember if this is necessary.
28398
28399 1999-12-26  Jim Meyering  <meyering@ascend.com>
28400
28401         * m4/jm-macros.m4: Use it here.
28402         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
28403
28404 1999-12-23  Jim Meyering  <meyering@ascend.com>
28405
28406         * m4/jm-macros.m4: Check for clock_gettime (moved from
28407         fileutils/configure.in)
28408         Check for gettimeofday.
28409
28410 1999-12-20  Jim Meyering  <meyering@ascend.com>
28411
28412         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
28413         autoconf-2.14a-1999-12-20.
28414
28415 1999-12-19  Jim Meyering  <meyering@ascend.com>
28416
28417         * m4/lstat-slash.m4: New file.
28418         * m4/jm-macros.m4: Use the new macro:
28419         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
28420
28421 1999-12-07  Jim Meyering  <meyering@ascend.com>
28422
28423         * m4/perl.m4: Require that File::Compare be available, too.
28424         Too many systems seem to lack it.
28425
28426         * m4/strftime.m4: Add checks for most of the cpp macros tested in
28427         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
28428
28429 1999-11-18  Paul Eggert  <eggert@twinsun.com>
28430
28431         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
28432         problem with the QNX 4.25 shell, which doesn't propagate exit
28433         status of failed commands inside shell assignments.
28434
28435 1999-11-17  Jim Meyering  <meyering@ascend.com>
28436
28437         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
28438
28439 1999-11-07  Jim Meyering  <meyering@ascend.com>
28440
28441         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
28442
28443 1999-11-06  Jim Meyering  <meyering@ascend.com>
28444
28445         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
28446         * m4/jm-macros.m4 (jm_MACROS): Use it here.
28447
28448 1999-11-05  Jim Meyering  <meyering@ascend.com>
28449
28450         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
28451         configure.in of textutils, fileutils, and sh-utils into this one
28452         (shared between those packages) file.
28453         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
28454         AC_STRUCT_ST_BLKSIZE.
28455
28456 1999-11-03  Jim Meyering  <meyering@ascend.com>
28457
28458         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
28459         of AC_CHECK_TYPE checks includes unistd.h.
28460         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
28461         Suggestion from Akim Demaille.
28462
28463 1999-10-30  Jim Meyering  <meyering@ascend.com>
28464
28465         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
28466         m4-quoted string.
28467         * m4/ls-mntd-fs.m4: Likewise.
28468         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
28469         * m4/jm-winsz1.m4: Likewise.
28470
28471         * m4/const.m4: Remove file, since the fix made it into the experimental
28472         version of autoconf.
28473         * m4/mktime.m4: Likewise.
28474
28475         * m4/check-type.m4: Remove file, now that the latest version of
28476         AC_CHECK_TYPE takes a third arg to specify additional #includes.
28477
28478         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
28479         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
28480         AC_CHECK_TYPE.
28481
28482 1999-10-04  Jim Meyering  <meyering@ascend.com>
28483
28484         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
28485
28486 1999-09-22  Paul Eggert  <eggert@twinsun.com>
28487
28488         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
28489         2.95.1 bug with HP-UX 10.20.
28490
28491 1999-09-17  Jim Meyering  <meyering@ascend.com>
28492
28493         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
28494         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
28495         due to missing strdup (against sh-utils-2.0).
28496
28497 1999-08-29  Jim Meyering  <meyering@ascend.com>
28498
28499         * m4/jm-macros.m4: Require jm_BISON.
28500         * m4/bison.m4: New file.
28501
28502 1999-08-17  Paul Eggert  <eggert@twinsun.com>
28503
28504         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
28505         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
28506
28507 1999-08-05  Jim Meyering  <meyering@ascend.com>
28508
28509         * m4/getline.m4: Rename test file from conftestdata to conftest.data
28510         to avoid conflicts with `conftest' on 8+3 filesystems.
28511         Suggestion from Eli Zaretskii.
28512
28513 1999-08-04  Jim Meyering  <meyering@ascend.com>
28514
28515         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
28516         fileutils and sh-utils (textutils's getline test was inadequate).
28517         (AM_FUNC_GETLINE): Run this test.
28518         (AC_CHECK_FUNCS): Check for getdelim.
28519         Reported by Bob Proulx.
28520
28521 1999-08-02  Jim Meyering  <meyering@ascend.com>
28522
28523         * m4/jm-macros.m4: Add a comment.
28524
28525 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28526
28527         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
28528         <inttypes.h> defines strtoumax as a macro (and not as a
28529         function).
28530
28531 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28532
28533         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
28534         that we can shift, multiply and divide unsigned long long
28535         values; Ultrix cc can't do it.
28536
28537 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28538
28539         * m4/mktime.m4: New file, which is a preview of what should appear
28540         in the next public autoconf release.
28541
28542 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28543
28544         * m4/lfs.m4: Remove this file.
28545         * m4/largefile.m4: New file.  It contains the old contents of
28546         lfs.m4, except that all names with prefix AC_LFS have been
28547         changed to use the prefix AC_SYS_LARGEFILE instead, to be
28548         compatible with future autoconf versions.  Also, some minor m4
28549         quoting problems have been fixed.
28550
28551 1999-08-01  Paul Eggert  <eggert@twinsun.com>
28552
28553         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
28554         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
28555         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
28556         and simplify the shell code.
28557
28558 1999-08-01  Jim Meyering  <meyering@ascend.com>
28559
28560         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
28561         m4.
28562
28563 1999-07-20  Jim Meyering  <meyering@ascend.com>
28564
28565         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
28566
28567 1999-07-15  Jim Meyering  <meyering@ascend.com>
28568
28569         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
28570
28571 1999-05-22  Jim Meyering  <meyering@ascend.com>
28572
28573         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
28574
28575 1999-05-20  Jim Meyering  <meyering@ascend.com>
28576
28577         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
28578         Add a colon after each `then' in case $4 is empty.
28579
28580 1999-05-16  Jim Meyering  <meyering@ascend.com>
28581
28582         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
28583
28584 1999-05-10  Jim Meyering  <meyering@ascend.com>
28585
28586         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
28587
28588         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
28589         AC_FUNC_MKTIME.
28590
28591 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
28592
28593         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
28594
28595 1999-05-04  Paul Eggert  <eggert@twinsun.com>
28596
28597         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
28598         not CPPFLAGS, so that linking works correctly in IRIX.
28599
28600 1999-04-30  Paul Eggert  <eggert@twinsun.com>
28601
28602         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
28603
28604 1999-04-20  Paul Eggert  <eggert@twinsun.com>
28605
28606         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
28607         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
28608         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
28609         jm_AC_TYPE_UNSIGNED_LONG_LONG.
28610         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
28611
28612         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
28613
28614 1999-04-20  Jim Meyering  <meyering@ascend.com>
28615
28616         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
28617         AC_REPLACE xstroull if necessary.  From Paul Eggert.
28618         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
28619
28620 1999-04-18  Jim Meyering  <meyering@ascend.com>
28621
28622         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
28623         * m4/jm-macros.m4: Use it.
28624
28625 1999-04-06  Jim Meyering  <meyering@ascend.com>
28626
28627         * m4/strftime.m4: Remove test for %f.
28628
28629 1999-03-29  Jim Meyering  <meyering@ascend.com>
28630
28631         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
28632         superset of the AC_TYPE_* checks in the textutils, fileutils,
28633         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
28634         AC_TYPE_PID_T.
28635
28636 1999-03-28  Jim Meyering  <meyering@ascend.com>
28637
28638         * m4/jm-macros.m4: Define GNU_PACKAGE here.
28639         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
28640         replaced e.g., in the *.sh files of the sh-utils.
28641
28642 1999-03-20  Jim Meyering  <meyering@ascend.com>
28643
28644         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
28645         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
28646         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
28647
28648 1999-03-19  Jim Meyering  <meyering@ascend.com>
28649
28650         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
28651
28652 1999-03-12  Jim Meyering  <meyering@ascend.com>
28653
28654         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
28655
28656 1999-03-07  Jim Meyering  <meyering@ascend.com>
28657
28658         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
28659         declared.
28660
28661 1999-02-17  Jim Meyering  <meyering@ascend.com>
28662
28663         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
28664         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
28665
28666 1999-02-07  Jim Meyering  <meyering@ascend.com>
28667
28668         * m4/group-member.m4: New file -- extracted from sh-utils'
28669         configure.in.
28670
28671         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
28672         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
28673
28674 1999-02-06  Jim Meyering  <meyering@ascend.com>
28675
28676         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
28677         * m4/fnmatch.m4: Likewise.
28678         * m4/getgroups.m4: Likewise.
28679         * m4/lstat.m4: Likewise.
28680         * m4/malloc.m4: Likewise.
28681         * m4/putenv.m4: Likewise.
28682         * m4/realloc.m4: Likewise.
28683         * m4/regex.m4: Likewise.
28684         * m4/stat.m4: Likewise.
28685         * m4/strftime.m4: Likewise.
28686         Suggestion from Alain Magloire.
28687
28688         * m4/chown.m4: Use `.$ac_objext', not `.o'.
28689         * m4/fnmatch.m4: Likewise.
28690         * m4/getgroups.m4: Likewise.
28691         * m4/getline.m4: Likewise.
28692         * m4/lstat.m4: Likewise.
28693         * m4/malloc.m4: Likewise.
28694         * m4/memcmp.m4: Likewise.
28695         * m4/putenv.m4: Likewise.
28696         * m4/realloc.m4: Likewise.
28697         * m4/regex.m4: Likewise.
28698         * m4/stat.m4: Likewise.
28699         * m4/strftime.m4: Likewise.
28700         Suggestion from Alain Magloire.
28701
28702         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
28703         an argument.
28704
28705         * m4/regex.m4: Add a run-time Test for proper operation of
28706         re_compile_pattern.
28707
28708 1999-01-31  Jim Meyering  <meyering@ascend.com>
28709
28710         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
28711
28712 1999-01-30  Jim Meyering  <meyering@ascend.com>
28713
28714         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
28715
28716         * m4/jm-mktime.m4: Make this a wrapper around the official
28717         AM_FUNC_MKTIME rather than my private copy, now that the official one
28718         is up to date.
28719         * m4/mktime.m4: Remove file.
28720
28721         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
28722         * m4/uptime.m4: Likewise.
28723         * m4/uintmax_t.m4: Likewise.
28724
28725 1999-01-28  Jim Meyering  <meyering@ascend.com>
28726
28727         * m4/jm-macros.m4: Use jm_AFS.
28728         * m4/afs.m4: New file (from fileutils' configure.in).
28729
28730         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
28731         * m4/chown.m4: Likewise.
28732         * m4/d-ino.m4: Likewise.
28733         * m4/d-type.m4: Likewise.
28734         * m4/fnmatch.m4: Likewise.
28735         * m4/getgroups.m4: Likewise.
28736         * m4/gettext.m4: Likewise.
28737         * m4/jm-mktime.m4: Likewise.
28738         * m4/jm-winsz2.m4: Likewise.
28739         * m4/lcmessage.m4: Likewise.
28740         * m4/ls-mntd-fs.m4: Likewise.
28741         * m4/malloc.m4: Likewise.
28742         * m4/memcmp.m4: Likewise.
28743         * m4/putenv.m4: Likewise.
28744         * m4/realloc.m4: Likewise.
28745         * m4/st_mtim.m4: Likewise.
28746         * m4/strftime.m4: Likewise.
28747
28748 1999-01-16  Jim Meyering  <meyering@ascend.com>
28749
28750         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
28751         (ARGMATCH_DIE_DECL): Define.
28752
28753 1999-01-12  Jim Meyering  <meyering@ascend.com>
28754
28755         * m4/Makefile.am.in: Rewrite to avoid using fmt.
28756         Reported by Lars Hecking.
28757
28758 1999-01-10  Jim Meyering  <meyering@ascend.com>
28759
28760         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
28761         gross kludge.
28762         * m4/inttypes_h.m4: Likewise.
28763         * m4/lstat.m4: Likewise.
28764         * m4/malloc.m4: Likewise.
28765         * m4/readdir.m4: Likewise.
28766         * m4/realloc.m4: Likewise.
28767         * m4/st_dm_mode.m4: Likewise.
28768         * m4/stat.m4: Likewise.
28769         * m4/utimbuf.m4: Likewise.
28770         * m4/utimes.m4: Likewise.
28771
28772         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
28773         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
28774         comments in config.h.in are meaningful.
28775
28776         * m4/jm-macros.m4: Require autoconf-2.13 here.
28777
28778         * m4/regex.m4: By default, don't use the included regex.c on systems
28779         with glibc 2.  Suggestion from Uli Drepper.
28780
28781 1999-01-02  Jim Meyering  <meyering@ascend.com>
28782
28783         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
28784
28785 1998-12-18  Jim Meyering  <meyering@ascend.com>
28786
28787         * m4/Makefile.am.in (Makefile.am): Simplify rule.
28788         Based on a suggestion from Lars Hecking.
28789
28790 1998-11-16  Paul Eggert  <eggert@twinsun.com>
28791
28792         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
28793
28794 1998-11-16  Jim Meyering  <meyering@ascend.com>
28795
28796         * m4/lfs.m4: Double-quote the `uname...` expression.
28797
28798 1998-11-14  Jim Meyering  <meyering@ascend.com>
28799
28800         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
28801         * m4/stat.m4: Likewise.
28802
28803 1998-11-03  Jim Meyering  <meyering@ascend.com>
28804
28805         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
28806         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
28807
28808 1998-10-18  Jim Meyering  <meyering@ascend.com>
28809
28810         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
28811
28812 1998-10-17  Jim Meyering  <meyering@ascend.com>
28813
28814         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
28815         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
28816         calls for those previously hard-coded headers.  Instead, take a new
28817         parameter.
28818         (jm_CHECK_DECLARATIONS): Reflect interface change.
28819         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
28820         (jm_CHECK_DECL_LOCALTIME_R): New macro.
28821
28822         * m4/mktime.m4: Test for spring-forward gap before long-running test.
28823
28824 1998-10-14  Jim Meyering  <meyering@ascend.com>
28825
28826         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
28827         instead of "TZ=America/Vancouver".  From Paul Eggert.
28828
28829 1998-10-11  Jim Meyering  <meyering@ascend.com>
28830
28831         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
28832         This adds a test for a recently added compatibility fix for mktime.c.
28833         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
28834
28835 1998-09-27  Jim Meyering  <meyering@ascend.com>
28836
28837         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
28838
28839         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
28840         ../configure.in, including a change from Gordon Matzigkeit to allow
28841         cross-compiling for the Hurd.
28842
28843         * m4/glibc.m4: New file/macro to test for the GNU C Library
28844         versions 1 and 2.  From Gordon Matzigkeit.
28845         Indent.
28846
28847 1998-09-21  Jim Meyering  <meyering@ascend.com>
28848
28849         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
28850
28851 1998-08-18  Paul Eggert  <eggert@twinsun.com>
28852
28853         Port nanosecond-resolution times to UnixWare 2.1.2 and
28854         pedantic Solaris 2.6.
28855
28856         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
28857         AC_STRUCT_ST_MTIM.
28858         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
28859         Generate name of ns member, instead of just 1 or undef.
28860         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
28861
28862 1998-08-15  Jim Meyering  <meyering@ascend.com>
28863
28864         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
28865         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
28866         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
28867         instead of jm_TYPE_SSIZE_T.
28868
28869 1998-08-12  Jim Meyering  <meyering@ascend.com>
28870
28871         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
28872
28873 1998-08-02  Jim Meyering  <meyering@ascend.com>
28874
28875         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
28876         in acconfig.h manually.
28877
28878 1998-07-31  Paul Eggert  <eggert@twinsun.com>
28879
28880         * m4/st_mtim.m4: New file.
28881
28882 1998-07-28  Jim Meyering  <meyering@ascend.com>
28883
28884         * m4/utimes.m4: Undef stat.
28885
28886 1998-07-25  Jim Meyering  <meyering@ascend.com>
28887
28888         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
28889         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
28890
28891 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
28892
28893         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
28894         uid and gid actually remain unchanged.
28895
28896 1998-07-07  Jim Meyering  <meyering@ascend.com>
28897
28898         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
28899
28900 1998-07-04  Jim Meyering  <meyering@ascend.com>
28901
28902         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
28903         to prove that this macro can be used in packages without regex.c.
28904
28905 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
28906
28907         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
28908         is to be used.
28909
28910 1998-07-03  Jim Meyering  <meyering@ascend.com>
28911
28912         * m4/gettext.m4: Add -lintl if it's found to be necessary.
28913
28914         * m4/gettext.m4: New file -- from gettext-0.10.35.
28915         * m4/lcmessage.m4: Likewise.
28916         * m4/progtest.m4: Likewise.
28917
28918         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
28919         * m4/jm-macros.m4: Require the new macro.
28920
28921 1998-06-29  Jim Meyering  <meyering@ascend.com>
28922
28923         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
28924         for the definition of NGROUPS (used in a system header included
28925         by sys/mount.h).
28926
28927 1998-06-28  Jim Meyering  <meyering@ascend.com>
28928
28929         * m4/ls-mntd-fs.m4: New file.
28930         * m4/fstypename.m4: New file.
28931
28932         * m4/jm-macros.m4: Require the new macro.
28933         * m4/jm-glibc-io.m4: New file.
28934
28935 1998-05-19  Jim Meyering  <meyering@ascend.com>
28936
28937         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
28938         * m4/lchown.m4: New file.
28939
28940         * m4/Makefile.am.in: New file.
28941         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
28942
28943 1998-05-14  Jim Meyering  <meyering@ascend.com>
28944
28945         * m4/Makefile.am (EXTRA_DIST): Add them.
28946         * m4/jm-macros.m4: New file.
28947         * m4/utimbuf.m4: New file.
28948
28949 1998-05-12  Jim Meyering  <meyering@ascend.com>
28950
28951         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
28952
28953 1998-05-11  Jim Meyering  <meyering@ascend.com>
28954
28955         * m4/isc-posix.m4: New file.
28956
28957 1998-05-10  Jim Meyering  <meyering@ascend.com>
28958
28959         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
28960
28961 1998-05-09  Jim Meyering  <meyering@ascend.com>
28962
28963         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
28964         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
28965         with automake.
28966
28967         * m4/ssize_t.m4: New file.
28968         * m4/mktime.m4: Remove file -- the new automake has this now.
28969
28970 1998-04-26  Jim Meyering  <meyering@ascend.com>
28971
28972         * m4/assert.m4: New file.
28973         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
28974
28975 1998-04-05  Jim Meyering  <meyering@ascend.com>
28976
28977         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
28978         (jm_PREREQ): Use it here.
28979
28980 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
28981
28982         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
28983         in acconfig.h.
28984
28985 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
28986
28987         * m4/prereq.m4: New file.
28988         * m4/error.m4: New file.
28989         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
28990
28991 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
28992
28993         * m4/getline.m4: Don't set am_cv_func_working_getline before the
28994         cache-check for the same variable -- that defeated the purpose of
28995         the test; the test program was never run.  This was a problem only
28996         on systems with losing getline functions -- HP-UX 10.20 is one.
28997         Reported by Bjorn Helgaas.
28998
28999 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
29000
29001         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
29002
29003 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
29004
29005         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
29006
29007         * m4/const.m4: New file.  Use an initializer in this declaration
29008         typedef int charset[2]; const charset x;
29009         Reported by Bob Glickstein.
29010
29011 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
29012
29013         * m4/chown.m4: Fix reversed types on -1 args to chown.
29014         From Kaveh Ghazi.
29015
29016 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
29017
29018         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
29019         Add lseek and memchr.
29020
29021         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
29022         T.E.Dickey <dickey@clark.net> said that some older preprocessors
29023         have a 20-character limit on names.
29024
29025 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
29026
29027         * m4/inttypes_h.m4: New file.
29028         * m4/uintmax_t.m4: New file.
29029         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
29030
29031 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
29032   Free Software Foundation, Inc.
29033 Copying and distribution of this file, with or without modification,
29034 are permitted provided the copyright notice and this notice are preserved.