Guard against FreeBSD 6.1 bug.
[gnulib.git] / ChangeLog
1 2007-04-10  Bruno Haible  <bruno@clisp.org>
2
3         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
4         for NaN and Infinity. Needed on FreeBSD 6.1.
5         * tests/test-vasnprintf-posix.c (test_function): Undo last change
6         regarding results for "%010a" of Infinity and NaN.
7         * tests/test-vasprintf-posix.c (test_function): Likewise.
8         * tests/test-snprintf-posix.h (test_function): Likewise.
9         * tests/test-sprintf-posix.h (test_function): Likewise.
10         * tests/test-fprintf-posix.h (test_function): Likewise.
11         * tests/test-printf-posix.h (test_function): Likewise.
12         * tests/test-fprintf-posix.out: Likewise.
13
14 2007-04-10  Bruno Haible  <bruno@clisp.org>
15
16         * modules/locale-tests: New file.
17         * tests/test-locale.c: New file.
18
19         * modules/locale: New file.
20         * lib/locale_.h: New file.
21         * m4/locale_h.m4: New file.
22
23 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
24             Bruno Haible  <bruno@clisp.org>
25
26         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
27         be determined, test for availability of the copysignf, copysign,
28         copysignl functions.
29         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
30         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
31         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
32
33 2007-04-09  Eric Blake  <ebb9@byu.net>
34
35         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
36         * modules/stdio (Makefile.am): Support fflush.
37         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
38         * modules/fflush: New file.
39         * lib/fflush.c: Likewise.
40         * m4/fflush.m4: Likewise.
41         * modules/fflush-tests: New test.
42         * tests/test-fflush.c: Likewise.
43         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
44
45 2007-04-06  Bruno Haible  <bruno@clisp.org>
46
47         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
48         (VASNPRINTF): Use signbit for faster determination whether to print a
49         minus sign.
50         * modules/vasnprintf (Files): Remove lib/float+.h.
51         * modules/fprintf-posix (Depends-on): Add signbit.
52         * modules/snprintf-posix (Depends-on): Likewise.
53         * modules/sprintf-posix (Depends-on): Likewise.
54         * modules/vasnprintf-posix (Depends-on): Likewise.
55         * modules/vasprintf-posix (Depends-on): Likewise.
56         * modules/vfprintf-posix (Depends-on): Likewise.
57         * modules/vsnprintf-posix (Depends-on): Likewise.
58         * modules/vsprintf-posix (Depends-on): Likewise.
59
60 2007-04-06  Bruno Haible  <bruno@clisp.org>
61
62         * tests/test-frexp.c (main): Test also the sign bit of zero results.
63         * tests/test-frexpl.c (main): Likewise.
64         * tests/test-ldexpl.c (main): Likewise.
65         * modules/frexp-tests (Depends-on): Add signbit.
66         * modules/frexpl-tests (Depdends-on): Likewise.
67         * modules/ldexpl-tests (Depdends-on): Likewise.
68
69 2007-04-06  Bruno Haible  <bruno@clisp.org>
70
71         * modules/signbit-tests: New file.
72         * tests/test-signbit.c: New file.
73
74         * modules/signbit: New file.
75         * lib/signbitf.c: New file.
76         * lib/signbitd.c: New file.
77         * lib/signbitl.c: New file.
78         * m4/signbit.m4: New file.
79         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
80         (signbit): New macro.
81         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
82         REPLACE_SIGNBIT.
83         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
84         REPLACE_FREXPL into math.h.
85
86 2007-04-06  Bruno Haible  <bruno@clisp.org>
87
88         * modules/isnanf-nolibm-tests: New file.
89         * tests/test-isnanf.c: New file.
90
91         * modules/isnanf-nolibm: New file.
92         * lib/isnanf.h: New file.
93         * lib/isnanf.c: New file.
94         * lib/isnan.c: Consider the USE_FLOAT macro.
95         * m4/isnanf.m4: New file.
96
97 2007-04-06  Bruno Haible  <bruno@clisp.org>
98
99         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
100         (Link): New section.
101
102         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
103
104 2007-04-06  Bruno Haible  <bruno@clisp.org>
105
106         Assume the 'long double' type.
107         * m4/longdouble.m4: Remove file.
108         * config/srclist.txt: Don't mention longdouble.m4.
109         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
110         * lib/float+.h: Likewise.
111         * lib/frexp.c: Likewise.
112         * lib/printf-args.h: Likewise.
113         * lib/printf-args.c: Likewise.
114         * lib/printf-frexp.c: Likewise.
115         * lib/printf-parse.c: Likewise.
116         * lib/vasnprintf.c: Likewise.
117         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
118         * m4/intl.m4: Likewise.
119         * m4/isnanl.m4: Likewise.
120         * m4/printf.m4: Likewise.
121         * m4/printf-frexpl.m4: Likewise.
122         * m4/vasnprintf.m4: Likewise.
123         * modules/allocsa (Files): Remove m4/longdouble.m4.
124         * modules/gettext (Files): Likewise.
125         * modules/relocatable-prog-wrapper (Files): Likewise.
126         * modules/vasnprintf (Files): Likewise.
127         * modules/isnanl (Files): Likewise.
128         (Include): Simplify.
129         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
130         (Include): Simplify.
131         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
132         (Include): Simplify.
133         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
134         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
135         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
136         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
137         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
138         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
139         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
140         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
141         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
142         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
143         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
144         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
145         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
146         * tests/test-isnanl.c: Likewise.
147         * tests/test-snprintf-posix.h: Likewise.
148         * tests/test-sprintf-posix.h: Likewise.
149         * tests/test-vasnprintf-posix.c: Likewise.
150         * tests/test-vasnprintf-posix2.c: Likewise.
151         * tests/test-vasprintf-posix.c: Likewise.
152
153 2007-04-06  Bruno Haible  <bruno@clisp.org>
154
155         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
156         * lib/math_.h [__DECC]: Include the overridden include file through
157         #include_next, outside the double-inclusion guard.
158         * lib/stdio_.h [__DECC]: Likewise.
159         * lib/stdlib_.h [__DECC]: Likewise.
160         * lib/string_.h [__DECC]: Likewise.
161         * lib/time_.h [__DECC]: Likewise.
162         * lib/wchar_.h [__DECC]: Likewise.
163         * lib/wctype_.h [__DECC]: Likewise.
164         * lib/inttypes_.h [__DECC]: Likewise.
165         Reported by Albert Chin <china@thewrittenword.com> in
166         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
167
168 2007-04-04  Eric Blake  <ebb9@byu.net>
169
170         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
171         1.5.x.
172
173 2007-04-04  Bruno Haible  <bruno@clisp.org>
174
175         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
176         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
177
178 2007-04-04  Bruno Haible  <bruno@clisp.org>
179
180         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
181         results for "%010a" of Infinity and NaN.
182         * tests/test-vasprintf-posix.c (test_function): Likewise.
183         * tests/test-snprintf-posix.h (test_function): Likewise.
184         * tests/test-sprintf-posix.h (test_function): Likewise.
185         * tests/test-fprintf-posix.h (test_function): Remove these tests.
186         * tests/test-printf-posix.h (test_function): Likewise.
187         * tests/test-fprintf-posix.out: Update.
188         Needed for FreeBSD 6.1.
189
190 2007-04-04  Bruno Haible  <bruno@clisp.org>
191
192         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
193         directly used by the gnulib modules nor by gnulib-tool.
194
195 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
196
197         * DEPENDENCIES: Give overall description of version dependency
198         desirability.  Use more-typical names for apps.
199         Add shell, coreutils, diffutils, grep, tar, gzip.
200
201 2007-04-04  Simon Josefsson  <simon@josefsson.org>
202
203         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
204
205 2007-04-04  Karl Berry  <karl@gnu.org>
206
207         * MODULES.html.sh (func_module): missing '.
208
209 2007-04-03  Bruno Haible  <bruno@clisp.org>
210
211         * modules/argmatch-tests (Makefile.am): New variable
212         test_argmatch_LDADD.
213         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
214         * modules/array-list-tests (Makefile.am): New variable
215         test_array_list_LDADD.
216         * modules/array-oset-tests (Makefile.am): New variable
217         test_array_oset_LDADD.
218         * modules/avltree-list-tests (Makefile.am): New variable
219         test_avltree_list_LDADD.
220         * modules/avltree-oset-tests (Makefile.am): New variable
221         test_avltree_oset_LDADD.
222         * modules/avltreehash-list-tests (Makefile.am): New variable
223         test_avltreehash_list_LDADD.
224         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
225         test_canonicalize_lgpl_LDADD.
226         * modules/carray-list-tests (Makefile.am): New variable
227         test_carray_list_LDADD.
228         * modules/dirname-tests (Makefile.am): New variable
229         test_dirname_LDADD.
230         * modules/linked-list-tests (Makefile.am): New variable
231         test_linked_list_LDADD.
232         * modules/linkedhash-list-tests (Makefile.am): New variable
233         test_linkedhash_list_LDADD.
234         * modules/rbtree-list-tests (Makefile.am): New variable
235         test_rbtree_list_LDADD.
236         * modules/rbtree-oset-tests (Makefile.am): New variable
237         test_rbtree_oset_LDADD.
238         * modules/rbtreehash-list-tests (Makefile.am): New variable
239         test_rbtreehash_list_LDADD.
240         * modules/xvasprintf-tests (Makefile.am): New variable
241         test_xvasprintf_LDADD.
242         Reported by Eric Blake.
243
244 2007-04-03  Eric Blake  <ebb9@byu.net>
245
246         * DEPENDENCIES: Weaken m4 requirements.
247
248 2007-04-03  Bruno Haible  <bruno@clisp.org>
249
250         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
251         * modules/isnanl-tests (configure.ac): Likewise.
252
253 2007-04-03  Ben Pfaff  <blp@gnu.org>
254
255         * modules/iconv_open: Add $(srcdir)/ to source directory
256         references in Makefile fragments that call gperf, to fix VPATH
257         builds.
258
259 2007-04-03  Bruno Haible  <bruno@clisp.org>
260
261         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
262         * lib/ldexpl.c: Undo last change.
263
264 2007-04-03  Bruno Haible  <bruno@clisp.org>
265
266         * modules/printf-frexpl (Depends-on): Undo last change.
267         (Files): Add m4/ldexpl.m4.
268
269 2007-04-03  Bruno Haible  <bruno@clisp.org>
270
271         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
272         * modules/isnanl (Link): New section.
273
274         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
275         * modules/frexp (Link): New section.
276
277         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
278         * modules/frexpl (Link): New section.
279
280         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
281         * modules/ldexpl (Link): New section.
282
283 2007-04-03  Bruno Haible  <bruno@clisp.org>
284
285         * modules/TEMPLATE-EXTENDED: New file.
286         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
287
288 2007-04-03  Bruno Haible  <bruno@clisp.org>
289
290         * DEPENDENCIES: New file.
291         Suggested by Simon Josefsson.
292
293 2007-04-03  Bruno Haible  <bruno@clisp.org>
294
295         * doc/gnulib.texi: Escape @.
296
297 2007-04-03  James Youngman  <jay@gnu.org>
298         and Paul Eggert  <eggert@cs.ucla.edu>
299
300         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
301         birthtime on all systems that have birthtime, not just those which
302         use st_birthtimensec rather than st_birthtim.  Putting zero in
303         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
304         that the birth time is not available for files on an NFS mount.
305
306 2007-04-03  Simon Josefsson  <simon@josefsson.org>
307
308         * modules/memxor: Move back from crypto/, suggested by Bruno.
309         * modules/crypto/hmac-sha1: Fix memxor dependency.
310
311         * modules/crypto/gc: Moved from ../.
312
313 2007-04-02  Eric Blake  <ebb9@byu.net>
314
315         * lib/ldexpl.c (includes): Avoid libm.
316
317         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
318
319 2007-04-02  Bruno Haible  <bruno@clisp.org>
320
321         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
322         on IRIX.
323
324 2007-04-02  Bruno Haible  <bruno@clisp.org>
325
326         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
327         x86 or x86_64 platforms running MacOS X.
328         Reported by Ryan Schmidt <@ryandesign.com>.
329
330 2007-04-02  Bruno Haible  <bruno@clisp.org>
331
332         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
333         i386.
334
335 2007-04-01  Simon Josefsson  <simon@josefsson.org>
336
337         * modules/crypto/arcfour: Moved from ../.
338         * modules/crypto/arcfour-tests: Moved from ../.
339         * modules/crypto/arctwo: Moved from ../.
340         * modules/crypto/arctwo-tests: Moved from ../.
341         * modules/crypto/des: Moved from ../.
342         * modules/crypto/des-tests: Moved from ../.
343         * modules/crypto/gc-arcfour: Moved from ../.
344         * modules/crypto/gc-arcfour-tests: Moved from ../.
345         * modules/crypto/gc-arctwo: Moved from ../.
346         * modules/crypto/gc-arctwo-tests: Moved from ../.
347         * modules/crypto/gc-des: Moved from ../.
348         * modules/crypto/gc-des-tests: Moved from ../.
349         * modules/crypto/gc-hmac-md5: Moved from ../.
350         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
351         * modules/crypto/gc-hmac-sha1: Moved from ../.
352         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
353         * modules/crypto/gc-md2: Moved from ../.
354         * modules/crypto/gc-md2-tests: Moved from ../.
355         * modules/crypto/gc-md4: Moved from ../.
356         * modules/crypto/gc-md4-tests: Moved from ../.
357         * modules/crypto/gc-md5: Moved from ../.
358         * modules/crypto/gc-md5-tests: Moved from ../.
359         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
360         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
361         * modules/crypto/gc-random: Moved from ../.
362         * modules/crypto/gc-rijndael: Moved from ../.
363         * modules/crypto/gc-rijndael-tests: Moved from ../.
364         * modules/crypto/gc-sha1: Moved from ../.
365         * modules/crypto/gc-sha1-tests: Moved from ../.
366         * modules/crypto/gc-tests: Moved from ../.
367         * modules/crypto/hmac-md5: Moved from ../.
368         * modules/crypto/hmac-md5-tests: Moved from ../.
369         * modules/crypto/hmac-sha1: Moved from ../.
370         * modules/crypto/hmac-sha1-tests: Moved from ../.
371         * modules/crypto/md2: Moved from ../.
372         * modules/crypto/md2-tests: Moved from ../.
373         * modules/crypto/md4: Moved from ../.
374         * modules/crypto/md4-tests: Moved from ../.
375         * modules/crypto/md5: Moved from ../.
376         * modules/crypto/md5-tests: Moved from ../.
377         * modules/crypto/memxor: Moved from ../.
378         * modules/crypto/rijndael: Moved from ../.
379         * modules/crypto/rijndael-tests: Moved from ../.
380         * modules/crypto/sha1: Moved from ../.
381
382 2007-03-30  James Youngman  <jay@gnu.org>
383
384         * tests/test-stat-time.c (prepare_test): use chmod() rather than
385         rename() to change the ctime of a file (because ctime is unaffected
386         by rename on jfs2 on AIX 5.1).
387         (main): Start by doing cleanup, in case a previous run failed leaving
388         test files behind.
389
390 2007-03-31  Bruno Haible  <bruno@clisp.org>
391
392         Support old proprietary implementations of iconv.
393         * modules/iconv_open: New file.
394         * lib/iconv_.h: New file.
395         * m4/iconv_h.m4: New file.
396         * lib/iconv_open.c: New file.
397         * lib/iconv_open-aix.gperf: New file.
398         * lib/iconv_open-hpux.gperf: New file.
399         * lib/iconv_open-irix.gperf: New file.
400         * lib/iconv_open-osf.gperf: New file.
401         * m4/iconv_open.m4: New file.
402         * modules/linebreak (Depends-on): Add iconv_open.
403         * modules/striconv (Depends-on): Likewise.
404         * modules/striconveh (Depends-on): Likewise.
405         * modules/unicodeio (Depends-on): Likewise.
406         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
407         (iconv_t)(-1).
408         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
409         conversion if cd is (iconv_t)(-1).
410         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
411         is not possible.
412
413 2007-03-31  Bruno Haible  <bruno@clisp.org>
414
415         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
416         work on Solaris either. Protect also second use of "autodetect_jp".
417
418 2007-03-31  Bruno Haible  <bruno@clisp.org>
419
420         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
421         the function is not present.
422
423 2007-03-31  Bruno Haible  <bruno@clisp.org>
424
425         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
426         the function is not present.
427
428 2007-03-31  Bruno Haible  <bruno@clisp.org>
429
430         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
431         a bug in HP-UX iconv_open().
432
433 2007-03-31  Bruno Haible  <bruno@clisp.org>
434
435         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
436         (Mathematics <math.h>): New section, add fpieee.
437         (Input/output <stdio.h>): Add fseterr.
438         (Mathematics <math.h>): New section, add printf-frexp.
439         (Container data structures): Add sublist.
440         (Core language properties): Add fpucw, inline.
441         (Functions for greatest-width integer types <inttypes.h>): Add
442         imaxabs, imaxdiv, inttypes.
443         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
444         isnanl-nolibm, ldexp.
445         (Mathematics <math.h>): New section, add printf-frexpl.
446         (Support for systems lacking POSIX:2001): Add fprintf-posix,
447         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
448         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
449         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
450         (Unicode string functions): Add unistr/u*-mbtoucr.
451         (Java): Add javacomp-script, javaexec-script.
452         (C#): Add csharpcomp-script, csharpexec-script.
453         (Support for building libraries and executables): Add havelib,
454         relocatable-*.
455         (Support for maintaining and releasing projects): Renamed from
456         'Support for maintaining and release projects'. Add announce-gen.
457
458 2007-03-31  Bruno Haible  <bruno@clisp.org>
459
460         * README: Talk primarily about git.
461         (git and CVS): Renamed from CVS.
462         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
463         gnulib is available through git.
464         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
465
466 2007-03-30  Bruno Haible  <bruno@clisp.org>
467
468         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
469         * lib/poll_.h: Likewise.
470         * lib/stat_.h: Likewise.
471         * lib/sys_time_.h: Likewise.
472         * lib/sysexit_.h: Likewise.
473         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
474         * lib/stdbool_.h: Likewise.
475         * lib/byteswap_.h: Add double-inclusion guard.
476
477 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
478
479         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
480
481 2007-03-30  Karl Berry  <karl@gnu.org>
482
483         * config/srclist-update: double space after USA in the license
484         substitution, since that's how it's usually (?) written.
485
486 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
487
488         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
489         reported by Bruno Haible.
490
491 2007-03-29  Bruno Haible  <bruno@clisp.org>
492
493         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
494         a bug in AIX iconv().
495
496 2007-03-29  Bruno Haible  <bruno@clisp.org>
497
498         * modules/ldexpl-tests: New file.
499         * tests/test-ldexpl.c: New file.
500
501 2007-03-29  Bruno Haible  <bruno@clisp.org>
502
503         * lib/ldexpl.c: Include fpucw.h.
504         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
505         multiplication.
506         * modules/ldexpl (Depends-on): Add fpucw.
507
508 2007-03-29  Bruno Haible  <bruno@clisp.org>
509
510         * modules/ldexpl: New file.
511         * m4/ldexpl.m4: New file.
512         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
513         set.
514         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
515         REPLACE_LDEXPL.
516         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
517         REPLACE_LDEXPL.
518         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
519         gl_FUNC_LDEXPL_WORKS.
520         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
521         * modules/mathl (Files): Remove lib/ldexpl.c.
522         (Depends-on): Add ldexpl.
523
524 2007-03-29  Bruno Haible  <bruno@clisp.org>
525
526         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
527
528 2007-03-29  Bruno Haible  <bruno@clisp.org>
529
530         * tests/test-striconveh.c (main): Don't assume that a direct conversion
531         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
532         and possibly also HP-UX.
533         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
534         work on AIX, IRIX, HP-UX, OSF/1.
535         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
536         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
537         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
538         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
539         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
540         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
541
542 2007-03-29  Bruno Haible  <bruno@clisp.org>
543
544         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
545
546 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
547
548         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
549         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
550
551 2007-03-29  Eric Blake  <ebb9@byu.net>
552
553         * lib/acl-internal.h: Remove redundant include.
554         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
555         Cygwin when a file is locked.
556
557 2007-03-29  Bruno Haible  <bruno@clisp.org>
558
559         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
560         file.
561         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
562
563 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
564
565         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
566         try to remove a parent directory if the child couldn't be removed
567         (except for the first rmdir, which could fail because the child
568         doesn't exist).  Problem reported by Jeff Blaine in
569         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
570
571 2007-03-28  Bruno Haible  <bruno@clisp.org>
572
573         * lib/striconveh.c (utf8conv_carefully): New function.
574         (mem_cd_iconveh_internal): Invoke it.
575
576 2007-03-28  Bruno Haible  <bruno@clisp.org>
577
578         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
579         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
580         input.
581         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
582         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
583         unistr/u8-uctomb.
584
585 2007-03-28  Bruno Haible  <bruno@clisp.org>
586
587         * modules/unistr/u8-mbtoucr: New file.
588         * lib/unistr/u8-mbtoucr.c: New file.
589         * modules/unistr/u16-mbtoucr: New file.
590         * lib/unistr/u16-mbtoucr.c: New file.
591         * modules/unistr/u16-mbtoucr: New file.
592         * lib/unistr/u16-mbtoucr.c: New file.
593         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
594
595 2007-03-27  Simon Josefsson  <simon@josefsson.org>
596             Bruno Haible  <bruno@clisp.org>
597
598         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
599         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
600         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
601
602         * m4/stdio_h.m4: Add stubs for vasprintf too.
603
604         * modules/stdio: Support vasprintf in sed command.
605
606         * modules/vasprintf: Depend on stdio for prototypes.  Remove
607         vasprintf.h.  Add stdio module indicator.
608
609         * lib/stdio_.h: Declare asprintf and vasprintf, based on
610         vasprintf.h.
611
612         * lib/vasprintf.h: File removed.
613
614         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
615         * lib/vasprintf.c: Ditto.
616         * lib/xvasprintf.c: Ditto.
617         * tests/test-vasprintf-posix.c: Ditto.
618         * tests/test-vasprintf.c: Ditto.
619
620 2007-03-27  Bruno Haible  <bruno@clisp.org>
621
622         Make vasnprintf multithread-safe.
623         * lib/vasnprintf.c (decimal_point_char): New function.
624         (VASNPRINTF): Use it.
625         Suggested by Simon Josefsson.
626
627 2007-03-27  Eric Blake  <ebb9@byu.net>
628
629         Support sub-second birthtime on cygwin.
630         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
631         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
632         (get_stat_birthtime): Also work with st_birthtim.
633
634 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
635
636         * lib/stat-time.h (USE_BIRTHTIME): Remove.
637         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
638         (get_stat_birthtime_ns): Do not try to use "spare" fields.
639         (get_stat_birthtime_ns): Simplify compile-time tests.
640         (get_stat_birthtime): Change the API to look like
641         get_stat_mtime etc., except return a negative tv_nsec on error.
642         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
643         Don't check for "spare" fields.
644         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
645         or for struct stat.st_birthtime, as these tests aren't used.
646         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
647
648 2007-03-27  Bruno Haible  <bruno@clisp.org>
649
650         * lib/stat-time.h: Include <sys/stat.h>.
651
652 2007-03-27  James Youngman  <jay@gnu.org>
653
654         * lib/stat-time.h (get_stat_birthtime): New function for
655           retrieving st_birthtime as provided by UFS2 (hence *BSD).
656         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
657           and its variants.
658         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
659         * modules/stat-time-test: New file.
660         * tests/test-stat-time.c: New test, devised by Bruno Haible.
661
662 2007-03-26  Bruno Haible  <bruno@clisp.org>
663
664         Better support of signalling NaNs.
665         * lib/atanl.c: Include isnanl.h.
666         (atanl): Perform test for NaN at the beginning of the function and
667         through a call to isnanl.
668         * lib/cosl.c: Include isnanl.h.
669         (cosl): Perform test for NaN at the beginning of the function and
670         through a call to isnanl.
671         * lib/ldexpl.c: Include isnanl.h.
672         (ldexpl): Perform test for NaN through a call to isnanl.
673         * lib/logl.c: Include isnanl.h.
674         (logl): Perform test for NaN at the beginning of the function and
675         through a call to isnanl.
676         * lib/sinl.c: Include isnanl.h.
677         (sinl): Perform test for NaN at the beginning of the function and
678         through a call to isnanl.
679         * lib/sqrtl.c: Include isnanl.h.
680         (sqrtl): Perform test for NaN at the beginning of the function and
681         through a call to isnanl.
682         * lib/tanl.c: Include isnanl.h.
683         (tanl): Perform test for NaN at the beginning of the function and
684         through a call to isnanl.
685         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
686         * modules/mathl (Depends-on): Add isnanl.
687
688 2007-03-26  Eric Blake  <ebb9@byu.net>
689
690         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
691         regression in logic sense of previous patch.
692
693 2007-03-26  Bruno Haible  <bruno@clisp.org>
694
695         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
696         unportable shell command "if ! ...".
697         Reported by Ralf Wildenhues.
698
699 2007-03-25  Bruno Haible  <bruno@clisp.org>
700
701         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
702         <sysexits.h> file, and only add EX_CONFIG.
703         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
704         absolute file name and whether it is sufficient. Substitute also
705         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
706         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
707         ABSOLUTE_SYSEXITS_H into sysexits.h.
708
709 2007-03-25  Bruno Haible  <bruno@clisp.org>
710
711         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
712         hints is NULL.
713
714 2007-03-25  Bruno Haible  <bruno@clisp.org>
715
716         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
717         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
718
719 2007-03-25  Bruno Haible  <bruno@clisp.org>
720
721         * lib/vasnprintf.c: Include langinfo.h.
722         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
723         multithread-safe.
724         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
725         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
726         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
727         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
728         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
729         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
730         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
731         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
732         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
733         Reported by Simon Josefsson.
734
735 2007-03-25  Bruno Haible  <bruno@clisp.org>
736
737         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
738         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
739         * modules/vasnprintf (Depends-on): Add stdint.
740
741 2007-03-25  Bruno Haible  <bruno@clisp.org>
742
743         * modules/fpieee: New file.
744         * m4/fpieee.m4: New file.
745         * modules/isnan-nolibm (Depends-on): Add fpieee.
746         * modules/isnanl-nolibm (Depends-on): Add fpieee.
747         * modules/isnanl (Depends-on): Add fpieee.
748
749 2007-03-25  Bruno Haible  <bruno@clisp.org>
750
751         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
752
753 2007-03-25  Bruno Haible  <bruno@clisp.org>
754
755         Avoid test failures on IRIX 6.5.
756         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
757         (main): Use it.
758         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
759         macros.
760         (main): Use them.
761
762 2007-03-25  Bruno Haible  <bruno@clisp.org>
763
764         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
765         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
766         exists but doesn't work.
767         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
768         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
769         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
770         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
771
772 2007-03-25  Bruno Haible  <bruno@clisp.org>
773
774         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
775         returns inf. Needed on IRIX 6.5.
776
777 2007-03-25  Bruno Haible  <bruno@clisp.org>
778
779         * tests/test-frexpl.c: Include isnanl-nolibm.h.
780         (main): Use isnanl instead of x != x idiom.
781         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
782
783         * tests/test-frexp.c: Include isnan.h.
784         (main): Use isnan instead of x != x idiom.
785         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
786
787 2007-03-25  Bruno Haible  <bruno@clisp.org>
788
789         * tests/test-frexp.c (NaN): New function/macro.
790         (main): Use it instead of 0.0 / 0.0.
791         * tests/test-isnan.c (NaN): New function/macro.
792         (main): Use it instead of 0.0 / 0.0.
793         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
794         (test_function): Use it instead of 0.0 / 0.0.
795         * tests/test-vasprintf-posix.c (NaN): New function/macro.
796         (test_function): Use it instead of 0.0 / 0.0.
797         * tests/test-snprintf-posix.h (NaN): New function/macro.
798         (test_function): Use it instead of 0.0 / 0.0.
799         * tests/test-sprintf-posix.h (NaN): New function/macro.
800         (test_function): Use it instead of 0.0 / 0.0.
801         * tests/test-fprintf-posix.h (NaN): New function/macro.
802         (test_function): Use it instead of 0.0 / 0.0.
803         * tests/test-printf-posix.h (NaN): New function/macro.
804         (test_function): Use it instead of 0.0 / 0.0.
805
806         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
807
808 2007-03-25  Bruno Haible  <bruno@clisp.org>
809
810         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
811
812 2007-03-25  Bruno Haible  <bruno@clisp.org>
813
814         * lib/regexec.c (merge_state_with_log): Make static.
815
816 2007-03-25  Bruno Haible  <bruno@clisp.org>
817
818         * lib/trigl.c (kernel_rem_pio2): Make static.
819
820 2007-03-25  Bruno Haible  <bruno@clisp.org>
821
822         * lib/sincosl.c (sincosl_table): Make static.
823
824 2007-03-25  Bruno Haible  <bruno@clisp.org>
825
826         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
827         if the compiler does not support C99.
828
829 2007-03-25  Bruno Haible  <bruno@clisp.org>
830
831         * modules/time (Makefile.am): Ensure all rule action lines start with a
832         tab.
833
834 2007-03-24  Bruno Haible  <bruno@clisp.org>
835
836         * modules/tsearch-tests: New file.
837         * tests/test-tsearch.sh: New file.
838         * tests/test-tsearch.c: New file, mostly copied from glibc.
839
840         * modules/search-tests: New file.
841         * tests/test-search.c: New file.
842
843         * modules/search: New file.
844         * lib/search_.h: New file, incorporating lib/tsearch.h.
845         * m4/search_h.m4: New file.
846         * lib/tsearch.h: Remove file.
847         * lib/tsearch.c: Include search.h instead of tsearch.h.
848         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
849         HAVE_TSEARCH.
850         * modules/tsearch (Files): Remove lib/tsearch.h.
851         (Depends-on): Add search.
852         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
853         (Include): Change tsearch.h into search.h.
854
855 2007-03-24  Bruno Haible  <bruno@clisp.org>
856
857         * modules/fpucw: New file.
858         * lib/fpucw.h: New file.
859         * lib/frexp.c: Include fpucw.h.
860         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
861         (FUNC): Use them.
862         * lib/printf-frexp.c: Include fpucw.h.
863         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
864         (FUNC): Use them.
865         * lib/vasnprintf.c: Include fpucw.h.
866         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
867         'long double' calculations.
868         * tests/test-frexpl.c: Include fpucw.h.
869         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
870         * tests/test-printf-frexpl.c: Include fpucw.h.
871         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
872         * modules/frexpl (Depends-on): Add fpucw.
873         * modules/printf-frexpl (Depends-on): Likewise.
874         * modules/fprintf-posix (Depends-on): Likewise.
875         * modules/snprintf-posix (Depends-on): Likewise.
876         * modules/sprintf-posix (Depends-on): Likewise.
877         * modules/vasnprintf-posix (Depends-on): Likewise.
878         * modules/vasprintf-posix (Depends-on): Likewise.
879         * modules/vfprintf-posix (Depends-on): Likewise.
880         * modules/vsnprintf-posix (Depends-on): Likewise.
881         * modules/vsprintf-posix (Depends-on): Likewise.
882         * modules/frexpl-tests (Depends-on): Likewise.
883         * modules/printf-frexpl-tests (Depends-on): Likewise.
884
885 2007-03-24  Bruno Haible  <bruno@clisp.org>
886
887         * lib/float+.h: New file.
888         * lib/isnan.c: Include float+.h.
889         (SIZE): New macro.
890         (FUNC): Compare only SIZE bytes of the value.
891         * lib/vasnprintf.c: Include float+.h.
892         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
893         SIZEOF_LDBL or SIZEOF_DBL bytes.
894         * modules/isnan-nolibm (Files): Add lib/float+.h.
895         * modules/isnanl-nolibm (Files): Add lib/float+.h.
896         * modules/isnanl (Files): Add lib/float+.h.
897         * modules/vasnprintf (Files): Add lib/float+.h.
898
899 2007-03-24  Bruno Haible  <bruno@clisp.org>
900
901         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
902         include isnanl-nolibm.h.
903
904 2007-03-24  Bruno Haible  <bruno@clisp.org>
905
906         * tests/test-read-file.c (main): Don't produce spurious output for
907         expected situations. Make the test fail if it encountered unexpected
908         results.
909
910 2007-03-24  Bruno Haible  <bruno@clisp.org>
911
912         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
913         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
914
915 2007-03-24  Bruno Haible  <bruno@clisp.org>
916
917         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
918
919 2007-03-24  Bruno Haible  <bruno@clisp.org>
920
921         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
922         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
923
924         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
925         * modules/utf8-ucs4: Turn into a symbolic link to module
926         unistr/u8-mbtouc.
927
928         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
929         utf8-ucs4-unsafe.
930         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
931         unistr/u8-mbtouc-unsafe.
932
933         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
934         * modules/utf16-ucs4: Turn into a symbolic link to module
935         unistr/u16-mbtouc.
936
937         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
938         utf16-ucs4-unsafe.
939         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
940         unistr/u16-mbtouc-unsafe.
941
942         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
943         * modules/ucs4-utf8: Turn into a symbolic link to module
944         unistr/u8-ubtomb.
945
946         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
947         * modules/ucs4-utf16: Turn into a symbolic link to module
948         unistr/u16-ubtomb.
949
950 2007-03-24  Bruno Haible  <bruno@clisp.org>
951
952         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
953         Enable the function only if HAVE_INLINE.
954         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
955         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
956         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
957         Enable the function only if HAVE_INLINE.
958         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
959         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
960         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
961         Enable the function only if HAVE_INLINE.
962         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
963         Enable the function only if HAVE_INLINE.
964         * modules/utf8-ucs4: Update.
965         * modules/utf8-ucs4-unsafe: Update.
966         * modules/utf16-ucs4: Update.
967         * modules/utf16-ucs4-unsafe: Update.
968         * modules/ucs4-utf8: Update.
969         * modules/ucs4-utf16: Update.
970
971 2007-03-24  Bruno Haible  <bruno@clisp.org>
972
973         * lib/utf8-ucs4.h: Remove file.
974         * lib/utf8-ucs4-unsafe.h: Remove file.
975         * lib/utf16-ucs4.h: Remove file.
976         * lib/utf16-ucs4-unsafe.h: Remove file.
977         * lib/ucs4-utf8.h: Remove file.
978         * lib/ucs4-utf16.h: Remove file.
979         * lib/unistr.h: Include their previous contents.
980         * m4/utf-ucs4.m4: Remove file.
981         * m4/ucs4-utf.m4: Remove file.
982         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
983         (Depends-on): Add unistr/base.
984         (configure.ac): Remove gl_UTF_UCS4.
985         (Makefile.am): Update.
986         (Include): Change to unistr.h.
987         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
988         (Depends-on): Add unistr/base.
989         (configure.ac): Remove gl_UTF_UCS4.
990         (Makefile.am): Update.
991         (Include): Change to unistr.h.
992         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
993         (Depends-on): Add unistr/base.
994         (configure.ac): Remove gl_UTF_UCS4.
995         (Makefile.am): Update.
996         (Include): Change to unistr.h.
997         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
998         (Depends-on): Add unistr/base.
999         (configure.ac): Remove gl_UTF_UCS4.
1000         (Makefile.am): Update.
1001         (Include): Change to unistr.h.
1002         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
1003         (Depends-on): Add unistr/base.
1004         (configure.ac): Remove gl_UCS4_UTF.
1005         (Makefile.am): Update.
1006         (Include): Change to unistr.h.
1007         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
1008         (Depends-on): Add unistr/base.
1009         (configure.ac): Remove gl_UCS4_UTF.
1010         (Makefile.am): Update.
1011         (Include): Change to unistr.h.
1012         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
1013         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
1014         utf8-ucs4-unsafe.h.
1015         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
1016         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
1017         utf16-ucs4-unsafe.h.
1018         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
1019         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
1020         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
1021         * lib/unistr/u8-strchr.c: Likewise.
1022         * lib/unistr/u8-strrchr.c: Likewise.
1023         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
1024         * lib/unistr/u16-strchr.c: Likewise.
1025         * lib/unistr/u16-strrchr.c: Likewise.
1026         * lib/striconveh.c: Update.
1027         * lib/linebreak.c: Update.
1028
1029 2007-03-24  Bruno Haible  <bruno@clisp.org>
1030
1031         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
1032         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
1033
1034 2007-03-22  Bruno Haible  <bruno@clisp.org>
1035
1036         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
1037
1038 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
1039
1040         * MODULES.html.sh (File system functions): New module write-any-file.
1041         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
1042         * m4/write-any-file.m4: New files.
1043
1044 2007-03-23  Eric Blake  <ebb9@byu.net>
1045
1046         * gnulib-tool: Rearrange space-tab sequences, since some editors
1047         like to eat them.
1048
1049 2007-03-23  Eric Blake  <ebb9@byu.net>
1050
1051         * lib/version-etc.c (version_etc_va): Update license wording to
1052         be more concise.  Recommended by Richard Stallman.
1053
1054 2007-03-22  Bruno Haible  <bruno@clisp.org>
1055
1056         * lib/poll.c (MSG_PEEK): New fallback definition.
1057
1058 2007-03-22  Bruno Haible  <bruno@clisp.org>
1059
1060         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
1061         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
1062         (main): Update.
1063         Fixes a compilation error on BeOS.
1064
1065 2007-03-22  Bruno Haible  <bruno@clisp.org>
1066
1067         * modules/frexpl-tests: New file.
1068         * tests/test-frexpl.c: New file.
1069
1070         * modules/frexpl: New file.
1071         * m4/frexpl.m4: New file.
1072         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
1073         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
1074         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
1075         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
1076         (Depends-on): Add frexpl. Remove isnanl-nolibm.
1077         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
1078
1079 2007-03-22  Bruno Haible  <bruno@clisp.org>
1080
1081         * lib/frexpl.c: Share code with lib/frexp.c.
1082         * modules/mathl (Files): Add lib/frexp.c.
1083         (Depends-on): Add isnanl-nolibm.
1084
1085 2007-03-22  Bruno Haible  <bruno@clisp.org>
1086
1087         * modules/printf-frexp (Files): Add m4/frexp.m4.
1088         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
1089         only if the found frexp function actually works.
1090
1091 2007-03-22  Bruno Haible  <bruno@clisp.org>
1092
1093         * lib/frexp.c: Remove older implementation that uses divisions.
1094
1095 2007-03-21  Bruno Haible  <bruno@clisp.org>
1096
1097         * modules/frexp-tests: New file.
1098         * tests/test-frexp.c: New file.
1099
1100         * modules/frexp: New file.
1101         * lib/frexp.c: New file.
1102         * m4/frexp.m4: New file.
1103         * lib/math_.h (frexp): New declaration.
1104         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
1105         REPLACE_FREXP.
1106         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
1107
1108 2007-03-21  Bruno Haible  <bruno@clisp.org>
1109
1110         * modules/isnanl-tests: New file.
1111         * tests/test-isnanl.c: New file.
1112
1113         * modules/isnanl: New file.
1114         * lib/isnanl.h: New file.
1115         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
1116         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
1117         gl_FUNC_ISNANL_WORKS.
1118         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
1119         New macros.
1120
1121 2007-03-21  Bruno Haible  <bruno@clisp.org>
1122
1123         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
1124         lib/isnanl.h.
1125         (Include): Update.
1126         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
1127         * lib/vasnprintf.c: Update.
1128         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
1129         tests/test-isnanl.h, remove tests/test-isnanl.c.
1130         (Makefile.am): Update.
1131         * tests/test-isnanl-nolibm.c: New file.
1132         * tests/test-isnanl.h: New file.
1133         * tests/test-isnanl.c: Remove file.
1134
1135 2007-03-21  Jim Meyering  <jim@meyering.net>
1136
1137         When trying to open ".", treat ESTALE like EACCES.
1138         * lib/savewd.c (savewd_save): Resort to forking not just upon
1139         failure with EACCES, but also when errno is ESTALE.
1140
1141 2007-03-20  Bruno Haible  <bruno@clisp.org>
1142
1143         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
1144         Needed on AIX 5.1. Reported by Matthew Woehlke.
1145
1146 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1147
1148         Suggestions by Bruno Haible:
1149         * lib/acl-internal.h: Include "gettext.h" rather than rolling
1150         our own.
1151         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
1152         * modules/acl (Depends-on): Add gettext.
1153
1154 2007-03-19  Bruno Haible  <bruno@clisp.org>
1155
1156         * modules/iconvme: Remove file.
1157         * lib/iconvme.h: Remove file.
1158         * lib/iconvme.c: Remove file.
1159         * m4/iconvme.m4: Remove file.
1160
1161 2007-03-19  Bruno Haible  <bruno@clisp.org>
1162
1163         * doc/relocatable-maint.texi: Break long shell script line.
1164         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
1165
1166 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1167
1168         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
1169         handle file_has_acl.
1170         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
1171         * lib/acl.c: Move header inclusions and related macro defns into
1172         lib/acl-internal.h.
1173         (S_ISLNK): Remove defn, since that's now done for us.
1174         (file_has_acl): Move to lib/file-has-acl.c.
1175         Call acl_trivial if available.  This is the crucial part of the fix.
1176         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
1177         shared within the library.  Rewrite a bit, partly to make it compatible
1178         with the GNU coding style.
1179         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
1180         Remove unnecessary double-quotes.
1181         Don't test for acl_to_text; the build will catch that.
1182         Replace acl_entries if it doesn't exist and it is needed.
1183         Check for -lsec and acl_trivial (as used on Solaris 10).
1184         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
1185         lib/file-has-acl.c.
1186         (Depends-on): Add sys_stat, for S_ISLNK.
1187
1188 2007-03-19  Ben Pfaff  <blp@gnu.org>
1189
1190         * doc/gnulib.texi: Fix typos.
1191         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
1192
1193 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1194
1195         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
1196         If size is zero here, buf must be zero.
1197
1198 2007-03-19  Simon Josefsson  <simon@josefsson.org>
1199
1200         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
1201         <bruno@clisp.org>.
1202
1203 2007-03-18  Bruno Haible  <bruno@clisp.org>
1204
1205         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
1206         Suggested by Eric Blake.
1207
1208 2007-03-18  Ben Pfaff  <blp@gnu.org>
1209
1210         * doc/relocatable.texi: Recommend using as prefix a directory
1211         that does not exist and will never be created.  Based on
1212         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
1213         and others.
1214
1215 2007-03-17  Bruno Haible  <bruno@clisp.org>
1216
1217         * lib/fchownat.c: Include lchown.h.
1218
1219 2007-03-17  Bruno Haible  <bruno@clisp.org>
1220
1221         Fix endless loop when the given allocated size was > INT_MAX.
1222         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
1223         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
1224         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
1225         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
1226         * lib/sprintf.c (sprintf): Likewise.
1227
1228 2007-03-17  Bruno Haible  <bruno@clisp.org>
1229
1230         * tests/test-argp-2.sh (func_compare): Output a context diff.
1231
1232 2007-03-17  Bruno Haible  <bruno@clisp.org>
1233
1234         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
1235         locale's decimal-point character.
1236
1237 2007-03-17  Bruno Haible  <bruno@clisp.org>
1238
1239         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
1240         before comparing it. Needed because on some platforms (e.g. x86) a
1241         'long double' occupies less bytes than sizeof (long double).
1242
1243 2007-03-17  Bruno Haible  <bruno@clisp.org>
1244
1245         * tests/test-crc.c (main): Make printf statements 64-bit clean.
1246         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
1247         * tests/test-getaddrinfo.c (simple): Likewise.
1248         * tests/test-read-file.c (main): Likewise.
1249
1250 2007-03-17  Bruno Haible  <bruno@clisp.org>
1251
1252         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
1253
1254 2007-03-17  Bruno Haible  <bruno@clisp.org>
1255
1256         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
1257         unused variable.
1258
1259 2007-03-17  Bruno Haible  <bruno@clisp.org>
1260
1261         * tests/test-c-strcasecmp.c: Include c-strcase.h.
1262         * tests/test-c-strncasecmp.c: Likewise.
1263
1264 2007-03-17  Bruno Haible  <bruno@clisp.org>
1265
1266         * modules/stdlib (Depends-on): Add unistd.
1267         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
1268         Needed for MacOS X 10.3.
1269
1270 2007-03-17  Bruno Haible  <bruno@clisp.org>
1271
1272         * lib/unistr/u-strdup.h: Include <stdlib.h>.
1273
1274 2007-03-17  Bruno Haible  <bruno@clisp.org>
1275
1276         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
1277
1278 2007-03-17  Bruno Haible  <bruno@clisp.org>
1279
1280         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
1281         to reflect files copied from gnulib (with or without modifications).
1282         Suggested by Jim Meyering.
1283
1284 2007-03-17  Eric Blake  <ebb9@byu.net>
1285
1286         * NEWS: Document stdlib change from 2007-02-18.
1287
1288 2007-03-17  Jim Meyering  <jim@meyering.net>
1289
1290         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
1291         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
1292         someone uses a name containing shell meta-characters.
1293         Reported by Alfred M. Szmidt.
1294
1295         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
1296
1297 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
1298
1299         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
1300         and copy gettext configuration files only if configure.ac contains
1301         a use of AM_GNU_GETTEXT_VERSION.
1302
1303 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
1304
1305         * build-aux/bootstrap (gnulib_name): New variable.
1306         (gnulib_tool_options): Use it.
1307
1308 2007-03-13  Simon Josefsson  <simon@josefsson.org>
1309
1310         * tests/test-des.c: Use new namespace.
1311
1312 2007-03-15  Bruno Haible  <bruno@clisp.org>
1313
1314         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
1315         Reported by James Youngman <jay@gnu.org>.
1316
1317 2007-03-15  Bruno Haible  <bruno@clisp.org>
1318
1319         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
1320         declared prototype. Needed with cc on OSF/1 5.1.
1321
1322 2007-03-15  Bruno Haible  <bruno@clisp.org>
1323
1324         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
1325         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
1326         (struct gl_list_implementation): Add dispose_fn argument to the
1327         'create_empty', 'create' methods.
1328         (struct gl_list_impl_base): Add field 'dispose_fn'.
1329         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
1330         argument.
1331         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
1332         dispose_fn argument.
1333         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
1334         dispose_fn on the dropped values.
1335         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
1336         dispose_fn argument.
1337         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
1338         dropped values.
1339         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
1340         (gl_tree_remove_node): Call dispose_fn on the dropped value.
1341         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
1342         (gl_tree_remove_node): Call dispose_fn on the dropped value.
1343         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
1344         argument.
1345         (gl_tree_list_free): Call dispose_fn on the dropped values.
1346         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
1347         the dropped values.
1348         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1349         Add dispose_fn argument.
1350         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
1351         Call dispose_fn on the dropped values.
1352         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
1353         Add dispose_fn argument.
1354         (gl_sublist_create): Initialize the 'dispose_fn' field.
1355         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
1356         * tests/test-array_list.c (main): Update.
1357         * tests/test-carray_list.c (main): Update.
1358         * tests/test-avltree_list.c (main): Update.
1359         * tests/test-rbtree_list.c (main): Update.
1360         * tests/test-avltreehash_list.c (main): Update.
1361         * tests/test-rbtreehash_list.c (main): Update.
1362         * tests/test-linked_list.c (main): Update.
1363         * tests/test-linkedhash_list.c (main): Update.
1364         * tests/test-array_oset.c (main): Update.
1365
1366 2007-03-15  Bruno Haible  <bruno@clisp.org>
1367
1368         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
1369         (gl_oset_create_empty): Add dispose_fn argument.
1370         (struct gl_oset_implementation): Add dispose_fn argument to
1371         'create_empty' method.
1372         (struct gl_oset_impl_base): Add dispose_fn field.
1373         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
1374         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
1375         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
1376         values.
1377         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
1378         (gl_tree_oset_free): Call dispose_fn on the dropped values.
1379         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
1380         dropped value.
1381         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
1382         dropped value.
1383         * tests/test-array_oset.c (main): Update.
1384         * tests/test-avltree_oset.c (main): Update.
1385         * tests/test-rbtree_oset.c (main): Update.
1386         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
1387
1388 2007-03-13  Bruno Haible  <bruno@clisp.org>
1389
1390         * tests/test-stdbool.c (i): Update after last patch.
1391
1392 2007-03-12  Bruno Haible  <bruno@clisp.org>
1393
1394         * lib/quotearg.c: Include <wctype.h> early, before the definition of
1395         the iswprint macro. Needed on Solaris 2.5.1.
1396
1397 2007-03-12  Bruno Haible  <bruno@clisp.org>
1398
1399         * tests/test-printf-frexp.c (main): Declare x as volatile.
1400
1401 2007-03-12  Simon Josefsson  <simon@josefsson.org>
1402
1403         * doc/gnulib.texi (Build robot for gnulib): New section.
1404
1405 2007-03-12  Jim Meyering  <jim@meyering.net>
1406
1407         * build-aux/bootstrap: New file.
1408         * build-aux/bootstrap.conf: New file, from coreutils.
1409
1410 2007-03-11  Bruno Haible  <bruno@clisp.org>
1411
1412         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
1413
1414 2007-03-12  Simon Josefsson  <simon@josefsson.org>
1415
1416         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
1417         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
1418         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
1419
1420 2007-03-11  Bruno Haible  <bruno@clisp.org>
1421
1422         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
1423         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
1424
1425 2007-03-11  Bruno Haible  <bruno@clisp.org>
1426
1427         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
1428         formula. Needed for SunPRO C 5.0.
1429
1430 2007-03-11  Bruno Haible  <bruno@clisp.org>
1431
1432         * modules/long-options (Depends-on): Add getopt.
1433
1434 2007-03-11  Bruno Haible  <bruno@clisp.org>
1435
1436         * modules/modechange (Depends-on): Add stdbool.
1437
1438 2007-03-11  Bruno Haible  <bruno@clisp.org>
1439
1440         * modules/i-ring (Depends-on): Add stdbool.
1441
1442 2007-03-11  Bruno Haible  <bruno@clisp.org>
1443
1444         * modules/gc-des (Depends-on): Add stdbool.
1445
1446 2007-03-11  Bruno Haible  <bruno@clisp.org>
1447
1448         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
1449
1450 2007-03-11  Bruno Haible  <bruno@clisp.org>
1451
1452         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
1453
1454 2007-03-11  Bruno Haible  <bruno@clisp.org>
1455
1456         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
1457
1458 2007-03-11  Bruno Haible  <bruno@clisp.org>
1459
1460         * lib/vasnprintf.c (sprintf): Undefine.
1461
1462 2007-03-11  Bruno Haible  <bruno@clisp.org>
1463
1464         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
1465         initializers in SunPRO C and Compaq C compilers.
1466
1467 2007-03-11  Bruno Haible  <bruno@clisp.org>
1468
1469         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
1470         decrementing code ANSI C compliant.
1471
1472 2007-03-11  Bruno Haible  <bruno@clisp.org>
1473
1474         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
1475         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
1476
1477 2007-03-11  Bruno Haible  <bruno@clisp.org>
1478
1479         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
1480         <stdbool.h> substitute doesn't pass.
1481
1482 2007-03-11  Bruno Haible  <bruno@clisp.org>
1483
1484         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
1485
1486 2007-03-11  Bruno Haible  <bruno@clisp.org>
1487
1488         * gnulib-tool (func_create_megatestdir): Create also an autobuild
1489         script, for submission to autobuild.josefsson.org.
1490
1491 2007-03-10  Bruno Haible  <bruno@clisp.org>
1492
1493         * modules/canonicalize-lgpl-tests: New file.
1494         * tests/test-canonicalize-lgpl.sh: New file.
1495         * tests/test-canonicalize-lgpl.c: New file.
1496
1497         * modules/c-strcase-tests: New file.
1498         * tests/test-c-strcase.sh: New file.
1499         * tests/test-c-strcasecmp.c: New file.
1500         * tests/test-c-strncasecmp.c: New file.
1501
1502         * modules/atexit-tests: New file.
1503         * tests/test-atexit.sh: New file.
1504         * tests/test-atexit.c: New file.
1505
1506 2007-03-10  Bruno Haible  <bruno@clisp.org>
1507
1508         * tests/test-binary-io.sh: Use temporary filenames that are not so
1509         likely to clash with those of other tests (in a parallel make).
1510         * tests/test-binary-io.c: Likewise.
1511
1512 2007-03-10  Bruno Haible  <bruno@clisp.org>
1513
1514         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
1515         fallback; use #error instead.
1516         Suggested by Simon Josefsson.
1517
1518 2007-03-10  Bruno Haible  <bruno@clisp.org>
1519
1520         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
1521         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
1522         first and the last.
1523
1524 2007-03-10  Bruno Haible  <bruno@clisp.org>
1525
1526         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
1527
1528 2007-03-10  Bruno Haible  <bruno@clisp.org>
1529
1530         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
1531         "make distcheck".
1532         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
1533         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
1534         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
1535
1536 2007-03-10  Bruno Haible  <bruno@clisp.org>
1537
1538         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
1539         variable.
1540         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
1541         variable.
1542
1543 2007-03-09  Eric Blake  <ebb9@byu.net>
1544         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
1545
1546         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
1547         types are not being provided by gnulib.
1548         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
1549         types are supported.
1550
1551 2007-03-10  Bruno Haible  <bruno@clisp.org>
1552
1553         * lib/stdio_.h (__attribute__): New macro.
1554         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
1555         vsprintf): Specify __attribute__ __format__ for GCC.
1556         Suggested by Eric Blake.
1557
1558 2007-03-09  Bruno Haible  <bruno@clisp.org>
1559
1560         * modules/printf-posix-tests: New file.
1561         * tests/test-printf-posix.sh: New file.
1562         * tests/test-printf-posix.c: New file.
1563
1564         * modules/printf-posix: New file.
1565         * lib/printf.c: New file.
1566         * m4/printf-posix-rpl.m4: New file.
1567         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
1568         REPLACE_PRINTF.
1569         * lib/stdio_.h (printf): New declaration.
1570         (format, __format__, ____printf____, ____scanf____, ____strftime____,
1571         ____strfmon____): New macros.
1572         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
1573         REPLACE_PRINTF.
1574
1575 2007-03-09  Bruno Haible  <bruno@clisp.org>
1576
1577         * tests/test-vasnprintf-posix2.sh: New file.
1578         * tests/test-vasnprintf-posix2.c: New file.
1579         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
1580         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
1581         (Makefile.am): Activate test-vasnprintf-posix2.sh.
1582
1583         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
1584         a locale dependent decimal point, rather than always '.'.
1585
1586 2007-03-09  Eric Blake  <ebb9@byu.net>
1587
1588         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
1589         spite of platforms like Tandem/NSK that define it to -1.
1590
1591 2007-03-08  Bruno Haible  <bruno@clisp.org>
1592
1593         * modules/vprintf-posix-tests: New file.
1594         * tests/test-vprintf-posix.sh: New file.
1595         * tests/test-vprintf-posix.c: New file.
1596         * tests/test-printf-posix.h: New file.
1597
1598         * modules/vprintf-posix: New file.
1599         * lib/vprintf.c: New file.
1600         * m4/vprintf-posix.m4: New file.
1601         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
1602         REPLACE_VPRINTF.
1603         * lib/stdio_.h (vprintf): New declaration.
1604         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
1605         REPLACE_VPRINTF.
1606
1607 2007-03-08  Bruno Haible  <bruno@clisp.org>
1608
1609         * modules/fprintf-posix-tests: New file.
1610         * tests/test-fprintf-posix.sh: New file.
1611         * tests/test-fprintf-posix.c: New file.
1612
1613         * modules/fprintf-posix: New file.
1614         * lib/fprintf.c: New file.
1615         * m4/fprintf-posix.m4: New file.
1616         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
1617         REPLACE_FPRINTF.
1618         * lib/stdio_.h (fprintf): New declaration.
1619         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
1620         REPLACE_FPRINTF.
1621
1622 2007-03-08  Bruno Haible  <bruno@clisp.org>
1623
1624         * modules/vfprintf-posix-tests: New file.
1625         * tests/test-vfprintf-posix.sh: New file.
1626         * tests/test-vfprintf-posix.c: New file.
1627         * tests/test-fprintf-posix.h: New file.
1628         * tests/test-fprintf-posix.out: New file.
1629
1630         * modules/vfprintf-posix: New file.
1631         * lib/vfprintf.c: New file.
1632         * m4/vfprintf-posix.m4: New file.
1633         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
1634         REPLACE_VFPRINTF.
1635         * lib/stdio_.h (vfprintf): New declaration.
1636         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
1637         REPLACE_VFPRINTF.
1638
1639 2007-03-08  Bruno Haible  <bruno@clisp.org>
1640
1641         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
1642
1643 2007-03-08  Bruno Haible  <bruno@clisp.org>
1644
1645         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
1646         instead of 'expr' invocations.
1647         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1648         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1649         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1650         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1651         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1652         Suggested by Paul Eggert.
1653
1654 2007-03-08  Bruno Haible  <bruno@clisp.org>
1655
1656         * modules/fseterr-tests: New file.
1657         * tests/test-fseterr.c: New file.
1658
1659         * modules/fseterr: New file.
1660         * lib/fseterr.h: New file.
1661         * lib/fseterr.c: New file.
1662
1663 2007-03-08  Bruno Haible  <bruno@clisp.org>
1664
1665         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
1666         * lib/getopt_.h: Likewise.
1667         * lib/mbswidth.h: Likewise.
1668         * lib/setenv.h: Likewise.
1669         * lib/vasnprintf.h: Likewise.
1670         * lib/vasprintf.h: Likewise.
1671         * lib/verror.h: Likewise.
1672         * lib/xsetenv.h: Likewise.
1673         * lib/xvasprintf.h: Likewise.
1674
1675 2007-03-08  Jim Meyering  <jim@meyering.net>
1676
1677         * users.txt: Add parted.
1678
1679         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
1680
1681 2007-03-07  Bruno Haible  <bruno@clisp.org>
1682
1683         * m4/printf.m4: Make the shell script snippets copy&pastable.
1684
1685 2007-03-02  Bruno Haible  <bruno@clisp.org>
1686
1687         * lib/netinet_in_.h: New file.
1688         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
1689         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
1690         * modules/netinet_in (Files): Add lib/netinet_in_.h.
1691         (Depends-on): Add absolute-header.
1692         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
1693         into netinet/in.h.
1694
1695 2007-03-03  Bruno Haible  <bruno@clisp.org>
1696
1697         * lib/sys_select_.h: New file.
1698         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
1699         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
1700         * modules/sys_select (Files): Add lib/sys_select_.h.
1701         (Depends-on): Add absolute-header.
1702         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
1703         into sys/select.h.
1704
1705 2007-03-02  Bruno Haible  <bruno@clisp.org>
1706
1707         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
1708         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
1709         values.
1710         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
1711         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
1712         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
1713         * modules/sys_socket (Depends-on): Add absolute-header.
1714         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
1715         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
1716         (Include): Remove requirement of inclusion of <sys/types.h>.
1717
1718 2007-03-02  Bruno Haible  <bruno@clisp.org>
1719
1720         * lib/byteswap_.h (bswap_32): Fix formula.
1721
1722 2007-03-06  Bruno Haible  <bruno@clisp.org>
1723
1724         * modules/sprintf-posix-tests: New file.
1725         * tests/test-sprintf-posix.c: New file.
1726
1727         * modules/sprintf-posix: New file.
1728         * lib/sprintf.c: New file.
1729         * m4/sprintf-posix.m4: New file.
1730         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
1731         REPLACE_SPRINTF.
1732         * lib/stdio_.h (sprintf): New declaration.
1733         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
1734         REPLACE_SPRINTF.
1735
1736 2007-03-06  Bruno Haible  <bruno@clisp.org>
1737
1738         * modules/vsprintf-posix-tests: New file.
1739         * tests/test-vsprintf-posix.c: New file.
1740         * tests/test-sprintf-posix.h: New file.
1741
1742         * modules/vsprintf-posix: New file.
1743         * lib/vsprintf.c: New file.
1744         * m4/vsprintf-posix.m4: New file.
1745         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
1746         REPLACE_VSPRINTF.
1747         * lib/stdio_.h (vsprintf): New declaration.
1748         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
1749         REPLACE_VSPRINTF.
1750
1751 2007-03-06  Bruno Haible  <bruno@clisp.org>
1752
1753         * modules/vsnprintf (Depend-on): Remove minmax.
1754
1755 2007-03-06  Bruno Haible  <bruno@clisp.org>
1756
1757         * modules/snprintf-posix-tests: New file.
1758         * tests/test-snprintf-posix.c: New file.
1759
1760         * modules/snprintf-posix: New file.
1761         * m4/snprintf-posix.m4: New file.
1762         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
1763         gl_FUNC_SNPRINTF.
1764         (gl_FUNC_SNPRINTF): Invoke it.
1765         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
1766         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
1767         is set.
1768         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
1769
1770 2007-03-06  Bruno Haible  <bruno@clisp.org>
1771
1772         * modules/vsnprintf-posix-tests: New file.
1773         * tests/test-vsnprintf-posix.c: New file.
1774         * tests/test-snprintf-posix.h: New file.
1775
1776         * modules/vsnprintf-posix: New file.
1777         * m4/vsnprintf-posix.m4: New file.
1778         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
1779         gl_FUNC_VSNPRINTF.
1780         (gl_FUNC_VSNPRINTF): Invoke it.
1781         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
1782         * lib/stdio_.h (vsnprintf): Define as a replacement if
1783         REPLACE_VSNPRINTF is set.
1784         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
1785
1786 2007-03-06  Bruno Haible  <bruno@clisp.org>
1787
1788         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
1789         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
1790
1791 2007-03-06  Bruno Haible  <bruno@clisp.org>
1792
1793         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
1794         (asinl): Declare also if HAVE_DECL_ASINL is set.
1795         (atanl): Declare also if HAVE_DECL_ATANL is set.
1796         (ceill): Declare also if HAVE_DECL_CEILL is set.
1797         (cosl): Declare also if HAVE_DECL_COSL is set.
1798         (expl): Declare also if HAVE_DECL_EXPL is set.
1799         (floorl): Declare also if HAVE_DECL_FLOORL is set.
1800         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
1801         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
1802         (logl): Declare also if HAVE_DECL_LOGL is set.
1803         (sinl): Declare also if HAVE_DECL_SINL is set.
1804         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
1805         (tanl): Declare also if HAVE_DECL_TANL is set.
1806         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
1807         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
1808         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
1809         declaration of frexpl, ldexpl.
1810         * modules/printf-frexpl (Depends-on): Add math.
1811         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
1812
1813 2007-03-05  Bruno Haible  <bruno@clisp.org>
1814
1815         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
1816         frexpl and ldexpl are declared.
1817         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
1818
1819 2007-03-05  Bruno Haible  <bruno@clisp.org>
1820
1821         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
1822         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
1823
1824 2007-03-05  Bruno Haible  <bruno@clisp.org>
1825
1826         * lib/stdio_.h: Include <stddef.h>.
1827
1828 2007-03-05  Bruno Haible  <bruno@clisp.org>
1829
1830         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
1831
1832 2007-03-05  Bruno Haible  <bruno@clisp.org>
1833
1834         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
1835         NetBSD 4, from Ralf Wildenhues.
1836
1837 2007-03-04  Bruno Haible  <bruno@clisp.org>
1838
1839         * lib/vasprintf.h: Update #if logic for the case when the functions
1840         exist but are overridden.
1841
1842 2007-03-04  Bruno Haible  <bruno@clisp.org>
1843
1844         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
1845         implementations: glibc-2.4 and MacOS X 10.3.
1846         * tests/test-vasnprintf-posix.c (test_function): Test also the case
1847         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
1848         * tests/test-vasprintf-posix.c (test_function): Likewise.
1849
1850 2007-03-04  Bruno Haible  <bruno@clisp.org>
1851
1852         * modules/vasprintf-posix-tests: New file.
1853         * tests/test-vasprintf-posix.c: New file.
1854
1855         * modules/vasprintf-posix: New file.
1856         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
1857         defined.
1858         * m4/vasprintf-posix.m4: New file.
1859         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
1860         gl_FUNC_VASPRINTF.
1861         (gl_FUNC_VASPRINTF): Invoke it.
1862         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
1863         here.
1864         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
1865
1866 2007-03-04  Bruno Haible  <bruno@clisp.org>
1867
1868         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
1869         REPLACE_GETTIMEOFDAY.
1870         * modules/sys_time (Makefile.am): Likewise.
1871         * m4/sys_time_h.m4: Likewise.
1872         * m4/gettimeofday.m4: Likewise.
1873
1874 2007-03-04  Bruno Haible  <bruno@clisp.org>
1875
1876         * modules/vasnprintf-posix-tests: New file.
1877         * tests/test-vasnprintf-posix.c: New file.
1878
1879         * modules/vasnprintf-posix: New file.
1880         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
1881         printf-frexpl.h.
1882         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
1883         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
1884         REPLACE_VASNPRINTF is defined.
1885         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
1886         gl_FUNC_VASNPRINTF.
1887         (gl_FUNC_VASNPRINTF): Invoke it.
1888         * m4/vasnprintf-posix.m4: New file.
1889         * m4/printf.m4: New file.
1890
1891 2007-03-04  Bruno Haible  <bruno@clisp.org>
1892
1893         Compile progreloc.c only if --enable-relocatable is specified.
1894         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
1895         if --enable-relocatable was specified.
1896         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
1897         lib_SOURCES.
1898
1899 2007-03-04  Jim Meyering  <jim@meyering.net>
1900
1901         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
1902         Use it consistently, rather than enumerating errno constants.
1903
1904 2007-03-04  Bruno Haible  <bruno@clisp.org>
1905
1906         * modules/xvasprintf-tests: New file.
1907         * tests/test-xvasprintf.c: New file.
1908
1909         * modules/vasprintf-tests: New file.
1910         * tests/test-vasprintf.c: New file.
1911
1912         * modules/vasnprintf-tests: New file.
1913         * tests/test-vasnprintf.c: New file.
1914
1915         * modules/vsnprintf-tests: New file.
1916         * tests/test-vsnprintf.c: New file.
1917
1918         * modules/snprintf-tests: New file.
1919         * tests/test-snprintf.c: New file.
1920
1921 2007-03-04  Bruno Haible  <bruno@clisp.org>
1922
1923         Compile relocatable.c only if --enable-relocatable is specified.
1924         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
1925         gl_RELOCATABLE_LIBRARY.
1926         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
1927         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
1928         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
1929         gl_RELOCATABLE_LIBRARY.
1930         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
1931         (Makefile.am): Remove lib_SOURCES.
1932         * modules/relocatable-lib-lgpl (configure.ac): Invoke
1933         gl_RELOCATABLE_LIBRARY.
1934         (Makefile.am): Remove lib_SOURCES.
1935         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
1936         always.
1937         * modules/relocatable-prog-wrapper (configure.ac): Invoke
1938         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
1939
1940 2007-03-04  Bruno Haible  <bruno@clisp.org>
1941
1942         * modules/argmatch-tests: New file.
1943         * tests/test-argmatch.c: New file.
1944
1945         * tests/test-allocsa.c (main): Halve the number of loop runs.
1946
1947         * modules/alloca-opt-tests: New file.
1948         * tests/test-alloca-opt.c: New file.
1949
1950 2007-03-04  Jim Meyering  <jim@meyering.net>
1951
1952         Work around difference between Linux ACLs and Solaris 10 ZFS.
1953         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
1954         for EINVAL.
1955
1956 2007-03-03  Bruno Haible  <bruno@clisp.org>
1957
1958         * modules/relocatable-prog (Depends-on): Add back progreloc's
1959         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
1960
1961 2007-03-03  Bruno Haible  <bruno@clisp.org>
1962
1963         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
1964         * modules/relocatable-lib: New file.
1965
1966 2007-03-03  Bruno Haible  <bruno@clisp.org>
1967
1968         * modules/relocatable-prog: Renamed from modules/relocatable.
1969         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
1970
1971 2007-03-03  Bruno Haible  <bruno@clisp.org>
1972
1973         * modules/relocatable-script (Files): Add doc/relocatable.texi,
1974         m4/relocatable-lib.m4.
1975         (Depends-on): Remove 'relocatable'.
1976         (configure.ac): Add gl_RELOCATABLE_NOP.
1977
1978 2007-03-03  Bruno Haible  <bruno@clisp.org>
1979
1980         * modules/relocatable-prog-wrapper: New file.
1981         * modules/relocatable (Depends-on): Add it. Remove all other
1982         dependencies except progname.
1983         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
1984
1985         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
1986         (gl_FUNC_STRERROR): Nop.
1987         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
1988
1989         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
1990         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
1991
1992         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
1993         (gl_FUNC_READLINK): Update.
1994
1995         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
1996
1997 2007-03-03  Bruno Haible  <bruno@clisp.org>
1998
1999         * lib/xreadlink.c: Include <unistd.h> unconditionally.
2000         * modules/xreadlink (Depends-on): Add unistd.
2001         * modules/xreadlink-with-size (Depends-on): Likewise.
2002
2003 2007-03-03  Bruno Haible  <bruno@clisp.org>
2004
2005         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
2006         extracted from gt_FUNC_SETENV.
2007         (gt_FUNC_SETENV): Remove macro.
2008         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
2009         remove gt_FUNC_SETENV.
2010
2011 2007-03-03  Bruno Haible  <bruno@clisp.org>
2012
2013         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
2014         ENABLE_RELOCATABLE here.
2015         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
2016
2017 2007-03-03  Bruno Haible  <bruno@clisp.org>
2018
2019         * modules/rbtreehash-list-tests (Depends-on): Add progname.
2020         * tests/test-rbtreehash_list.c: Include progname.h.
2021         (main): Call set_program_name.
2022
2023         * modules/rbtree-oset-tests (Depends-on): Add progname.
2024         * tests/test-rbtree_oset.c: Include progname.h.
2025         (main): Call set_program_name.
2026
2027         * modules/rbtree-list-tests (Depends-on): Add progname.
2028         * tests/test-rbtree_list.c: Include progname.h.
2029         (main): Call set_program_name.
2030
2031         * modules/linked-list-tests (Depends-on): Add progname.
2032         * tests/test-linked_list.c: Include progname.h.
2033         (main): Call set_program_name.
2034
2035 2007-03-03  Bruno Haible  <bruno@clisp.org>
2036
2037         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
2038         All uses of __restrict changed to _Restrict_.
2039         * lib/glob_.h (__restrict): Remove macro.
2040
2041 2007-03-02  Bruno Haible  <bruno@clisp.org>
2042
2043         * modules/gettext (configure.ac): Require gettext infrastructure
2044         from version 0.16.1.
2045
2046 2007-03-02  Bruno Haible  <bruno@clisp.org>
2047
2048         * modules/linkedhash-list-tests (Depends-on): Add progname.
2049         * tests/test-linkedhash_list.c: Include progname.h.
2050         (main): Call set_program_name.
2051
2052         * modules/carray-list-tests (Depends-on): Add progname.
2053         * tests/test-carray_list.c: Include progname.h.
2054         (main): Call set_program_name.
2055
2056         * modules/avltreehash-list-tests (Depends-on): Add progname.
2057         * tests/test-avltreehash_list.c: Include progname.h.
2058         (main): Call set_program_name.
2059
2060         * modules/avltree-oset-tests (Depends-on): Add progname.
2061         * tests/test-avltree_oset.c: Include progname.h.
2062         (main): Call set_program_name.
2063
2064         * modules/avltree-list-tests (Depends-on): Add progname.
2065         * tests/test-avltree_list.c: Include progname.h.
2066         (main): Call set_program_name.
2067
2068         * modules/array-oset-tests (Depends-on): Add progname.
2069         * tests/test-array_oset.c: Include progname.h.
2070         (main): Call set_program_name.
2071
2072         * modules/array-list-tests (Depends-on): Add progname.
2073         * tests/test-array_list.c: Include progname.h.
2074         (main): Call set_program_name.
2075
2076         * modules/argp-tests (Depends-on): Add progname.
2077         * tests/test-argp.c: Include argp.h first. Include progname.h.
2078         (main): Call set_program_name.
2079
2080 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
2081
2082         * doc/gnulib-tool.texi (Initial import): Reword description of
2083         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
2084         limited effect even if defined after the first system include.
2085
2086 2007-03-01  Bruno Haible  <bruno@clisp.org>
2087
2088         * build-aux/config.libpath: Update to libtool-1.5.22.
2089         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
2090
2091 2007-03-01  Bruno Haible  <bruno@clisp.org>
2092
2093         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
2094         foo_CFLAGS.
2095         Reported by Ralf Wildenhues.
2096
2097 2007-03-01  Bruno Haible  <bruno@clisp.org>
2098
2099         * build-aux/install-reloc: Remove object files left over by some
2100         compilers.
2101         Reported by Ralf Wildenhues.
2102
2103 2007-03-01  Bruno Haible  <bruno@clisp.org>
2104
2105         * build-aux/install-reloc: Break long lines.
2106
2107 2007-03-01  Bruno Haible  <bruno@clisp.org>
2108
2109         * doc/relocatable.texi: Document that it may not work on OpenBSD.
2110         Reported by Ralf Wildenhues.
2111
2112 2007-03-01  Bruno Haible  <bruno@clisp.org>
2113
2114         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
2115         include ordering constraints.
2116
2117 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
2118
2119         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
2120         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
2121         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
2122         as another example.
2123         * lib/time_.h: Fix misspelling.
2124         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
2125         Require gl_HEADER_TIME_H_DEFAULTS.
2126         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
2127         * m4/time_r.m4 (gl_TIME_R): Likewise.
2128         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
2129
2130 2007-03-01  Bruno Haible  <bruno@clisp.org>
2131
2132         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
2133         * m4/utimens.m4 (gl_UTIMENS): Likewise.
2134
2135 2007-03-01  Jim Meyering  <jim@meyering.net>
2136
2137         * modules/xreadlink (Maintainer): Add my name.
2138         * modules/xreadlink-with-size (Depends-on): Alphabetize.
2139
2140 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
2141             Bruno Haible  <bruno@clisp.org>
2142
2143         * build-aux/install-reloc: Compile also c-ctype.c.
2144         * build-aux/relocatable.sh.in: New file.
2145         * doc/relocatable.texi: New file.
2146         * doc/relocatable-maint.texi: New file.
2147         * doc/gnulib.texi: Include relocatable-maint.texi.
2148         * lib/progreloc.c: Include unistd.h unconditionally.
2149         * lib/relocwrapper.c: Include unistd.h unconditionally.
2150         Include c-ctype.h.
2151         (add_dotbin): Use c_tolower.
2152         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
2153         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
2154         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
2155         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
2156         to m4/relocatable-lib.m4.
2157         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
2158         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
2159         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
2160         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
2161         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
2162         * modules/relocatable: New file.
2163         * modules/relocatable-lib: New file.
2164         * modules/relocatable-script: New file.
2165
2166 2007-02-28  Bruno Haible  <bruno@clisp.org>
2167
2168         Import --enable-relocatable infrastructure.
2169         * build-aux/config.libpath: New file, from GNU gettext.
2170         * build-aux/install-reloc: New file, from GNU gettext.
2171         * build-aux/reloc-ldflags: New file, from GNU gettext.
2172         * lib/relocatable.h: New file, from GNU gettext.
2173         * lib/relocatable.c: New file, from GNU gettext.
2174         * lib/relocwrapper.c: New file, from GNU gettext.
2175         * m4/relocatable.m4: New file, from GNU gettext.
2176
2177 2007-02-28  Bruno Haible  <bruno@clisp.org>
2178
2179         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
2180
2181         * modules/xreadlink: New file, from GNU gettext with modifications.
2182         * lib/xreadlink.c: New file, from GNU gettext.
2183         * lib/xreadlink.h: Add comments.
2184         (xreadlink): New declaration.
2185
2186         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
2187         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
2188         lib/xreadlink-with-size.c.
2189         (configure.ac): Remove gl_XREADLINK invocation.
2190         (Makefile.am): Augment lib_SOURCES.
2191         * m4/xreadlink.m4: Remove file.
2192         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
2193         (xreadlink_with_size): Renamed from xreadink.
2194         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
2195         * modules/canonicalize (Depends-on): Replace xreadlink with
2196         xreadlink-with-size.
2197         * lib/canonicalize.c (canonicalize_filename_mode): Update.
2198
2199 2007-02-25  Jim Meyering  <jim@meyering.net>
2200
2201         * build-aux/announce-gen: When complaining about excess arguments,
2202         list them.
2203
2204 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
2205
2206         * README: Document signed integer overflow situation more
2207         accurately.
2208
2209 2007-02-25  Bruno Haible  <bruno@clisp.org>
2210
2211         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
2212         'a' or 'A' conversion.
2213
2214 2007-02-25  Bruno Haible  <bruno@clisp.org>
2215
2216         * modules/filename: Renamed from modules/pathname.
2217         (Files): Replace lib/pathname.h with lib/filename.h. Replace
2218         lib/concatpath.c with lib/concat-filename.c.
2219         (Makefile.am): Update.
2220         (Include): Replace pathname.h with filename.h.
2221         * lib/filename.h: Renamed from lib/pathname.h.
2222         (concatenated_filename): Renamed from concatenated_pathname.
2223         * lib/concat-filename.c: Renamed from lib/concatpath.c.
2224         (concatenated_filename): Renamed from concatenated_pathname.
2225         * lib/findprog.c: Include filename.h instead of pathname.h.
2226         (find_in_path): Update.
2227         * lib/javacomp.c: Include filename.h instead of pathname.h.
2228         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
2229         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
2230         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
2231         is_oldgcj_14_13_usable, is_javac_usable): Update.
2232         * lib/javaexec.c: Include filename.h instead of pathname.h.
2233         (execute_java_class): Update.
2234         * modules/findprog: Update.
2235         * modules/javacomp: Update.
2236         * modules/javaexec: Update.
2237         * MODULES.html.sh (File system functions): Add 'filename', remove
2238         'pathname'.
2239
2240 2007-02-25  Bruno Haible  <bruno@clisp.org>
2241
2242         * modules/printf-frexpl-tests: New file.
2243         * tests/test-printf-frexpl.c: New file.
2244
2245         * modules/printf-frexpl: New file.
2246         * lib/printf-frexpl.h: New file.
2247         * lib/printf-frexpl.c: New file.
2248         * m4/printf-frexpl.m4: New file.
2249
2250 2007-02-25  Bruno Haible  <bruno@clisp.org>
2251
2252         * modules/printf-frexp-tests: New file.
2253         * tests/test-printf-frexp.c: New file.
2254
2255         * modules/printf-frexp: New file.
2256         * lib/printf-frexp.h: New file.
2257         * lib/printf-frexp.c: New file.
2258         * m4/printf-frexp.m4: New file.
2259
2260 2007-02-25  Bruno Haible  <bruno@clisp.org>
2261
2262         Assume automake >= 1.10 for the tests.
2263         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
2264         * modules/arctwo-tests: Likewise.
2265         * modules/argp-tests: Likewise.
2266         * modules/avltree-list-tests: Likewise.
2267         * modules/avltree-oset-tests: Likewise.
2268         * modules/avltreehash-list-tests: Likewise.
2269         * modules/carray-list-tests: Likewise.
2270         * modules/crc-tests: Likewise.
2271         * modules/des-tests: Likewise.
2272         * modules/gc-arcfour-tests: Likewise.
2273         * modules/gc-arctwo-tests: Likewise.
2274         * modules/gc-des-tests: Likewise.
2275         * modules/gc-hmac-md5-tests: Likewise.
2276         * modules/gc-hmac-sha1-tests: Likewise.
2277         * modules/gc-md2-tests: Likewise.
2278         * modules/gc-md4-tests: Likewise.
2279         * modules/gc-md5-tests: Likewise.
2280         * modules/gc-pbkdf2-sha1-tests: Likewise.
2281         * modules/gc-rijndael-tests: Likewise.
2282         * modules/gc-sha1-tests: Likewise.
2283         * modules/gc-tests: Likewise.
2284         * modules/getaddrinfo-tests: Likewise.
2285         * modules/hmac-md5-tests: Likewise.
2286         * modules/hmac-sha1-tests: Likewise.
2287         * modules/linked-list-tests: Likewise.
2288         * modules/linkedhash-list-tests: Likewise.
2289         * modules/lock-tests: Likewise.
2290         * modules/md2-tests: Likewise.
2291         * modules/md4-tests: Likewise.
2292         * modules/md5-tests: Likewise.
2293         * modules/rbtree-list-tests: Likewise.
2294         * modules/rbtree-oset-tests: Likewise.
2295         * modules/rbtreehash-list-tests: Likewise.
2296         * modules/read-file-tests: Likewise.
2297         * modules/rijndael-tests: Likewise.
2298         * modules/stdint-tests: Likewise.
2299         * modules/tls-tests: Likewise.
2300
2301 2007-02-24  Bruno Haible  <bruno@clisp.org>
2302
2303         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
2304         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
2305         function; instead check whether isnan with a double argument links.
2306         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
2307         function; instead check whether isnan with a 'long double' argument
2308         links.
2309         Reported by Eric Blake <ebb9@byu.net>.
2310
2311 2007-02-24  Bruno Haible  <bruno@clisp.org>
2312
2313         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
2314         defined.
2315         * lib/isnanl.c: Remove all code. Just include isnan.c.
2316         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
2317
2318 2007-02-25  Jim Meyering  <jim@meyering.net>
2319
2320         Avoid conflicting types for 'unsetenv' on FreeBSD.
2321         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
2322         conflicting with FreeBSD's (5.0 and 6.1) function declaration
2323         in stdlib.h.
2324
2325 2007-02-24  Bruno Haible  <bruno@clisp.org>
2326
2327         * modules/isnanl-nolibm-tests: New file.
2328         * tests/test-isnanl.c: New file.
2329
2330         * modules/isnanl-nolibm: New file.
2331         * lib/isnanl.h: New file.
2332         * lib/isnanl.c: New file.
2333         * m4/isnanl.m4: New file.
2334
2335 2007-02-24  Bruno Haible  <bruno@clisp.org>
2336
2337         * modules/isnan-nolibm-tests: New file.
2338         * tests/test-isnan.c: New file.
2339
2340         * modules/isnan-nolibm: New file.
2341         * lib/isnan.h: New file.
2342         * lib/isnan.c: New file.
2343         * m4/isnan.m4: New file.
2344
2345 2007-02-24  Bruno Haible  <bruno@clisp.org>
2346
2347         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
2348         assume that an exponent fits in 20 bits.
2349
2350 2007-02-24  Jim Meyering  <jim@meyering.net>
2351
2352         * m4/regex.m4: Update the description of the configure-time option,
2353         --without-included-regex, to state accurately what the defaults are,
2354         and perhaps to give people an idea why using this option is risky.
2355
2356 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
2357
2358         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
2359         loops on small arguments.  This attempts to avoid the problem
2360         Bruno Haible reported for AIX 4.3.2 in
2361         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
2362
2363 2007-02-23  Bruno Haible  <bruno@clisp.org>
2364
2365         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
2366         Needed for help2man.
2367
2368 2007-02-23  Karl Berry  <karl@gnu.org>
2369
2370         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
2371         exists, foo.h should be cvs-ignored, not committed.
2372
2373 2007-02-23  Eric Blake  <ebb9@byu.net>
2374
2375         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
2376         * lib/stat-time.h (includes): Likewise.
2377         * lib/utimecmp.c (includes): Likewise.
2378         * lib/utimens.h (includes): Likewise.
2379         * lib/getdate.y (includes): Also include "timespec.h" for use
2380         internal to the module.
2381         * modules/utimens (Depends-on): Revert yesterday's patch.
2382         * modules/nanosleep (Depends-on): Add missing dependency.
2383
2384 2007-02-22  Bruno Haible  <bruno@clisp.org>
2385
2386         * lib/glob.c: Don't include getlogin_r.h.
2387
2388 2007-02-22  Jim Meyering  <jim@meyering.net>
2389
2390         * modules/utimens (Depends-on): Add timespec, required for
2391         utimens.h's inclusion of timespec.h.
2392
2393 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
2394
2395         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
2396         long unreadable paths in GNU/Linux.  Problem reported by Andreas
2397         Schwab in
2398         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
2399         I'll try to think of a better way to fix the Solaris problem.
2400
2401         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
2402         like glibc; on Solaris 10, it fails with errno == EINVAL.
2403         POSIX says the behavior is unspecified if the first argument is NULL,
2404         so play it safe and never pass NULL to the system getcwd.
2405
2406 2007-02-21  Jim Meyering  <jim@meyering.net>
2407
2408         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
2409         of gettimeofday.  It would conflict with the one now always
2410         provided via sys_time_.h.  Reported by Matthew Woehlke, as
2411         an IRIX 6.5 build failure.
2412
2413 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
2414
2415         Minor fixups to port to Solaris 10 with Sun C 5.8.
2416         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
2417         * modules/getcwd (Depends-on): Add dirfd.
2418         * lib/putenv.c (putenv): #undef it.
2419         (rpl_putenv): New decl.
2420         (malloc, free): Include <stdlib.h> rather than prototyping separately.
2421
2422 2007-02-20  Bruno Haible  <bruno@clisp.org>
2423
2424         * modules/stdio-tests: New file.
2425         * tests/test-stdio.c: New file.
2426
2427         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
2428         (Depends-on): Add stdio.
2429         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
2430         (Include): Use <stdio.h> instead of vsnprintf.h.
2431         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
2432         HAVE_DECL_VSNPRINTF.
2433         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
2434
2435         * modules/snprintf (Files): Remove lib/snprintf.h.
2436         (Depends-on): Add stdio.
2437         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
2438         (Include): Use <stdio.h> instead of snprintf.h.
2439         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
2440         HAVE_DECL_SNPRINTF.
2441         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
2442         * lib/getaddrinfo.c: Likewise.
2443
2444         * modules/stdio: New file.
2445         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
2446         * lib/snprintf.h: Remove file.
2447         * lib/vsnprintf.h: Remove file.
2448         * lib/.cppi-disable: Remove snprintf.h.
2449         * m4/stdio_h.m4: New file.
2450         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
2451
2452 2007-02-20  Jim Meyering  <jim@meyering.net>
2453
2454         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
2455         used by e.g., mingw.  From Bruno Haible.
2456
2457 2007-02-19  Bruno Haible  <bruno@clisp.org>
2458
2459         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
2460         warnings.
2461         Reported by Ben Pfaff <blp@cs.stanford.edu>.
2462
2463 2007-02-19  Bruno Haible  <bruno@clisp.org>
2464
2465         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
2466         from mingw users.
2467
2468 2007-02-19  Bruno Haible  <bruno@clisp.org>
2469
2470         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
2471         warnings.
2472         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
2473
2474 2007-02-19  Jim Meyering  <jim@meyering.net>
2475
2476         Don't use FD after a successful "fdopendir (fd)".
2477         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
2478         Reset it by calling dirfd on the just-obtained DIR*.
2479
2480         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
2481         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
2482
2483 2007-02-18  Bruno Haible  <bruno@clisp.org>
2484
2485         * lib/readlink.c: Include <unistd.h>.
2486         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
2487         HAVE_READLINK.
2488         * modules/readlink (Depends-on): Add unistd.
2489         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2490         (Include): Add <unistd.h>.
2491
2492         * lib/getlogin_r.h: Remove file.
2493         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
2494         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
2495         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
2496         HAVE_DECL_GETLOGIN_R.
2497         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
2498         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2499         (Include): Use <unistd.h> instead of getlogin_r.h.
2500
2501         * lib/getcwd.h: Remove file.
2502         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
2503         * lib/xgetcwd.c: Likewise.
2504         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
2505         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
2506         * modules/getcwd (Files): Remove lib/getcwd.h.
2507         (Depends-on): Add unistd.
2508         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2509         (Include): Use <unistd.h> instad of getcwd.h.
2510
2511         * lib/ftruncate.c: Include <unistd.h> first.
2512         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
2513         Set HAVE_FTRUNCATE.
2514         * modules/ftruncate (Depends-on): Add unistd.
2515         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2516
2517         * lib/fchdir.c: Include <unistd.h> first.
2518         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
2519         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
2520         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
2521         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2522         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
2523
2524         * lib/dup2.c: Include <unistd.h> first.
2525         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
2526         HAVE_DUP2.
2527         * modules/dup2 (Depends-on): Add unistd.
2528         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2529
2530         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
2531         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
2532         REPLACE_CHOWN. Don't define chown as a macro here.
2533         * modules/chown (Depends-on): Add unistd.
2534         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2535
2536         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
2537         Add definition for GL_LINK_WARNING.
2538         (chown, dup2): New declarations.
2539         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
2540         link warning.
2541         (ftruncate): New declaration.
2542         (getcwd): New declaration, taken from old getcwd.h.
2543         (getlogin_r): New declaration, taken from old getlogin_r.h.
2544         (readlink): New declaration.
2545         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
2546         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
2547         (gl_PREREQ_UNISTD): Remove macro.
2548         (gl_UNISTD_MODULE_INDICATOR): New macro.
2549         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
2550         many new variables. Don't set UNISTD_H.
2551         * modules/unistd (Description): Change.
2552         (Depends-on): Add link-warning.
2553         (configure.ac): Update.
2554         (Makefile.am): Create unistd.h always. Substitute many new variables
2555         into it.
2556
2557 2007-02-18  Bruno Haible  <bruno@clisp.org>
2558
2559         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
2560         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
2561         HAVE_GETSUBOPT.
2562         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
2563         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
2564         * lib/getsubopt.h: Remove file.
2565         * modules/getsubopt (Files): Remove lib/getsubopt.h.
2566         (Depends-on): Add stdlib.
2567         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2568         (Includes): Use <stdlib.h> instead of getsubopt.h.
2569         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
2570         Set HAVE_GETSUBOPT.
2571         * lib/getsubopt.c: Don't include getsubopt.h.
2572
2573 2007-02-18  Bruno Haible  <bruno@clisp.org>
2574
2575         * modules/fchdir (Depends-on): Add dup2.
2576
2577 2007-02-18  Bruno Haible  <bruno@clisp.org>
2578
2579         * lib/stdlib_.h: Handle glibc's special invocation convention
2580         specially.
2581
2582 2007-02-18  Bruno Haible  <bruno@clisp.org>
2583
2584         * modules/stdlib-tests: New file.
2585         * tests/test-stdlib.c: New file.
2586
2587         * modules/mkstemp (Files): Remove lib/mkstemp.h.
2588         (Depends-on): Add stdlib.
2589         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2590         (Includes): Use <stdlib.h> instead of mkstemp.h.
2591         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
2592         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
2593         * lib/mkstemp.c: Don't include mkstemp.h.
2594         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
2595         * lib/stdlib--.h: Don't include mkstemp.h.
2596
2597         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
2598         (Depends-on): Add stdlib.
2599         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2600         (Includes): Use <stdlib.h> instead of mkdtemp.h.
2601         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
2602         HAVE_MKDTEMP.
2603         * lib/mkdtemp.c: Don't include mkdtemp.h.
2604         * lib/clean-temp.c: Don't include mkdtemp.h.
2605
2606         * modules/exit (Files): Remove lib/exit.h.
2607         (Depends-on): Add stdlib.
2608         (Makefile.am): Remove lib_SOURCES.
2609         (Include): Use <stdlib.h> instead of exit.h.
2610         * lib/argmatch.c: Don't include exit.h.
2611         * lib/execute.c: Likewise.
2612         * lib/pagealign_alloc.c: Likewise.
2613         * lib/pipe.c: Likewise.
2614         * lib/wait-process.c: Likewise.
2615         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
2616         * lib/exitfail.c: Likewise.
2617         * lib/savewd.c: Likewise.
2618         * lib/xsetenv.c: Likewise.
2619
2620         * modules/stdlib: New file.
2621         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
2622         and extra comments about mkstemp().
2623         * lib/exit.h: Remove file.
2624         * lib/mkdtemp.h: Remove file.
2625         * lib/mkstemp.h: Remove file.
2626         * m4/stdlib_h.m4: New file.
2627         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
2628
2629 2007-02-18  Bruno Haible  <bruno@clisp.org>
2630
2631         * modules/math-tests: New file.
2632         * tests/test-math.c: New file.
2633
2634         * modules/math: New file.
2635         * modules/mathl (Files): Remove lib/mathl.h.
2636         (Depends-on): Add math.
2637         (Makefile.am): Don't mention mathl.h.
2638         (Include): Use <math.h> instead of mathl.h.
2639         * lib/math_.h: New file.
2640         * lib/mathl.h: Remove file.
2641         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
2642         mathl.h.
2643         * lib/asinl.c: Likewise.
2644         * lib/atanl.c: Likewise.
2645         * lib/ceill.c: Likewise.
2646         * lib/cosl.c: Likewise.
2647         * lib/expl.c: Likewise.
2648         * lib/floorl.c: Likewise.
2649         * lib/frexpl.c: Likewise.
2650         * lib/ldexpl.c: Likewise.
2651         * lib/logl.c: Likewise.
2652         * lib/sincosl.c: Likewise.
2653         * lib/sinl.c: Likewise.
2654         * lib/sqrtl.c: Likewise.
2655         * lib/tanl.c: Likewise.
2656         * lib/trigl.c: Likewise.
2657         * m4/math_h.m4: New file.
2658         * MODULES.html.sh (Mathematics): Add math.
2659
2660 2007-02-17  Bruno Haible  <bruno@clisp.org>
2661
2662         * modules/wctype-tests: New file.
2663         * tests/test-wctype.c: New file.
2664
2665         * modules/wchar-tests: New file.
2666         * tests/test-wchar.c: New file.
2667
2668         * modules/unistd-tests: New file.
2669         * tests/test-unistd.c: New file.
2670
2671         * modules/time-tests: New file.
2672         * tests/test-time.c: New file.
2673
2674         * modules/sysexits-tests: New file.
2675         * tests/test-sysexits.c: New file.
2676
2677         * modules/sys_time-tests: New file.
2678         * tests/test-sys_time.c: New file.
2679
2680         * modules/sys_stat-tests: New file.
2681         * tests/test-sys_stat.c: New file.
2682
2683         * modules/sys_socket-tests: New file.
2684         * tests/test-sys_socket.c: New file.
2685
2686         * modules/sys_select-tests: New file.
2687         * tests/test-sys_select.c: New file.
2688
2689         * modules/string-tests: New file.
2690         * tests/test-string.c: New file.
2691
2692         * modules/stdbool-tests: New file.
2693         * tests/test-stdbool.c: New file.
2694
2695         * modules/netinet_in-tests: New file.
2696         * tests/test-netinet_in.c: New file.
2697
2698         * modules/inttypes-tests: New file.
2699         * tests/test-inttypes.c: New file.
2700
2701         * modules/fcntl-tests: New file.
2702         * tests/test-fcntl.c: New file.
2703
2704         * modules/byteswap-tests: New file.
2705         * tests/test-byteswap.c: New file.
2706
2707         * modules/arpa_inet-tests: New file.
2708         * tests/test-arpa_inet.c: New file.
2709
2710 2007-02-17  Bruno Haible  <bruno@clisp.org>
2711
2712         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
2713         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
2714         if the corresponding module is not enabled. Emit link warnings if
2715         the function is used nevertheless.
2716         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
2717         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
2718         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
2719         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
2720         * modules/inttypes (Depends-on): Add link-warning.
2721         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2722         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
2723         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
2724         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
2725         * modules/imaxdiv (configure.ac): Likewise.
2726         * modules/strtoimax (configure.ac): Likewise.
2727         * modules/strtoumax (configure.ac): Likewise.
2728
2729 2007-02-17  Bruno Haible  <bruno@clisp.org>
2730
2731         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
2732         gl_STRING_MODULE_INDICATOR_DEFAULTS.
2733         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
2734         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
2735
2736 2007-02-17  Bruno Haible  <bruno@clisp.org>
2737
2738         * modules/link-warning: New file.
2739         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
2740         * lib/string_.h (GL_LINK_WARNING): Remove definition.
2741         * modules/string (Depends-on): Add link-warning.
2742         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2743         string.h.
2744         * MODULES.html.sh (Support for building libraries and executables): Add
2745         link-warning.
2746
2747 2007-02-17  Bruno Haible  <bruno@clisp.org>
2748
2749         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
2750         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
2751         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
2752         long lines.
2753
2754 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
2755             Bruno Haible  <bruno@clisp.org>
2756
2757         * modules/tmpfile: New file.
2758         * lib/tmpfile.c: New file.
2759         * m4/tmpfile.m4: New file.
2760         * MODULES.html.sh (func_all_modules): New section "Input/output".
2761
2762 2007-02-15  Bruno Haible  <bruno@clisp.org>
2763
2764         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
2765         (supports_delete_on_close): New function.
2766         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
2767
2768 2007-02-14  Bruno Haible  <bruno@clisp.org>
2769
2770         * modules/mbspcasecmp-tests: New file.
2771         * tests/test-mbspcasecmp.sh: New file.
2772         * tests/test-mbspcasecmp.c: New file.
2773
2774         New module mbspcasecmp.
2775         * modules/mbspcasecmp: New file.
2776         * lib/mbspcasecmp.c: New file.
2777         * lib/string_.h (strncasecmp): Change warning message.
2778         (mbspcasecmp): New declaration.
2779         * m4/mbspcasecmp.m4: New file.
2780         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2781         GNULIB_MBSPCASECMP.
2782         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
2783         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
2784
2785 2007-02-14  Bruno Haible  <bruno@clisp.org>
2786
2787         * modules/mbsncasecmp-tests: New file.
2788         * tests/test-mbsncasecmp.sh: New file.
2789         * tests/test-mbsncasecmp.c: New file.
2790
2791         New module mbsncasecmp.
2792         * modules/mbsncasecmp: New file.
2793         * lib/mbsncasecmp.c: New file.
2794         * lib/string_.h (mbsncasecmp): New declaration.
2795         * m4/mbsncasecmp.m4: New file.
2796         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2797         GNULIB_MBSNCASECMP.
2798         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
2799         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
2800
2801 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
2802
2803         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
2804         Verify that it doesn't overlap with our flags.
2805         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
2806         do not have the desired effect in multibyte locales; instead, use
2807         mbscasecmp.
2808         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
2809         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
2810         we don't require GNU fnmatch ourselves (if our users require it, they
2811         should do so explicitly).
2812
2813         Fix regex code so it doesn't rely on strcasecmp.
2814         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
2815         Otherwise, include gnulib's langinfo.h.
2816         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
2817         undesirable behavior in non-C locales.  Instead, rely on localecharset.
2818         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
2819         * modules/regex (FILES): Remove m4/codeset.m4.
2820         (Depends-on): Add localcharset.  Remove strcase.
2821
2822 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2823
2824         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
2825         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
2826
2827 2007-02-13  Bruno Haible  <bruno@clisp.org>
2828
2829         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
2830         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
2831
2832 2007-02-12  Bruno Haible  <bruno@clisp.org>
2833
2834         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
2835         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
2836         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
2837         time warning rather than a link error.
2838
2839 2007-02-12  Bruno Haible  <bruno@clisp.org>
2840
2841         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
2842         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
2843         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
2844
2845 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
2846
2847         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
2848         args, not 2.
2849
2850 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
2851
2852         New module 'time', so that apps can include <time.h> as per
2853         POSIX and GNU instead of separate include files like time_r.h
2854         and timegm.h.  This implementation tries out a simpler approach
2855         for replacing decls in standard include files (as compared to
2856         the string module), somewhat as an experiment.
2857
2858         * config/srclist.txt: Comment out mktime.c for now.
2859         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
2860         since it doesn't apply any more.  Use generic wording instead.
2861         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
2862         'time'.
2863         * lib/time_.h, m4/time_h.m4, modules/time: New files.
2864         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
2865         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
2866         Don't include <sys/types.h>; no longer needed since we assume C89.
2867         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
2868         * lib/strftime.c: Likewise.
2869         * lib/time_r.c: Likewise.
2870         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
2871         * lib/nanosleep.c: Include <time.h> first, to check interface.
2872         * lib/strptime.c: Likewise.
2873         * lib/time_r.c: Likewise.
2874         * lib/timegm.c: Likewise.
2875         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
2876         needed.
2877         * lib/timegm.c: Don't include timegm.h; no longer needed.
2878         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
2879         time.h now handles any problems in that area.
2880         (struct timespec, nanosleep): Remove; time.h now arranges for these.
2881         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
2882         that time.h defines struct timespec.
2883         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
2884         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
2885         handles that.
2886         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
2887         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
2888         needed.  Set REPLACE_LOCALTIME.
2889         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
2890         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
2891         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
2892         nanosleep; time_h.m4 now does that.  Don't require
2893         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
2894         module handles this now.
2895         * modules/getdate (Depends-on): Remove timespec.  Add time.
2896         * modules/nanosleep (Depends-on): Likewise.
2897         * modules/stat-time (Depends-on): Likewise.
2898         * modules/nanosleep (Include): Include time.h, not timespec.h.
2899         * modules/strptime (Files): Remove lib/strptime.h.
2900         (Depends-on): Add extensions, time.
2901         (Include): Include time.h, not strptime.h.
2902         * modules/time_r (Files): Remove lib/time_r.h.
2903         (Depends-on): Add time.
2904         (Include): Include time.h, not time_r.h.
2905         * modules/timegm: Likewise.
2906         * modules/timespec (Description): Now does timespec-related decls
2907         of our own, instead of struct timespec itself.
2908         (Depends-on): Add time; remove extensions.
2909         (Maintainer): Add self.
2910         * modules/utimecmp (Depends-on): Add time; remove timespec.
2911         * modules/utimens (Depends-on): Likewise.
2912         * modules/xnanosleep (Depends-on): Likewise.
2913
2914 2007-02-11  Bruno Haible  <bruno@clisp.org>
2915
2916         * lib/c-strstr.c: Include allocsa.h.
2917         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2918         * lib/c-strcasestr.c: Include allocsa.h.
2919         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2920         * lib/strcasestr.c: Include allocsa.h.
2921         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
2922         * lib/mbsstr.c: Include allocsa.h.
2923         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
2924         allocsa/freesa instead of malloc/free.
2925         * lib/mbscasestr.c: Include allocsa.h.
2926         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
2927         allocsa/freesa instead of malloc/free.
2928         * modules/c-strstr (Depends-on): Add allocsa.
2929         * modules/c-strcasestr (Depends-on): Likewise.
2930         * modules/strcasestr (Depends-on): Likewise.
2931         * modules/mbsstr (Depends-on): Likewise.
2932         * modules/mbscasestr (Depends-on): Likewise.
2933
2934 2007-02-11  Bruno Haible  <bruno@clisp.org>
2935
2936         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
2937
2938         * modules/mbsspn-tests: New file.
2939         * tests/test-mbsspn.sh: New file.
2940         * tests/test-mbsspn.c: New file.
2941
2942 2007-02-11  Bruno Haible  <bruno@clisp.org>
2943
2944         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
2945
2946         * modules/mbspbrk-tests: New file.
2947         * tests/test-mbspbrk.sh: New file.
2948         * tests/test-mbspbrk.c: New file.
2949
2950 2007-02-11  Bruno Haible  <bruno@clisp.org>
2951
2952         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
2953         unneeded cast.
2954
2955         * modules/mbscspn-tests: New file.
2956         * tests/test-mbscspn.sh: New file.
2957         * tests/test-mbscspn.c: New file.
2958
2959 2007-02-11  Bruno Haible  <bruno@clisp.org>
2960
2961         * modules/mbscasecmp-tests: New file.
2962         * tests/test-mbscasecmp.sh: New file.
2963         * tests/test-mbscasecmp.c: New file.
2964
2965 2007-02-11  Bruno Haible  <bruno@clisp.org>
2966
2967         Ensure O(n) worst-case complexity of mbscasestr.
2968         * lib/mbscasestr.c: Include stdbool.h.
2969         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
2970         functions.
2971         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
2972         the bookkeeping indicates that it's worth it.
2973         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
2974
2975         * modules/mbscasestr-tests: New file.
2976         * tests/test-mbscasestr1.c: New file.
2977         * tests/test-mbscasestr2.sh: New file.
2978         * tests/test-mbscasestr2.c: New file.
2979         * tests/test-mbscasestr3.sh: New file.
2980         * tests/test-mbscasestr3.c: New file.
2981         * tests/test-mbscasestr4.sh: New file.
2982         * tests/test-mbscasestr4.c: New file.
2983         * m4/locale-tr.m4: New file.
2984
2985 2007-02-11  Bruno Haible  <bruno@clisp.org>
2986
2987         Ensure O(n) worst-case complexity of mbsstr.
2988         * lib/mbsstr.c: Include stdbool.h.
2989         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
2990         functions.
2991         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
2992         bookkeeping indicates that it's worth it.
2993         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
2994
2995         * modules/mbsstr-tests: New file.
2996         * tests/test-mbsstr1.c: New file.
2997         * tests/test-mbsstr2.sh: New file.
2998         * tests/test-mbsstr2.c: New file.
2999         * tests/test-mbsstr3.sh: New file.
3000         * tests/test-mbsstr3.c: New file.
3001         * m4/locale-fr.m4: New file.
3002
3003 2007-02-11  Bruno Haible  <bruno@clisp.org>
3004
3005         * lib/mbsrchr.c (mbsrchr): Fix bug.
3006
3007         * modules/mbsrchr-tests: New file.
3008         * tests/test-mbsrchr.sh: New file.
3009         * tests/test-mbsrchr.c: New file.
3010
3011 2007-02-11  Bruno Haible  <bruno@clisp.org>
3012
3013         * lib/mbschr.c (mbschr): Fix bug.
3014
3015         * modules/mbschr-tests: New file.
3016         * tests/test-mbschr.sh: New file.
3017         * tests/test-mbschr.c: New file.
3018         * m4/locale-zh.m4: New file.
3019
3020 2007-02-11  Bruno Haible  <bruno@clisp.org>
3021
3022         Support for copying multibyte string iterators.
3023         * lib/mbiter.h: Include <string.h>.
3024         (mbiter_multi_copy): New function.
3025         (mbi_copy): New macro.
3026         * lib/mbuiter.h: Include <string.h>.
3027         (mbuiter_multi_copy): New function.
3028         (mbui_copy): New macro.
3029
3030 2007-02-11  Bruno Haible  <bruno@clisp.org>
3031
3032         New module mbslen.
3033         * modules/mbslen: New file.
3034         * lib/mbslen.c: New file.
3035         * lib/string_.h (mbslen): New declaration.
3036         * m4/mbslen.m4: New file.
3037         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3038         GNULIB_MBSLEN.
3039         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
3040         * MODULES.html.sh (Internationalization functions): Add mbslen.
3041
3042 2007-02-11  Bruno Haible  <bruno@clisp.org>
3043
3044         Ensure O(n) worst-case complexity of strcasestr substitute.
3045         * lib/strcasestr.c: Include stdbool.h.
3046         (knuth_morris_pratt): New function.
3047         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
3048         bookkeeping indicates that it's worth it.
3049         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
3050
3051         * modules/strcasestr-tests: New file.
3052         * tests/test-strcasestr.c: New file.
3053
3054 2007-02-11  Bruno Haible  <bruno@clisp.org>
3055
3056         Ensure O(n) worst-case complexity of c_strcasestr.
3057         * lib/c-strcasestr.c: Include stdbool.h, string.h.
3058         (knuth_morris_pratt): New function.
3059         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
3060         the bookkeeping indicates that it's worth it.
3061         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
3062
3063         * modules/c-strcasestr-tests: New file.
3064         * tests/test-c-strcasestr.c: New file.
3065
3066 2007-02-11  Bruno Haible  <bruno@clisp.org>
3067
3068         Ensure O(n) worst-case complexity of c_strstr.
3069         * lib/c-strstr.c: Include stdbool.h, string.h.
3070         (knuth_morris_pratt): New function.
3071         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
3072         bookkeeping indicates that it's worth it.
3073         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
3074
3075         * lib/c-strstr.c: Complete rewrite for maintainability.
3076
3077         * modules/c-strstr-tests: New file.
3078         * tests/test-c-strstr.c: New file.
3079
3080 2007-02-11  Bruno Haible  <bruno@clisp.org>
3081
3082         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
3083         5.2.1 and earlier, whereby \055 was treated just like the range
3084         delimiter '-'.
3085         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
3086
3087 2007-02-08  Bruno Haible  <bruno@clisp.org>
3088
3089         * modules/regex (Depends-on): Add stdbool.
3090         Reported by Dalibor Topic <robilad@kaffe.org>.
3091
3092 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
3093
3094         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
3095         Prefer returning from main to exiting from it.
3096         Remove unnecessary parens after sizeof.
3097
3098 2007-02-05  Bruno Haible  <bruno@clisp.org>
3099
3100         New module mbssep.
3101         * modules/mbssep: New file.
3102         * lib/mbssep.c: New file.
3103         * lib/string_.h (strsep): Add a conditional link warning.
3104         (mbssep): New declaration.
3105         * m4/mbssep.m4: New file.
3106         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3107         GNULIB_MBSSEP.
3108         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
3109         * MODULES.html.sh (Internationalization functions): Add mbssep.
3110
3111 2007-02-05  Bruno Haible  <bruno@clisp.org>
3112
3113         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
3114         Optimize search in case of 1 delimiter.
3115
3116 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
3117
3118         * lib/acl.h: Include sys/types.h before sys/acl.h.
3119
3120 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
3121
3122         Merge upstream fix for glibc bugzilla #3957:
3123
3124         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
3125
3126         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
3127         bit for RE_HAT_LISTS_NOT_NEWLINE.
3128         (build_charclass_op): Remove bogus comment.
3129
3130 2007-02-05  Simon Josefsson  <simon@josefsson.org>
3131
3132         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
3133
3134 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
3135
3136         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
3137         * lib/memmem.c [!defined _LIBC]: Include config.h.
3138
3139 2007-02-04  Bruno Haible  <bruno@clisp.org>
3140
3141         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
3142         warning message.
3143
3144 2007-02-04  Bruno Haible  <bruno@clisp.org>
3145
3146         New module mbstok_r.
3147         * modules/mbstok_r: New file.
3148         * lib/mbstok_r.c: New file.
3149         * lib/string_.h (strtok_r): Change argument names to match the
3150         comments. Add a conditional link warning.
3151         (mbstok_r): New declaration.
3152         * m4/mbstok_r.m4: New file.
3153         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3154         GNULIB_MBSTOK_R.
3155         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
3156         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
3157
3158 2007-02-04  Bruno Haible  <bruno@clisp.org>
3159
3160         New module mbsspn.
3161         * modules/mbsspn: New file.
3162         * lib/mbsspn.c: New file.
3163         * lib/string_.h (strspn): Add a conditional link warning.
3164         (mbsspn): New declaration.
3165         * m4/mbsspn.m4: New file.
3166         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3167         GNULIB_MBSSPN.
3168         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
3169         * MODULES.html.sh (Internationalization functions): Add mbsspn.
3170
3171 2007-02-04  Bruno Haible  <bruno@clisp.org>
3172
3173         New module mbspbrk.
3174         * modules/mbspbrk: New file.
3175         * lib/mbspbrk.c: New file.
3176         * lib/string_.h (strpbrk): Add a conditional link warning.
3177         (mbspbrk): New declaration.
3178         * m4/mbspbrk.m4: New file.
3179         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3180         GNULIB_MBSPBRK.
3181         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
3182         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
3183
3184 2007-02-04  Bruno Haible  <bruno@clisp.org>
3185
3186         New module mbscspn.
3187         * modules/mbscspn: New file.
3188         * lib/mbscspn.c: New file.
3189         * lib/string_.h (strcspn): Add a conditional link warning.
3190         (mbscspn): New declaration.
3191         * m4/mbscspn.m4: New file.
3192         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3193         GNULIB_MBSCSPN.
3194         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
3195         * MODULES.html.sh (Internationalization functions): Add mbscspn.
3196
3197 2007-02-04  Bruno Haible  <bruno@clisp.org>
3198
3199         New module mbscasestr, reduced goal of strcasestr.
3200         * modules/mbscasestr: New file.
3201         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
3202         (mbscasestr): Renamed from strcasestr.
3203         * lib/strcasestr.c: Don't include mbuiter.h.
3204         (strcasestr): Remove support for multibyte locales.
3205         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
3206         Change the conditional link warning.
3207         (mbscasestr): New declaration.
3208         * m4/mbscasestr.m4: New file.
3209         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
3210         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
3211         REPLACE_STRCASESTR.
3212         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
3213         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
3214         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
3215         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
3216         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
3217         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
3218         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
3219         (Depends-on): Remove mbuiter.
3220         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
3221
3222 2007-02-04  Bruno Haible  <bruno@clisp.org>
3223
3224         Simplify handling of strncasecmp.
3225         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
3226         the conditional link warning.
3227         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
3228         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
3229         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
3230         * modules/strcase (configure.ac): Don't invoke
3231         gl_STRING_MODULE_INDICATOR.
3232         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
3233
3234 2007-02-04  Bruno Haible  <bruno@clisp.org>
3235
3236         New module mbscasecmp, reduced goal of strcasecmp.
3237         * modules/mbscasecmp: New file.
3238         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
3239         (mbscasecmp): Renamed from strcasecmp.
3240         * lib/strcasecmp.c: Don't include mbuiter.h.
3241         (strcasecmp): Remove support for multibyte locales.
3242         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
3243         Change the conditional link warning.
3244         (mbscasecmp): New declaration.
3245         * m4/mbscasecmp.m4: New file.
3246         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
3247         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
3248         REPLACE_STRCASECMP.
3249         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
3250         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3251         GNULIB_MBSCASECMP.
3252         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
3253         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
3254         * modules/strcase (Files): Remove m4/mbrtowc.m4.
3255         (Depends-on): Remove mbuiter.
3256         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
3257
3258 2007-02-04  Bruno Haible  <bruno@clisp.org>
3259
3260         New module mbsstr. Remove module strstr.
3261         * modules/mbsstr: New file.
3262         * modules/strstr: Remove file.
3263         * lib/mbsstr.c: Renamed from lib/strstr.c.
3264         (mbsstr): Renamed from strstr.
3265         * lib/string_.h (strstr): Remove declaration. Change the conditional
3266         link warning.
3267         (mbsstr): New declaration.
3268         * m4/mbsstr.m4: New file.
3269         * m4/strstr.m4: Remove file.
3270         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
3271         REPLACE_STRSTR.
3272         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
3273         Don't initialize GNULIB_STRSTR.
3274         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
3275         substitute GNULIB_STRSTR and REPLACE_STRSTR.
3276         * MODULES.html.sh (Internationalization functions): Add mbsstr.
3277         (Support for systems lacking ANSI C 89): Remove strstr.
3278
3279 2007-02-04  Bruno Haible  <bruno@clisp.org>
3280
3281         New module mbsrchr.
3282         * modules/mbsrchr: New file.
3283         * lib/mbsrchr.c: New file.
3284         * lib/string_.h (strrchr): Add a conditional link warning.
3285         (mbsrchr): New declaration.
3286         * m4/mbsrchr.m4: New file.
3287         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3288         GNULIB_MBSRCHR.
3289         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
3290         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
3291
3292 2007-02-04  Bruno Haible  <bruno@clisp.org>
3293
3294         New module mbschr.
3295         * modules/mbschr: New file.
3296         * lib/mbschr.c: New file.
3297         * lib/string_.h (strchr): Add a conditional link warning.
3298         (mbschr): New declaration.
3299         * m4/mbschr.m4: New file.
3300         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3301         GNULIB_MBSCHR.
3302         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
3303         * MODULES.html.sh (Internationalization functions): Add mbschr.
3304
3305 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
3306
3307         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
3308
3309         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
3310
3311 2007-02-04  Bruno Haible  <bruno@clisp.org>
3312
3313         New module description section 'configure.ac-early'.
3314         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
3315         (func_get_autoconf_early_snippet): New function.
3316         (func_import, func_create_testdir): Use it. Remove special cases for
3317         modules 'extensions' and 'lock'.
3318         * modules/extensions (configure.ac-early): Require
3319         gl_USE_SYSTEM_EXTENSIONS.
3320         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
3321
3322 2007-02-04  Bruno Haible  <bruno@clisp.org>
3323
3324         Make use of gcj-4.3's -fsource and -ftarget option.
3325         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
3326         and if so try the options -fsource and -ftarget.
3327         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
3328         source_version, ftarget_option, target_version arguments.
3329         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
3330         (is_envjavac_oldgcj_14_14_usable): Renamed from
3331         is_envjavac_gcj_14_14_usable.
3332         (is_envjavac_oldgcj_14_13_usable): Renamed from
3333         is_envjavac_gcj_14_13_usable.
3334         (is_gcj_present): Update.
3335         (is_gcj_43, is_gcj43_usable): New functions.
3336         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
3337         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
3338         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
3339         try the options -fsource and -ftarget.
3340
3341 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
3342
3343         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
3344         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
3345         larger value.
3346
3347 2007-02-03  Jim Meyering  <jim@meyering.net>
3348
3349         Give tools a better chance to allocate space for very large buffers.
3350         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
3351
3352         Make pwd and readlink work also when run with an unreadable parent dir
3353         on systems with openat support.
3354         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
3355         provided getcwd function, even when we have openat support.
3356         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
3357
3358 2007-02-02  Bruno Haible  <bruno@clisp.org>
3359
3360         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
3361         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
3362         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
3363         portability problems if one of these functions is only used on specific
3364         platforms.
3365         Reported by Paul Eggert.
3366
3367 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
3368
3369         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
3370         is causing more trouble than it's curing.
3371         * lib/regex_internal.h (__mempcpy): Remove.
3372         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
3373         (and make the code a tad smaller to boot).
3374         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
3375
3376 2007-02-02  Jim Meyering  <jim@meyering.net>
3377
3378         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
3379         section, not in the Makefile.am: one.
3380
3381 2007-02-02  Eric Blake  <ebb9@byu.net>
3382
3383         * lib/strchrnul.c: Always include config.h first.
3384
3385         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
3386         gnulib strstr is not necessary here.
3387
3388 2007-02-02  Simon Josefsson  <simon@josefsson.org>
3389
3390         * m4/socklen.m4: Fix typo.
3391
3392 2007-02-02  Eric Blake  <ebb9@byu.net>
3393
3394         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
3395         * modules/netinet_in (Makefile.am): Likewise.
3396
3397 2007-02-01  Bruno Haible  <bruno@clisp.org>
3398
3399         * lib/string_.h (GL_LINK_WARNING): New macro.
3400         (strcasecmp, strstr, strcasestr): If provided by the system,
3401         conditionally define as a macro that leads to a warning instead of to
3402         an error.
3403         (strncasecmp): Conditionally define as a macro that leads to a warning.
3404
3405 2007-02-01  Karl Berry  <karl@gnu.org>
3406
3407         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
3408
3409 2007-02-01  Bruno Haible  <bruno@clisp.org>
3410
3411         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
3412         renamings.
3413
3414 2007-02-01  Eric Blake  <ebb9@byu.net>
3415
3416         * modules/regex (Depends-on): Revert dependence on mempcpy.
3417         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
3418         module's definition of mempcpy.
3419         Reported by Paul Eggert.
3420
3421 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
3422
3423         * lib/string_.h: If the gnulib module XYZ is not present, undefine
3424         the symbol XYZ before redefining it.  This fixes a problem with
3425         programs that don't use XYZ, when compiled on systems that define
3426         XYZ to something else.
3427
3428 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
3429
3430         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
3431         occurs when "mkdir -m foo" creates a setgid directory that is (1)
3432         writeable to group or other and (2) is intended to have a special
3433         mode bit that is set or cleared.  In such a case, the directory
3434         should be neither group- nor other-writeable until the special
3435         mode bits are right.
3436
3437 2007-01-31  Eric Blake  <ebb9@byu.net>
3438
3439         * modules/mountlist (Depends-on): Add strstr.
3440
3441         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
3442         bug.
3443         * modules/string (Makefile.am): Remove redundant replacement.
3444         * modules/regex (Depends-on): Add mempcpy.
3445
3446 2007-01-31  Bruno Haible  <bruno@clisp.org>
3447
3448         New module description field 'Link'.
3449         * gnulib-tool (func_usage): Document --extract-link-directive.
3450         (sed_extract_prog): Recognize 'Link' directive.
3451         (func_get_link_directive): New function.
3452         (func_import): Show summary of link directives.
3453         Handle --extract-link-directive option.
3454         * modules/acl (Link): New section.
3455         * modules/clock-time (Link): New section.
3456         * modules/euidaccess (Link): New section.
3457         * modules/gettext (Link): New section.
3458         * modules/iconv (Link): New section.
3459         * modules/lock (Link): New section.
3460         * modules/nanosleep (Link): New section.
3461         * modules/readline (Link): New section.
3462
3463 2007-01-27  Bruno Haible  <bruno@clisp.org>
3464
3465         Enforce the use of gnulib modules for unportable <string.h> functions.
3466         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
3467         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
3468         (gl_HEADER_STRING_H_BODY): Require it.
3469         * lib/string_.h: If the gnulib module XYZ is not present, redefine
3470         the symbol XYZ to one that gives a link error.
3471         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
3472         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
3473         * modules/mempcpy (configure.ac): Likewise.
3474         * modules/memrchr (configure.ac): Likewise.
3475         * modules/stpcpy (configure.ac): Likewise.
3476         * modules/stpncpy (configure.ac): Likewise.
3477         * modules/strcase (configure.ac): Likewise.
3478         * modules/strcasestr (configure.ac): Likewise.
3479         * modules/strchrnul (configure.ac): Likewise.
3480         * modules/strdup (configure.ac): Likewise.
3481         * modules/strndup (configure.ac): Likewise.
3482         * modules/strnlen (configure.ac): Likewise.
3483         * modules/strpbrk (configure.ac): Likewise.
3484         * modules/strsep (configure.ac): Likewise.
3485         * modules/strstr (configure.ac): Likewise.
3486         * modules/strtok_r (configure.ac): Likewise.
3487
3488 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
3489
3490         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
3491
3492 2007-01-30  Jim Meyering  <jim@meyering.net>
3493
3494         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
3495
3496 2007-01-29  Bruno Haible  <bruno@clisp.org>
3497
3498         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
3499         * lib/execute.c: Likewise.
3500         * lib/pipe.c: Likewise.
3501         * lib/printf-args.h: Likewise.
3502         * lib/printf-args.c: Likewise.
3503         * lib/printf-parse.c: Likewise.
3504         * lib/vasnprintf.c: Likewise.
3505
3506 2007-01-29  Eric Blake  <ebb9@byu.net>
3507
3508         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
3509         declaration.
3510
3511 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
3512
3513         * lib/strptime.h (strptime): Use 'restrict' for args where
3514         POSIX requires this.
3515         * lib/strptime.c (strptime): Likewise.
3516         Change license notice from LGPL to GPL, since gnulib-tool will
3517         change this as needed.
3518         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
3519         defined.
3520         Include "strptime.h" first, to check interface.
3521         Do not #undef _LIBC and _NL_CURRENT.
3522         Do not include <stdlib.h>; no longer needed.
3523         Include "time_r.h" and declare ptime_locale_status
3524         only if _LIBC is not defined.
3525         (__P): Remove unused macro.
3526         (match_string): Bring back glibc version, but use it only if _LIBC
3527         is defined.
3528         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
3529         Remove unnecessary assertion and abort() call.
3530         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
3531         * m4/strptime.m4: Fix serial number comment.
3532         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
3533         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
3534         (Depends-on): Add time_r.
3535
3536 2007-01-29  Bruno Haible  <bruno@clisp.org>
3537
3538         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
3539         strptime.
3540         * modules/strptime (Depends-on): Add stdbool.
3541         * lib/strptime.h: Include <time.h> always. Add comments.
3542
3543 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
3544
3545         * modules/strptime: New file.
3546         * lib/strptime.h: New file.
3547         * lib/strptime.c: New file.
3548         * m4/strptime.m4: New file.
3549
3550 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
3551
3552         * MODULES.html.sh: New module mpsort.
3553         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
3554
3555         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
3556         a circularity problem with HP-UX ia64 reported by Bob Proulx in
3557         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
3558         All uses changed.
3559         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
3560         All uses changed.
3561         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
3562         to _Restrict_.
3563         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
3564         the parameter matches the prototype.
3565
3566 2007-01-28  Jim Meyering  <jim@meyering.net>
3567
3568         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
3569         sys/time.h here, reverting that part of the previous patch:
3570         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
3571
3572 2007-01-28  Bruno Haible  <bruno@clisp.org>
3573
3574         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
3575         value of $(SYS_TIME_H).
3576         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
3577         remove it conditionally, too. [added by Jim Meyering]
3578         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
3579         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
3580         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
3581         GETTIMEOFDAY_REPLACEMENT to 1.
3582
3583 2007-01-28  Bruno Haible  <bruno@clisp.org>
3584
3585         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
3586         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
3587         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
3588         Set UNISTD_H instead of UNISTD_H2.
3589         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
3590
3591 2007-01-28  Bruno Haible  <bruno@clisp.org>
3592
3593         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
3594         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
3595
3596 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3597
3598         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
3599         (func_create_testdir): Ensure C locale for `grep' and `tr'
3600         character ranges.
3601         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
3602         ACLOCAL_AMFLAGS parsing state machine.
3603
3604 2007-01-27  Bruno Haible  <bruno@clisp.org>
3605
3606         * modules/unistr/base: Update.
3607
3608 2007-01-27  Bruno Haible  <bruno@clisp.org>
3609
3610         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
3611         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
3612         * modules/unistr/u32-mbtouc-unsafe: Renamed from
3613         modules/unistr/u32-mbtouc.
3614         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
3615         * lib/unistr.h: Update.
3616         * lib/linebreak.c: Update.
3617         * modules/unistr/u32-mbtouc: Renamed from
3618         modules/unistr/u32-mbtouc-safe.
3619         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
3620         * lib/unistr.h: Update.
3621         * lib/unistr/u32-to-u8.c: Update.
3622         * lib/unistr/u32-to-u16.c: Update.
3623
3624 2007-01-27  Bruno Haible  <bruno@clisp.org>
3625
3626         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
3627         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
3628         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
3629         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
3630         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
3631         * modules/unistr/u16-mbtouc-unsafe: Renamed from
3632         modules/unistr/u16-mbtouc.
3633         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
3634         * lib/unistr.h: Update.
3635         * lib/linebreak.c: Update.
3636         * modules/linebreak: Update.
3637         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
3638         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
3639         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
3640         * modules/unistr/u16-mbtouc: Renamed from
3641         modules/unistr/u16-mbtouc-safe.
3642         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
3643         * lib/unistr.h: Update.
3644         * lib/unistr/u16-to-u8.c: Update.
3645         * modules/unistr/u16-to-u8: Update.
3646         * lib/unistr/u16-to-u32.c: Update.
3647         * modules/unistr/u16-to-u32: Update.
3648
3649 2007-01-27  Bruno Haible  <bruno@clisp.org>
3650
3651         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
3652         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
3653         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
3654         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
3655         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
3656         * modules/unistr/u8-mbtouc-unsafe: Renamed from
3657         modules/unistr/u8-mbtouc.
3658         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
3659         * lib/unistr.h: Update.
3660         * lib/striconveh.c: Update.
3661         * modules/striconveh: Update.
3662         * lib/linebreak.c: Update.
3663         * modules/linebreak: Update.
3664         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
3665         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
3666         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
3667         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
3668         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
3669         * lib/unistr.h: Update.
3670         * lib/striconveh.c: Update.
3671         * modules/striconveh: Update.
3672         * lib/unistr/u8-to-u16.c: Update.
3673         * modules/unistr/u8-to-u16: Update.
3674         * lib/unistr/u8-to-u32.c: Update.
3675         * modules/unistr/u8-to-u32: Update.
3676
3677 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3678
3679         Sync from Libtool.
3680         * lib/argz.c: Do not include strings.h nor memory.h, include
3681         string.h unconditionally.  Patch by Simon Josefsson.
3682
3683 2007-01-27  Bruno Haible  <bruno@clisp.org>
3684
3685         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
3686         from gl_HEADER_STRING_H_BODY.
3687         (gl_HEADER_STRING_H_BODY): Require it.
3688         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
3689         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
3690         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
3691         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
3692         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
3693         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
3694         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
3695         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
3696         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
3697         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
3698         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
3699         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
3700         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
3701         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
3702         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
3703
3704 2007-01-27  Bruno Haible  <bruno@clisp.org>
3705
3706         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
3707         check_PROGRAMS into noinst_PROGRAMS.
3708         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
3709         check_PROGRAMS in this case.
3710         (func_import): Set for_test to false.
3711         (func_create_testdir): Set for_test to true.
3712
3713 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
3714             Bruno Haible  <bruno@clisp.org>
3715
3716         * modules/strcasestr (Files): Remove lib/strcasestr.h.
3717         (Depends-on): Add string.
3718         (Includes): Use <string.h> instead of strcasestr.h.
3719         * modules/string (Makefile.am): Also substitute the value of
3720         REPLACE_STRCASESTR.
3721         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
3722         assume strcasestr is declared in <string.h> not <strings.h>. Also
3723         set REPLACE_STRCASESTR.
3724         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
3725         REPLACE_STRCASESTR.
3726         * lib/strcasestr.h: Remove file.
3727         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
3728         * lib/string_.h (strcasestr): New declaration.
3729
3730 2007-01-27  Bruno Haible  <bruno@clisp.org>
3731
3732         * lib/string_.h: Use 'extern'.
3733
3734 2007-01-27  Jim Meyering  <jim@meyering.net>
3735
3736         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
3737         of set-but-not-used local, "q".
3738
3739         * lib/mempcpy.c: Include <config.h> before <string.h>.
3740         This fixes a compilation error on HP-UX, due to the system's
3741         "restrict"-using mempcpy prototype.
3742
3743 2007-01-26  Bruno Haible  <bruno@clisp.org>
3744
3745         Small optimization.
3746         * lib/javacomp.c: Include c-strstr.h.
3747          (is_envjavac_gcj): Use c_strstr instead of strstr.
3748         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
3749
3750 2007-01-26  Bruno Haible  <bruno@clisp.org>
3751
3752         * MODULES.html.sh (Unicode string functions): Add the new modules.
3753
3754         * modules/uniconv/u32-strconv-to-locale: New file.
3755         * lib/uniconv/u32-strconv-to-locale.c: New file.
3756
3757         * modules/uniconv/u16-strconv-to-locale: New file.
3758         * lib/uniconv/u16-strconv-to-locale.c: New file.
3759
3760         * modules/uniconv/u8-strconv-to-locale: New file.
3761         * lib/uniconv/u8-strconv-to-locale.c: New file.
3762
3763         * modules/uniconv/u32-strconv-from-locale: New file.
3764         * lib/uniconv/u32-strconv-from-locale.c: New file.
3765
3766         * modules/uniconv/u16-strconv-from-locale: New file.
3767         * lib/uniconv/u16-strconv-from-locale.c: New file.
3768
3769         * modules/uniconv/u8-strconv-from-locale: New file.
3770         * lib/uniconv/u8-strconv-from-locale.c: New file.
3771
3772         * modules/uniconv/u32-strconv-to-enc: New file.
3773         * lib/uniconv/u32-strconv-to-enc.c: New file.
3774         * modules/uniconv/u32-strconv-to-enc-tests: New file.
3775         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
3776
3777         * modules/uniconv/u16-strconv-to-enc: New file.
3778         * lib/uniconv/u16-strconv-to-enc.c: New file.
3779         * lib/uniconv/u-strconv-to-enc.h: New file.
3780         * modules/uniconv/u16-strconv-to-enc-tests: New file.
3781         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
3782
3783         * modules/uniconv/u8-strconv-to-enc: New file.
3784         * lib/uniconv/u8-strconv-to-enc.c: New file.
3785         * modules/uniconv/u8-strconv-to-enc-tests: New file.
3786         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
3787
3788         * modules/uniconv/u32-strconv-from-enc: New file.
3789         * lib/uniconv/u32-strconv-from-enc.c: New file.
3790         * modules/uniconv/u32-strconv-from-enc-tests: New file.
3791         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
3792
3793         * modules/uniconv/u16-strconv-from-enc: New file.
3794         * lib/uniconv/u16-strconv-from-enc.c: New file.
3795         * modules/uniconv/u16-strconv-from-enc-tests: New file.
3796         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
3797
3798         * modules/uniconv/u8-strconv-from-enc: New file.
3799         * lib/uniconv/u8-strconv-from-enc.c: New file.
3800         * lib/uniconv/u-strconv-from-enc.h: New file.
3801         * modules/uniconv/u8-strconv-from-enc-tests: New file.
3802         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
3803
3804         * modules/uniconv/u32-conv-from-enc: New file.
3805         * lib/uniconv/u32-conv-from-enc.c: New file.
3806         * modules/uniconv/u32-conv-from-enc-tests: New file.
3807         * tests/uniconv/test-u32-conv-from-enc.c: New file.
3808
3809         * modules/uniconv/u16-conv-from-enc: New file.
3810         * lib/uniconv/u16-conv-from-enc.c: New file.
3811         * lib/uniconv/u-conv-from-enc.h: New file.
3812         * modules/uniconv/u16-conv-from-enc-tests: New file.
3813         * tests/uniconv/test-u16-conv-from-enc.c: New file.
3814
3815         * modules/uniconv/u8-conv-from-enc: New file.
3816         * lib/uniconv/u8-conv-from-enc.c: New file.
3817         * modules/uniconv/u8-conv-from-enc-tests: New file.
3818         * tests/uniconv/test-u8-conv-from-enc.c: New file.
3819
3820         * modules/uniconv/base: New file.
3821         * lib/uniconv.h: New file.
3822
3823 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
3824
3825         * doc/gnulib-tool.texi (Initial import): Update to match current
3826         behavior with strdup module.
3827         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
3828         * lib/memmem.h: Remove; all uses removed.  This is now done
3829         by <string.h>.
3830         * lib/mempcpy.h: Likewise.
3831         * lib/memrchr.h: Likewise.
3832         * lib/stpcpy.h: Likewise.
3833         * lib/stpncpy.h: Likewise.
3834         * lib/strcase.h: Likewise.
3835         * lib/strchrnul.h: Likewise.
3836         * lib/strdup.h: Likewise.
3837         * lib/strndup.h: Likewise.
3838         * lib/strnlen.h: Likewise.
3839         * lib/strpbrk.h: Likewise.
3840         * lib/strsep.h: Likewise.
3841         * lib/strstr.h: Likewise.
3842         * lib/strtok_r.h: Likewise.
3843         * lib/string_.h: New file.
3844         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
3845         Rely on <string.h> instead.
3846         * lib/canon-host.c: Likewise.
3847         * lib/chdir-long.c: Likewise.
3848         * lib/concatpath.c: Likewise.
3849         * lib/exclude.c: Likewise.
3850         * lib/fchdir.c: Likewise.
3851         * lib/getaddrinfo.c: Likewise.
3852         * lib/getcwd.c: Likewise.
3853         * lib/getsubopt.c: Likewise.
3854         * lib/glob.c: Likewise.
3855         * lib/hard-locale.c: Likewise.
3856         * lib/iconvme.c: Likewise.
3857         * lib/javacomp.c: Likewise.
3858         * lib/mempcpy.c: Likewise.
3859         * lib/memrchr.c: Likewise.
3860         * lib/regex_internal.h: Likewise.
3861         * lib/stpncpy.c: Likewise.
3862         * lib/strcasecmp.c: Likewise.
3863         * lib/strchrnul.c: Likewise.
3864         * lib/strdup.c: Likewise.
3865         * lib/striconv.c: Likewise.
3866         * lib/striconveh.c: Likewise.
3867         * lib/striconveha.c: Likewise.
3868         * lib/strncasecmp.c: Likewise.
3869         * lib/strndup.c: Likewise.
3870         * lib/strnlen.c: Likewise.
3871         * lib/strsep.c: Likewise.
3872         * lib/strstr.c: Likewise.
3873         * lib/strtok_r.c: Likewise.
3874         * lib/userspec.c: Likewise.
3875         * lib/w32spawn.h: Likewise.
3876         * lib/xstrndup.c: Likewise.
3877         * lib/mountlist.c (strstr): Remove decl.
3878         * m4/string_h.m4: New file.
3879         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
3880         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
3881         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
3882         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
3883         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
3884         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
3885         Set REPLACE_STRCASECMP if necessary.
3886         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
3887         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
3888         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
3889         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
3890         HAVE_DECL_STRDUP if necessary.
3891         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
3892         since gl_FUNC_STRNDUP does that now.
3893         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
3894         Check for decl here...
3895         (gl_PREREQ_STRNLEN): ... not here.
3896         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
3897         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
3898         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
3899         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
3900         necessary.
3901         * modules/string: New file.
3902         * modules/memmem (Files): Remove special-purpose include file.
3903         (Depends-on): Add string.
3904         (Include): Include <string.h>, not the removed file.
3905         * modules/mempcpy: Likewise.
3906         * modules/memrchr: Likewise.
3907         * modules/stpcpy: Likewise.
3908         * modules/stpncpy: Likewise.
3909         * modules/strcase: Likewise.
3910         * modules/strchrnul: Likewise.
3911         * modules/strdup: Likewise.
3912         * modules/strndup: Likewise.
3913         * modules/strnlen: Likewise.
3914         * modules/strpbrk: Likewise.
3915         * modules/strsep: Likewise.
3916         * modules/strstr: Likewise.
3917         * modules/strtok_r: Likewise.
3918         * tests/test-dirname.c: Don't include "strdup.h", since
3919         <string.h> now suffices.
3920         * tests/test-memmem.c: Don't include "memmem.h", since
3921         <string.h> now suffices.
3922
3923 2007-01-25  Bruno Haible  <bruno@clisp.org>
3924
3925         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
3926         *resultp is 0.
3927
3928         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
3929         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
3930         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
3931         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
3932
3933         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
3934         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
3935         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
3936         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
3937         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
3938         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
3939
3940 2007-01-24  Bruno Haible  <bruno@clisp.org>
3941
3942         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
3943         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
3944         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
3945         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
3946         gl_FUNC_FTS_CORE.
3947         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
3948         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
3949         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
3950         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
3951         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
3952         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
3953         gl_FUNC_FCHOWNAT.
3954         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
3955         gl_FUNC_STRFTIME.
3956         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
3957         Reported by Ralf Wildenhues.
3958
3959 2007-01-24  Bruno Haible  <bruno@clisp.org>
3960
3961         Drop AC_REQUIRE calls that are redundant with the module dependencies.
3962         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
3963         gl_GETADDRINFO.
3964         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
3965         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
3966         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
3967
3968 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
3969
3970         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
3971         Don't use 'exit'; just return from 'main'.
3972         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
3973
3974         * lib/fnmatch_.h: Readjust white space and comments to match
3975         glibc, to avoid spurious diffs.
3976
3977 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
3978
3979         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
3980         2004-12-01 change by Jakub Jelinek, since this code won't compile
3981         if !LIBC.  Problem reported by Bob Proulx.
3982
3983 2007-01-23  Bruno Haible  <bruno@clisp.org>
3984
3985         * lib/striconveh.c: Include c-strcaseeq.h.
3986         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
3987         * modules/striconveh (Depends-on): Add c-strcaseeq.
3988
3989 2007-01-23  Bruno Haible  <bruno@clisp.org>
3990
3991         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
3992
3993         * modules/c-strcaseeq: New file.
3994         * lib/c-strcaseeq.h: New file.
3995
3996         * modules/streq: New file.
3997         * lib/streq.h: New file.
3998
3999 2007-01-23  Bruno Haible  <bruno@clisp.org>
4000
4001         * modules/striconveha-tests: New file.
4002         * tests/test-striconveha.c: New file.
4003
4004         * lib/striconveha.h: Include <stdbool.h>.
4005         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
4006         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
4007         (mem_iconveha_notranslit): Renamed from mem_iconveha.
4008         (mem_iconveha): New function.
4009         (str_iconveha_notranslit): Renamed from str_iconveha.
4010         (str_iconveha): New function.
4011         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
4012         c-strcase.
4013
4014 2007-01-23  Bruno Haible  <bruno@clisp.org>
4015
4016         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
4017         encodings without forgiving before trying any encoding with handler.
4018         (str_iconveha): Try all encodings without forgiving before trying any
4019         encoding with handler.
4020
4021 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
4022
4023         Import the following changes from libc.
4024
4025         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
4026
4027         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
4028
4029         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
4030
4031         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
4032         normal_bracket label.
4033
4034         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
4035
4036         [BZ #361]
4037         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
4038         to normal_bracket after fetching the next character.
4039
4040 2007-01-22  Bruno Haible  <bruno@clisp.org>
4041
4042         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
4043         argument.
4044         * lib/striconveh.c (iconv_carefully_1): New function.
4045         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
4046         argument.
4047         (str_cd_iconveh): Update.
4048         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
4049         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
4050         * tests/test-striconveh.c (MAGIC): New macro.
4051         (new_offsets): New function.
4052         (main): Test call with and without offsets.
4053
4054 2007-01-22  Bruno Haible  <bruno@clisp.org>
4055
4056         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
4057         * modules/sys_select (Makefile.am): Likewise.
4058         * modules/sys_socket (Makefile.am): Likewise.
4059         * modules/sys_time (Makefile.am): Likewise.
4060
4061 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
4062
4063         * modules/gettimeofday (License): Change from GPL to LGPL, since
4064         gettimeofday is a library function.
4065
4066 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4067
4068         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
4069
4070 2007-01-21  Bruno Haible  <bruno@clisp.org>
4071
4072         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
4073
4074 2007-01-21  Bruno Haible  <bruno@clisp.org>
4075
4076         * modules/striconveha: New file.
4077         * lib/striconveha.h: New file.
4078         * lib/striconveha.c: New file.
4079         * MODULES.html.sh (Internationalization functions): Add striconveha.
4080         * lib/striconv.c (str_iconv): Optimize the case of an empty input
4081         string.
4082         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
4083
4084 2007-01-21  Bruno Haible  <bruno@clisp.org>
4085
4086         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
4087         * lib/striconveh.c (str_iconveh): Likewise.
4088
4089 2007-01-21  Bruno Haible  <bruno@clisp.org>
4090
4091         * lib/striconveh.h (mem_iconveh): New declaration.
4092         * lib/striconveh.c (mem_iconveh): New function.
4093         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
4094
4095 2007-01-21  Bruno Haible  <bruno@clisp.org>
4096
4097         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
4098
4099         * lib/striconveh.h (mem_cd_iconveh): Change specification.
4100         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
4101         original result buffer.
4102         (str_cd_iconveh): Update.
4103         * tests/test-striconveh.c (main): Update.
4104
4105         * lib/striconv.h (mem_cd_iconv): Change specification.
4106         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
4107         result buffer.
4108         (str_cd_iconv): Update.
4109         * tests/test-striconv.c (main): Update.
4110
4111 2007-01-21  Bruno Haible  <bruno@clisp.org>
4112
4113         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
4114
4115 2007-01-20  Jim Meyering  <jim@meyering.net>
4116
4117         * lib/userspec.c (parse_with_separator): If a user or group string
4118         starts with "+", skip the corresponding name-to-ID look-up, since
4119         such a look-up must fail: user and group names may not include "+".
4120
4121 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
4122
4123         * lib/poll.c: Include sys/time.h and time.h unconditionally,
4124         since we now assume the sys_time module.
4125         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
4126         check for sys/time.h; no longer needed.
4127         * modules/poll (Depends-on): Depend on sys_time.
4128
4129 2007-01-18  Bruno Haible  <bruno@clisp.org>
4130
4131         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
4132         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
4133
4134         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
4135         gettimeofday.
4136
4137         * tests/test-gettimeofday.c: Include <time.h>.
4138         (dummy): Remove variable.
4139
4140         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
4141         gl_HEADER_SYS_TIME_H.
4142         (gl_HEADER_SYS_TIME_H): New macro.
4143
4144         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
4145         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4146         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
4147         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
4148         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4149         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
4150         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
4151         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4152         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
4153         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
4154         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4155
4156         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
4157         last change; it caused a compilation error when cross-compiling to
4158         Cygwin.
4159
4160 2007-01-18  Jim Meyering  <jim@meyering.net>
4161
4162         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
4163         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
4164         than the race-prone "test -d sys || mkdir sys".
4165         (configure.ac): Use AC_PROG_MKDIR_P.
4166         * modules/sys_select: Likewise.
4167         * modules/sys_socket: Likewise.
4168         * modules/sys_time: Likewise.
4169
4170 2007-01-18  Eric Blake  <ebb9@byu.net>
4171
4172         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
4173         replace gettimeofday.
4174         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
4175         name, to avoid infinite recursion.
4176
4177 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
4178
4179         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
4180         module sys_time.
4181         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
4182         assume timespec.h defines struct timeval.
4183         * lib/settime.c: Likewise.
4184         * lib/utimens.c: Likewise.
4185         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
4186         since we now assume the gettimeofday module.
4187         * lib/tempname.c (__gen_tempname): Likewise.
4188         * lib/gettimeofday.h: Remove.
4189         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
4190         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
4191         Include <time.h>, for 'time()'.
4192         (localtime_buffer_addr): Also use this workaround if
4193         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
4194         to simplify the uses.  All uses changed.
4195         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
4196         that #undef is inside {}, and 'const' follows type name consistently.
4197         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
4198         (gettimeofday): Do not use the maximum possible value for
4199         tv->tv_usec, since that might break usages other than ls.c.
4200         Instead, we'll leave ls.c alone.  This undoes today's patch
4201         by Bruno.  Add a compile-time warning for 1s-clock resolution;
4202         we've never observed the problem but might as well keep the
4203         canary.
4204         * lib/nanosleep.c: Include timespec.h first, for interface check.
4205         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
4206         now assume the sys_time module.
4207         * lib/tempname.c: Likewise.
4208         * lib/timespec.h: Likewise.
4209         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
4210         needed.
4211         * lib/strftime.c: Likewise.
4212         * lib/timespec.h: Likewise.
4213         * lib/posixtm.c: Include posixtm.h first, for interface check.
4214         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
4215         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
4216         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
4217         * lib/sys_time_.h: New file.
4218         * lib/timespec.h (struct timespec): Use long int, not long.
4219         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
4220         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
4221         Remove obsolescent call to AC_HEADER_TIME.
4222         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
4223         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
4224         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
4225         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
4226         Likewise.
4227         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
4228         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
4229         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
4230         into the sys_time module.  Check for gettimeofday just once.
4231         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
4232         for gettimeofday signature to just check the signature.  Merely
4233         compile it, since linking doesn't test signature.  Improve test for
4234         whether gettimeofday.o is actually needed.
4235         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
4236         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
4237         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
4238         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4239         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
4240         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
4241         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
4242         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
4243         than worrying about sys/time.h.
4244         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4245         Don't bother worrying about TIME_WITH_SYS_TIME.
4246         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
4247         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
4248         * m4/sys_time_h.m4: New file.
4249         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
4250         Don't include sys/time.h.  Return from main rather than exiting.
4251         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
4252         all uses changed.
4253         * modules/gethrxtime (Depends-on): Add sys_time.
4254         * modules/gettime (Depends-on): Likewise.
4255         * modules/gettimeofday (Depends-on): Likewise.
4256         * modules/nanosleep (Depends-on): Likewise.
4257         * modules/settime (Depends-on): Likewise.
4258         * modules/tempname (Depends-on): Likewise.
4259         * modules/utimens (Depends-on): Likewise.
4260         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
4261         (Include:) Change back to <sys/time.h>.
4262         (Maintainer:) Add self.
4263         * modules/sys_time: New file.
4264         * modules/tempname (Depends-on): Add gettimeofday.
4265         * tests/test-gettimeofday.c: Include <sys/time.h>
4266         rather than gettimeofday.h.
4267
4268 2007-01-17  Bruno Haible  <bruno@clisp.org>
4269
4270         * gnulib-tool (func_get_license): Revert last patch. Instead, let
4271         the license default to GPL.
4272         (func_create_testdir): Don't complain if a module is LGPL and its
4273         tests module depends on GPLed modules.
4274
4275 2007-01-17  Bruno Haible  <bruno@clisp.org>
4276
4277         * lib/gettimeofday.c (gettimeofday): Add code for the case
4278         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
4279         maximum possible value for tv->tv_usec, rather than the minimum one.
4280
4281 2005-10-08  Martin Lambers  <marlam@marlam.de>
4282 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
4283 2007-01-16  Bruno Haible  <bruno@clisp.org>
4284
4285         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
4286         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
4287         gl_FUNC_GETTIMEOFDAY.
4288         (Include): Add gettimeofday.h.
4289         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
4290         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
4291         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
4292         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
4293         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
4294         * lib/gettimeofday.h: New file.
4295         * lib/gettimeofday.c: Include <sys/timeb.h>.
4296         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
4297         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4298         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
4299         fall back on time().
4300
4301         * tests/test-gettimeofday.c: New file.
4302         * modules/gettimeofday-tests: New file.
4303
4304 2007-01-16  Eric Blake  <ebb9@byu.net>
4305
4306         * modules/fnmatch (Depends-on): Depend on wchar.
4307         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
4308         * m4/fnmatch.m4: Likewise.
4309         * modules/mbchar (Makefile.am): Assume <wchar.h>.
4310         * m4/mbchar.m4: Likewise.
4311         * modules/mbswidth (Depends-on): Depend on wchar.
4312         * lib/mbswidth.c: Assume <wchar.h>.
4313         * m4/mbswidth.m4: Likewise.
4314         * modules/quotearg (Depends-on): Depend on wchar.
4315         * lib/quotearg.c: Assume <wchar.h>.
4316         * m4/quotearg.m4: Likewise.
4317         * modules/regex (Depends-on): Depend on wchar.
4318         * lib/regex_internal.h: Assume <wchar.h>.
4319         * m4/regex.m4: Likewise.
4320         * modules/stdint (Depends-on): Depend on wchar.
4321         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
4322         * m4/stdint.m4: Likewise.
4323         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
4324         * modules/strftime (Depends-on): Depend on wchar.
4325         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
4326         * modules/strtol (Depends-on): Depend on wchar.
4327         * lib/strtol.c: Assume <wchar.h>.
4328         * modules/wcwidth (Depends-on): Depend on wchar.
4329         * lib/wcwidth.h: Assume <wchar.h>.
4330         * m4/wcwidth.m4: Likewise.
4331
4332 2007-01-16  Bruno Haible  <bruno@clisp.org>
4333
4334         * modules/csharpexec-script: New, created from...
4335         * modules/csharpexec: ... this.
4336
4337 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
4338
4339         * modules/javaexec-script: New, created from...
4340         * modules/javaexec: ... this.
4341
4342 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4343
4344         * modules/poll (Dependencies): Add sys_select.
4345
4346 2007-01-15  Jim Meyering  <jim@meyering.net>
4347
4348         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
4349         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
4350         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
4351         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
4352
4353 2007-01-15  Bruno Haible  <bruno@clisp.org>
4354
4355         * modules/striconveh: New file.
4356         * lib/striconveh.h: New file.
4357         * lib/striconveh.c: New file.
4358         * MODULES.html.sh (Internationalization functions): Add striconveh.
4359
4360         * modules/striconveh-tests: New file.
4361         * tests/test-striconveh.c: New file.
4362
4363 2007-01-15  Bruno Haible  <bruno@clisp.org>
4364
4365         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
4366         not from GNU libiconv or GNU libc.
4367
4368 2007-01-15  Bruno Haible  <bruno@clisp.org>
4369
4370         * doc/gnulib-intro.texi (Copyright): Explain the different license
4371         terms for module descriptions, autoconf macros, tests, documentation.
4372
4373 2007-01-14  Bruno Haible  <bruno@clisp.org>
4374
4375         * modules/striconv-tests: New file.
4376         * tests/test-striconv.c: New file.
4377
4378 2007-01-14  Bruno Haible  <bruno@clisp.org>
4379
4380         * modules/iconv-tests: New file.
4381         * tests/test-iconv.c: New file.
4382
4383 2007-01-14  Bruno Haible  <bruno@clisp.org>
4384
4385         * gnulib-tool (func_get_license): For test modules, use the license of
4386         the main module.
4387
4388 2007-01-14  Bruno Haible  <bruno@clisp.org>
4389
4390         * modules/iconv (Include): Clarify that <iconv.h> can only be included
4391         if iconv is found to exist.
4392
4393 2007-01-14  Bruno Haible  <bruno@clisp.org>
4394
4395         * modules/c-ctype-tests: New file.
4396         * tests/test-c-ctype.c: New file.
4397
4398 2007-01-14  Bruno Haible  <bruno@clisp.org>
4399
4400         * modules/binary-io-tests: New file.
4401         * tests/test-binary-io.sh: New file.
4402         * tests/test-binary-io.c: New file.
4403
4404 2007-01-14  Bruno Haible  <bruno@clisp.org>
4405
4406         * modules/array-oset-tests: New file.
4407         * tests/test-array_oset.c: New file.
4408
4409 2007-01-14  Bruno Haible  <bruno@clisp.org>
4410
4411         * modules/array-list-tests: New file.
4412         * tests/test-array_list.c: New file.
4413
4414 2007-01-14  Bruno Haible  <bruno@clisp.org>
4415
4416         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
4417         and make.
4418         Reported by Simon Josefsson in
4419         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
4420
4421 2007-01-14  Bruno Haible  <bruno@clisp.org>
4422
4423         * modules/allocsa-tests: New file.
4424         * tests/test-allocsa.c: New file.
4425
4426 2007-01-14  Bruno Haible  <bruno@clisp.org>
4427
4428         * modules/fchdir (Depends-on): Add absolute-header.
4429         * modules/unistd (Depends-on): Likewise.
4430
4431 2006-12-30  Bruno Haible  <bruno@clisp.org>
4432
4433         * modules/fchdir: New file.
4434         * modules/unistd (Files): Add lib/unistd_.h.
4435         (Makefile.am): Generate unistd.h from unistd_.h.
4436         * lib/fchdir.c: New file.
4437         * lib/dirent_.h: New file.
4438         * lib/unistd_.h: New file.
4439         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
4440         * m4/fchdir.m4: New file.
4441         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
4442         (gl_HEADER_UNISTD): Invoke it.
4443         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
4444         function.
4445         * lib/backupfile.c (opendir, closedir): Undefine.
4446         * lib/chown.c (open, close): Undefine.
4447         * lib/clean-temp.c (open, close): Undefine.
4448         * lib/copy-file.c (open, close): Undefine.
4449         * lib/execute.c (open, close): Undefine.
4450         * lib/fsusage.c (open, close): Undefine.
4451         * lib/gc-gnulib.c (open, close): Undefine.
4452         * lib/getcwd.c (opendir, closedir): Undefine.
4453         * lib/glob.c (opendir, closedir): Undefine.
4454         * lib/javacomp.c (open, close): Undefine.
4455         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
4456         * lib/openat-proc.c (open, close): Undefine.
4457         * lib/pagealign_alloc.c (open, close): Undefine.
4458         * lib/pipe.c (open, close): Undefine.
4459         * lib/progreloc.c (open, close): Undefine.
4460         * lib/savedir.c (opendir, closedir): Undefine.
4461         * lib/utime.c (open, close): Undefine.
4462         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
4463
4464 2007-01-10  Bruno Haible  <bruno@clisp.org>
4465
4466         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
4467
4468 2007-01-12  Eric Blake  <ebb9@byu.net>
4469
4470         Provide a robust <wchar.h>.  Further simplifications are now
4471         possible in other modules, but not included here.
4472         * modules/wchar: New module.
4473         * m4/wchar.m4: New file.
4474         * lib/wchar_.h: Likewise.
4475         * modules/mbchar (Depends-on): Depend on wchar, as the first use
4476         of the new module.
4477         * MODULES.html.sh (Extended multibyte and wide character utilities):
4478         New section.
4479
4480 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
4481
4482         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
4483         to a reasonable default for memory allocation.
4484         (xreadlink): Don't allocate a huge buffer, to work around a buggy
4485         file system that reports garbage st_size values for symlinks.
4486         Problem reported by Liyang Hu.
4487
4488 2007-01-11  Simon Josefsson  <simon@josefsson.org>
4489
4490         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
4491         Emacs .#* auto-save files).
4492
4493 2007-01-11  Bruno Haible  <bruno@clisp.org>
4494
4495         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
4496         directory.
4497
4498 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
4499
4500         Use @...@ consistently in lib/wctype_.h.
4501         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
4502         on it being set to 1 or 0.
4503         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
4504         go back to AC_SUBSTing it.
4505         * modules/wctype (Makefile.am): Undo previous change.
4506
4507 2007-01-10  Eric Blake  <ebb9@byu.net>
4508
4509         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
4510         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
4511         * modules/wctype (Makefile.am): Likewise.
4512         Reported by Chris McGuire.
4513
4514 2007-01-10  Jim Meyering  <jim@meyering.net>
4515
4516         fts.c: a small readability/maintainability improvement
4517         * lib/fts.c (fts_read): Make this code slightly more readable and
4518         maintainable by hoisting the "sp->fts_cur = p" assignments to
4519         immediately follow the statements that set P.  Derived from
4520         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
4521
4522 2007-01-10  Eric Blake  <ebb9@byu.net>
4523
4524         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
4525         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
4526         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
4527         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
4528         Reported by Chris McGuire.
4529
4530 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4531
4532         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
4533         in sed script.
4534
4535 2007-01-09  Bruno Haible  <bruno@clisp.org>
4536
4537         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
4538         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
4539         variables.
4540         (func_module): Use them.
4541
4542 2007-01-09  Bruno Haible  <bruno@clisp.org>
4543
4544         * modules/unistr/base: New file.
4545         * lib/unistr.h: New file.
4546
4547         * modules/unistr/u8-to-u16: New file.
4548         * lib/unistr/u8-to-u16.c: New file.
4549
4550         * modules/unistr/u8-to-u32: New file.
4551         * lib/unistr/u8-to-u32.c: New file.
4552
4553         * modules/unistr/u16-to-u8: New file.
4554         * lib/unistr/u16-to-u8.c: New file.
4555
4556         * modules/unistr/u16-to-u32: New file.
4557         * lib/unistr/u16-to-u32.c: New file.
4558
4559         * modules/unistr/u32-to-u8: New file.
4560         * lib/unistr/u32-to-u8.c: New file.
4561
4562         * modules/unistr/u32-to-u16: New file.
4563         * lib/unistr/u32-to-u16.c: New file.
4564
4565         * modules/unistr/u8-check: New file.
4566         * modules/unistr/u16-check: New file.
4567         * modules/unistr/u32-check: New file.
4568         * lib/unistr/u8-check.c: New file.
4569         * lib/unistr/u16-check.c: New file.
4570         * lib/unistr/u32-check.c: New file.
4571
4572         * modules/unistr/u8-chr: New file.
4573         * modules/unistr/u16-chr: New file.
4574         * modules/unistr/u32-chr: New file.
4575         * lib/unistr/u8-chr.c: New file.
4576         * lib/unistr/u16-chr.c: New file.
4577         * lib/unistr/u32-chr.c: New file.
4578
4579         * modules/unistr/u8-cmp: New file.
4580         * modules/unistr/u16-cmp: New file.
4581         * modules/unistr/u32-cmp: New file.
4582         * lib/unistr/u8-cmp.c: New file.
4583         * lib/unistr/u16-cmp.c: New file.
4584         * lib/unistr/u32-cmp.c: New file.
4585
4586         * modules/unistr/u8-cpy: New file.
4587         * modules/unistr/u16-cpy: New file.
4588         * modules/unistr/u32-cpy: New file.
4589         * lib/unistr/u8-cpy.c: New file.
4590         * lib/unistr/u16-cpy.c: New file.
4591         * lib/unistr/u32-cpy.c: New file.
4592         * lib/unistr/u-cpy.h: New file.
4593
4594         * modules/unistr/u8-cpy-alloc: New file.
4595         * modules/unistr/u16-cpy-alloc: New file.
4596         * modules/unistr/u32-cpy-alloc: New file.
4597         * lib/unistr/u8-cpy-alloc.c: New file.
4598         * lib/unistr/u16-cpy-alloc.c: New file.
4599         * lib/unistr/u32-cpy-alloc.c: New file.
4600         * lib/unistr/u-cpy-alloc.h: New file.
4601
4602         * modules/unistr/u8-endswith: New file.
4603         * modules/unistr/u16-endswith: New file.
4604         * modules/unistr/u32-endswith: New file.
4605         * lib/unistr/u8-endswith.c: New file.
4606         * lib/unistr/u16-endswith.c: New file.
4607         * lib/unistr/u32-endswith.c: New file.
4608         * lib/unistr/u-endswith.h: New file.
4609
4610         * modules/unistr/u8-mblen: New file.
4611         * modules/unistr/u16-mblen: New file.
4612         * modules/unistr/u32-mblen: New file.
4613         * lib/unistr/u8-mblen.c: New file.
4614         * lib/unistr/u16-mblen.c: New file.
4615         * lib/unistr/u32-mblen.c: New file.
4616
4617         * modules/unistr/u8-mbtouc: New file.
4618         * modules/unistr/u16-mbtouc: New file.
4619         * modules/unistr/u32-mbtouc: New file.
4620         * lib/unistr/u8-mbtouc.c: New file.
4621         * lib/unistr/u16-mbtouc.c: New file.
4622         * lib/unistr/u32-mbtouc.c: New file.
4623
4624         * modules/unistr/u8-mbtouc-safe: New file.
4625         * modules/unistr/u16-mbtouc-safe: New file.
4626         * modules/unistr/u32-mbtouc-safe: New file.
4627         * lib/unistr/u8-mbtouc-safe.c: New file.
4628         * lib/unistr/u16-mbtouc-safe.c: New file.
4629         * lib/unistr/u32-mbtouc-safe.c: New file.
4630
4631         * modules/unistr/u8-move: New file.
4632         * modules/unistr/u16-move: New file.
4633         * modules/unistr/u32-move: New file.
4634         * lib/unistr/u8-move.c: New file.
4635         * lib/unistr/u16-move.c: New file.
4636         * lib/unistr/u32-move.c: New file.
4637         * lib/unistr/u-move.h: New file.
4638
4639         * modules/unistr/u8-next: New file.
4640         * modules/unistr/u16-next: New file.
4641         * modules/unistr/u32-next: New file.
4642         * lib/unistr/u8-next.c: New file.
4643         * lib/unistr/u16-next.c: New file.
4644         * lib/unistr/u32-next.c: New file.
4645
4646         * modules/unistr/u8-prev: New file.
4647         * modules/unistr/u16-prev: New file.
4648         * modules/unistr/u32-prev: New file.
4649         * lib/unistr/u8-prev.c: New file.
4650         * lib/unistr/u16-prev.c: New file.
4651         * lib/unistr/u32-prev.c: New file.
4652
4653         * modules/unistr/u8-set: New file.
4654         * modules/unistr/u16-set: New file.
4655         * modules/unistr/u32-set: New file.
4656         * lib/unistr/u8-set.c: New file.
4657         * lib/unistr/u16-set.c: New file.
4658         * lib/unistr/u32-set.c: New file.
4659         * lib/unistr/u-set.h: New file.
4660
4661         * modules/unistr/u8-startswith: New file.
4662         * modules/unistr/u16-startswith: New file.
4663         * modules/unistr/u32-startswith: New file.
4664         * lib/unistr/u8-startswith.c: New file.
4665         * lib/unistr/u16-startswith.c: New file.
4666         * lib/unistr/u32-startswith.c: New file.
4667         * lib/unistr/u-startswith.h: New file.
4668
4669         * modules/unistr/u8-stpcpy: New file.
4670         * modules/unistr/u16-stpcpy: New file.
4671         * modules/unistr/u32-stpcpy: New file.
4672         * lib/unistr/u8-stpcpy.c: New file.
4673         * lib/unistr/u16-stpcpy.c: New file.
4674         * lib/unistr/u32-stpcpy.c: New file.
4675         * lib/unistr/u-stpcpy.h: New file.
4676
4677         * modules/unistr/u8-stpncpy: New file.
4678         * modules/unistr/u16-stpncpy: New file.
4679         * modules/unistr/u32-stpncpy: New file.
4680         * lib/unistr/u8-stpncpy.c: New file.
4681         * lib/unistr/u16-stpncpy.c: New file.
4682         * lib/unistr/u32-stpncpy.c: New file.
4683         * lib/unistr/u-stpncpy.h: New file.
4684
4685         * modules/unistr/u8-strcat: New file.
4686         * modules/unistr/u16-strcat: New file.
4687         * modules/unistr/u32-strcat: New file.
4688         * lib/unistr/u8-strcat.c: New file.
4689         * lib/unistr/u16-strcat.c: New file.
4690         * lib/unistr/u32-strcat.c: New file.
4691         * lib/unistr/u-strcat.h: New file.
4692
4693         * modules/unistr/u8-strchr: New file.
4694         * modules/unistr/u16-strchr: New file.
4695         * modules/unistr/u32-strchr: New file.
4696         * lib/unistr/u8-strchr.c: New file.
4697         * lib/unistr/u16-strchr.c: New file.
4698         * lib/unistr/u32-strchr.c: New file.
4699
4700         * modules/unistr/u8-strcmp: New file.
4701         * modules/unistr/u16-strcmp: New file.
4702         * modules/unistr/u32-strcmp: New file.
4703         * lib/unistr/u8-strcmp.c: New file.
4704         * lib/unistr/u16-strcmp.c: New file.
4705         * lib/unistr/u32-strcmp.c: New file.
4706
4707         * modules/unistr/u8-strcpy: New file.
4708         * modules/unistr/u16-strcpy: New file.
4709         * modules/unistr/u32-strcpy: New file.
4710         * lib/unistr/u8-strcpy.c: New file.
4711         * lib/unistr/u16-strcpy.c: New file.
4712         * lib/unistr/u32-strcpy.c: New file.
4713         * lib/unistr/u-strcpy.h: New file.
4714
4715         * modules/unistr/u8-strcspn: New file.
4716         * modules/unistr/u16-strcspn: New file.
4717         * modules/unistr/u32-strcspn: New file.
4718         * lib/unistr/u8-strcspn.c: New file.
4719         * lib/unistr/u16-strcspn.c: New file.
4720         * lib/unistr/u32-strcspn.c: New file.
4721         * lib/unistr/u-strcspn.h: New file.
4722
4723         * modules/unistr/u8-strdup: New file.
4724         * modules/unistr/u16-strdup: New file.
4725         * modules/unistr/u32-strdup: New file.
4726         * lib/unistr/u8-strdup.c: New file.
4727         * lib/unistr/u16-strdup.c: New file.
4728         * lib/unistr/u32-strdup.c: New file.
4729         * lib/unistr/u-strdup.h: New file.
4730
4731         * modules/unistr/u8-strlen: New file.
4732         * modules/unistr/u16-strlen: New file.
4733         * modules/unistr/u32-strlen: New file.
4734         * lib/unistr/u8-strlen.c: New file.
4735         * lib/unistr/u16-strlen.c: New file.
4736         * lib/unistr/u32-strlen.c: New file.
4737         * lib/unistr/u-strlen.h: New file.
4738
4739         * modules/unistr/u8-strmblen: New file.
4740         * modules/unistr/u16-strmblen: New file.
4741         * modules/unistr/u32-strmblen: New file.
4742         * lib/unistr/u8-strmblen.c: New file.
4743         * lib/unistr/u16-strmblen.c: New file.
4744         * lib/unistr/u32-strmblen.c: New file.
4745
4746         * modules/unistr/u8-strmbtouc: New file.
4747         * modules/unistr/u16-strmbtouc: New file.
4748         * modules/unistr/u32-strmbtouc: New file.
4749         * lib/unistr/u8-strmbtouc.c: New file.
4750         * lib/unistr/u16-strmbtouc.c: New file.
4751         * lib/unistr/u32-strmbtouc.c: New file.
4752
4753         * modules/unistr/u8-strncat: New file.
4754         * modules/unistr/u16-strncat: New file.
4755         * modules/unistr/u32-strncat: New file.
4756         * lib/unistr/u8-strncat.c: New file.
4757         * lib/unistr/u16-strncat.c: New file.
4758         * lib/unistr/u32-strncat.c: New file.
4759         * lib/unistr/u-strncat.h: New file.
4760
4761         * modules/unistr/u8-strncmp: New file.
4762         * modules/unistr/u16-strncmp: New file.
4763         * modules/unistr/u32-strncmp: New file.
4764         * lib/unistr/u8-strncmp.c: New file.
4765         * lib/unistr/u16-strncmp.c: New file.
4766         * lib/unistr/u32-strncmp.c: New file.
4767
4768         * modules/unistr/u8-strncpy: New file.
4769         * modules/unistr/u16-strncpy: New file.
4770         * modules/unistr/u32-strncpy: New file.
4771         * lib/unistr/u8-strncpy.c: New file.
4772         * lib/unistr/u16-strncpy.c: New file.
4773         * lib/unistr/u32-strncpy.c: New file.
4774         * lib/unistr/u-strncpy.h: New file.
4775
4776         * modules/unistr/u8-strnlen: New file.
4777         * modules/unistr/u16-strnlen: New file.
4778         * modules/unistr/u32-strnlen: New file.
4779         * lib/unistr/u8-strnlen.c: New file.
4780         * lib/unistr/u16-strnlen.c: New file.
4781         * lib/unistr/u32-strnlen.c: New file.
4782         * lib/unistr/u-strnlen.h: New file.
4783
4784         * modules/unistr/u8-strpbrk: New file.
4785         * modules/unistr/u16-strpbrk: New file.
4786         * modules/unistr/u32-strpbrk: New file.
4787         * lib/unistr/u8-strpbrk.c: New file.
4788         * lib/unistr/u16-strpbrk.c: New file.
4789         * lib/unistr/u32-strpbrk.c: New file.
4790         * lib/unistr/u-strpbrk.h: New file.
4791
4792         * modules/unistr/u8-strrchr: New file.
4793         * modules/unistr/u16-strrchr: New file.
4794         * modules/unistr/u32-strrchr: New file.
4795         * lib/unistr/u8-strrchr.c: New file.
4796         * lib/unistr/u16-strrchr.c: New file.
4797         * lib/unistr/u32-strrchr.c: New file.
4798
4799         * modules/unistr/u8-strspn: New file.
4800         * modules/unistr/u16-strspn: New file.
4801         * modules/unistr/u32-strspn: New file.
4802         * lib/unistr/u8-strspn.c: New file.
4803         * lib/unistr/u16-strspn.c: New file.
4804         * lib/unistr/u32-strspn.c: New file.
4805         * lib/unistr/u-strspn.h: New file.
4806
4807         * modules/unistr/u8-strstr: New file.
4808         * modules/unistr/u16-strstr: New file.
4809         * modules/unistr/u32-strstr: New file.
4810         * lib/unistr/u8-strstr.c: New file.
4811         * lib/unistr/u16-strstr.c: New file.
4812         * lib/unistr/u32-strstr.c: New file.
4813         * lib/unistr/u-strstr.h: New file.
4814
4815         * modules/unistr/u8-strtok: New file.
4816         * modules/unistr/u16-strtok: New file.
4817         * modules/unistr/u32-strtok: New file.
4818         * lib/unistr/u8-strtok.c: New file.
4819         * lib/unistr/u16-strtok.c: New file.
4820         * lib/unistr/u32-strtok.c: New file.
4821         * lib/unistr/u-strtok.h: New file.
4822
4823         * modules/unistr/u8-uctomb: New file.
4824         * modules/unistr/u16-uctomb: New file.
4825         * modules/unistr/u32-uctomb: New file.
4826         * lib/unistr/u8-uctomb.c: New file.
4827         * lib/unistr/u16-uctomb.c: New file.
4828         * lib/unistr/u32-uctomb.c: New file.
4829
4830         * MODULES.html.sh (Unicode string functions): Add the new modules.
4831
4832 2007-01-08  Bruno Haible  <bruno@clisp.org>
4833
4834         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
4835         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
4836         subdirectories.
4837
4838 2007-01-08  Karl Berry  <karl@gnu.org>
4839
4840         * doc/error.texi: mention that main() fns must set program_name
4841         when progname is used.
4842
4843 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
4844
4845         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
4846         WCTYPE_H is empty, for the benefit of builds from non-distclean
4847         directories.  Problem reported by Eric Blake in
4848         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
4849
4850 2007-01-08  Bruno Haible  <bruno@clisp.org>
4851
4852         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
4853         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
4854         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
4855         PROVIDE_CANONICALIZE_FILENAME_MODE.
4856         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
4857
4858 2007-01-08  Bruno Haible  <bruno@clisp.org>
4859
4860         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
4861         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
4862         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
4863         * lib/fts.c: Likewise.
4864         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
4865
4866 2006-12-25  Bruno Haible  <bruno@clisp.org>
4867
4868         * modules/utf8-ucs4-safe: New file.
4869         * lib/utf8-ucs4-safe.h: New file.
4870         * lib/unistr/utf8-ucs4-safe.c: New file.
4871
4872         * modules/utf16-ucs4-safe: New file.
4873         * lib/utf16-ucs4-safe.h: New file.
4874         * lib/unistr/utf16-ucs4-safe.c: New file.
4875
4876         * MODULES.html.sh (Unicode string functions): Add the new modules.
4877
4878 2007-01-08  Bruno Haible  <bruno@clisp.org>
4879
4880         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
4881         (Depends-on): Add unitypes.
4882         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
4883         (u8_mbtouc_aux): Move out to separate file.
4884         (u8_mbtouc): Use ucs4_t, uint8_t types.
4885         * lib/unistr/utf8-ucs4.c: New file.
4886
4887         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
4888         (Depends-on): Add unitypes.
4889         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
4890         (u16_mbtouc_aux): Move out to separate file.
4891         (u16_mbtouc): Use ucs4_t, uint16_t types.
4892         * lib/unistr/utf16-ucs4.c: New file.
4893
4894         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
4895         (Depends-on): Add unitypes.
4896         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
4897         (u8_uctomb_aux): Move out to separate file.
4898         (u8_uctomb): Use ucs4_t, uint8_t types.
4899         * lib/unistr/ucs4-utf8.c: New file.
4900
4901         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
4902         (Depends-on): Add unitypes.
4903         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
4904         (u16_uctomb_aux): Move out to separate file.
4905         (u16_uctomb): Use ucs4_t, uint16_t types.
4906         * lib/unistr/ucs4-utf16.c: New file.
4907
4908 2006-12-25  Bruno Haible  <bruno@clisp.org>
4909
4910         * modules/unitypes: New file.
4911         * lib/unitypes.h: New file.
4912         * MODULES.html.sh (func_all_modules): New section "Unicode string
4913         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
4914         this section. Add unitypes.
4915
4916 2007-01-08  Bruno Haible  <bruno@clisp.org>
4917
4918         Avoid variable names that conflict with those from libtool.
4919         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
4920         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
4921         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
4922         library_names_spec to acl_library_names_spec, hardcode_* to
4923         acl_hardcode_*.
4924         Reported by Ralf Wildenhues.
4925
4926 2007-01-08  Bruno Haible  <bruno@clisp.org>
4927
4928         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
4929         definition.
4930         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
4931         definition.
4932         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
4933         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
4934         definition.
4935         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
4936         definition.
4937         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
4938         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
4939         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
4940         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
4941         definition.
4942         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
4943         definition.
4944         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
4945         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
4946         GC_USE_<algorithm>.
4947         * lib/gc-libgcrypt.c: Likewise.
4948         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
4949         * modules/gc-arctwo (configure.ac): Likewise.
4950         * modules/gc-des (configure.ac): Likewise.
4951         * modules/gc-hmac-md5 (configure.ac): Likewise.
4952         * modules/gc-hmac-sha1 (configure.ac): Likewise.
4953         * modules/gc-md2 (configure.ac): Likewise.
4954         * modules/gc-md4 (configure.ac): Likewise.
4955         * modules/gc-md5 (configure.ac): Likewise.
4956         * modules/gc-random (configure.ac): Likewise.
4957         * modules/gc-rijndael (configure.ac): Likewise.
4958         * modules/gc-sha1 (configure.ac): Likewise.
4959
4960 2007-01-08  Bruno Haible  <bruno@clisp.org>
4961
4962         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
4963         macro definition.
4964         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
4965         definition.
4966         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
4967         definition.
4968         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
4969         * modules/fcntl-safer (configure.ac): Likewise.
4970         * modules/fopen-safer (configure.ac): Likewise.
4971         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
4972         GNULIB_FWRITEERROR macro definition.
4973
4974 2007-01-08  Bruno Haible  <bruno@clisp.org>
4975
4976         * m4/gnulib-common.m4: New file.
4977         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
4978         (func_get_filelist): Add m4/gnulib-common.m4.
4979
4980 2007-01-08  Bruno Haible  <bruno@clisp.org>
4981
4982         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
4983         command.
4984
4985 2007-01-08  Jim Meyering  <jim@meyering.net>
4986
4987         Use a more robust test for a "can't happen" condition.
4988         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
4989         narrowed the st_size value.  Presuming the "can't happen" condition
4990         is true, that narrowing could conceivably convert an invalid st_size
4991         value into a valid one.  Instead, use a change based on Matthew
4992         Woehlke's original patch.
4993
4994         Slight readability improvement: use an assert-like macro
4995         in place of literal "abort ()" uses.
4996         * lib/fts.c (fts_assert): Define.
4997         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
4998         Use this macro instead of a bare 'abort'.
4999
5000 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
5001
5002         Don't worry about using IRIX 5.3's wctype.h broken definitions;
5003         simply work around them.
5004         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
5005         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
5006         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
5007         declaring.
5008         Don't bother to define as macros, since the standard doesn't require it.
5009         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
5010         longer worry about IRIX 5.3.
5011         (HAVE_WCTYPE_CTMP_BUG): Remove.
5012
5013 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
5014
5015         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
5016         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
5017         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
5018         Problems reported by Georg Schwarz for IRIX 5.3.
5019
5020         * gnulib-tool (autoconf_minversion): Take the maximum version number
5021         found, not the minimum.  Problem reported by James Youngman.
5022
5023 2007-01-03  Karl Berry  <karl@gnu.org>
5024
5025         * doc/error.texi: new file, explaining interaction with progname.
5026         * doc/gnulib.texi: include it.  Update copyright.
5027
5028 2007-01-03  Simon Josefsson  <simon@josefsson.org>
5029
5030         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
5031         AC_CANONICAL_HOST, to improve autobuild outputs.
5032
5033 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
5034             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
5035
5036         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
5037         sockets, server sockets, and other file descriptors.  Count errors
5038         to compute the return value.  Reorder the code a bit to be easier
5039         to follow.  Don't set event bits that were not requested (except
5040         POLLERR and POLLHUP).
5041
5042 2007-01-01  Bruno Haible  <bruno@clisp.org>
5043
5044         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
5045
5046 2007-01-03  Jim Meyering  <jim@meyering.net>
5047
5048         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
5049
5050 2007-01-02  Bruno Haible  <bruno@clisp.org>
5051
5052         * modules/settime (Include): Require timespec.h.
5053         * modules/nanosleep (Include): Likewise.
5054
5055 2007-01-01  Bruno Haible  <bruno@clisp.org>
5056
5057         * gnulib-tool (func_emit_copyright_notice): Bump year.
5058         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
5059
5060 2007-01-01  Bruno Haible  <bruno@clisp.org>
5061
5062         Improve support for OpenBSD.
5063         * build-aux/config.rpath (libname_spec): Export.
5064         (library_names_spec): New variable. Export.
5065         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
5066         library_names_spec from the config.rpath output. Locate shared library
5067         through the name pattern in library_names_spec.
5068
5069 2007-01-01  Eric Blake  <ebb9@byu.net>
5070
5071         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
5072
5073 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
5074
5075         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
5076         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
5077         assume the C locale, and avoid an "eval" that could cause trouble.
5078         Problem with SORT reported by Bob Proulx.
5079
5080         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
5081         Define.  Trivial patch from Henning Nielsen Lund, originally
5082         sent to bug-grep@gnu.org today.
5083
5084 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
5085
5086         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
5087         struct stat.  Problem reported by Henning Nielsen Lund.
5088         * lib/acl.c: Include acl.h first, to check interface.  Don't
5089         bother to include sys/types.h and sys/stat.h again.
5090
5091 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
5092
5093         Import the following change from libc; problem reported by
5094         Sven Verdoolaege.
5095
5096         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
5097
5098         [BZ #1373]
5099         * lib/argp.h: Remove __NTH for __argp_usage inline function.
5100
5101 2006-12-28  Jim Meyering  <jim@meyering.net>
5102
5103         * build-aux/announce-gen: Do not assume that the package
5104         builds any of tar.gz, tar.bz2, and .xdelta files.
5105         Suggestion from Simon Josefsson.
5106
5107 2006-12-28  Simon Josefsson  <simon@josefsson.org>
5108
5109         * modules/announce-gen: New file.
5110
5111 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
5112
5113         * lib/mbchar.h: Just include <wctype.h>; the wctype module
5114         handles its gotchas now.
5115         * lib/mbswidth.c: Likewise.
5116         * lib/wcwidth.h: Likewise.
5117         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
5118         and iswcntrl; the wctype module does this stuff now.
5119         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
5120         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
5121         * modules/mbchar (Depends-on): Add wctype.
5122         * modules/mbswidth (Depends-on): Likewise.
5123         * modules/wcwidth (Depends-on): Likewise.
5124
5125 2006-12-27  Eric Blake  <ebb9@byu.net>
5126
5127         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
5128         module uses more than what <wctype.h> is required to provide.
5129
5130 2006-12-26  Eric Blake  <ebb9@byu.net>
5131
5132         * gnulib-tool (sed_extract_prog): Avoid space-tab.
5133
5134 2006-12-26  Eric Blake  <ebb9@byu.net>
5135
5136         * modules/absolute-header: New module.
5137         * modules/fcntl (Depends-on): Depend on it.
5138         * modules/inttypes (Depends-on): Likewise.
5139         * modules/stdint (Depends-on): Likewise.
5140         * modules/sys_stat (Depends-on): Likewise.
5141         * modules/wctype (Depends-on): Likewise.
5142         * MODULES.html.sh (Support for building libraries and
5143         executables): Document it.
5144
5145 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
5146
5147         * gnulib-tool (SED): Remove, undoing previous change.
5148         The problem was that it broke coreutils on Solaris, because
5149         "sed --posix" leaked into a makefile.
5150         (sed): New alias, if 'alias' and GNU sed.
5151
5152 2006-12-24  Jim Meyering  <jim@meyering.net>
5153
5154         Work around an fchownat bug in glibc-2.4:
5155         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
5156         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
5157         in spite of the -P option.
5158         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
5159         New macros.
5160         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
5161         * modules/openat (Files): Add lib/fchownat.c.
5162         * lib/openat.c (fchownat): Don't define here.  Move to...
5163         * lib/fchownat.c: ...this new file.
5164
5165 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
5166
5167         Fix bug reported by Bruno Haible in
5168         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
5169         where quotearg.c didn't compile on Mac OS X 10.2 because it
5170         lacks <wchar.h> and wint_t.
5171         * lib/wctype_.h (__wctype_wint_t): New type.
5172         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
5173         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
5174         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
5175         Arg is now of type __wctype_wint_t, not wint_t.
5176         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
5177         substitute HAVE_WINT_T.
5178         * modules/wctype (Files): Add m4/wint_t.m4.
5179         (wctype.h): Substitute HAVE_WINT_T.
5180
5181 2006-12-23  Bruno Haible  <bruno@clisp.org>
5182
5183         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
5184
5185 2006-12-23  Bruno Haible  <bruno@clisp.org>
5186
5187         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
5188         S_ISLNK.
5189         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
5190         mingw.
5191
5192 2006-12-22  Bruno Haible  <bruno@clisp.org>
5193
5194         * lib/copy-file.c: Include acl.h.
5195         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
5196         Close the file descriptors only after being done with copy_acl.
5197         * modules/copy-file (Depends-on): Add acl.
5198
5199 2006-12-22  Bruno Haible  <bruno@clisp.org>
5200
5201         * gnulib-tool (SED): New variable.
5202         Use $SED instead of sed everywhere.
5203
5204 2006-12-22  Bruno Haible  <bruno@clisp.org>
5205
5206         * modules/no-c++: New file.
5207         * m4/no-c++.m4: New file.
5208         * MODULES.html.sh (Support for building libraries and executables):
5209         Add no-c++.
5210
5211 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
5212
5213         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
5214         Include <limits.h>, and use its INT_MAX to rewrite the
5215         j loop so that it does not overflow 'int'.  Problem reported by
5216         Ralf Wildenhues in
5217         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
5218         Play it safe by shifting left by 1 rather than multiplying by 2,
5219         as GCC is less likely to optimize this away when the value
5220         is signed (when it assumes overflow leads to undefined behavior).
5221         Also, don't assume time_t uses two's complement.
5222
5223 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
5224
5225         * MODULES.html.sh: New module wctype.
5226         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
5227         * lib/fnmatch.c: Don't bother to include <wchar.h> before
5228         <wctype.h>, since the new wctype module should fix this.
5229         * lib/quotearg.c: Include <wctype.h> unconditionally, since
5230         the wctype module should arrange for it.
5231         * lib/regex_internal.h: Likewise.
5232         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
5233         since the wctype module should handle this now.
5234         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
5235         * modules/fnmatch (Depends-on): Add wctype.
5236         * modules/quotearg (Depends-on): Likewise.
5237         * modules/regex (Depends-on): Likewise.
5238
5239 2006-12-19  Bruno Haible  <bruno@clisp.org>
5240
5241         * lib/strdup.h [C++]: Wrap definitions in extern "C".
5242         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
5243
5244 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5245
5246         * modules/savewd (Depends-on): Fix dependency on fcntl.
5247
5248 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
5249
5250         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
5251         conforms to C99, rather than relying on the user's environment
5252         setting of STDINT_H.
5253
5254 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
5255         and Eric Blake  <ebb9@byu.net>
5256
5257         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
5258         This is more consistent with the other defines here.
5259         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
5260         Port to z/OS.  Problem reported by Paul Gilmartin.
5261         Change local vars to use gl_ prefix rather than ac_.
5262         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
5263         with other defines.
5264         * modules/double-slash-root: New module.
5265         * modules/dirname (Files): Remove m4/double-slash-root.m4.
5266         (Depends-on): Add double-slash-root.
5267         * MODULES.html.sh (File system functions): Mention new module.
5268
5269 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
5270
5271         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
5272         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
5273         This is for the benefit of gzip, which doesn't do i18n.
5274
5275 2006-12-12  Jim Meyering  <jim@meyering.net>
5276
5277         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
5278         Reported by Andreas Schwab <schwab@suse.de>.
5279
5280 2006-12-12  Bruno Haible  <bruno@clisp.org>
5281
5282         Merge these changes.
5283         2006-09-05  Bruno Haible  <bruno@clisp.org>
5284         * lib/iconvme.c (iconv_string): No need to save and restore errno when
5285         iconv_alloc succeeded.
5286         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
5287         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
5288         test for " && dest " at the end - dest is always != NULL there. Call
5289         iconv with 4xNULL arguments initially, to reset the state. Call iconv
5290         with 2xNULL arguments, also to flush the state storage. Handle the
5291         IRIX iconv behaviour. Realloc the final result, to throw away unused
5292         memory.
5293
5294 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
5295
5296         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
5297         and fchmodat unconditionally, since glibc 2.4 has them.
5298         Problem reported by Arkadiusz Miskiewicz.
5299
5300 2006-12-10  Bruno Haible  <bruno@clisp.org>
5301
5302         * gnulib-tool (func_import): Show the include files only for those
5303         modules that are copied and specified.
5304         Reported by Karl Berry.
5305
5306 2006-12-08  Jim Meyering  <jim@meyering.net>
5307
5308         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
5309         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
5310
5311         * build-aux/announce-gen: Add two new options, both optional:
5312         --bootstrap-tools=TOOL_LIST
5313               a comma-separated list of tools, e.g.,
5314               autoconf,automake,bison,gnulib
5315         --gnulib-snapshot-date=DATE
5316               if gnulib is in the bootstrap tool list,
5317               then report this as the snapshot date.
5318               If not specified, use the current date/time.
5319               If you specify a date here, be sure it's UTC.
5320
5321 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5322
5323         * tests/test-argp-2.sh: Fix test to match actual output.
5324         (func_compare): Fix sed script to be portable.
5325
5326 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
5327
5328         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
5329         workaround for this case.  It is not autoconfigured now; offhand
5330         it's hard to see how to autoconfigure it.
5331
5332 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
5333
5334         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
5335         a directory that is about to be chowned.  Such a directory's
5336         initial file permissions should permit the owner only and this
5337         should not be changed until after the chown, since the group and
5338         other bits would be incorrect if they granted permission before
5339         the chown.
5340
5341         Fix porting problem for iswctype reported by Georg Schwarz in:
5342         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
5343         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
5344         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
5345         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
5346         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
5347
5348 2006-12-03  Jim Meyering  <jim@meyering.net>
5349
5350         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
5351         p->fts_statp may not yet be defined.
5352         (fts_read): Instead, set it in the caller, once p->fts_statp is
5353         sure to be defined, and corresponds to a top-level directory.
5354         This bug made du -x fail.  Here's the coreutils test case:
5355         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
5356         Reported by Mike Frysinger.
5357
5358 2006-12-01  Jim Meyering  <jim@meyering.net>
5359
5360         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
5361         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
5362         Reported by Simon Josefsson.
5363
5364 2006-11-30  Jim Meyering  <jim@meyering.net>
5365
5366         * m4/warning.m4: Use the all-permissive copyright notice
5367         recommended by RMS (rather than LGPL).
5368         * m4/vararrays.m4: Likewise.
5369         * m4/flexmember.m4: Likewise.
5370
5371 2006-11-29  Bruno Haible  <bruno@clisp.org>
5372
5373         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
5374         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
5375         using +=.
5376         Reported by Simon Josefsson <simon@josefsson.org>.
5377
5378 2006-11-28  James Youngman <jay@gnu.org>
5379
5380         * README: Advise users that they might find the bug-gnulib@gnu.org
5381         and autotools-announce@gnu.org mailing lists useful.
5382
5383 2006-11-28  Bruno Haible  <bruno@clisp.org>
5384
5385         * m4/ptrdiff_max.m4: Remove file.
5386
5387 2006-11-21  Bruno Haible  <bruno@clisp.org>
5388
5389         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
5390         _AC_COMPUTE_INT.
5391         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5392         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
5393         _AC_COMPUTE_INT.
5394         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5395         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
5396         _AC_COMPUTE_INT.
5397         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5398
5399 2006-11-28  Jim Meyering  <jim@meyering.net>
5400
5401         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
5402         warning from "gcc -Wshadow" about shadowing the builtin.
5403
5404 2006-11-27  Bruno Haible  <bruno@clisp.org>
5405
5406         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
5407         _AC_COMPUTE_INT.
5408         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5409
5410 2006-11-27  Bruno Haible  <bruno@clisp.org>
5411             Paul Eggert  <eggert@cs.ucla.edu>
5412
5413         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
5414
5415 2006-11-26  Bruno Haible  <bruno@clisp.org>
5416
5417         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
5418         noinst_LTLIBRARIES.
5419
5420 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
5421             Bruno Haible  <bruno@clisp.org>
5422
5423         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
5424         if compiling with "gcc -ansi".
5425
5426 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
5427
5428         Fix some incompatibilities with gcc -ansi -pedantic.
5429         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
5430         if compiling pedantically with GCC, unless it's C99 or later.
5431         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
5432         it mishandles gcc -ansi -pedantic as well.
5433         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
5434         if gcc -pedantic.
5435         * lib/regexec.c (check_node_accept_bytes): Don't use auto
5436         initializers for struct if -pedantic, unless it's C99 or later.
5437
5438 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
5439
5440         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
5441         Don't close an fd more than once. Identical atimes indicate
5442         success, not failure.
5443
5444 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
5445
5446         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
5447
5448 2006-11-23  Jim Meyering  <jim@meyering.net>
5449
5450         * build-aux/announce-gen: New file.  From coreutils.
5451
5452 2006-11-22  Jim Meyering  <jim@meyering.net>
5453
5454         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
5455         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
5456         (fts_read): Use a temporary to narrow the overused st_size member
5457         before using it in a switch statement.  Reported by Matthew Woehlke.
5458
5459         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
5460         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
5461
5462 2006-11-20  Bruno Haible  <bruno@clisp.org>
5463
5464         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
5465         changequote instead of pairs of brackets.
5466         Reported by Andreas Schwab <schwab@suse.de>.
5467
5468 2006-11-21  Jim Meyering  <jim@meyering.net>
5469
5470         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
5471         so as to remain compatible with older compilers.
5472         Patch from Michael Deutschmann.
5473
5474 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
5475
5476         * MODULES.html.sh (File system functions): Add openat.
5477
5478         * lib/openat.h (rpl_fstatat): New macro, if
5479         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
5480         (fstatat): Define to rpl_fstatat under the same conditions,
5481         unless COMPILING_FSTATAT.
5482         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
5483         seems to have the bug.
5484         * lib/fstatat.c: New file.
5485         * modules/openat (Files): Add it.
5486
5487 2006-11-20  Bruno Haible  <bruno@clisp.org>
5488
5489         * Makefile: New file.
5490
5491 2006-11-20  Jim Meyering  <jim@meyering.net>
5492
5493         The beginnings of syntax-related checks for gnulib.
5494         * lib/Makefile: New file.
5495         * lib/t-idcache: New script.  Ensure that the two halves of
5496         idcache.c stay in sync.
5497
5498         * lib/idcache.c: Adjust comments in user- and group- portions to
5499         be more accurate, and to be consistent with one another.
5500
5501 2006-11-20  Jim Meyering  <jim@meyering.net>
5502
5503         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
5504         continue using the flexible array member (thus, this module performs
5505         half as many malloc calls), with the addition that...
5506         (getgroup, getuser): Consistently record a non-match via an empty
5507         "name" string, and map an empty string match to a NULL return value.
5508         * modules/idcache (Depends-on): Re-add flexmember.
5509
5510         * lib/idcache.c (getuser): Remove all uses of the register keyword.
5511         (getuidbyname, getgroup, getgidbyname): Likewise.
5512
5513         Use cleaner syntax: NULL rather than 0.
5514         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
5515
5516 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
5517
5518         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
5519         It mishandled the case where the group was missing.
5520         Problem reported by Greg Schafer.
5521         * modules/idcache: Likewise.
5522
5523 2006-11-18  Jim Meyering  <jim@meyering.net>
5524
5525         * check-module (%exempt_header): Add exception for some
5526         conditionally-included headers.
5527
5528         * modules/i-ring (Depends-on): Add verify.
5529         (License): Change to LGPL.
5530
5531 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
5532
5533         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
5534         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
5535         and inttostr.h.  Use snprintf rather than uinttostr, so that
5536         LGPLed code doesn't depend on GPLed.
5537
5538 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
5539
5540         * modules/inline (License): Change from GPL to LGPL.
5541
5542 2006-11-17  Jim Meyering  <jim@meyering.net>
5543
5544         * modules/d-type (License): Switch to LGPL.
5545
5546 2006-11-15  Bruno Haible  <bruno@clisp.org>
5547
5548         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
5549
5550 2006-11-15  Eric Blake  <ebb9@byu.net>
5551
5552         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
5553         the module dependency.
5554
5555 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5556             Bruno Haible  <bruno@clisp.org>
5557
5558         * gnulib-tool (func_create_testdir): Add license consistency check.
5559
5560 2006-11-15  Eric Blake  <ebb9@byu.net>
5561
5562         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
5563         random "(cached)" in configure output.
5564
5565 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5566
5567         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
5568         test for conforming inttypes.h is both announced and cached.
5569
5570         * MODULES.html.sh (seen_modules, seen_files): New variables.
5571         (func_module): Rewrite to use a few less gnulib-tool and sed
5572         invocations.  Avoid a couple of quadratic algorithms for ...
5573         (missed_modules, missed_files): ... these, with ...
5574         (func_append, func_tmpdir): ... these new functions, from
5575         gnulib-tool.  Analogously, install traps for cleanup.
5576
5577         * tests/test-gc.c (main): Remove unused variables.
5578         * tests/test-read-file.c: Include stdlib.h, for 'free'.
5579
5580 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
5581
5582         * modules/inttostr (License): Change to LGPL.
5583
5584 2006-11-14  Eric Blake  <ebb9@byu.net>
5585
5586         * modules/tempname (License): Change to LGPL.
5587
5588 2006-11-14  Eric Blake  <ebb9@byu.net>
5589
5590         * doc/functions.texi (Function Portability): *printf functions on
5591         Cygwin now understand all POSIX size specifiers.
5592
5593 2006-11-14  Bruno Haible  <bruno@clisp.org>
5594
5595         * modules/c-ctype (License): Change to LGPL.
5596
5597 2006-11-12  Bruno Haible  <bruno@clisp.org>
5598
5599         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
5600         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
5601         for GNOME libraries, for which the include files are installed in
5602         subdirectories of $prefix/include.
5603
5604 2006-11-12  Bruno Haible  <bruno@clisp.org>
5605
5606         * m4/lib-link.m4: Require at least autoconf-2.54.
5607         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
5608         name to underscores for the --with option.
5609
5610 2006-11-13  Bruno Haible  <bruno@clisp.org>
5611
5612         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
5613         the tests directory.
5614         Reported by Ralf Wildenhues.
5615
5616 2006-11-13  Bruno Haible  <bruno@clisp.org>
5617
5618         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
5619         (func_emit_initmacro_end): Undo the override here.
5620         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
5621         Works around the famous automake error in coreutils.
5622
5623 2006-11-13  Eric Blake  <ebb9@byu.net>
5624
5625         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
5626         element, not its node.
5627
5628 2006-11-12  Bruno Haible  <bruno@clisp.org>
5629
5630         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
5631         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
5632
5633 2006-11-12  Bruno Haible  <bruno@clisp.org>
5634
5635         * gnulib-tool: New option --local-symlink.
5636         (func_usage): Document it.
5637         (lsymbolic): New variable.
5638         (func_import, func_create_testdir): If --symlink was not specified,
5639         test whether --local-symlink was specified and the file comes from
5640         the local_gnulib_dir.
5641
5642 2006-11-12  Bruno Haible  <bruno@clisp.org>
5643
5644         * gnulib-tool (func_ln): New function.
5645         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
5646
5647 2006-11-12  Bruno Haible  <bruno@clisp.org>
5648
5649         Finish support for source files in subdirectories.
5650         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
5651         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
5652         AUTOMAKE_OPTIONS.
5653         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
5654
5655 2006-11-12  Bruno Haible  <bruno@clisp.org>
5656
5657         * gnulib-tool (func_get_automake_snippet): Synthesize also an
5658         EXTRA_lib_SOURCES augmentation.
5659         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
5660
5661 2006-11-12  Jim Meyering  <jim@meyering.net>
5662
5663         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
5664         file descriptors.  This also averts a failure on systems with
5665         native openat support when a traversed directory lacks "x" access.
5666         * lib/fts_.h: Include "i-ring.h"
5667         (struct FTS) [fts_fd_ring]: New member.
5668         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
5669         (FCHDIR): Add parentheses.
5670         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
5671         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
5672         When descending, rather than simply closing the previous
5673         fts_cwd_fd value, push that file descriptor onto the ring.
5674         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
5675         (fts_open): Initialize the new fd_ring member.
5676         (fts_close): Clear the ring.
5677         (fts_safe_changedir): When possible, use our new fd_ring to skip
5678         the diropen and fstat and dev/ino comparison that would normally
5679         accompany a virtual `chdir ("..")'.
5680
5681         * modules/fts (Depends-on): Add i-ring.
5682         * modules/i-ring: New module.
5683         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
5684         * m4/i-ring.m4: New file.
5685
5686 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5687
5688         * gnulib-tool (func_create_testdir): Fix replacement of
5689         `build-aux' in configure.ac.  Run autotools in gltests
5690         subdirectory.
5691         (func_create_testdir, func_create_megatestdir, test): There is
5692         no need for '--force' in most autotool invocations in a new
5693         tree.  Actually fail the whole test if any of the tools, or the
5694         configure or make stages fail.
5695
5696         Sync from Automake.
5697         * build-aux/gnupload: Revert last change.  Add pointer to upload
5698         instructions of the GNU Maintenance Instructions.
5699         Suggestion by Karl Berry.
5700
5701 2006-11-10  Jim Meyering  <jim@meyering.net>
5702
5703         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
5704
5705 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5706
5707         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
5708         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
5709         (bind_textdomain_codeset) [! ENABLE_NLS]:
5710         Evaluate all the arguments.  That way, callers get compatible behavior
5711         if the arguments have side effects.  Also, it avoids some GCC
5712         diagnostics in some cases; Joel E. Denny reported problems when Bison
5713         was configured with --enable-gcc-warnigs.
5714
5715 2006-11-10  Jim Meyering  <jim@meyering.net>
5716
5717         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
5718         relevant options in CFLAGS (like -O, -fno-inline) are taken into
5719         account.
5720
5721 2006-11-10  Jim Meyering  <jim@meyering.net>
5722
5723         * modules/inline: New file/module.
5724         * modules/xalloc (Files): Remove m4/inline.m4.
5725         (Depends-on): Add inline, instead.
5726         * modules/oset: Likewise.
5727         * modules/list: Likewise.
5728
5729 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5730
5731         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
5732         Problem reported by Matthew Woehlke.
5733
5734 2006-11-09  Bruno Haible  <bruno@clisp.org>
5735
5736         * lib/tempname.c (gen_tempname): Remove variant that invokes
5737         __gen_tempname.
5738         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
5739         __gen_tempname.
5740
5741 2006-11-08  Bruno Haible  <bruno@clisp.org>
5742
5743         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
5744         to 'yes' instead of 'cross-compiling'.
5745
5746 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
5747
5748         * lib/quotearg.h (quotearg_free): New decl.
5749         * lib/quotearg.c (quotearg_free): New function.
5750         (slot0, nslots, slotvec0, slotvec):
5751         Now file-scope so that quotearg_free can get at them.
5752
5753 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5754
5755         Sync from Automake.
5756         * build-aux/gnupload: Add missing 'gnu' to example URL.
5757         Report by Karl Berry.
5758
5759 2006-11-08  Bruno Haible  <bruno@clisp.org>
5760
5761         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
5762         Suggested by Paul Eggert.
5763
5764 2006-11-08  Jim Meyering  <jim@meyering.net>
5765
5766         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
5767         It's already included if !_LIBC.
5768         (fts_safe_changedir): Add a comment.
5769
5770 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5771
5772         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
5773         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
5774         Matthew Woehlke.
5775
5776         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
5777         definitions up, to avoid colliding with change below.
5778         (static_inline) [HAVE_INLINE]: New macro.
5779         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
5780         Provide extern decls when !HAVE_INLINE.  Do not define unless
5781         static_inline is defined, either by us or by xmalloc.c.  Use
5782         static_inline rather than static inline.
5783         (XCALLOC): Optimize sizeof(T) = 1 case.
5784         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
5785
5786 2006-11-07  Bruno Haible  <bruno@clisp.org>
5787
5788         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
5789         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
5790         AC_C_INLINE.
5791         * modules/xalloc (Files): Add m4/inline.m4.
5792
5793 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5794
5795         * README: Fix typo.
5796         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
5797         (Miscellanous Notes): ...from this.
5798
5799 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5800
5801         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
5802         Mention that offsetof should be used instead of sizeof.
5803         From Bruno Haible.
5804
5805 2006-11-07  Bruno Haible  <bruno@clisp.org>
5806
5807         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
5808
5809 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
5810
5811         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
5812         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
5813         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
5814         (gl_tree_add_before, gl_tree_add_after):
5815         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
5816         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
5817         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
5818         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
5819         (gl_linked_add_after, gl_linked_add_at): Likewise.
5820         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
5821         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
5822         (gl_tree_add_before, gl_tree_add_after): Likewise.
5823         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
5824         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
5825         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
5826
5827 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5828
5829         * lib/gl_oset.h: Use C comment style, not C++ comment style.
5830
5831 2006-11-06  Bruno Haible  <bruno@clisp.org>
5832
5833         * m4/inline.m4: New file.
5834         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
5835         * modules/list (Files): Add m4/inline.m4.
5836         * modules/oset (Files): Likewise.
5837
5838 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
5839
5840         * lib/idcache.c: Include <stddef.h>, for offsetof.
5841         (struct userid.name): Change from char * to a flexible array member.
5842         All uses changed.
5843         * modules/idcache (Depends-on): Add flexmember.
5844
5845         * MODULES.html.sh (Core language properties): New module flexmember.
5846         * modules/flexmember, m4/flexmember.m4: New files.
5847
5848         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
5849         inline functions that are identical with the old xnmalloc_inline,
5850         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
5851         that we can avoid some unnecessary integer multiplications and
5852         divisions in the common case where the element size is known at
5853         compile time.
5854         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
5855         needed.
5856         (xnboundedmalloc): Remove.
5857         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
5858         arguments, for consistency with rest of this header.
5859         (xcharalloc): Rewrite using XNMALLOC.
5860         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
5861         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
5862         versions have been moved to lib/xalloc.h and renamed to be the
5863         non-*_inline versions.
5864         (xmalloc, xrealloc): Implement without reference to the xnmalloc
5865         and xnrealloc functions, since those functions are now inline and
5866         now call us.
5867         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
5868         renaming described above.
5869         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
5870         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
5871         captures the dependency in AC_C_INLINE.
5872
5873         New module canonicalize-lgpl, proposed by Charles Wilson in
5874         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
5875         with a few small changes afterwards.
5876         * MODULES.html.sh (File system functions): New module
5877         canonicalize-lgpl.
5878         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
5879         and canonicalize_file_name.
5880         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
5881         * modules/canonicalize-lgpl: New files.
5882
5883 2006-11-05  Bruno Haible  <bruno@clisp.org>
5884
5885         * gnulib-tool (func_import, func_create_testdir): Create directories
5886         also for files in subdirectories of lib/.
5887
5888 2006-11-05  Bruno Haible  <bruno@clisp.org>
5889
5890         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
5891         ANSI C compliant.
5892
5893 2006-11-03  Bruno Haible  <bruno@clisp.org>
5894
5895         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
5896         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
5897         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
5898         (xnboundedmalloc): New inline function.
5899         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
5900         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
5901         xmalloc.
5902         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
5903         xmalloc.
5904         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
5905         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
5906         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
5907         xmalloc.
5908         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
5909         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
5910         xmalloc.
5911         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
5912         gl_tree_add_after): Use XMALLOC instead of xmalloc.
5913         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
5914         xmalloc.
5915         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
5916         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
5917         gl_tree_add_after): Use XMALLOC instead of xmalloc.
5918         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
5919         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
5920         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
5921         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
5922
5923 2006-11-03  Bruno Haible  <bruno@clisp.org>
5924
5925         * lib/c-ctype.h [C++]: Define functions without name mangling.
5926         * lib/fwriteerror.h [C++]: Likewise.
5927         * lib/gcd.h [C++]: Likewise.
5928         * lib/linebreak.h [C++]: Likewise.
5929
5930 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
5931
5932         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
5933         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
5934         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
5935         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
5936         Check for functions and headers just once.
5937         Check for declaration of canonicalize_file_name.
5938         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
5939
5940 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
5941
5942         * gnulib-tool (func_import): Fix typo in actioncmd.
5943
5944 2006-11-02  Bruno Haible  <bruno@clisp.org>
5945
5946         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
5947         newline sequence in the Makefile.am snippet as a space, like "make"
5948         does.
5949         Reported by Roger Persson <perrog@gmail.com>.
5950
5951 2006-11-01  Bruno Haible  <bruno@clisp.org>
5952
5953         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
5954         already declared in <string.h>.
5955         * lib/strcase.h (strncasecmp): Don't declare it if yes.
5956
5957 2006-11-01  Bruno Haible  <bruno@clisp.org>
5958
5959         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
5960         * lib/strcase.h: Include <string.h>.
5961         (strcasecmp): Define to rpl_strcasecmp here.
5962
5963 2006-11-01  Bruno Haible  <bruno@clisp.org>
5964
5965         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
5966
5967 2006-11-01  Eric Blake  <ebb9@byu.net>
5968
5969         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
5970
5971         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
5972
5973 2006-10-29  Bruno Haible  <bruno@clisp.org>
5974
5975         Make it compile in C++ mode.
5976         * lib/full-write.c (full_rw): Add a cast.
5977
5978 2006-11-01  Bruno Haible  <bruno@clisp.org>
5979
5980         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
5981         be POSIX compliant.
5982         Reported by Roger Persson <perrog@gmail.com>.
5983
5984 2006-11-01  Eric Blake  <ebb9@byu.net>
5985
5986         * lib/getopt_.h: Fix comments.
5987
5988 2006-10-31  Eric Blake  <ebb9@byu.net>
5989
5990         * modules/tmpdir (Depends-on): Add sys_stat.
5991         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
5992         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
5993         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
5994         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
5995         tempname.
5996
5997 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
5998
5999         Avoid some C++ diagnostics reported by Bruno Haible.
6000         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
6001         xmalloc.
6002         (quotearg_alloc): Use xcharalloc rather than xmalloc.
6003         (struct slotvec): Move to top level.
6004         (quotearg_n_options): Rewrite to avoid xmalloc.
6005         * lib/xalloc.h (xcharalloc): New function.
6006         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
6007         [defined __cplusplus]: Add function template that provides result
6008         type propagation.  This part of the change is from Bruno Haible.
6009
6010 2006-10-29  Bruno Haible  <bruno@clisp.org>
6011
6012         Make it compile in C++ mode.
6013         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
6014         * lib/strnlen1.c (strnlen1): Cast memchr result.
6015         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
6016         * lib/clean-temp.c (string_equals, string_hash): Add casts.
6017         (create_temp_dir): Rename local variable 'template'.
6018         (compile_csharp_using_sscli): Add cast.
6019         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
6020         * lib/findprog.c (find_in_path): Likewise.
6021         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
6022         * lib/wait-process.c (register_slave_subprocess): Likewise.
6023
6024 2006-10-22  Bruno Haible  <bruno@clisp.org>
6025
6026         * modules/tsearch: New file.
6027         * lib/tsearch.h: New file.
6028         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
6029         * m4/tsearch.m4: New file.
6030         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
6031
6032 2006-10-29  Eric Blake  <ebb9@byu.net>
6033
6034         * lib/arcfour.c: Assume config.h.
6035         * lib/arctwo.c: Likewise.
6036         * lib/base64.c: Likewise.
6037         * lib/check-version.c: Likewise.
6038         * lib/crc.c: Likewise.
6039         * lib/des.c: Likewise.
6040         * lib/gc-gnulib.c: Likewise.
6041         * lib/gc-libgcrypt.c: Likewise.
6042         * lib/gc-pbkdf2-sha1.c: Likewise.
6043         * lib/getaddrinfo.c: Likewise.
6044         * lib/getdelim.c: Likewise.
6045         * lib/getline.c: Likewise.
6046         * lib/hmac-md5.c: Likewise.
6047         * lib/hmac-sha1.c: Likewise.
6048         * lib/iconvme.c: Likewise.
6049         * lib/md2.c: Likewise.
6050         * lib/md4.c: Likewise.
6051         * lib/memxor.c: Likewise.
6052         * lib/read-file.c: Likewise.
6053         * lib/readline.c: Likewise.
6054         * lib/rijndael-alg-fst.c: Likewise.
6055         * lib/rijndael-api-fst.c: Likewise.
6056         * lib/xgetdomainname.c: Likewise.
6057
6058 2006-10-28  Eric Blake  <ebb9@byu.net>
6059
6060         * lib/xstrndup.c: Assume config.h.
6061
6062 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
6063
6064         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
6065         stat-macros.h is now for our own macros, whereas stat_h is for
6066         macros in the <sys/stat.h> name space.
6067         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
6068         (STAT_MACROS_H): Remove.
6069         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
6070         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
6071         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
6072         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
6073         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
6074         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
6075         Move these macros to ...
6076         * lib/stat_.h: here.  Don't include stat-macros.h.
6077         * lib/canonicalize.c: Don't include stat-macros.h.
6078         * lib/chown.c: Likewise.
6079         * lib/euidaccess.c: Likewise.
6080         * lib/file-type.c: Likewise.
6081         * lib/filemode.c: Likewise.
6082         * lib/glob.c: Likewise.
6083         * lib/isapipe.c: Likewise.
6084         * lib/lchown.c: Likewise.
6085         * lib/lstat.c: Likewise.
6086         * lib/mkdir-p.c: Likewise.
6087         * lib/rmdir.c: Likewise.
6088         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
6089         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
6090         unless mkdir isn't declared, to speed up 'configure'.
6091         Always create sys/stat.h, since it's unlikely any real sys/stat.h
6092         would define all the S_* symbols.
6093         * modules/canonicalize (Depends-on):
6094         Depend on sys_stat, not stat-macros.
6095         * modules/chown: Likewise.
6096         * modules/euidaccess: Likewise.
6097         * modules/filemode: Likewise.
6098         * modules/file-type: Likewise.
6099         * modules/glob: Likewise.
6100         * modules/isapipe: Likewise.
6101         * modules/lchown: Likewise.
6102         * modules/lstat: Likewise.
6103         * modules/mkancesdirs: Likewise.
6104         * modules/rmdir: Likewise.
6105         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
6106         * modules/modechange: Likewise.
6107         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
6108         (configure.ac): Remove gl_STAT_MACROS.
6109         * modules/sys_stat (Depends-on): Remove stat-macros.
6110
6111 2006-10-27  Bruno Haible  <bruno@clisp.org>
6112
6113         * m4/signed.m4: Remove file.
6114         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
6115         invocation.
6116         * modules/vasnprintf (Files): Remove m4/signed.m4.
6117
6118 2006-10-27  Bruno Haible  <bruno@clisp.org>
6119
6120         Update to GNU gettext 0.16.
6121         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
6122         m4/inttypes-h.m4, m4/signed.m4.
6123         * m4/gettext.m4: Update to GNU gettext 0.16.
6124         * m4/intl.m4: New file, from GNU gettext.
6125         * m4/intldir.m4: New file, from GNU gettext.
6126         * config/srclist.txt: Update
6127
6128 2006-10-27  Eric Blake  <ebb9@byu.net>
6129
6130         * MODULES.html.sh: Document tempname.
6131         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
6132         dependencies.
6133         (Files): Move lib/tempname.c...
6134         * modules/tempname: ...to this new module.
6135         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
6136         (gl_PREREQ_TEMPNAME): Move...
6137         * m4/tempname.m4: ...to this new file.
6138         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
6139         * modules/sys_stat (Depends-on): Add stat-macros.
6140         * lib/stat_.h (includes): Pick up stat macros.
6141         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
6142         if stat macros are broken.
6143         * lib/tempname.c (includes): No need to include "stat-macros.h".
6144         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
6145         (direxists, __path_search) [!_LIBC]: Don't compile these in
6146         gnulib; the tmpdir module covers that.
6147         * lib/tempname.h: New file.
6148
6149 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
6150
6151         * COPYING: Explain how gnulib-tool converts licence headers.
6152         Almost all wording by Eric Blake.
6153
6154 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
6155
6156         * lib/mbchar.h (is_basic_table): Make read-only.
6157         * lib/mbchar.c (is_basic_table): Likewise.
6158         Reported by John Darrington.
6159
6160 2006-10-25  Bruno Haible  <bruno@clisp.org>
6161
6162         * lib/progname.h (set_program_name): Undefine before defining.
6163
6164 2006-10-25  Bruno Haible  <bruno@clisp.org>
6165
6166         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
6167         false for non-gcc C++ compilers.
6168         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
6169
6170 2006-10-24  Bruno Haible  <bruno@clisp.org>
6171
6172         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
6173         iconv implementations like Irix iconv.
6174
6175 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6176
6177         * modules/vararrays: New file.
6178         * m4/vararrays.m4: New file, taken from diffutils.
6179         * MODULES.html.sh: New module vararrays.
6180
6181 2006-10-24  Karl Berry  <karl@gnu.org>
6182
6183         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
6184         Don't call GNU Unix.
6185
6186 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6187
6188         * users.txt: Add Libtool.
6189
6190         Sync from Libtool:
6191
6192         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6193
6194         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
6195         to gnulib's policy of including config.h unconditionally.
6196
6197 2006-10-24  Bruno Haible  <bruno@clisp.org>
6198
6199         * modules/wcwidth (Files): Add m4/wint_t.m4.
6200         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
6201         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
6202
6203 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6204
6205         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
6206         to pacify GCC with some -W flags enabled.  Problem reported by
6207         Bruno Haible.
6208
6209 2006-10-24  Jim Meyering  <jim@meyering.net>
6210
6211         * MODULES.html.sh: Remove uinttostr.  It's not a module.
6212         Reported by Karl Berry.
6213
6214 2006-10-23  Bruno Haible  <bruno@clisp.org>
6215
6216         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
6217
6218 2006-10-24  Bruno Haible  <bruno@clisp.org>
6219
6220         * lib/gl_list.h: Use C comment style, not C++ comment style.
6221
6222 2006-10-23  Eric Blake  <ebb9@byu.net>
6223
6224         * lib/getaddrinfo.c (includes): Add missing include.
6225
6226 2006-10-23  Bruno Haible  <bruno@clisp.org>
6227             Paul Eggert  <eggert@cs.ucla.edu>
6228
6229         Ability to rename obstack_free.
6230         * lib/obstack.h (__obstack_free): New macro. Declare instead of
6231         obstack_free.
6232         (obstack_free): Invoke the __obstack_free macro.
6233         * lib/obstack.c (obstack_free): Use __obstack_free macro.
6234
6235 2006-10-23  Bruno Haible  <bruno@clisp.org>
6236             Paul Eggert  <eggert@cs.ucla.edu>
6237
6238         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
6239         __argc, __argv from the declaration. (They are defined as macros on
6240         mingw.)
6241
6242 2006-10-22  Bruno Haible  <bruno@clisp.org>
6243
6244         * doc/gnulib-intro.texi: New file.
6245         * doc/gnulib.texi: Include it.
6246
6247 2006-10-21  Bruno Haible  <bruno@clisp.org>
6248
6249         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
6250         "Introduction", "Miscellanous Notes", "Particular Modules".
6251
6252 2006-10-21  Bruno Haible  <bruno@clisp.org>
6253
6254         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6255         Change mostlyclean-local rule to avoid sh syntax error from bash
6256         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
6257
6258 2006-10-23  Jim Meyering  <jim@meyering.net>
6259
6260         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
6261         in place of snprintf.
6262
6263         * modules/inttostr (Files): Add lib/uinttostr.c.
6264         * lib/uinttostr.c (inttostr): New file/function.
6265         * lib/inttostr.h (uinttostr): Declare.
6266         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
6267         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
6268         Add uinttostr.
6269         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
6270
6271 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
6272
6273         * lib/canonicalize.c (ELOOP): Define if not already defined.
6274         Problem reported by Bruno Haible in
6275         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
6276
6277 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
6278
6279         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
6280         Problem reported by Perry Smith and Ville Laurikari.
6281
6282         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
6283         uses.
6284
6285 2006-10-19  Bruno Haible  <bruno@clisp.org>
6286
6287         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
6288         for mingw.
6289
6290 2006-10-19  Bruno Haible  <bruno@clisp.org>
6291
6292         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
6293         Needed for mingw.
6294
6295 2006-10-19  Bruno Haible  <bruno@clisp.org>
6296
6297         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
6298
6299 2006-10-19  Bruno Haible  <bruno@clisp.org>
6300
6301         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
6302         it.
6303
6304 2006-10-19  Bruno Haible  <bruno@clisp.org>
6305
6306         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
6307         invocation.
6308
6309 2006-10-19  Bruno Haible  <bruno@clisp.org>
6310
6311         * gnulib-tool (func_create_testdir): Don't include ftruncate and
6312         mountlist by default.
6313
6314 2006-10-16  Bruno Haible  <bruno@clisp.org>
6315
6316         * lib/c-strstr.c: Include c-strstr.h.
6317
6318 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
6319
6320         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
6321         in a slash.
6322
6323 2006-10-18  Bruno Haible  <bruno@clisp.org>
6324
6325         * lib/lock.h [C++]: Wrap definitions in extern "C".
6326
6327 2006-10-18  Bruno Haible  <bruno@clisp.org>
6328
6329         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
6330         gl_LIBOBJS list.
6331
6332 2006-10-18  Bruno Haible  <bruno@clisp.org>
6333
6334         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
6335
6336 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
6337
6338         * lib/xstrtol.h: Include gettext.h.
6339         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
6340         Problem reported by Eric Blake.
6341         * modules/xstrtol (Depends-on): Add gettext-h.
6342
6343 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
6344
6345         * lib/strftime.c (advance): New macro.
6346         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
6347         incomplete type, so you can't add 0 to it.  Problem and patch
6348         reported by Eelco Dolstra for dietlibc.
6349
6350 2006-10-18  Jim Meyering  <jim@meyering.net>
6351
6352         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
6353         type for a local, and rename it: s/up/user_proc/.
6354
6355 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
6356
6357         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
6358         READ_UTMP_USER_PROCESS.
6359         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
6360
6361 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
6362
6363         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
6364         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
6365
6366 2006-10-17  Eric Blake  <ebb9@byu.net>
6367
6368         * lib/sigprocmask.c (sigprocmask): Fix typo.
6369
6370         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
6371
6372         * modules/clean-temp (Makefile.am): Don't add to make output...
6373         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
6374         config.h.
6375
6376 2006-10-17  Bruno Haible  <bruno@clisp.org>
6377
6378         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
6379         differently if DEFAULT_TEXT_DOMAIN is set.
6380
6381 2006-10-16  Bruno Haible  <bruno@clisp.org>
6382
6383         * lib/clean-temp.c: Include fwriteerror.h.
6384
6385 2006-10-16  Bruno Haible  <bruno@clisp.org>
6386
6387         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
6388
6389 2006-10-16  Bruno Haible  <bruno@clisp.org>
6390
6391         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
6392         * lib/sigprocmask.h: Include <sys/types.h>.
6393         (sigset_t): Use the system's definition if present.
6394
6395 2006-10-17  Eric Blake  <ebb9@byu.net>
6396
6397         * lib/xvasprintf.c (includes): Assume config.h.
6398         * lib/xasprintf.c (includes): Likewise.
6399
6400 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
6401
6402         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
6403         at least as wide as intmax_t.
6404
6405 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
6406
6407         (Imported from Automake.)
6408         * build-aux/gnupload: Update to version 1.1 of directive file.
6409
6410 2006-10-16  Eric Blake  <ebb9@byu.net>
6411
6412         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
6413         match Automake 1.10a.
6414
6415 2006-10-14  Bruno Haible  <bruno@clisp.org>
6416
6417         * modules/sigprocmask: New file.
6418         * lib/sigprocmask.h: New file.
6419         * lib/sigprocmask.c: New file.
6420         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
6421         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
6422         request sigprocmask.o.
6423         (gl_PREREQ_SIGPROCMASK): New macro.
6424         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
6425         (Depends-on): Add sigprocmask.
6426         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
6427         gt_SIGNALBLOCKING. Test for 'raise' only once.
6428         * lib/fatal-signal.c: Include sigprocmask.h.
6429         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
6430         unblock_fatal_signals): Define always.
6431         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6432         sigprocmask.
6433
6434 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
6435
6436         Sync from Automake.
6437         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
6438         which incorrectly sets the mode of an existing destination
6439         directory.  In some cases the unpatched install-sh could do the
6440         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
6441         system.  We hope this is rare in practice, but it's clearly worth
6442         fixing.  Problem reported by Alex Unleashed in
6443         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
6444         Also, don't bother to check for -m bugs unless we're using -m;
6445         suggested by Stepan Kasal.
6446
6447 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6448
6449         Sync from Automake.
6450         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
6451         `-c' flag, so they appear at the same position as in %FASTDEP%
6452         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
6453         which ignores unknown options only after the first non-option.
6454         Bug report against M4 by Nelson H. F. Beebe.
6455
6456 2006-10-13  Jim Meyering  <jim@meyering.net>
6457
6458         Fix a bug in yesterday's change.
6459         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
6460         p->fts_statp->st_dev would be used uninitialized.
6461         Ensures that we always call fts_stat on the very first entry.
6462         Miklos Szeredi reported that find -xdev stopped working.
6463
6464 2006-10-12  Bruno Haible  <bruno@clisp.org>
6465
6466         * gnulib-tool (func_get_automake_snippet): Append an automatically
6467         computed EXTRA_DIST augmentation.
6468         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
6469         * modules/alloca-opt (Makefile.am): Likewise.
6470         * modules/allocsa (Makefile.am): Likewise.
6471         * modules/arcfour (Makefile.am): Likewise.
6472         * modules/arctwo (Makefile.am): Likewise.
6473         * modules/argmatch (Makefile.am): Likewise.
6474         * modules/argz (Makefile.am): Likewise.
6475         * modules/atexit (Makefile.am): Likewise.
6476         * modules/backupfile (Makefile.am): Likewise.
6477         * modules/byteswap (Makefile.am): Likewise.
6478         * modules/c-strtod (Makefile.am): Likewise.
6479         * modules/c-strtold (Makefile.am): Likewise.
6480         * modules/calloc (Makefile.am): Likewise.
6481         * modules/canon-host (Makefile.am): Likewise.
6482         * modules/canonicalize (Makefile.am): Likewise.
6483         * modules/chdir-long (Makefile.am): Likewise.
6484         * modules/chdir-safer (Makefile.am): Likewise.
6485         * modules/check-version (Makefile.am): Likewise.
6486         * modules/chown (Makefile.am): Likewise.
6487         * modules/cloexec (Makefile.am): Likewise.
6488         * modules/close-stream (Makefile.am): Likewise.
6489         * modules/closeout (Makefile.am): Likewise.
6490         * modules/crc (Makefile.am): Likewise.
6491         * modules/csharpexec (Makefile.am): Likewise.
6492         * modules/cycle-check (Makefile.am): Likewise.
6493         * modules/des (Makefile.am): Likewise.
6494         * modules/dev-ino (Makefile.am): Likewise.
6495         * modules/dirfd (Makefile.am): Likewise.
6496         * modules/dirname (Makefile.am): Likewise.
6497         * modules/dup2 (Makefile.am): Likewise.
6498         * modules/eealloc (Makefile.am): Likewise.
6499         * modules/error (Makefile.am): Likewise.
6500         * modules/euidaccess (Makefile.am): Likewise.
6501         * modules/exclude (Makefile.am): Likewise.
6502         * modules/exitfail (Makefile.am): Likewise.
6503         * modules/fcntl-safer (Makefile.am): Likewise.
6504         * modules/fcntl (Makefile.am): Likewise.
6505         * modules/file-type (Makefile.am): Likewise.
6506         * modules/fileblocks (Makefile.am): Likewise.
6507         * modules/filemode (Makefile.am): Likewise.
6508         * modules/filenamecat (Makefile.am): Likewise.
6509         * modules/fnmatch (Makefile.am): Likewise.
6510         * modules/fopen-safer (Makefile.am): Likewise.
6511         * modules/fpending (Makefile.am): Likewise.
6512         * modules/fprintftime (Makefile.am): Likewise.
6513         * modules/free (Makefile.am): Likewise.
6514         * modules/fsusage (Makefile.am): Likewise.
6515         * modules/ftruncate (Makefile.am): Likewise.
6516         * modules/fts (Makefile.am): Likewise.
6517         * modules/gc-arcfour (Makefile.am): Likewise.
6518         * modules/gc-des (Makefile.am): Likewise.
6519         * modules/gc-hmac-md5 (Makefile.am): Likewise.
6520         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
6521         * modules/gc-md4 (Makefile.am): Likewise.
6522         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
6523         * modules/gc-sha1 (Makefile.am): Likewise.
6524         * modules/gc (Makefile.am): Likewise.
6525         * modules/getaddrinfo (Makefile.am): Likewise.
6526         * modules/getcwd (Makefile.am): Likewise.
6527         * modules/getdelim (Makefile.am): Likewise.
6528         * modules/getdomainname (Makefile.am): Likewise.
6529         * modules/getgroups (Makefile.am): Likewise.
6530         * modules/gethostname (Makefile.am): Likewise.
6531         * modules/gethrxtime (Makefile.am): Likewise.
6532         * modules/getline (Makefile.am): Likewise.
6533         * modules/getloadavg (Makefile.am): Likewise.
6534         * modules/getlogin_r (Makefile.am): Likewise.
6535         * modules/getndelim2 (Makefile.am): Likewise.
6536         * modules/getopt (Makefile.am): Likewise.
6537         * modules/getpagesize (Makefile.am): Likewise.
6538         * modules/getpass-gnu (Makefile.am): Likewise.
6539         * modules/getpass (Makefile.am): Likewise.
6540         * modules/getsubopt (Makefile.am): Likewise.
6541         * modules/gettime (Makefile.am): Likewise.
6542         * modules/gettimeofday (Makefile.am): Likewise.
6543         * modules/getugroups (Makefile.am): Likewise.
6544         * modules/getusershell (Makefile.am): Likewise.
6545         * modules/glob (Makefile.am): Likewise.
6546         * modules/group-member (Makefile.am): Likewise.
6547         * modules/hard-locale (Makefile.am): Likewise.
6548         * modules/hash (Makefile.am): Likewise.
6549         * modules/hmac-md5 (Makefile.am): Likewise.
6550         * modules/hmac-sha1 (Makefile.am): Likewise.
6551         * modules/human (Makefile.am): Likewise.
6552         * modules/idcache (Makefile.am): Likewise.
6553         * modules/imaxabs (Makefile.am): Likewise.
6554         * modules/imaxdiv (Makefile.am): Likewise.
6555         * modules/inet_ntop (Makefile.am): Likewise.
6556         * modules/inet_pton (Makefile.am): Likewise.
6557         * modules/intprops (Makefile.am): Likewise.
6558         * modules/inttostr (Makefile.am): Likewise.
6559         * modules/inttypes (Makefile.am): Likewise.
6560         * modules/isapipe (Makefile.am): Likewise.
6561         * modules/javaversion (Makefile.am): Likewise.
6562         * modules/lchmod (Makefile.am): Likewise.
6563         * modules/lchown (Makefile.am): Likewise.
6564         * modules/localcharset (Makefile.am): Likewise.
6565         * modules/long-options (Makefile.am): Likewise.
6566         * modules/lstat (Makefile.am): Likewise.
6567         * modules/malloc (Makefile.am): Likewise.
6568         * modules/mathl (Makefile.am): Likewise.
6569         * modules/mbchar (Makefile.am): Likewise.
6570         * modules/md2 (Makefile.am): Likewise.
6571         * modules/md4 (Makefile.am): Likewise.
6572         * modules/md5 (Makefile.am): Likewise.
6573         * modules/memcasecmp (Makefile.am): Likewise.
6574         * modules/memchr (Makefile.am): Likewise.
6575         * modules/memcmp (Makefile.am): Likewise.
6576         * modules/memcoll (Makefile.am): Likewise.
6577         * modules/memcpy (Makefile.am): Likewise.
6578         * modules/memmem (Makefile.am): Likewise.
6579         * modules/memmove (Makefile.am): Likewise.
6580         * modules/mempcpy (Makefile.am): Likewise.
6581         * modules/memrchr (Makefile.am): Likewise.
6582         * modules/memset (Makefile.am): Likewise.
6583         * modules/memxor (Makefile.am): Likewise.
6584         * modules/mkancesdirs (Makefile.am): Likewise.
6585         * modules/mkdir-p (Makefile.am): Likewise.
6586         * modules/mkdir (Makefile.am): Likewise.
6587         * modules/mkdtemp (Makefile.am): Likewise.
6588         * modules/mkstemp (Makefile.am): Likewise.
6589         * modules/mktime (Makefile.am): Likewise.
6590         * modules/modechange (Makefile.am): Likewise.
6591         * modules/mountlist (Makefile.am): Likewise.
6592         * modules/nanosleep (Makefile.am): Likewise.
6593         * modules/obstack (Makefile.am): Likewise.
6594         * modules/openat (Makefile.am): Likewise.
6595         * modules/pagealign_alloc (Makefile.am): Likewise.
6596         * modules/pathmax (Makefile.am): Likewise.
6597         * modules/physmem (Makefile.am): Likewise.
6598         * modules/poll (Makefile.am): Likewise.
6599         * modules/posixtm (Makefile.am): Likewise.
6600         * modules/posixver (Makefile.am): Likewise.
6601         * modules/putenv (Makefile.am): Likewise.
6602         * modules/quote (Makefile.am): Likewise.
6603         * modules/quotearg (Makefile.am): Likewise.
6604         * modules/raise (Makefile.am): Likewise.
6605         * modules/read-file (Makefile.am): Likewise.
6606         * modules/readline (Makefile.am): Likewise.
6607         * modules/readlink (Makefile.am): Likewise.
6608         * modules/readtokens (Makefile.am): Likewise.
6609         * modules/readutmp (Makefile.am): Likewise.
6610         * modules/realloc (Makefile.am): Likewise.
6611         * modules/regex (Makefile.am): Likewise.
6612         * modules/rename-dest-slash (Makefile.am): Likewise.
6613         * modules/rename (Makefile.am): Likewise.
6614         * modules/rijndael (Makefile.am): Likewise.
6615         * modules/rmdir (Makefile.am): Likewise.
6616         * modules/rpmatch (Makefile.am): Likewise.
6617         * modules/safe-read (Makefile.am): Likewise.
6618         * modules/safe-write (Makefile.am): Likewise.
6619         * modules/same-inode (Makefile.am): Likewise.
6620         * modules/same (Makefile.am): Likewise.
6621         * modules/save-cwd (Makefile.am): Likewise.
6622         * modules/savedir (Makefile.am): Likewise.
6623         * modules/setenv (Makefile.am): Likewise.
6624         * modules/settime (Makefile.am): Likewise.
6625         * modules/sha1 (Makefile.am): Likewise.
6626         * modules/sig2str (Makefile.am): Likewise.
6627         * modules/snprintf (Makefile.am): Likewise.
6628         * modules/stat-macros (Makefile.am): Likewise.
6629         * modules/stat-time (Makefile.am): Likewise.
6630         * modules/stdbool (Makefile.am): Likewise.
6631         * modules/stdint (Makefile.am): Likewise.
6632         * modules/stdlib-safer (Makefile.am): Likewise.
6633         * modules/stpcpy (Makefile.am): Likewise.
6634         * modules/stpncpy (Makefile.am): Likewise.
6635         * modules/strcase (Makefile.am): Likewise.
6636         * modules/strcasestr (Makefile.am): Likewise.
6637         * modules/strchrnul (Makefile.am): Likewise.
6638         * modules/strcspn (Makefile.am): Likewise.
6639         * modules/strdup (Makefile.am): Likewise.
6640         * modules/strerror (Makefile.am): Likewise.
6641         * modules/strftime (Makefile.am): Likewise.
6642         * modules/strndup (Makefile.am): Likewise.
6643         * modules/strnlen (Makefile.am): Likewise.
6644         * modules/strpbrk (Makefile.am): Likewise.
6645         * modules/strsep (Makefile.am): Likewise.
6646         * modules/strstr (Makefile.am): Likewise.
6647         * modules/strtod (Makefile.am): Likewise.
6648         * modules/strtoimax (Makefile.am): Likewise.
6649         * modules/strtok_r (Makefile.am): Likewise.
6650         * modules/strtol (Makefile.am): Likewise.
6651         * modules/strtoll (Makefile.am): Likewise.
6652         * modules/strtoul (Makefile.am): Likewise.
6653         * modules/strtoull (Makefile.am): Likewise.
6654         * modules/strtoumax (Makefile.am): Likewise.
6655         * modules/strverscmp (Makefile.am): Likewise.
6656         * modules/sys_socket (Makefile.am): Likewise.
6657         * modules/sys_stat (Makefile.am): Likewise.
6658         * modules/sysexits (Makefile.am): Likewise.
6659         * modules/time_r (Makefile.am): Likewise.
6660         * modules/timegm (Makefile.am): Likewise.
6661         * modules/timespec (Makefile.am): Likewise.
6662         * modules/tmpfile-safer (Makefile.am): Likewise.
6663         * modules/trim (Makefile.am): Likewise.
6664         * modules/unistd-safer (Makefile.am): Likewise.
6665         * modules/unlinkdir (Makefile.am): Likewise.
6666         * modules/unlocked-io (Makefile.am): Likewise.
6667         * modules/userspec (Makefile.am): Likewise.
6668         * modules/utime (Makefile.am): Likewise.
6669         * modules/utimecmp (Makefile.am): Likewise.
6670         * modules/utimens (Makefile.am): Likewise.
6671         * modules/vasnprintf (Makefile.am): Likewise.
6672         * modules/vasprintf (Makefile.am): Likewise.
6673         * modules/vsnprintf (Makefile.am): Likewise.
6674         * modules/xalloc (Makefile.am): Likewise.
6675         * modules/xgetcwd (Makefile.am): Likewise.
6676         * modules/xnanosleep (Makefile.am): Likewise.
6677         * modules/xreadlink (Makefile.am): Likewise.
6678         * modules/xstrtod (Makefile.am): Likewise.
6679         * modules/xstrtol (Makefile.am): Likewise.
6680         * modules/xstrtold (Makefile.am): Likewise.
6681         * modules/yesno (Makefile.am): Likewise.
6682         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
6683
6684 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
6685
6686         * modules/error (Makefile.am): Distribute files through
6687         EXTRA_DIST, not lib_SOURCES.
6688
6689 2006-10-12  Eric Blake  <ebb9@byu.net>
6690
6691         * modules/error (Makefile.am): Distribute files in /lib.
6692         * modules/obstack (Makefile.am): Likewise.
6693
6694 2006-10-12  Bruno Haible  <bruno@clisp.org>
6695
6696         * modules/acl (Makefile.am): Distribute all files in lib/ through
6697         EXTRA_DIST.
6698         * modules/arcfour (Makefile.am): Likewise.
6699         * modules/arctwo (Makefile.am): Likewise.
6700         * modules/argmatch (Makefile.am): Likewise.
6701         * modules/argz (Makefile.am): Likewise.
6702         * modules/atexit (Makefile.am): Likewise.
6703         * modules/backupfile (Makefile.am): Likewise.
6704         * modules/c-strtod (Makefile.am): Likewise.
6705         * modules/c-strtold (Makefile.am): Likewise.
6706         * modules/calloc (Makefile.am): Likewise.
6707         * modules/canon-host (Makefile.am): Likewise.
6708         * modules/canonicalize (Makefile.am): Likewise.
6709         * modules/chdir-long (Makefile.am): Likewise.
6710         * modules/chdir-safer (Makefile.am): Likewise.
6711         * modules/check-version (Makefile.am): Likewise.
6712         * modules/chown (Makefile.am): Likewise.
6713         * modules/cloexec (Makefile.am): Likewise.
6714         * modules/close-stream (Makefile.am): Likewise.
6715         * modules/closeout (Makefile.am): Likewise.
6716         * modules/crc (Makefile.am): Likewise.
6717         * modules/cycle-check (Makefile.am): Likewise.
6718         * modules/des (Makefile.am): Likewise.
6719         * modules/dirfd (Makefile.am): Likewise.
6720         * modules/dirname (Makefile.am): Likewise.
6721         * modules/dup2 (Makefile.am): Likewise.
6722         * modules/euidaccess (Makefile.am): Likewise.
6723         * modules/exclude (Makefile.am): Likewise.
6724         * modules/exitfail (Makefile.am): Likewise.
6725         * modules/fcntl-safer (Makefile.am): Likewise.
6726         * modules/file-type (Makefile.am): Likewise.
6727         * modules/fileblocks (Makefile.am): Likewise.
6728         * modules/filemode (Makefile.am): Likewise.
6729         * modules/filenamecat (Makefile.am): Likewise.
6730         * modules/fnmatch (Makefile.am): Likewise.
6731         * modules/fopen-safer (Makefile.am): Likewise.
6732         * modules/fpending (Makefile.am): Likewise.
6733         * modules/fprintftime (Makefile.am): Likewise.
6734         * modules/free (Makefile.am): Likewise.
6735         * modules/fsusage (Makefile.am): Likewise.
6736         * modules/ftruncate (Makefile.am): Likewise.
6737         * modules/fts (Makefile.am): Likewise.
6738         * modules/gc (Makefile.am): Likewise.
6739         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
6740         * modules/getaddrinfo (Makefile.am): Likewise.
6741         * modules/getcwd (Makefile.am): Likewise.
6742         * modules/getdelim (Makefile.am): Likewise.
6743         * modules/getdomainname (Makefile.am): Likewise.
6744         * modules/getgroups (Makefile.am): Likewise.
6745         * modules/gethostname (Makefile.am): Likewise.
6746         * modules/gethrxtime (Makefile.am): Likewise.
6747         * modules/getline (Makefile.am): Likewise.
6748         * modules/getloadavg (Makefile.am): Likewise.
6749         * modules/getlogin_r (Makefile.am): Likewise.
6750         * modules/getopt (Makefile.am): Likewise.
6751         * modules/getpass (Makefile.am): Likewise.
6752         * modules/getpass-gnu (Makefile.am): Likewise.
6753         * modules/getsubopt (Makefile.am): Likewise.
6754         * modules/gettime (Makefile.am): Likewise.
6755         * modules/gettimeofday (Makefile.am): Likewise.
6756         * modules/getugroups (Makefile.am): Likewise.
6757         * modules/getusershell (Makefile.am): Likewise.
6758         * modules/glob (Makefile.am): Likewise.
6759         * modules/group-member (Makefile.am): Likewise.
6760         * modules/hard-locale (Makefile.am): Likewise.
6761         * modules/hash (Makefile.am): Likewise.
6762         * modules/hmac-md5 (Makefile.am): Likewise.
6763         * modules/hmac-sha1 (Makefile.am): Likewise.
6764         * modules/human (Makefile.am): Likewise.
6765         * modules/idcache (Makefile.am): Likewise.
6766         * modules/imaxabs (Makefile.am): Likewise.
6767         * modules/imaxdiv (Makefile.am): Likewise.
6768         * modules/inet_ntop (Makefile.am): Likewise.
6769         * modules/inet_pton (Makefile.am): Likewise.
6770         * modules/inttostr (Makefile.am): Likewise.
6771         * modules/isapipe (Makefile.am): Likewise.
6772         * modules/lchown (Makefile.am): Likewise.
6773         * modules/long-options (Makefile.am): Likewise.
6774         * modules/lstat (Makefile.am): Likewise.
6775         * modules/malloc (Makefile.am): Likewise.
6776         * modules/mathl (Makefile.am): Likewise.
6777         * modules/mbchar (Makefile.am): Likewise.
6778         * modules/md2 (Makefile.am): Likewise.
6779         * modules/md4 (Makefile.am): Likewise.
6780         * modules/md5 (Makefile.am): Likewise.
6781         * modules/memcasecmp (Makefile.am): Likewise.
6782         * modules/memchr (Makefile.am): Likewise.
6783         * modules/memcmp (Makefile.am): Likewise.
6784         * modules/memcoll (Makefile.am): Likewise.
6785         * modules/memcpy (Makefile.am): Likewise.
6786         * modules/memmem (Makefile.am): Likewise.
6787         * modules/memmove (Makefile.am): Likewise.
6788         * modules/mempcpy (Makefile.am): Likewise.
6789         * modules/memrchr (Makefile.am): Likewise.
6790         * modules/memset (Makefile.am): Likewise.
6791         * modules/memxor (Makefile.am): Likewise.
6792         * modules/mkancesdirs (Makefile.am): Likewise.
6793         * modules/mkdir (Makefile.am): Likewise.
6794         * modules/mkdir-p (Makefile.am): Likewise.
6795         * modules/mkdtemp (Makefile.am): Likewise.
6796         * modules/mkstemp (Makefile.am): Likewise.
6797         * modules/mktime (Makefile.am): Likewise.
6798         * modules/modechange (Makefile.am): Likewise.
6799         * modules/mountlist (Makefile.am): Likewise.
6800         * modules/nanosleep (Makefile.am): Likewise.
6801         * modules/openat (Makefile.am): Likewise.
6802         * modules/pagealign_alloc (Makefile.am): Likewise.
6803         * modules/physmem (Makefile.am): Likewise.
6804         * modules/poll (Makefile.am): Likewise.
6805         * modules/posixtm (Makefile.am): Likewise.
6806         * modules/posixver (Makefile.am): Likewise.
6807         * modules/putenv (Makefile.am): Likewise.
6808         * modules/quote (Makefile.am): Likewise.
6809         * modules/quotearg (Makefile.am): Likewise.
6810         * modules/raise (Makefile.am): Likewise.
6811         * modules/read-file (Makefile.am): Likewise.
6812         * modules/readline (Makefile.am): Likewise.
6813         * modules/readlink (Makefile.am): Likewise.
6814         * modules/readtokens (Makefile.am): Likewise.
6815         * modules/readutmp (Makefile.am): Likewise.
6816         * modules/realloc (Makefile.am): Likewise.
6817         * modules/regex (Makefile.am): Likewise.
6818         * modules/rename (Makefile.am): Likewise.
6819         * modules/rename-dest-slash (Makefile.am): Likewise.
6820         * modules/rijndael (Makefile.am): Likewise.
6821         * modules/rmdir (Makefile.am): Likewise.
6822         * modules/rpmatch (Makefile.am): Likewise.
6823         * modules/safe-read (Makefile.am): Likewise.
6824         * modules/safe-write (Makefile.am): Likewise.
6825         * modules/same (Makefile.am): Likewise.
6826         * modules/save-cwd (Makefile.am): Likewise.
6827         * modules/savedir (Makefile.am): Likewise.
6828         * modules/setenv (Makefile.am): Likewise.
6829         * modules/settime (Makefile.am): Likewise.
6830         * modules/sha1 (Makefile.am): Likewise.
6831         * modules/sig2str (Makefile.am): Likewise.
6832         * modules/snprintf (Makefile.am): Likewise.
6833         * modules/stdlib-safer (Makefile.am): Likewise.
6834         * modules/stpcpy (Makefile.am): Likewise.
6835         * modules/stpncpy (Makefile.am): Likewise.
6836         * modules/strcase (Makefile.am): Likewise.
6837         * modules/strcasestr (Makefile.am): Likewise.
6838         * modules/strchrnul (Makefile.am): Likewise.
6839         * modules/strcspn (Makefile.am): Likewise.
6840         * modules/strdup (Makefile.am): Likewise.
6841         * modules/strerror (Makefile.am): Likewise.
6842         * modules/strftime (Makefile.am): Likewise.
6843         * modules/strndup (Makefile.am): Likewise.
6844         * modules/strnlen (Makefile.am): Likewise.
6845         * modules/strpbrk (Makefile.am): Likewise.
6846         * modules/strsep (Makefile.am): Likewise.
6847         * modules/strstr (Makefile.am): Likewise.
6848         * modules/strtod (Makefile.am): Likewise.
6849         * modules/strtoimax (Makefile.am): Likewise.
6850         * modules/strtok_r (Makefile.am): Likewise.
6851         * modules/strtol (Makefile.am): Likewise.
6852         * modules/strtoll (Makefile.am): Likewise.
6853         * modules/strtoul (Makefile.am): Likewise.
6854         * modules/strtoull (Makefile.am): Likewise.
6855         * modules/strtoumax (Makefile.am): Likewise.
6856         * modules/strverscmp (Makefile.am): Likewise.
6857         * modules/time_r (Makefile.am): Likewise.
6858         * modules/timegm (Makefile.am): Likewise.
6859         * modules/tmpfile-safer (Makefile.am): Likewise.
6860         * modules/unistd-safer (Makefile.am): Likewise.
6861         * modules/unlinkdir (Makefile.am): Likewise.
6862         * modules/userspec (Makefile.am): Likewise.
6863         * modules/utime (Makefile.am): Likewise.
6864         * modules/utimecmp (Makefile.am): Likewise.
6865         * modules/utimens (Makefile.am): Likewise.
6866         * modules/vasnprintf (Makefile.am): Likewise.
6867         * modules/vasprintf (Makefile.am): Likewise.
6868         * modules/vsnprintf (Makefile.am): Likewise.
6869         * modules/xalloc (Makefile.am): Likewise.
6870         * modules/xgetcwd (Makefile.am): Likewise.
6871         * modules/xnanosleep (Makefile.am): Likewise.
6872         * modules/xreadlink (Makefile.am): Likewise.
6873         * modules/xstrtod (Makefile.am): Likewise.
6874         * modules/xstrtol (Makefile.am): Likewise.
6875         * modules/xstrtold (Makefile.am): Likewise.
6876         * modules/yesno (Makefile.am): Likewise.
6877
6878 2006-10-12  Jim Meyering  <jim@meyering.net>
6879
6880         * m4/getloadavg.m4: Revert the change below.
6881
6882         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
6883         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
6884         fail with a symlink, which is what coreutils' ./bootstrap now
6885         creates by default.
6886
6887 2006-10-12  Bruno Haible  <bruno@clisp.org>
6888
6889         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
6890         mingw.
6891         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
6892         MSVC and mingw explicitly.
6893
6894 2006-10-11  Simon Josefsson  <jas@extundo.com>
6895             Bruno Haible  <bruno@clisp.org>
6896
6897         Add support for multiple gnulib-tool invocations in the scope of a
6898         single configure.ac file.
6899         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
6900         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
6901         with the same contents as the _LIBADD variable.
6902         (func_emit_initmacro_start, func_emit_initmacro_end,
6903         func_emit_initmacro_done): New functions.
6904         (func_import, func_create_testdir): Invoke them. Allow the identifiers
6905         gl_LIBOBJS and gl_LTLIBOBJS.
6906
6907 2006-10-11  Bruno Haible  <bruno@clisp.org>
6908
6909         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
6910         (func_create_testdir): Don't create po/Makefile.am, don't invoke
6911         autoreconf. Instead, invoke autopoint explicitly but move back the
6912         *.m4 files from gnulib.
6913
6914 2006-10-11  Bruno Haible  <bruno@clisp.org>
6915
6916         * gnulib-tool (func_usage): Make module names after --create-testdir
6917         optional.
6918         (func_create_testdir): If no module was specified, use nearly all
6919         modules.
6920
6921 2006-10-12  Jim Meyering  <jim@meyering.net>
6922
6923         Big performance improvement for fts-based tools that use FTS_NOSTAT.
6924         Avoid spurious inode-mismatch problems on non-POSIX file systems.
6925         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
6926         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
6927         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
6928         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
6929         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
6930         (fts_set_stat_required): New function.
6931         (fts_open): Defer the calls to fts_stat, if possible or requested.
6932         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
6933         into fts_stat itself.
6934         (fts_read): Perform any required (deferred) fts_stat call.
6935         (fts_build): Likewise, for the directory we're about to open and read.
6936         In the readdir loop, carefully decide whether each entry will require
6937         an eventual call to fts_stat, using dirent.d_type info if available.
6938         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
6939         a command line argument into this function.  Update all callers.
6940         Map a return value of FTS_DOT to FTS_D for a command line argument.
6941         * modules/fts (Depends-on): Add d-type.  Alphabetize.
6942         Thanks to Miklos Szeredi for his tenacity and for the initial
6943         bug report about "find" failing on a FUSE-based file system.
6944
6945         * lib/fts.c (fts_open): Use consistent indentation.
6946
6947 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
6948
6949         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
6950         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
6951         reported by Jim Meyering.  All uses of cache variables renamed
6952         to match Autoconf's.
6953         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
6954         the other one.
6955
6956         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
6957         Fix misspelling in diagnostic.
6958
6959 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
6960
6961         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
6962         defined.  Problem reported by Matthew Woehlke.
6963
6964         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
6965         Add support for Tandem NonStop R series.
6966         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
6967         Use new macro.
6968
6969         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
6970         (has_trailing_slash): Omit size arg; all callers changed.
6971         Omit 'inline', since it doesn't help performance and we'd
6972         need to configure it.
6973         Don't count //, ///, etc. as having a trailing slash.
6974         As a side effect, this removes a C99ism reported by Matthew Woehlke.
6975         (rpl_rename_dest_slash): On failure, use rename's errno rather
6976         than (in some cases) an incorrect or junk errno.
6977         Simplify code by removing need to compute length; this does
6978         cause it to make two passes instead of one over the file name,
6979         but it's worth it.
6980
6981         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
6982         change, since Autoconf's version may no longer be appropriate now
6983         that we are using CVS Autoconf's version.  Add support for Tandem.
6984
6985 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
6986             Bruno Haible  <bruno@clisp.org>
6987
6988         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
6989         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
6990         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
6991         gl_AC_TYPE_LONG_LONG.
6992
6993         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
6994         instead of HAVE_LONG_LONG.
6995         * lib/printf-args.c (printf_fetchargs): Likewise.
6996         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
6997         * lib/vasnprintf.c (VASNPRINTF): Likewise.
6998         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
6999         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
7000         gl_AC_TYPE_LONG_LONG.
7001
7002 2006-10-11  Bruno Haible  <bruno@clisp.org>
7003
7004         * m4/longlong.m4: Add comments.
7005         * m4/ulonglong.m4: Likewise.
7006
7007 2006-10-10  Bruno Haible  <bruno@clisp.org>
7008
7009         Make it possible to #define stpcpy, strdup to aliases.
7010         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
7011         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
7012
7013 2006-10-10  Bruno Haible  <bruno@clisp.org>
7014
7015         Make it possible to #define gcd to an alias.
7016         * lib/gcd.c: Include config.h.
7017
7018 2006-10-10  Bruno Haible  <bruno@clisp.org>
7019
7020         Make it possible to #define c_isascii to an alias.
7021         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
7022         defined. Undefine the macros before defining them, to avoid gcc
7023         warnings.
7024         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
7025         define NO_C_CTYPE_MACROS early.
7026
7027 2006-10-10  Bruno Haible  <bruno@clisp.org>
7028
7029         Make it possible to #define set_program_name to an alias.
7030         * lib/progname.c: Don't undefine set_program_name; instead, undefine
7031         ENABLE_RELOCATABLE early.
7032
7033 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
7034
7035         Port to Tandem NSK OSS, which has 64-bit signed int but at most
7036         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
7037         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
7038         More generally, don't assume that 64-bit signed int is available
7039         if unsigned int is, and vice versa.
7040         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
7041         unsigned symbols, not on their signed counterparts.
7042         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
7043         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
7044         (UINT64_C, UINTMAX_C):
7045         Likewise.
7046         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
7047         unsigned counterparts.
7048         (Have_long_long, Unsigned): New macros.
7049         (Int): Renamed from INT.
7050         (strtoimax): Use the new macros.
7051         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
7052         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
7053         * modules/inttypes (inttypes.h): Substitute
7054         HAVE_UNSIGNED_LONG_LONG_INT.
7055         * modules/stdint (stdint.h): Likewise.
7056         (Files): Add m4/ulonglong.m4.
7057
7058 2006-10-10  Bruno Haible  <bruno@clisp.org>
7059
7060         Fix a gcc -Wshadow warning.
7061         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
7062         to 'bucket'.
7063         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
7064         gl_linked_indexof_from_to): Likewise.
7065         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
7066         Likewise.
7067         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
7068         Likewise.
7069         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
7070         Reported by Eric Blake.
7071
7072 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
7073
7074         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
7075         for NetBSD.  Problem reported by Bruno Haible.
7076
7077 2006-10-09  Jim Meyering  <jim@meyering.net>
7078
7079         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
7080         Patch from Bruno Haible.
7081
7082 2006-10-09  Jim Meyering  <jim@meyering.net>
7083
7084         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
7085         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
7086         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
7087
7088 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
7089
7090         Don't include <config.h> twice; this doesn't work in some cases,
7091         e.g., when config.h has "#define intmax_t long long int" and
7092         we include <config.h>, <inttypes.h>, <config.h> in that order.
7093         Problem reported by Matthew Woehlke in:
7094         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
7095         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
7096         * lib/fts-cycle.c: Don't include config.h.
7097         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
7098         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
7099         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
7100         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
7101         inttypes.h.
7102         * lib/xstrtoumax.c: Likewise.
7103         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
7104         __strtol and the like, so that this module is more like its siblings.
7105         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
7106         Remove; no longer needed now that we assume gnulib inttypes.h.
7107
7108 2006-10-08  Bruno Haible  <bruno@clisp.org>
7109
7110         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
7111         option.
7112
7113 2006-10-07  Jim Meyering  <jim@meyering.net>
7114
7115         * modules/inttypes (inttypes.h): Revert what seems to have been
7116         an inadvertent part of today's change: use "|", not "/" in the
7117         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
7118
7119 2006-10-07  Bruno Haible  <bruno@clisp.org>
7120
7121         * modules/sublist: New file.
7122
7123 2006-10-07  Bruno Haible  <bruno@clisp.org>
7124
7125         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
7126         * modules/argz (argz.h): Likewise.
7127         * modules/arpa_inet (arpa/inet.h): Likewise.
7128         * modules/byteswap (byteswap.h): Likewise.
7129         * modules/configmake (configmake.h): Likewise.
7130         * modules/fcntl (fcntl.h): Likewise.
7131         * modules/fnmatch (fnmatch.h): Likewise.
7132         * modules/getopt (getopt.h): Likewise.
7133         * modules/glob (glob.h): Likewise.
7134         * modules/inttypes (inttypes.h): Likewise.
7135         * modules/netinet_in (netinet/in.h): Likewise.
7136         * modules/poll (poll.h): Likewise.
7137         * modules/stdbool (stdbool.h): Likewise.
7138         * modules/stdint (stdint.h): Likewise.
7139         * modules/sys_select (sys/select.h): Likewise.
7140         * modules/sys_socket (sys/socket.h): Likewise.
7141         * modules/sys_stat (sys/stat.h): Likewise.
7142         * modules/sysexits (sysexits.h): Likewise.
7143         * modules/unistd (unistd.h): Likewise.
7144         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
7145         Add a "DO NOT EDIT" comment to the generated file.
7146         (func_import): Likewise for gnulib-comp.m4.
7147
7148 2006-10-07  Bruno Haible  <bruno@clisp.org>
7149
7150         * lib/gl_sublist.h: New file.
7151         * lib/gl_sublist.c: New file.
7152
7153 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
7154
7155         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
7156         name (relative to the original working directory) and the file
7157         name component (relative to the temporary working directory).  All
7158         callers changed.
7159         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
7160         * lib/mkdir-p.c (make_dir_parents): Likewise.
7161         * lib/mkdir-p.h (make_dir_parents): Likewise.
7162
7163 2006-10-06  Eric Blake  <ebb9@byu.net>
7164
7165         Define several macros for use by the clean-temp module.
7166         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
7167         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
7168         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
7169
7170         * lib/clean-temp.h (close_stream_temp): New declaration.
7171         * lib/clean-temp.c (includes): Pull in headers according to what
7172         other modules are in use.
7173         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
7174
7175 2006-10-06  Bruno Haible  <bruno@clisp.org>
7176
7177         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
7178         instead of fopen, fwriteerror.
7179
7180 2006-10-06  Bruno Haible  <bruno@clisp.org>
7181
7182         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
7183         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
7184         int.
7185         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
7186         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
7187         Return an error indicator.
7188         Suggested by Eric Blake.
7189
7190 2006-10-06  Bruno Haible  <bruno@clisp.org>
7191
7192         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
7193         Reported by Eric Blake.
7194
7195 2006-10-06  Bruno Haible  <bruno@clisp.org>
7196
7197         * modules/closeout (Description): Mention stderr too.
7198
7199 2006-10-06  Bruno Haible  <bruno@clisp.org>
7200         and Paul Eggert  <eggert@cs.ucla.edu>
7201
7202         * lib/closeout.c (close_stdout): Also close stderr.
7203         * lib/closeout.h: Update comment.
7204
7205 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
7206
7207         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
7208         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
7209         * lib/dirchownmod.c: Include lchown.h.
7210         * lib/lchown.c: Don't include files that lchown.h now includes.
7211         Don't declare chown, since lchown.h now does that.
7212         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
7213         (lchown): Define to rpl_chown if lchown is declared but
7214         does not exist.  Declare using a prototype if lchown is not
7215         declared.  Add a copyright notice.
7216         * lib/mkstemp.h: Include <unistd.h>.
7217         * lib/openat.c: Include lchown.h.
7218
7219         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
7220         we now test for that separately.
7221         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
7222         rather than O_NOFOLLOW, when testing whether it's possible to
7223         avoid a race condition reliably.
7224         * lib/savewd.c (savewd_chdir): Likewise.
7225
7226         Remove macros that are no longer needed now that stdint.h is
7227         reliable.
7228         * lib/fsusage.c (UINTMAX_MAX): Remove.
7229         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
7230         * lib/utimecmp.c (SIZE_MAX): Remove.
7231
7232         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
7233
7234         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
7235         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
7236         O_NOATIME works.
7237
7238 2006-10-05  Bruno Haible  <bruno@clisp.org>
7239
7240         * lib/gl_list.h (gl_sortedlist_search_from_to,
7241         gl_sortedlist_indexof_from_to): New declarations.
7242         (gl_list_implementation): New fields sortedlist_search_from_to,
7243         sortedlist_indexof_from_to.
7244         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
7245         inline functions.
7246         * lib/gl_list.c (gl_sortedlist_search_from_to,
7247         gl_sortedlist_indexof_from_to): New functions.
7248         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
7249         function.
7250         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
7251         (gl_array_sortedlist_search_from_to): New function.
7252         (gl_array_list_implementation): Update.
7253         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
7254         function.
7255         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
7256         (gl_carray_sortedlist_search_from_to): New function.
7257         (gl_carray_list_implementation): Update.
7258         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
7259         gl_linked_sortedlist_indexof_from_to): New functions.
7260         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
7261         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
7262         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
7263         gl_tree_sortedlist_indexof_from_to): New functions.
7264         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
7265         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
7266         Update.
7267         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
7268         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
7269         Update.
7270
7271 2006-10-05  Bruno Haible  <bruno@clisp.org>
7272
7273         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
7274         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
7275         (struct gl_list_implementation): Add fields search_from_to,
7276         indexof_from_to. Remove fields search, indexof.
7277         (gl_list_search): Use the search_from_to method.
7278         (gl_list_search_from, gl_list_search_from_to): New functions.
7279         (gl_list_indexof): Use the indexof_from_to method.
7280         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
7281         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
7282         (gl_list_search_from, gl_list_search_from_to): New functions.
7283         (gl_list_indexof): Use the indexof_from_to method.
7284         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
7285         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
7286         gl_array_indexof. Add start_index, end_index arguments.
7287         (gl_array_search_from_to): Renamed from gl_array_search. Add
7288         start_index, end_index arguments.
7289         (gl_array_remove, gl_array_list_implementation): Update.
7290         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
7291         gl_carray_indexof. Add start_index, end_index arguments.
7292         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
7293         start_index, end_index arguments.
7294         (gl_carray_remove, gl_carray_list_implementation): Update.
7295         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
7296         gl_linked_search. Add start_index, end_index arguments.
7297         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
7298         start_index, end_index arguments.
7299         (gl_linked_remove): Update.
7300         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
7301         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
7302         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
7303         field to 'size_t'.
7304         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
7305         gl_tree_search. Add start_index, end_index arguments.
7306         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
7307         start_index, end_index arguments.
7308         (gl_tree_remove): Update.
7309         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
7310         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
7311         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
7312         function.
7313         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
7314         gl_tree_search. Add start_index, end_index arguments.
7315         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
7316         start_index, end_index arguments.
7317         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
7318         Update.
7319         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
7320
7321 2006-10-05  Bruno Haible  <bruno@clisp.org>
7322
7323         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
7324
7325         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
7326         fwriteerror_temp): New declarations.
7327         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
7328         (descriptors): New variable.
7329         (cleanup): First, close the descriptors.
7330         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
7331         fclose_temp, fwriteerror_temp): New functions.
7332
7333 2006-10-04  Jim Meyering  <jim@meyering.net>
7334
7335         * lib/fts.c (fts_open): Tiny comment change.
7336
7337 2006-10-04  Bruno Haible  <bruno@clisp.org>
7338
7339         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
7340         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
7341         gl_LOCK_BODY.
7342         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
7343         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
7344         gl_LOCK_EARLY_BODY.
7345         (gl_LOCK): Require gl_LOCK_BODY.
7346
7347 2006-10-04  Bruno Haible  <bruno@clisp.org>
7348
7349         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
7350         (gl_oset_search_atleast): New declaration.
7351         (struct gl_oset_implementation): Add field 'search_atleast'.
7352         (gl_oset_search_atleast): New inline function.
7353         * lib/gl_oset.c (gl_oset_search_atleast): New function.
7354         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
7355         (gl_array_oset_implementation): Update.
7356         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
7357         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
7358         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
7359
7360 2006-10-04  Bruno Haible  <bruno@clisp.org>
7361
7362         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
7363
7364 2006-10-03  Bruno Haible  <bruno@clisp.org>
7365
7366         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
7367         from gl_avltreehash_list_implementation.
7368
7369 2006-10-03  Bruno Haible  <bruno@clisp.org>
7370
7371         * lib/gl_oset.c (gl_oset_add): Fix return type.
7372
7373 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
7374
7375         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
7376
7377 2006-10-02  Eric Blake  <ebb9@byu.net>
7378
7379         * modules/strnlen (Depends-on): Add extensions.
7380
7381 2006-10-02  Eric Blake  <ebb9@byu.net>
7382
7383         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
7384         definition in 2.60+.
7385
7386 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
7387
7388         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
7389         checks.
7390
7391 2006-10-02  Bruno Haible  <bruno@clisp.org>
7392
7393         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
7394         to the AUTOMAKE_OPTIONS.
7395         Reported by Jim Meyering.
7396
7397 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
7398
7399         Work around bug in Solaris 10 /proc file system:
7400         /proc/self/fd/NNN/.. isn't the parent directory of
7401         the directory whose file descriptor is NNN.  This needs to
7402         be worked around at run time, not compile time, since a
7403         program might be built on Solaris 8, where things work, and
7404         run on Solaris 10.
7405         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
7406         to use the following interface instead:
7407         (OPENAT_BUFFER_SIZE): New macro.
7408         (openat_proc_name): New function.
7409         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
7410         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
7411         Likewise.
7412         * lib/openat-proc.c: New file.
7413         * modules/openat (Files): Add lib/openat-proc.c.
7414         (Depends-on): Add same-inode, stdbool.
7415         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
7416
7417 2006-09-29  Bruno Haible  <bruno@clisp.org>
7418
7419         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
7420         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
7421         argument. Set stdout_closed before testing for ferror, not after.
7422         (fwriteerror, fwriteerror_no_ebadf): New functions.
7423
7424 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7425
7426         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
7427
7428 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
7429
7430         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
7431         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
7432
7433 2006-09-28  Jim Meyering  <jim@meyering.net>
7434
7435         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
7436         Include <unistd.h>.
7437
7438 2006-09-28  Bruno Haible  <bruno@clisp.org>
7439
7440         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
7441         * modules/linkedhash-list (Depends-on): Likewise.
7442         * modules/rbtreehash-list (Depends-on): Likewise.
7443
7444 2006-09-28  Bruno Haible  <bruno@clisp.org>
7445
7446         * lib/strndup.h: Simplify the redefinition of strndup.
7447         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
7448         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
7449
7450 2006-09-28  Bruno Haible  <bruno@clisp.org>
7451
7452         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
7453         * lib/gl_linkedhash_list.c: Likewise.
7454         * lib/gl_rbtreehash_list.c: Likewise.
7455
7456 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
7457
7458         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
7459         getaddrinfo.
7460
7461         * lib/__fpending.h: Don't include <stdio_ext.h> unless
7462         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
7463         it causes <stdio_ext.h> to cause a compile-time error.
7464         Problem reported by Nelson H. F. Beebe.
7465         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
7466         of HAVE_DECL___PENDING.
7467
7468         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
7469         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
7470         declaration.
7471
7472 2006-09-27  Jim Meyering  <jim@meyering.net>
7473
7474         This file could end up with a definition for a function
7475         named __strndup, rather than rpl_strndup on a system with
7476         incomplete weak_alias support.
7477         * lib/strndup.c (strndup): Rename from __strndup.
7478         Remove #defines that used to map __strndup to strndup.
7479         Don't use K&R prototypes.
7480         Remove LIBC-related code, since this file is not sync'd with glibc.
7481         * lib/strndup.h: Revamp, accordingly.
7482         * m4/strndup.m4: Modernize.
7483
7484 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
7485
7486         * modules/savewd (Depends-on): Add 'raise'.
7487         * lib/savewd.c: Include <signal.h>, for 'raise'.
7488
7489 2006-09-26  Jim Meyering  <jim@meyering.net>
7490
7491         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
7492         when we detect Darwin 8.7.0's acl_get_file bug.
7493         Rearrange to perform the new (below) run-test while $LIBS
7494         contains any acl-related library.  Set USE_ACL at the end.
7495         (gl_ACL_GET_FILE): New function.
7496
7497 2006-09-26  Eric Blake  <ebb9@byu.net>
7498
7499         * lib/verror.c: Include <config.h> unconditionally.
7500
7501 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
7502
7503         * modules/clock-time (Maintainer): Add self.
7504         * modules/getlogin_r (Depends-on): Add extensions.
7505
7506 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7507
7508         * modules/clock-time: New module.
7509         * modules/nanosleep (Depends-on): Add clock-time.
7510         * modules/gethrxtime (Depends-on): Likewise.
7511         * modules/gettime (Depends-on): Likewise.
7512         * modules/settime (Depends-on): Likewise.
7513
7514         * modules/fts-lgpl: Depend on openat.
7515         * modules/mkancesdirs: Depend on savewd.
7516         * modules/mkdir-p: Likewise.
7517
7518 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7519
7520         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
7521
7522         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
7523         `gl_have_arbitrary_file_name_length_limit' to
7524         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
7525         actually works between configure runs.
7526
7527 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7528             Bruno Haible  <bruno@clisp.org>
7529
7530         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
7531
7532 2006-09-25  Jim Meyering  <jim@meyering.net>
7533
7534         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
7535         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
7536
7537 2006-09-25  Eric Blake  <ebb9@byu.net>
7538
7539         * gnulib-tool (func_import, func_create_testdir): Fix typos in
7540         exec's in 2006-09-18 patch when shuffling fds.
7541
7542 2006-09-25  Bruno Haible  <bruno@clisp.org>
7543
7544         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
7545         Reported by Jim Meyering.
7546
7547 2006-09-24  Jim Meyering  <jim@meyering.net>
7548
7549         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
7550         compare a pointer against a literal "0".  That caused failures with
7551         at least HP-UX's hpcc.
7552
7553 2006-09-22  Simon Josefsson  <jas@extundo.com>
7554
7555         * modules/gc-sha1:
7556         * modules/gc-md4:
7557         * modules/gc-hmac-sha1:
7558         * modules/gc-hmac-md5:
7559         * modules/gc-des:
7560         * modules/gc-arcfour: Distribute more files.
7561
7562 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7563
7564         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
7565         (gl_linked_iterator_from_to): Initialize struct completely.
7566         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
7567         (gl_tree_iterator_from_to): Likewise
7568         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
7569         * lib/gl_array_list.c [lint] (gl_array_iterator)
7570         (gl_array_iterator_from_to): Likewise.
7571         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
7572         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
7573         (gl_carray_iterator_from_to): Likewise.
7574
7575         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
7576         * lib/md4.c (md4_process_block): Remove unused variable.
7577         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
7578         parentheses for clarity.
7579
7580 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7581
7582         * modules/bison-i18n (Depends-on): Add gettext.
7583
7584 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7585
7586         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
7587         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
7588         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
7589         also add missing comma that caused broken test.
7590         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
7591         stdlib.h, for `abort'.
7592         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
7593         variables.
7594         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
7595         include unistd.h if present, for `rmdir'.
7596         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
7597         variables.
7598         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
7599         in the process include standard headers for prototypes.
7600         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
7601         gets declared on GNU/Linux.
7602         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
7603         unistd.h, for `rmdir'.
7604         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
7605
7606         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
7607         always true.
7608         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
7609
7610         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
7611
7612 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7613
7614         * gnulib-tool (func_version): Create output all at once.  This
7615         may help avoid triggering unnecessary SIGPIPEs, and at any
7616         rate it doesn't hurt.
7617
7618 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7619             Bruno Haible  <bruno@clisp.org>
7620
7621         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
7622         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
7623         * m4/signed.m4 (bh_C_SIGNED): Likewise.
7624
7625         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
7626         (gl_FUNC_VASPRINTF): Invoke it.
7627
7628 2006-09-22  Bruno Haible  <bruno@clisp.org>
7629
7630         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
7631         getloadavg.c as first argument.
7632
7633 2006-09-22  Bruno Haible  <bruno@clisp.org>
7634
7635         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
7636         at the beginning of the gl_INIT macro.
7637         * modules/getloadavg (configure.ac): Pass $gl_source_base to
7638         gl_GETLOADAVG.
7639
7640 2006-09-22  Bruno Haible  <bruno@clisp.org>
7641
7642         * gnulib-tool (func_create_megatestdir): Don't include the config-h
7643         module.
7644         Suggested by Ralf Wildenhues.
7645
7646 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
7647
7648         Import this patch from libc:
7649
7650         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
7651
7652         * lib/regex_internal.c (re_string_reconstruct): Handle
7653         offset < pstr->valid_raw_len && pstr->offsets_needed case.
7654         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
7655         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
7656         re_string_context_at.
7657
7658         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
7659         now requires it.
7660         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
7661         gl_REGEX now does it for us.
7662         (gl_REGEX): Add test taken from
7663         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
7664
7665         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
7666         Check that large offsets work.  Modernize Autoconf usages.
7667         Prefer "yes" to mean a good thing rather than a bad.
7668         Don't put "#define mkstemp" in config.h, as this might interfere
7669         with standard system headers that "#define mkstemp mkstemp64".
7670
7671         * modules/mkstemp (Depends-on): Add extensions, so that
7672         mkstemp is visible on some platforms.
7673         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
7674         (Include): Change to "mkstemp.h" from <stdlib.h>.
7675         (Files): Add mkstemp.h.
7676
7677         * lib/mkstemp.h: New file, since some standard headers
7678         #define mkstemp.
7679         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
7680         Include "mkstemp.h".
7681         Make the _LIBC code resemble glibc original more,
7682         e.g., use K&R style.
7683         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
7684         (mkstemp): Remove, since mkstemp.h does this for us.
7685         * lib/stdlib--.h: Include mkstemp.h.
7686
7687         Import this patch from libc:
7688
7689         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7690
7691         * lib/tempname.c (__gen_tempname): Change attempts_min
7692         into a macro.  Use preprocessor to decide how to initialize
7693         attempts [Coverity CID 67].
7694
7695 2006-09-20  Bruno Haible  <bruno@clisp.org>
7696
7697         * lib/mkdtemp.c: Import from libc.
7698         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7699                 * sysdeps/posix/tempname.c (__gen_tempname): Change
7700                 attempts_min into a macro.  Use preprocessor to decide how to
7701                 initialize attempts [Coverity CID 67].
7702         2001-11-27  Paul Eggert  <eggert@twinsun.com>
7703                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
7704                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
7705
7706 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7707
7708         * gnulib-tool (func_exit): New function, to allow to pass the
7709         exit status portably through the trap.  Use everywhere.
7710         (--help, --version): Signal a write error.
7711         (trap): catch SIGPIPE, for write errors.
7712         Exit at the end of the trap, with the correct exit status.
7713
7714 2006-09-19  Karl Berry  <karl@gnu.org>
7715
7716         * doc/gnulib.texi: note about the license texinfo files.
7717
7718 2006-09-19  Eric Blake  <ebb9@byu.net>
7719
7720         * gnulib-tool: Avoid space-tab.
7721
7722 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7723
7724         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
7725         that prevented coreutils 6.1 from building.  Problem reported
7726         by Petter Reinholdtsen.
7727
7728 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7729
7730         * gnulib-tool (avoidlist): Fix typo that broke options like
7731         --avoid=lock that are used by coreutils bootstrap.
7732
7733 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
7734
7735         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
7736         more systematically.
7737
7738 2006-09-18  Jim Meyering  <jim@meyering.net>
7739
7740         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
7741
7742 2006-09-18  Bruno Haible  <bruno@clisp.org>
7743
7744         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
7745
7746 2006-09-18  Bruno Haible  <bruno@clisp.org>
7747
7748         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
7749         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
7750         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
7751         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
7752         * m4/gettext.m4: Require autoconf >= 2.52.
7753         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
7754         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
7755         of gl_cv_header_inttypes_h.
7756
7757 2006-09-18  Bruno Haible  <bruno@clisp.org>
7758
7759         * lib/javaversion.c: Include configmake.h.
7760
7761 2006-09-18  Bruno Haible  <bruno@clisp.org>
7762
7763         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
7764         avoid that the while loops be executed in a subshell.
7765
7766 2006-09-18  Bruno Haible  <bruno@clisp.org>
7767
7768         * MODULES.html.sh (func_module): Break long lines.
7769         Suggested by Bruce Korb <bkorb@gnu.org>.
7770
7771 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7772
7773         Speed up by a factor of 1.12.
7774         * gnulib-tool (nl): New variable.
7775         (func_import): Rewrite include directive extraction to only read each
7776         directive once.
7777
7778 2006-09-17  Bruno Haible  <bruno@clisp.org>
7779
7780         * modules/javaversion (Makefile.am): Remove DEFS setting.
7781         (Depends-on): Add configmake, for PKGDATADIR definition.
7782
7783 2006-09-17  Bruno Haible  <bruno@clisp.org>
7784
7785         * gnulib-tool (func_create_testdir): Rewrite all files at once.
7786
7787 2006-09-17  Bruno Haible  <bruno@clisp.org>
7788
7789         * gnulib-tool (func_append): New function, stolen from libtool.m4.
7790         (func_modules_transitive_closure, func_modules_add_dummy,
7791         func_modules_to_filelist, func_import, func_create_testdir,
7792         func_create_megatestdir, ...): Use it wherever possible.
7793         Suggested by Ralf Wildenhues.
7794
7795 2006-09-16  Karl Berry  <karl@gnu.org>
7796
7797         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
7798         to avoid sectioning errors.
7799         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
7800         [ifinfo]: blank line after @center-ed titles.
7801         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
7802         Spell FSF address consistently with others.
7803         (These changes approved by rms.)
7804
7805 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7806
7807         Speed up by a factor of 1.61.
7808         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
7809         already checked module names again.
7810
7811 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7812
7813         Speed up by a factor of 1.13.
7814         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
7815         for new_files, and the input to func_add_or_update.
7816
7817 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7818
7819         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
7820         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
7821
7822 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7823
7824         * modules/mkancesdirs (Depends-on): Add fcntl.
7825         * modules/savewd: New file.
7826         * MODULES.html.sh (File system functions): Add savewd.
7827
7828         * modules/configmake (Makefile.am): Add support for the
7829         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
7830
7831 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7832
7833         * m4/savewd.m4: New file.
7834
7835 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
7836
7837         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
7838         (dirchownmod): New arg FD.  All callers changed.
7839         Use FD rather than opening the directory ourself, as opening is
7840         now the caller's responsibility.
7841         * lib/dirchownmod.h: Likewise.
7842         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
7843         hosts that require <sys/types.h> before <sys/stat.h>.  Include
7844         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
7845         (test_dir): Remove.
7846         (mkancesdirs): Return length of prefix of FILE that has already
7847         been made, or -2 if there is a child doing the work.  Redo
7848         algorithm so that it is O(N) rather than O(N**2).  Optimize away
7849         ".", and treat ".." specially since it might stray back into
7850         already-created areas.  Use a subprocess if necessary.  New arg
7851         WD; all users changed.  MAKE_DIR function should now return 1
7852         if it creates a directory that is not readable.  Return -2 if
7853         a child process is spun off.
7854         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
7855         Adjust signature to match code.
7856         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
7857         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
7858         all users changed.
7859         * lib/savewd.c, lib/savewd.h: New files.
7860
7861 2006-09-15  Jim Meyering  <jim@meyering.net>
7862
7863         * modules/rename-dest-slash: New module.
7864         * MODULES.html.sh (posix_compat): Add it here.
7865
7866         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
7867
7868 2006-09-15  Jim Meyering  <jim@meyering.net>
7869
7870         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
7871         file.
7872
7873         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
7874
7875 2006-09-15  Jim Meyering  <jim@meyering.net>
7876
7877         * lib/rename-dest-slash.c (has_trailing_slash): Use
7878         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
7879         (rpl_rename_dest_slash): Perform the cheaper trailing slash
7880         test before testing whether SRC is a directory.
7881         Suggestions from Bruno Haible.
7882
7883         Avoid a warning about an unused variable.
7884         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
7885         into the #ifdef block where it's used.
7886
7887         * lib/rename-dest-slash.c: New file.
7888
7889 2006-09-14  Bruno Haible  <bruno@clisp.org>
7890
7891         * lib/allocsa.c: Include <config.h> unconditionally.
7892         * lib/asnprintf.c: Likewise.
7893         * lib/asprintf.c: Likewise.
7894         * lib/c-strcasecmp.c: Likewise.
7895         * lib/c-strcasestr.c: Likewise.
7896         * lib/c-strncasecmp.c: Likewise.
7897         * lib/c-strstr.c: Likewise.
7898         * lib/classpath.c: Likewise.
7899         * lib/clean-temp.c: Likewise.
7900         * lib/concatpath.c: Likewise.
7901         * lib/copy-file.c: Likewise.
7902         * lib/csharpcomp.c: Likewise.
7903         * lib/csharpexec.c: Likewise.
7904         * lib/execute.c: Likewise.
7905         * lib/fatal-signal.c: Likewise.
7906         * lib/findprog.c: Likewise.
7907         * lib/fwriteerror.c: Likewise.
7908         * lib/gl_array_list.c: Likewise.
7909         * lib/gl_array_oset.c: Likewise.
7910         * lib/gl_avltree_list.c: Likewise.
7911         * lib/gl_avltree_oset.c: Likewise.
7912         * lib/gl_avltreehash_list.c: Likewise.
7913         * lib/gl_carray_list.c: Likewise.
7914         * lib/gl_linked_list.c: Likewise.
7915         * lib/gl_linkedhash_list.c: Likewise.
7916         * lib/gl_list.c: Likewise.
7917         * lib/gl_oset.c: Likewise.
7918         * lib/gl_rbtree_list.c: Likewise.
7919         * lib/gl_rbtree_oset.c: Likewise.
7920         * lib/gl_rbtreehash_list.c: Likewise.
7921         * lib/imaxabs.c: Likewise.
7922         * lib/imaxdiv.c: Likewise.
7923         * lib/javacomp.c: Likewise.
7924         * lib/javaexec.c: Likewise.
7925         * lib/javaversion.c: Likewise.
7926         * lib/linebreak.c: Likewise.
7927         * lib/localcharset.c: Likewise.
7928         * lib/lock.c: Likewise.
7929         * lib/mbchar.c: Likewise.
7930         * lib/mbswidth.c: Likewise.
7931         * lib/mkdtemp.c: Likewise.
7932         * lib/pipe.c: Likewise.
7933         * lib/printf-args.c: Likewise.
7934         * lib/printf-parse.c: Likewise.
7935         * lib/progname.c: Likewise.
7936         * lib/progreloc.c: Likewise.
7937         * lib/readlink.c: Likewise.
7938         * lib/sh-quote.c: Likewise.
7939         * lib/stpcpy.c: Likewise.
7940         * lib/stpncpy.c: Likewise.
7941         * lib/strcasecmp.c: Likewise.
7942         * lib/strcasestr.c: Likewise.
7943         * lib/strcspn.c: Likewise.
7944         * lib/striconv.c: Likewise.
7945         * lib/strncasecmp.c: Likewise.
7946         * lib/strnlen1.c: Likewise.
7947         * lib/strstr.c: Likewise.
7948         * lib/strtok_r.c: Likewise.
7949         * lib/tls.c: Likewise.
7950         * lib/tmpdir.c: Likewise.
7951         * lib/unicodeio.c: Likewise.
7952         * lib/unsetenv.c: Likewise.
7953         * lib/vasnprintf.c: Likewise.
7954         * lib/vasprintf.c: Likewise.
7955         * lib/wait-process.c: Likewise.
7956         * lib/xallocsa.c: Likewise.
7957         * lib/xsetenv.c: Likewise.
7958         * lib/xstriconv.c: Likewise.
7959
7960 2006-09-13  Simon Josefsson  <jas@extundo.com>
7961
7962         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
7963         that internally, suggested by Ralf Wildenhues
7964         <Ralf.Wildenhues@gmx.de>.
7965
7966 2006-09-13  Simon Josefsson  <jas@extundo.com>
7967
7968         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
7969         @LIBOBJS@.
7970         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
7971
7972 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
7973
7974         * lib/_fpending.c: Include <config.h> unconditionally, since we no
7975         longer worry about uses that don't define HAVE_CONFIG_H.
7976         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
7977         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
7978         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
7979         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
7980         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
7981         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
7982         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
7983         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
7984         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
7985         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
7986         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
7987         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
7988         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
7989         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
7990         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
7991         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
7992         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
7993         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
7994         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
7995         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
7996         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
7997         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
7998         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
7999         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
8000         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
8001         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
8002         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
8003         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
8004         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
8005         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
8006         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
8007         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
8008         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
8009         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
8010         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
8011         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
8012         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
8013         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
8014         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
8015         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
8016         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
8017         Likewise.
8018
8019 2006-09-13  Eric Blake  <ebb9@byu.net>
8020
8021         * lib/getopt.c: Fix typo in last commit.
8022
8023 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
8024
8025         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
8026         dgettext.
8027
8028 2006-09-12  Jim Meyering  <jim@meyering.net>
8029
8030         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
8031         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
8032         Reported by Nelson H. F. Beebe.
8033
8034 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8035
8036         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
8037         program_invocation_name and program_invocation_short_name are
8038         initialized.
8039         * lib/argp-namefrob.h: Move declarations of program_invocation_name
8040         and program_invocation_short_name to argp.h, so they are visible
8041         to user programs.
8042         * lib/argp.h: Likewise
8043
8044 2006-09-10  Bruno Haible  <bruno@clisp.org>
8045
8046         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
8047         m4/inttypes_h.m4, m4/uintmax_t.m4.
8048
8049 2006-09-10  Bruno Haible  <bruno@clisp.org>
8050
8051         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
8052         gl_AC_TYPE_UINTMAX_T.
8053
8054 2006-09-10  Bruno Haible  <bruno@clisp.org>
8055
8056         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
8057
8058 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8059
8060         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
8061         convention.  Text proposed by Bruno Haible.
8062         (struct argp_option): Document the use of N_() wrappers.
8063
8064         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
8065         '\v', and translate the two parts separately, instead of feeding
8066         the whole string to gettext.  This allows to exclude
8067         '\v' from the strings visible to the translator by writing doc
8068         strings as N_("..") "\v" N_("..").
8069
8070 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
8071
8072         * config/srclist.txt: Undo latest change; the bug was fixed.
8073
8074 2006-09-09  Bruno Haible  <bruno@clisp.org>
8075
8076         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
8077         assignments if building a library without libtool.
8078         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
8079         in func_emit_lib_Makefile_am.
8080         (func_import): When building a static library libfoo.a, arrange to
8081         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
8082         (func_create_testdir): Likewise.
8083         * modules/gc (configure.ac, Makefile.am): If building statically,
8084         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
8085         * modules/iconvme (configure.ac, Makefile.am): Likewise.
8086         * modules/striconv (configure.ac, Makefile.am): Likewise.
8087         Based on a suggestion by Ralf Wildenhues.
8088
8089 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8090
8091         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
8092         Check for unistd.h too, since Autoconf doesn't assume POSIX.
8093         Also:
8094
8095         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8096         Add year_2050_test to catch glibc bug 2821
8097         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
8098
8099         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8100         Prefer #ifdef to #if.
8101
8102         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
8103         Return from 'main' instead of calling 'exit'.
8104
8105 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8106
8107         * lib/mktime.c (guess_time_tm): Fix bug where mktime
8108         returned the maximum time_t value rather than (time_t) -1.
8109         Problem originally reported by William Bardwell
8110         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
8111
8112         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
8113         Moved to here ...
8114         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
8115         ... from here.
8116
8117 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8118
8119         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
8120         2821 is fixed.
8121
8122 2006-09-08  Jim Meyering  <jim@meyering.net>
8123
8124         Don't make generated files read-only.  That would bother too many
8125         people.  However, do retain the ability to work when targets are
8126         read-only: remove the destination and temporary files before writing
8127         them (when generated via sed or echo), or by using the -f option for
8128         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
8129         * modules/alloca-opt, modules/argz, modules/arpa_inet:
8130         * modules/byteswap, modules/configmake, modules/fcntl:
8131         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
8132         * modules/localcharset, modules/netinet_in, modules/poll:
8133         * modules/stdbool, modules/stdint, modules/sys_select:
8134         * modules/sys_socket, modules/sys_stat, modules/sysexits:
8135
8136 2006-09-08  Jim Meyering  <jim@meyering.net>
8137
8138         Avoid new build failure on FreeBSD 6.0.
8139         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
8140         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
8141         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
8142
8143 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8144
8145         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
8146
8147 2006-09-07  Jim Meyering  <jim@meyering.net>
8148
8149         Fix global typo in last change: use chmod u-w, not chmod u-x.
8150         Spotted by Paul Eggert and Bruce Korb.
8151         * modules/alloca-opt, modules/argz, modules/arpa_inet:
8152         * modules/byteswap, modules/configmake, modules/fcntl:
8153         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
8154         * modules/localcharset, modules/netinet_in, modules/poll:
8155         * modules/stdbool, modules/stdint, modules/sys_select:
8156         * modules/sys_socket, modules/sys_stat, modules/sysexits:
8157
8158 2006-09-06  Jim Meyering  <jim@meyering.net>
8159
8160         Make generated files be read-only.
8161         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
8162         Ensure that each generated file is now read-only.
8163         * modules/argz: Likewise.
8164         * modules/arpa_inet: Likewise.
8165         * modules/byteswap: Likewise.
8166         * modules/configmake: Likewise.
8167         * modules/fcntl: Likewise.
8168         * modules/fnmatch: Likewise.
8169         * modules/getopt: Likewise.
8170         * modules/glob: Likewise.
8171         * modules/inttypes: Likewise.
8172         * modules/netinet_in: Likewise.
8173         * modules/poll: Likewise.
8174         * modules/stdbool: Likewise.
8175         * modules/stdint: Likewise.
8176         * modules/sys_select: Likewise.
8177         * modules/sys_socket: Likewise.
8178         * modules/sys_stat: Likewise.
8179         * modules/sysexits: Likewise.
8180         * modules/localcharset: Same as above, but continue using temporary
8181         file named "t-$@" (why different?) rather than the "$@-t" used
8182         everywhere else.
8183
8184         * modules/sysexits (Makefile.am): Replace literal occurrences
8185         of "sysexit.h" more readable, and more consistent, "$@".
8186
8187 2006-09-06  Bruno Haible  <bruno@clisp.org>
8188
8189         * modules/striconv: New file.
8190         * modules/xstriconv: New file.
8191         * MODULES.html.sh (Internationalization functions): Add striconv,
8192         xstriconv.
8193
8194 2006-09-06  Bruno Haible  <bruno@clisp.org>
8195
8196         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
8197         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
8198         not using libtool correctly.
8199
8200 2006-09-06  Bruno Haible  <bruno@clisp.org>
8201
8202         * lib/striconv.h: New file.
8203         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
8204         iconvstring.c.
8205         * lib/xstriconv.h: New file.
8206         * lib/xstriconv.c: New file.
8207
8208 2006-09-06  Bruno Haible  <bruno@clisp.org>
8209
8210         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8211         lib_..._LDFLAGS.
8212
8213 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8214
8215         * lib/argz_.h: Sync from Libtool.
8216
8217         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
8218                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
8219
8220         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
8221
8222 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
8223
8224         * modules/trim: New file.
8225
8226 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
8227
8228         * lib/trim.h: New file.
8229         * lib/trim.c: New file.
8230
8231 2006-09-05  Bruno Haible  <bruno@clisp.org>
8232
8233         * MODULES.html.sh (String handling): Add trim.
8234
8235 2006-09-04  Karl Berry  <karl@gnu.org>
8236
8237         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
8238         until next release.
8239
8240 2006-09-03  Bruno Haible  <bruno@clisp.org>
8241
8242         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
8243         correctly.
8244
8245 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
8246
8247         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
8248         not gl_GETLOADAVG.  Omit unneeded semicolons.
8249         Problems reported by Ralf Wildenhues in
8250         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
8251         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
8252         at the end, which is the usual gnulib style.
8253
8254         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
8255         of doing all the work ourselves.
8256         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
8257         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
8258
8259 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
8260
8261         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
8262         Problem reported by Ralf Wildenhues in
8263         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
8264
8265         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
8266         HAVE_STRUCT_STATFS_F_FSTYPENAME.
8267
8268 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
8269
8270         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
8271         yesterday's patch by changing test -n to test -z.
8272
8273 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
8274
8275         * modules/getloadavg (Files): Add m4/getloadavg.m4.
8276         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
8277         the former is now obsolescent.
8278
8279         * modules/chdir-long (Depends-on): Add fcntl.
8280
8281 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
8282
8283         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
8284         obsolescent, and programs should use gnulib instead.
8285         * m4/getloadavg.m4: New file, with contents taken from Autoconf
8286         but with prefixes changed.
8287
8288 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
8289
8290         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
8291         or stdbool.h, because they might not exist while configuring.
8292
8293         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
8294         Don't include unistd.h or limits.h; not needed, since chdir-long.h
8295         does that for us.
8296         (O_DIRECTORY): Remove.
8297
8298 2006-08-31  Eric Blake  <ebb9@byu.net>
8299
8300         * gnulib-tool: Don't let emacs change spaces to TAB.
8301
8302 2006-08-31  Bruno Haible  <bruno@clisp.org>
8303
8304         * gnulib-tool: When calling func_import more than once, do it in a
8305         subshell.
8306         Reported by Eric Blake <ebb9@byu.net>.
8307
8308 2006-08-31  Bruno Haible  <bruno@clisp.org>
8309
8310         * gnulib-tool (nl): Remove variable.
8311         (sed_transform_lib_file): Use more robust test for config-h module.
8312         (func_import): Fix typo in 2006-08-25 patch.
8313
8314 2006-08-31  Bruno Haible  <bruno@clisp.org>
8315
8316         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
8317         specified, augment Makefile.am variables instead of assigning them.
8318
8319 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8320
8321         Work around a bug in both the Linux and SunOS 64-bit kernels:
8322         nanosleep mishandles sleeps for longer than 2**31 seconds.
8323         Problem reported by Frank v Waveren in
8324         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
8325         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
8326         Check for nanosleep bug.
8327         (LIB_NANOSLEEP): Append clock_gettime library if needed.
8328
8329 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8330
8331         Work around a bug in both the Linux and SunOS 64-bit kernels:
8332         nanosleep mishandles sleeps for longer than 2**31 seconds.
8333         Problem reported by Frank v Waveren in
8334         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
8335         * lib/nanosleep.c (BILLION): New constant.
8336         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
8337         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
8338         implementation.
8339
8340 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8341
8342         * modules/nanosleep (Depends-on): Add gettime.
8343
8344 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8345         and Simon Josefsson  <jas@extundo.com>
8346         and Oskar Liljeblad  <oskar@osk.mine.nu>
8347
8348         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
8349         * gnulib-tool (func_import): New license type 'unmodifiable license
8350         text'.
8351         * modules/fdl: Use it.  Longer description.
8352         * module/gpl, module/lgpl: New files.
8353
8354 2006-08-30  Jim Meyering  <jim@meyering.net>
8355
8356         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
8357         shadowing the parameter.
8358
8359 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8360
8361         Sync from Libtool:
8362
8363         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8364
8365         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
8366         sharing with gnulib.  Report by Eric Blake.
8367
8368 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8369
8370         * modules/isapipe: New file.
8371         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
8372
8373 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8374
8375         * modules/configmake (Makefile.am): Add a comment, and omit
8376         the CONFIGMAKE_ prefix from generated macro names.  Suggested
8377         by Bruno Haible.
8378
8379 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8380
8381         * m4/isapipe.m4: New file.
8382
8383 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8384
8385         * lib/isapipe.c, lib/isapipe.h: New files.
8386
8387 2006-08-29  Jim Meyering  <jim@meyering.net>
8388
8389         * modules/configmake (Makefile.am): Make configmake.h depend on
8390         Makefile.  Otherwise, a stale configmake.h could hang around.
8391
8392 2006-08-29  Eric Blake  <ebb9@byu.net>
8393
8394         * lib/error.c (error_at_line, print_errno_message): Match libc, after
8395         resolution of upstream bug 3044.
8396
8397 2006-08-29  Bruno Haible  <bruno@clisp.org>
8398
8399         * modules/localcharset (Depends-on): Add configmake.
8400         (Makefile.am): Remove setting of LIBDIR through DEFS.
8401
8402 2006-08-29  Bruno Haible  <bruno@clisp.org>
8403
8404         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
8405         defined.
8406
8407 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8408
8409         * modules/fcntl: New file.
8410         * modules/chdir-safer (Depends-on): Add fcntl.
8411         * modules/fts: Likewise.
8412         * modules/mkdir-p: Likewise.
8413
8414         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
8415         This undoes the most recent change, since we're now addressing the
8416         problem in a different way.
8417
8418         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
8419         into output, since the output might be called Makefile.am even
8420         if $makefile_name is something different.
8421         (func_import): Use $makefile_am rather than
8422         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
8423         empty.
8424
8425         * modules/inttypes (Files): Add m4/inttypes-h.m4.
8426
8427 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8428
8429         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
8430         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
8431         recent change to stdint.m4, since we're now addressing the problem in a
8432         different way.
8433
8434 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8435
8436         * m4/fcntl_h.m4: New file.
8437
8438 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8439
8440         * lib/fcntl_.h: New file.
8441         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
8442         the fcntl module.
8443         * lib/dirchownmod.c: Likewise.
8444         * lib/fts.c: Likewise.
8445
8446         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
8447         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
8448         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
8449         just before including <inttypes.h>, to avoid circular inclusion.
8450
8451 2006-08-28  Jim Meyering  <jim@meyering.net>
8452
8453         * doc/visibility.texi: Actually read and correct the grammar of the
8454         sentence affected by yesterday's change.
8455
8456 2006-08-28  Eric Blake  <ebb9@byu.net>
8457
8458         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
8459         needs wrapper.
8460
8461 2006-08-28  Eric Blake  <ebb9@byu.net>
8462
8463         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
8464
8465 2006-08-28  Eric Blake  <ebb9@byu.net>
8466
8467         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
8468
8469 2006-08-28  Bruno Haible  <bruno@clisp.org>
8470
8471         * modules/c-strstr: New file, from GNU gettext.
8472         * MODULES.html.sh (String handling): Add c-strstr.
8473
8474 2006-08-28  Bruno Haible  <bruno@clisp.org>
8475
8476         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
8477         macros.
8478         Reported by Eric Blake.
8479
8480 2006-08-28  Bruno Haible  <bruno@clisp.org>
8481
8482         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
8483         (VASNPRINTF): Return a string of length > INT_MAX without failing.
8484         * lib/vasprintf.c: Include errno.h, limits.h.
8485         (EOVERFLOW): New fallback definition.
8486         (vasprintf): Test here whether the string length is > INT_MAX.
8487         * lib/vsnprintf.c: Include errno.h, limits.h.
8488         (EOVERFLOW): New fallback definition.
8489         (vsnprintf): Fix bug when generated string was too long for the buffer.
8490         Test here whether the string length is > INT_MAX.
8491
8492 2006-08-28  Bruno Haible  <bruno@clisp.org>
8493
8494         * lib/inttypes_.h (SCNX*): Remove definitions.
8495         Reported by Eric Blake.
8496
8497 2006-08-28  Bruno Haible  <bruno@clisp.org>
8498
8499         * lib/c-strstr.h: New file, from GNU gettext.
8500         * lib/c-strstr.c: New file, from GNU gettext.
8501
8502 2006-08-28  Bruno Haible  <bruno@clisp.org>
8503
8504         * gnulib-tool: Reorder some statements.
8505
8506 2006-08-28  Bruno Haible  <bruno@clisp.org>
8507
8508         * gnulib-tool: New option --makefile-name.
8509         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
8510         $makefile_name.
8511         (func_import): Write $makefile_name to the cache file, and read it from
8512         there unless explicitly specified. Use $makefile_name as file name
8513         instead of Makefile.am. Adjust the recommendations accordingly.
8514
8515 2006-08-28  Bruno Haible  <bruno@clisp.org>
8516
8517         * gnulib-tool (func_verify_module): Check against misapplying patch.
8518
8519 2006-08-28  Bruno Haible  <bruno@clisp.org>
8520
8521         * gnulib-tool (func_relativize, func_relconcat): New functions.
8522         Give an error if --local-dir is given with --update.
8523         Remove trailing slashes from $local_gnulib_dir.
8524         (func_import): Store the relativized $local_gnulib_dir in
8525         gnulib-cache.m4, and read it from there if not specified explicitly.
8526
8527 2006-08-28  Bruno Haible  <bruno@clisp.org>
8528
8529         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
8530         is the current directory. Respect also $local_gnulib_dir.
8531
8532 2006-08-28  Bruno Haible  <bruno@clisp.org>
8533             Simon Josefsson  <jas@extundo.com>
8534
8535         BeOS portability.
8536         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
8537
8538 2006-08-27  Jim Meyering  <jim@meyering.net>
8539
8540         * doc/visibility.texi: Remove duplicate word: "pointer".
8541
8542 2006-08-26  Bruno Haible  <bruno@clisp.org>
8543
8544         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
8545         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
8546         (Makefile.am): Create inttypes.h from inttypes_.h.
8547         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
8548
8549         * modules/imaxabs: New file.
8550
8551         * modules/imaxdiv: New file.
8552
8553 2006-08-26  Bruno Haible  <bruno@clisp.org>
8554
8555         * m4/inttypes.m4: New file.
8556         * m4/_inttypes_h.m4: Remove file.
8557         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
8558         PRI_MACROS_BROKEN.
8559         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
8560
8561         * m4/imaxabs.m4: New file.
8562
8563         * m4/imaxdiv.m4: New file.
8564
8565 2006-08-26  Bruno Haible  <bruno@clisp.org>
8566
8567         * lib/inttypes_.h: New file.
8568         * lib/inttypes.h: Remove file.
8569         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
8570
8571         * lib/imaxabs.c: New file.
8572
8573         * lib/imaxdiv.c: New file.
8574
8575 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8576
8577         New config-h module, so that "make" output needn't be cluttered
8578         by -DHAVE_CONFIG_H.
8579         * MODULES.html.sh (Support for building libraries and executables):
8580         Add config-h.
8581         * modules/config-h: New file.
8582         * gnulib-tool (nl, sed_transform_lib_file): New vars.
8583         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
8584         the config-h module is used.
8585
8586         New configmake module, so that "make" output needn't be cluttered
8587         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
8588         * MODULES.html.sh (Support for building libraries and executables):
8589         Add configmake.
8590         * modules/configmake: New file.
8591
8592 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8593
8594         * m4/config-h.m4: New file.
8595
8596 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8597
8598         * config/srclist.txt: Add elisp-comp.
8599
8600 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8601
8602         * MODULES.html.sh (Support for building libraries and executables):
8603         Add elisp-comp.
8604         * build-aux/elisp-comp: New file.
8605         * modules/elisp-comp: New file.
8606
8607 2006-08-24  Bruno Haible  <bruno@clisp.org>
8608
8609         * gnulib-tool (func_create_testdir): Use non-default values of
8610         sourcebase and m4base.
8611
8612 2006-08-24  Bruno Haible  <bruno@clisp.org>
8613
8614         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
8615         HTML structure.
8616
8617 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
8618
8619         * modules/openat (Depends-on): Add lchown.
8620
8621 2006-08-23  Bruno Haible  <bruno@clisp.org>
8622
8623         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
8624         of gl_LOCK_EARLY instead of gl_LOCK.
8625
8626 2006-08-23  Bruno Haible  <bruno@clisp.org>
8627
8628         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
8629         on OSF/1 to no.
8630         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
8631
8632 2006-08-23  Bruno Haible  <bruno@clisp.org>
8633
8634         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
8635         as unusable.
8636
8637         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
8638         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
8639         (gl_LOCK): New macro.
8640
8641 2006-08-22  Simon Josefsson  <jas@extundo.com>
8642
8643         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
8644         to md5 module.
8645
8646 2006-08-22  Simon Josefsson  <jas@extundo.com>
8647
8648         * MODULES.html.sh: Add "Support for maintaining and release
8649         projects".
8650
8651         * build-aux/gnupload: New file, from coreutils.
8652
8653 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8654
8655         Avoid the need for AC_LIBSOURCES in m4 macros.
8656         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
8657         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
8658         * modules/check-version (EXTRA_DIST): Add check-version.h.
8659         * modules/crc (EXTRA_DIST): Add crc.h.
8660         * modules/des (EXTRA_DIST): Add des.h.
8661         * modules/gc (EXTRA_DIST): Add gc.h.
8662         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
8663         * modules/getline (EXTRA_DIST): Add getline.h.
8664         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
8665         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
8666         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
8667         * modules/md2 (EXTRA_DIST): Add md2.h.
8668         * modules/md4 (EXTRA_DIST): Add md4.h.
8669         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
8670         * modules/read-file (EXTRA_DIST): Add read-file.h.
8671         * modules/readline (EXTRA_DIST): Add readline.h.
8672         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
8673         rijndael-api-fst.h.
8674
8675 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8676
8677         * m4/rijndael.m4 (gl_ARCFOUR):
8678         * m4/arctwo.m4 (gl_ARCTWO):
8679         * m4/check-version.m4 (gl_CHECK_VERSION):
8680         * m4/crc.m4 (gl_CRC):
8681         * m4/des.m4 (gl_DES):
8682         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
8683         * m4/gc.m4 (gl_GC):
8684         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
8685         * m4/getline.m4 (gl_FUNC_GETLINE):
8686         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
8687         * m4/hmac-md5.m4 (gl_HMAC_MD5):
8688         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
8689         * m4/md2.m4 (gl_MD2):
8690         * m4/md4.m4 (gl_MD4):
8691         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
8692         * m4/read-file.m4 (gl_FUNC_READ_FILE):
8693         * m4/readline.m4 (gl_FUNC_READLINE):
8694         * m4/rijndael.m4 (gl_RIJNDAEL):
8695         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
8696         to get the necessary .h files and whatnot.
8697
8698 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8699
8700         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
8701         gnulib rather than the other way around.
8702         * config/srclistvars.sh (COREUTILS): Remove.
8703
8704 2006-08-22  Jim Meyering  <jim@meyering.net>
8705
8706         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
8707
8708         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
8709
8710 2006-08-22  Eric Blake  <ebb9@byu.net>
8711
8712         * modules/regexprops-generic: New file.
8713         * MODULES.html.sh (Support for building documentation): List it.
8714
8715 2006-08-22  Eric Blake  <ebb9@byu.net>
8716
8717         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
8718         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
8719         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
8720         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
8721
8722 2006-08-22  Bruno Haible  <bruno@clisp.org>
8723
8724         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
8725         and lib_LTLIBRARIES like the other lib_* variables.
8726
8727 2006-08-22  Bruno Haible  <bruno@clisp.org>
8728
8729         * build-aux/x-to-1.in: New file, from GNU gettext.
8730
8731 2006-08-22  Bruno Haible  <bruno@clisp.org>
8732
8733         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
8734         <utmpx.h> exists.
8735
8736 2006-08-22  Bruno Haible  <bruno@clisp.org>
8737
8738         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
8739         <utmpx.h> exists.
8740
8741 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8742
8743         BeOS portability.
8744         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
8745         exist.
8746         Problem reported by Bruno Haible.
8747
8748 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8749
8750         Avoid the need for AC_LIBSOURCES in m4 macros.
8751         * modules/acl (EXTRA_DIST): Add acl.h.
8752         * modules/argmatch (Files): Add m4/argmatch.m4.
8753         (configure.ac): Add gl_ARGMATCH.
8754         (EXTRA_DIST): Renamed from lib_SOURCES, for
8755         consistency with the other modules.  Remove argmatch.c.
8756         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
8757         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
8758         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
8759         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
8760         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
8761         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
8762         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
8763         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
8764         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
8765         * modules/closeout (EXTRA_DIST): Add closeout.h.
8766         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
8767         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
8768         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
8769         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
8770         dirname.h; remove basename.c and stripslash.c.
8771         * modules/exclude (EXTRA_DIST): Add exclude.h.
8772         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
8773         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
8774         * modules/file-type (EXTRA_DIST): Add file-type.h.
8775         * modules/filemode (EXTRA_DIST): Add filemode.h.
8776         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
8777         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
8778         * modules/fpending (EXTRA_DIST): Add __fpending.h.
8779         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
8780         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
8781         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
8782         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
8783         * modules/getdate (EXTRA_DIST): Add getdate.c.
8784         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
8785         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
8786         * modules/getpass (EXTRA_DIST): Add getpass.h.
8787         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
8788         * modules/group-member (EXTRA_DIST): Add group-member.h.
8789         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
8790         * modules/hash (EXTRA_DIST): Add hash.h.
8791         * modules/human (EXTRA_DIST): Add human.h.
8792         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
8793         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
8794         * modules/lchown (EXTRA_DIST): Add lchown.h.
8795         * modules/long-options (EXTRA_DIST): Add long-options.h.
8796         * modules/lstat (EXTRA_DIST): Add lstat.h.
8797         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
8798         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
8799         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
8800         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
8801         * modules/memxor (EXTRA_DIST): Add memxor.h.
8802         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
8803         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
8804         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
8805         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
8806         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
8807         * modules/physmem (EXTRA_DIST): Add physmem.h.
8808         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
8809         * modules/posixver (EXTRA_DIST): Add posixver.h.
8810         * modules/quote (EXTRA_DIST): Add quote.h.
8811         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
8812         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
8813         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
8814         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
8815         regex_internal.h regexec.c.
8816         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
8817         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
8818         * modules/same (EXTRA_DIST): Add same.h.
8819         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
8820         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
8821         * modules/savedir (EXTRA_DIST): Add savedir.h.
8822         * modules/sha1 (EXTRA_DIST): Add sha1.h.
8823         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
8824         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
8825         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
8826         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
8827         * modules/strdup (EXTRA_DIST): Add strdup.h.
8828         * modules/strftime (EXTRA_DIST): Add strftime.h.
8829         * modules/strndup (EXTRA_DIST): Add strndup.h.
8830         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
8831         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
8832         * modules/time_r (EXTRA_DIST): Add time_r.h.
8833         * modules/timespec (EXTRA_DIST): Add timespec.h.
8834         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
8835         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
8836         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
8837         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
8838         * modules/userspec (EXTRA_DIST): Add userspec.h.
8839         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
8840         * modules/utimens (EXTRA_DIST): Add utimens.h.
8841         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
8842         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
8843         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
8844         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
8845         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
8846         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
8847         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
8848         * modules/yesno (EXTRA_DIST): Add yesno.h.
8849
8850 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8851
8852         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
8853
8854         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
8855         * m4/dev-ino.m4, same-inode.m4: Remove.
8856
8857         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
8858         * m4/acl.m4 (AC_FUNC_ACL):
8859         * m4/backupfile.m4 (gl_BACKUPFILE):
8860         * m4/c-strtod.m4 (gl_C99_STRTOLD):
8861         * m4/canon-host.m4 (gl_CANON_HOST):
8862         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
8863         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
8864         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
8865         * m4/cloexec.m4 (gl_CLOEXEC):
8866         * m4/close-stream.m4 (gl_CLOSE_STREAM):
8867         * m4/closeout.m4 (gl_CLOSEOUT):
8868         * m4/dirfd.m4 (gl_FUNC_DIRFD):
8869         * m4/dirname.m4 (gl_DIRNAME):
8870         * m4/exclude.m4 (gl_EXCLUDE):
8871         * m4/exitfail.m4 (gl_EXITFAIL):
8872         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
8873         * m4/file-type.m4 (gl_FILE_TYPE):
8874         * m4/filemode.m4 (gl_FILEMODE):
8875         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
8876         * m4/fpending.m4 (gl_FUNC_FPENDING):
8877         * m4/fprintftime.m4 (gl_FPRINTFTIME):
8878         * m4/fts.m4 (gl_FUNC_FTS):
8879         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
8880         * m4/getdate.m4 (gl_GETDATE):
8881         * m4/gethrxtime.m4 (gl_GETHRXTIME):
8882         * m4/getpagesize.m4 (gl_GETPAGESIZE):
8883         * m4/getpass.m4 (gl_FUNC_GETPASS):
8884         * m4/gettime.m4 (gl_GETTIME):
8885         * m4/getugroups.m4 (gl_GETUGROUPS):
8886         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
8887         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
8888         * m4/hard-locale.m4 (gl_HARD_LOCALE):
8889         * m4/hash.m4 (gl_HASH):
8890         * m4/idcache.m4 (gl_IDCACHE):
8891         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
8892         * m4/lchown.m4 (gl_FUNC_LCHOWN):
8893         * m4/long-options.m4 (gl_LONG_OPTIONS):
8894         * m4/lstat.m4 (gl_FUNC_LSTAT):
8895         * m4/md5.m4 (gl_MD5):
8896         * m4/memcasecmp.m4 (gl_MEMCASECMP):
8897         * m4/memcoll.m4 (gl_MEMCOLL):
8898         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
8899         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
8900         * m4/memxor.m4 (gl_MEMXOR):
8901         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
8902         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
8903         * m4/modechange.m4 (gl_MODECHANGE):
8904         * m4/mountlist.m4 (gl_MOUNTLIST):
8905         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
8906         * m4/openat.m4 (gl_FUNC_OPENAT):
8907         * m4/pathmax.m4 (gl_PATHMAX):
8908         * m4/physmem.m4 (gl_PHYSMEM):
8909         * m4/posixtm.m4 (gl_POSIXTM):
8910         * m4/posixver.m4 (gl_POSIXVER):
8911         * m4/quote.m4 (gl_QUOTE):
8912         * m4/quotearg.m4 (gl_QUOTEARG):
8913         * m4/readtokens.m4 (gl_READTOKENS):
8914         * m4/readutmp.m4 (gl_READUTMP):
8915         * m4/regex.m4 (gl_REGEX):
8916         * m4/safe-read.m4 (gl_SAFE_READ):
8917         * m4/safe-write.m4 (gl_SAFE_WRITE):
8918         * m4/same.m4 (gl_SAME):
8919         * m4/save-cwd.m4 (gl_SAVE_CWD):
8920         * m4/savedir.m4 (gl_SAVEDIR):
8921         * m4/settime.m4 (gl_SETTIME):
8922         * m4/sha1.m4 (gl_SHA1):
8923         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
8924         * m4/stat-macros.m4 (gl_STAT_MACROS):
8925         * m4/stat-time.m4 (gl_STAT_TIME):
8926         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
8927         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
8928         * m4/strdup.m4 (gl_FUNC_STRDUP):
8929         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
8930         * m4/strndup.m4 (gl_FUNC_STRNDUP):
8931         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
8932         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
8933         * m4/time_r.m4 (gl_TIME_R):
8934         * m4/timespec.m4 (gl_TIMESPEC):
8935         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
8936         * m4/unlinkdir.m4 (gl_UNLINKDIR):
8937         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
8938         * m4/userspec.m4 (gl_USERSPEC):
8939         * m4/utimecmp.m4 (gl_UTIMECMP):
8940         * m4/utimens.m4 (gl_UTIMENS):
8941         * m4/xalloc.m4 (gl_XALLOC):
8942         * m4/xgetcwd.m4 (gl_XGETCWD):
8943         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
8944         * m4/xreadlink.m4 (gl_XREADLINK):
8945         * m4/xstrtod.m4 (gl_XSTRTOD):
8946         * m4/yesno.m4 (gl_YESNO):
8947         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
8948         to get the necessary .h files and whatnot.
8949
8950 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
8951             Bruno Haible  <bruno@clisp.org>
8952
8953         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
8954         /bin/sh understanding of '!' conditional negation.
8955
8956 2006-08-21  Jim Meyering  <jim@meyering.net>
8957
8958         * modules/openat (Depends-on): Really alphabetize.
8959
8960         * modules/acl (Depends-on): Add error and quote.
8961
8962         * check-module (find_included_lib_files): Add at-func.c to the
8963         ok-to-include-more-than-once white list.
8964
8965         * modules/openat (Depends-on): Add lstat.  Alphabetize.
8966
8967 2006-08-21  Bruno Haible  <bruno@clisp.org>
8968
8969         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8970         Emit a pkgdata_DATA variable only if some snippets add contents to it.
8971         Reported by Martin Lambers <marlam@marlam.de>.
8972
8973 2006-08-21  Bruno Haible  <bruno@clisp.org>
8974
8975         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
8976         specify an installation location, don't emit a noinst_LIBRARIES or
8977         noinst_LTLIBRARIES assignment.
8978
8979 2006-08-21  Bruno Haible  <bruno@clisp.org>
8980
8981         BeOS portability.
8982         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
8983         BeOS has mbrtowc() but no <wctype.h>.
8984
8985 2006-08-21  Bruno Haible  <bruno@clisp.org>
8986
8987         BeOS portability.
8988         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
8989         exist.
8990
8991 2006-08-21  Bruno Haible  <bruno@clisp.org>
8992
8993         BeOS portability.
8994         * lib/mbchar.h: Include <wctype.h> only if it exists.
8995
8996 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8997
8998         Remove files that are no longer needed by their respective modules.
8999         * m4/obstack.m4: Remove.
9000         * m4/strerror_r.m4: Remove.
9001         * m4/uint32_t.m4: Remove.
9002         * m4/uintptr_t.m4: Remove.
9003         * m4/ullong_max.m4: Remove.
9004         * m4/xstrtoimax.m4: Remove.
9005         * m4/xstrtoumax.m4: Remove.
9006
9007         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
9008         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
9009         dependencies now capture this.
9010
9011         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
9012         Do not use AC_LIBSOURCES, since gnulib modules now do this.
9013         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
9014         * m4/human.m4 (gl_HUMAN): Likewise.
9015         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
9016         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
9017
9018         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
9019
9020         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
9021         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
9022         stdint.
9023         * m4/human.m4 (gl_HUMAN): Likewise.
9024         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
9025         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
9026         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
9027         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
9028         * m4/xstrtol (gl_XSTRTOL): Likewise.
9029
9030         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
9031         AC_TYPE_LONG_LONG_INT.
9032         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
9033         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
9034         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
9035         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
9036
9037         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
9038         on stdbool.
9039
9040         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
9041         (gl_PREREQ_XSTRTOUL): Remove.
9042
9043         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
9044
9045         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
9046         mode.
9047
9048 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9049
9050         Add and change modules to make it easier for coreutils to use
9051         gnulib-tool.
9052         * modules/backupfile (Files): Remove m4/d-ino.m4.
9053         (Depends-on): Add d-ino.
9054         * modules/cycle-check (Depends-on): Add stdint.
9055         (lib_SOURCES): Add cycle-check.h.
9056         * modules/d-ino: New module.
9057         * modules/d-type: New module.
9058         * modules/error (Files): Remove m4/strerror_r.m4.
9059         * modules/filemode (Files): Add m4/st_dm_mode.m4.
9060         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
9061         m4/inttypes_h.m4, m4/uintmax_t.m4.
9062         (Depends-on): Add stdint.
9063         (lib_SOURCES): Add fsusage.h.
9064         * modules/getcwd (Files): Remove d-ino.m4.
9065         (Depends-on): Add d-ino.
9066         * modules/getndelim2 (Depends-on): Add stdint.
9067         * modules/glob (Files): Remove m4/d-type.m4.
9068         (Depends-on): Add d-type.
9069         * modules/host-os: New module.
9070         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
9071         m4/inttypes_h.m4, m4/uintmax_t.m4.
9072         * Depends-on: Add stdint.
9073         (lib_SOURCES): Add human.h.
9074         * modules/inttostr (Files): Remove m4/intmax_t.m4,
9075         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
9076         m4/uintmax_t.m4, m4/ulonglong.m4.
9077         (Depends-on): Add stdint.
9078         (EXTRA_DIST): Add inttostr.h.
9079         * modules/lchmod: New module.
9080         * modules/link-follow: New module.
9081         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
9082         (Depends-on): Add lchmod.
9083         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
9084         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
9085         (Depends-on): Add stdint.
9086         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
9087         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
9088         (Depends-on): Add stdint.
9089         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
9090         * modules/perl: New module.
9091         * modules/regex (Depends-on): Add stdint.
9092         * modules/rmdir-errno: New module.
9093         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
9094         m4/intmax_t.m4.
9095         (Depends-on): Add stdint.
9096         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
9097         m4/uintmax_t.m4.
9098         (Depends-on): Add stdint.
9099         * modules/unlink-busy: New module.
9100         * modules/utimecmp (Depends-on): Add stdint.
9101         * modules/uptime: New module.
9102         * modules/winsz-ioctl: New module.
9103         * modules/winsz-termios: New module.
9104         * modules/xnanosleep (Depends-on): Add nanosleep.
9105         * modules/ullong_max: Remove.
9106         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
9107         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
9108         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
9109         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
9110         (Depends-on): Add inttypes.
9111         (lib_SOURCES): Add xstrtol.h.
9112         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
9113         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
9114         * MODULES.html.sh: Move 'assert' into the assert section.
9115         Move 'dummy' into the linking section.
9116         Remove ullong_max.
9117         Add section for compatibility checks for POSIX:2001 functions,
9118         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
9119         winsz-ioctl, and winsz-termios into it.
9120         Add lchmod.
9121         Add top-level Misc section and put host-os, perl, and uptime
9122         into it.
9123
9124 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9125
9126         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
9127         now assume the stdint module.  Do not include inttypes.h.
9128         * lib/fsusage.h: Likewise.
9129         * lib/getndelim2.c: Likewise.
9130         * lib/human.h: Likewise.
9131         * lib/inttostr.h: Likewise.
9132         * lib/obstack.c: Likewise.
9133         * lib/regex_internal.h: Likewise.
9134         * lib/tempname.c: Likewise.
9135         * lib/utimecmp.c: Likewise.
9136         * lib/xstrtol.h: Likewise.
9137
9138         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
9139
9140         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
9141         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
9142         * lib/xtime.h: Likewise.
9143
9144 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
9145
9146         * modules/openat (Files): Add lib/fchmodat.c.
9147         Fixes problem reported by Jay Youngman.
9148
9149 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
9150
9151         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
9152         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
9153
9154 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
9155             Bruno Haible  <bruno@clisp.org>
9156
9157         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
9158         and is a script that invokes bison. Tighten the code. Add comments.
9159
9160 2006-08-18  Jim Meyering  <jim@meyering.net>
9161
9162         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
9163         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
9164         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
9165         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
9166
9167 2006-08-18  Bruno Haible  <bruno@clisp.org>
9168
9169         * modules/bison-i18n: New file.
9170         * MODULES.html.sh (Internationalization functions): Add it.
9171
9172 2006-08-18  Bruno Haible  <bruno@clisp.org>
9173
9174         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
9175         sys/statvfs.h. When getmntinfo was found, check its declaration and
9176         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
9177
9178 2006-08-18  Bruno Haible  <bruno@clisp.org>
9179
9180         * m4/bison-i18n.m4: New file, from bison.
9181
9182 2006-08-18  Bruno Haible  <bruno@clisp.org>
9183
9184         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
9185         (ME_DUMMY): Treat "kernfs" as a dummy.
9186         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
9187
9188 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
9189
9190         Update from coreutils.
9191
9192         2006-08-15  Jim Meyering  <jim@meyering.net>
9193
9194         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
9195
9196         2006-01-17  Jim Meyering  <jim@meyering.net>
9197
9198         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
9199
9200         2006-01-11  Jim Meyering  <jim@meyering.net>
9201
9202         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
9203         Check for the lchmod function.
9204
9205 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
9206
9207         Update from coreutils.
9208
9209         * lib/__fpending.h: Add copyright notice.
9210         * lib/fprintftime.h: Likewise.
9211         * lib/savedir.c: Use (C) in copyright notice.
9212         * lib/savedir.h: Likewise.
9213
9214         2006-08-15  Jim Meyering  <jim@meyering.net>
9215
9216         * lib/at-func.c: New file, with the logic of all emulated at-functions.
9217         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
9218         in support of the EXPECTED_ERRNO macro.
9219         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
9220         definitions.  Instead, define the appropriate symbols and include
9221         "at-func.c".
9222         * lib/mkdirat.c (mkdirat): Likewise.
9223         * lib/fchmodat.c (fchmodat): Likewise.
9224         (ENOSYS): Remove definition.
9225         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
9226         it.  Don't include "unistd--.h" -- it wasn't ever used.
9227
9228         2006-01-17  Jim Meyering  <jim@meyering.net>
9229
9230         Rewrite fts.c not to change the current working directory,
9231         by using openat, fstatat, fdopendir, etc..
9232
9233         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
9234         (HAVE_OPENAT_SUPPORT): Define.
9235         [_LIBC] (fchdir): Don't undef or define; no longer used.
9236         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
9237         Now, this `function' always succeeds, and consumes its file descriptor
9238         parameter -- so callers must not close such FDs.  Update callers.
9239         (diropen_fd, opendirat, cwd_advance_fd): New functions.
9240         (diropen): Add parameter, SP.  Adjust all callers.
9241         Implement using diropen_fd, rather than open.
9242         (fts_open): Initialize new member, fts_cwd_fd.
9243         Remove fts_rft-setting code.
9244         (fts_close): Close fts_cwd_fd, if necessary.
9245         (__opendir2): Define in terms of opendir or opendirat,
9246         depending on whether the FST_NOCHDIR flag is set.
9247         (fts_build): Since fts_safe_changedir consumes its FD, and since
9248         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
9249         and close the dup'd file descriptor upon failure.
9250         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
9251         (fts_safe_changedir): Tweak semantics to reflect that this function
9252         now calls cwd_advance_fd and hence consumes its FD argument.
9253         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
9254         [struct FTS] (fts_rft): Remove now-unused member.
9255         [struct FTS] (fts_cycle.state): Improve comment.
9256
9257         * lib/openat.c (openat_needs_fchdir): New function.
9258         * lib/openat.h (openat_needs_fchdir): Declare it.
9259
9260 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
9261
9262         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
9263         Problem and fix reported by Pádraig Brady in
9264         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
9265
9266 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
9267
9268         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
9269
9270 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
9271
9272         * lib/memcoll.c (memcoll): Optimize for the common case where the
9273         arguments are bytewise equal.
9274
9275 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
9276
9277         * doc/regexprops-generic.texi: Add a copyright notice.
9278
9279 2006-08-15  Bruno Haible  <bruno@clisp.org>
9280
9281         * modules/tmpdir (License): Change to LGPL.
9282
9283 2006-08-15  Bruno Haible  <bruno@clisp.org>
9284
9285         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
9286         module.
9287
9288 2006-08-14  Simon Josefsson  <jas@extundo.com>
9289
9290         * config/srclist.txt: Add gnupload.
9291
9292 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9293
9294         Change copyright notice from LGPL 2 to GPL 2, since that's the
9295         standard form used in the gnulib repository.
9296         * tests/test-lock.c: Likewise.
9297         * tests/test-stdint.c: Likewise.
9298         * tests/test-tls.c: Likewise.
9299
9300         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
9301         prelude-manager.  User shorter URLs for GNU projects, without '?'.
9302         Add copyright notice.
9303
9304         * check-module: Add copyright notice.  Output a copyright
9305         notice if "--version" is specified.
9306         * modules/COPYING: New file.
9307         * tests/test-getaddrinfo.c: Add copyright notice.
9308         * tests/test-verify.c: Likewise.
9309
9310 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9311
9312         Change copyright notice from LGPL 2 to GPL 2, since that's the
9313         standard form used in the gnulib repository.
9314         * lib/lock.c: LGPL -> GPL.
9315         * lib/lock.h: Likewise.
9316         * lib/strnlen1.c: Likewise.
9317         * lib/strnlen1.h: Likewise.
9318         * lib/tls.c: Likewise.
9319         * lib/tls.h: Likewise.
9320         * lib/tmpdir.c: Likewise.
9321
9322         * lib/TODO: Remove; this belongs only in coreutils.
9323
9324 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9325
9326         Add copyright notices to long-enough files that lack them, since
9327         otherwise the files aren't clearly free.  Use the same notice that
9328         getdate.texi already uses.
9329         * doc/alloca-opt.texi: Add copyright notice.
9330         * doc/alloca.texi: Likewise.
9331         * doc/ctime.texi: Likewise.
9332         * doc/functions.texi: Likewise.
9333         * doc/gcd.texi: Likewise.
9334         * doc/gnulib-tool.texi: Likewise.
9335         * doc/inet_ntoa.texi: Likewise.
9336         * doc/visibility.texi: Likewise.
9337
9338         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
9339         * doc/quote.texi: Add copyright notice.
9340
9341         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
9342         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
9343         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
9344         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
9345         is now obsolete, and give a pointer to the Sun list.
9346         Add copyright notice.
9347
9348 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9349
9350         * config/srclistvars.sh: Add copyright notice.
9351
9352 2006-08-14  Eric Blake  <ebb9@byu.net>
9353
9354         Import the following change from libc:
9355
9356         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
9357
9358         Upstream bug 2997.
9359         * lib/misc/error.c: Add space between program name and message if file
9360         name is missing.
9361
9362 2006-08-12  Karl Berry  <karl@gnu.org>
9363
9364         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
9365         remove, these originate in gnulib now.
9366
9367 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9368
9369         * doc/Makefile (standards.info standards.html standards.dvi):
9370         Also depend on make-stds.texi.
9371
9372 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
9373
9374         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
9375         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
9376
9377         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
9378         in wchar_t.  Problem reported by Eric Blake.
9379
9380         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
9381         LEN is smaller than SIZE.  Suggested by Bruno Haible.
9382         Also, help the compiler to keep LEN in a register.
9383
9384 2006-08-11  Eric Blake  <ebb9@byu.net>
9385
9386         * users.txt: Sort.  Add tar.
9387
9388 2006-08-11  Bruno Haible  <bruno@clisp.org>
9389
9390         * users.txt: New file.
9391
9392 2006-08-11  Bruno Haible  <bruno@clisp.org>
9393
9394         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
9395         before <wchar.h>. Needed for OSF/1 and BSD/OS.
9396
9397 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
9398
9399         * modules/snprintf (Depends-on): Remove minmax.
9400         (Maintainer): Add self and Bruno.
9401
9402 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
9403
9404         * lib/.cppi-disable: Add snprintf.h, socket_.h.
9405         * lib/snprintf.c: Include <errno.h> and <limits.h>.
9406         (EOVERFLOW): Define if the system does not.
9407         Do not include "minmax.h"; it wasn't used.
9408         (snprintf): Don't assume size_t promotes to an unsigned type.
9409         Fix bug when generated string was too long for the buffer: the
9410         buffer's contents are supposed to be the initial prefix of the
9411         output.  Don't assume vasnprintf returns EOVERFLOW if the size
9412         exceeds INT_MAX; do the check ourselves.
9413
9414         Import the following changes from libc:
9415
9416         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
9417
9418         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
9419         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
9420         set wc to the byte which couldn't be converted.
9421         (re_string_reconstruct): Don't clear valid_raw_len before calling
9422         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
9423         tip_context using re_string_context_at.
9424
9425         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
9426
9427         * lib/posix/regex.h: g++ still cannot handled [restrict].
9428
9429         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
9430
9431         * lib/posix/regex.h: Remove special handling for VMS.
9432
9433 2006-08-10  Jim Meyering  <jim@meyering.net>
9434
9435         * modules/same-inode: New module.
9436         * modules/dev-ino: New module.
9437         * modules/cycle-check: Depend on these modules, rather than simply
9438         including their .h files.
9439         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
9440         required via m4/cycle-check.m4.
9441         * modules/same: Depend on new same-inode module, rather than
9442         including same-inode.h.
9443         * modules/chdir-safer: New file.
9444
9445         * modules/chown (Depends-on): Add stat-macros.
9446
9447 2006-08-10  Jim Meyering  <jim@meyering.net>
9448
9449         * m4/cycle-check.m4: New file.
9450         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
9451         * m4/dev-ino.m4, m4/same-inode.m4: New files.
9452
9453 2006-08-10  Eric Blake  <ebb9@byu.net>
9454
9455         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
9456         in from original proposal.
9457
9458 2006-08-10  Eric Blake  <ebb9@byu.net>
9459         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
9460
9461         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
9462         namespace.
9463
9464 2006-08-10  Bruno Haible  <bruno@clisp.org>
9465
9466         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
9467         as well.
9468
9469 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
9470
9471         Sync from coreutils.
9472
9473         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
9474
9475         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
9476         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
9477
9478 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
9479
9480         * modules/restrict: Remove; no longer needed now that we assume
9481         Autoconf 2.59 or later.
9482         * MODULES.html.sh: Remove 'restrict'.
9483         * modules/argp (Depends-on): Remove 'restrict'.
9484         * modules/base64 (Depends-on): Likewise.
9485         * modules/gc (Depends-on): Likewise.
9486         * modules/getaddrinfo (Depends-on): Likewise.
9487         * modules/glob (Depends-on): Likewise.
9488         * modules/inet_ntop (Depends-on): Likewise.
9489         * modules/inet_pton (Depends-on): Likewise.
9490         * modules/memxor (Depends-on): Likewise.
9491         * modules/regex (Depends-on): Likewise.
9492         * modules/strtok_r (Depends-on): Likewise.
9493         * modules/time_r (Depends-on): Likewise.
9494
9495 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
9496
9497         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
9498         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
9499         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
9500         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
9501         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
9502         * m4/memxor.m4 (gl_MEMXOR): Likewise.
9503         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
9504         gl_C_RESTRICT replaced by AC_C_RESTRICT.
9505
9506         Merge from coreutils.
9507         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
9508         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
9509         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
9510         * m4/time_r.m4 (gl_TIME_R): Likewise.
9511
9512 2006-08-09  Karl Berry  <karl@gnu.org>
9513
9514         * config/srclist.txt: no more gettext-tools, per Bruno.
9515
9516 2006-08-08  Eric Blake  <ebb9@byu.net>
9517
9518         * modules/verror: New module.
9519         * MODULES.html.sh: Document it.
9520
9521 2006-08-08  Eric Blake  <ebb9@byu.net>
9522
9523         * lib/verror.h, lib/verror.c: New files.
9524
9525 2006-08-08  Eric Blake  <ebb9@byu.net>
9526
9527         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
9528         verror_at_line output complies with GNU Coding Standards even when
9529         file is NULL.
9530
9531 2006-08-07  Bruno Haible  <bruno@clisp.org>
9532
9533         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
9534         versions of AIX.
9535         Reported by Ralf Wildenhues.
9536
9537 2006-08-07  Bruno Haible  <bruno@clisp.org>
9538
9539         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
9540         in an AC_DEFUN. Needed so that the autoconf snippets can use
9541         AC_REQUIRE.
9542
9543 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9544
9545         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9546         Initialize pkgdata_DATA.
9547         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
9548         overriding it.
9549
9550 2006-08-06  Eric Blake  <ebb9@byu.net>
9551
9552         * lib/error.h: Fold in some upstream changes from glibc.
9553         * lib/error.c: Likewise.
9554
9555 2006-08-04  Bruno Haible  <bruno@clisp.org>
9556
9557         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9558         Make the mostlyclean-local rule depend on mostlyclean-generic.
9559         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
9560
9561 2006-07-31  Bruno Haible  <bruno@clisp.org>
9562
9563         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
9564         <stdlib.h>, <string.h>.
9565
9566 2006-07-30  Bruno Haible  <bruno@clisp.org>
9567
9568         * modules/readlink (License): Change to LGPL.
9569
9570 2006-07-30  Bruno Haible  <bruno@clisp.org>
9571
9572         * modules/javaversion (Makefile.am): Distribute javaversion.java and
9573         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
9574         set PKGDATADIR to point to it.
9575
9576 2006-07-30  Bruno Haible  <bruno@clisp.org>
9577
9578         * modules/csharpexec (configure.ac): Comment out macro invocation.
9579         * modules/javaexec (configure.ac): Likewise.
9580         * modules/javacomp-script (configure.ac): Likewise.
9581
9582         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
9583
9584 2006-07-30  Bruno Haible  <bruno@clisp.org>
9585
9586         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
9587         linked-list.
9588
9589 2006-07-30  Bruno Haible  <bruno@clisp.org>
9590
9591         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
9592
9593 2006-07-30  Bruno Haible  <bruno@clisp.org>
9594
9595         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9596         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
9597         get removed.
9598
9599 2006-07-29  Bruno Haible  <bruno@clisp.org>
9600
9601         Make it possible for gnulib-tool to work with locally modified or
9602         augmented gnulib repositories.
9603         * gnulib-tool (func_usage): Document --local-dir option.
9604         (local_gnulib_dir): New variable.
9605         Handle --local-dir option.
9606         (func_lookup_file): New function.
9607         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
9608         (func_get_description, func_get_filelist, func_get_description,
9609         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
9610         func_get_automake_snippet, func_get_include_directive,
9611         func_get_license, func_get_maintainer): Use func_lookup_file.
9612         (func_import, func_create_testdir): Use func_lookup_file.
9613
9614 2006-07-29  Bruno Haible  <bruno@clisp.org>
9615
9616         * modules/setenv (Depends-on): Add unistd.
9617
9618 2006-07-29  Bruno Haible  <bruno@clisp.org>
9619
9620         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
9621
9622 2006-07-29  Bruno Haible  <bruno@clisp.org>
9623
9624         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
9625
9626 2006-07-29  Bruno Haible  <bruno@clisp.org>
9627
9628         * gnulib-tool (import, update): If there is no Makefile.am, look at
9629         aclocal.m4, instead of bailing out.
9630
9631 2006-07-29  Bruno Haible  <bruno@clisp.org>
9632
9633         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
9634         Categorize the options by when they are useful.
9635
9636 2006-07-29  Bruno Haible  <bruno@clisp.org>
9637
9638         * gnulib-tool (func_usage): Document option --no-libtool.
9639         Handle option --no-libtool.
9640         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
9641         for changed semantics of $libtool variable.
9642         (func_import): Likewise. If libtool is not used, show this through
9643         an option --no-libtool.
9644         (func_create_testdir): Update.
9645
9646 2006-07-29  Bruno Haible  <bruno@clisp.org>
9647
9648         * gnulib-tool (func_import): Extend error message about missing
9649         --doc-base.
9650
9651 2006-07-29  Bruno Haible  <bruno@clisp.org>
9652
9653         * gnulib-tool (func_import): Don't create the $docbase directory if
9654         there is no file to store there.
9655
9656 2006-07-29  Bruno Haible  <bruno@clisp.org>
9657
9658         * gnulib-tool (autoconf_minversion): If a --dir option is given and
9659         relevant, look for configure.ac there, not in the current directory.
9660         Also use a simple search for AC_PREREQ, not "autoconf --trace".
9661
9662 2006-07-29  Bruno Haible  <bruno@clisp.org>
9663
9664         * gnulib-tool (SORT): New variable.
9665         (func_usage): Undocument --assume-autoconf option.
9666         Remove --assume-autoconf option handling.
9667         (autoconf_minversion): Determine from the contents of configure.ac.
9668         (func_import): Remove autoconf_minversion handling.
9669         Suggested by Eric Blake.
9670
9671 2006-07-29  Bruno Haible  <bruno@clisp.org>
9672
9673         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
9674
9675 2006-07-29  Bruno Haible  <bruno@clisp.org>
9676
9677         * config/srclist.txt (*setenv.[ch]): Remove rules.
9678
9679 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9680
9681         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
9682
9683 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9684
9685         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
9686         arpa/inet.h.
9687
9688 2006-07-28  Simon Josefsson  <jas@extundo.com>
9689
9690         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
9691         * modules/inet_pton (Depends-on): Likewise.
9692
9693 2006-07-28  Simon Josefsson  <jas@extundo.com>
9694
9695         * m4/netinet_in_h.m4: New file.
9696
9697 2006-07-28  Simon Josefsson  <jas@extundo.com>
9698
9699         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
9700         #include's.
9701
9702 2006-07-28  Simon Josefsson  <jas@extundo.com>
9703
9704         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
9705         #include's.
9706
9707 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
9708
9709         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
9710         setgid on directories only if they set these bits.
9711         * lib/modechange.h: Remove obsolete comment about masks.
9712
9713 2006-07-28  Eric Blake  <ebb9@byu.net>
9714
9715         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
9716         macro expansion.
9717
9718 2006-07-28  Bruno Haible  <bruno@clisp.org>
9719
9720         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
9721
9722 2006-07-28  Bruno Haible  <bruno@clisp.org>
9723
9724         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
9725
9726 2006-07-28  Bruno Haible  <bruno@clisp.org>
9727
9728         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
9729         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
9730         Define fallbacks.
9731         Avoids link error on FreeBSD 4.x.
9732         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
9733
9734         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
9735         encoding.
9736         * lib/mbswidth.c (iswcntrl): Likewise.
9737
9738 2006-07-27  Bruno Haible  <bruno@clisp.org>
9739
9740         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
9741         test.
9742
9743 2006-07-27  Bruno Haible  <bruno@clisp.org>
9744
9745         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
9746         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
9747         defined.
9748
9749 2006-07-26  Eric Blake  <ebb9@byu.net>
9750
9751         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
9752
9753 2006-07-26  Eric Blake  <ebb9@byu.net>
9754
9755         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
9756         like mingw that lack mkstemp.
9757         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
9758         avoid compilation warning on mingw.
9759
9760 2006-07-26  Bruno Haible  <bruno@clisp.org>
9761
9762         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
9763         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
9764         INT_FAST*_MIN, INTPTR_MIN.
9765
9766 2006-07-25  Bruno Haible  <bruno@clisp.org>
9767
9768         * modules/version-etc (Depends-on): Add stdarg.
9769
9770 2006-07-25  Bruno Haible  <bruno@clisp.org>
9771
9772         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
9773         complex commands.
9774
9775 2006-07-25  Bruno Haible  <bruno@clisp.org>
9776
9777         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
9778         defined in <stdarg.h> or config.h.
9779
9780 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9781
9782         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
9783         (gl_STDIO_SAFER): Remove.
9784
9785 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9786
9787         * MODULES.html.sh (File stream based Input/Output):
9788         Add fopen-safer, tmpfile-safer; remove stdio-safer.
9789         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
9790         * modules/fopen-safer, modules/tmpfile-safer: New files.
9791         * modules/stdio-safer: Remove.
9792
9793 2006-07-24  Bruno Haible  <bruno@clisp.org>
9794
9795         * modules/tmpdir: New file.
9796         * MODULES.html.sh (File system functions): Add it.
9797
9798 2006-07-24  Bruno Haible  <bruno@clisp.org>
9799
9800         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
9801         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
9802
9803 2006-07-24  Bruno Haible  <bruno@clisp.org>
9804
9805         * modules/clean-temp: New file.
9806
9807 2006-07-24  Bruno Haible  <bruno@clisp.org>
9808
9809         * m4/tmpdir.m4: New file, from GNU gettext.
9810
9811 2006-07-24  Bruno Haible  <bruno@clisp.org>
9812
9813         * lib/tmpdir.h: New file, from GNU gettext.
9814         * lib/tmpdir.c: New file, from GNU gettext.
9815
9816 2006-07-24  Bruno Haible  <bruno@clisp.org>
9817
9818         * lib/clean-temp.h: New file, from GNU gettext.
9819         * lib/clean-temp.c: New file, from GNU gettext.
9820
9821 2006-07-23  Eric Blake  <ebb9@byu.net>
9822
9823         * modules/stdio-safer (Files): Add tmpfile-safer.c.
9824         (Depends-on): Add binary-io.
9825
9826 2006-07-23  Eric Blake  <ebb9@byu.net>
9827
9828         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
9829
9830 2006-07-23  Eric Blake  <ebb9@byu.net>
9831
9832         * lib/tmpfile-safer.c: New file.
9833         * lib/stdio-safer.h (fopen_safer): Add prototype.
9834         * lib/stdio--.h (tmpfile): Make safer.
9835
9836 2006-07-23  Bruno Haible  <bruno@clisp.org>
9837
9838         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
9839         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
9840         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
9841         gl_linked_remove_at): Use it.
9842
9843 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9844         and Simon Josefsson <jas@extundo.com>
9845
9846         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
9847
9848         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
9849
9850 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9851
9852         * modules/close-stream: New file.
9853         * modules/closeout (Description): Make it clear that it exits
9854         with a diagnostic on error.
9855         (Depends-on): Add close-stream.  Remove fpending, stdbool.
9856         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
9857
9858 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9859
9860         * m4/close-stream.m4: New file.
9861
9862 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
9863
9864         * lib/close-stream.c, lib/close-stream.h: New files.
9865
9866 2006-07-22  Bruno Haible  <bruno@clisp.org>
9867
9868         Merge from GNU gettext 0.15.
9869
9870         2006-05-01  Bruno Haible  <bruno@clisp.org>
9871
9872                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
9873
9874         2006-07-22  Bruno Haible  <bruno@clisp.org>
9875
9876                 * modules/javaversion: New file.
9877                 * MODULES.html.sh (Java): Add javaversion.
9878
9879         2006-03-12  Bruno Haible  <bruno@clisp.org>
9880
9881                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
9882
9883         2005-12-04  Bruno Haible  <bruno@clisp.org>
9884
9885                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
9886                 (untested).
9887
9888         2006-06-21  Bruno Haible  <bruno@clisp.org>
9889
9890                 Avoid warnings from recent versions of mcs.
9891                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
9892                 -o, -L, -r any more. Use options documented since mcs-1.0
9893                 instead. Similarly for -g.
9894
9895         2005-12-04  Bruno Haible  <bruno@clisp.org>
9896
9897                 * build-aux/csharpcomp.sh.in: Suffix for resources is
9898                 .resources, not .resource.
9899
9900         2005-07-09  Bruno Haible  <bruno@clisp.org>
9901
9902                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
9903                 add a .dll suffix.
9904                 Reported by Mark Junker <mjscod@gmx.de>.
9905
9906         2006-07-22  Bruno Haible  <bruno@clisp.org>
9907
9908                 * modules/gettext: Upgrade to gettext-0.15.
9909                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
9910                 m4/visibility.m4.
9911                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
9912
9913 2006-07-22  Bruno Haible  <bruno@clisp.org>
9914
9915         Merge from GNU gettext 0.15.
9916
9917         2006-03-25  Bruno Haible  <bruno@clisp.org>
9918
9919                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
9920
9921         2006-07-21  Bruno Haible  <bruno@clisp.org>
9922
9923                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
9924                 "1.1".
9925
9926         2006-05-09  Bruno Haible  <bruno@clisp.org>
9927
9928                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
9929                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
9930                 for the conftestver execution.
9931
9932         2006-05-01  Bruno Haible  <bruno@clisp.org>
9933
9934                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
9935                 optional target-version argument. Verify that the compiler
9936                 groks source of the specified source-version, or add -source
9937                 option as necessary. Verify that the compiler produces
9938                 bytecode in the specified target-version, or add -target and
9939                 -source options as necessary. Make the result of the test
9940                 available as variable CONF_JAVAC. Also log error output in
9941                 config.log.
9942
9943         2006-03-11  Bruno Haible  <bruno@clisp.org>
9944
9945                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
9946
9947         2006-05-09  Bruno Haible  <bruno@clisp.org>
9948
9949                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
9950                 CLASSPATH_SEPARATOR to a semicolon.
9951
9952         2006-03-12  Bruno Haible  <bruno@clisp.org>
9953
9954                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
9955                 available as variable CONF_JAVA, for subsequent autoconf
9956                 tests. Also log error output in config.log.
9957
9958         2006-07-19  Bruno Haible  <bruno@clisp.org>
9959
9960                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
9961                 that getline works on glibc2 systems. Needed to avoid trouble
9962                 in relocatable.c.
9963                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
9964
9965         2005-12-04  Bruno Haible  <bruno@clisp.org>
9966
9967                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
9968                 launcher (untested).
9969
9970         2005-12-04  Bruno Haible  <bruno@clisp.org>
9971
9972                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
9973
9974         2006-07-22  Bruno Haible  <bruno@clisp.org>
9975
9976                 * gettext.m4: Update from GNU gettext-0.15.
9977                 * nls.m4: Likewise.
9978                 * po.m4: Likewise.
9979                 * inttypes-pri.m4: Likewise.
9980                 * inttypes-h.m4: Renamed from inttypes.m4.
9981                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
9982
9983 2006-07-22  Bruno Haible  <bruno@clisp.org>
9984
9985         Merge from GNU gettext 0.15.
9986
9987         2005-07-05  Bruno Haible  <bruno@clisp.org>
9988
9989                 * printf-args.c (printf_fetchargs): Work around broken
9990                 definition of wint_t on mingw.
9991
9992         2005-02-12  Bruno Haible  <bruno@clisp.org>
9993
9994                 * xallocsa.h: Add extern "C" for C++.
9995
9996         2006-05-17  Bruno Haible  <bruno@clisp.org>
9997
9998                 Cygwin portability.
9999                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
10000
10001         2006-04-30  Bruno Haible  <bruno@clisp.org>
10002
10003                 * progreloc.c: Include <mach-o/dyld.h> if available.
10004                 (find_executable): Use _NSGetExecutablePath when possible.
10005
10006         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
10007
10008                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
10009                 function.
10010
10011         2005-12-29  Bruno Haible  <bruno@clisp.org>
10012
10013                 * progreloc.c (set_program_name_and_installdir): Fix
10014                 compilation error.
10015
10016         2005-12-04  Bruno Haible  <bruno@clisp.org>
10017
10018                 Cygwin portability.
10019                 * progreloc.c: Include <windows.h> also on Cygwin.
10020                 (find_executable): Add support for Cygwin.
10021                 (set_program_name_and_installdir): Handle also platforms with
10022                 nonempty EXEEXT.
10023
10024         2006-07-11  Bruno Haible  <bruno@clisp.org>
10025
10026                 * javacomp.c: Fix a comment.
10027                 Reported by Jim Meyering.
10028
10029         2006-04-30  Bruno Haible  <bruno@clisp.org>
10030
10031                 * javacomp.h (compile_java_class): Add source_version,
10032                 target_version arguments.
10033                 * javacomp.c: Rewritten to choose only a compiler that
10034                 respects the specified source_version and target_version.
10035
10036         2006-06-27  Bruno Haible  <bruno@clisp.org>
10037
10038                 Assume correct S_ISDIR macro.
10039                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
10040
10041         2006-07-22  Bruno Haible  <bruno@clisp.org>
10042
10043                 * javaversion.h: New file, from GNU gettext.
10044                 * javaversion.c: New file, from GNU gettext.
10045                 * javaversion.java: New file, from GNU gettext.
10046                 * javaversion.class: New file, from GNU gettext.
10047
10048         2006-05-17  Bruno Haible  <bruno@clisp.org>
10049
10050                 Cygwin portability.
10051                 * javaexec.c (execute_java_class): Test for jview program
10052                 also on Cygwin.
10053
10054         2006-04-09  Bruno Haible  <bruno@clisp.org>
10055
10056                 * fatal-signal.c: Don't include string.h.
10057                 (at_fatal_signal): Use a copying loop instead of memcpy.
10058
10059         2005-12-04  Bruno Haible  <bruno@clisp.org>
10060
10061                 * csharpexec.c: Add support for 'clix' launcher (untested).
10062                 (execute_csharp_using_sscli): New function.
10063                 (execute_csharp_program): Call it.
10064
10065         2006-06-21  Bruno Haible  <bruno@clisp.org>
10066
10067                 Avoid warnings from recent versions of mcs.
10068                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
10069                 -o, -L, -r any more. Use options documented since mcs-1.0
10070                 instead. Similarly for -g.
10071
10072         2005-07-09  Bruno Haible  <bruno@clisp.org>
10073
10074                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
10075                 add a .dll suffix.
10076                 Reported by Mark Junker <mjscod@gmx.de>.
10077
10078         2006-06-17  Bruno Haible  <bruno@clisp.org>
10079
10080                 * config.charset: Update for NetBSD 3.0.
10081
10082         2006-05-17  Bruno Haible  <bruno@clisp.org>
10083
10084                 Cygwin portability.
10085                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
10086
10087         2006-05-16  Bruno Haible  <bruno@clisp.org>
10088
10089                 * localcharset.c [CYGWIN]: Include <windows.h>.
10090                 (get_charset_aliases): For Cygwin, return the same CPxxx
10091                 aliases list as under WIN32.
10092                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
10093                 the environment variables. Fall back to GetACP().
10094
10095         2006-04-05  Bruno Haible  <bruno@clisp.org>
10096
10097                 * config.charset: Update Juan Manuel Guerrero's address.
10098
10099         2005-02-12  Bruno Haible  <bruno@clisp.org>
10100
10101                 * allocsa.h: Add extern "C" for C++.
10102
10103         2005-02-10  Bruno Haible  <bruno@clisp.org>
10104
10105                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
10106                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
10107
10108         2006-07-22  Bruno Haible  <bruno@clisp.org>
10109
10110                 * gettext.h: Update to GNU gettext-0.15.
10111
10112 2006-07-22  Bruno Haible  <bruno@clisp.org>
10113
10114         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
10115         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
10116         lib-prefix.m4, longdouble.m4, ssize_t.m4.
10117
10118 2006-07-21  Eric Blake  <ebb9@byu.net>
10119
10120         * modules/stdlib-safer: New file.
10121         * MODULES.html.sh (File stream based Input/Output): Add
10122         stdlib-safer.
10123
10124 2006-07-21  Eric Blake  <ebb9@byu.net>
10125
10126         * lib/stdlib-safer.h: New file from coreutils, required by
10127         stdlib--.h.
10128
10129 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
10130
10131         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
10132
10133 2006-07-20  Bruno Haible  <bruno@clisp.org>
10134
10135         * gnulib-tool: Recognize new option --assume-autoconf.
10136         (autoconf_minversion): New variable.
10137         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
10138
10139 2006-07-20  Bruno Haible  <bruno@clisp.org>
10140
10141         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
10142
10143 2006-07-19  Derek R. Price  <derek@ximbiot.com>
10144
10145         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
10146         Reindent and repaginate.
10147
10148 2006-07-19  Derek Price  <derek@ximbiot.com>
10149
10150         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
10151         Correct grammar.
10152
10153 2006-07-17  Bruno Haible  <bruno@clisp.org>
10154
10155         * modules/list: New file.
10156         * modules/array-list: New file.
10157         * modules/carray-list, modules/carray-list-tests: New files.
10158         * modules/linked-list, modules/linked-list-tests: New files.
10159         * modules/avltree-list, modules/avltree-list-tests: New files.
10160         * modules/rbtree-list, modules/rbtree-list-tests: New files.
10161         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
10162         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
10163         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
10164         * modules/oset: New file.
10165         * modules/array-oset: New file.
10166         * modules/avltree-oset, modules/avltree-oset-tests: New files.
10167         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
10168         * tests/test-carray_list.c: New file.
10169         * tests/test-linked_list.c: New file.
10170         * tests/test-avltree_list.c: New file.
10171         * tests/test-rbtree_list.c: New file.
10172         * tests/test-linkedhash_list.c: New file.
10173         * tests/test-avltreehash_list.c: New file.
10174         * tests/test-rbtreehash_list.c: New file.
10175         * tests/test-avltree_oset.c: New file.
10176         * tests/test-rbtree_oset.c: New file.
10177         * MODULES.html.sh (Container data structures): New section.
10178
10179 2006-07-17  Bruno Haible  <bruno@clisp.org>
10180
10181         * m4/gl_list.m4: New file.
10182
10183 2006-07-17  Bruno Haible  <bruno@clisp.org>
10184
10185         * lib/gl_list.h: New file.
10186         * lib/gl_list.c: New file.
10187         * lib/gl_array_list.h: New file.
10188         * lib/gl_array_list.c: New file.
10189         * lib/gl_carray_list.h: New file.
10190         * lib/gl_carray_list.c: New file.
10191         * lib/gl_linked_list.h: New file.
10192         * lib/gl_linked_list.c: New file.
10193         * lib/gl_anylinked_list1.h: New file.
10194         * lib/gl_anylinked_list2.h: New file.
10195         * lib/gl_avltree_list.h: New file.
10196         * lib/gl_avltree_list.c: New file.
10197         * lib/gl_anyavltree_list1.h: New file.
10198         * lib/gl_anyavltree_list2.h: New file.
10199         * lib/gl_rbtree_list.h: New file.
10200         * lib/gl_rbtree_list.c: New file.
10201         * lib/gl_anyrbtree_list1.h: New file.
10202         * lib/gl_anyrbtree_list2.h: New file.
10203         * lib/gl_anytree_list1.h: New file.
10204         * lib/gl_anytree_list2.h: New file.
10205         * lib/gl_linkedhash_list.h: New file.
10206         * lib/gl_linkedhash_list.c: New file.
10207         * lib/gl_anyhash_list1.h: New file.
10208         * lib/gl_anyhash_list2.h: New file.
10209         * lib/gl_avltreehash_list.h: New file.
10210         * lib/gl_avltreehash_list.c: New file.
10211         * lib/gl_rbtreehash_list.h: New file.
10212         * lib/gl_rbtreehash_list.c: New file.
10213         * lib/gl_anytreehash_list1.h: New file.
10214         * lib/gl_anytreehash_list2.h: New file.
10215
10216         * lib/gl_oset.h: New file.
10217         * lib/gl_oset.c: New file.
10218         * lib/gl_array_oset.h: New file.
10219         * lib/gl_array_oset.c: New file.
10220         * lib/gl_avltree_oset.h: New file.
10221         * lib/gl_avltree_oset.c: New file.
10222         * lib/gl_rbtree_oset.h: New file.
10223         * lib/gl_rbtree_oset.c: New file.
10224         * lib/gl_anytree_oset.h: New file.
10225
10226 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
10227
10228         * m4/mkancesdirs.m4: New file.
10229         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
10230         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
10231         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
10232         it.
10233
10234 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
10235
10236         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
10237         * lib/mkancesdirs.h: New files.
10238         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
10239         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
10240         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
10241         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
10242         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
10243         callers changed.  Revamp internals significantly, by not
10244         attempting to create directories that are temporarily more
10245         permissive than the final results.  Do not attempt to use
10246         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
10247         This removes some race conditions, fixes some bugs, and simplifies
10248         things.  Use new dirchownmod function to do owner and mode changes.
10249         * lib/mkdir-p.h: Likewise.
10250         * lib/modechange.c (octal_to_mode): New function.
10251         (struct mode_change): New member mentioned.
10252         (make_node_op_equals): New arg mentioned.  All callers changed.
10253         (mode_compile): Keep track of which mode bits the user has explicitly
10254         mentioned.
10255         (mode_adjust): New arg DIR, so that we implement the X op correctly.
10256         New arg PMODE_BITS, to keep track of which mode bits the user
10257         mentioned; it treats S_ISUID and S_ISGID speciall.
10258         All callers changed.
10259         * lib/modechange.h: Likewise.
10260
10261 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
10262
10263         * MODULES.html.sh: Add mkancestors.
10264         * modules/mkancesdirs: New module.
10265         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
10266         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
10267         The chdir-safer and afs files are now orphans; I'll remove them
10268         unless someone speaks up.
10269         Add lib/dirchownmod.c, lib/dirchownmod.h.
10270         (Depends-on): Remove alloca, chown, save-cwd, dirname.
10271         Add lchown, mkancesdirs.
10272         (Maintainer): Add self.
10273
10274 2006-07-15  Karl Berry  <karl@gnu.org>
10275
10276         * gnulib-tool: help message wording/arrangement.
10277
10278 2006-07-14  Simon Josefsson  <jas@extundo.com>
10279
10280         * doc/gnulib.texi (Libtool and Windows): New section.
10281
10282 2006-07-12  Simon Josefsson  <jas@extundo.com>
10283
10284         * modules/gendocs (License): Fix license, approved by Karl.
10285
10286 2006-07-12  Eric Blake  <ebb9@byu.net>
10287
10288         * MODULES.html.sh: Add gendocs.
10289
10290 2006-07-11  Eric Blake  <ebb9@byu.net>
10291
10292         * modules/fdl: New module, to install doc/fdl.texi.
10293         * MODULES.html.sh: Add new section for documentation modules.
10294         * gnulib-tool: Avoid space-tab.
10295         (--doc-base): New option, to manage files from doc.
10296
10297 2006-07-11  Eric Blake  <ebb9@byu.net>
10298
10299         * m4/absolute-header.m4: Fix comments to match recent change.
10300
10301 2006-07-11  Eric Blake  <ebb9@byu.net>
10302
10303         * gnulib-tool: List --doc-base before --tests-base.
10304
10305 2006-07-11  Derek R. Price  <derek@ximbiot.com>
10306
10307         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
10308
10309 2006-07-11  Bruno Haible  <bruno@clisp.org>
10310
10311         * README: Mention where to put documentation.
10312
10313 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10314
10315         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
10316
10317 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
10318
10319         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
10320         to stdint.m4.
10321
10322 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
10323
10324         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
10325         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
10326         "no/such/file/stdint.h" when there is no such file, so that
10327         the resulting C code can be parsed by dodgy compilers.
10328         Problems reported by Bob Proulx.
10329
10330 2006-07-10  Derek R. Price  <derek@ximbiot.com>
10331
10332         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
10333         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
10334         macros into the GNU _D_EXACT_NAMLEN.
10335         * lib/savedir.c:  Likewise.
10336         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
10337
10338 2006-07-10  Derek R. Price  <derek@ximbiot.com>
10339         and Paul Eggert  <eggert@cs.ucla.edu>
10340
10341         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
10342         * m4/savedir.m4:
10343         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
10344         macros into the GNU _D_EXACT_NAMLEN.
10345
10346 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
10347
10348         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
10349         around the absolute name, to work around a problem with the HP-UX
10350         11.23 native C compiler, reported by Bob Proulx.
10351
10352 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
10353
10354         * doc/maintain.texi, make-stds.texi: Sync from
10355         <http://savannah.gnu.org/projects/gnustandards>.
10356
10357 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
10358
10359         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
10360
10361 2006-07-09  Jim Meyering  <jim@meyering.net>
10362
10363         * m4/glob.m4: Remove a doubled word in a comment.
10364
10365 2006-07-09  Jim Meyering  <jim@meyering.net>
10366
10367         * lib/argp-pv.c: Remove a doubled word in a comment.
10368         * lib/check-version.c (check_version): Likewise.
10369         * lib/javacomp.c (compile_java_class): Likewise.
10370
10371 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
10372
10373         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
10374         for the benefit of people using Autoconf 2.60.  If you want to
10375         support older Autoconf versions you can copy m4/onceonly_2_57.m4
10376         (or m4/onceonly.m4, if pre-2.57) manually.
10377
10378 2006-07-08  Jim Meyering  <jim@meyering.net>
10379
10380         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
10381         comment.
10382         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
10383         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
10384         comment.
10385
10386 2006-07-08  Jim Meyering  <jim@meyering.net>
10387
10388         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
10389
10390 2006-07-07  Simon Josefsson  <jas@extundo.com>
10391
10392         * tests/test-crc.c: Change expected crc value, the test vector
10393         were probably computed using the old broken crc.c?
10394
10395 2006-07-06  Simon Josefsson  <jas@extundo.com>
10396
10397         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
10398         now the canonical place for the M4 file).
10399
10400         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
10401         from the sys_socket dependency now.
10402
10403         * modules/inet_pton (Files): Ditto.
10404
10405         * modules/inet_ntop (Files): Ditto.
10406
10407 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10408
10409         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
10410         not gl_PREREQ_GETUSERSHELL.
10411
10412 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10413
10414         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
10415         with only one argument, for Autoconf 2.60.
10416         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
10417         expand to nothing, so add a shell command to avoid syntax error.
10418         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
10419
10420 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10421
10422         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
10423
10424 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
10425
10426         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
10427         no longer needed.  Check for isblank decl.
10428         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
10429         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
10430         of existence.
10431
10432 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
10433
10434         * lib/getloadavg.c: Use __VMS, not VMS.
10435         * lib/getopt.c: Likewise.
10436         * lib/getpagesize.h: Likewise.
10437         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
10438         and probably does not work.
10439
10440 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
10441
10442         * lib/.cppi-disable: Add wcwidth.
10443         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
10444         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
10445         (ISGRAPH): Remove.  All uses changed to isgraph.
10446         (FOLD) [!defined _LIBC]: Remove special case.
10447         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
10448         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
10449         HAVE_ISBLANK.
10450         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
10451         case.
10452
10453 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
10454
10455         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
10456         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
10457         brackets.  Other minor changes to suppress some compiler
10458         warnings.
10459
10460 2006-07-06  Derek R. Price  <derek@ximbiot.com>
10461         and Paul Eggert  <eggert@cs.ucla.edu>
10462
10463         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
10464         of invoking obsolescent AC_HEADER_DIRENT macro.
10465         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
10466         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
10467         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
10468         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
10469         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
10470         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
10471         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
10472         * m4/readdir.m4: Remove; no longer needed.
10473
10474 2006-07-06  Derek R. Price  <derek@ximbiot.com>
10475         and Paul Eggert  <eggert@cs.ucla.edu>
10476
10477         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
10478         Don't worry about this obsolete case any more.
10479         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
10480         directories.
10481         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
10482         worry about this obsolete case any more.
10483         * lib/fts.c: Likewise.
10484         * lib/getcwd.c: Likewise.
10485         * lib/glob.h: Likewise.
10486         * lib/savedir.c: Likewise.
10487
10488 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
10489
10490         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
10491         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
10492         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
10493         needed.
10494         All uses removed.
10495         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
10496         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
10497         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
10498         needed.
10499         * m4/getdate.m4 (gl_GETDATE): Likewise.
10500         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
10501         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
10502         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
10503         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
10504         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
10505         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
10506         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
10507         needed.
10508
10509 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
10510
10511         * lib/memcasecmp.c: Include <limits.h>.
10512         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
10513         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
10514         Don't assume isdigit succeeds only on '0' through '9'.
10515
10516 2006-07-05  Eric Blake  <ebb9@byu.net>
10517
10518         * modules/getaddrinfo (Depends-on): Add snprintf.
10519
10520 2006-07-05  Eric Blake  <ebb9@byu.net>
10521
10522         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
10523         to avoid 'header present but could not be compiled' on cygwin.
10524
10525 2006-07-05  Eric Blake  <ebb9@byu.net>
10526
10527         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
10528         missing from netdb.h.
10529         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
10530
10531 2006-07-05  Derek R. Price  <derek@ximbiot.com>
10532
10533         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
10534         no longer needed.
10535         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
10536         * m4/getdate.m4 (gl_GETDATE): Likewise.
10537         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
10538         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
10539         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
10540         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
10541         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
10542
10543 2006-07-05  Derek R. Price  <derek@ximbiot.com>
10544
10545         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
10546         All uses of is_space replaced by isspace.
10547         * lib/exit.h: Don't talk about STDC_HEADERS.
10548         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
10549         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
10550         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
10551         replaced by isprint etc.
10552         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
10553         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
10554         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
10555         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
10556         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
10557         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
10558
10559 2006-07-05  Bruno Haible  <bruno@clisp.org>
10560
10561         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
10562         the function exists, before testing against AIX.
10563         Reported by Martin Lambers <marlam@marlam.de>.
10564
10565 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
10566
10567         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
10568         From Mark D. Baushke.
10569
10570 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
10571
10572         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
10573         to the absolute name, not just one, to bypass Sun C 5.8's
10574         "warning: #include of /usr/include/... may be non-portable".
10575
10576 2006-07-04  Eric Blake  <ebb9@byu.net>
10577
10578         * modules/dirname-tests: New test module.
10579         * tests/test-dirname.c: New file, replacing dirname.c
10580         TEST_DIRNAME section that was recently deleted.
10581
10582 2006-07-04  Bruno Haible  <bruno@clisp.org>
10583
10584         Assume ANSI C header files and <ctype.h> functions.
10585         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
10586         (mbsnwidth): Use isprint, iscntrl instead.
10587
10588 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10589
10590         Merge from coreutils.
10591         * MODULES.html.sh: Add xstrtold.
10592         * modules/xstrtold: New file.
10593         * modules/cycle-check (Files): Add lib/same-inode.h.
10594         * modules/dirname (Files): Add m4/double-slash-root.m4.
10595         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
10596         * modules/mkdir-p (Files): Add lib/same-inode.h.
10597         * modules/same (Files): Add lib/same-inode.h.
10598
10599 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10600
10601         * m4/absolute-header.m4: Renamed from full-header-path.m4.
10602         This is to keep the terminology clean; POSIX talks about
10603         "absolute pathnames", not "full pathnames", but the GNU
10604         Coding Standards say to use "path" for something else;
10605         so use "absolute" to keep both sides happy.
10606         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
10607         Set gl_absolute_header, not gl_full_header_path.
10608         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
10609         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
10610         All uses changed.
10611
10612         Merge from coreutils.
10613
10614         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
10615
10616         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
10617         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
10618         want to require the building of c-strtod.o.
10619         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
10620         needs -lm directly.
10621         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
10622
10623         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
10624
10625         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
10626         --as-needed option if available.  Problem reported by Albert Chin in
10627         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
10628         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
10629         cc merely issues a bunch of annoying warnings for --as-needed
10630         (this problem was reported by Bob Proulx).  Also, try linking with
10631         -lm to detect a bug in binutils 2.16 (this problem was reported
10632         by Ralf Wildenhues).
10633
10634         2006-06-18  Jim Meyering  <jim@meyering.net>
10635
10636         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
10637         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
10638         macro.
10639         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
10640         also check for glibc-2.4's abort-inducing bug.
10641
10642         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
10643         Low-probability clean-up should be to use rmdir to get rid of
10644         the just-created directory, not unlink.
10645
10646         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
10647         configure fail, and request a bug report to inform us about it.
10648         Add a comment that, barring reports to the contrary, in 2007 we'll
10649         assume ftruncate is universally available.
10650
10651         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10652
10653         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
10654
10655         2006-03-12  Jim Meyering  <jim@meyering.net>
10656
10657         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
10658         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
10659         * m4/same.m4 (gl_SAME): Likewise.
10660         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
10661
10662         2006-03-11  Eric Blake  <ebb9@byu.net>
10663
10664         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
10665         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
10666         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
10667         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
10668
10669 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10670
10671         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
10672         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
10673         reported by Mark D. Baushke, one in
10674         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
10675
10676         Merge from coreutils.
10677
10678         * lib/.cppi-disable: Add stdint_.h.
10679         * lib/.cvsignore: Add stdint.h.
10680
10681         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
10682
10683         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
10684         both double and long double versions.
10685         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
10686         * lib/xstrtold.c: New file.
10687         * lib/xstrtod.h (xstrtold): New decl.
10688
10689         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
10690
10691         * lib/filemode.c (setst): Remove.
10692         (strmode): Rewrite to avoid setst.  This makes the code shorter,
10693         (arguably) clearer, and the generated code is a bit smaller on my
10694         Debian GNU/Linux stable x86 host.
10695
10696         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10697
10698         * lib/filemode.c: Include "filemode.h" first, to test the interface.
10699         Assume that filemode.h includes sys/types.h and sys/stat.h.
10700         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
10701         (ftypelet): Reorder to put common cases first, for efficiency.
10702         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
10703         to do 'M'.
10704         (strmode): Renamed from mode_string, and now stores 12 bytes instead
10705         of 10, for compatibility with FreeBSD.  All callers changed.
10706         (filemodestring): Now stores 12 bytes instead of 10, and sets file
10707         types that can't be deduced solely from st_mode.  First arg is now a
10708         const pointer.
10709         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
10710         (strmode): Renamed from mode_string.
10711         (filemodestring): New decl.
10712         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
10713         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
10714         needed.
10715         (S_ISPORT, S_ISWHT): New macros, if not already defined.
10716
10717         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
10718
10719         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
10720         fsusage.h now does that.  Include fsusage.h first, to test interface.
10721         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
10722         at most one method (the old code could have generated decls that
10723         didn't conform to C89, not that this was ever exercised).
10724         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
10725
10726         2006-03-19  Jim Meyering  <jim@meyering.net>
10727
10728         Work even in a chroot where d_ino values for entries in "/"
10729         don't match the stat.st_ino values for the same names.
10730         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
10731         number, iterate through all entries again, using lstat instead.
10732         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
10733         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
10734
10735         * lib/getcwd.c (__getcwd): Clarify a comment.
10736         Use memcpy in place of a call to strcpy.
10737
10738         2006-03-12  Jim Meyering  <jim@meyering.net>
10739
10740         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
10741         matches that of the current directory (which we're about to chdir ".."
10742         out of), then save the dev-ino of the parent, instead.
10743
10744         * lib/same-inode.h (SAME_INODE): New file/macro.
10745         * lib/chdir-safer.c (SAME_INODE): Remove definition.
10746         Include "same-inode.h", instead.
10747         * lib/same.c: Likewise.
10748         * lib/cycle-check.h: Include "same-inode.h".
10749         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
10750         * lib/cycle-check.c (SAME_INODE): Remove definition.
10751         * lib/root-dev-ino.h: Include "same-inode.h".
10752
10753         2006-03-11  Eric Blake  <ebb9@byu.net>
10754
10755         * lib/same.c (same_name): s/base_name/last_component/
10756         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
10757         * lib/filenamecat.c (file_name_concat): Likewise.
10758
10759         2006-03-11  Eric Blake  <ebb9@byu.net>,
10760                     Paul Eggert  <eggert@cs.ucla.edu>
10761
10762         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
10763         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
10764         drive prefix.
10765         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
10766         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
10767         (last_component): New method.
10768         * lib/dirname.c (dir_len): Determine when drive letters need a
10769         subsequent slash.  Preserve // when it is special.
10770         (dir_name): Don't append dot when drive letter is absolute.
10771         [TEST_DIRNAME]: Move into a full-blown gnulib test.
10772         * lib/basename.c (base_name): New semantics - malloc the result.
10773         Preserve // when it is special.  Preserve relative files that look
10774         like drive letters.
10775         (base_len): Preserve // when it is special.
10776         (last_component): New method, similar to old base_name semantics.
10777         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
10778         base_name.  Strip redundant slashes from ///.
10779
10780 2006-07-03  Jim Meyering  <jim@meyering.net>
10781
10782         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
10783         macro is used before the first cycle_check call.
10784
10785 2006-07-03  Eric Blake  <ebb9@byu.net>
10786
10787         * modules/dirname (Depends-on): Add xstrndup.
10788
10789 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10790
10791         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
10792         test cases, so that config.log is a bit easier to follow.
10793
10794 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10795
10796         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
10797         both are 64 bits, since this seems to be the tradition, and this
10798         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
10799         we ever run into a host that prefers long long to long in this
10800         case, we'll need another configure-time test.  Problem reported by
10801         Jim Meyering.
10802
10803 2006-07-02  Eric Blake  <ebb9@byu.net>
10804
10805         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
10806
10807 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10808
10809         * modules/inttypes (Depends-on): No longer depends on stdint.
10810         * modules/stdint (Description): Say more about assumptions.
10811         Say that the fast types might differ.  Say macros are used.
10812         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
10813         (Makefile.am): Revise list of substituted symbols to match
10814         new stdint.m4.
10815         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
10816         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
10817         * tests/test-stdint.c (verify_same_types)
10818         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
10819         the code conforms to C99/C89.
10820         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
10821         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
10822
10823 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10824
10825         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
10826         but fix a bug, by requiring at least 64 bits.
10827         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
10828         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
10829         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
10830         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
10831
10832         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
10833         changes.  Make 2.59 a prerequisite.  Check and substitute for
10834         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
10835         inttypes.h.  Do not use special include files; just use the
10836         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
10837         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
10838         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
10839         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
10840         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
10841         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
10842         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
10843         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
10844         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
10845         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
10846         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
10847         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
10848         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
10849         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
10850         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
10851         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
10852         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
10853         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
10854         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
10855         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
10856         WINT_MAX.  Check for C99 conformance more strictly, by detecting
10857         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
10858         not check for things that C99 does not require, e.g., int8_t.  If
10859         a test isn't needed unless <stdint.h> isn't working, and is
10860         unlikely to be needed for any other reason, then don't do it
10861         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
10862         size_t, since we assume C89 freestanding at least.  Do not check
10863         for sig_atomic_t, wchar_t, or wint_t, since the code now does
10864         the right thing even if the types are not defined.  Instead use:
10865         (gl_STDINT_TYPE_PROPERTIES): New macro.
10866         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
10867         testing whether <sys/types.h> clashes, as Autoconf does this for
10868         us now.  All uses removed.
10869         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
10870         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
10871         (gl_CHECK_TYPE_SAME):
10872         Remove; no longer needed.
10873         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
10874         exists, since we'll return 0 anyway in that case.
10875         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
10876
10877 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10878
10879         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
10880         possible collision with system files.
10881         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
10882         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
10883         WCHAR_MIN and WCHAR_MAX in this case.
10884         (<stddef.h>): Do not include; no longer needed.
10885         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
10886         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
10887         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
10888         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
10889         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
10890         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
10891         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
10892         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
10893         !defined(__c99))]: Include in this case too, since it's harmless
10894         now.
10895         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
10896         dangerous to do so.
10897         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
10898         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
10899         (_STDINT_MIN, _STDINT_MAX): New macros.
10900         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
10901         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
10902         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
10903         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
10904         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
10905         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
10906         macros, not typedefs; this simplifies things quite a bit.
10907         Use long int for all types narrower than int64_t.
10908         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
10909         Define in terms of long long int or int64_t or long int,
10910         not int64_t or int32_t.  This saves some compile-time testing.
10911         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
10912         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
10913         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
10914         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
10915         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
10916         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
10917         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
10918         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
10919         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
10920         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
10921         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
10922         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
10923         undef any previous version and define our own version, for
10924         simplicity and consistency with the new macros for types.
10925         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
10926         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
10927         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
10928         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
10929         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
10930         @WINT_T_SUFFIX@ to keep things simple here.
10931         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
10932         Simplify by assuming typical 8/16/32/64 host, since we're
10933         already doing that elsewhere anyway.
10934         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
10935         and assume long long int is 64 bits if available.  This
10936         speeds up 'configure'.
10937
10938 2006-07-01  Eric Blake  <ebb9@byu.net>
10939
10940         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
10941         Reported by Andreas Buening.
10942
10943 2006-07-01  Eric Blake  <ebb9@byu.net>
10944
10945         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
10946
10947 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
10948
10949         * lib/getaddrinfo.c: fixed typo
10950
10951 2006-06-29  Jim Meyering  <jim@meyering.net>
10952
10953         * modules/strftime (Maintainer): Add my name, since with the
10954         FPRINTFTIME changes strftime.c has forked from glibc.
10955
10956 2006-06-29  Eric Blake  <ebb9@byu.net>
10957
10958         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
10959
10960 2006-06-29  Eric Blake  <ebb9@byu.net>
10961
10962         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
10963
10964 2006-06-29  Eric Blake  <ebb9@byu.net>
10965
10966         * lib/stat_.h: New file.
10967
10968 2006-06-29  Eric Blake  <ebb9@byu.net>
10969
10970         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
10971         unused static function.
10972
10973 2006-06-29  Eric Blake  <ebb9@byu.net>
10974
10975         * doc/functions.texi (Function Portability): Document missing lstat
10976         on mingw.
10977
10978 2006-06-29  Eric Blake  <ebb9@byu.net>
10979
10980         * MODULES.html.sh: Add sys_stat.
10981         * modules/sys_stat: New module.
10982         * modules/mkstemp (Depends-on): Add sys_stat.
10983
10984 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10985
10986         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
10987
10988 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10989
10990         * m4/c-bs-a.m4: Removed.
10991
10992 2006-06-29  Derek R. Price  <derek@ximbiot.com>
10993
10994         * lib/strftime.c: Assume strftime() exists.
10995
10996 2006-06-29  Derek Price  <derek@ximbiot.com>
10997
10998         * modules/c-bs-a: Removed - \a is C89.
10999         * MODULES.html.sh: Remove c-bs-a.
11000
11001 2006-06-29  Bruno Haible  <bruno@clisp.org>
11002
11003         * modules/wcwidth (License): Change to LGPL.
11004
11005 2006-06-28  Simon Josefsson  <jas@extundo.com>
11006
11007         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
11008         on _WIN32.
11009
11010         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
11011         getnameinfo.
11012
11013 2006-06-28  Simon Josefsson  <jas@extundo.com>
11014
11015         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
11016
11017 2006-06-28  Simon Josefsson  <jas@extundo.com>
11018
11019         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
11020         functions there.  It will succeed on Windows XP, but on Windows
11021         2000 and (presumably) earlier, it will fail, and use the internal
11022         re-implementation.
11023         (use_win32_p): New function.
11024         (getaddrinfo): Use strtoul on servname, to support numeric ports.
11025         Support AI_NUMERICSERV to disable getservbyname.
11026         (getnameinfo): New function, only supports
11027         NI_NUMERICHOST|NI_NUMERICSERV for now.
11028
11029         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
11030         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
11031         getnameinfo.
11032
11033 2006-06-28  Eric Blake  <ebb9@byu.net>
11034
11035         * modules/wcwidth: New file.
11036         * modules/mbchar (Depends-on): Add wcwidth.
11037         * modules/mbswidth (Depends-on): Add wcwidth.
11038         * MODULES.html.sh: Add wcwidth.
11039
11040 2006-06-28  Eric Blake  <ebb9@byu.net>
11041
11042         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
11043         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
11044
11045 2006-06-28  Eric Blake  <ebb9@byu.net>
11046
11047         * lib/xvasprintf.h: Fix comments.
11048
11049 2006-06-28  Eric Blake  <ebb9@byu.net>
11050
11051         * lib/mbchar.h (wcwidth): Include wcwidth.h.
11052         * lib/mbswidth.c (wcwidth): Move from here...
11053         * lib/wcwidth.h: ...to this new file.
11054
11055 2006-06-28  Derek R. Price  <derek@ximbiot.com>
11056
11057         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
11058
11059         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
11060         it's obsolete.
11061         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
11062
11063 2006-06-28  Derek R. Price  <derek@ximbiot.com>
11064
11065         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
11066         Autoconf 2.60 says this stuff was obsolete.
11067
11068 2006-06-28  Bruno Haible  <bruno@clisp.org>
11069
11070         * modules/wcwidth (Files): Add m4/wchar_t.m4.
11071
11072 2006-06-28  Bruno Haible  <bruno@clisp.org>
11073
11074         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
11075         gt_TYPE_WCHAR_T.
11076
11077 2006-06-28  Bruno Haible  <bruno@clisp.org>
11078
11079         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
11080         declaration for wcwidth.
11081         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
11082
11083 2006-06-28  Bruno Haible  <bruno@clisp.org>
11084
11085         * lib/mkdtemp.c [MINGW]: Include <io.h>.
11086         (mkdir): Define using _mkdir.
11087
11088 2006-06-28  Bruno Haible  <bruno@clisp.org>
11089
11090         * lib/getaddrinfo.h: Fix POSIX URL.
11091         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
11092         _WIN32.
11093         (use_win32_p): Make static.
11094         (getaddrinfo): Reject service name if it is empty or does not consist
11095         solely of decimal digits, or if its value is > 65535.
11096         (getnameinfo): Remove useless casts.
11097
11098 2006-06-27  Simon Josefsson  <jas@extundo.com>
11099
11100         * modules/sys_select: New file, suggested by Bruno Haible, Paul
11101         Eggert and Martin Lambers.
11102
11103 2006-06-27  Simon Josefsson  <jas@extundo.com>
11104
11105         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
11106         Eggert and Martin Lambers.
11107
11108 2006-06-27  Bruno Haible  <bruno@clisp.org>
11109
11110         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
11111         result to 0, not to empty.
11112         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
11113
11114 2006-06-27  Bruno Haible  <bruno@clisp.org>
11115
11116         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
11117
11118 2006-06-26  Simon Josefsson  <jas@extundo.com>
11119
11120         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
11121         present.
11122
11123 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
11124
11125         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
11126         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
11127         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
11128
11129 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
11130
11131         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
11132
11133 2006-06-26  Bruno Haible  <bruno@clisp.org>
11134
11135         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
11136
11137 2006-06-26  Bruno Haible  <bruno@clisp.org>
11138
11139         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
11140
11141 2006-06-26  Bruno Haible  <bruno@clisp.org>
11142
11143         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
11144         SGI C compiler in pre-C99 mode.
11145         Suggested by Mark D. Baushke and Larry Jones.
11146
11147 2006-06-26  Bruno Haible  <bruno@clisp.org>
11148
11149         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
11150         WCHAR_MAX.
11151         Reported by Mark D. Baushke and Larry Jones.
11152
11153 2006-06-26  Bruno Haible  <bruno@clisp.org>
11154
11155         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
11156         in pre-C99 mode.
11157         Suggested by Mark D. Baushke and Larry Jones.
11158
11159 2006-06-23  Simon Josefsson  <jas@extundo.com>
11160             Bruno Haible  <bruno@clisp.org>
11161
11162         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
11163         Emit mostlyclean-local rule.
11164         (func_emit_tests_Makefile_am): Likewise.
11165         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
11166
11167 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
11168
11169         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
11170
11171 2006-06-23  Bruno Haible  <bruno@clisp.org>
11172
11173         * tests/test-stdint.c: Update to match ISO C 99 Technical
11174         Corrigendum 1.
11175
11176 2006-06-23  Bruno Haible  <bruno@clisp.org>
11177
11178         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
11179
11180 2006-06-23  Bruno Haible  <bruno@clisp.org>
11181
11182         * lib/stdint_.h: Treat IRIX like OpenBSD.
11183
11184 2006-06-23  Bruno Haible  <bruno@clisp.org>
11185
11186         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
11187         ISO C 99 Technical Corrigendum 1.
11188
11189 2006-06-22  Simon Josefsson  <jas@extundo.com>
11190
11191         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
11192         MinGW.
11193
11194 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
11195
11196         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
11197         needed.  Some compiler complained about some of them.  Problem reported
11198         by Larry Jones in
11199         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
11200
11201 2006-06-21  Simon Josefsson  <jas@extundo.com>
11202
11203         * tests/test-getaddrinfo.c: New file.
11204
11205         * modules/getaddrinfo-tests: New file.
11206
11207         * MODULES.html.sh: Add inet_pton.
11208
11209         * modules/inet_pton: New file.
11210
11211 2006-06-21  Simon Josefsson  <jas@extundo.com>
11212
11213         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
11214         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
11215         of using the (limited) gnulib implementation on Windows XP.
11216
11217         * m4/inet_pton.m4: New file.
11218
11219 2006-06-21  Simon Josefsson  <jas@extundo.com>
11220
11221         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
11222         variable.
11223
11224         * lib/socket_.h: Don't define WINVER.
11225
11226         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
11227         slightly modified to work in gnulib.
11228
11229 2006-06-21  Simon Josefsson  <jas@extundo.com>
11230
11231         * doc/gnulib.texi (Windows sockets): Add.
11232
11233 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
11234
11235         * lib/read-file.c (fread_file): Start with buffer allocation of
11236         0 bytes rather than 1 byte; this simplifies the code.
11237         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
11238         code to free buffer and save/restore errno.
11239         (internal_read_file): Remove unused local.
11240
11241 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
11242
11243         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
11244         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
11245         Problem reported by Denis Excoffier in
11246         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
11247
11248 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
11249
11250         * modules/sys_socket, modules/socklen: Include sys/types since
11251         FreeBSD 4.x's sys/socket.h needs it.
11252
11253 2006-06-19  Simon Josefsson  <jas@extundo.com>
11254
11255         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
11256
11257 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
11258
11259         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
11260
11261 2006-06-19  Bruno Haible  <bruno@clisp.org>
11262
11263         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
11264         and FULL_PATH_INTTYPES_H in angle brackets.
11265         Reported by Mark D. Baushke <mdb@gnu.org>.
11266
11267 2006-06-17  Eric Blake  <ebb9@byu.net>
11268
11269         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
11270         errno.
11271
11272 2006-06-17  Bruno Haible  <bruno@clisp.org>
11273
11274         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
11275         <sys/inttypes.h>.
11276
11277 2006-06-17  Bruno Haible  <bruno@clisp.org>
11278
11279         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
11280         whether errno is declared. Assume <errno.h> declares errno.
11281
11282 2006-06-17  Bruno Haible  <bruno@clisp.org>
11283
11284         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
11285
11286 2006-06-17  Bruno Haible  <bruno@clisp.org>
11287
11288         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
11289         problem on Solaris 2.5.1.
11290
11291 2006-06-16  Eric Blake  <ebb9@byu.net>
11292
11293         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
11294         * lib/unicodeio.c [!defined errno]: Likewise.
11295         * lib/strtol.c [!defined errno]: Likewise.
11296         * lib/strtod.c [!defined errno]: Likewise.
11297
11298 2006-06-15  Eric Blake  <ebb9@byu.net>
11299
11300         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
11301
11302 2006-06-15  Eric Blake  <ebb9@byu.net>
11303
11304         * config/srclist.txt (ssize_t.m4): Lose sync.
11305
11306 2006-06-15  Bruno Haible  <bruno@clisp.org>
11307
11308         * modules/stdint (Files): Include m4/full-header-path.m4,
11309         m4/size_max.m4, m4/wchar_t.m4.
11310         (Makefile.am): Many more substitutions.
11311         * modules/stdint-tests: New file.
11312         * tests/test-stdint.c: New file.
11313
11314 2006-06-15  Bruno Haible  <bruno@clisp.org>
11315
11316         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
11317         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
11318         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
11319         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
11320         gl_CHECK_TYPE_SAME): New macros.
11321
11322 2006-06-15  Bruno Haible  <bruno@clisp.org>
11323
11324         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
11325
11326 2006-06-15  Bruno Haible  <bruno@clisp.org>
11327
11328         * lib/stdint_.h: Rewritten to be fully auto-configured.
11329         Fixes bug on HP-UX/IA64.
11330
11331 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
11332
11333         * lib/getdate.y (__attribute__): Don't define if already defined.
11334         Problem reported by Larry Jones.
11335         * lib/utimens.c (__attribute__): Likewise.
11336
11337 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
11338
11339         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
11340         reported by Andreas Schwab.
11341
11342 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11343             Bruno Haible  <bruno@clisp.org>
11344
11345         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
11346         check for the declaration of strnlen and a run test that exposes the
11347         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
11348         rpl_strndup.
11349
11350 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11351             Bruno Haible  <bruno@clisp.org>
11352
11353         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
11354
11355 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11356
11357         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
11358         compile test, for Tru64 4.0D.
11359
11360 2006-05-28  Karl Berry  <karl@gnu.org>
11361
11362         * config/srclist.txt (printf-args.c): lose sync.
11363
11364 2006-05-26  Martin Lambers  <marlam@marlam.de>
11365
11366         * lib/getpass.c: Updates the test for the native W32 API, and adds
11367         missing includes, thus fixing compilation warnings.
11368
11369 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
11370
11371         * lib/exclude.c (exclude_fnmatch): New function.
11372         (excluded_file_name): Call exclude_fnmatch.
11373         * lib/exclude.h (excluded_file_name): New prototype
11374
11375 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
11376
11377         * lib/tempname.c (small_open, large_open): New macros.
11378         (__open, __open64) [!_LIBC]: Remove.
11379         (__gen_tempname): Use small_open and large_open instead of __open
11380         and __open64.  This fixes a portability bug on HP-UX 11.11i
11381         reported by Simon Wing-Tang in
11382         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
11383
11384 2006-05-24  Bruno Haible  <bruno@clisp.org>
11385
11386         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
11387         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
11388         Reported by Thorsten Maerz <torte@netztorte.de> via
11389         Aaron Stone <aaron@serendipity.cx>.
11390
11391 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
11392
11393         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
11394         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
11395         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
11396         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
11397         not really conditional on the cache.
11398         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
11399
11400 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
11401
11402         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
11403         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
11404         (my_usleep): Don't mishandle maximum value.
11405
11406 2006-05-19  Jim Meyering  <jim@meyering.net>
11407
11408         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
11409
11410 2006-05-17  Bruno Haible  <bruno@clisp.org>
11411
11412         Cygwin portability.
11413         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
11414
11415 2006-05-17  Bruno Haible  <bruno@clisp.org>
11416
11417         * lib/stdint_.h: Fix recognition of Cygwin.
11418
11419 2006-05-15  Bruno Haible  <bruno@clisp.org>
11420
11421         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
11422         on libtool patch by Ralf Wildenhues.
11423
11424 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
11425
11426         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
11427         test for C99 conformance; (bool) 0.5 is an integer constant
11428         expression, but (bool) -0.5 is not.  Problem reported by Fedor
11429         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
11430
11431 2006-05-11  Simon Josefsson  <jas@extundo.com>
11432
11433         * m4/xvasprintf.m4: Fix obvious typo.
11434
11435 2006-05-11  Jim Meyering  <jim@meyering.net>
11436
11437         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
11438         James Lemley.
11439
11440 2006-05-10  Simon Josefsson  <jas@extundo.com>
11441
11442         * lib/md4.c: Typo fix, update copyright years.
11443         (K1, K2): Don't use L because it turn computations into 64-bit on
11444         64-bit platforms.
11445
11446 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
11447
11448         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
11449         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
11450         unwanted sign propagation, e.g., on hosts with 64-bit int.
11451         There still are some problems with reeelly weird theoretical hosts
11452         (e.g., 33-bit int) but it's not worth worrying about now.
11453         * lib/sha1.c (rol): Likewise.
11454         (K1, K2, K3, K4): Remove unnecessary L suffix.
11455
11456 2006-05-10  Bruno Haible  <bruno@clisp.org>
11457
11458         * lib/des.c: Cast to avoid warnings.
11459
11460 2006-05-09  Bruno Haible  <bruno@clisp.org>
11461
11462         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
11463         (Depends-on): Depend also on xsize, stdarg.
11464         (configure.ac): Add gl_XVASPRINTF.
11465
11466 2006-05-09  Bruno Haible  <bruno@clisp.org>
11467
11468         * m4/xvasprintf.m4: New file.
11469
11470 2006-05-09  Bruno Haible  <bruno@clisp.org>
11471
11472         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
11473         (EOVERFLOW): Define fallback value.
11474         (xstrcat): New function.
11475         (xvasprintf): Recognize the special case of a string concatenation.
11476
11477 2006-05-08  Eric Blake  <ebb9@byu.net>
11478
11479         * gnulib-tool (func_version): Base copyright year on CVS date.
11480         (func_emit_copyright_notice): New function.
11481         (func_emit_lib_Makefile_am): Use it.
11482         (func_emit_tests_Makefile_am): Likewise.
11483         (func_import): Likewise.
11484
11485 2006-05-08  Bruno Haible  <bruno@clisp.org>
11486
11487         * modules/stdarg: New file.
11488         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
11489
11490 2006-05-08  Bruno Haible  <bruno@clisp.org>
11491
11492         * m4/stdarg.m4: New file, from GNU gettext.
11493
11494 2006-05-08  Bruno Haible  <bruno@clisp.org>
11495
11496         * config/srclist.txt (build-aux/config.rpath): different from latest
11497         release.
11498
11499 2006-05-08  Bruno Haible  <bruno@clisp.org>
11500
11501         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
11502
11503 2006-05-05  Jim Meyering  <jim@meyering.net>
11504
11505         * m4/warning.m4: New file, derived from bison's file by the same name.
11506
11507 2006-05-03  Bruno Haible  <bruno@clisp.org>
11508
11509         * lib/stdint_.h: Shorter URL.
11510         * lib/inttypes.h: Likewise.
11511
11512 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
11513
11514         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
11515
11516 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
11517
11518         * lib/verify.h: Document the internals better.  Most of this change
11519         was written by Bruno Haible.
11520
11521 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
11522
11523         * doc/verify.texi: New file, partly based on a proposal by
11524         Bruno Haible.
11525
11526 2006-05-02  Bruno Haible  <bruno@clisp.org>
11527
11528         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
11529         test from here...
11530         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
11531
11532 2006-04-29  Bruno Haible  <bruno@clisp.org>
11533
11534         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
11535         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
11536
11537 2006-04-29  Bruno Haible  <bruno@clisp.org>
11538
11539         * gnulib-tool: Make --update option actually work.
11540
11541 2006-04-29  Bruno Haible  <bruno@clisp.org>
11542
11543         * doc/gcd.texi: New file.
11544         * doc/gnulib.texi: Include it.
11545
11546 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
11547
11548         * lib/getdate.y (get_date): When adding relative date, start with the
11549         initial time, not with the result of the first mktime call.
11550
11551 2006-04-25  Bruno Haible  <bruno@clisp.org>
11552
11553         * gnulib-tool (func_import): Output the include directives in three
11554         blocks, sorted separately.
11555         Reported by Ben Pfaff <blp@cs.stanford.edu>.
11556
11557 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
11558
11559         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
11560         to define main with arguments, for C++.  Reported by Eric Blake.
11561         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
11562         Prefer 'int main ()' to 'int main (void)', for C++.
11563         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
11564         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
11565         for 'main', for C99 and C++.
11566
11567 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
11568
11569         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
11570         Don't assume that exit status -1 is valid.
11571         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
11572         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
11573         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
11574         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
11575         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
11576         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
11577         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
11578         functions can be used without declaring them, or that you can
11579         exit with status -1.
11580         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
11581
11582 2006-04-24  Karl Berry  <karl@gnu.org>
11583
11584         * config/srclist.txt (longdouble.m4): sync lost.
11585
11586 2006-04-24  Eric Blake  <ebb9@byu.net>
11587
11588         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
11589
11590 2006-04-24  Bruno Haible  <bruno@clisp.org>
11591
11592         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
11593         poll() implementation in AIX.
11594         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11595
11596 2006-04-24  Bruno Haible  <bruno@clisp.org>
11597
11598         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
11599         assigned exactly once.
11600
11601 2006-04-23  Claudio Fontana  <claudio@gnu.org>
11602             Bruno Haible  <bruno@clisp.org>
11603
11604         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
11605         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
11606         for AM_CPPFLAGS.
11607
11608 2006-04-23  Bruno Haible  <bruno@clisp.org>
11609
11610         * modules/copy-file: Depend on unistd.
11611         * modules/execute: Likewise.
11612         * modules/fatal-signal: Likewise.
11613         * modules/findprog: Likewise.
11614         * modules/mkdtemp : Likewise.
11615         * modules/pipe: Likewise.
11616         * modules/wait-process: Likewise.
11617
11618 2006-04-23  Bruno Haible  <bruno@clisp.org>
11619
11620         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
11621         condition was already detected.
11622         Reported by Ben Pfaff <blp@cs.stanford.edu>.
11623
11624 2006-04-23  Bruno Haible  <bruno@clisp.org>
11625
11626         * lib/copy-file.c: Include <unistd.h> unconditionally.
11627         * lib/execute.c: Likewise.
11628         * lib/fatal-signal.c: Likewise.
11629         * lib/findprog.c: Likewise.
11630         * lib/mkdtemp.c: Likewise.
11631         * lib/pipe.h: Likewise.
11632         * lib/pipe.c: Likewise.
11633         * lib/wait-process.h: Likewise.
11634
11635 2006-04-23  Bruno Haible  <bruno@clisp.org>
11636
11637         * gnulib-tool (func_usage): Fix --import description. Document
11638         --update.
11639         (func_import): Create temporary file in a temporary directory, if
11640         --dry-run is specified. Silence errors from 'grep' when there are no
11641         m4 files in $m4dir.
11642         (func_create_testdir): Silence errors from 'grep' when there are no
11643         m4 files in $m4dir.
11644         Reported by Karl Berry <karl@freefriends.org>.
11645
11646 2006-04-20  Bruno Haible  <bruno@clisp.org>
11647
11648         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
11649         one argument, so that the code will be portable to Autoconf 2.60.
11650         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
11651         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
11652         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
11653
11654 2006-04-19  Derek Price  <derek@ximbiot.com>
11655             Eric Blake  <ebb9@byu.net>
11656
11657         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
11658         rather than "/full/path.h".  Update comment to match.  Shorten &
11659         generalize m4_translit call via AS_TR_CPP.
11660
11661 2006-04-19  Derek Price  <derek@ximbiot.com>
11662             Eric Blake  <ebb9@byu.net>
11663
11664         * lib/inttypes.h: Correct grammar in comment.
11665
11666 2006-04-18  Derek Price  <derek@ximbiot.com>
11667             Paul Eggert  <eggert@cs.ucla.edu>
11668
11669         * modules/inttypes: New file.
11670         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
11671
11672 2006-04-18  Derek Price  <derek@ximbiot.com>
11673             Paul Eggert  <eggert@cs.ucla.edu>
11674
11675         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
11676         New files.
11677
11678 2006-04-18  Derek Price  <derek@ximbiot.com>
11679             Paul Eggert  <eggert@cs.ucla.edu>
11680
11681         * lib/inttypes.h: New file.
11682         * lib/strtoimax.c: Assume <inttypes.h>.
11683
11684 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
11685
11686         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
11687         isn't mounted.  Problem reported by Kir Kolyshkin.
11688
11689 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
11690
11691         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
11692         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
11693         Derek R. Price.
11694         * lib/regex.h (RE_DUP_MAX): Update comment to match current
11695         implementation.
11696
11697 2006-04-12  Eric Blake  <ebb9@byu.net>
11698
11699         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
11700         is now done automatically by the corresponding Autoconf macro.
11701
11702 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
11703
11704         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
11705         time_r.h.
11706
11707 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11708
11709         Merge regex changes from libc, removing some of our
11710         POSIX-conformance changes that were rejected and redoing them in a
11711         less-intrusive way.
11712
11713         * lib/regcomp.c (re_compile_internal, init_dfa):
11714         Length arg is now size_t, not Idx.  All uses changed.
11715         (peek_token): Forward decl now says internal_function.
11716         (__re_error_msgid, __re_error_msgid_idx):
11717         Now static rather than extern with attribute_hidden.
11718         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
11719         For some reason libc prefers K&R style defns for external functions.
11720         (regerror) [!defined _LIBC]: Likewise.
11721         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
11722         (seek_collating_symbol_entry, lookup_collation_sequence_value):
11723         (build_range_exp, build_collating_symbol):
11724         Use K&R-style defn.
11725         (re_compile_fastmap): Use '\0' to memset, not 0.
11726         (utf8_sb_map): Make the calculations more obvious.
11727         (init_dfa, parse_bracket_exp, build_charclass_op):
11728         Call calloc and cast result, as glibc does.
11729         (init_word_char, fetch_token, peek_token, peek_token_bracket):
11730         (build_range_exp, build_collating_symbol):
11731         Now internal functions.
11732
11733         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
11734
11735         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
11736         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
11737         Don't depend on VMS; depend on __VMS instead, for POSIX
11738         namespace cleanness.
11739         (regoff_t): Define to ssize_t, not long int.
11740
11741         Remove the REG_ macros named below.  Instead, make the old names
11742         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
11743         __USE_GNU_REGEX.
11744         (REG_BACKSLASH_ESCAPE_IN_LISTS):
11745         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
11746         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
11747         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
11748         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
11749         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
11750         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
11751         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
11752         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
11753         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
11754         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
11755         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
11756         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
11757         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
11758         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
11759         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
11760         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
11761         (REG_NREGS):
11762         Remove.  All uses replaced by the old RE_* names.
11763         (RE_BACKSLASH_ESCAPE_IN_LISTS):
11764         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
11765         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
11766         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
11767         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
11768         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
11769         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
11770         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
11771         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
11772         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
11773         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
11774         Don't bother having these macros be independent of each others'
11775         values, since they no longer exist in the POSIX name space.
11776
11777         Rename the following member names back to their old names,
11778         unless !__USE_GNU_REGEX.  All uses changed back.
11779         (buffer): Renamed from re_buffer.
11780         (allocated): Renamed from re_allocated.
11781         (used): Renamed from re_used.
11782         (syntax): Renamed from re_syntax.
11783         (fastmap): Renamed from re_fastmap.
11784         (translate): Renamed from re_translate.
11785         (can_be_null): Renamed from re_can_be_null.
11786         (regs_allocated): Renamed from re_regs_allocated.
11787         (fastmap_accurate): Renamed from re_fastmap_accurate.
11788         (no_sub): Renamed from re_no_sub.
11789         (not_bol): Renamed from re_not_bol.
11790         (not_eol): Renamed from re_not_eol.
11791         (newline_anchor): Renamed from re_newline_anchor.
11792         (num_regs): Renamed from rm_num_regs.
11793         (start): Renamed from rm_start.
11794         (end): Renamed from rm_end.
11795
11796         (free_state): Move up a bit.
11797
11798         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
11799         #define to be empty.
11800         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
11801         when that is what is intended.
11802         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
11803         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
11804         (MAX): New macro.
11805         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
11806         All uses changed back to re_malloc, etc.  It's now the caller's
11807         responsibility to check for overflow; all callers changed.
11808         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
11809         (re_x2nrealloc): Remove.
11810         (free_state): Remove decl.
11811
11812         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
11813         (re_set_registers, re_exec):
11814         Use K&R-style defn.
11815
11816         2006-01-31  Roland McGrath  <roland@redhat.com>
11817
11818         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
11819         Reported by Mike Frysinger <vapier@gentoo.org>.
11820
11821         2006-01-15  Andreas Jaeger  <aj@suse.de>
11822
11823         [BZ #1950]
11824         * lib/regex_internal.c (re_string_reconstruct): Adjust for
11825         build_wcs_upper_buffer change.
11826         (build_wcs_upper_buffer): Change return type.
11827
11828         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
11829
11830         * lib/regex_internal.h: Include <stdint.h> if available.
11831
11832         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
11833
11834         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
11835
11836         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
11837
11838         * lib/regcomp.c: Adjust for changed secondary hash function.
11839
11840         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
11841
11842         * lib/regex.h: Pretty printing.
11843         Clean up namespace a bit.
11844
11845         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
11846
11847         * lib/regexec.c (update_cur_sifted_state, check_arrival,
11848         check_arrival_add_next_nodes): Avoid using uninitialized variable.
11849
11850         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
11851                     Ulrich Drepper  <drepper@redhat.com>
11852
11853         [BZ #1302]
11854         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
11855         changed.
11856         (bitset_word_t): Renamed from bitset_word.  All uses changed.
11857
11858         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
11859
11860         [BZ #281]
11861         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
11862         * lib/regcomp.c: Remove unnecessary uses of
11863         unsigned RE_TRANSLATE_TYPE.
11864         * lib/regex_internal.h: Likewise.
11865         * lib/regex_internal.c: Likewise.
11866         * lib/regexec.c: Likewise.
11867         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
11868
11869         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
11870
11871         * lib/regexec.c (find_recover_state): Remove unnecessary
11872         initialization.
11873         (transit_state_bkref): Make DFA a const pointer.
11874         (get_subexp): Likewise.
11875         (check_arrival): Likewise.
11876         (update_cur_sifted_state): Likewise.
11877         (re_search_internal): Likewise.
11878         (prune_impossible_nodes): Likewise.
11879         (acquire_init_state_context): Likewise.
11880         (proceed_next_node): Likewise.
11881         (set_regs): Likewise.
11882         (free_fail_stack_return): Likewise.
11883         (check_arrival_expand_ecl): Mark DFA parameter as const.
11884         (check_arrival_expand_ecl_sub): Likewise.
11885         (check_subexp_limits): Likewise.
11886         (sub_epsilon_src_nodes):  Likewise.
11887         (add_epsilon_src_nodes):  Likewise.
11888         (merge_state_array): Likewise.
11889         (update_regs): Likewise.
11890         (build_trtable): Likewise.
11891         (sift_states_backward): Mark MCTX parameter as const.
11892         (build_sifted_states): Likewise.
11893         (update_cur_sifted_state): Likewise.
11894         (sift_states_mkref): Likewise.
11895         (check_arrival_expand_ecl): Mark eclosure as const.
11896         (check_dst_limits_calc_pos_1): Likewise.
11897         * lib/regex_internal.h (re_match_context_t): Make dfa a const
11898         pointer.
11899
11900         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
11901
11902         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
11903         (transit_state_sb): Likewise.
11904         (transit_state_mb): Likewise.
11905         (sift_states_iter_mb): Likewise.
11906         (check_arrival_add_next_nodes): Likewise.
11907         (check_node_accept_bytes): Change first parameter to pointer-to-const.
11908         [_LIBC] (re_search_2_stub): Use mempcpy.
11909
11910         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
11911         mbrtowc for very simple UTF-8 case.
11912
11913         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
11914         a pointer-to-const.
11915         (re_acquire_state_context): Likewise.
11916         * lib/regex_internal.h: Adjust prototypes.
11917
11918         * lib/regex.c: Prevent using C++ compilers.
11919
11920         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
11921         (re_acquire_state_context): Likewise.
11922
11923 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11924
11925         * modules/regex (Depends-on): Add ssize_t.
11926
11927 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11928
11929         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
11930         translation table.
11931
11932 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11933
11934         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
11935
11936 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
11937             Bruno Haible  <bruno@clisp.org>
11938
11939         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
11940         <sys/types.h> and <inttypes.h>.
11941
11942 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11943
11944         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
11945         `__error_t_defined', so argp.h will not typedef the former.
11946
11947 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
11948
11949         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
11950         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
11951         glibc names.  Even if glibc is changed to conform to POSIX, the
11952         traditional names will be available anyway, since regex depends on
11953         the extensions module.  Also, fix a longstanding typo in the
11954         implementation of Spencer ERE test #75 from grep 2.3.  Problems
11955         reported by Emanuele Giaquinta.  Also, change sense of cached
11956         variable, so that the message makes sense.
11957
11958 2006-03-24  Simon Josefsson  <jas@extundo.com>
11959
11960         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
11961         including some doc fixes.
11962         (base64_encode_alloc): Fix +1 bug on allocation failures.
11963
11964 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11965
11966         * lib/base64.c (base64_encode): Do not read past end of array with
11967         unsanitized input on systems with CHAR_BIT > 8.
11968
11969 2006-03-24  Eric Blake  <ebb9@byu.net>
11970
11971         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
11972
11973 2006-03-22  Karl Berry  <karl@gnu.org>
11974
11975         * config/srclist.txt (*setenv.[ch]): get from coreutils.
11976         * config/srclistvars.sh (COREUTILS): new var.
11977
11978 2006-03-17  Jim Meyering  <jim@meyering.net>
11979
11980         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
11981         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
11982
11983 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
11984
11985         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
11986         no longer needs it.  Instead, check that regoff_t is as least
11987         as wide as ptrdiff_t.
11988
11989         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
11990         so that our regex.h stays compatible with the installed regex.
11991         This is helpful for installers who configure --without-included-regex.
11992         Problem reported by Emanuele Giaquinta.
11993
11994 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
11995
11996         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
11997         Typedef to long int, not to off_, as POSIX will likely change
11998         in that direction.
11999
12000 2006-03-15  Eric Blake  <ebb9@byu.net>
12001
12002         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
12003
12004 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
12005
12006         * lib/argp-help.c (validate_uparams): Fix typo
12007         * lib/argp-parse.c (argp_default_options): Consistently begin help
12008         messages with a lowercase letter.
12009
12010 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
12011
12012         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
12013         overrun buffers and shouldn't be used (much as gets shouldn't be
12014         used).
12015         * lib/time_r.c (asctime_r, ctime_r): Likewise.
12016
12017 2006-03-08  Simon Josefsson  <jas@extundo.com>
12018
12019         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
12020         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12021
12022 2006-03-08  Simon Josefsson  <jas@extundo.com>
12023
12024         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
12025         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12026
12027 2006-03-08  Simon Josefsson  <jas@extundo.com>
12028
12029         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
12030         signal that configure disabled the device.
12031
12032 2006-03-08  Simon Josefsson  <jas@extundo.com>
12033
12034         * build-aux/maint.mk: Fix refresh-po, to handle no translated
12035         languages.
12036
12037 2006-03-07  Simon Josefsson  <jas@extundo.com>
12038
12039         * modules/getopt (Depends-on): Add unistd.
12040
12041         * modules/unistd: New file.
12042
12043 2006-03-07  Simon Josefsson  <jas@extundo.com>
12044
12045         * modules/gc-random: New file.
12046
12047 2006-03-07  Simon Josefsson  <jas@extundo.com>
12048
12049         * m4/unistd_h.m4: New file.
12050
12051 2006-03-07  Simon Josefsson  <jas@extundo.com>
12052
12053         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
12054         test to be side-effect free by storing the result in the cache
12055         variable gl_cv_lib_readline, and moving the assignment of
12056         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
12057         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12058
12059 2006-03-07  Simon Josefsson  <jas@extundo.com>
12060
12061         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
12062         error on missing devices (the functions will return an error).
12063
12064         * m4/gc.m4: Move random stuff to gc-random.m4
12065
12066 2006-03-07  Simon Josefsson  <jas@extundo.com>
12067
12068         * lib/unistd_.h: New file.
12069
12070 2006-03-07  Simon Josefsson  <jas@extundo.com>
12071
12072         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
12073
12074 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12075
12076         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
12077         Problem reported by Juan Manuel Guerrero.
12078
12079 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12080
12081         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
12082         the unistd module.
12083         * lib/getlogin_r.c: Likewise.
12084         * lib/getlogin_r.h: Likewise.
12085         * lib/glob.c: Likewise.
12086         * lib/pagealign_alloc.c: Likewise.
12087         * lib/unistd_.h: Remove; no longer needed.
12088
12089 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12090
12091         * MODULES.html.sh (Support for systems lacking POSIX:2001):
12092         Add unistd.
12093         * modules/c-stack (Depends-on): Add unistd.
12094         * modules/getlogin_r: Likewise.
12095         * modules/glob: Likewise.
12096         * modules/pagealign_alloc: Likewise.
12097         * modules/unistd (Files): Remove lib/unistd_.h.
12098         (EXTRA_DIST): Remove.
12099         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
12100         need unistd_.h.
12101         (MOSTLYCLEANFILES): Remove unistd.h-t.
12102
12103 2006-03-03  Simon Josefsson  <jas@extundo.com>
12104
12105         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
12106
12107 2006-03-03  Simon Josefsson  <jas@extundo.com>
12108
12109         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
12110         libidn and bison.
12111
12112 2006-03-03  Simon Josefsson  <jas@extundo.com>
12113
12114         * build-aux/maint.mk: Add indent target.
12115
12116 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
12117
12118         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
12119         our replacement poll.h in any case, to avoid a differing
12120         declaration from a system header.  Seen on AIX.
12121
12122 2006-03-01  Simon Josefsson  <jas@extundo.com>
12123
12124         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
12125         <kasal@ucw.cz>.
12126
12127 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
12128
12129         * modules/gettime (Depends-on): Add extensions module.
12130         * modules/nanosleep (Depends-on): Likewise.
12131         * modules/settime (Depends-on): Likewise.
12132
12133 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
12134
12135         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
12136         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
12137         pedantically.
12138         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
12139         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
12140
12141         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
12142         not "==".  Reported by Ralf Wildenhues.
12143
12144 2006-03-01  Karl Berry  <karl@gnu.org>
12145
12146         * doc/Copyright/request-*: new files, synced from gnuorg.
12147
12148 2006-03-01  Karl Berry  <karl@gnu.org>
12149
12150         * config/srclist.txt (Copyright/*): new entries.
12151
12152 2006-02-28  Simon Josefsson  <jas@extundo.com>
12153
12154         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
12155
12156 2006-02-27  Simon Josefsson  <jas@extundo.com>
12157
12158         * lib/base64.h: Indent #define's.  From Jim Meyering
12159         <jim@meyering.net>.
12160
12161 2006-02-27  Jim Meyering  <jim@meyering.net>
12162
12163         Revert the change of 2006-02-24, so these files can continue
12164         to be sync'd from gettext.
12165         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
12166         of `config.h'.
12167
12168 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
12169
12170         * modules/intprops: New file.
12171         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
12172         Add intprops.
12173         * modules/getloadavg (Files): Remove lib/intprops.h.
12174         (Depends-on): Add intprops.
12175         * modules/human: Likewise.
12176         * modules/inttostr: Likewise.
12177         * modules/openat: Likewise.
12178         * modules/sig2str: Likewise.
12179         * modules/userspec: Likewise.
12180         * modules/utimecmp: Likewise.
12181         * modules/xnanosleep: Likewise.
12182         * modules/xstrtol: Likewise.
12183
12184 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
12185
12186         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
12187         * modules/lock-tests (TESTS): Use $(EXEEXT).
12188         * modules/tls-tests: Likewise.
12189         * modules/argp-tests: Likewise.
12190         (check_PROGRAMS): New var, replacing...
12191         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
12192
12193 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12194
12195         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
12196         `config.h'.
12197
12198 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
12199
12200         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
12201
12202 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12203
12204         Sync from coreutils.
12205         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
12206         gl_CHDIR_SAFER.
12207
12208 2006-02-22  Jim Meyering  <jim@meyering.net>
12209
12210         Sync from coreutils.
12211         * m4/chdir-safer.m4: New file.
12212
12213 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
12214
12215         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
12216         AT_FDCWD exceeds INT_MAX.
12217         * lib/openat.h (AT_FDCWD): Likewise.
12218
12219 2006-02-17  Eric Blake  <address@hidden>
12220
12221         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
12222
12223 2006-02-16  Simon Josefsson  <jas@extundo.com>
12224
12225         * modules/getaddrinfo (Depends-on): Add sys_socket.
12226
12227 2006-02-15  Simon Josefsson  <jas@extundo.com>
12228
12229         * build-aux/maint.mk: Add dsyntax-check rule.
12230
12231 2006-02-15  Eric Blake  <ebb9@byu.net>
12232
12233         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
12234         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
12235         'present but cannot compile' warnings on cygwin.
12236         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
12237         use ws2tcpip.h if sys/socket.h works.
12238         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
12239         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
12240
12241 2006-02-14  Simon Josefsson  <jas@extundo.com>
12242
12243         * modules/maintainer-makefile (Files): Rename.
12244
12245         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
12246         and (the local) Makefile.cfg to maint-cfg.mk.
12247
12248         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
12249         to the latter.
12250
12251         * modules/maintainer-makefile: New module.
12252
12253         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
12254         severaly stripped to make it possible to build it up from scratch
12255         with reliable tests.
12256
12257         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
12258         fixes to permit overriding the default actions when configure and
12259         makefile are not available.
12260
12261 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
12262
12263         Sync from coreutils.
12264         * modules/lstat (Depends-on): Don't depend on xalloc.
12265         (License): Change from GPL to LGPL, since this is now simply a
12266         replacement for a libc function.
12267
12268 2006-02-14  Jim Meyering  <jim@meyering.net>
12269
12270         Sync from coreutils.
12271
12272         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
12273         failure on deficient systems, and simplify gnulib lgpl dependencies.
12274         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
12275         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
12276
12277         * lib/xalloc-die.c: Remove unused definition of N_.
12278
12279 2006-02-14  Jim Meyering  <jim@meyering.net>
12280
12281         Sync from coreutils.
12282         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
12283         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
12284         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
12285         double-quote uses of that variable, to accommodate the rare case in
12286         which getmntent is available in none of the libraries checked.  This
12287         happens at least on FreeBSD 5.0.
12288
12289 2006-02-13  Simon Josefsson  <jas@extundo.com>
12290
12291         * gnulib-tool (Usage): Fix --import, from
12292         karl@freefriends.org (Karl Berry).
12293
12294 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
12295
12296         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
12297
12298 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
12299
12300         * lib/argp-namefrob.h: Restore changes accidentally lost during the
12301         "autoupdate" on 2005-12-12.
12302
12303 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
12304
12305         * modules/closeout (Depends-on): Remove atexit.
12306
12307 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
12308
12309         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
12310         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
12311
12312 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
12313
12314         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
12315         __EXTENSIONS__ if this causes compilation to fail.  Problem
12316         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
12317         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
12318
12319 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
12320
12321         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
12322         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
12323         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
12324         All uses changed.
12325
12326 2006-01-26  Simon Josefsson  <jas@extundo.com>
12327
12328         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
12329         prototype is visible on mingw32.
12330
12331         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
12332         for mingw32.
12333
12334         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
12335         mingw32).
12336
12337 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
12338
12339         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
12340         attempt to open for write; this always fails, at least on POSIX
12341         hosts.  This reinstates the 2006-01-09 change, which was
12342         inadvertently removed.
12343
12344 2006-01-26  Bruno Haible  <bruno@clisp.org>
12345
12346         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
12347         Reported by Paul Eggert.
12348
12349 2006-01-26  Bruno Haible  <bruno@clisp.org>
12350             Paul Eggert  <eggert@cs.ucla.edu>
12351
12352         * lib/stdbool_.h (_Bool)
12353         [(! (defined __cplusplus || defined __BEOS__)
12354           && !defined __GNUC__
12355           && !(defined __HP_cc || defined __xlc__
12356                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
12357                || defined __sgi))]:
12358         #define to signed char in these cases too; this simplifies
12359         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
12360         etc., separately) and makes it more conservative.
12361
12362 2006-01-25  Simon Josefsson  <jas@extundo.com>
12363
12364         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
12365         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
12366         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
12367
12368 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
12369
12370         * lib/argp-namefrob.h: Bugfix. Remove stray #
12371
12372 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
12373
12374         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
12375         so that we test the test.
12376         Check for yet another HP-UX cc bug involving *bool |= bool.
12377
12378 2006-01-25  Karl Berry  <karl@gnu.org>
12379
12380         * config/srclist.txt (vasnprintf.c): sync lost.
12381
12382 2006-01-25  Jim Meyering  <jim@meyering.net>
12383
12384         Sync from the stable (b5) branch of coreutils:
12385
12386         * lib/fts.c (fts_children): Don't let close() clobber errno from
12387         failed fchdir().
12388
12389         * lib/fts.c (fts_stat): When following a symlink-to-directory,
12390         don't necessarily interpret stat-fails+lstat-succeeds as indicating
12391         a dangling symlink.  That can also happen at least for ELOOP.
12392         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
12393         FYI, this bug predates the inclusion of fts.c in coreutils.
12394
12395         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
12396         in their own block, so pre-c99 compilers don't object.
12397
12398         Avoid the double-free (first in fts_read, second in fts_close) that
12399         would occur when an `active' directory is made inaccessible (e.g.,
12400         via chmod a-x) during a traversal.
12401         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
12402         before returning.  Reproduce this failure by
12403         mkdir -p a/b; cd a; chmod a-x . b
12404         Reported by Stavros Passas.
12405
12406 2006-01-25  Jim Meyering  <jim@meyering.net>
12407
12408         * lib/fileblocks.c: Remove more useless parentheses.
12409         * lib/readutmp.h: Likewise.
12410
12411 2006-01-25  Bruno Haible  <bruno@clisp.org>
12412
12413         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
12414         warnings.
12415         Reported by Paul Eggert.
12416
12417 2006-01-25  Bruno Haible  <bruno@clisp.org>
12418
12419         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
12420         rid of a trap command. For Solaris sh.
12421         Reported by Mark D. Baushke <mdb@gnu.org>.
12422
12423 2006-01-24  Simon Josefsson  <jas@extundo.com>
12424
12425         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
12426         Bruno.
12427
12428 2006-01-24  Karl Berry  <karl@gnu.org>
12429
12430         * config/srclist.txt (argp-namefrob.h): sync lost.
12431
12432 2006-01-24  Jim Meyering  <jim@meyering.net>
12433
12434         * modules/openat (Files): Add lib/intprops.h.
12435         From Mark D. Baushke.
12436
12437 2006-01-24  Jim Meyering  <jim@meyering.net>
12438
12439         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
12440         Reported by Mark D. Baushke.
12441
12442 2006-01-24  Jim Meyering  <jim@meyering.net>
12443
12444         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
12445
12446 2006-01-24  Bruno Haible  <bruno@clisp.org>
12447
12448         * modules/strnlen (Maintainer): Change from glibc to all.
12449
12450 2006-01-24  Bruno Haible  <bruno@clisp.org>
12451
12452         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
12453         Patch by Paul Eggert.
12454
12455 2006-01-24  Bruno Haible  <bruno@clisp.org>
12456
12457         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
12458         already has it.
12459         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
12460         2005-11-26.
12461
12462         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
12463         'signed char' to avoid problems with the built-in _Bool type.
12464         Reported by Paul Eggert on 2005-11-26.
12465
12466 2006-01-24  Bruno Haible  <bruno@clisp.org>
12467
12468         * gnulib-tool (func_import): Avoid constructing complicated sed
12469         expressions inside backquote.
12470         Report and solution by Mark D. Baushke <mdb@gnu.org>.
12471
12472 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
12473
12474         These changes imported from libc.
12475         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
12476         test and two separate function calls.
12477         * lib/strndup.c (__strndup): Add libc_hidden_def.
12478
12479 2006-01-23  Simon Josefsson  <jas@extundo.com>
12480
12481         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
12482         Remove the test_*_SOURCES variable: automake infers it by default.
12483         * modules/tls-tests: Likewise.
12484
12485 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
12486
12487         Work around porting bugs reported by Dieter in
12488         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
12489         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
12490         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
12491         Include "getopt.h" first, to check interface.
12492         (getenv): Declare only if defined HAVE_DECL_GETENV &&
12493         !HAVE_DECL_GETENV.
12494         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
12495         (__strndup): Revert to K&R-style function dfns, the glibc style.
12496         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
12497         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
12498         Include strnlen.h first, to get prototype properly.
12499         (strnlen): Renamed from __strnlen.
12500         Remove weak alias.
12501
12502 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
12503
12504         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
12505
12506 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
12507
12508         * config/srclist.txt: Adjust to reflect glibc reorganization.
12509         This affects only comments.
12510
12511 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
12512
12513          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
12514          Reported by Bruce Korb <bkorb@gnu.org>.
12515
12516 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
12517
12518         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
12519         to pacify gcc -Wswitch-default.
12520
12521 2006-01-22  Bruno Haible  <bruno@clisp.org>
12522
12523         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
12524         temporary buffer for sprintf, take into account the precision also
12525         for 'd', 'i', 'u', 'o', 'x', 'X'.
12526
12527 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
12528
12529         * modules/argp-tests: New module
12530         * tests/test-argp.c: New file
12531         * tests/test-argp-2.sh: New file
12532
12533 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
12534
12535         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
12536         (__argp_base_name): Removed
12537         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
12538         typo.
12539         (__argp_base_name): Provide macro definition or extern declaration
12540         depending on the configuration
12541
12542 2006-01-20  Simon Josefsson  <jas@extundo.com>
12543
12544         * modules/inet_ntop (Depends-on): Depend on sys_socket.
12545
12546 2006-01-20  Simon Josefsson  <jas@extundo.com>
12547
12548         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
12549
12550 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
12551
12552         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
12553         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
12554         Suggested by Bruno Haible.
12555
12556 2006-01-20  Karl Berry  <karl@gnu.org>
12557
12558         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
12559         until changes propagate, I guess.
12560
12561 2006-01-19  Simon Josefsson  <jas@extundo.com>
12562
12563         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
12564
12565 2006-01-19  Simon Josefsson  <jas@extundo.com>
12566
12567         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
12568
12569 2006-01-19  Simon Josefsson  <jas@extundo.com>
12570
12571         * gnulib-tool: Set check_PROGRAMS.
12572
12573         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
12574         modules/des-tests, modules/gc-arcfour-tests,
12575         modules/gc-arctwo-tests, modules/gc-des-tests,
12576         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
12577         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
12578         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
12579         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
12580         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
12581         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
12582         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
12583         test_*_SOURCES.
12584
12585 2006-01-18  Simon Josefsson  <jas@extundo.com>
12586
12587         * modules/socklen (Depends-on): Depend on sys_socket.
12588
12589 2006-01-18  Simon Josefsson  <jas@extundo.com>
12590
12591         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
12592         modules/des-tests, modules/gc-arcfour-tests,
12593         modules/gc-arctwo-tests, modules/gc-des-tests,
12594         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
12595         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
12596         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
12597         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
12598         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
12599         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
12600         $(EXEEXT) to automake TESTS variable, for mingw32.
12601
12602 2006-01-17  Simon Josefsson  <jas@extundo.com>
12603
12604         * modules/socklen (Include): Need sys/socket.h.
12605
12606 2006-01-17  Bruno Haible  <bruno@clisp.org>
12607
12608         * modules/ssize_t (Include): Add <sys/types.h>.
12609
12610 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
12611
12612         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
12613         it's not portable and it doesn't work with cross-compiles.
12614         Problem reported by Bruno Haible.  Fix missing-$ typo in
12615         'test "gl_cv_ignore_unused_libraries" ...' that prevented
12616         -zignore from being used with Sun's C compiler.
12617
12618 2006-01-12  Simon Josefsson  <jas@extundo.com>
12619
12620         * lib/base64.c: Fix warning, reported by Bruno Haible
12621         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
12622
12623 2006-01-12  Bruno Haible  <bruno@clisp.org>
12624
12625         * modules/ldd: New file.
12626         * build-aux/ldd.sh.in: New file.
12627         * MODULES.html.sh (Support for building libraries and executables): Add
12628         ldd.
12629
12630 2006-01-12  Bruno Haible  <bruno@clisp.org>
12631
12632         * m4/ldd.m4: New file.
12633
12634 2006-01-12  Bruno Haible  <bruno@clisp.org>
12635
12636         * gnulib-tool (func_import, func_create_testdir): Don't go into an
12637         endless loop while replacing $auxdir with build-aux.
12638
12639 2006-01-11  Simon Josefsson  <jas@extundo.com>
12640
12641         * lib/stdint_.h (SIZE_MAX): Add missing (.
12642
12643 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
12644
12645         Sync from coreutils.
12646         * lib/md5.c: Fix commentary typos.
12647         (alignof, UNALIGNED_P): No need for a GCC-specific version.
12648         * lib/md5.h (__attribute__): Remove; unused.
12649         * lib/sha1.c: Fix commentary to match md5 better.
12650         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
12651         so that we don't need to worry about alignment.  All uses changed.
12652         This merges the 2005-10-28 md5 change into sha1.
12653
12654 2006-01-11  Jim Meyering  <jim@meyering.net>
12655
12656         Sync from coreutils.
12657         * lib/md5.c (OP): Fix spacing.
12658
12659 2006-01-11  Bruno Haible  <bruno@clisp.org>
12660
12661         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12662         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
12663         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
12664
12665 2006-01-11  Bruno Haible  <bruno@clisp.org>
12666
12667         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12668         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
12669         the "early" section as well.
12670
12671 2006-01-11  Bruno Haible  <bruno@clisp.org>
12672
12673         Avoid "ar: no archive members specified" error on MacOS X.
12674         * gnulib-tool (func_modules_add_dummy): New function.
12675         (func_import, func_create_testdir): Invoke it.
12676
12677 2006-01-11  Bruno Haible  <bruno@clisp.org>
12678
12679         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
12680         with $auxdir in AC_CONFIG_FILES statements.
12681
12682 2006-01-11  Bruno Haible  <bruno@clisp.org>
12683
12684         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12685         Initialize also noinst_HEADERS to empty.
12686
12687 2006-01-11  Bruno Haible  <bruno@clisp.org>
12688
12689         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
12690         variables.
12691         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
12692         autoreconf.
12693
12694 2006-01-11  Bruno Haible  <bruno@clisp.org>
12695
12696         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
12697         overridable by the user.
12698         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12699
12700 2006-01-10  Simon Josefsson  <jas@extundo.com>
12701
12702         * modules/sys_socket: New file.
12703
12704 2006-01-10  Simon Josefsson  <jas@extundo.com>
12705
12706         * m4/sys_socket_h.m4: New file.
12707
12708 2006-01-10  Simon Josefsson  <jas@extundo.com>
12709
12710         * lib/socket_.h: New file.
12711
12712 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12713
12714         * modules/readutmp (Maintainer): Add myself.
12715
12716 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12717
12718         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
12719         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
12720         People who are still concerned with buggy memcmp implementations
12721         can invoke gl_FUNC_MEMCMP themselves.
12722
12723 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12724
12725         * lib/regex_internal.h (BITSET_WORD_BITS):
12726         Work around a bug in 64-bit PGC (before version 6.1-2), where the
12727         preprocessor mishandles large unsigned values as if they were signed.
12728         Problem reported by Claudio Fontana in
12729         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
12730
12731 2006-01-10  Jim Meyering  <jim@meyering.net>
12732
12733         Avoid the double-free (first in fts_read, second in fts_close) that
12734         would occur when an `active' directory is made inaccessible (e.g.,
12735         via chmod a-x) during a traversal.
12736         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
12737         before returning.  Reproduce this failure by
12738         mkdir -p a/b; cd a; chmod a-x . b
12739         Reported by Stavros Passas.
12740
12741         Sync from coreutils.
12742         * lib/sha1.c: Tweak grammar in a comment.
12743
12744 2006-01-10  Jim Meyering  <jim@meyering.net>
12745
12746         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
12747         Patch by Joerg Sonnenberger.
12748
12749 2006-01-10  Bruno Haible  <bruno@clisp.org>
12750
12751         * modules/readutmp: Depend on module free.
12752         * modules/strtok_r: Depend on module restrict.
12753
12754 2006-01-10  Bruno Haible  <bruno@clisp.org>
12755
12756         * modules/gettext (configure.ac): Add an invocation of
12757         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
12758
12759 2006-01-10  Bruno Haible  <bruno@clisp.org>
12760
12761         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
12762         Reported by Werner Lemberg <wl@gnu.org>.
12763
12764 2006-01-10  Bruno Haible  <bruno@clisp.org>
12765
12766         * lib/localcharset.c: Update from GNU gettext.
12767
12768 2006-01-10  Bruno Haible  <bruno@clisp.org>
12769
12770         * lib/argp.h (__const): Remove macro. Use const instead.
12771         * lib/argp-fmtstream.h (__const): Likewise.
12772         * lib/glob_.h (__const): Remove macro.
12773         * lib/glob-libc.h: Use const instead of __const.
12774
12775 2006-01-10  Bruno Haible  <bruno@clisp.org>
12776
12777         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
12778         variable.
12779         Needed to avoid an automake error regarding the 'gettext' module.
12780
12781 2006-01-09  Simon Josefsson  <jas@extundo.com>
12782
12783         * modules/inet_ntop (Depends-on): Add restrict.
12784
12785 2006-01-09  Simon Josefsson  <jas@extundo.com>
12786
12787         * modules/gc-rijndael-tests (License): Put under LGPL.
12788
12789         * modules/gc-des-tests (License): Likewise.
12790
12791         * modules/gc-arcfour-tests (License): Likewise.
12792
12793         * modules/gc-arctwo-tests (License): Likewise.
12794
12795         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
12796
12797         * modules/gc-hmac-sha1-tests (Files): Likewise.
12798
12799         * modules/gc-hmac-md5-tests (License): Likewise.
12800
12801         * modules/gc-sha1-tests (License): Likewise.
12802
12803         * modules/gc-md5-tests (License): Likewise.
12804
12805         * modules/gc-md4-tests (License): Likewise.
12806
12807         * modules/gc-md2-tests (License): Likewise.
12808
12809         * modules/gc-tests (License): Likewise.
12810
12811         * modules/des-tests (License): Likewise.
12812
12813         * modules/md4-tests (License): Likewise.
12814
12815         * modules/md2-tests (License): Likewise.
12816
12817 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12818
12819         Sync from coreutils:
12820
12821         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
12822         * modules/lib-ignore: New file.
12823         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
12824         chdir-safer.m4, lchmod.m4.
12825         * modules/openat: Add mkdirat.c, openat-priv.h.
12826
12827 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12828
12829         Sync from coreutils.
12830         * m4/lib-ignore.m4: New file.
12831         * m4/lchmod.m4: New file.
12832
12833 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12834
12835         Sync from coreutils.
12836         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
12837         for write access: POSIX says that must fail.
12838         * lib/fts.c (diropen): Likewise.
12839         * lib/save-cwd.c (save_cwd): Likewise.
12840         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
12841         well, for minor improvements on hosts that lack O_DIRECTORY.
12842         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
12843         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
12844         Fall back on chown if open failed with EACCES.
12845
12846         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
12847         Report an error at compile-time if only a 1-second nominal clock
12848         resolution is found.
12849
12850         * lib/lchmod.h: New file.
12851         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
12852         (make_dir_parents): Use lchown rather than chown, and
12853         lchmod rather than chmod.
12854
12855         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
12856         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
12857         "proc" reported by n0dalus.
12858
12859         * lib/mountlist.c: Include <limits.h>.
12860         (dev_from_mount_options)
12861         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
12862         New function.  It no longer assumes "dev=" has the System V meaning
12863         on Linux (since it doesn't).  It also parses "dev=" more carefully.
12864         (read_file_system_list)
12865         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
12866         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
12867         dev= in that case.
12868
12869         * lib/posixtm.h (PDS_PRE_2000): New macro.
12870         * lib/posixtm.c (year): Arg is now syntax_bits rather than
12871         allow_century.  All usages changed.  Reject dates outside the range
12872         1969-1999 if PDS_PRE_2000 is used.
12873
12874 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12875
12876         Sync from coreutils.
12877         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
12878         (Time of day items): Mention the possibility of leap seconds.
12879         Problem reported by Dr. David Alan Gilbert.
12880
12881 2006-01-09  Jim Meyering  <jim@meyering.net>
12882
12883         Sync from coreutils.
12884
12885         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
12886
12887         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
12888
12889         * lib/modechange.c (mode_compile): Reject an invalid mode string
12890         that starts with an octal digit.  From Andreas Gruenbacher.
12891
12892         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
12893         and dup to open_safer and dup_safer, respectively.
12894         (openat_permissive): Fix typo in comment.
12895
12896         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
12897         "gettext.h"; either no longer needed or are guaranteed by openat.h.
12898         (_): Remove; no longer needed.
12899         (openat): Renamed from rpl_openat; no need for rpl_openat
12900         since openat.h renames openat for us.
12901         Replace most of the body with a call to openat_permissive,
12902         to avoid duplicate code.
12903         Port to (probably hypothetical) environments were mode_t is
12904         wider than int.
12905         (openat_permissive): Require mode arg, so that we can check
12906         types better.  Put it just after flags.  Change cwd failure
12907         indicator from pointer-to-bool to pointer-to-errno-value.
12908         All callers changed.
12909         Invoke openat_save_fail and/or openat_restore_fail if
12910         cwd_errno is null, so that openat can call us.
12911         (openat_permissive, fdopendir, fstatat, unlinkat):
12912         Simplify errno handling to avoid some duplicate code,
12913         as it's OK to set errno on success.
12914         * lib/openat.h: Revamp code so that function macros depend on
12915         __OPENAT_PREFIX only, not also on AT_FDCWD.
12916         (openat_ro): Remove.  Caller changed to use openat_permissive.
12917         (openat_permissive): Now a macro, if not a function.
12918         (openat_restore_fail, openat_save_fail): Now always functions,
12919         since mkdirat needs them even if __OPENAT_PREFIX is defined.
12920
12921         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
12922         and openat.c.
12923         * lib/mkdirat.c: Include openat-priv.h.
12924         Remove definitions of macros defined therein.
12925         * lib/openat.c: Likewise.
12926
12927         * lib/mkdirat.c (mkdirat): New file and function.
12928         * lib/openat.h (mkdirat): Declare.
12929
12930         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
12931
12932         * lib/openat.h (openat_permissive): Declare.
12933         (openat_ro): Define.
12934
12935         * lib/openat.c (EXPECTED_ERRNO): New macro.
12936         (openat_permissive): New function -- used in remove.c rewrite.
12937         (all functions): Set errno just before returning, only if there
12938         was an actual failure.
12939         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
12940
12941         Emulate openat-family functions using Linux's procfs, if possible.
12942         Idea and some code based on Ulrich Drepper's glibc changes.
12943
12944         * lib/openat.c: (BUILD_PROC_NAME): New macro.
12945         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
12946         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
12947         before falling back on save_cwd and restore_cwd.
12948         (fdopendir, fstatat, unlinkat): Likewise.
12949
12950         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
12951         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
12952
12953         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
12954         as second argument to va_arg.  Otherwise, some versions of gcc
12955         warn that `if this code is reached, the program will abort'.
12956
12957 2006-01-09  Jim Meyering  <jim@meyering.net>
12958
12959         Sync from coreutils.
12960         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
12961         Require openat-priv.h.
12962
12963 2006-01-09  Bruno Haible  <bruno@clisp.org>
12964
12965         * modules/strnlen (Include): Use strnlen.h.
12966
12967 2006-01-09  Bruno Haible  <bruno@clisp.org>
12968
12969         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
12970
12971 2006-01-09  Bruno Haible  <bruno@clisp.org>
12972
12973         * lib/sysexit_.h (EX_OK): New macro.
12974         Suggested by Martin Lambers <marlam@marlam.de>.
12975
12976 2006-01-09  Bruno Haible  <bruno@clisp.org>
12977
12978         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
12979         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
12980
12981 2006-01-09  Bruno Haible  <bruno@clisp.org>
12982
12983         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
12984         numbers.
12985
12986 2006-01-09  Bruno Haible  <bruno@clisp.org>
12987
12988         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
12989         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
12990         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
12991         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
12992
12993 2006-01-09  Bruno Haible  <bruno@clisp.org>
12994
12995         * build-aux/javacomp.sh.in: New file, moved from lib/.
12996         * modules/javacomp-script (Files): Update.
12997         (configure.ac): Add AC_CONFIG_FILES invocation.
12998         (EXTRA_DIST): Remove variable.
12999
13000         * build-aux/javaexec.sh.in: New file, moved from lib/.
13001         * modules/javaexec (Files): Update.
13002         (configure.ac): Add AC_CONFIG_FILES invocation.
13003         (EXTRA_DIST): Remove javaexec.sh.in.
13004
13005         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
13006         * modules/csharpcomp-script (Files): Update.
13007         (configure.ac): Add AC_CONFIG_FILES invocation.
13008         (EXTRA_DIST): Remove variable.
13009
13010         * build-aux/csharpexec.sh.in: New file, moved from lib/.
13011         * modules/csharpexec (Files): Update.
13012         (configure.ac): Add AC_CONFIG_FILES invocation.
13013         (EXTRA_DIST): Remove csharpexec.sh.in.
13014
13015 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
13016
13017         Sync from coreutils.
13018
13019         Add POSIX ACL support
13020         * lib/acl.h (copy_acl, set_acl): Add declarations.
13021         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
13022         systems other than Linux.
13023         (chmod_or_fchmod): New function: use fchmod when possible,
13024         and chmod otherwise.
13025         (file_has_acl): Add a POSIX ACL implementation, with a
13026         Linux-specific subcase.
13027         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
13028         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
13029         acls are unsupported.
13030         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
13031         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
13032         are unsupported.
13033
13034 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
13035
13036         Sync from coreutils.
13037         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
13038
13039 2006-01-07  Bruno Haible  <bruno@clisp.org>
13040
13041         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
13042         gl_EARLY.
13043
13044 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13045
13046         * lib/strftime.c (tzname): Don't declare if it is already #defined.
13047         Problem reported for Mingw by Mark Junker.
13048
13049 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13050
13051         * README: Gnulib normally doesn't generate a tarball.
13052
13053 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
13054
13055         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
13056         long int, not int, for nanosecond counts, so that people who are
13057         used to POSIX struct timespec won't be surprised.  Reported by Jim
13058         Meyering.
13059
13060 2005-12-28  Bruno Haible  <bruno@clisp.org>
13061
13062         * build-aux/config.rpath: Update from GNU gettext.
13063
13064 2005-12-16  Jim Meyering  <jim@meyering.net>
13065
13066         * modules/fprintftime: New module.
13067         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
13068
13069 2005-12-16  Jim Meyering  <jim@meyering.net>
13070
13071         * m4/fprintftime.m4: New file.
13072
13073 2005-12-16  Jim Meyering  <jim@meyering.net>
13074
13075         * lib/fprintftime.c, lib/fprintftime.h: New files.
13076
13077 2005-12-15  Simon Josefsson  <jas@extundo.com>
13078
13079         * modules/socklen (configure.ac): Fix M4 macro name, to align with
13080         new m4/socklen.m4.
13081
13082 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
13083
13084         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
13085         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
13086
13087 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
13088
13089         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
13090         * lib/argp-help.c (fill_in_uparams): Check if the constructed
13091         struct uparams is valid. Fall back to the default values if it is
13092         not.
13093
13094 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13095
13096         * modules/argp (Files): Add argp-pin.c
13097         (Depends-on): dirname
13098         (lib_SOURCES): Add argp-pin.c
13099
13100 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13101
13102         * m4/argp.m4:  Check if program_invocation_name and
13103         program_invocation_short_name are declared and define appropriate
13104         macros if they are not.
13105
13106 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13107
13108         * lib/argp-help.c (__argp_base_name): New function
13109         (__argp_short_program_name): Rewrite using __argp_base_name
13110         * lib/argp-namefrob.h: Define program_invocation_name and
13111         program_invocation_short_name if requested
13112         (__argp_base_name): Add prototype
13113         * lib/argp-parse.c (argp_def): Use gettext wrappers
13114         (argp_default_parser): Use __argp_base_name
13115         * lib/argp-pin.c: New file. Defines program_invocation_name and
13116         program_invocation_short_name on systems that lack them.
13117
13118 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13119
13120         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
13121         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
13122         porting problem reported by Georg Schwarz in
13123         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
13124
13125 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13126
13127         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
13128         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
13129         porting problem reported by Georg Schwarz in
13130         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
13131
13132 2005-12-05  Bruno Haible  <bruno@clisp.org>
13133
13134         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
13135         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
13136         Reported by Mark Junker <mjscod@gmx.de>.
13137
13138 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
13139
13140         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
13141         Use implementation from Albert Chin, with some
13142         comments/corrections by Stepan Kasal and myself.
13143
13144 2005-12-02  Bruno Haible  <bruno@clisp.org>
13145
13146         * gnulib-tool (func_import): Accept GPLed build tool modules when
13147         --lgpl is given.
13148         * modules/csharpcomp-script: New file.
13149         * modules/csharpcomp: Depend on it.
13150         * modules/javacomp-script: New file.
13151         * modules/javacomp: Depend on it.
13152         Suggested by Simon Josefsson.
13153
13154 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
13155
13156         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
13157         statement, to work around an HP-UX 10.20 compiler bug reported by
13158         Peter O'Gorman.
13159
13160 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
13161
13162         * modules/savedir (Depends-on): Add openat.
13163
13164 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
13165
13166         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
13167         (uintmax_t) [defined uintmax_t]: Do not declare.
13168         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
13169         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
13170         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
13171         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
13172         sake of portability to weird hosts that C allows (though we don't
13173         know of any practical examples).
13174
13175         * lib/savedir.h (fdsavedir): New decl.
13176         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
13177         contains most of the former guts of savedir.
13178         (savedir): Use savedirstream.
13179         Include "openat.h".
13180
13181 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13182
13183         * modules/obstack (Files): Add m4/ulonglong.m4.
13184         Problem reported by Davide Angelocola.
13185
13186 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
13187
13188         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
13189         coreutils no longer futzes with rounding modes.
13190
13191 2005-11-14  Jim Meyering  <jim@meyering.net>
13192
13193         * lib/mkstemp-safer.c: Include <config.h>, required for possible
13194         replacement of mkstemp.
13195
13196 2005-11-10  Simon Josefsson  <jas@extundo.com>
13197
13198         * lib/readline.c: Remove EOL.
13199
13200 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13201
13202         * modules/gethrxtime (Depends-on): Add gettime.
13203
13204 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13205
13206         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
13207         or gettimeofday; no longer needed.
13208
13209 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13210
13211         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
13212         time business.
13213         (gethrxtime) [! (HAVE_NANOUPTIME
13214         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
13215         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
13216         our own approximation.
13217
13218 2005-11-08  Eric Blake  <ebb9@byu.net>
13219
13220         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
13221
13222 2005-11-08  Eric Blake  <ebb9@byu.net>
13223
13224         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
13225
13226 2005-11-04  Bruno Haible  <bruno@clisp.org>
13227
13228         * gnulib-tool: Implement --update mode.
13229
13230 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
13231
13232         Fix porting problem reported by Theodoros V. Kalamatianos.
13233         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
13234         Don't assume that futimes failing means we must fail.
13235
13236 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
13237
13238         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
13239         variables to suggest the intended function of the PATH_MAX check.
13240
13241 2005-10-30  Kean Johnston  <jkj@sco.com>
13242
13243         Trivial changes to support SCO systems.
13244         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
13245         as PATH_MAX.
13246         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
13247         where __ptr is null when no I/O is pending.
13248
13249 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
13250
13251         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
13252         leave errno alone.  Problem reported by Dmitry V. Levin.
13253
13254 2005-10-28  Simon Josefsson  <jas@extundo.com>
13255
13256         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
13257         Test more.
13258
13259         * tests/test-gc-md2.c, tests/test-md2.c: New files.
13260
13261         * modules/md2, modules/md2-tests: New files.
13262
13263 2005-10-28  Simon Josefsson  <jas@extundo.com>
13264
13265         * m4/inet_ntop.m4: More tests.
13266
13267         * m4/gc-md2.m4, md2.m4: New file.
13268
13269 2005-10-28  Simon Josefsson  <jas@extundo.com>
13270
13271         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
13272         "restrict" keywords, as per POSIX.  Protect the function
13273         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
13274         Don't use K&R prototypes.  Check the sprintf return values.
13275         Re-define EAFNOSUPPORT if not present.  Indent.
13276
13277         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
13278         suggested by Bruno Haible <bruno@clisp.org>.
13279
13280         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
13281
13282         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
13283
13284         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
13285         libgcrypt).
13286
13287         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
13288
13289         * lib/md2.h, lib/md2.c: New files.
13290
13291 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
13292
13293         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
13294         errno alone.  Problem reported by Frederic Jolliton.
13295
13296 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
13297
13298         * modules/verify (License): Change from GPL to LGPL.  This is a
13299         tiny module and there are apparently near-equivalents that are
13300         under the BSD license.
13301
13302 2005-10-24  Simon Josefsson  <jas@extundo.com>
13303
13304         * modules/sha1: Relicense to LGPL.
13305
13306 2005-10-24  Simon Josefsson  <jas@extundo.com>
13307
13308         * lib/md4.h: Shrink buffer size, now that we changed the type.
13309
13310 2005-10-23  Simon Josefsson  <jas@extundo.com>
13311
13312         * gnulib-tool (func_import): Fix --tests-base.
13313
13314 2005-10-22  Simon Josefsson  <jas@extundo.com>
13315
13316         * modules/arcfour (Depends-on): Need stdint.
13317
13318 2005-10-22  Simon Josefsson  <jas@extundo.com>
13319
13320         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
13321         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
13322
13323 2005-10-22  Simon Josefsson  <jas@extundo.com>
13324
13325         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
13326         suggested by Bruno Haible <bruno@clisp.org>.
13327
13328 2005-10-22  Simon Josefsson  <jas@extundo.com>
13329
13330         * lib/crc.h: Include stddef.h, for size_t.
13331
13332 2005-10-22  Simon Josefsson  <jas@extundo.com>
13333
13334         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
13335         arcfour_context struct (simplify test vector testing in GNU
13336         Shishi).
13337
13338 2005-10-21  Simon Josefsson  <jas@extundo.com>
13339
13340         * modules/des, modules/des-tests: New files.
13341
13342         * modules/gc-des, modules/gc-des-tests: New files.
13343
13344         * tests/test-des.c, tests/test-gc-des.c: New file.
13345
13346 2005-10-21  Simon Josefsson  <jas@extundo.com>
13347
13348         * modules/arctwo, modules/arctwo-tests: New files.
13349
13350         * tests/test-arctwo.c: New file.
13351
13352         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
13353
13354         * tests/test-gc-arctwo.c: New file.
13355
13356 2005-10-21  Simon Josefsson  <jas@extundo.com>
13357
13358         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
13359         Bruno Haible <bruno@clisp.org>.
13360
13361         * m4/gc-des.m4: New file.
13362
13363 2005-10-21  Simon Josefsson  <jas@extundo.com>
13364
13365         * m4/arctwo.m4: New file.
13366
13367         * m4/gc-arctwo.m4: New file.
13368
13369 2005-10-21  Simon Josefsson  <jas@extundo.com>
13370
13371         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
13372         block.
13373
13374 2005-10-21  Simon Josefsson  <jas@extundo.com>
13375
13376         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
13377         <bruno@clisp.org>.
13378
13379         * lib/hmac-sha1.c (hmac_sha1): Likewise.
13380
13381         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
13382         Bruno Haible <bruno@clisp.org>.
13383
13384         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
13385         <bruno@clisp.org>.
13386
13387 2005-10-21  Simon Josefsson  <jas@extundo.com>
13388
13389         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
13390
13391 2005-10-21  Simon Josefsson  <jas@extundo.com>
13392
13393         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
13394
13395 2005-10-21  Simon Josefsson  <jas@extundo.com>
13396
13397         * lib/des.h, lib/des.c: New files.
13398
13399         * lib/gc-gnulib.c: Support DES.c
13400
13401 2005-10-21  Simon Josefsson  <jas@extundo.com>
13402
13403         * lib/arctwo.h, lib/arctwo.c: New files.
13404
13405         * lib/gc-gnulib.c: Support ARCTWO.
13406
13407 2005-10-21  Simon Josefsson  <jas@extundo.com>
13408
13409         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
13410         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
13411
13412 2005-10-21  Simon Josefsson  <jas@extundo.com>
13413
13414         * gnulib-tool (func_import, func_create_testdir): Define automake
13415         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
13416         Makefile.am snippet),
13417         suggested by Bruno Haible <bruno@clisp.org>.
13418
13419         * modules/gc (Makefile.am): Use it.
13420
13421 2005-10-21  Bruno Haible  <bruno@clisp.org>
13422
13423         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
13424         patch.
13425
13426 2005-10-19  Simon Josefsson  <jas@extundo.com>
13427
13428         * tests/test-gc-rijndael.c: New file.
13429
13430         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
13431
13432 2005-10-19  Simon Josefsson  <jas@extundo.com>
13433
13434         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
13435         interface too.
13436
13437 2005-10-19  Simon Josefsson  <jas@extundo.com>
13438
13439         * tests/test-gc-arcfour.c: New file.
13440
13441         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
13442
13443 2005-10-19  Simon Josefsson  <jas@extundo.com>
13444
13445         * modules/gc-md4, modules/gc-md4-tests: New file.
13446
13447         * tests/test-gc-md4.c: New file.
13448
13449 2005-10-19  Simon Josefsson  <jas@extundo.com>
13450
13451         * m4/gc-md4.m4: New file.
13452
13453 2005-10-19  Simon Josefsson  <jas@extundo.com>
13454
13455         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
13456         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
13457         <kasal@ucw.cz>.
13458
13459 2005-10-19  Simon Josefsson  <jas@extundo.com>
13460
13461         * m4/gc-arcfour.m4: New file.
13462
13463         * m4/gc-rijndael.m4: New file.
13464
13465 2005-10-19  Simon Josefsson  <jas@extundo.com>
13466
13467         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
13468
13469 2005-10-19  Simon Josefsson  <jas@extundo.com>
13470
13471         * lib/gc-gnulib.c: Support ARCFOUR.
13472
13473 2005-10-19  Simon Josefsson  <jas@extundo.com>
13474
13475         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
13476         support.
13477
13478         * lib/gc.h: Add ECB enum type.
13479
13480         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
13481
13482 2005-10-18  Simon Josefsson  <jas@extundo.com>
13483
13484         * tests/test-md5.c: New file.
13485
13486         * modules/md5-tests: New file.
13487
13488 2005-10-18  Simon Josefsson  <jas@extundo.com>
13489
13490         * tests/test-md4.c: New file.
13491
13492         * modules/md4, modules/md4-tests: New files.
13493
13494 2005-10-18  Simon Josefsson  <jas@extundo.com>
13495
13496         * m4/md4.m4: New file.
13497
13498 2005-10-18  Simon Josefsson  <jas@extundo.com>
13499
13500         * lib/md4.h, lib/md4.c: New files, based on md5.?.
13501
13502 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
13503
13504         * gnulib-tool (func_create_testdir): Omit the second check whether
13505         BUILT_SOURCES in nonempty.
13506
13507 2005-10-17  Simon Josefsson  <jas@extundo.com>
13508
13509         * tests/test-rijndael.c: New file.
13510
13511 2005-10-17  Simon Josefsson  <jas@extundo.com>
13512
13513         * modules/sha1: Depend on stdint instead of md5.
13514
13515         * modules/md5: Depend on stdint, remove uint32_t.
13516
13517 2005-10-17  Simon Josefsson  <jas@extundo.com>
13518
13519         * modules/gc-sha1-tests: New file.
13520
13521         * tests/test-gc-sha1.c: New file.
13522
13523 2005-10-17  Simon Josefsson  <jas@extundo.com>
13524
13525         * m4/md5.m4: Remove call to uint32_t.m4.
13526
13527 2005-10-17  Simon Josefsson  <jas@extundo.com>
13528
13529         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
13530
13531         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
13532         md5.h.
13533
13534         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
13535
13536         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
13537
13538 2005-10-17  Simon Josefsson  <jas@extundo.com>
13539
13540         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
13541
13542 2005-10-17  Simon Josefsson  <jas@extundo.com>
13543
13544         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
13545
13546 2005-10-17  Simon Josefsson  <jas@extundo.com>
13547
13548         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
13549
13550         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
13551
13552 2005-10-17  Bruno Haible  <bruno@clisp.org>
13553
13554         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
13555         that it can also be used in a test.
13556
13557 2005-10-16  Bruno Haible  <bruno@clisp.org>
13558
13559         * gnulib-tool (func_emit_tests_Makefile_am): Also define
13560         TESTS_ENVIRONMENT, so that individual tests can augment it.
13561
13562         * gnulib-tool (func_create_testdir): Use an intermediate target for
13563         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
13564         macros, like $(ALLOCA_H), which cannot be passed through the command
13565         line.
13566
13567 2005-10-15  Simon Josefsson  <jas@extundo.com>
13568
13569         * modules/rijndael-tests: New file.
13570
13571         * modules/rijndael: New file.
13572
13573 2005-10-15  Simon Josefsson  <jas@extundo.com>
13574
13575         * m4/rijndael.m4: New file.
13576
13577 2005-10-15  Simon Josefsson  <jas@extundo.com>
13578
13579         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
13580
13581         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
13582
13583 2005-10-14  Simon Josefsson  <jas@extundo.com>
13584
13585         * tests/test-arcfour.c: New file.
13586
13587         * modules/arcfour, modules/arcfour-tests: New files.
13588
13589 2005-10-14  Simon Josefsson  <jas@extundo.com>
13590
13591         * m4/arcfour.m4: New file.
13592
13593 2005-10-14  Simon Josefsson  <jas@extundo.com>
13594
13595         * lib/arcfour.h, lib/arcfour.c: New files.
13596
13597 2005-10-14  Roland McGrath  <roland@redhat.com>
13598
13599         Import from libc.  [BZ #1331]
13600         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
13601         macro argument.
13602         Reported by Matej Vela <vela@debian.org>.
13603
13604 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
13605
13606         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
13607         include <wchar.h>; no longer needed.
13608
13609 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
13610
13611         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
13612
13613 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
13614         and  Ulrich Drepper  <drepper@redhat.com>
13615
13616         Import from libc.
13617         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
13618         instead of inline stream orientation test and two separate
13619         function calls.  Pay no attention to USE_IN_LIBIO.
13620
13621 2005-10-13  Simon Josefsson  <jas@extundo.com>
13622
13623         * modules/gc-hmac-md5-tests: New file.
13624
13625         * tests/test-gc-hmac-sha1.c: New file.
13626
13627         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
13628
13629         * modules/gc-hmac-md5-tests: New file.
13630
13631         * tests/test-gc-md5.c: New file.
13632
13633         * modules/gc-md5-tests: New file.
13634
13635 2005-10-13  Simon Josefsson  <jas@extundo.com>
13636
13637         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
13638         Move memory allocation outside of loop.
13639
13640 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
13641
13642         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
13643         intermediate directory is in a read-only file system.  Problem
13644         reported by Eric Blake.
13645
13646 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
13647
13648         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
13649
13650 2005-10-12  Simon Josefsson  <jas@extundo.com>
13651
13652         * tests/test-hmac-sha1.c: New file.
13653
13654         * modules/hmac-sha1-tests: New file.
13655
13656         * modules/hmac-sha1: New file.
13657
13658 2005-10-12  Simon Josefsson  <jas@extundo.com>
13659
13660         * modules/gc-sha1: New file.
13661
13662 2005-10-12  Simon Josefsson  <jas@extundo.com>
13663
13664         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
13665
13666         * tests/test-gc-pbkdf2-sha1.c: New file.
13667
13668 2005-10-12  Simon Josefsson  <jas@extundo.com>
13669
13670         * modules/gc-md5, modules/gc-hmac-md5: New files.
13671
13672         * modules/gc (Files): Remove md5, memxor and hmac files.
13673
13674 2005-10-12  Simon Josefsson  <jas@extundo.com>
13675
13676         * m4/gc-pbkdf2-sha1.m4: New file.
13677
13678         * m4/gc-hmac-sha1.m4: New file.
13679
13680         * m4/gc-sha1: New file.
13681
13682         * m4/hmac-sha1.m4: New file.
13683
13684 2005-10-12  Simon Josefsson  <jas@extundo.com>
13685
13686         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
13687
13688         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
13689
13690 2005-10-12  Simon Josefsson  <jas@extundo.com>
13691
13692         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
13693         suggested by Bruno Haible <bruno@clisp.org>.
13694
13695 2005-10-12  Simon Josefsson  <jas@extundo.com>
13696
13697         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
13698
13699 2005-10-12  Simon Josefsson  <jas@extundo.com>
13700
13701         * lib/gc-pbkdf2-sha1.c: New file.
13702
13703         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
13704
13705 2005-10-12  Simon Josefsson  <jas@extundo.com>
13706
13707         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
13708
13709         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
13710
13711 2005-10-12  Simon Josefsson  <jas@extundo.com>
13712
13713         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
13714         GC_USE_HMAC_MD5, respectively.
13715
13716         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
13717         (gc_md5): Fix typo.
13718
13719         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
13720
13721         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
13722
13723         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
13724
13725 2005-10-12  Bruno Haible  <bruno@clisp.org>
13726
13727         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
13728         Reported by Stepan Kasal <kasal@ucw.cz>.
13729
13730 2005-10-11  Simon Josefsson  <jas@extundo.com>
13731
13732         * tests/test-crc.c: New file.
13733
13734         * modules/crc, modules/crc-tests: New files.
13735
13736 2005-10-11  Simon Josefsson  <jas@extundo.com>
13737
13738         * m4/crc.m4: New file.
13739
13740 2005-10-11  Simon Josefsson  <jas@extundo.com>
13741
13742         * lib/gc.h: Add gc_hash and gc_hash_buffer.
13743
13744         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
13745
13746         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
13747
13748 2005-10-11  Simon Josefsson  <jas@extundo.com>
13749
13750         * lib/crc.h, lib/crc.c: New files.
13751
13752         * lib/gc.h (gc_hash_buffer): Add doc.
13753
13754 2005-10-11  Bruno Haible  <bruno@clisp.org>
13755
13756         * modules/c-strcasestr: New file.
13757         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
13758
13759 2005-10-11  Bruno Haible  <bruno@clisp.org>
13760
13761         * modules/c-strcase: New file.
13762         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
13763
13764 2005-10-11  Bruno Haible  <bruno@clisp.org>
13765
13766         * lib/strcasecmp.c: Include limits.h.
13767         (strcasecmp): Avoid integer overflow on exotic platforms.
13768         * lib/strncasecmp.c: Include limits.h.
13769         (strncasecmp): Avoid integer overflow on exotic platforms.
13770         Reported by Paul Eggert.
13771
13772 2005-10-11  Bruno Haible  <bruno@clisp.org>
13773
13774         * lib/c-strcasestr.h: New file, from GNU gettext.
13775         * lib/c-strcasestr.c: New file, from GNU gettext.
13776
13777 2005-10-11  Bruno Haible  <bruno@clisp.org>
13778
13779         * lib/c-strcase.h: New file, from GNU gettext.
13780         * lib/c-strcasecmp.c: New file, from GNU gettext.
13781         * lib/c-strncasecmp.c: New file, from GNU gettext.
13782
13783 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
13784
13785         * modules/mempcpy (License): GPL -> LGPL.
13786         * modules/strchrnul (License): Likewise.
13787         * modules/sysexits (License): Likewise.
13788
13789 2005-10-08  Simon Josefsson  <jas@extundo.com>
13790
13791         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
13792
13793 2005-10-07  Simon Josefsson  <jas@extundo.com>
13794
13795         * m4/memxor.m4: Remove gl_C_RESTRICT call.
13796
13797 2005-10-06  Simon Josefsson  <jas@extundo.com>
13798
13799         * tests/test-hmac-md5.c: New file.
13800
13801         * modules/hmac-md5-tests: New file.
13802
13803         * modules/hmac-md5: New file.
13804
13805 2005-10-06  Simon Josefsson  <jas@extundo.com>
13806
13807         * m4/hmac-md5.m4: New file.
13808
13809         * m4/memxor.m4: Require gl_C_RESTRICT.
13810
13811 2005-10-06  Simon Josefsson  <jas@extundo.com>
13812
13813         * lib/memxor.c (memxor): Avoid casts and warnings.
13814
13815 2005-10-06  Simon Josefsson  <jas@extundo.com>
13816
13817         * lib/hmac-md5.c: New file.
13818
13819         * lib/hmac.h: New file.
13820
13821 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
13822
13823         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
13824         promotes to int, not unsigned int, to catch the AIX 5.3
13825         compiler bug.
13826
13827 2005-10-05  Simon Josefsson  <jas@extundo.com>
13828
13829         * modules/memxor: New file.
13830
13831         * modules/iconv (Files): Move config.rpath to havelib, it is used
13832         there.
13833
13834         * modules/havelib (Files): Add config.rpath.
13835
13836 2005-10-05  Simon Josefsson  <jas@extundo.com>
13837
13838         * m4/memxor.m4: New file.
13839
13840 2005-10-05  Simon Josefsson  <jas@extundo.com>
13841
13842         * lib/memxor.c (memxor): Fix compiler error.
13843
13844         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
13845         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
13846
13847         * lib/memxor.h, lib/memxor.c: New files.
13848
13849         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
13850         we assume all systems have it, suggested by Jim Meyering
13851         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
13852         any systems lack sys/socket.h; mingw32 is known to lack it, but we
13853         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
13854         same reasons.
13855
13856 2005-10-05  Simon Josefsson  <jas@extundo.com>
13857
13858         * config/srclist.txt: Add glibc bug 1423 for md5.h.
13859
13860 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
13861
13862         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
13863         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
13864         needed, since the source code now assumes these .h files.
13865
13866 2005-10-05  Derek Price  <derek@ximbiot.com>
13867
13868         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
13869
13870 2005-10-05  Bruno Haible  <bruno@clisp.org>
13871
13872         * modules/stdint (License): Change to LGPL.
13873
13874 2005-10-04  Simon Josefsson  <jas@extundo.com>
13875
13876         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
13877         D. Baushke" <mdb@gnu.org>.
13878
13879 2005-10-04  Bruno Haible  <bruno@clisp.org>
13880
13881         * lib/verify.h (verify_true): Provide alternative definition for C++.
13882
13883 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
13884
13885         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
13886         (SSIZE_MAX): New macro, if not already defined.
13887         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
13888         than 2 GiB.
13889
13890 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13891
13892         Sync from coreutils.
13893         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
13894         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
13895         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
13896         ULLONG_MAX doesn't work with 2.7.2.1.
13897
13898 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13899
13900         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
13901         From Ben Pfaff.
13902
13903         * modules/exclude (Depends-on): Depend on verify.
13904         * modules/strtoimax (Depends-on): Likewise.
13905         * modules/utimecmp (Depends-on): Likewise.
13906
13907 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
13908
13909         * lib/exclude.c: Include verify.h.
13910         (verify): Remove.  All callers changed to use verify.h's version.
13911         * lib/strtoimax.c: Likewise.
13912         * lib/utimecmp.c: Likewis.e
13913
13914         Sync from coreutils.
13915         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
13916         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
13917         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
13918         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
13919         bother returning ENOSYS if settimeofday or stime fails; just let
13920         them return whatever errno they want to return.
13921         * lib/utimens.c: Include unistd.h, for dup2.
13922         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
13923         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
13924
13925 2005-10-02  Jim Meyering  <jim@meyering.net>
13926
13927         Sync from coreutils.
13928         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
13929         from glibc-2.2.5 that fails for read-only files.
13930
13931 2005-10-02  Jim Meyering  <jim@meyering.net>
13932
13933         Sync from coreutils.
13934         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
13935         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
13936         `#if HAVE_CONFIG_H'.
13937         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
13938         Remove AT_FDCWD test.
13939         Do not consume the fd unless successful.
13940         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
13941         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
13942         block, so that we don't even try to compile it if settimeofday is
13943         available.  This works around a compilation failure on OSF1 V5.1,
13944         due to stime requiring a `long int*' while tv_sec is `int'.
13945
13946 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
13947
13948         Sync from coreutils.
13949         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
13950         against `yes', rather than just testing for nonempty.
13951
13952 2005-10-01  Simon Josefsson  <jas@extundo.com>
13953
13954         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
13955         and Darwin.
13956
13957         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
13958         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
13959         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
13960         freeaddrinfo and gai_strerror are declared by the POSIX headers.
13961         Check if struct addrinfo is declared.
13962
13963 2005-10-01  Simon Josefsson  <jas@extundo.com>
13964
13965         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
13966         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
13967         AI_* and EAI_* definitions.  Protect function declarations.
13968
13969 2005-10-01  Jim Meyering  <jim@meyering.net>
13970
13971         Sync from coreutils.
13972
13973         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
13974         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
13975         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
13976         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
13977         in the inet and nsl libraries.  Required on Solaris 5.7.
13978
13979 2005-10-01  Jim Meyering  <jim@meyering.net>
13980
13981         Sync from coreutils.
13982         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
13983         in the inet and nsl libraries.  Required on Solaris 5.7.
13984
13985 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
13986
13987         * lib/getdelim.c (getdelim): Remove unused variables.
13988
13989 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
13990
13991         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
13992         so that the code works even with ancient cpp.  Portability problem
13993         with GCC 2.7.2.1 reported by Thomas M.Ott.
13994
13995 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
13996
13997         * modules/regex (Depends-on): Add strcase.
13998
13999         * modules/gethostname (Licence): Change from GPL to LGPL, since
14000         gethostname.c is a trivial implementation of a standard library
14001         function.
14002         * modules/poll (License): Change from GPL to LGPL, since it's
14003         derived from LGPL code.
14004
14005 2005-09-27  Jim Meyering  <jim@meyering.net>
14006
14007         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
14008         HAVE_CONFIG_H.
14009
14010         * lib/intprops.h (signed_type_or_expr__): Define.
14011         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
14012         for unsigned types.
14013
14014 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
14015
14016         * lib/verify.h (verify_expr): Remove, replacing with:
14017         (verify_true): New macro that returns true instead of void.
14018         (verify_type__): Remove.
14019         (verify): Use verify_true rather than verify_type__.
14020
14021 2005-09-26  Bruno Haible  <bruno@clisp.org>
14022
14023         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
14024         is necessary.
14025         (lib_SOURCES): Remove mbchar.c.
14026         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
14027         (Files): Add m4/mbrtowc.m4.
14028         * modules/mbiter: Likewise.
14029         * modules/mbuiter: Likewise.
14030
14031 2005-09-26  Bruno Haible  <bruno@clisp.org>
14032
14033         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
14034         compile mbchar.c if they are not both present.
14035         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
14036         * m4/mbiter.m4 (gl_MBITER): Likewise.
14037         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
14038         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
14039         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
14040
14041 2005-09-25  Jim Meyering  <jim@meyering.net>
14042
14043         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
14044         also uses socklen_t.
14045
14046 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
14047
14048         * lib/utimens.c (ENOSYS): Define if not already defined.
14049         (futimens): Support having a null PATH if the file descriptor
14050         is nonnegative.
14051
14052         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
14053         Remove.
14054         (__attribute): Define to empty unless GCC 3.1 or later.
14055         This works around a core dump on OpenBSD 3.4, which has GCC
14056         2.95.3, which dumps core when given __attribute__(()).  It also
14057         simplifies other tests, since we really don't want to bother with
14058         worrying about which ancient version of GCC supported what.
14059         Original problem reported by Yoann Vandoorselaere, with part of
14060         the fix suggested by Derek Price.
14061
14062 2005-09-24  Jim Meyering  <jim@meyering.net>
14063
14064         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
14065         so we can once again use a positive bitfield width of 1 -- now we
14066         don't have to explain why we were using a bitfield width of 2.
14067
14068 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
14069
14070         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
14071         and similarly for the other external symbols.  Problem reported
14072         by James Gallager.
14073
14074         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
14075         bug reported by Jim Meyering.
14076
14077         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
14078         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
14079         not needed, since socklen is a prerequisite module.
14080
14081 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
14082
14083         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
14084         Problem reported by Eric Blake.
14085         (getaddrinfo): Initialize se so that it's not garbage.
14086         Redo internal storage allocation so that it doesn't make unportable
14087         assumptions about alignment.
14088         Fix a memory leak.
14089
14090         * lib/utimens.c (futimens): Use futimesat if available.
14091         Prefer it to futimes since it doesn't have the futimes bug.
14092
14093         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
14094         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
14095         Instead, declare a function that returns a pointer to an array,
14096         and use verify_type__ to declare the size of the array.
14097         Problem and germ of a solution reported by Bruno Haible.
14098         (verify_type__): Use 2, not 1, for bitfield size, to avoid
14099         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
14100
14101 2005-09-23  Jim Meyering  <jim@meyering.net>
14102
14103         Sync from coreutils.
14104         Correct build failure (socklen_t not defined) on at least
14105         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
14106         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
14107
14108 2005-09-23  Jim Meyering  <jim@meyering.net>
14109
14110         * modules/getaddrinfo (Depends-on): Add socklen.
14111
14112 2005-09-23  Bruno Haible  <bruno@clisp.org>
14113
14114         * tests/test-verify.c: New file.
14115
14116 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14117
14118         Sync from coreutils.
14119
14120         * modules/argmatch (Depends-on): Add verify.
14121         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
14122         unistd-safer.
14123         * modules/save-cwd (Depends-on): Likewise.
14124
14125         * modules/openat (Files): Add lib/openat-die.c.
14126         (Depends-on): Remove error, exitfail.
14127         Add dirname.
14128
14129         * modules/verify: New file.
14130         * MODULES.html.sh (Diagnostics <assert.h>): New section,
14131         with "verify" module.
14132
14133 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14134
14135         Sync from coreutils.
14136
14137         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
14138         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
14139         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
14140         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
14141         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
14142         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
14143         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
14144         Don't bother checking for string.h, stdlib.h, unistd.h.
14145         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
14146         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
14147         module's job.
14148         * m4/jm-macros.m4 (gl_MACROS): Likewise.
14149         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
14150
14151         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
14152         (gl_GETDATE): Use it.
14153
14154         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
14155
14156 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14157
14158         Sync from coreutils.
14159
14160         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
14161         stat-time.h.
14162         * lib/argmatch.h: Include verify.h
14163         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
14164         (ARGMATCH_ASSERT): Remove; unused.
14165         * lib/canonicalize.c: Assume STDC_HEADERS.
14166         * lib/exclude.c: Include "strcase.h".
14167         * lib/regex_internal.h [!defined _LIBC]: Likewise.
14168         * lib/getusershell.c: Include stdio--.h rather than stdio.h
14169         and stdio-safer.h.
14170         (getusershell): Call fopen, not fopen_safer.
14171         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
14172         Do not include unistd-safer.h.
14173         (save_cwd): Don't call fd_safer; no longer needed
14174         now that we include fcntl--.h.
14175
14176         * lib/getdate.y (relative_time): New type.
14177         (RELATIVE_TIME_0): New constant.
14178         (parser_control): Use relative_time instead of doing it ourselves.
14179         (%union): Add new relative_time rel member.
14180         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
14181         Now typeless.
14182         (relunit, relunit_snumber): Now of type rel.
14183         (zone, rel, relunit, get_date): Adjust to above changes.
14184
14185         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
14186         Do not include unistd-safer.h.
14187         (getloadavg): Don't call fd_safer; no longer needed
14188         now that we include fcntl--.h.
14189
14190         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
14191         (make_dir_parents): Treat ENOSYS like EEXIST.
14192
14193         Improve quality of diagnostics on restore_cwd failure.
14194         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
14195         (make_dir_parents): Last arg is now int * (for errno), not bool *.
14196         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
14197         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
14198         each time through the loop.  Do not diagnose restore_cwd failure;
14199         that is the caller's job (and perhaps the caller does not care).
14200
14201         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
14202         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
14203         If the file already exists but is not a directory, don't bother
14204         to try to make its parents.
14205         Close potential file descriptor leak if we can't chdir("/") (!).
14206         Don't always return true if chdir($PWD) fails; return true only
14207         if the requested action was done successfully (except for the
14208         chdir($PWD)).
14209         Don't log final directory unless we actually made it.
14210         Refactor to avoid duplicate code to fix up permissions.
14211         Don't attempt to fix up parent permissions if chdir($PWD) fails.
14212
14213         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
14214         to make it a bit faster and (I hope) clearer.
14215         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
14216         Fix bug in formats like %2N.
14217
14218         * lib/verify.h: New file.
14219
14220 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14221
14222         Sync from coreutils.
14223         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
14224
14225 2005-09-22  Jim Meyering  <jim@meyering.net>
14226
14227         Sync from coreutils.
14228
14229         * m4/lstat.m4 (gl_FUNC_LSTAT):
14230         Use AC_LIBSOURCES to require lstat.c and lstat.h.
14231         Remove obsolete comment.
14232         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
14233         * m4/xstrtod.m4: Likewise.
14234
14235         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
14236
14237 2005-09-22  Jim Meyering  <jim@meyering.net>
14238
14239         Sync from coreutils.
14240
14241         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
14242
14243         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
14244         the .tm_year member, since otherwise gcc-4.0 would now warn about
14245         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
14246
14247         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
14248         order to avoid an unsuppressible warning from gcc on 64-bit systems.
14249
14250         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
14251         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
14252         when run in a time zone for which daylight savings time is in effect
14253         for the starting date.
14254
14255         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
14256         stop us from restricting permissions of just-created absolute-named
14257         directories.
14258         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
14259         to restore initial working directory.
14260         * lib/mkdir-p.c (make_dir_parents): New parameter:
14261         different_working_dir, to tell caller if/when we change the working
14262         directory and are unable to return to the initial one.
14263         * lib/mkdir-p.h (make_dir_parents): Update prototype.
14264         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
14265         `return false'.  This fixes a bug introduced on 2004-07-30.
14266
14267         * lib/openat.c (fdopendir): Be sure to close the supplied
14268         file descriptor before returning.  This makes our replacement
14269         implementation a little closer to Solaris's, where fdopendir
14270         ties the file descriptor to the returned DIR* pointer.
14271         * lib/openat.c (unlinkat): New function.
14272         * lib/openat.h (unlinkat): Add prototype.
14273         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
14274         (openat_restore_fail): Rename from openat_restore_die.
14275         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
14276
14277         Provide an alternative to exiting immediately upon save_cwd or
14278         restore_cwd failure.  Now, an application can arrange e.g.,
14279         to perform a longjump in that case.
14280         * lib/openat.c: Include dirname.h.
14281         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
14282         (rpl_openat, fdopendir, fstatat): Call openat_save_die
14283         and openat_restore_die rather than calling error directly.
14284         Don't include "error.h" or "exitfail.h"; they're no longer needed.
14285
14286         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
14287         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
14288         define.
14289
14290         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
14291         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
14292                             int utc, int nanoseconds);
14293         Background:
14294         date should not have to allocate a megabyte of virtual memory to
14295         handle a format argument like +%1048575T.  When implemented with
14296         strftime, it must allocate such a buffer, use strftime to fill it
14297         in, print it, then free it.
14298         With fprintftime, it simply prints everything and exits.
14299         With no need for memory allocation, that's one fewer way to fail.
14300         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
14301         optional field width, not before, so we accept %9:z, not %:9z.
14302         (my_strftime): Be sure to use L_('x') for literals.
14303
14304         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
14305         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
14306         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
14307         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
14308         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
14309         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
14310         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
14311         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
14312         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
14313         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
14314         * lib/xgethostname.c, lib/xreadlink.c:
14315         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
14316
14317         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
14318         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
14319         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
14320         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
14321         and don't include <sys/file.h>).
14322
14323 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
14324
14325         Sync from coreutils.
14326
14327         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
14328         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
14329         [!LDAV_DONE]: Avoid unused variable warning.
14330
14331 2005-09-21  Bruno Haible  <bruno@clisp.org>
14332
14333         * lib/unicodeio.h (unicode_to_mb): New declaration.
14334
14335 2005-09-20  Derek Price  <derek@ximbiot.com>
14336
14337         * lib/getaddrinfo.c: Don't include <netdb.h> included from
14338         getaddrinfo.h.
14339
14340 2005-09-20  Bruno Haible  <bruno@clisp.org>
14341
14342         * gnulib-tool: Remove trailing slashes from the values specified for
14343         --source-base, --m4-base, --tests-base, --aux-dir.
14344         Suggested by Simon Josefsson <jas@extundo.com>.
14345
14346 2005-09-20  Bruno Haible  <bruno@clisp.org>
14347
14348         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
14349         func_modules_to_filelist, func_import, func_create_testdir): Make all
14350         sorting results locale-independent, so that gnulib-cache.m4 doesn't
14351         change when gnulib-tool is invoked in a different locale.
14352
14353 2005-09-19  Simon Josefsson  <jas@extundo.com>
14354
14355         * m4/socklen.m4: Fix typo.
14356
14357 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14358
14359         Use a consistent style for including <config.h>.
14360         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
14361         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
14362         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
14363         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
14364         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
14365         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
14366         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
14367         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
14368         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
14369         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
14370         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
14371         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
14372         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
14373         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
14374         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
14375         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
14376         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
14377         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
14378         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
14379         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
14380         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
14381         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
14382         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
14383         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
14384         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
14385         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
14386         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
14387         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
14388         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
14389         lib/xstrtoumax.c, lib/yesno.c:
14390         Standardize inclusion of config.h.
14391         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
14392         lib/inttostr.h:  Removed inclusion of config.h from header files.
14393         * lib/inttostr.c:  Adjusted in-tree users.
14394         * lib/timespec.h: Remove superfluous warning to include config.h.
14395         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
14396         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
14397         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
14398         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
14399         config.h with HAVE_CONFIG_H.
14400
14401 2005-09-19  Jim Meyering  <jim@meyering.net>
14402
14403         * modules/pathmax (License): Change to LGPL.
14404
14405 2005-09-19  Derek Price  <derek@ximbiot.com>
14406
14407         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
14408
14409 2005-09-19  Bruno Haible  <bruno@clisp.org>
14410
14411         * gnulib-tool (import): Provide default for --tests-base.
14412
14413 2005-09-19  Bruno Haible  <bruno@clisp.org>
14414
14415         * doc/quote.texi: New file, extracted from gnulib.texi.
14416         * doc/ctime.texi: New file, extracted from gnulib.texi.
14417         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
14418         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
14419         * doc/gnulib.texi: Include them.
14420
14421 2005-09-18  Bruno Haible  <bruno@clisp.org>
14422
14423         Portability fix.
14424         * gnulib-tool (func_readlink): New function.
14425         (func_ln_if_changed): Use it.
14426
14427 2005-09-18  Bruno Haible  <bruno@clisp.org>
14428
14429         * gnulib-tool: Support --with-tests also with --import.
14430         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
14431         (func_import): Use variables $testsbase and $inctests. Emit a
14432         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
14433         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
14434         SUBDIRS += $testsdir.
14435         (func_create_testdir): Update.
14436
14437 2005-09-18  Bruno Haible  <bruno@clisp.org>
14438
14439         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
14440         instead of $dry_run.
14441         (func_cp_if_changed, func_mv_if_changed): Remove functions.
14442         (func_ln_if_changed): Don't handle dry-run here.
14443         (func_import): In dry-run mode, detect more precisely which actions
14444         would be performed, and don't use "...ing" verbs.
14445
14446 2005-09-18  Bruno Haible  <bruno@clisp.org>
14447
14448         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
14449         (func_import): Use join on two temporary files instead of three nested
14450         loops, in order to determine which files are new or old.
14451
14452 2005-09-18  Bruno Haible  <bruno@clisp.org>
14453
14454         * gnulib-tool (func_import): Comment out code that spits out the
14455         new files with --dry-run.
14456
14457 2005-09-18  Bruno Haible  <bruno@clisp.org>
14458
14459         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
14460
14461 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
14462
14463         * lib/stat-time.h: New file.
14464         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
14465         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
14466         in a different way.
14467         (timespec_cmp): New function.
14468         * lib/utimecmp.c: Include stat-time.h.
14469         (SYSCALL_RESOLUTION): Depend on whether various struct stat
14470         members exist, not on the obsolescent ST_MTIM_NSEC.
14471         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
14472
14473 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
14474
14475         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
14476
14477 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
14478
14479         * MODULES.html.sh (File system functions): Add stat-time.
14480         * modules/stat-time: New file.
14481         * modules/timespec (Files): Remove m4/st_mtim.m4; this
14482         is now done in a different way, by the stat-time module.
14483         * modules/utimecmp (Depends-on): Add stat-time.
14484
14485 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
14486
14487         * m4/st_mtim.m4: Remove.  Superseded by...
14488         * m4/stat-time.m4: New file.
14489         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
14490         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
14491
14492 2005-09-15  Derek Price  <derek@ximbiot.com>
14493
14494         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
14495
14496 2005-09-15  Derek Price  <derek@ximbiot.com>
14497
14498         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
14499         * lib/regex_internal.c: Ditto, using this...
14500         (__GNUC_PREREQ): ...new macro.
14501         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
14502         using...
14503         (__GNUC_PREREQ): ...this new macro.
14504
14505         * lib/strstr.h: Include string.h. Define strstr as a macro here.
14506
14507 2005-09-15  Derek Price  <derek@ximbiot.com>
14508             Paul Eggert  <eggert@cs.ucla.edu>
14509
14510         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
14511         changes, consolidating in...
14512         * lib/regex_internal.h: ...this file.
14513
14514 2005-09-13  Jim Meyering  <jim@meyering.net>
14515
14516         * lib/canon-host.c: Filter through gnu indent and reword comments
14517         slightly.
14518         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
14519
14520 2005-09-13  Derek Price  <derek@ximbiot.com>
14521
14522         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
14523         failure.
14524         Reported by Jim Meyering  <jim@meyering.net>.
14525
14526 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
14527
14528         * lib/base64.c: Typo.
14529         (base64_encode): Put b64str in initialized data section.
14530
14531 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
14532
14533         Merge glibc and coreutils changes into gnulib, plus a few
14534         extra fixes.
14535         * lib/md5.c: Use #error rather than a string.
14536         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
14537         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
14538         (__attribute__): Define to empty for non recent-GCC.
14539         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
14540         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
14541         Renamed from their non-__ counterparts, with new macros replacing
14542         them if not _LIBC.  Add __THROW attribute.
14543         (rol): Remove.
14544         (struct md5_ctx): Align buffer if using GCC.
14545         * lib/sha1.h (struct sha1_ctx): Likewise.
14546         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
14547         The old name was backwards.
14548         (NOTSWAP): Remove; not used.
14549         (rol): New macro, moved here from md5.h.
14550         (sha1_process_block): Remove a FIXME that doesn't make sense.
14551
14552 2005-09-12  Derek Price  <derek@ximbiot.com>
14553
14554         Return usable errors from canon-host.
14555         * lib/canon-host.h: New file.
14556         * lib/canon-host.c (canon_host): Wrap...
14557         (canon_host_r): ...this new function, which now relies exclusively on
14558         getaddrinfo.
14559         (ch_strerror): New function.
14560         (last_cherror): New global.
14561         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
14562         interface.
14563         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
14564         void *.
14565         (freeaddrinfo): Free ai->ai_canonname when set.
14566
14567 2005-09-12  Derek Price  <derek@ximbiot.com>
14568
14569         Make canon-host require getaddrinfo.
14570         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
14571         AC_LIBSOURCE canon-host.h.  Call...
14572         (gl_PREREQ_CANON_HOST): ...this new function, which requires
14573         gl_GETADDRINFO.
14574         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
14575
14576 2005-09-12  Derek Price  <derek@ximbiot.com>
14577
14578         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
14579         LGPL.
14580         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
14581
14582 2005-09-12  Derek Price  <derek@ximbiot.com>
14583
14584         * lib/gai_strerror.c: Include config.h when available.  Include
14585         getaddrinfo.h before other headers to test interface.
14586         Reported by Larry Jones <lawrence.jones@ugs.com>.
14587
14588 2005-09-12  Derek Price  <derek@ximbiot.com>
14589             Paul Eggert  <eggert@cs.ucla.edu>
14590
14591         * modules/glob (Files): Add glob-libc.h.
14592
14593 2005-09-12  Derek Price  <derek@ximbiot.com>
14594             Paul Eggert  <eggert@cs.ucla.edu>
14595
14596         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
14597         glob_.h, glob-libc.h.
14598         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
14599
14600 2005-09-12  Derek Price  <derek@ximbiot.com>
14601             Paul Eggert  <eggert@cs.ucla.edu>
14602
14603         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
14604         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
14605         protecting things that should be done only in gnulib contexts.
14606         * lib/glob_.h: New file, containing only the glob things needed for
14607         gnulib.
14608         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
14609         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
14610         (glob, globfree, glob_pattern_p): Now defined simply in terms of
14611         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
14612         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
14613         and to respect the namespace rules better.
14614
14615 2005-09-08  Simon Josefsson  <jas@extundo.com>
14616
14617         * modules/socklen: New file.
14618
14619 2005-09-08  Simon Josefsson  <jas@extundo.com>
14620
14621         * m4/socklen.m4: New file.
14622
14623 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14624
14625         * modules/utimens (Files): Add m4/utimbuf.m4, since
14626         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
14627         Reported by Sergey Poznyakoff.
14628
14629 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14630
14631         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
14632         definitions, since that's the preferred style in glibc.
14633         Fix a minor spacing issue, and update copyright notice to match
14634         glibc's.
14635
14636 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14637
14638         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
14639
14640 2005-09-06  Simon Josefsson  <jas@extundo.com>
14641
14642         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
14643         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
14644
14645 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14646
14647         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
14648         warning.
14649
14650 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14651
14652         * config/srclist.txt: Add glibc bug 1302.
14653
14654 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
14655
14656         Change bitset word type from unsigned int to unsigned long int,
14657         as this has better performance on typical 64-bit hosts.
14658         Port bitset code to hosts with unusual word sizes.
14659         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
14660         (build_collating_symbol):
14661         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
14662         argument is a bitset.  This is merely a style issue, but it makes
14663         it clearer that an entire array is expected.
14664         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
14665         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
14666         Port to the case where bitset_word is not the same as unsigned int.
14667         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
14668         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
14669         Likewise.
14670         * lib/regexec.c (check_dst_limits_calc_pos_1,
14671         check_subexp_matching_top):
14672         (build_trtable, group_nodes_into_DFAstates):
14673         Likewise.
14674         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
14675         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
14676         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
14677         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
14678         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
14679         * lib/regcomp.c (optimize_subexps, lower_subexp):
14680         Work even if bitset_word has holes in its bitwise representation.
14681         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
14682         * lib/regexec.c (check_dst_limits_calc_pos_1,
14683         check_subexp_matching_top):
14684         Likewise.
14685         * lib/regex_internal.c (re_string_reconstruct):
14686         Don't assume UCHAR_MAX == 255.
14687         * lib/regex_internal.h (bitset_set_all): Likewise.
14688         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
14689         All uses changed.
14690         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
14691         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
14692         All uses changed.
14693         (BITSET_WORD_MAX): New macro.
14694         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
14695         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
14696         (bitset_empty, bitset_copy):
14697         Prefer sizeof (bitset) to multiplying it out ourselves.
14698         (bitset_not_merge): Remove; unused.
14699         (bitset_contain): Return bool, not unsigned int with one bit on.
14700         All callers changed.
14701         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
14702         alignment than re_node_set; do this by defining a new internal
14703         type struct dests_alloc and using it to allocate memory.
14704
14705 2005-09-05  Bruno Haible  <bruno@clisp.org>
14706
14707         * gnulib-tool (func_import): Fix comparison in handling of symbolic
14708         links.
14709
14710 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
14711
14712         * modules/size_max (Makefile.am): Add size_max.h
14713
14714 2005-09-04  Derek Price  <derek@ximbiot.com>
14715
14716         * gnulib-tool (func_import): Fix reversed $symbolic logic.
14717
14718 2005-09-03  Simon Josefsson  <jas@extundo.com>
14719
14720         * gnulib-tool: Fix typo.
14721
14722 2005-09-03  Simon Josefsson  <jas@extundo.com>
14723
14724         * config/srclist.txt: Add glibc bug 1293.
14725
14726 2005-09-03  Derek Price  <derek@ximbiot.com>
14727
14728         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
14729         From Larry Jones <lawrence.jones@ugs.com>.
14730
14731 2005-09-02  Simon Josefsson  <jas@extundo.com>
14732
14733         * modules/socklen: New file.
14734
14735 2005-09-02  Simon Josefsson  <jas@extundo.com>
14736
14737         * modules/havelib: New module.
14738
14739         * modules/gettext, modules/iconv, modules/lock, modules/readline:
14740         Use havelib.
14741
14742 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14743
14744         Check for arithmetic overflow when calculating sizes, to prevent
14745         some buffer-overflow issues.  These patches are conservative, in the
14746         sense that when I couldn't determine whether an overflow was possible,
14747         I inserted a run-time check.
14748         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
14749         macros.
14750         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
14751         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
14752         (re_xnrealloc, re_x2nrealloc): New inline functions.
14753         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
14754         parse_bracket_exp):
14755         (build_equiv_class, build_charclass): Check for arithmetic overflow
14756         in size expression calculations.
14757         * lib/regex_internal.c (re_string_realloc_buffers):
14758         (build_wcs_upper_buffer, re_node_set_add_intersect):
14759         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
14760         (re_dfa_add_node, register_state): Likewise.
14761         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
14762         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
14763         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
14764         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
14765
14766 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14767
14768         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14769         m4/ulonglong.m4.  Problem reported by Martin Lambers.
14770
14771 2005-09-02  Bruno Haible  <bruno@clisp.org>
14772
14773         Support for lib vs. lib64 distinction on biarch platforms.
14774         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
14775         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
14776         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
14777
14778 2005-09-02  Bruno Haible  <bruno@clisp.org>
14779
14780         * gnulib-tool (import): In the other first-use case, provide defaults
14781         as well.
14782
14783 2005-09-02  Bruno Haible  <bruno@clisp.org>
14784
14785         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
14786         patches not yet found in the latest gettext release.
14787
14788 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
14789
14790         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
14791         to avoid a collision with bits/local_lim.h in glibc.
14792         All uses changed.  Problem reported by Dmitry V. Levin in
14793         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
14794
14795         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
14796         bugs in int versus size_t comparisons.
14797         (re_string_context_at): Fix bug where the code assumed that
14798         Idx is signed.
14799
14800         Use bool where appropriate.
14801         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
14802         All callers changed.
14803         (calc_eclosure_iter): Likewise, for ROOT arg.
14804         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
14805         (build_charclass_op): Likewise, for NON_MATCH arg.
14806         * lib/regex_internal.c (re_string_allocate, re_string_construct):
14807         (re_string_construct_common): Likewise, for ICASE arg.
14808         * lib/regexec.c (re_search_2_stub, re_search_stub):
14809         Likewise, for RET_LEN arg.
14810         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
14811         (set_regs): Likewise, for FL_BACKTRACK arg.
14812         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
14813         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
14814         (calc_eclosure_iter, parse_bracket_exp):
14815         Use bool for internal variables that are booleans.
14816         * lib/regexec.c (re_search_internal, check_matching,
14817         proceed_next_node):
14818         (set_regs, build_sifted_states, sift_states_bkref):
14819         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
14820         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
14821         (find_collation_sequence_value):
14822         Likewise.
14823         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
14824         (re_node_set_compare):
14825         Return bool, not int. All callers changed.
14826         * lib/regexec.c (check_halt_node_context, check_dst_limits):
14827         (build_trtable, check_node_accept): Likewise.
14828         * lib/regex_internal.h: Include stdbool.h.
14829
14830         Fix bugs uncovered when converting to bool.
14831         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
14832         failure instead of charging ahead blindly.
14833         * lib/regex_internal.c (register_state): Likewise.
14834         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
14835         for freeing internal storage.
14836         (group_nodes_into_DFA_states): Use unsigned int, not int, for
14837         bitset pieces used as boolean, to avoid undefined behavior
14838         on hosts that do int overflow checking.
14839
14840 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
14841
14842         * config/srclist.txt: Add glibc bugs 1285-1287.
14843
14844 2005-09-01  Jim Meyering  <jim@meyering.net>
14845
14846         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
14847         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
14848         Require gl_STAT_MACROS, too.
14849
14850 2005-09-01  Bruno Haible  <bruno@clisp.org>
14851
14852         * gnulib-tool (import): In the first-use case, provide defaults.
14853
14854 2005-09-01  Bruno Haible  <bruno@clisp.org>
14855
14856         * gnulib-tool (func_import): Remove the .tmp files.
14857
14858 2005-09-01  Bruno Haible  <bruno@clisp.org>
14859
14860         * gnulib-tool (func_import): Fix handling of symbolic links.
14861
14862 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14863
14864         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
14865         old glibc regex code mishandles strings longer than 2**31 bytes.
14866         This patch fixes this when the regex code is used in gnulib
14867         (i.e., outside glibc).
14868
14869         This patch should not affect the use of the regex code inside
14870         glibc.  No doubt this problem also needs to be handled for glibc
14871         as well, but the result will be an incompatible change to the
14872         glibc ABI, and the old ABI will have to be supported too.  That
14873         can be the the subject for another patch.
14874
14875         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
14876         governing whether the rest of this patch is active.  By default,
14877         the macro is disabled and the patch has no effect.
14878         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
14879         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
14880         (struct re_pattern_buffer, re_search, re_search_2, re_match):
14881         (re_match_2, re_set_registers): Use the new types.
14882         * lib/regex_internal.h (Idx, re_hashval_t): New types.
14883         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
14884         New macros.
14885         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
14886         (re_string_context_at, bin_tree_t, re_dfastate_t):
14887         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
14888         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
14889         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
14890         (re_string_char_size_at, re_string_wchar_at):
14891         (re_string_elem_size_at):
14892         Use the new types and macros to port to 64-bit hosts.
14893         Use unsigned types for internal values, so that the code
14894         mostly works even for arrays larger than SSIZE_MAX.
14895         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
14896         (search_duplicated_node, calc_eclosure_iter, fetch_number):
14897         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
14898         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
14899         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
14900         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
14901         (calc_inveclosure, parse_dup_op, build_range_exp):
14902         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
14903         (fetch_number, create_token_tree, mark_opt_subexp):
14904         Likewise.
14905         * lib/regex_internal.c (re_string_construct_common,
14906         create_ci_newstate):
14907         (create_cd_newstate, re_string_allocate, re_string_construct):
14908         (re_string_realloc_buffers, build_wcs_upper_buffer):
14909         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
14910         (re_string_reconstruct, re_string_peek_byte_case):
14911         (re_string_fetch_byte_case, re_string_context_at):
14912         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
14913         (re_node_set_init_copy, re_node_set_add_intersect):
14914         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
14915         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
14916         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
14917         (re_acquire_state, re_acquire_state_context, register_state):
14918         Likewise.
14919         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
14920         search_cur_bkref_entry):
14921         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
14922         (re_search_internal, re_search_2_stub, re_search_stub)
14923         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
14924         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
14925         (update_cur_sifted_state, check_dst_limits):
14926         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
14927         (check_subexp_limits, sift_states_bkref, merge_state_array):
14928         (check_subexp_matching_top, get_subexp, get_subexp_sub):
14929         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
14930         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
14931         (expand_bkref_cache, check_node_accept_bytes):
14932         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
14933         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
14934         (acquire_init_state_context, check_halt_node_context):
14935         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
14936         (sift_states_backward, clean_state_log_if_needed):
14937         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
14938         (find_recover_state, transit_state_sb, transit_state_mb):
14939         (transit_state_bkref, build_trtable, match_ctx_clean):
14940         Likewise.
14941         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
14942         to work around an assumption that REG_MISSING is negative.
14943
14944         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
14945         (seek_collating_symbol_entry) [defined _LIBC]:
14946         (lookup_collation_sequence_value) [defined _LIBC]:
14947         (build_range_exp, build_collating_symbol) [defined _LIBC]:
14948         Use prototypes rather than old-style function definitions.
14949         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
14950         (transit_state_sb) [0]:
14951         (find_collation_sequence_value) [defined _LIBC]: Likewise.
14952
14953         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
14954         rm_eo.
14955
14956         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
14957         (optimize_subexps, lower_subexp):
14958         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
14959         since the signed shift might overflow.  Use 1u<<31 instead.
14960         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
14961         Likewise.
14962         * lib/regexec.c (check_dst_limits_calc_pos_1,
14963         check_subexp_matching_top): Likewise.
14964
14965         * lib/regcomp.c (optimize_subexps, lower_subexp):
14966         Use CHAR_BIT rather than 8, for clarity.
14967         * lib/regexec.c (check_dst_limits_calc_pos_1):
14968         (check_subexp_matching_top): Likewise.
14969         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
14970         have to worry about portability issues when shifting it left.
14971         Remove no-longer-needed test for table_size > 0.
14972         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
14973         in a word, as the resulting behavior is undefined.
14974         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
14975         in one case, a <= should have been an <, and in another case the
14976         whole test was missing.
14977         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
14978         the standard name CHAR_BIT.
14979         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
14980         this is not true on one's complement and signed-magnitude hosts.
14981
14982         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
14983         next_last_offset.
14984         (struct re_dfa_t): Remove unused member states_alloc.
14985         * lib/regcomp.c (init_dfa): Don't initialize unused members.
14986
14987 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14988
14989         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
14990         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
14991         and large-file glibc and in 32-bit large-file Solaris.
14992
14993 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
14994
14995         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
14996         lengths fit in regoff_t; this isn't true if regoff_t is the same
14997         width as size_t.
14998         * lib/regex.c (re_search_internal): 5th arg is LAST_START
14999         (= START + RANGE) instead of RANGE.  This avoids overflow
15000         problems when regoff_t is the same width as size_t.
15001         All callers changed.
15002         (re_search_2_stub): Check for overflow when adding the
15003         sizes of the two strings.
15004         (re_search_stub): Check for overflow when adding START
15005         to RANGE; if it occurs, substitute the extreme value.
15006
15007 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15008
15009         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
15010
15011 2005-08-31  Jim Meyering  <jim@meyering.net>
15012
15013         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
15014         a pointer-to-const.
15015         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
15016         (register_state): Likewise.
15017         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
15018         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
15019         (group_nodes_into_DFAstates): Likewise.
15020
15021 2005-08-31  Jim Meyering  <jim@meyering.net>
15022
15023         * check-module: Add a FIXME comment.
15024
15025 2005-08-31  Eric Blake  <ebb9@byu.net>
15026
15027         * modules/unistd-safer (Files): Add unistd--.h.
15028         * modules/stdio-safer (Files): Add stdio--.h.
15029
15030 2005-08-31  Derek Price  <derek@ximbiot.com>
15031
15032         * lib/getdelim.c (getdelim): Return EOF on EOF.
15033         Reported by Larry Jones <lawrence.jones@ugs.com>.
15034
15035 2005-08-31  Bruno Haible  <bruno@clisp.org>
15036
15037         Avoid unnecessary diffs in the generated lib/Makefile.am.
15038         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
15039         the generated files.
15040         (func_import): Don't set cmd.
15041
15042 2005-08-31  Bruno Haible  <bruno@clisp.org>
15043
15044         * lib/strstr.c: Include <stddef.h>, for NULL.
15045         * lib/strcasestr.c: Likewise.
15046         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
15047
15048 2005-08-31  Bruno Haible  <bruno@clisp.org>
15049
15050         * gnulib-tool: New option --macro-prefix.
15051         (func_import): Use macro_prefix.
15052         (import): Handle option --macro-prefix.
15053
15054 2005-08-31  Bruno Haible  <bruno@clisp.org>
15055
15056         * gnulib-tool (import): Rename most ac_* variables to cached_*.
15057         Also use new variables cached_lgpl, cached_libtool.
15058
15059 2005-08-31  Bruno Haible  <bruno@clisp.org>
15060
15061         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
15062         always instantiating them.
15063
15064 2005-08-31  Bruno Haible  <bruno@clisp.org>
15065
15066         * gnulib-tool (func_import): Read the previous cached settings
15067         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
15068         earlier added by gnulib but are now dropped. Warn when a gnulib file
15069         overwrites a non-gnulib file.
15070
15071 2005-08-31  Bruno Haible  <bruno@clisp.org>
15072
15073         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
15074         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
15075         projects that don't keep autogenerated files in CVS. Put into
15076         actioncmd only the specified modules, not the transitive closure.
15077
15078 2005-08-31  Bruno Haible  <bruno@clisp.org>
15079
15080         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
15081         Create directories that shall be filled.
15082         (import): Don't look for gl_* macros in configure.ac. Recurse across
15083         all directories containing a gnulib-cache.m4 files, if meaningful.
15084
15085 2005-08-31  Bruno Haible  <bruno@clisp.org>
15086
15087         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
15088         (import): Set seen_libtool when we see gl_LIBTOOL.
15089
15090 2005-08-31  Bruno Haible  <bruno@clisp.org>
15091
15092         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
15093         declaration macro definitions from generated gnulib.m4.
15094
15095 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
15096
15097         * lib/iconvme.h: Add prototype for iconv_alloc.
15098
15099 2005-08-29  Simon Josefsson  <jas@extundo.com>
15100
15101         * lib/iconvme.c: Fix errno.
15102
15103 2005-08-29  Bruno Haible  <bruno@clisp.org>
15104
15105         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
15106         that it works when the directory contains spaces.
15107
15108 2005-08-29  Bruno Haible  <bruno@clisp.org>
15109
15110         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
15111
15112 2005-08-29  Bruno Haible  <bruno@clisp.org>
15113
15114         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
15115         Emit more advice.
15116
15117 2005-08-29  Bruno Haible  <bruno@clisp.org>
15118         and Stepan Kasal  <kasal@ucw.cz>
15119
15120         * check-module: If more parameters are given, check each of them
15121         separately; add more exceptions, as noted by Jim Meyering.
15122         (check_module): New procedure.
15123         (%exempt_header): Now contains all exceptions.
15124
15125 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
15126
15127         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
15128
15129 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
15130
15131         * lib/iconvme.c: Split iconv_string into iconv_alloc.
15132
15133 2005-08-28  Bruno Haible  <bruno@clisp.org>
15134
15135         * m4/gnulib-tool.m4: New file.
15136
15137 2005-08-27  Jim Meyering  <jim@meyering.net>
15138
15139         * modules/unistd-safer (Files): Add pipe-safer.c.
15140         * modules/fcntl-safer (Files): Add creat-safer.c.
15141
15142 2005-08-27  Jim Meyering  <jim@meyering.net>
15143
15144         * m4/stdlib-safer.m4: New file.  From coreutils.
15145         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
15146         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
15147         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
15148         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
15149         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
15150
15151 2005-08-27  Jim Meyering  <jim@meyering.net>
15152
15153         * lib/fopen-safer.c: Merge minor changes from coreutils.
15154         * lib/dup-safer.c: Likewise.
15155         * lib/fd-safer.c: Likewise.
15156
15157         Merge from coreutils.
15158         * lib/stdio--.h: New file.
15159         * lib/stdlib--.h: New file.
15160         * lib/mkstemp-safer.c: New file.
15161
15162         GNU tar needs these.
15163         * lib/pipe-safer.c: New file.
15164         * lib/creat-safer.c: New file.
15165         * lib/fcntl--.h (creat): Define to creat_safer.
15166         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
15167         * lib/unistd--.h (pipe): Define to pipe_safer.
15168         * lib/unistd-safer.h: Declare pipe_safer.
15169
15170 2005-08-26  Simon Josefsson  <jas@extundo.com>
15171
15172         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
15173         Haible <bruno@clisp.org>.
15174
15175 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
15176
15177         * lib/regex_internal.h: Remove all references to
15178         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
15179         or better.
15180         (bitset_not, bitset_merge, bitset_not_merge):
15181         (bitset_mask, re_string_allocate, re_string_construct):
15182         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
15183         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
15184         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
15185         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
15186         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15187         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15188         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
15189         (re_acquire_state_context):
15190         Remove unnecessary forward decls.
15191         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
15192         Put __attribute at function definition,
15193         now that the function decl has been removed.
15194         * lib/regex_internal.c (re_string_peek_byte_case):
15195         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
15196         Likewise.
15197
15198 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
15199
15200         * m4/regex.m4: Add AC_PREREQ(2.50).
15201         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
15202
15203 2005-08-25  Simon Josefsson  <jas@extundo.com>
15204
15205         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
15206         __fsetlocking.
15207
15208 2005-08-25  Simon Josefsson  <jas@extundo.com>
15209
15210         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
15211         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
15212         GLIBC specific code.
15213
15214 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15215
15216         Make regex safe for g++.  This fixes one real bug (an "err"
15217         that should have been "*err").  g++ problem reported by
15218         Sam Steingold.
15219         * lib/regex_internal.h (re_calloc): New macro, consistent with
15220         re_malloc etc.  All callers of calloc changed to use re_calloc.
15221         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
15222         not int.  All callers changed.
15223         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
15224         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
15225         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
15226         (find_recover_state): Change "err" to "*err"; this fixes what
15227         appears to be a real bug.
15228         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
15229         versus int.
15230
15231 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15232
15233         * modules/regex (Depends-on): Add malloc, since the code
15234         assumes that !malloc(0) means failure.
15235
15236 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15237
15238         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
15239
15240         alloca modernization/simplification for regex.
15241         * lib/regex.c: Remove portability cruft for alloca.  This no longer
15242         needs to be at the start of the file, and can be moved into
15243         regex_internal.h and simplified.
15244         * lib/regex_internal.h: Include <alloca.h>.
15245         (__libc_use_alloca) [!defined _LIBC]: New macro.
15246         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
15247         now works outside glibc.
15248
15249 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15250
15251         * config/srclist.txt: Add glibc bugs 1241, 1245.
15252
15253 2005-08-25  Jim Meyering  <jim@meyering.net>
15254
15255         * lib/open-safer.c: Include <config.h>.
15256         Otherwise, we'd lose LARGEFILE support in any file using
15257         e.g. "fcntl--.h"
15258
15259 2005-08-25  Bruno Haible  <bruno@clisp.org>
15260
15261         * m4/minmax.m4: Require autoconf 2.52.
15262         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
15263         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
15264         alternatives of translit over the alphabet.
15265         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
15266
15267 2005-08-24  Simon Josefsson  <jas@extundo.com>
15268
15269         * tests/test-getpass.c: New file.
15270
15271 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
15272
15273         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
15274         for GNU regex features.
15275
15276 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
15277
15278         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
15279         * lib/regex.h (regerror): Likewise.
15280
15281         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
15282         requires this.  (The code never needed it.)
15283
15284         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
15285         All uses of recently-renamed identifiers changed to use the new,
15286         POSIX-compliant names.  The code will build and run just fine
15287         without these changes, but it's better to eat our own dog food
15288         and use the standard-conforming names.
15289
15290         * lib/regex.h: Fix a multitude of POSIX name space violations.
15291         These changes have an effect only for programs that define
15292         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
15293         do not change anything for programs compiled in the normal way.
15294         Also, there is no effect on the ABI.
15295
15296         (_REGEX_SOURCE): New macro.
15297         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
15298         defined and _GNU_SOURCE is not; this fixes a name space violation.
15299
15300         Rename the following macros to obey POSIX requirements.
15301         The old names are still visible as macros if _REGEX_SOURCE is defined.
15302         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
15303         RE_BACKSLASH_ESCAPE_IN_LISTS.
15304         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
15305         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
15306         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
15307         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
15308         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
15309         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
15310         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
15311         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
15312         (REG_INTERVALS): renamed from RE_INTERVALS.
15313         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
15314         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
15315         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
15316         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
15317         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
15318         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
15319         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
15320         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
15321         RE_UNMATCHED_RIGHT_PAREN_ORD.
15322         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
15323         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
15324         (REG_DEBUG): renamed from RE_DEBUG.
15325         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
15326         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
15327         unusual, since we can't clash with the POSIX REG_ICASE.
15328         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
15329         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
15330         (REG_NO_SUB): renamed from RE_NO_SUB.
15331         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
15332         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
15333         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
15334         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
15335         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
15336         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
15337         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
15338         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
15339         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
15340         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
15341         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
15342         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
15343         RE_SYNTAX_POSIX_MINIMAL_BASIC.
15344         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
15345         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
15346         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
15347         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
15348         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
15349         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
15350         (REG_FIXED): Renamed from REGS_FIXED.
15351         (REG_NREGS): Renamed from RE_NREGS.
15352
15353         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
15354         of other REG_* macros, since POSIX says the user is allowed to
15355         #undef these macros selectively.
15356
15357         (reg_errcode_t): Update comment stating what other tables need
15358         to be consistent.
15359
15360         Rename the following enum values to obey POSIX requirements.
15361         The old names are still visible as macros.
15362         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
15363         is not defined, since GNU is supposed to be a superset of POSIX as
15364         much as possible, and since we want reg_errcode_t to be a signed
15365         type for implementation consistency.
15366         (_REG_NOERROR): Renamed from REG_NOERROR.
15367         (_REG_NOMATCH): Renamed from REG_NOMATCH.
15368         (_REG_BADPAT): Renamed from REG_BADPAT.
15369         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
15370         (_REG_ECTYPE): Renamed from REG_ECTYPE.
15371         (_REG_EESCAPE): Renamed from REG_EESCAPE.
15372         (_REG_ESUBREG): Renamed from REG_ESUBREG.
15373         (_REG_EBRACK): Renamed from REG_EBRACK.
15374         (_REG_EPAREN): Renamed from REG_EPAREN.
15375         (_REG_EBRACE): Renamed from REG_EBRACE.
15376         (_REG_BADBR): Renamed from REG_BADBR.
15377         (_REG_ERANGE): Renamed from REG_ERANGE.
15378         (_REG_ESPACE): Renamed from REG_ESPACE.
15379         (_REG_BADRPT): Renamed from REG_BADRPT.
15380         (_REG_EEND): Renamed from REG_EEND.
15381         (_REG_ESIZE): Renamed from REG_ESIZE.
15382         (_REG_ERPAREN): Renamed from REG_ERPAREN.
15383         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
15384         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
15385         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
15386         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
15387
15388         (_REG_RE_NAME, _REG_RM_NAME): New macros.
15389         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
15390         changed.  But support the old name if the new one is not defined
15391         and if _REGEX_SOURCE.
15392
15393         Change the following member names in struct re_pattern_buffer.
15394         The old names are still supported if !_REGEX_SOURCE.
15395         The new names are always supported, regardless of _REGEX_SOURCE.
15396         (re_buffer): Renamed from buffer.
15397         (re_allocated): Renamed from allocated.
15398         (re_used): Renamed from used.
15399         (re_syntax): Renamed from syntax.
15400         (re_fastmap): Renamed from fastmap.
15401         (re_translate): Renamed from translate.
15402         (re_can_be_null): Renamed from can_be_null.
15403         (re_regs_allocated): Renamed from regs_allocated.
15404         (re_fastmap_accurate): Renamed from fastmap_accurate.
15405         (re_no_sub): Renamed from no_sub.
15406         (re_not_bol): Renamed from not_bol.
15407         (re_not_eol): Renamed from not_eol.
15408         (re_newline_anchor): Renamed from newline_anchor.
15409
15410         Change the following member names in struct re_registers.
15411         The old names are still supported if !_REGEX_SOURCE.
15412         The new names are always supported, regardless of _REGEX_SOURCE.
15413         (rm_num_regs): Renamed from num_regs.
15414         (rm_start): Renamed from start.
15415         (rm_end): Renamed from end.
15416
15417         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
15418         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
15419         Prepend __ to parameter names.
15420
15421         Undo yesterday's changes.
15422
15423 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
15424
15425         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
15426         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
15427         lib/regex.c.
15428
15429 2005-08-24  Jim Meyering  <jim@meyering.net>
15430
15431         Sync from coreutils.
15432         * m4/fcntl-safer.m4: New file.
15433
15434         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
15435         and object files for this module.
15436
15437 2005-08-24  Jim Meyering  <jim@meyering.net>
15438
15439         Sync from coreutils.
15440         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
15441
15442 2005-08-24  Jim Meyering  <jim@meyering.net>
15443
15444         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
15445         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
15446
15447 2005-08-24  Jim Meyering  <jim@meyering.net>
15448
15449         * modules/fcntl-safer: New module.
15450         * modules/fts (Depends-on): Add fcntl-safer.
15451         * MODULES.html.sh (File descriptor based Input/Output):
15452         Add fcntl-safer.
15453
15454 2005-08-24  Bruno Haible  <bruno@clisp.org>
15455
15456         Support for unit test modules.
15457         * modules/README: Mention tests modules.
15458         * modules/TEMPLATE-TESTS: New file.
15459         * gnulib-tool: New options --extract-tests-module, --with-tests and
15460         --tests-base (unused for the moment).
15461         (testsbase, inctests): New variables.
15462         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
15463         (func_verify_module): Exclude TEMPLATE-TESTS.
15464         (func_verify_nontests_module, func_verify_tests_module): New functions.
15465         (func_get_dependencies): Add implicit dependency for tests modules.
15466         (func_get_tests_module): New function.
15467         (func_modules_transitive_closure): When --with-tests was specified,
15468         include the unit tests as well, unless explicitly avoided.
15469         (func_emit_lib_Makefile_am): Ignore the tests modules here.
15470         (func_emit_tests_Makefile_am): New function.
15471         (func_create_testdir): When --with-tests was specified, emit a
15472         tests/ directory.
15473         * MODULES.html.sh (Future developments): Update.
15474
15475 2005-08-24  Bruno Haible  <bruno@clisp.org>
15476
15477         * modules/tls-tests: New file.
15478         * tests/test-tls.c: New file, from GNU gettext.
15479
15480 2005-08-24  Bruno Haible  <bruno@clisp.org>
15481
15482         * modules/lock-tests: New file.
15483         * tests/test-lock.c: New file, from GNU gettext.
15484
15485 2005-08-24  Bruno Haible  <bruno@clisp.org>
15486
15487         * lib/lock.h: Add multiple inclusion guard.
15488         * lib/tls.h: Add multiple inclusion guard.
15489
15490 2005-08-24  Bruno Haible  <bruno@clisp.org>
15491
15492         * gnulib-tool: Add support for the --aux-dir option to
15493         --create-testdir, --create-megatestdir, --test, --megatest.
15494         (func_create_testdir, func_create_megatestdir): Optionally emit a
15495         AC_CONFIG_AUX_DIR directive.
15496         (create-testdir, create-megatestdir, test, megatest): Provide a
15497         default value for $auxdir.
15498
15499 2005-08-24  Bruno Haible  <bruno@clisp.org>
15500
15501         * gnulib-tool (import): Use compound statement instead of subshell
15502         where possible.
15503
15504 2005-08-24  Bruno Haible  <bruno@clisp.org>
15505
15506         * gnulib-tool (import): Change --aux-dir default to "build-aux".
15507
15508 2005-08-24  Bruno Haible  <bruno@clisp.org>
15509
15510         * gnulib-tool (func_version): Update.
15511
15512 2005-08-24  Bruno Haible  <bruno@clisp.org>
15513
15514         * gnulib-tool (func_import, func_create_testdir,
15515         func_create_megatestdir): Quote all autoconf macro arguments.
15516
15517 2005-08-24  Bruno Haible  <bruno@clisp.org>
15518
15519         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
15520         option --force, because --force causes the aclocal.m4 of each
15521         subdirectory to be newer than the corresponding config.h.in.
15522
15523 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
15524
15525         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
15526         All contents moved to gl_REGEX.
15527         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
15528         assume that it does.
15529
15530 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
15531
15532         * lib/regex.h (REG_NOSYS)
15533         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
15534         Define, since POSIX requires it as of 2001.
15535         (_REG_ENOSYS)
15536         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
15537         New private symbol, used to keep the enum signed in all cases.
15538         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
15539         Youngman in
15540         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
15541
15542         * lib/regex_internal.c (re_string_skip_chars, register_state):
15543         (calc_state_hash):
15544         Remove forward decls; no longer needed now that we use prototypes.
15545         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
15546         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
15547         (clean_state_log_if_needed): Likewise.
15548
15549 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
15550
15551         * config/srclist.txt: Add glibc bugs 1231-1233.
15552
15553 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15554
15555         Fix problems reported by Sam Steingold in
15556         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
15557         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
15558         assumed that reg_errcode_t is a signed type, which is not
15559         necessarily true if _XOPEN_SOURCE is not defined.
15560         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
15561         since some compilers warn about it otherwise.
15562
15563 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15564
15565         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
15566         (init_word_char, create_initial_state, duplicate_node_closure):
15567         (fetch_token, peek_token_bracket, build_range_exp):
15568         (build_collating_symbol): Remove forward decls; no longer needed
15569         now that we use prototypes.
15570
15571         * lib/regcomp.c:
15572         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
15573         (re_compile_fastmap_iter, regcomp, regerror, regfree):
15574         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
15575         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
15576         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
15577         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
15578         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
15579         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
15580         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
15581         (build_range_exp, build_collating_symbol, parse_bracket_exp):
15582         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
15583         (build_charclass, build_charclass_op, fetch_number, create_tree):
15584         (create_token_tree, mark_opt_subexp, duplicate_tree):
15585         Use prototypes rather than old-style definitions.
15586
15587         * lib/regex_internal.c:
15588         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
15589         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
15590         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
15591         (re_string_reconstruct, re_string_peek_byte_case):
15592         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
15593         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
15594         (re_node_set_init_copy, re_node_set_add_intersect):
15595         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15596         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15597         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
15598         (re_acquire_state, re_acquire_state_context, register_state):
15599         (create_ci_newstate, create_cd_newstate, free_state):
15600         Likewise.
15601         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
15602         re_search_2):
15603         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
15604         (re_search_internal, prune_impossible_nodes):
15605         (acquire_init_state_context, check_matching, static):
15606         (check_halt_node_context, check_halt_state_context, proceed_next_node):
15607         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
15608         (update_regs, sift_states_backward, build_sifted_states):
15609         (clean_state_log_if_needed, merge_state_array):
15610         (update_cur_sifted_state, add_epsilon_src_nodes):
15611         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
15612         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
15613         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
15614         (find_recover_state, check_subexp_matching_top, transit_state_mb):
15615         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
15616         (check_arrival, check_arrival_add_next_nodes):
15617         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
15618         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
15619         (check_node_accept_bytes, check_node_accept, extend_buffers):
15620         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
15621         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
15622         (sift_ctx_init):
15623         Likewise.
15624
15625         * lib/regex_internal.h:
15626         (re_string_allocate, re_string_construct, re_string_reconstruct):
15627         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
15628         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
15629         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
15630         (re_string_context_at, re_string_peek_byte_case):
15631         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
15632         is defined, since we now use prototypes always.
15633
15634         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
15635         C89 or better.  All uses removed.
15636
15637 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15638
15639         * config/srclist.txt: Add glibc bugs 1220-1227.
15640
15641 2005-08-20  Jim Meyering  <jim@meyering.net>
15642
15643         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
15644         of unused local, dfa.
15645
15646 2005-08-20  Bruno Haible  <bruno@clisp.org>
15647
15648         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
15649
15650 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15651
15652         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
15653         (re_node_set_insert_last, re_dfa_add_node):
15654         Rename local variables to avoid GCC shadowing warnings.
15655
15656 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15657
15658         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
15659         [defined lint]: Suppress bogus uninitialized-variable warnings.
15660
15661         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
15662         and let the caller return REG_ESPACE if out of space.  This
15663         removes an uninitialied-variable warning with GCC 4.0.1, and also
15664         avoids taking the address of a local variable.  All callers
15665         changed.
15666
15667 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15668
15669         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
15670         $LIBCSRC/posix/regexec.c.
15671         Add glibc bug 1217 for regcomp.c.
15672
15673 2005-08-19  Jim Meyering  <jim@meyering.net>
15674
15675         * lib/regexec.c (proceed_next_node): Redo local variables to
15676         avoid GCC shadowing warnings.
15677
15678 2005-08-18  Bruno Haible  <bruno@clisp.org>
15679
15680         * lib/strstr.c (strstr): Fix return value in multibyte case.
15681         * lib/strcasestr.c (strcasestr): Likewise.
15682
15683 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
15684
15685         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
15686
15687 2005-08-17  Jim Meyering  <jim@meyering.net>
15688
15689         Make the %s format (seconds since the epoch) work for a negative
15690         number and when used with a zero-padded field width, e.g. %015s.
15691
15692         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
15693         label so that it precedes the code to set `digits'.  Otherwise,
15694         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
15695         print `00-22'.  Now, it prints `-0022', as it should.
15696
15697 2005-08-17  Bruno Haible  <bruno@clisp.org>
15698
15699         * modules/strstr (Files): Add m4/mbrtowc.m4.
15700         (Depends-on): Add mbuiter.
15701
15702 2005-08-17  Bruno Haible  <bruno@clisp.org>
15703
15704         * modules/strcasestr: New file.
15705         * MODULES.html.sh (String handling, based on ANSI C 89): Add
15706         strcasestr.
15707
15708 2005-08-17  Bruno Haible  <bruno@clisp.org>
15709
15710         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
15711
15712 2005-08-17  Bruno Haible  <bruno@clisp.org>
15713
15714         * modules/mbuiter: New file.
15715         * MODULES.html.sh (Extended multibyte and wide character utilities):
15716         Add mbuiter.
15717
15718 2005-08-17  Bruno Haible  <bruno@clisp.org>
15719
15720         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
15721         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
15722
15723 2005-08-17  Bruno Haible  <bruno@clisp.org>
15724
15725         * m4/strcasestr.m4: New file.
15726
15727 2005-08-17  Bruno Haible  <bruno@clisp.org>
15728
15729         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
15730         * lib/strstr.c: Completely rewritten, with multibyte locale support.
15731
15732 2005-08-17  Bruno Haible  <bruno@clisp.org>
15733
15734         * lib/strcasestr.h: New file.
15735         * lib/strcasestr.c: New file.
15736
15737 2005-08-17  Bruno Haible  <bruno@clisp.org>
15738
15739         * lib/strcasecmp.c: Use mbuiter.h.
15740
15741 2005-08-17  Bruno Haible  <bruno@clisp.org>
15742
15743         * lib/mbuiter.h: New file.
15744
15745 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
15746
15747         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
15748         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
15749         and gl_GETOPT are both invoked via different paths (as happens
15750         with GNU tar CVS because it uses both argp and getopt), the former
15751         wins.
15752
15753 2005-08-16  Bruno Haible  <bruno@clisp.org>
15754
15755         * modules/tls: New file.
15756         * MODULES.html.sh (Multithreading): Add tls.
15757
15758 2005-08-16  Bruno Haible  <bruno@clisp.org>
15759
15760         * modules/strnlen1: New file.
15761         * MODULES.html.sh (String handling): Add strnlen1.
15762
15763 2005-08-16  Bruno Haible  <bruno@clisp.org>
15764
15765         * modules/strcase (Files): Add m4/mbrtowc.m4.
15766         (Depends-on): Add strnlen1, mbchar.
15767
15768 2005-08-16  Bruno Haible  <bruno@clisp.org>
15769
15770         * modules/mbiter: New file.
15771         * MODULES.html.sh (Extended multibyte and wide character utilities):
15772         Add mbiter.
15773
15774 2005-08-16  Bruno Haible  <bruno@clisp.org>
15775
15776         * modules/mbfile: New file.
15777         * MODULES.html.sh (Extended multibyte and wide character utilities):
15778         Add mbfile.
15779
15780 2005-08-16  Bruno Haible  <bruno@clisp.org>
15781
15782         * modules/mbchar: New file.
15783         * MODULES.html.sh (Extended multibyte and wide character utilities):
15784         New section.
15785
15786 2005-08-16  Bruno Haible  <bruno@clisp.org>
15787
15788         * m4/tls.m4: New file, from GNU gettext.
15789
15790 2005-08-16  Bruno Haible  <bruno@clisp.org>
15791
15792         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
15793         always.
15794         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
15795
15796 2005-08-16  Bruno Haible  <bruno@clisp.org>
15797
15798         * m4/mbiter.m4: New file.
15799
15800 2005-08-16  Bruno Haible  <bruno@clisp.org>
15801
15802         * m4/mbfile.m4: New file.
15803
15804 2005-08-16  Bruno Haible  <bruno@clisp.org>
15805
15806         * m4/mbchar.m4: New file.
15807
15808 2005-08-16  Bruno Haible  <bruno@clisp.org>
15809
15810         * lib/tls.h: New file, from GNU gettext.
15811         * lib/tls.c: New file, from GNU gettext.
15812
15813 2005-08-16  Bruno Haible  <bruno@clisp.org>
15814
15815         * lib/strnlen1.h: New file.
15816         * lib/strnlen1.c: New file.
15817
15818 2005-08-16  Bruno Haible  <bruno@clisp.org>
15819
15820         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
15821         (mbi_init): Update.
15822         (mbi_avail, mbi_advance): Let the iteration end before the terminating
15823         NUL byte, not after it.
15824
15825 2005-08-16  Bruno Haible  <bruno@clisp.org>
15826
15827         * lib/strcase.h (strcasecmp): Add note in comments.
15828         * lib/strncasecmp.c: Use code from strcasecmp.c.
15829         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
15830         (strcasecmp): Work correctly in multibyte locales.
15831
15832 2005-08-16  Bruno Haible  <bruno@clisp.org>
15833
15834         * lib/mbiter.h: New file.
15835
15836 2005-08-16  Bruno Haible  <bruno@clisp.org>
15837
15838         * lib/mbfile.h: New file.
15839
15840 2005-08-16  Bruno Haible  <bruno@clisp.org>
15841
15842         * lib/mbchar.h: New file.
15843         * lib/mbchar.c: New file.
15844
15845 2005-08-16  Bruno Haible  <bruno@clisp.org>
15846
15847         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
15848         the valid ones. Makes the comparison operations transitive:
15849         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
15850         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
15851
15852 2005-08-15  Simon Josefsson  <jas@extundo.com>
15853
15854         * modules/ssize_t (License): Change to 'unlimited'.
15855
15856         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
15857
15858 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
15859
15860         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
15861         Add comments for each pending glibc patch.
15862
15863 2005-08-15  Bruno Haible  <bruno@clisp.org>
15864
15865         * lib/regex.h (__restrict_arr): Don't define to __restrict if
15866         __cplusplus is defined.
15867
15868 2005-08-14  Jim Meyering  <jim@meyering.net>
15869
15870         Sync from coreutils.
15871
15872         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
15873         Use the hash-table-based cycle-detection code not just when
15874         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
15875         Reported by James Youngman in
15876         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
15877         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
15878         FTS_TIGHT_CYCLE_CHECK.
15879         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
15880         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
15881         once again.
15882         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
15883         * lib/fts.c (fd_safer): Remove decl.
15884         Include fcntl--.h rather than unistd-safer.h
15885         (fts_safe_changedir): Don't call fd_safer; no longer needed
15886         now that we include fcntl--.h.
15887
15888 2005-08-12  Simon Josefsson  <jas@extundo.com>
15889
15890         * modules/getndelim2: Use ssize_t module.
15891         * modules/getnline: Likewise.
15892         * modules/safe-read: Likewise.
15893         * modules/xreadlink: Likewise.
15894
15895         * modules/ssize_t: New file.
15896
15897 2005-08-12  Simon Josefsson  <jas@extundo.com>
15898
15899         * m4/readline.m4: Look for termcap, curses or ncurses if required.
15900
15901 2005-08-12  Simon Josefsson  <jas@extundo.com>
15902
15903         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
15904         ssize_t.
15905
15906 2005-08-12  Simon Josefsson  <jas@extundo.com>
15907
15908         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
15909         readline, getdelim and check_version.
15910         (Support for systems lacking ISO C 99: Sizes of integer types):
15911         Add size_max.
15912
15913 2005-08-12  Bruno Haible  <bruno@clisp.org>
15914
15915         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
15916
15917 2005-08-11  Simon Josefsson  <jas@extundo.com>
15918
15919         * modules/readline: New file.
15920
15921         * modules/strnlen (Files): Add strnlen.h.
15922
15923 2005-08-11  Simon Josefsson  <jas@extundo.com>
15924
15925         * m4/readline.m4: New file.
15926
15927 2005-08-11  Simon Josefsson  <jas@extundo.com>
15928
15929         * lib/readline.h, readline.c: New file.
15930
15931 2005-08-11  Simon Josefsson  <jas@extundo.com>
15932
15933         * doc/gnulib.texi (Initial import, Finishing touches): Mention
15934         gl_AVOID.
15935
15936 2005-08-11  Bruno Haible  <bruno@clisp.org>
15937
15938         * lib/strnlen.h (strnlen): Change parameter name to match comment.
15939
15940 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
15941
15942         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
15943
15944 2005-08-10  Simon Josefsson  <jas@extundo.com>
15945
15946         * tests/test-iconvme.c: New file.
15947
15948 2005-08-10  Simon Josefsson  <jas@extundo.com>
15949
15950         * m4/strnlen.m4: New file.
15951
15952         * m4/strndup.m4: Don't check for strnlen declaration, done in
15953         strnlen.m4.
15954
15955 2005-08-10  Simon Josefsson  <jas@extundo.com>
15956
15957         * lib/strndup.c: Use strnlen.h.
15958
15959         * lib/strnlen.h: New file.
15960
15961 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15962
15963         * README: Typos.
15964
15965 2005-08-02  Simon Josefsson  <jas@extundo.com>
15966
15967         * modules/readline: New file.
15968
15969 2005-08-02  Simon Josefsson  <jas@extundo.com>
15970
15971         * modules/getdelim: New file.
15972
15973         * modules/getline: Rewrite, don't use getndelim2.
15974
15975 2005-08-02  Simon Josefsson  <jas@extundo.com>
15976
15977         * m4/getline.m4: Separate out getdelim stuff into separate module.
15978
15979         * m4/getdelim.m4: New file.
15980
15981 2005-08-02  Simon Josefsson  <jas@extundo.com>
15982
15983         * lib/getline.h, getline.c: Rewrite.
15984
15985         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
15986
15987 2005-07-31  Bruno Haible  <bruno@clisp.org>
15988
15989         * lib/lock.h (gl_lock_initializer): New macro.
15990         (gl_lock_define_initialized): Use it.
15991         (gl_rwlock_initializer): New macro.
15992         (gl_rwlock_define_initialized): Use it.
15993         (gl_recursive_lock_initializer): New macro.
15994         (gl_recursive_lock_define_initialized): Use it.
15995
15996 2005-07-30  Karl Berry  <karl@gnu.org>
15997
15998         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
15999         Report from Ben Pfaff, regarding getopt.
16000
16001 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
16002
16003         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
16004         normal way.
16005         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
16006         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
16007         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
16008         (gl_GETOPT): Use the new macros.  Most of the implementation
16009         is moved to the new macros.  This is for programs like Emacs
16010         that don't want all the functionality of gl_GETOPT.
16011
16012 2005-07-26  Bruno Haible  <bruno@clisp.org>
16013
16014         * m4/lock.m4: Update from GNU gettext.
16015
16016 2005-07-26  Bruno Haible  <bruno@clisp.org>
16017
16018         * lib/lock.h: Update from GNU gettext.
16019         * lib/lock.c: Update from GNU gettext.
16020
16021 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
16022
16023         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
16024         obsolescent AC_TRY_RUN.  Include the default includes files, for
16025         'exit'.
16026
16027 2005-07-24  Bruno Haible  <bruno@clisp.org>
16028
16029         * modules/visibility: New file.
16030         * MODULES.html.sh (Misc): Add visibility.
16031
16032 2005-07-24  Bruno Haible  <bruno@clisp.org>
16033
16034         * m4/visibility.m4: New file.
16035
16036 2005-07-24  Bruno Haible  <bruno@clisp.org>
16037
16038         * doc/visibility.texi: New file.
16039
16040 2005-07-22  Bruno Haible  <bruno@clisp.org>
16041
16042         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
16043         $(ALLOCA_H), redundant through BUILT_SOURCES.
16044         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
16045         redundant through BUILT_SOURCES.
16046         * modules/byteswap (Makefile.am): Remove explicit dependency on
16047         $(BYTESWAP_H), redundant through BUILT_SOURCES.
16048         * modules/fnmatch (Makefile.am): Remove explicit dependency on
16049         $(FNMATCH_H), redundant through BUILT_SOURCES.
16050         * modules/getopt (Makefile.am): Remove explicit dependency on
16051         $(GETOPT_H), redundant through BUILT_SOURCES.
16052         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
16053         redundant through BUILT_SOURCES.
16054         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
16055         redundant through BUILT_SOURCES.
16056         * modules/stdbool (Makefile.am): Remove explicit dependency on
16057         $(STDBOOL_H), redundant through BUILT_SOURCES.
16058         * modules/stdint (Makefile.am): Remove explicit dependency on
16059         $(STDINT_H), redundant through BUILT_SOURCES.
16060         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
16061         Remove explicit dependency on $(SYSEXITS_H).
16062         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
16063
16064 2005-07-18  Simon Josefsson  <jas@extundo.com>
16065
16066         * lib/check-version.c (check_version): Accept identical versions too.
16067
16068 2005-07-18  Bruno Haible  <bruno@clisp.org>
16069
16070         * modules/lock: New file.
16071         * MODULES.html.sh (Multithreading): New section.
16072
16073 2005-07-18  Bruno Haible  <bruno@clisp.org>
16074
16075         * m4/lock.m4: New file, from GNU gettext.
16076
16077 2005-07-18  Bruno Haible  <bruno@clisp.org>
16078
16079         * lib/lock.h: New file, from GNU gettext.
16080         * lib/lock.c: New file, from GNU gettext.
16081
16082 2005-07-18  Bruno Haible  <bruno@clisp.org>
16083
16084         * lib/lock.h (gl_once_t): New type.
16085         (gl_once_define, gl_once): New macros.
16086         * lib/lock.c (fresh_once): New variable.
16087         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
16088         functions.
16089
16090 2005-07-16  Simon Josefsson  <jas@extundo.com>
16091
16092         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
16093         workaround, suggested by Bruno.
16094
16095 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
16096
16097         * modules/xalloc (Depends-on): Add xalloc-die.
16098         * modules/xvasprintf (Depends-on): Add xalloc-die.
16099
16100 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
16101
16102         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
16103         with a minor change.
16104
16105 2005-07-15  Bruno Haible  <bruno@clisp.org>
16106
16107         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
16108         When using lib/poll.c, define poll as rpl_poll.
16109
16110 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
16111
16112         * modules/argp (Depends-on): Remove unlocked-io.
16113
16114 2005-07-14  Derek Price  <derek@ximbiot.com>
16115
16116         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
16117         for glob symlink bug.
16118
16119 2005-07-14  Bruno Haible  <bruno@clisp.org>
16120
16121         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
16122         Instead, test for *_unlocked function declarations directly.
16123
16124 2005-07-11  Simon Josefsson  <jas@extundo.com>
16125
16126         * modules/size_max: New file.
16127
16128         * modules/xsize: Depend on size_max module for size_max.m4.
16129
16130 2005-07-11  Simon Josefsson  <jas@extundo.com>
16131
16132         * lib/size_max.h: New file.
16133
16134 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
16135
16136         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
16137         copyright symbol and the year.
16138         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
16139         (version_etc_va): Use parameterized copyright notice.
16140         Reword to conform to the current GNU coding standards.
16141
16142 2005-07-11  Karl Berry  <karl@gnu.org>
16143
16144         * doc/gnulib.texi (Quoting): new node.
16145         (Initial import): more info, from Patrice.
16146
16147 2005-07-11  Bruno Haible  <bruno@clisp.org>
16148
16149         * gnulib-tool (func_usage): Document option --avoid.
16150         (Command line options): Handle --avoid.
16151         (func_acceptable): New function.
16152         (func_modules_transitive_closure): Use it.
16153
16154 2005-07-11  Bruno Haible  <bruno@clisp.org>
16155
16156         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
16157         Reported by Jim Meyering.
16158
16159 2005-07-10  Bruno Haible  <bruno@clisp.org>
16160
16161         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
16162         Needed when size_t is smaller than 'unsigned int'.
16163         Reported by Paul Eggert.
16164
16165 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16166
16167         * modules/argp (Depends-on): Add unlocked-io
16168
16169 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16170
16171         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
16172         block of defines.
16173
16174 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
16175
16176         * config/srclist.txt: Comment out regcomp.c, since we have a porting
16177         fix now.
16178
16179 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
16180         and Paul Eggert  <eggert@cs.ucla.edu>
16181
16182         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
16183         in wint_t, not wchar_t.  Remove now-unnecessary cast.
16184
16185 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16186
16187         * modules/regex (Files): Add lib/regex_internal.c,
16188         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
16189         (Depends-on): Add extensions.
16190         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
16191
16192 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16193
16194         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
16195         pathconf.
16196         * m4/same.m4 (gl_SAME): Likewise.
16197         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
16198
16199         * m4/regex.m4: Adjust to new libc regex implementation.
16200         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
16201         all the .c and .h parts of (the new) regex.
16202         Quote the m4 stuff better.
16203         Check for RE_ICASE bug of old gnulib.
16204         Check for REG_STARTEND of recent libc.
16205         Rename local variables from jm_* to gl_*.
16206         Quote operand of "test -f".
16207         Say "recent enough" version of libc, not "version 2".
16208         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
16209         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
16210         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
16211         Remove check for btowc, isascii.
16212         Require AM_LANGINFO_CODESET.
16213
16214 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16215
16216         * lib/regex.c, regex.h: Sync from libc.
16217         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
16218         * lib/regexec.c:
16219         New files, synced from libc, except that regex_internal.h
16220         currently has a small porting fix.
16221
16222 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16223
16224         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
16225         regex_internal.c, regexec.c.
16226         Add regex_internal.h too, but as a comment, since the libc version
16227         is currently broken in gnulib mode.
16228
16229 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
16230
16231         Support programs like Emacs that use gnulib but not gettext.
16232         * MODULES.html.sh (Internationalization functions): Add gettext-h.
16233         * modules/gettext-h: New file.
16234         * modules/gettext (Files): Remove lib/gettext.h.
16235         (Depends-on): Add gettext-h.
16236         (Makefile.am): Remove lib_SOURCES.
16237         * modules/argmatch, modules/c-stack, modules/closeout:
16238         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
16239         * modules/execute, modules/file-type, modules/getaddrinfo:
16240         * modules/getopt, modules/human, modules/javacomp:
16241         * modules/javaexec, modules/mkdir-p, modules/obstack:
16242         * modules/openat, modules/pagealign_alloc, modules/pipe:
16243         * modules/quotearg, modules/regex, modules/rpmatch:
16244         * modules/unicodeio, modules/userspec, modules/version-etc:
16245         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
16246         * modules/xsetenv:
16247         Depend on gettext-h, not gettext.
16248
16249 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
16250
16251         * gnulib-tool (func_import): Add support for 'public domain' license.
16252         * modules/alloca, modules/atexit, modules/memmove:
16253         Now public domain, not GPL.
16254         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
16255         * modules/realloc, modules/strerror, modules/strtod:
16256         Now LGPL, not GPL.
16257
16258 2005-07-05  Bruno Haible  <bruno@clisp.org>
16259
16260         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
16261         autoconf CVS. Needed for mingw.
16262
16263 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
16264
16265         Remove the dependency of the strftime module on the tzset module.
16266         * modules/strftime (Depends-on): Remove dependency on tzset.
16267
16268 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
16269
16270         Remove the dependency of the strftime module on the tzset module.
16271         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
16272         gl_FUNC_TZSET_CLOBBER.
16273
16274 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
16275
16276         Remove the dependency of the strftime module on the tzset module.
16277         * lib/strftime.c (my_strftime)
16278         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
16279         Copy the input structure, to work around some of the bug with
16280         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
16281         Solaris releases, you should also use the tzset module, but we won't
16282         require it as a dependency any more since we don't want LGPLed code
16283         to depend on GPLed code.
16284
16285 2005-07-02  Jim Meyering  <jim@meyering.net>
16286
16287         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
16288         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
16289         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
16290         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
16291
16292 2005-07-02  Jim Meyering  <jim@meyering.net>
16293
16294         * lib/backupfile.c (backup_args): Change a `0' to NULL.
16295
16296 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
16297
16298         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
16299         declares only 'struct timespec;' (!).
16300
16301 2005-07-01  Jim Meyering  <jim@meyering.net>
16302
16303         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
16304         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
16305         * lib/save-cwd.c, tempname.c:
16306         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
16307         and don't include <sys/file.h>).
16308
16309 2005-06-29  Jim Meyering  <jim@meyering.net>
16310
16311         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
16312         type name.  Use the variable name instead.
16313         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
16314         Likewise.
16315
16316 2005-06-28  Simon Josefsson  <jas@extundo.com>
16317
16318         * modules/check-version (Files): Add check-version.m4.
16319
16320 2005-06-28  Simon Josefsson  <jas@extundo.com>
16321
16322         * m4/check-version.m4: New file, suggested by Jim Meyering
16323         <jim@meyering.net>.
16324
16325 2005-06-28  Simon Josefsson  <jas@extundo.com>
16326
16327         * lib/check-version.h, lib/check-version.c: New files.
16328
16329 2005-06-28  Simon Josefsson  <jas@extundo.com>
16330
16331         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
16332         collision with global variable.  Better indentation.  Don't
16333         increment buffer pointer beyond buffer end.  Based on comments
16334         from Paul Eggert <eggert@cs.ucla.edu>.
16335
16336         * lib/base64.h: Indent.
16337
16338 2005-06-28  Simon Josefsson  <jas@extundo.com>
16339
16340         * doc/gnulib.texi (Library version handling): New section.
16341
16342 2005-06-28  Jim Meyering  <jim@meyering.net>
16343
16344         * check-module (find_included_lib_files): Hard-code another
16345         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
16346         but modules/fts-lgpl (correctly) does not list those files.
16347
16348         * modules/canonicalize (Files): Add lib/pathmax.h.
16349
16350 2005-06-25  Simon Josefsson  <jas@extundo.com>
16351
16352         * modules/check-version: New file.
16353
16354 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
16355
16356         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
16357         initializer of struct addrinfo, as an indication that we don't
16358         care how many members the structure has.
16359
16360 2005-06-24  Derek Price  <derek@ximbiot.com>
16361         and Bruno Haible  <bruno@clisp.org>
16362
16363         Remove stat module & update lstat.
16364         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
16365         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
16366         * m4/stat.m4: Remove this file.
16367
16368 2005-06-24  Derek Price  <derek@ximbiot.com>
16369         and Bruno Haible  <bruno@clisp.org>
16370
16371         Remove stat module & update lstat.
16372         * lib/stat.c: Remove this file...
16373         (slash_aware_lstat): ...moving this content and its support...
16374         * lib/lstat.c (rpl_lstat): ...into here.
16375         * lib/lstat.h: New file.
16376
16377 2005-06-24  Derek Price  <derek@ximbiot.com>
16378         and Bruno Haible  <bruno@clisp.org>
16379
16380         Remove stat module & update lstat.
16381         * config/srclist.txt (libc sources): Remove stat.
16382
16383 2005-06-24  Derek Price  <derek@ximbiot.com>
16384         and Bruno Haible  <bruno@clisp.org>
16385
16386         Remove stat module & update lstat.
16387         * MODULES.html.sh (stat): Remove.
16388         * MODULES.html: Regenerated.
16389         * modules/lstat (Description): Correct function name.
16390         (Files): Add "lstat.h".
16391         (Depends-on): Remove stat, add xalloc, stat-macros.
16392         * modules/stat: Remove this file.
16393         (Include): Add "lstat.h", remove <sys/stat.h>.
16394
16395 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
16396
16397         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
16398         (ranged_convert): Don't save conversion in a temporary struct.
16399         This causes a warning with GCC 4.0.0, and anyway in the typical
16400         case it's not worth the extra 100 bytes or so of code.
16401         (ranged_convert, __mktime_internal): When calling a function via a
16402         pointer P, use P () rather than (*P) (), as we now assume C89 or
16403         better.
16404
16405 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16406
16407         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
16408         "who -r" failed to give output.  Problem reported by Tim Waugh.
16409
16410         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
16411         (xcalloc): Use it to avoid needless tests.
16412         Problem reported by Jim Meyering.
16413
16414 2005-06-20  Derek Price  <derek@ximbiot.com>
16415
16416         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
16417         unnecessary for Autoconfs > 2.59c.
16418
16419 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16420
16421         * lib/argp.h (__option_is_short): Check upper limit of
16422         __key. Isprint() requires its argument to have the value
16423         of an unsigned char or EOF.
16424
16425 2005-06-16  Jim Meyering  <jim@meyering.net>
16426
16427         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
16428         when either N or S is zero.
16429
16430 2005-06-16  Derek Price  <derek@ximbiot.com>
16431
16432         * m4/bison.m4: Declare YACC & YFLAGS precious.
16433
16434 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
16435
16436         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
16437         multibyte string or pattern, fall back on unibyte matching.
16438         Problem reported by James Youngman.
16439
16440 2005-06-08  Bruno Haible  <bruno@clisp.org>
16441
16442         * modules/csharpcomp: New file.
16443         * MODULES.html.sh (C#): Add csharpcomp.
16444
16445 2005-06-08  Bruno Haible  <bruno@clisp.org>
16446
16447         * m4/csharpcomp.m4: New file, from GNU gettext.
16448
16449 2005-06-08  Bruno Haible  <bruno@clisp.org>
16450
16451         * lib/csharpcomp.h: New file, from GNU gettext.
16452         * lib/csharpcomp.c: New file, from GNU gettext.
16453         * lib/csharpcomp.sh.in: New file, from GNU gettext.
16454
16455 2005-06-08  Bruno Haible  <bruno@clisp.org>
16456
16457         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
16458         warning on mingw.
16459
16460 2005-06-07  Derek Price  <derek@ximbiot.com>
16461
16462         Sync from CVS.
16463         * lib/glob_.h: Indent nested #ifdef.
16464
16465 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
16466
16467         Sync from coreutils.
16468         Use "file name" when talking about file names, instead of "filename"
16469         or "path", as per the GNU coding standards.
16470         * lib/mkdir-p.c: Renamed from makepath.c.
16471         (make_dir_parents): Renamed from make_path.  All callers changed.
16472         * lib/mkdir-p.h: Likewise.  All includers changed.
16473         * lib/filenamecat.c: Renamed from path-concat.c.
16474         (file_name_concat): Renamed from path_concat.  All callers changed.
16475         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
16476         * lib/filenamecat.h: Likewise.  All includers changed.
16477         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
16478         in comments or local variable names.
16479         * lib/basename.c: Likewise.
16480         * lib/canonicalize.c, canonicalize.h: Likewise.
16481         * lib/dirname.c, dirname.h: Likewise.
16482         * lib/euidaccess.c: Likewise.
16483         * lib/exclude.c: Likewise
16484         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
16485         * lib/fsusage.c, fsuage.h: Likewise.
16486         * lib/fts.c, fts_.h: Likewise.
16487         * lib/getcwd.c: Likewise.
16488         * lib/getloadavg.c: Likewise.
16489         * lib/mkstemp.c: Likewise.
16490         * lib/mountlist.c, mountlist.h: Likewise.
16491         * lib/openat.c, openat.h: Likewise.
16492         * lib/readlink-stub.c: Likewise.
16493         * lib/readutmp.c, readutmp.h: Likewise.
16494         * lib/rename.c: Likewise.
16495         * lib/rmdir.c: Likewise.
16496         * lib/same.c: Likewise.
16497         * lib/savedir.c: Likewise.
16498         * lib/stripslash.c: Likewise.
16499         * lib/tempname.c: Likewise.
16500         * lib/xreadlink.c: Likewise.
16501         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
16502         All uses changed.
16503         * lib/exclude.h: Likewise.
16504
16505         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
16506         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
16507         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
16508         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
16509         * lib/pathmax.h: Include <limits.h> unconditionally, since other
16510         files have been getting away with it for years (MORE/BSD 4.3
16511         is extinct now).
16512         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
16513         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
16514
16515         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
16516         Define to 256, not 255, as per modern POSIX.
16517
16518 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
16519
16520         Sync from coreutils.
16521         Use "file name" when talking about file names, instead of "filename"
16522         or "path", as per the GNU coding standards.
16523         * MODULES.html.sh: mkdir-p renamed from makepath.
16524         filenamecat renamed from path-concat.
16525         * modules/filenamecat: Renamed from modules/path-concat.
16526         (Files): filenamecat.h and filenamecat.c renamed from
16527         path-concat.h and path-concat.c.
16528         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
16529         (Include): filenamecat.h, not path-concat.h.
16530         * modules/mkdir-p: Renamed from modules/makepath.
16531         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
16532         makepath.c.
16533         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
16534         (Include): mkdir-p.h, not makepath.h.
16535
16536 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
16537
16538         Sync from coreutils.
16539         * m4/mkdir-p.m4: Renamed from makepath.m4.
16540         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
16541         Rename files from makepath.c to mkdir-p.c, and from
16542         makepath.h to mkdir-p.h.
16543         * m4/filenamecat.m4: Renamed from path-concat.m4.
16544         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
16545         Rename files from path-concat.c to filenamecat.c,
16546         and from path-concat.h to filenamecat.h.
16547         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
16548         "file name" in local variables or comments.
16549         * m4/rename.m4: Likewise.
16550
16551 2005-06-01  Bruno Haible  <bruno@clisp.org>
16552
16553         * modules/csharpexec: New file.
16554         * MODULES.html.sh (C#): New section.
16555
16556 2005-06-01  Bruno Haible  <bruno@clisp.org>
16557
16558         * m4/csharp.m4: New file, from GNU gettext.
16559         * m4/csharpexec.m4: New file, from GNU gettext.
16560
16561 2005-06-01  Bruno Haible  <bruno@clisp.org>
16562
16563         * lib/csharpexec.h: New file, from GNU gettext.
16564         * lib/csharpexec.c: New file, from GNU gettext.
16565         * lib/csharpexec.sh.in: New file, from GNU gettext.
16566
16567 2005-05-31  Derek Price  <derek@ximbiot.com>
16568             Paul Eggert  <eggert@cs.ucla.edu>
16569
16570         Sync from cvs.
16571         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
16572
16573 2005-05-31  Derek Price  <derek@ximbiot.com>
16574             Paul Eggert  <eggert@cs.ucla.edu>
16575
16576         Sync from cvs.
16577         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
16578
16579 2005-05-29  Derek Price  <derek@ximbiot.com>
16580
16581         * config/srclist.txt (glob_.h, glob.c): Add these files.
16582
16583 2005-05-29  Derek Price  <derek@ximbiot.com>
16584
16585         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
16586         * modules/glob: New file.
16587         * modules/getlogin_r: Add link to POSIX spec in description.
16588
16589 2005-05-29  Derek Price  <derek@ximbiot.com>
16590             Paul Eggert  <eggert@cs.ucla.edu>
16591
16592         * m4/glob.m4: New file.
16593
16594 2005-05-29  Derek Price  <derek@ximbiot.com>
16595             Paul Eggert  <eggert@cs.ucla.edu>
16596
16597         * lib/glob_.h, lib/glob.c: New files.
16598
16599 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16600
16601         * modules/fts (Files): Remove m4/inttypes-pri.m4.
16602         * modules/fts-lgpl (Depends-on): Remove gettext.
16603
16604 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16605
16606         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
16607         and don't require gt_INTTYPES_PRI.
16608
16609 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16610
16611         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
16612
16613         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
16614         the configuration hassle isn't worth it.
16615         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
16616         (LONGEST_MODIFIER, PRIuMAX): Remove.
16617
16618 2005-05-27  Bruno Haible  <bruno@clisp.org>
16619
16620         * lib/getlogin_r.h: Remove second include of <stddef.h>.
16621
16622 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
16623
16624         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
16625         _POSIX_PTHREAD_SEMANTICS for Solaris.
16626
16627 2005-05-25  Derek Price  <derek@ximbiot.com>
16628
16629         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
16630
16631 2005-05-25  Derek Price  <derek@ximbiot.com>
16632             Paul Eggert  <eggert@cs.ucla.edu>
16633
16634         * modules/getlogin_r, m4/getlogin_r.m4: New files.
16635         * lib/getlogin_r.c, getlogin_r.h: New files.
16636
16637 2005-05-25  Bruno Haible  <bruno@clisp.org>
16638             Derek Price  <derek@ximbiot.com>
16639
16640         * lib/getlogin_r.h: Simplify API documentation.
16641
16642 2005-05-23  Derek Price  <derek@ximbiot.com>
16643
16644         * modules/minmax (Files): Add m4/minmax.m4.
16645         (configure.ac): Add gl_MINMAX.
16646
16647 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
16648
16649         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
16650         so that unistd-safer.h (GPL'ed code) need not be included.
16651
16652 2005-05-22  Bruno Haible  <bruno@clisp.org>
16653
16654         * m4/minmax.m4: New file.
16655         Based on a patch by Derek Price <derek@ximbiot.com>.
16656
16657 2005-05-22  Bruno Haible  <bruno@clisp.org>
16658
16659         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
16660         (INT64_MIN): Fix definition.
16661         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
16662
16663         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
16664         NEED_SIGNED_INT_TYPES.
16665
16666         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
16667         HAVE_SYSTEM_INTTYPES.
16668
16669 2005-05-22  Bruno Haible  <bruno@clisp.org>
16670
16671         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
16672         Also include <sys/param.h> if it defines MIN, MAX.
16673         Based on a patch by Derek Price <derek@ximbiot.com>.
16674
16675 2005-05-21  Jim Meyering  <jim@meyering.net>
16676
16677         * modules/fts (Files): Add m4/inttypes-pri.m4.
16678         (Depends-on): Add lstat and remove gettext.  Alphabetize.
16679
16680 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16681
16682         New fts module.
16683         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
16684         (setup_dir, free_dir): New functions.
16685         (enter_dir, leave_dir): Define trivial
16686         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
16687         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
16688         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
16689         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
16690         Move to fts-cycle.c.
16691         (fts_open): Use setup_dir.
16692         (fts_close): Use free_dir.
16693         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
16694         This adds a label and some gotos, but the alternatives were messier.
16695         Check for memory allocation failure when entering a dir.
16696         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
16697         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
16698         (FTS): New member fts_cycle, that is a union that contains the
16699         old active_dir_ht and cycle_state.  All uses changed to mention
16700         fts_cycle.ht and fts_cycle.state.
16701         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
16702         fts.c, with the following changes:
16703         (setup_dir, free_dir): New functions.
16704         (enter_dir): Now returns bool.  Return true if successful, false
16705         if memory exhausted.  All callers changed.
16706         Do not bother partly cleaning up on
16707         memory allocation failure; that is free_dir's job.
16708         However, free ad if hash_insert fails, to avoid memory leak.
16709         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
16710         fts->fts_options to see which union member to use.
16711
16712 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16713
16714         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
16715         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
16716
16717 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16718
16719         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
16720
16721 2005-05-20  Jim Meyering  <jim@meyering.net>
16722
16723         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
16724         Now a macro, to pacify GCC.
16725
16726 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16727
16728         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
16729         of -1.
16730
16731 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16732
16733         * lib/chown.c (rpl_chown): Return -1 on failure.
16734
16735 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16736
16737         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
16738         Don't check for stddef.h.
16739         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
16740         don't use its results.
16741         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
16742         since we include them unconditionally.  Don't require
16743         AM_STDBOOL_H, since stdbool is a prerequisite.
16744         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
16745         since we assume C89 or better.
16746         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
16747         as we don't use their results.
16748         Don't check for fchdir, memmove, memset, strrchr, as we use
16749         them unconditionally.
16750         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
16751         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
16752
16753 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16754
16755         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
16756         Include <stddef.h> unconditionally, since we assume C89 now.
16757         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
16758         * lib/fts.c: Include fts_.h first, to check interface.
16759         Do not include intprops.h; no longer needed.
16760         Include cycle-check.h and hash.h, since fts_.h no longer does.
16761         Remove unnecessary casts of closedir to void.
16762         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
16763         decide whether to decrement nlinks.
16764         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
16765         (FTS): Use struct hash_table * instead of Hash_table, so that
16766         we no longer need to include hash.h here.
16767
16768 2005-05-18  Jim Meyering  <jim@meyering.net>
16769
16770         * modules/dirfd (License): Change to LGPL.  Most of the code
16771         is already in the public domain.
16772
16773 2005-05-18  Jim Meyering  <jim@meyering.net>
16774
16775         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
16776         Reported by Yoann Vandoorselaere.
16777
16778 2005-05-17  Jim Meyering  <jim@meyering.net>
16779
16780         * m4/fts.m4: New file, from coreutils.
16781
16782 2005-05-17  Jim Meyering  <jim@meyering.net>
16783
16784         * lib/fts.c, lib/fts_.h: New files, from coreutils.
16785
16786 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16787
16788         Sync from coreutils.
16789         * m4/unlinkdir.m4: New file.
16790
16791 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16792
16793         Sync from coreutils.
16794         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
16795         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
16796         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
16797         White space changes only.
16798         * lib/makepath.c (make_path): Port to hosts where leading "//" is
16799         special.
16800         * lib/yesno.c: Include getline.h, not ctype.h.
16801         (yesno): Don't remove leading white space; POSIX doesn't allow it.
16802         Use getline to remove arbitrary restriction on response length.
16803
16804 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16805
16806         * config/srclist-update: Spell out "Street" in FSF postal
16807         mail address; this is the style the FSF seems to prefer.
16808
16809         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
16810         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
16811         this updates FSF postal mail address.
16812
16813         Sync from coreutils.
16814         * modules/unlinkdir: New file.
16815         * modules/yesno (Depends-on): Add getline.
16816         * MODULES.html.sh (File system functions): Add unlinkdir.
16817
16818 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16819
16820         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
16821         lib/strsep.h:
16822         Change the initial comment to refer to GPL, not LGPL.
16823         gnulib-tool will change it to LGPL as needed.
16824
16825         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
16826         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
16827         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
16828         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
16829         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
16830         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
16831         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
16832         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
16833         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
16834         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
16835         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
16836         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
16837         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
16838         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
16839         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
16840         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
16841         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
16842         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
16843         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
16844         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
16845         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
16846         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
16847         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
16848         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
16849         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
16850         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
16851         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
16852         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
16853         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
16854         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
16855         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
16856         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
16857         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
16858         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
16859         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
16860         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
16861         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
16862         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
16863         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
16864         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
16865         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
16866         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
16867         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
16868         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
16869         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
16870         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
16871         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
16872         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
16873         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
16874         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
16875         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
16876         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
16877         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
16878         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
16879         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
16880         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
16881         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
16882         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
16883         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
16884         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
16885         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
16886         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
16887         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
16888         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
16889         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
16890         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
16891         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
16892         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
16893         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
16894         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
16895         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
16896         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
16897         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
16898         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
16899         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
16900         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
16901         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
16902         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
16903         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
16904         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
16905         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
16906         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
16907         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
16908         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
16909         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
16910         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
16911         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
16912         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
16913         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
16914         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
16915         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
16916         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
16917         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
16918         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
16919         lib/yesno.c, lib/yesno.h:
16920         Update FSF postal mail address.
16921
16922 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16923
16924         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
16925         tests/test-memmem.c, tests/test-stpncpy.c:
16926         Update FSF postal mail address.
16927
16928 2005-05-13  Bruno Haible  <bruno@clisp.org>
16929
16930         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
16931         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
16932         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
16933         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
16934         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
16935         Add support for 64-bit integers in the MSVC compiler.
16936
16937 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16938
16939         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
16940
16941 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
16942
16943         * gnulib-tool (func_import): Sort and uniquify recommended includes.
16944
16945 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
16946
16947         * doc/getdate.texi (General date syntax): Don't say that date
16948         date --iso-8601=ns generates acceptable dates; it doesn't yet.
16949         Problem reported by Nic Ferrier.
16950
16951 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16952
16953         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
16954         specified in ai_socktype. Fix invalid ai_protocol
16955         check. ai_protocol is usually set to 0 or depending on
16956         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
16957         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
16958         ai_socktype / ai_protocol in the returned addrinfo structure.
16959
16960 2005-05-10  Simon Josefsson  <jas@extundo.com>
16961
16962         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
16963         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
16964
16965 2005-05-10  Karl Berry  <karl@gnu.org>
16966
16967         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
16968         (from http://www.gnu.org/licenses).
16969         * doc/COPYING.LIB: also rename to COPYING.LESSER.
16970         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
16971         fdl.texi suffices.
16972
16973 2005-05-10  Karl Berry  <karl@gnu.org>
16974
16975         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
16976         (COPYING.DOC): remove.
16977
16978         * config/srclist-update: new FSF address.
16979
16980 2005-05-10  Derek Price  <derek@ximbiot.com>
16981
16982         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
16983         possible.
16984
16985 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16986             Bruno Haible  <bruno@clisp.org>
16987
16988         * modules/inet_ntop: New file.
16989         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16990         inet_ntop.
16991
16992 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16993             Bruno Haible  <bruno@clisp.org>
16994
16995         * m4/inet_ntop.m4: New file.
16996
16997 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
16998             Bruno Haible  <bruno@clisp.org>
16999
17000         * lib/inet_ntop.h: New file.
17001         * lib/inet_ntop.c: New file, from glibc with modifications.
17002
17003 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
17004
17005         * modules/time_r (License): Change to LGPL.
17006         * modules/extensions (License): Change to LGPL.  Actually,
17007         the license is more permissive than that, but currently gnulib-tool
17008         doesn't know how to handle more-permissive licenses.
17009
17010         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
17011         Problem reported by Dave Love.
17012
17013 2005-05-08  Jim Meyering  <jim@meyering.net>
17014
17015         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
17016         blank.
17017
17018 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
17019
17020         * modules/argmatch (Depends-on): Add stdbool.
17021         * modules/backupfile (Depends-on): Likewise.
17022         * modules/chdir-long (Depends-on): Likewise.
17023         * modules/closeout (Depends-on): Likewise.
17024         * modules/cycle-check (Depends-on): Likewise.
17025         * modules/dirname (Depends-on): Likewise.
17026         * modules/fnmatch (Depends-on): Likewise.
17027         * modules/fsusage (Depends-on): Likewise.
17028         * modules/fwriteerror (Depends-on): Likewise.
17029         * modules/getcwd (Depends-on): Likewise.
17030         * modules/getloadavg (Depends-on): Likewise.
17031         * modules/hard-locale (Depends-on): Likewise.
17032         * modules/makepath (Depends-on): Likewise.
17033         * modules/mountlist (Depends-on): Likewise.
17034         * modules/nanosleep (Depends-on): Likewise.
17035         * modules/posixtm (Depends-on): Likewise.
17036         * modules/quotearg (Depends-on): Likewise.
17037         * modules/readtokens (Depends-on): Likewise.
17038         * modules/readtokens0 (Depends-on): Likewise.
17039         * modules/readutmp (Depends-on): Likewise.
17040         * modules/save-cwd (Depends-on): Likewise.
17041         * modules/strftime (Depends-on): Likewise.
17042         * modules/userspec (Depends-on): Likewise.
17043         * modules/utimecmp (Depends-on): Likewise.
17044         * modules/xgetcwd (Depends-on): Likewise.
17045         * modules/xnanosleep (Depends-on): Likewise.
17046         * modules/xstrtod (Depends-on): Likewise.
17047         * modules/yesno (Depends-on): Likewise.
17048
17049 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
17050
17051         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
17052         needless checks.
17053
17054 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17055
17056         Merge from coreutils.  Among other things,
17057         add bulletproofing for cases where stdin, stdout, or stderr are closed.
17058         * lib/fd-safer.c: New file.
17059         * lib/fcntl-safer.h, open-safer.c: Remove.
17060         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
17061         * lib/dup-safer.c: Include unistd-safer.h first.
17062         Don't include errno.h.
17063         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
17064         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
17065         * lib/file-type.c: Rely on file-type.h change.
17066         * lib/getloadavg.c: Include unistd-safer.h.
17067         (getloadavg): Use safer open.
17068         * lib/getusershell.c: Include "stdio-safer.h".
17069         (getusershell): Use safer fopen.
17070         * lib/long-options.c (long_options): Use NULL rather than 0.
17071         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
17072         'free'.
17073         * lib/modechange.c: Likewise.
17074         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
17075         (MODE_DONE): New constant.
17076         (struct mode_change): Remove 'next' member.
17077         (make_node_op_equals): New function; like the old one of the
17078         same name, except it allocates an array.
17079         (mode_compile, mode_create_from_ref): Use it.
17080         (mode_compile): Allocate result as an array, not a linked list.
17081         Parse octal string ourself, so that we catch mistakes like "+0".
17082         (mode_adjust): Arg is an array, not a linked list.
17083         * lib/modechange.c: Include stat-macros.h, xalloc.h.
17084         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
17085         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
17086         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
17087         Remove.  This is now stat-macros.h's job.
17088         (talloc): Remove.  All callers replaced by xalloc, so that
17089         our invokers don't have to worry about reporting memory failures.
17090         (make_node_op_equals): Remove.
17091         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
17092         New constants.
17093         (struct mode_change): Moved here from modechange.h.
17094         (mode_append_entry): Remove.
17095         (mode_compile): Remove MASKED_OPS arg, since it encouraged
17096         apps to have incorrect behavior.  Use simpler algorithm for head
17097         and tail.  Don't futz with umask; that's now the job of mode_adjust.
17098         Detect more invalid usages rather than having somewhat-random behavior.
17099         Don't insert an "a=" action, as that leads to incorrect behavior.
17100         (mode_compile, mode_create_from_ref): Return NULL on error instead
17101         of an enum, since now there's only one way to have an error.  All
17102         callers changed.
17103         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
17104         at the correct time.  Simplify calculation of "+u" and its ilk.
17105         Don't mishandle "+X".
17106         (mode_free): Remove "register" and localize decls.
17107         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
17108         (struct mode_change): Move to modechange.c; callers don't
17109         need to see this stuff.
17110         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
17111         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
17112         (mode_change, mode_adjust): Reflect the new signatures noted above.
17113         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
17114         that might redefine system include files.
17115         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
17116         (my_usleep): Use NULL rather than (void *) 0.
17117         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
17118         Use siginterrupt to specify that system calls should be interrupted.
17119         (rpl_nanosleep): Move initialization of suspended closer to call of
17120         my_usleep.
17121         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
17122         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
17123         (desirable_utmp_entry): New function.
17124         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
17125         using x2nrealloc, to simplify logic.
17126         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
17127         size calculation.  Do not assume utmp file is a regular file.
17128         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
17129         (READ_UTMP_CHECK_PIDS): New constant.
17130         * lib/save-cwd.c: Include unistd-safer.h.
17131         (save_cwd): Use fd_safer.
17132         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
17133         [!_LIBC] Include "stat-macros.h" instead.
17134         * lib/unistd-safer.h (fd_safer): New decl.
17135
17136 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17137
17138         * modules/getloadavg (Depends-on): Add unistd-safer.
17139         * modules/getusershell (Depends-on): Add stdio-safer.
17140         * modules/lstat (Depends-on): Remove xalloc.
17141         * modules/mkstemp (Depends-on): Add stat-macros.
17142         * modules/modechange (Depends-on): Remove xstrtol.
17143         Add stat-macros, xalloc.
17144         * modules/save-cwd (Depends-on): Add unistd-safer.
17145         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
17146         * modules/unistd-safer (Files): Add lib/fd-safer.c
17147         (Makefile.am): Remove lib_SOURCES.
17148
17149         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
17150         Remove fcntl-safer; unistd-safer supersedes it.
17151
17152 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17153
17154         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
17155         AC_HEADER_STAT.
17156         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
17157         (gl_PREREQ_CHOWN): Remove.
17158         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
17159         it.  Don't require AC_HEADER_STAT.
17160         (gl_PREREQ_LSTAT): Remove.
17161         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
17162         Don't require AC_HEADER_STAT.
17163         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
17164         (gl_PREREQ_RMDIR): Remove.
17165         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
17166         mention stat-macros.h or AC_HEADER_STAT, since we'll make
17167         the stat-macros module a prerequisite.
17168         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
17169         * m4/filemode.m4 (gl_FILEMODE): Likewise.
17170         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
17171         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
17172         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
17173         variable names.
17174         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
17175         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
17176         variable prefixes.
17177         * m4/fcntl-safer.m4: Remove.
17178         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
17179         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
17180         Invoke gl_PREREQ_FD_SAFER.
17181         (gl_PREREQ_FD_SAFER): New macro.
17182         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
17183         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
17184         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
17185         Remove duplicate call to AC_LIBOBJ(readutmp).
17186         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
17187
17188         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
17189         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
17190
17191 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17192
17193         * MODULES.html.sh (Misc): Add byteswap.
17194
17195 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17196
17197         * modules/getcwd (Depends-on): Add extensions.
17198         * modules/openat (Depends-on): Likewise.
17199
17200 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17201
17202         * modules/byteswap: New file.
17203
17204 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17205
17206         * m4/byteswap.m4: New file.
17207
17208 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17209
17210         * lib/byteswap_.h: New file.
17211
17212 2005-04-25  Karl Berry  <karl@gnu.org>
17213
17214         * m4/gettext.m4: Update from GNU gettext 0.14.4.
17215
17216 2005-04-25  Albert Chin  <china@thewrittenword.com>
17217
17218         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
17219         Toolkit C bug.
17220
17221 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
17222
17223         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
17224         (func_ln_if_changed) Remove forcibly for no error message
17225         in case file does not exist.
17226
17227 2005-04-19  Simon Josefsson  <jas@extundo.com>
17228
17229         * gnulib-tool (Options): Make --symlink mean --symbolic.
17230
17231 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
17232
17233         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
17234
17235 2005-04-16  Simon Josefsson  <jas@extundo.com>
17236
17237         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
17238
17239 2005-04-15  Simon Josefsson  <jas@extundo.com>
17240
17241         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
17242
17243 2005-04-15  Simon Josefsson  <jas@extundo.com>
17244
17245         * gnulib-tool: Rename --symlink to --symbolic.
17246
17247 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
17248
17249         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
17250         symbolic links to files instead of copying/moving.  Add --aux-dir,
17251         specifying directory relative --dir where auxiliary build tools
17252         are placed.
17253
17254 2005-04-14  Bruno Haible  <bruno@clisp.org>
17255
17256         * modules/allocsa (License): Change to LGPL.
17257         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
17258
17259 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
17260
17261         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
17262         that "UTC +1 second" continues to work.  Problem reported
17263         by Dmitry V. Levin.
17264         (relunit_snumber): New rule.
17265         (relunit): Use it.
17266
17267 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
17268
17269         * lib/getdate.y (universal_time_zone_table): New constant.
17270         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
17271         universal_time_zone_table.
17272         (lookup_zone): Prefer universal_time_zone_table to
17273         local_time_zone_table, so that "GMT" time stamps are allowed in
17274         London during the summer.  Problem reported by Ian Abbott.
17275
17276 2005-04-12  Jim Meyering  <jim@meyering.net>
17277
17278         * lib/human.c (humblock): Set *options even when returning due to
17279         xstrtoumax conversion failure.  Thanks to a used-uninitialized
17280         warning from gcc-4.
17281
17282 2005-04-09  Jim Meyering  <jim@meyering.net>
17283
17284         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
17285         -Wuninitialized: initialize tm0.tm_year.
17286
17287 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
17288
17289         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
17290         count, since there's no maximum.  All uses changed.
17291         Add member dsts_seen.
17292         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
17293         not being INT_MAX.
17294         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
17295         Use pc_rels_seen to decide whther a date is absolute.
17296
17297         * lib/getdate.y (number): Don't overwrite year.
17298         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
17299         check.
17300
17301 2005-04-02  Simon Josefsson  <jas@extundo.com>
17302
17303         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
17304         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
17305
17306 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
17307
17308         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
17309         where no absolute path name can be longer than PATH_MAX.
17310
17311 2005-03-27  Jim Meyering  <jim@meyering.net>
17312
17313         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
17314
17315 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
17316
17317         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
17318         "one's complement" -> "ones' complement" in comment, as per Knuth.
17319         "value of type" -> "type or expression" in comment.
17320         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
17321
17322 2005-03-26  Jim Meyering  <jim@meyering.net>
17323
17324         Comment nits.
17325         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
17326         Correct typos: s/or/of/.
17327
17328 2005-03-26  Jim Meyering  <jim@meyering.net>
17329
17330         * modules/check-include-files: Move to ../ and rename to...
17331         * check-module: ...this.
17332
17333 2005-03-25  Jim Meyering  <jim@meyering.net>
17334
17335         * modules/xvasprintf (Files): Add xalloc.h.
17336
17337 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
17338
17339         * modules/gettext (Files): config/config.rpath ->
17340         build-aux/config.rpath
17341         * modules/iconv (Files): Likewise.
17342         Problem reported by Oskar Liljeblad.
17343
17344 2005-03-23  Jim Meyering  <jim@meyering.net>
17345
17346         * modules/check-include-files: New script to check for
17347         missing dependencies, multiple includes, etc.
17348
17349         * modules/c-strtold (Depends-on): Add xalloc.
17350         * modules/c-strtod (Depends-on): Add xalloc.
17351         * modules/hash (Depends-on): Add xalloc.
17352         (Files): Remove lib/xalloc.h.
17353
17354         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
17355         * modules/userspec (Files): Add lib/inttostr.h.
17356
17357 2005-03-23  Jim Meyering  <jim@meyering.net>
17358
17359         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
17360
17361 2005-03-22  Jim Meyering  <jim@meyering.net>
17362
17363         * modules/stat-macros: New module.
17364         * modules/canonicalize, modules/euidaccess, modules/file-type,
17365         * modules/filemode, modules/lchown, modules/makepath,
17366         * modules/rmdir, modules/stat: Depend on new stat-macros module
17367         rather than listing lib/stat-macros.h manually.
17368         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
17369
17370 2005-03-22  Jim Meyering  <jim@meyering.net>
17371
17372         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
17373
17374 2005-03-22  Bruno Haible  <bruno@clisp.org>
17375
17376         * config/srclist.txt: Replace target directory 'config' with
17377         'build-aux'.
17378         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
17379         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
17380         ../build-aux/.
17381
17382 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
17383
17384         * modules/chdir-long (Depends-on): Add mempcpy.
17385
17386         * modules/acl, modules/backupfile, modules/c-strtod,
17387         modules/c-strtold, modules/canon-host, modules/canonicalize,
17388         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
17389         modules/exclude, modules/exitfail, modules/file-type,
17390         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
17391         modules/getdate, modules/getline, modules/getpagesize,
17392         modules/getpass, modules/getugroups, modules/group-member,
17393         modules/hard-locale, modules/hash, modules/human, modules/idcache,
17394         modules/inttostr, modules/long-options, modules/makepath,
17395         modules/md5, modules/memcasecmp, modules/memcoll,
17396         modules/modechange, modules/mountlist, modules/path-concat,
17397         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
17398         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
17399         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
17400         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
17401         modules/strftime, modules/strndup, modules/strverscmp,
17402         modules/timespec, modules/unlocked-io, modules/userspec,
17403         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
17404         modules/yesno:
17405         Remove lib_SOURCES line from Makefile.am section, as this is now
17406         done automatically by the corresponding Autoconf macro.
17407
17408 2005-03-21  Jim Meyering  <jim@meyering.net>
17409
17410         Changes imported from coreutils.
17411
17412         * lib/cycle-check.c: Don't include xalloc.h.
17413
17414         * lib/path-concat.c: Don't include assert.h.
17415         (path_concat): Remove assertion that would have triggered
17416         for ABASE starting with more than one slash.
17417         Reported by Andreas Schwab.
17418
17419         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
17420         properly when ABASE is an absolute file name.
17421         Correct the description of this function.
17422         Include <assert.h>.
17423         Add an assertion and a test driver.
17424         This fixes a bug introduced on 2004-07-02.
17425         Andreas Schwab reported the resulting failure of cp --parents:
17426         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
17427
17428 2005-03-21  Jim Meyering  <jim@meyering.net>
17429
17430         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
17431         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
17432
17433 2005-03-21  Jim Meyering  <jim@meyering.net>
17434         and  Paul Eggert  <eggert@cs.ucla.edu>
17435
17436         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
17437         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
17438         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
17439         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
17440         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
17441         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
17442         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
17443         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
17444         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
17445         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
17446         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
17447         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
17448         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
17449         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
17450         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
17451         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
17452         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
17453         for these modules.
17454
17455 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
17456
17457         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
17458         (which shouldn't happen), generate nothing instead of returning 0
17459         immediately, so that nstrftime (NULL, ...) doesn't return 0.
17460
17461 2005-03-16  Bruno Haible  <bruno@clisp.org>
17462
17463         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
17464         HAVE_LONGLONG_64BIT.
17465
17466 2005-03-16  Bruno Haible  <bruno@clisp.org>
17467
17468         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
17469         HAVE_LONGLONG_64BIT.
17470
17471 2005-03-16  Bruno Haible  <bruno@clisp.org>
17472
17473         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
17474         HAVE_LONGLONG_64BIT.
17475
17476 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
17477
17478         * lib/strftime.c (my_strftime): Prepend space to format so that we can
17479         reliably distinguish strftime failure from empty output on POSIX
17480         hosts.
17481
17482 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
17483
17484         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
17485         (iconv_string): Don't guess a size-zero buffer, as that might cause
17486         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
17487         result would be 'too large', where 'too large' is (heuristically)
17488         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
17489         overflow concerns.  This will prevent some unwanted malloc failures
17490         when the inputs are very large.
17491
17492 2005-03-15  Karl Berry  <karl@gnu.org>
17493
17494         * config/srclist.txt (config.rpath): from gettext.
17495         * config/config.rpath: update.
17496
17497 2005-03-15  Bruno Haible  <bruno@clisp.org>
17498
17499         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
17500         to 'negate'.
17501
17502         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
17503         variable.
17504
17505         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
17506         results.
17507
17508 2005-03-14  Simon Josefsson  <jas@extundo.com>
17509
17510         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
17511         <fx@gnu.org>.
17512
17513 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
17514
17515         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
17516         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
17517         intprops.h.
17518         * lib/strtol.c: Likewise.
17519
17520 2005-03-14  Jim Meyering  <jim@meyering.net>
17521
17522         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
17523         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
17524         to be nonzero so that we (and caller) can detect the difference
17525         between a valid zero-length expansion and an error return, even
17526         when the underlying strftime fails before writing anything into
17527         that location.
17528
17529 2005-03-14  Bruno Haible  <bruno@clisp.org>
17530
17531         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
17532         Update from GNU gettext 0.14.3.
17533
17534 2005-03-10  Jim Meyering  <jim@meyering.net>
17535
17536         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
17537
17538 2005-03-10  Jim Meyering  <jim@meyering.net>
17539
17540         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
17541         so that this module works on systems without fchdir.
17542
17543 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
17544
17545         Factor int-properties macros into a single file, except for
17546         glibc-related files.
17547         * lib/intprops.h: New file.
17548         * lib/getloadavg.c: Include it instead of limits.h.
17549         (INT_STRLEN_BOUND): Remove.
17550         * lib/human.c: Include intprops.h.
17551         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
17552         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
17553         302/1000.
17554         * lib/inttostr.h: Include intprops.h instead of limits.h.
17555         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
17556         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
17557         for consistency with intprops.h.
17558         (time_t_is_integer, twos_complement_arithmetic): Use them.
17559         * lib/sig2str.h: Include <signal.h>, intprops.h.
17560         (INT_STRLEN_BOUND): Remove.
17561         * lib/strftime.c (TYPE_SIGNED): Remove.
17562         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
17563         * lib/strtol.c: Adjust comments to match intprops.h.
17564         * lib/userspec.c: Include intprops.h.
17565         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
17566         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
17567         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
17568         instead of rolling our own expressions.
17569         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
17570
17571         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
17572         instead of int.
17573         (my_strftime): Do not mishandle years close to INT_MAX, by doing
17574         the right thing even if adding 1900 would overflow.  Similarly
17575         for tm_mon + 1 and tm_yday + 1.
17576         Make %Y always equivalent to %C%y, and similarly for %G and %g.
17577         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
17578         (DO_SIGNED_NUMBER): New macro.
17579         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
17580
17581 2005-03-07  Bruno Haible  <bruno@clisp.org>
17582
17583         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
17584
17585 2005-03-07  Bruno Haible  <bruno@clisp.org>
17586
17587         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
17588
17589 2005-03-04  Derek R. Price  <derek@ximbiot.com>
17590
17591         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
17592         (func_import): Only replace files via --import when they have actually
17593         changed.
17594
17595 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17596
17597         * m4/mmap-anon.m4: New file.
17598         * m4/pagealign_alloc.m4: New file.
17599
17600 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17601             Bruno Haible  <bruno@clisp.org>
17602
17603         * modules/pagealign_alloc: New file.
17604         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
17605
17606 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17607             Bruno Haible  <bruno@clisp.org>
17608
17609         * lib/pagealign_alloc.h: New file.
17610         * lib/pagealign_alloc.c: New file.
17611
17612 2005-03-03  Bruno Haible  <bruno@clisp.org>
17613
17614         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
17615         Use an all-permissive copyright notice, recommended by RMS.
17616
17617 2005-03-02  Bruno Haible  <bruno@clisp.org>
17618
17619         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
17620         of AIX, the replacement has to be done only after <string.h> is
17621         included, therefore not in config.h. stpncpy.h does the replacement,
17622         and stpncpy.c uses it.
17623
17624 2005-03-02  Bruno Haible  <bruno@clisp.org>
17625
17626         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
17627         stpncpy.c uses it.
17628
17629 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17630
17631         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
17632         The workaround isn't strictly needed for POSIX conformance, and
17633         it's too much of a pain to configure and maintain.  We'll ask
17634         people to fix their kernels instead.
17635         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
17636         (NANOSLEEP_BUG_WORKAROUND): Remove.
17637         (xnanosleep): Remove the workaround.
17638
17639 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17640
17641         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
17642         Reported by Derek Price.
17643         (Include): Add "timespec.h".
17644
17645         * modules/xnanosleep (Depends-on): Remove gethrxtime.
17646
17647 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17648
17649         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
17650         to detect nanosleep bug.
17651
17652 2005-03-01  Bruno Haible  <bruno@clisp.org>
17653
17654         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
17655
17656 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
17657
17658         * modules/gethrxtime: New file.
17659         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
17660         (Depends-on): Add gethrxtime.
17661         (configure.ac): Add gl_XNANOSLEEP.
17662         (Makefile.am): Remove lib_SOURCES line.
17663
17664 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17665
17666         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
17667         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
17668
17669 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17670
17671         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
17672         * lib/timespec.h (gettime): Return void, since it always
17673         succeeds now.  All uses changed.
17674         * lib/gettime.c (gettime) Likewise.
17675         [HAVE_NANOTIME]: Prefer nanotime.
17676         Assume gettimeofday succeeds, as POSIX requires.
17677         Assime time () succeeds, since other code already does.
17678         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
17679         (timespec_subtract): Remove.
17680         (NANOSLEEP_BUG_WORKAROUND): New constant.
17681         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
17682         things considerably.  Use it only on GNU/Linux hosts, since the
17683         workaround shouldn't be needed elsewhere.
17684
17685 2005-02-24  Bruno Haible  <bruno@clisp.org>
17686
17687         * modules/gettext (Files): Add m4/glibc2.m4.
17688
17689 2005-02-24  Bruno Haible  <bruno@clisp.org>
17690
17691         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
17692         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
17693         * m4/progtest.m4:
17694         Update from GNU gettext 0.14.2.
17695         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
17696
17697 2005-02-24  Bruno Haible  <bruno@clisp.org>
17698
17699         * lib/localcharset.c: Update from GNU gettext 0.14.2.
17700         * lib/config.charset: Update from GNU gettext 0.14.2.
17701
17702 2005-02-24  Bruno Haible  <bruno@clisp.org>
17703
17704         * lib/gettext.h: Update from GNU gettext 0.14.2.
17705
17706 2005-02-23  Simon Josefsson  <jas@extundo.com>
17707
17708         * m4/iconvme.m4: New file.
17709
17710 2005-02-23  Jim Meyering  <jim@meyering.net>
17711
17712         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
17713         change.
17714         Thanks to Bruno Haible for catching it.
17715
17716 2005-02-22  Simon Josefsson  <jas@extundo.com>
17717
17718         * modules/iconvme: New file.
17719
17720         * MODULES.html.sh: Add iconvme.
17721
17722 2005-02-22  Simon Josefsson  <jas@extundo.com>
17723
17724         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
17725
17726 2005-02-22  Simon Josefsson  <jas@extundo.com>
17727
17728         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
17729
17730 2005-02-22  Jim Meyering  <jim@meyering.net>
17731
17732         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
17733         s/ifndef/ifdef/.
17734
17735 2005-02-20  Neil Conway  <neilc@samurai.com>
17736
17737         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
17738         returned by OSX/Darwin if the specified buffer is not large
17739         enough for the hostname.
17740
17741 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17742
17743         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
17744         pass it to _help, otherwise the latter coredumps trying to
17745         dereference state.root_argp.
17746
17747 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17748
17749         * modules/chdir-long (Depends-on): Add memrchr.
17750         * modules/memrchr (Files): Add lib/memrchr.h.
17751         (Include): "memrchr.h".
17752
17753 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17754
17755         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
17756
17757 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17758
17759         * lib/memrchr.h: New file.
17760         * lib/chdir-long.c: Include it.
17761         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
17762         Don't bother including stddef.h.
17763
17764 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
17765
17766         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
17767         inclusion.
17768         Include <sys/types.h>, for dev_t.
17769         (ME_DUMMY, ME_REMOTE): Move from here....
17770         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
17771         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
17772         Dmitry V. Levin.
17773         Include mountlist.h first, to test the interface.
17774
17775 2005-01-29  Bruno Haible  <bruno@clisp.org>
17776
17777         * lib/progname.c (program_name): Initialize.
17778         Needed when linking statically on MacOS X.
17779
17780 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17781
17782         Sync from coreutils.
17783         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
17784         (Depends-on): Add c-strtod.
17785         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
17786
17787 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17788
17789         Sync from coreutils.
17790         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
17791
17792         Remove files that are specific to coreutils.
17793         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
17794
17795 2005-01-28  Bruno Haible  <bruno@clisp.org>
17796
17797         * modules/javacomp: New file.
17798         * MODULES.html.sh (Java): Add javacomp.
17799
17800 2005-01-28  Bruno Haible  <bruno@clisp.org>
17801
17802         * m4/javacomp.m4: New file, from GNU gettext.
17803
17804 2005-01-28  Bruno Haible  <bruno@clisp.org>
17805
17806         * lib/javacomp.sh.in: New file, from GNU gettext.
17807         * lib/javacomp.h: New file, from GNU gettext.
17808         * lib/javacomp.c: New file, from GNU gettext.
17809
17810 2005-01-26  Simon Josefsson  <jas@extundo.com>
17811
17812         * lib/gai_strerror.c: Use GPL in header.
17813
17814 2005-01-26  Bruno Haible  <bruno@clisp.org>
17815
17816         * modules/javaexec: New file.
17817         * MODULES.html.sh (Java): Add javaexec.
17818
17819 2005-01-26  Bruno Haible  <bruno@clisp.org>
17820
17821         * m4/javaexec.m4: New file, from GNU gettext.
17822
17823 2005-01-26  Bruno Haible  <bruno@clisp.org>
17824
17825         * lib/javaexec.sh.in: New file, from GNU gettext.
17826         * lib/javaexec.h: New file, from GNU gettext.
17827         * lib/javaexec.c: New file, from GNU gettext.
17828
17829 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17830
17831         * modules/lchown (Depends-on): Remove lchown.h
17832
17833 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17834
17835         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
17836         must be defined if the header file was not found, in order
17837         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
17838
17839 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17840
17841         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
17842         initializers for struct pentry_state.
17843         (__argp_error): Check return value of __asprintf
17844         (__argp_failure): Translate error message
17845
17846         * lib/argp-parse.c: Removed braces around the expansion of N_()
17847
17848 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
17849
17850         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
17851         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
17852         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
17853         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
17854         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
17855         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
17856         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
17857         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
17858         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
17859         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
17860         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
17861         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
17862         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
17863         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
17864         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
17865         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
17866         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
17867         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
17868         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
17869         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
17870         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
17871         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
17872         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
17873         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
17874         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
17875         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
17876         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
17877         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
17878         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
17879         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
17880         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
17881         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
17882         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
17883         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
17884         xstrtol.m4, xstrtoumax.m4, yesno.m4:
17885         Use an all-permissive copyright notice, recommended by RMS.
17886
17887 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
17888
17889         * modules/chdir-long (Depends-on): Remove mempcpy.
17890
17891 2005-01-21  Jim Meyering  <jim@meyering.net>
17892
17893         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
17894         same value as for Solaris 9.
17895
17896         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
17897         component length.  This included changing the parameter to be
17898         of type `char *' rather than `char const *'.
17899         * lib/chdir-long.h (chdir_long): Update prototype.
17900
17901         * lib/openat.c (fdopendir, fstatat): New functions.
17902         * lib/openat.h: Include headers required for use of DIR and struct
17903         stat.
17904         [AT_SYMLINK_NOFOLLOW]: Define.
17905         (fdopendir, fstatat): Add prototypes.
17906
17907 2005-01-21  Bruno Haible  <bruno@clisp.org>
17908
17909         * modules/classpath: New file.
17910         * MODULES.html.sh (Java): Add classpath.
17911
17912 2005-01-21  Bruno Haible  <bruno@clisp.org>
17913
17914         * lib/classpath.h: New file, from GNU gettext.
17915         * lib/classpath.c: New file, from GNU gettext.
17916
17917 2005-01-20  Simon Josefsson  <jas@extundo.com>
17918
17919         * modules/version-etc-fsf: New file.
17920
17921 2005-01-20  Simon Josefsson  <jas@extundo.com>
17922
17923         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
17924         * lib/version-etc.c: Remove version_etc_copyright.
17925         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
17926         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
17927
17928 2005-01-20  Simon Josefsson  <jas@extundo.com>
17929
17930         * lib/base64.h (isbase64): Add.
17931
17932         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
17933         using a unsigned prototype, don't inline.
17934         (base64_decode): Use it.
17935
17936 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17937
17938         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
17939         it.
17940
17941 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17942
17943         * lib/save-cwd.c (save_cwd): Remove code to support the case
17944         where fchdir is missing or flaky.
17945
17946 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
17947
17948         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
17949
17950 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
17951
17952         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
17953         AC_LIBSOURCES now does this.
17954         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
17955         with new ullong_max module.
17956
17957 2005-01-19  Bruno Haible  <bruno@clisp.org>
17958
17959         * modules/sh-quote: New file.
17960         * MODULES.html.sh (Executing programs): Add sh-quote.
17961
17962 2005-01-19  Bruno Haible  <bruno@clisp.org>
17963
17964         * lib/sh-quote.h: New file, from GNU gettext.
17965         * lib/sh-quote.c: New file, from GNU gettext.
17966
17967 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17968
17969         Merge from coreutils.
17970         * m4/ullong_max.m4: New file.
17971         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
17972         (gl_MACROS): Assume localeconv exists.
17973
17974 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17975
17976         Merge changes from coreutils, as described below in several
17977         changelogs dated today.
17978
17979         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
17980         (O_DIRECTORY): Remove; not needed here, since "." must be
17981         a directory.  All uses removed.
17982         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
17983         universal on Suns, and we also need to test for IRIX.
17984         Revamp code to use 'if' rather than '#if'.
17985         Avoid unnecessary comparison of cwd->desc to 0.
17986
17987         * lib/utimens.c (futimens): Robustify the previous patch, by checking
17988         for known valid error numbers rather than observed invalid ones.
17989
17990 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
17991
17992         * modules/ullong_max: New file.
17993
17994         * modules/chdir-long, modules/openat: New files.
17995         * modules/save-cwd (Depends-on): Depend on chdir-long.
17996         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
17997
17998 2005-01-18  Jim Meyering  <jim@meyering.net>
17999
18000         Merge from coreutils.
18001         * m4/chdir-long.m4, m4/openat.m4: New files.
18002         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
18003         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
18004         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
18005         is sane and DOES follow symlinks.  Besides, testing 20 different
18006         systems found no broken chown implementations.
18007         Prompted by a change in rsync's copy of this macro.
18008         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
18009
18010         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
18011
18012         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
18013         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
18014         NULL-means-set-to-current-time semantics.
18015         Remove temporary file immediately, rather than waiting
18016         for configure's at-exit trap code to do it.
18017
18018 2005-01-18  Jim Meyering  <jim@meyering.net>
18019
18020         * lib/version-etc.c (version_etc_copyright): Update copyright date.
18021
18022         * lib/utimens.c (futimens): Account for the fact that futimes
18023         can also fail with errno == ENOSYS or errno == ENOENT.
18024         Patch from Dmitry V. Levin.
18025
18026         Change the name of the robust chdir function from chdir to chdir_long.
18027         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
18028         (restore_cwd): Use chdir_long, not chdir.
18029         * lib/chdir-long.c: Renamed from chdir.c.
18030         * lib/chdir-long.h: Renamed from chdir.h.
18031         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
18032         Hurd.
18033
18034 2005-01-18  Bruno Haible  <bruno@clisp.org>
18035
18036         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
18037         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
18038         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
18039         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
18040         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
18041         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
18042         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
18043         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
18044         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
18045         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
18046         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
18047         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
18048         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
18049         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
18050         Use an all-permissive copyright notice, recommended by RMS.
18051
18052 2005-01-18  Bob Proulx  <bob@proulx.com>
18053
18054         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
18055         simplify offsetof() macro construct to avoid compile failure with
18056         native HP-UX 11.0 ANSI C compiler.
18057
18058 2005-01-17  Bruno Haible  <bruno@clisp.org>
18059
18060         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
18061         redundant because stpncpy.m4 takes care of it.
18062
18063 2005-01-17  Bruno Haible  <bruno@clisp.org>
18064
18065         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
18066
18067 2005-01-17  Bruno Haible  <bruno@clisp.org>
18068
18069         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
18070         used.
18071
18072 2005-01-17  Bruno Haible  <bruno@clisp.org>
18073
18074         * lib/fwriteerror.h (fwriteerror): Change specification to include
18075         fclose.
18076         * lib/fwriteerror.c: Include <stdbool.h>.
18077         (fwriteerror): At the end, close the file stream. Record whether
18078         stdout was already closed.
18079
18080 2005-01-17  Bruno Haible  <bruno@clisp.org>
18081
18082         * lib/execute.c (environ): Declare if needed.
18083         * lib/pipe.c (environ): Likewise.
18084         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
18085
18086 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18087
18088         * modules/argp: Depend on vsnprintf
18089
18090 2005-01-10  Jim Meyering  <jim@meyering.net>
18091
18092         * modules/closeout (Depends-on): Add atexit.
18093
18094 2005-01-06  Bruno Haible  <bruno@clisp.org>
18095
18096         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
18097
18098 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
18099
18100         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
18101         definitions to be after all include files, to avoid collisions.
18102         Problem reported by Bob Proulx.
18103
18104 2005-01-04  Jim Meyering  <jim@meyering.net>
18105
18106         Changes imported from coreutils.
18107         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
18108         as the mkstemp template, use a temporary directory and an
18109         8.3-friendly template to avoid trouble on systems like DJGPP.
18110         Reported by Juan M. Guerrero via Stepan Kasal.
18111         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
18112         close. Remove the temporary directory right away, rather than waiting
18113         for configure's at-exit trap code to do it.
18114         Suggestion from Stepan Kasal.
18115
18116 2005-01-01  Simon Josefsson  <jas@extundo.com>
18117
18118         * gnulib-tool: Print #include directives when --import'ing.
18119
18120 2004-12-28  Simon Josefsson  <jas@extundo.com>
18121
18122         * tests/test-base64.c: Include required header files.  Remove
18123         unused variables.
18124
18125 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
18126
18127         * modules/error (Depends-on): Remove gettext.
18128
18129 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
18130
18131         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
18132         not needed.  This removes a dependency on the gettext module.
18133         [defined _LIBC]: Do not include <libintl.h>; not needed.
18134
18135 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
18136
18137         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
18138         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
18139
18140 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
18141
18142         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
18143         HAVE_DECL_STRTOLD.
18144
18145 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18146
18147         * modules/getdate (Depends-on): Remove alloca-opt.
18148
18149 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18150
18151         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
18152
18153 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18154
18155         * lib/argp-parse.c: Include <stddef.h>.
18156         (alignof, alignto): New macros.
18157         (parser_init): Don't assume that void * is aligned sufficiently
18158         for struct option.
18159
18160         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
18161         need to extend the stack.
18162         (YYINITDEPTH): New macro, so that the initial stack isn't overly
18163         large.
18164
18165 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18166
18167         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
18168
18169 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
18170
18171         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
18172         (2004-10-24) change.  Apparently this was a false alarm.
18173
18174         * modules/getdate: Depend on alloca-opt, not alloca.
18175
18176 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
18177
18178         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
18179         Remove now-obsolete comment about AIX.
18180         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
18181         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
18182         (YYMAXDEPTH): New macro.
18183
18184 2004-12-18  Simon Josefsson  <jas@extundo.com>
18185
18186         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
18187
18188 2004-12-18  Bruno Haible  <bruno@clisp.org>
18189
18190         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
18191
18192 2004-12-18  Bruno Haible  <bruno@clisp.org>
18193
18194         * lib/fatal-signal.c (fatal_signals): Make non-const.
18195         (init_fatal_signals): New function.
18196         (uninstall_handlers, install_handlers): Ignore signals that were set to
18197         SIG_IGN.
18198         (at_fatal_signal): Call init_fatal_signals.
18199         (init_fatal_signal_set): Likewise. Ignore signals that were set to
18200         SIG_IGN.
18201         Reported by Paul Eggert.
18202
18203 2004-12-18  Bruno Haible  <bruno@clisp.org>
18204
18205         * doc/alloca.texi: New file.
18206         * doc/alloca-opt.texi: New file.
18207
18208 2004-12-17  Jim Meyering  <jim@meyering.net>
18209
18210         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
18211         Otherwise, install-sh could exit with improper exit status when
18212         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
18213
18214 2004-12-16  Simon Josefsson  <jas@extundo.com>
18215
18216         * tests/test-base64.c: Add license.
18217
18218 2004-12-15  Stepan Kasal  <address@hidden>
18219
18220         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
18221
18222 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
18223
18224         * modules/getcwd (Files): Add m4/d-ino.m4.
18225         Suggested by Mark D. Baushke.
18226
18227 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
18228
18229         * lib/getdate.y (textint): New member "negative".
18230         (time_zone_hhmm): New function.
18231         Expect 14 shift-reduce conflicts, not 13.
18232         (o_colon_minutes): New rule.
18233         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
18234         (yylex): Set the "negative" member of signed numbers.
18235
18236 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
18237
18238         * doc/getdate.texi (Time of day items, Time zone items):
18239         Describe new formats +00:00, UTC+00:00.
18240
18241 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
18242
18243         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
18244         spurious "-l"s.  Problem reported by Stepan Kasal.
18245
18246 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
18247
18248         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
18249         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
18250
18251 2004-12-04  Simon Josefsson  <jas@extundo.com>
18252
18253         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
18254         Vandoorselaere <yoann@prelude-ids.org>.
18255
18256 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
18257
18258         Changes imported from coreutils.
18259         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
18260         exist.
18261         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
18262
18263 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
18264
18265         Changes imported from coreutils.
18266         * lib/hard-locale.c: Assume <locale.h> exists.
18267         Include "strdup.h".
18268         (GLIBC_VERSION): New macro.
18269         (hard_locale): Assume setlocale exists.
18270         Rewrite to avoid #ifdef.
18271         Use strdup rather than malloc + strcpy.
18272         * lib/human.c: Assume <locale.h> exists.
18273         (human_readable): Assume localeconv exists.
18274
18275 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
18276
18277         * modules/hard-locale (Depends-on): Add strdup.
18278
18279 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
18280
18281         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
18282         convert T2, not T.  (Imported from libc.)
18283
18284 2004-11-30  Simon Josefsson  <jas@extundo.com>
18285
18286         * modules/restrict (License): Change to LGPL.
18287
18288 2004-11-30  Simon Josefsson  <jas@extundo.com>
18289
18290         * m4/restrict.m4: Add copyright and copying conditions.
18291
18292 2004-11-30  Simon Josefsson  <jas@extundo.com>
18293
18294         * m4/base64.m4: New file.
18295
18296 2004-11-30  Simon Josefsson  <jas@extundo.com>
18297
18298         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
18299         base64.
18300
18301         * tests/test-base64.c: New file.
18302
18303         * modules/base64: New file.
18304
18305 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
18306
18307         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
18308         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
18309
18310         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
18311
18312 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
18313
18314         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
18315         (__getcwd.c): Don't restore errno; glibc doesn't.
18316         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
18317         first, falling back to our code only if its results look suspicious.
18318         Ensure that the resulting buffer is only as large as necessary.
18319
18320         * lib/readutmp.c: Include readutmp.h first.
18321         Include <errno.h>, since readutmp.h no longer does that.
18322         * lib/readutmp.h: Don't include <errno.h>,
18323         <sys/param.h>, <time.h>; not needed to establish interface.
18324         (errno): Remove decl.
18325         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
18326         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
18327         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
18328
18329 2004-11-28  Simon Josefsson  <jas@extundo.com>
18330
18331         * lib/base64.h, base64.c: New file.
18332
18333 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
18334
18335         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
18336
18337 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
18338
18339         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
18340         (Depends-on): Remove pathmax, same.  Add mempcpy.
18341         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
18342         (Makefile.am): Append getcwd.h to lib_SOURCES.
18343         (Include): Add getcwd.h.
18344         (Maintainer): Change from Jim Meyering to "all, glibc",
18345         since getdate now uses intended-for-glibc code.
18346         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
18347         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
18348
18349 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
18350
18351         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
18352         HP's ANSI C compiler.
18353         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
18354         Declaring int functions causes warnings on some modern systems and
18355         shouldn't be needed to compile on ancient ones.
18356         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
18357         defined.
18358
18359         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
18360         with the following changes.
18361         (__set_errno): Parenthesize properly.
18362         Include <stdbool.h>.
18363         (MIN, MAX, MATCHING_INO): New macros.
18364         (__getcwd): Define with prototype, not K&R form.
18365         Use heuristics to allocate default buffer on stack if possible.
18366         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
18367         behavior, and to avoid the PATH_MAX limit when computing
18368         ../../../../...
18369         Use MATCHING_INO to compare inode number to file.
18370         Check for arithmetic overflow in size calculations.
18371         Fix bug in reallocation of dot array that caused getcwd to fail
18372         on directories nested deeper than 75.
18373         Be more careful about saving errno on error.
18374         Do not use realloc; use only free+malloc, as this is a bit
18375         more flexible and avoids a needless copy operation.
18376         Do not inspect st_dev and st_ino for symbolic links; POSIX
18377         doesn't specify the latter.
18378         Check for closedir errors.
18379         Avoid needless casts.
18380         Use "#ifdef weak_alias" around weak_alias, to be like other
18381         glibc code.
18382         The following changes to getcwd.c have effect only when used in
18383         gnulib; they have no effect inside glibc proper.
18384         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
18385         as alloca isn't used.
18386         (alloca, __alloca): Likewise.
18387         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
18388         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
18389         unconditionally, as gnulib assumes C89 or better.
18390         Do not include <sys/param.h>.
18391         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
18392         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
18393         better.
18394         (NULL) [!defined NULL]: Remove; we assume C89 or better.
18395         Include <dirent.h> in a way that is compatible with modern Autoconf.
18396         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
18397         New macros, if not already defined.
18398         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
18399         Use "_LIBC", not "defined _LIBC", for consistency.
18400         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
18401         a mempcpy module.
18402         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
18403         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
18404         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
18405         credit only to Jim Meyering and adjust the copyright dates.
18406         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
18407         <stdlib.h>, <unistd.h>, "pathmax.h".
18408         Instead, include "xgetcwd.h" (first) and "getcwd.h".
18409         (INITIAL_BUFFER_SIZE): Remove.
18410         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
18411
18412 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
18413
18414         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
18415         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
18416         Use the _ONCE methods, for efficiency.
18417         Check for fcntl.h.  In test program, include <errno.h>
18418         and <fcntl.h> if available.  Remove old K&R cruft from
18419         test program.  Check for common errors in GNU/Linux,
18420         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
18421         don't do AC_LIBOBJ, as that's getcwd.m4's job.
18422         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
18423         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
18424         name accordingly.
18425         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
18426         accommodate new getcwd.c.
18427         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
18428         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
18429         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
18430         that's all we need now.
18431
18432 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18433
18434         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
18435         argp-parse.c depends on getopt internals, that means we should
18436         always use our getopt, to be on the safe side.
18437         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
18438         order not to spoil the result of an eventual previous invocation
18439         of gl_GETOPT_SUBSTITUTE.
18440
18441 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18442
18443         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
18444         redefinition warnings. To avoid them, include the defines
18445         in `#if !defined __need_getopt ... #endif'. The only place
18446         where __getopt_argv_const is used is in definitions
18447         of getopt_long and getopt_long_only below, which are as well
18448         protected by `#ifndef __need_getopt'.
18449         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
18450         __need_getopt after including <stdio.h> and <unistd.h> These
18451         headers might have defined it.
18452
18453 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
18454
18455         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
18456
18457 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
18458
18459         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
18460         (futimens): New function, which uses futimes if available.
18461         (futimens, utimens): Support timespec==NULL, with same semantics
18462         as utime and utimens.
18463         * lib/utimens.h (futimens): New decl.
18464
18465 2004-11-23  Jim Meyering  <jim@meyering.net>
18466
18467         * lib/getopt_.h: Remove trailing blanks.
18468
18469 2004-11-23  Jim Meyering  <jim@meyering.net>
18470
18471         * lib/__fpending.c: Add comment.
18472
18473 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
18474
18475         * modules/canonicalize (Depends-on): Add xreadlink.
18476         Problem reported by James Youngman.
18477
18478 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
18479
18480         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
18481         New macros.
18482         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
18483         optopt): Use them instead of invoking ## directly; otherwise, the
18484         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
18485
18486 2004-11-19  Bruno Haible  <bruno@clisp.org>
18487
18488         * lib/strtok_r.c: Move comments from here...
18489         * lib/strtok_r.h: ... to here.
18490
18491 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
18492
18493         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
18494         implementations that mishandle size_t overflow.
18495
18496 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
18497
18498         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
18499         might fail.  Problem reported by Yoann Vandoorselaere.
18500         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
18501         implementations that mishandle size_t overflow.
18502
18503 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18504
18505         * modules/canon-host (Depends-on): Add strdup.
18506
18507 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18508
18509         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
18510
18511 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18512
18513         * lib/canon-host.c: Include "strdup.h".
18514         (canon_host): Use getaddrinfo if available, so that IPv6 works.
18515         Use strdup instead of malloc/strcpy to duplicate strings.
18516
18517         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
18518         (human_space_before_unit): New constant.
18519         * lib/human.c (human_readable): Support it.
18520
18521         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
18522         (xgetcwd): Set errno correctly when failing.
18523         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
18524         the failure is actually due to a PATH_MAX problem.
18525
18526         Further getopt changes to make it more likely that glibc will
18527         buy the changes back.
18528         * lib/getopt.c (POSIXLY_CORRECT): New constant.
18529         (getopt): Use it, so to preserve glibc semantic
18530         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
18531         when compiling for libc.
18532         * lib/getopt_.h (__getopt_argv_const): Bring it back.
18533         (getopt_long, getopt_long_only): Use it.
18534
18535         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
18536         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
18537         (getopt): Argv is now char * const *, as per standard.
18538         (_getopt_internal_r, _getopt_internal): Argv is now char **,
18539         not char *__getopt_argv_const *.
18540         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
18541         _getopt_long_only_r): Likewise.
18542         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
18543         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
18544         _getopt_long_r, _getopt_long_only_r): Likewise.
18545         * lib/getopt_.h (__getopt_argv_const): Remove.
18546         (getopt): Argv is now char * const *, as per standard.
18547
18548         * lib/getdate.y (tORDINAL): New token.
18549         (day, relunit): Allow it for relative times.
18550         (relative_time_table): Use tORDINAL for ordinals.
18551
18552 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18553
18554         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
18555         Document that "second" isn't allowed as an ordinal number.
18556
18557 2004-11-16  Jim Meyering  <jim@meyering.net>
18558
18559         * modules/closeout (Depends-on): Add fpending.
18560
18561 2004-11-15  Jim Meyering  <jim@meyering.net>
18562
18563         * lib/closeout.c: Include "__fpending.h" once again.
18564         Include <stdbool.h>.
18565         (close_stdout): Don't fail just because stdout was closed initially,
18566         since some programs don't write to stdout in the normal course of
18567         operation (other than --version and --help), and we don't want this
18568         function to make e.g. `touch file >&-' fail.
18569         But do fail if it was closed and someone has tried to write to it.
18570         E.g., `printf foo >&-' must fail.
18571
18572 2004-11-13  Jim Meyering  <jim@meyering.net>
18573
18574         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
18575
18576 2004-11-12  Simon Josefsson  <jas@extundo.com>
18577
18578         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
18579         small doc fix is still pending.
18580
18581 2004-11-11  Simon Josefsson  <jas@extundo.com>
18582
18583         * modules/strtok_r: New file.
18584
18585         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18586         strtok_r.
18587
18588 2004-11-11  Simon Josefsson  <jas@extundo.com>
18589
18590         * m4/strtok_r.m4: New file.
18591
18592         * m4/getopt.m4: Replace opterr.
18593
18594 2004-11-11  Simon Josefsson  <jas@extundo.com>
18595
18596         * lib/strtok_r.h, strtok_r.c: New file.
18597
18598 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
18599
18600         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
18601         of replacing opterr, getopt, etc.  This should handle the
18602         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
18603
18604 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
18605
18606         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
18607         we can stop lying to compilers about the constness of argv when we
18608         are compiled outside glibc.
18609         (getopt, getopt_long, getopt_long_only): Use it.
18610         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
18611         _getopt_internal, getopt): Likewise.
18612         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
18613         _getopt_long_only_r): Likewise.
18614         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
18615         _getopt_long_r, _getopt_long_only_r): Likewise.
18616
18617         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
18618         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
18619         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
18620         the other external symbols.
18621         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
18622         declaration, since the above renaming now works around collisions.
18623
18624 2004-11-11  Jim Meyering  <jim@meyering.net>
18625
18626         * lib/linebreak.c: Remove trailing blanks.
18627         * lib/alloca_.h: Likewise.
18628         * lib/acosl.c: Likewise.
18629         * lib/euidaccess.c: Likewise.
18630         * lib/allocsa.h: Likewise.
18631
18632 2004-11-10  Simon Josefsson  <jas@extundo.com>
18633
18634         * m4/getaddrinfo.m4: New file.
18635
18636 2004-11-10  Simon Josefsson  <jas@extundo.com>
18637
18638         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
18639
18640 2004-11-10  Simon Josefsson  <jas@extundo.com>
18641
18642         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18643         getaddrinfo.
18644
18645         * modules/getaddrinfo: New file.
18646
18647 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18648
18649         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
18650
18651 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18652
18653         * lib/mktime.c (SHR): New macro, which is a portable
18654         substitute for >> that should work even on Crays.
18655         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
18656         Problem reported by Mark D. Baushke in
18657         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
18658         * lib/getdate.y (SHR): Likewise.
18659         (tm_diff): Use it.
18660         * lib/strftime.c (SHR): Likewise.
18661         (tm_diff): Use it.
18662         * lib/quotearg.c (struct quoting_options): Use unsigned int for
18663         quote_these_too, so that right shifts are well defined.  All uses
18664         changed.
18665
18666 2004-11-10  Jim Meyering  <jim@meyering.net>
18667
18668         Ensure that no close failure goes unreported.
18669         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
18670         return early when it seems there's nothing to flush.
18671         Don't include __fpending.h.
18672
18673 2004-11-10  Jim Meyering  <jim@meyering.net>
18674
18675         * modules/closeout (Depends-on): Remove fpending.
18676
18677 2004-11-10  Jim Meyering  <jim@meyering.net>
18678
18679         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
18680
18681 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18682
18683         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
18684         gl_FUNC_STRFTIME.
18685         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
18686         and AC_REQUIRE when possible, to avoid duplicate checks.
18687         Check for <wchar.h>.
18688
18689 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18690
18691         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
18692
18693 2004-11-09  Bruno Haible  <bruno@clisp.org>
18694
18695         * m4/sockpfaf.m4: New file.
18696
18697 2004-11-05  Bruno Haible  <bruno@clisp.org>
18698
18699         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
18700         Reported by Mark D. Baushke <mdb@cvshome.org>.
18701
18702 2004-11-04  Bruno Haible  <bruno@clisp.org>
18703
18704         2004-09-11  Bruno Haible  <bruno@clisp.org>
18705                 * allocsa.valgrind: New file.
18706         2004-02-06  Bruno Haible  <bruno@clisp.org>
18707                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
18708                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
18709                 Reported by Christopher Seip <chris.seip@hp.com>.
18710
18711 2004-11-04  Bruno Haible  <bruno@clisp.org>
18712
18713         * modules/allocsa (Files): Add lib/allocsa.valgrind.
18714         (Makefile.am): Distribute it.
18715
18716 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
18717
18718         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
18719         with errno == ERANGE if the buffer is too small.
18720         Problem reported by Mark D. Baushke.
18721
18722 2004-11-03  Albert Chin  <china@thewrittenword.com>
18723             Paul Eggert  <eggert@cs.ucla.edu>
18724
18725         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
18726         equivalent, substitute $ac_type for equivalent type rather than
18727         blindly using uint32_t *always* which won't work if uint32_t is not
18728         available.  Define _UINT32_T to work around typedef of uint32_t if
18729         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
18730         2.5.1.
18731
18732 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18733
18734         * m4/jm-macros.m4: Sync from coreutils.
18735         (gl_MACROS): Check for mbrlen, for pathchk.
18736         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
18737
18738 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18739
18740         * lib/xreadlink.c (MAXSIZE): New macro.
18741         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
18742         size does not exceed MAXSIZE.  Avoid cast.
18743         As suggested by Mark D. Baushke in
18744         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
18745         if readlink fails with buffer size just under MAXSIZE, try again
18746         with MAXSIZE.
18747
18748 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18749
18750         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
18751
18752 2004-11-02  Derek R. Price  <derek@ximbiot.com>
18753         and  Paul Eggert  <eggert@cs.ucla.edu>
18754
18755         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
18756         (get_date): Overparenthesize to avoid GCC warning.
18757
18758 2004-11-02  Bruno Haible  <bruno@clisp.org>
18759
18760         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
18761         returns void.
18762
18763 2004-11-02  Bruno Haible  <bruno@clisp.org>
18764
18765         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
18766         function returns void.
18767
18768 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18769
18770         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
18771         fflush_unlocked, flockfile, funlockfile, funlockfile,
18772         fputs_unlocked, putc_unlocked.
18773
18774 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18775
18776         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
18777         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
18778         already declared.
18779
18780 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18781
18782         * modules/getdate (Files): Add doc/getdate.texi.
18783         (Depends-on): Add setenv, xalloc.
18784
18785 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18786
18787         * lib/getdate.y: Add support for TZ="foo" within a date string.
18788         Fix some bugs near time_t boundaries.  Reject dates with
18789         out-of-range components, e.g., "Sept 31".
18790         Include <stdlib.h>, "setenv.h", "xalloc.h".
18791         (ISDIGIT_LOCALE): Remove; unused.
18792         Note that the TZ and time functions used here are not reentrant.
18793         (mktime_ok, get_tz): New functions.
18794         (TZBUFSIZE): New constant.
18795         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
18796         This requires that we sometimes generate our own TZ="XXX..." setting.
18797
18798 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18799
18800         * doc/getdate.texi: New file, from coreutils with modifications for
18801         the new TZ parsing.
18802
18803 2004-10-27  Derek R. Price  <derek@ximbiot.com>
18804
18805         * lib/mktime.c (not_equal_tm): Remove redundant check.
18806
18807 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18808
18809         * modules/regex (lib_SOURCES): Add regex.c.
18810         Reported by James Youngman in
18811         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
18812
18813 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18814
18815         * lib/getdate.y: Use Bison 1.875 features, and some minor
18816         code cleanups.  This change does not affect semantics.
18817         Don't include <stdlib.h>; no longer needed.
18818         Don't include unlocked-io.h; only the "#if TEST" code uses
18819         stdio, and performance isn't crucial there.
18820         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
18821         Bison 1.875 features as described below.
18822         All uses of "PC." replaced by "pc->".
18823         (YYSTYPE): Add a forward declaration.
18824         (yylex, yyerror): Use full prototypes in forward decls.
18825         Use "%pure-parser" rather than obsolescent "%pure_parser".
18826         Use %parse-param and %lex-param instead of obsolescent
18827         YYPARSE_PARAM and YYLEX_PARAM.
18828         (meridian_table, month_and_day_table, time_units_table,
18829         relative_time_table, time_zone_table, military_table,
18830         lookup_zone, lookup_word, get_date):
18831         Use NULL instead of 0 where appropriate.
18832         (to_hour): Avoid abort (), to avoid a dependency on
18833         stdlib.h.
18834         (yyerror, yylex): Now accepts parser_control * arg.
18835         (main) [TEST]: Use '\0' rather than 0 for char.
18836
18837 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
18838
18839         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
18840
18841 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
18842
18843         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
18844         It's now the caller's responsibility to handle the case where
18845         !HAVE_GETPAGESIZE && !defined getpagesize.
18846
18847         * lib/mktime.c (leapyear): Arg is long int, not int.
18848
18849 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
18850
18851         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
18852
18853 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
18854
18855         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
18856         missing.  Problem reported by James Youngman.
18857
18858 2004-10-16  Simon Josefsson  <jas@extundo.com>
18859
18860         * gnulib-tool: Fix comments.  Fix parse problem.
18861         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
18862
18863 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
18864
18865         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
18866         implementation of getopt_long.  Problem reported by Alexander Taler in:
18867         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
18868
18869 2004-10-15  Bruno Haible  <bruno@clisp.org>
18870
18871         * gnulib-tool: Untabify. Initialize supplied_libname.
18872         (func_usage): More homogenous output.
18873         (func_modules_transitive_closure, func_modules_to_filelist,
18874         func_emit_lib_Makefile_am): New functions.
18875         (func_import): New function, extracted from big case statement. Use
18876         func_get_license, func_modules_transitive_closure,
18877         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
18878         opt_lgpl. Don't use test -a, as it's not portable.
18879         (func_create_testdir): Use func_modules_transitive_closure,
18880         func_modules_to_filelist, func_emit_lib_Makefile_am.
18881
18882 2004-10-15  Bruno Haible  <bruno@clisp.org>
18883
18884         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
18885
18886 2004-10-15  Bruno Haible  <bruno@clisp.org>
18887
18888         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
18889         the portions belonging to each module.
18890         Suggested by Derek Robert Price <derek@ximbiot.com>.
18891
18892 2004-10-12  Simon Josefsson  <jas@extundo.com>
18893
18894         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
18895         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
18896         to real functions.
18897
18898 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18899
18900         * modules/vsnprintf: New file.
18901
18902 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18903
18904         * m4/vsnprintf.m4: New file.
18905
18906 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
18907
18908         * lib/vsnprintf.h: New file.
18909         * lib/vsnprintf.c: New file.
18910
18911 2004-10-11  Bruno Haible  <bruno@clisp.org>
18912
18913         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
18914         vsnprintf.
18915
18916 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
18917
18918         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
18919
18920 2004-10-07  Bruno Haible  <bruno@clisp.org>
18921
18922         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
18923         fits into the provided buffer.
18924
18925 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
18926
18927         * lib/diacrit.c, diacrit.h: Add GPL notice.
18928
18929         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
18930         notice.
18931         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
18932         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
18933         This avoids a potential constant-folding bug.
18934
18935 2004-10-05  Bruno Haible  <bruno@clisp.org>
18936
18937         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
18938         for the declaration of strsep.
18939
18940 2004-10-05  Bruno Haible  <bruno@clisp.org>
18941
18942         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
18943
18944 2004-10-04  Simon Josefsson  <jas@extundo.com>
18945
18946         * modules/memmem: New file.
18947         * tests/test-memmem.c: New file.
18948         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
18949
18950 2004-10-04  Simon Josefsson  <jas@extundo.com>
18951
18952         * m4/memmem.m4: New file.
18953
18954 2004-10-04  Simon Josefsson  <jas@extundo.com>
18955
18956         * lib/memmem.h: New file.
18957         * lib/memmem.c: New file, taken from glibc.
18958
18959 2004-10-04  Simon Josefsson  <jas@extundo.com>
18960
18961         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
18962         '#ifdef USE_UNLOCKED_IO'.
18963
18964 2004-10-04  Simon Josefsson  <jas@extundo.com>
18965
18966         * config/srclist.txt: Add memmem from glibc.
18967
18968 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18969
18970         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
18971
18972         * modules/argmatch, modules/argp, modules/closeout, modules/error,
18973         modules/exclude, modules/getdate, modules/getline,
18974         modules/getndelim2, modules/getpass, modules/getpass-gnu,
18975         modules/getusershell, modules/linebuffer, modules/md5,
18976         modules/mountlist, modules/posixtm, modules/readtokens,
18977         modules/readutmp, modules/regex, modules/sha1,
18978         modules/version-etc, modules/yesno:
18979         Remove dependency on unlocked-io.
18980
18981 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18982
18983         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
18984
18985         * m4/unlocked-io.m4: Add copyright notice.
18986         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
18987
18988 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
18989
18990         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
18991         * lib/xmalloc.c (xmemdup): Likewise.
18992         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
18993         XFREE): Remove these long-obsolescent macros.
18994         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
18995         * lib/xstrdup.c: Remove.
18996
18997         * lib/regex.c (re_comp): Cast gettext return value to char *,
18998         Problem reported by Martin Neitzel via Mark D. Baushke.
18999
19000 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19001
19002         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
19003         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
19004         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
19005         regex.c, sha1.c, version-etc.c, yesno.c:
19006         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
19007         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
19008         the includer's responsibility.
19009
19010         Sync from coreutils.
19011
19012         * lib/modechange.c (mode_compile): Don't decrement a pointer that
19013         points to the start of a string, as the C Standard says the
19014         resulting behavior is undefined.
19015
19016         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
19017         simple -> simple_backups, numbered_existing ->
19018         numbered_existing_backups, numbered -> numbered_backups
19019         to avoid shadowing problems.  All uses changed.
19020         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
19021         * lib/backupfile.c (check_extension, numbered_backup):
19022         Rename locals to avoid shadowing 'basename'.
19023         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
19024         once.
19025
19026         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
19027         * lib/.cvsignore: Add getopt.h.
19028
19029 2004-10-04  Bruno Haible  <bruno@clisp.org>
19030
19031         * modules/README: New file.
19032         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
19033         not a module.
19034
19035 2004-10-02  Jim Meyering  <jim@meyering.net>
19036
19037         * lib/dirfd.h, getpagesize.h: Add copyright notice.
19038
19039 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19040
19041         * modules/strsep: New file.
19042
19043 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19044
19045         * m4/strsep.m4: New file.
19046
19047 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19048
19049         * lib/strsep.h: New file.
19050         * lib/strsep.c: New file.
19051
19052 2004-10-01  Simon Josefsson  <jas@extundo.com>
19053
19054         * lib/snprintf.c (snprintf): Handle size==0.
19055
19056 2004-10-01  Simon Josefsson  <jas@extundo.com>
19057             Bruno Haible  <bruno@clisp.org>
19058
19059         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
19060         (snprintf): Declare 'args'.
19061
19062 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
19063
19064         * lib/snprintf.c: Remove comments as to why each header is needed.
19065
19066 2004-10-01  Bruno Haible  <bruno@clisp.org>
19067
19068         * MODULES.html.sh: Add strsep.
19069
19070 2004-09-30  Simon Josefsson  <jas@extundo.com>
19071
19072         * modules/snprintf: New file.
19073
19074 2004-09-30  Simon Josefsson  <jas@extundo.com>
19075
19076         * m4/snprintf.m4: New file.
19077
19078 2004-09-30  Simon Josefsson  <jas@extundo.com>
19079
19080         * lib/snprintf.h, lib/snprintf.c: New files.
19081
19082 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19083
19084         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
19085         (hol_entry_help): Never translate an empty string.
19086         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
19087         * lib/argp.h (OPTION_NO_TRANS): New option.
19088
19089 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19090
19091         * modules/argp (Maintainer): Replace Simon Josefsson
19092         by Sergey Poznyakoff.
19093
19094 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19095
19096         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
19097         changes merged back into glibc.
19098
19099 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19100
19101         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
19102
19103 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
19104
19105         * lib/xvasprintf.c: Include xalloc.h.
19106         (xvasprintf): Use xalloc_die, not xmalloc_die.
19107
19108 2004-09-29  Bruno Haible  <bruno@clisp.org>
19109
19110         * modules/alloca-opt: New file, derived from modules/alloca.
19111         * modules/allocsa: Depend on alloca-opt instead of alloca.
19112         * modules/setenv: Likewise.
19113         * modules/vasnprintf: Likewise.
19114         * MODULES.html.sh: Add alloca-opt.
19115
19116 2004-09-28  Simon Josefsson  <jas@extundo.com>
19117
19118         * gnulib-tool: New parameter --lgpl, to asseert that modules are
19119         LGPL, and to replace license template from GPL to LGPL.
19120
19121 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
19122
19123         * modules/dummy: Change license to LGPL.
19124
19125 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
19126
19127         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
19128
19129 2004-09-24  Simon Josefsson  <jas@extundo.com>
19130
19131         * modules/minmax (License): Change from GPL to LGPL.
19132
19133 2004-09-23  Simon Josefsson  <jas@extundo.com>
19134
19135         * gnulib-tool (--import): Typo.
19136
19137 2004-09-23  Simon Josefsson  <jas@extundo.com>
19138
19139         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
19140
19141 2004-09-22  Bruno Haible  <bruno@clisp.org>
19142
19143         * modules/*: Add 'License' field.
19144         * gnulib-tool: Accept --extract-license option.
19145         (func_get_license): New function.
19146
19147 2004-09-21  Bruno Haible  <bruno@clisp.org>
19148
19149         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
19150         Reported by Simon Josefsson.
19151
19152 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
19153
19154         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
19155         gl_AC_TYPE_LONG_LONG.
19156
19157 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
19158
19159         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
19160
19161 2004-09-18  Simon Josefsson  <jas@extundo.com>
19162         and  Paul Eggert  <eggert@cs.ucla.edu>
19163
19164         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
19165         calls with autoreconf.  Define GL_LIB.
19166
19167 2004-09-14  Karl Berry  <karl@gnu.org>
19168
19169         * config/srclist.txt: unsync setenv.c, sigh.
19170
19171 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19172
19173         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
19174         Problem reported by Bruno Haible in:
19175         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
19176
19177 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19178
19179         * config/srclist.txt: Comment out argp-pvh.c.
19180
19181 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
19182
19183         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
19184         in case some system header has #define'd it.  Problem reported by
19185         Soeren D. Schulze in
19186         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
19187
19188 2004-09-09  Karl Berry  <karl@gnu.org>
19189
19190         * regex.[ch]: delete from the root.  These were supposed to be
19191                 synced with emacs cvs, but this has not happened for about
19192                 a year, and anyway nothing else uses emacs regex.[ch].
19193                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
19194                 lib/regex[.ch] is untouched.
19195
19196 2004-09-09  Bruno Haible  <bruno@clisp.org>
19197
19198         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
19199
19200 2004-09-09  Bruno Haible  <bruno@clisp.org>
19201
19202         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
19203         modifications.
19204         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
19205
19206 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
19207
19208         * modules/xvasprintf: New file.
19209         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
19210
19211 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
19212
19213         * lib/xvasprintf.h: New file.
19214         * lib/xvasprintf.c: New file.
19215         * lib/xasprintf.c: New file.
19216
19217 2004-09-08  Bruno Haible  <bruno@clisp.org>
19218
19219         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
19220
19221 2004-09-08  Bruno Haible  <bruno@clisp.org>
19222
19223         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
19224         length is > INT_MAX.
19225         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
19226         more.
19227
19228 2004-09-08  Bruno Haible  <bruno@clisp.org>
19229
19230         * lib/stdint_.h: New file, taken from GNU clisp.
19231
19232 2004-09-08  Bruno Haible  <bruno@clisp.org>
19233             Oskar Liljeblad  <oskar@osk.mine.nu>
19234
19235         * modules/stdint: New file.
19236         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
19237
19238 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
19239
19240         Import from coreutils.
19241         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
19242         strings on unbounded length.  alloca's performance benefits aren't
19243         that important here.
19244         (V_STRDUP): Remove.
19245         (parse_with_separator): New function, with most of the internals
19246         of the old parse_user_spec.  Allow user to omit both user and group,
19247         for compatibility with FreeBSD.
19248         Clone only the user name, not the entire spec.
19249         Do not set *uid, *gid unless entirely successful.
19250         Avoid memory leak in some failing cases.
19251         Fix regression for USER.GROUP reported by Dmitry V. Levin in
19252         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
19253         (parse_user_spec): Rewrite to use parse_with_separator.
19254
19255 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
19256
19257         * modules/userspec: Don't depend on alloca.
19258
19259 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
19260
19261         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
19262
19263 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
19264
19265         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
19266         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
19267         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
19268
19269 2004-08-16  Simon Josefsson  <jas@extundo.com>
19270
19271         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
19272         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
19273         Add --dry-run for --import.
19274         Let user provided command line parameters override configure.ac
19275         settings.
19276
19277 2004-08-12  Simon Josefsson  <jas@extundo.com>
19278
19279         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
19280         as discussed with Paul Eggert in threads rooted at
19281         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
19282         and
19283         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
19284         Before, the test was empty, and relied on ELIDE_CODE in source
19285         code.)
19286         (gl_PREREQ_GETOPT): New macro.
19287         (gl_GETOPT): Use them.
19288
19289 2004-08-12  Simon Josefsson  <jas@extundo.com>
19290
19291         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
19292         * lib/getopt_.h: Renamed from getopt.h.
19293
19294 2004-08-12  Simon Josefsson  <jas@extundo.com>
19295
19296         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
19297         Change default library name from libfoo to libgnu.
19298         Now, if you have a configure.ac that says:
19299                 gl_SOURCE_BASE(gl)
19300                 gl_M4_BASE(gl/m4)
19301                 gl_MODULES(error getopt etcetera)
19302                 gl_INIT
19303         you can import all you need by running:
19304                 ../gnulib/gnulib-tool --import
19305
19306         * modules/getopt (Files): Rename getopt.h to getopt_.h.
19307         (Makefile.am): Rewrite, use logic from argz.
19308         (Include): Use <getopt.h> instead of "getopt.h".
19309
19310 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19311
19312         * modules/argp (Files): Add m4/unlocked-io.m4.
19313         (Depends-on): Add extensions.
19314
19315 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19316
19317         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
19318         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
19319         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
19320         Check for program_invocation_name, program_invocation_short_name,
19321         flockfile, funlockfile, features.h, _getopt_long_only_r.
19322
19323 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19324
19325         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
19326         its complicated substitute.
19327         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
19328         and program_invocation_name.
19329         (__argp_basename) [!_LIBC]: Remove; the only use was
19330         replaced by its body.
19331         (__argp_short_program_name): Change condition from
19332         !defined __argp_short_program_name to
19333         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
19334         to match argp-namefrob.h.
19335         (__argp_failure): Don't assume strerror_r returns char *.
19336         * lib/argp-parse.c (N_): Define unconditionally.
19337         (argp_default_options): Fill out initializers with 0 to avoid
19338         gcc warnings.
19339
19340 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19341
19342         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
19343         getopt1.c.
19344
19345 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
19346
19347         Merge from coreutils.
19348
19349         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
19350
19351         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
19352         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
19353
19354 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
19355
19356         Merge from coreutils.
19357
19358         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
19359         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
19360         for Reliant Unix 5.43.
19361
19362         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
19363         (union fooround): Use uintmax_t, not long int.
19364         The rest is a merge from libc:
19365         [defined _LIBC]: Include <shlib-compat.h>.
19366         (_obstack) [defined _LIBC]: Remove after 2.3.4.
19367
19368         * lib/settime.c (settime): Recode to avoid warning with
19369         Sun Forte C 6U2.
19370
19371         * lib/strverscmp.c: Convert to UTF-8.
19372
19373 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
19374
19375         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
19376         m4/uintmax_t.m4.
19377
19378 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
19379
19380         * modules/xalloc-die: New file.
19381         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
19382
19383         * modules/md5 (Files): Add m4/uint32_t.m4.
19384         * modules/sha1: Renamed from modules/sha.
19385         (Files):
19386         Rename lib/sha.h to lib/sha1.h.
19387         Rename lib/sha.c to lib/sha1.c.
19388         Rename m4/sha.m4 to m4/sha1.m4.
19389         (lib_SOURCES): Likewise.
19390         (configure.ac): Rename gl_SHA to gl_SHA1.
19391         (Include): sha.h -> sha1.h.
19392
19393 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
19394
19395         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
19396         * m4/sha1.m4: Renamed from sha.m4.
19397         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
19398
19399 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
19400
19401         * lib/obstack.h (obstack_empty_p):
19402         Don't assume that chunk->contents is suitably aligned.
19403         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
19404         Likewise. Problem reported by Benno in
19405         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
19406
19407         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
19408         readable.  This could be improved further but it'd take some work.
19409
19410 2004-08-08  Simon Josefsson  <jas@extundo.com>
19411
19412         * modules/xgethostname (Depends-on): Remove exit and error (not
19413         used).
19414
19415         * modules/getpass-gnu: Add getpass.h.
19416         (Depends-on): Add stdbool.
19417         * modules/getpass: Add getpass.h.
19418
19419 2004-08-08  Simon Josefsson  <jas@extundo.com>
19420
19421         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
19422         Check getpass declaration.
19423
19424 2004-08-08  Simon Josefsson  <jas@extundo.com>
19425
19426         * lib/xgethostname.c: Don't include error.h (not used).
19427
19428         * lib/getpass.h: Add.
19429         * lib/getpass.c: Include getpass.h first.
19430
19431 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
19432
19433         * lib/xalloc-die.c: New file.
19434         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
19435         All uses removed.
19436         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
19437         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
19438         xalloc-die.c.
19439         (_, N_, xalloc_die): Move to xalloc-die.c.
19440         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
19441         so that we needn't mess with xalloc_msg_memory_exhausted.
19442
19443         * lib/sha1.h: Renamed from sha.h.
19444         (SHA1_H): Renamed from _SHA_H.
19445         (sha1_ctx): Renamed from sha_ctx.
19446         (sha1_init_ctx): Renamed from sha_init_ctx.
19447         (sha1_process_block): Renamed from sha_process_block.
19448         (sha1_process_bytes): Renamed from sha_process_bytes.
19449         (sha1_finish_ctx): Renamed from sha_finish_ctx.
19450         (sha1_read_ctx): Renamed from sha_read_ctx.
19451         (sha1_stream): Renamed from sha_stream.
19452         (sha1_buffer): Renamed from sha_buffer.
19453         * lib/sha1.c: Likewise; renamed from sha.c.
19454         Do not include <sys/types.h>.
19455         Include <stddef.h> rather than <stdlib.h>.
19456
19457 2004-08-08  Bruno Haible  <bruno@clisp.org>
19458
19459         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
19460         FILESYSTEM_PREFIX_LEN.
19461         * lib/progreloc.c: Likewise.
19462         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
19463
19464 2004-08-06  Simon Josefsson  <jas@extundo.com>
19465
19466         * modules/progname (Depends-on): Don't depend on stdbool.
19467
19468 2004-08-06  Simon Josefsson  <jas@extundo.com>
19469
19470         * modules/getsubopt: New file.
19471         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19472         getsubopt.
19473
19474 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
19475
19476         More merge from coreutils.
19477
19478         * m4/utimens.m4, m4/utimecmp.m4: New files.
19479         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
19480         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
19481         prereq.m4, sha.m4: Import changes from coreutils.
19482
19483 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
19484
19485         More merge from coreutils.
19486         * modules/raise, modules/readtokens0, modules/utimens:
19487         * modules/utimecmp, module/xnanosleep: New files.
19488         * modules/strftime: Add lib/strftime.h.
19489         Change include from <time.h> to "strftime.h".
19490         * modules/yesno: Add lib/yesno.h.
19491         * modules/backupfile: Remove lib/addext.c.
19492         * modules/euidaccess: Add stat-macros.h.
19493         * modules/canonicalize, modules/euidaccess,
19494         modules/filemode, modules/lchown, modules/makepath,
19495         modules/rmdir, modules/stat: Likewise.
19496
19497 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
19498
19499         Merge from tar.
19500         * lib/argp-help.c (make_hol, hol_append): Don't assume that
19501         SIZE_MAX is a valid preprocessor constant.
19502         (__argp_basename): Change from "#ifndef _LIBC"
19503         to "#ifndef __argp_short_program_name", so that
19504         we don't compile these functions for tar.
19505
19506         More merges from coreutils.
19507         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
19508         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
19509         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
19510         * lib/addext.c: Remove; no longer needed.
19511         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
19512         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
19513         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
19514         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
19515         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
19516         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
19517         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
19518         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
19519         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
19520         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
19521         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
19522         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
19523         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
19524         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
19525         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
19526         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
19527         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
19528         Import changes from coreutils.
19529
19530 2004-08-05  Simon Josefsson  <jas@extundo.com>
19531
19532         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
19533
19534 2004-08-05  Simon Josefsson  <jas@extundo.com>
19535
19536         * m4/getsubopt.m4: New file.
19537
19538 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19539
19540         Merge from coreutils.
19541
19542         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
19543         * m4/getcwd-path-max.m4: New files.
19544
19545         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
19546         FILESYSTEM_PREFIX_LEN ->
19547         FILE_SYSTEM_PREFIX_LEN.
19548         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
19549         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
19550         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
19551         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
19552
19553         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
19554         prerequisite modules now handle the DOS stuff.
19555         Don't check for unistd.h.
19556
19557 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19558
19559         Merge from coreutils.
19560
19561         * lib/.gdb-history: Remove; this doesn't belong here.
19562
19563         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
19564         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
19565         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
19566         * lib/getcwd.c: New files.
19567
19568         * lib/dirname.h: Include <stdbool.h>.
19569         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
19570         for consistency with POSIX terminology.  All uses changed.
19571         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
19572         (strip_trailing_slashes): Use bool for booleans.
19573         * lib/stripslash.c (strip_trailing_slashes): Likewise.
19574
19575         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
19576         sometimes returns a positive errno value even when it succeeds.
19577         (print_errno_message) [!LIBC]: Fall back on strerror if
19578         __strerror_r fails.
19579
19580         * lib/path-concat.c (mempcpy): Don't define if a system header defines
19581         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
19582         (longest_relative_suffix): New function.
19583         (path_concat): Use it.  Assume first argument is not NULL.
19584         Port to DOS.  Omit redundant separators.
19585         Report an error instead of returning NULL.
19586         Use mempcpy instead of memcpy.
19587         (xpath_concat): Remove: not declared or used.
19588
19589         * lib/same.h: Include <stdbool.h>
19590         (same_name): Return bool, not int.
19591         * lib/same.c (same_name): Likewise.
19592         (errno): Don't declare; we assume C89 or better now.
19593
19594         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
19595         if not already defined.
19596
19597         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
19598         * lib/dup-safer.c (errno): Likewise.
19599
19600 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19601
19602         Merge from coreutils.
19603         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
19604         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
19605         * modules/path-concat: Don't depend on strdup.
19606
19607 2004-08-03  Simon Josefsson  <jas@extundo.com>
19608
19609         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
19610         * lib/progname.h: Don't include stdbool.h.
19611
19612 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19613
19614         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
19615         * MODULES.html.sh (func_all_modules): Remove fatal.
19616
19617 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19618
19619         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
19620
19621 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19622
19623         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
19624         working.
19625
19626 2004-08-02  Simon Josefsson  <jas@extundo.com>
19627
19628         * lib/getsubopt.h: New file, with comments from Bruno Haible.
19629         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
19630         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
19631
19632 2004-08-01  Simon Josefsson  <jas@extundo.com>
19633
19634         * lib/xgetdomainname.c: Include stdlib.h, for free().
19635
19636 2004-07-19  Bruno Haible  <bruno@clisp.org>
19637
19638         * MODULES.html.sh (func_all_modules): Add dummy.
19639
19640 2004-07-16  Simon Josefsson  <jas@extundo.com>
19641
19642         * modules/dummy: New file.
19643
19644 2004-07-16  Simon Josefsson  <jas@extundo.com>
19645
19646         * lib/dummy.c: New file.
19647
19648 2004-07-16  Bruno Haible  <bruno@clisp.org>
19649
19650         * lib/backupfile.h: Add extern "C" for C++.
19651         * lib/closeout.h: Likewise.
19652         * lib/copy-file.h: Likewise.
19653         * lib/findprog.h: Likewise.
19654         * lib/full-write.h: Likewise.
19655         * lib/pathname.h: Likewise.
19656         * lib/progname.h: Likewise.
19657         * lib/stpcpy.h: Likewise.
19658         * lib/stpncpy.h: Likewise.
19659         * lib/strcase.h: Likewise.
19660         * lib/strstr.h: Likewise.
19661         * lib/xalloc.h: Likewise.
19662
19663         * lib/mbswidth.h: Add extern "C" for C++.
19664         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
19665
19666 2004-07-13  Robert Millan  <robertmh@gnu.org>
19667
19668         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
19669
19670 2004-07-09  Simon Josefsson  <jas@extundo.com>
19671
19672         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
19673         failed without this.)
19674
19675 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19676
19677         * modules/chown (Files): Add lib/fchown-stub.c, since
19678         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
19679
19680 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19681
19682         * lib/fchown-stub.c: New file.
19683
19684 2004-06-24  Jim Meyering  <jim@meyering.net>
19685
19686         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
19687
19688 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19689
19690         * modules/argz: Omit "#include".
19691
19692         * MODULES.html.sh (func_all_modules): Add calloc, to match
19693         2004-06-01 addition of calloc module.
19694
19695 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19696
19697         * m4/argz.m4: New file, which is autoupdated from libtool.
19698
19699 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19700
19701         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
19702         libtool.
19703
19704 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19705
19706         * config/srclist-update: Don't insist on "USA." before the
19707         close-comment, as libtool omits the period and puts the */ on a
19708         separate line.
19709         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
19710         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
19711
19712 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
19713
19714         * modules/argz: New file.
19715         * MODULES.html.sh (func_all_modules): Add argz.
19716
19717 2004-06-12  Jim Meyering  <jim@meyering.net>
19718         and  Paul Eggert  <eggert@cs.ucla.edu>
19719
19720         * modules/hash (Files): Add lib/xalloc.h.
19721         * modules/pipe (Depends-on): Add wait-process.
19722         * modules/stat (Depends-on): Add xalloc.
19723         * modules/userspec (Files): Add lib/userspec.h.
19724         * modules/xstrto
19725
19726         Upgrade from gettext-0.13.
19727         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
19728         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
19729         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
19730
19731 2004-06-10  Jim Meyering  <jim@meyering.net>
19732
19733         * lib/calloc.c: New file.
19734
19735 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
19736
19737         * lib/getdate.y (yylex): Allow space between sign and number.
19738         Problem reported by Dan Jacobson.
19739
19740 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19741
19742         Merge from coreutils CVS.
19743
19744         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
19745         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
19746         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
19747         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
19748         xstrtol.m4: Fix copyright date and/or serial number.
19749
19750         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
19751         See if we need an fchown replacement.
19752         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
19753         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
19754         and use the replacement function if we detect either defect.
19755
19756         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
19757         gl_UTIMECMP.
19758
19759 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19760         and  Jim Meyering  <jim@meyering.net>
19761
19762         Merge from coreutils CVS.
19763
19764         * lib/stat-macros.h: New file, with contents from file-type.h
19765         and coreutils' system.h.
19766         * lib/file-type.c: Include "stat-macros.h".
19767         * lib/file-type.h (file_type): Move all macro definitions to new file,
19768         stat-macros.h.
19769
19770         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
19771         Wrap old code with this conditional.
19772         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
19773         function that does not dereference symlinks.
19774         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
19775
19776         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
19777         dependency problems.
19778         (xreadlink): Accept new arg SIZE, for efficiency.
19779         All decls and uses changed.
19780         * lib/xreadlink.h: Include <stddef.h>, for size_t.
19781
19782         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
19783         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
19784
19785         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
19786         sysexits.h.
19787
19788 2004-06-01  Jim Meyering  <jim@meyering.net>
19789
19790         * m4/calloc.m4: New file.
19791
19792 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
19793
19794         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
19795         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
19796         Also, fix a typo in a diagnostic.
19797
19798 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19799
19800         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
19801         or AC_FUNC_REALLOC.
19802
19803 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19804
19805         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
19806         macros to be defined.
19807         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
19808         the allocator returns NULL because the requested size is zero.
19809
19810 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19811
19812         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
19813         var.  Add comment explaining why libc still defines it.  This
19814         merges the following patch from glibc:
19815         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
19816
19817 2004-05-20  Andreas Schwab  <schwab@suse.de>
19818
19819         * m4/free.m4: Replace free if it not known to work, not the other
19820         way round.
19821
19822 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
19823
19824         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
19825         present in glibc since revision 1.1 of this file.
19826         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
19827         obstack_alignment_mask, obstack_alloc, obstack_base,
19828         obstack_blank, obstack_blank_fast, obstack_chunk_size,
19829         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
19830         obstack_grow0, obstack_init, obstack_int_grow,
19831         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
19832         obstack_next_free, obstack_object_size, obstack_ptr_grow,
19833         obstack_ptr_grow_fast, obstack_room): Remove declarations of
19834         nonexistent functions.
19835
19836 2004-05-18  Karl Berry  <karl@gnu.org>
19837
19838         * config/srclist.txt: break link for vasnprintf.c.
19839
19840 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
19841
19842         Port obstack to the AS/400, where pointers are 16 bytes wide and
19843         you cannot cast an integer to a valid pointer.  This patch is
19844         currently waiting to be integrated into glibc; see
19845         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
19846
19847         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
19848         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
19849         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
19850         (struct obstack): temp member is now a union of a pointer and
19851         an integer, instead of an integer.  All integer uses changed.
19852         This does not affect the physical layout of struct obstack,
19853         except on hosts (like the AS/400) where the size or alignment of
19854         void * is greater than that of ptrdiff_t.
19855         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
19856         __STDC__)]: Store temporary in pointer member of union, not
19857         integer member.
19858         * lib/obstack.c: Include <stddef.h>, for offsetof.
19859         (struct fooalign): Remove; it doesn't need a name.
19860         (union fooround): Change double to long double, and add void *.
19861         (DEFAULT_ALIGNMENT): Use offsetof to compute.
19862         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
19863         not a macro.  Hence the values are always int; so remove all
19864         casts-to-int in uses.
19865
19866 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
19867
19868         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
19869         we can get this patch merged into glibc.
19870
19871 2004-05-17  Derek R. Price  <derek@ximbiot.com>
19872             Paul Eggert  <eggert@cs.ucla.edu>
19873
19874         * m4/argp: Depend on alloca.
19875
19876 2004-05-17  Derek R. Price  <derek@ximbiot.com>
19877             Paul Eggert  <eggert@cs.ucla.edu>
19878
19879         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
19880         freecoding.
19881
19882 2004-05-17  Bruno Haible  <bruno@clisp.org>
19883
19884         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
19885         precision that consists of a '.' followed by an empty digit string.
19886         Patch by Tor Lillqvist <tml@iki.fi>.
19887
19888 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
19889
19890         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
19891         for backward compatibility with older code.  We need our own
19892         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
19893         it under some other name, and our alloca.h will define it.
19894
19895 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
19896             Derek Price  <derek@ximbiot.com>
19897
19898         * lib/alloca.c: Include <alloca.h>, to get our interface.
19899         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
19900         include <alloca.h> first.  Use C89 prototype for alloca; this
19901         requires including <stddef.h> for size_t.  Use extern "C" if C++.
19902         Use #elif for simplicity, since we can assume C89 now.
19903         Don't try to source the system alloca.h since it will not be found
19904         and to prevent recursively including its replacement.
19905         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
19906         * lib/regex.c: Likewise.
19907
19908 2004-05-16  Derek Price  <derek@ximbiot.com>
19909             Paul Eggert  <eggert@cs.ucla.edu>
19910
19911         getline cleanup.  This changes the getndelim2 API: both order of
19912         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
19913         no delimiter).
19914
19915         * lib/getline.c: Don't include stddef.h or stdio.h, since our
19916         interface does that.
19917         (getline): Always use getdelim, so that we don't have two
19918         copies of this code.
19919         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
19920         if available.
19921         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
19922         (GETNDELIM2_MAXIMUM): New macro.
19923         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
19924         instead of the old practice of delim2==0.  All callers changed.
19925         Return -1 on overflow, instead of returning junk.
19926         Do not set *linesize unless allocation succeeds.
19927         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
19928         that we include sys/types.h.
19929         * lib/getnline.h: Likewise.
19930         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
19931         (getndelim2): Reorder arguments.
19932         * lib/getnline.c (getnline, getndelim):
19933         Don't discard the NMAX argument.
19934         (getnline): Invoke getndelim, to avoid code duplication.
19935         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
19936         of (size_t) -1 by callers of the getnline family.
19937
19938 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19939
19940         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
19941         Check for gettimeofday.
19942         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
19943         Check for settimeofday, stime.
19944
19945 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19946
19947         * lib/nanosleep.c (suspended): Change its type from int to
19948         sig_atomic_t volatile.
19949         (first_call): Make it private to rpl_nanosleep, and have it
19950         be zero initially as that's a bit faster.
19951         (my_usleep): Round up fractional times instead of truncating them,
19952         as this is the usual meaning for 'sleep'.
19953
19954         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
19955         doesn't work.
19956         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
19957         (ENOSYS): Define if not defined.
19958         (settime): Fall back on stime if it exists and settimeofday fails.
19959         But don't bother with fallbacks if a method fails with errno == EPERM.
19960
19961 2004-05-11  Jim Meyering  <jim@meyering.net>
19962
19963         Prior to this change, the save_cwd caller required read access to the
19964         current directory on most systems (ones with the fchdir function).
19965
19966         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
19967         fails, try write-only, and finally, resort to using xgetcwd.
19968
19969 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
19970
19971         * lib/obstack.c, obstack.h: Import changes from libc.
19972
19973 2004-04-28  Bruno Haible  <bruno@clisp.org>
19974
19975         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
19976         also implicitly appends .exe to executables.
19977         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
19978         accepts Windows pathnames.
19979         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
19980         Treat Cygwin like Windows, since it now accepts Windows pathnames.
19981         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
19982         Treat Cygwin like Windows, since it now accepts Windows pathnames.
19983         Reported by Derek Robert Price <derek@ximbiot.com>.
19984
19985 2004-04-21  Karl Berry  <karl@gnu.org>
19986
19987         * config/srclist.txt (localcharset.c): break sync.
19988
19989 2004-04-20  Paul Eggert  <eggert@twinsun.com>
19990
19991         * m4/host-os.m4: Add a copyright notice.
19992
19993 2004-04-20  Jim Meyering  <jim@meyering.net>
19994
19995         Change UTILS_ to gl_ in AC_DEFINE'd names.
19996         Change utils_- and jm_-prefixed variables, too.
19997         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
19998         UTILS_FUNC_MKDIR_TRAILING_SLASH.
19999         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
20000
20001         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
20002         Don't emit trailing blanks.
20003         Also rename jm_-prefixed variables to have gl_ prefix.
20004
20005         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
20006         Also rename jm_-prefixed variables to have gl_ prefix.
20007
20008         * m4/jm-macros.m4: Reflect the renamings.
20009         * m4/prereq.m4: Likewise.
20010
20011 2004-04-20  Jim Meyering  <jim@meyering.net>
20012
20013         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
20014         memory.
20015
20016 2004-04-20  Jim Meyering  <jim@meyering.net>
20017             Bruno Haible  <bruno@clisp.org>
20018
20019         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
20020         memory when realloc fails.
20021
20022 2004-04-19  Jim Meyering  <jim@meyering.net>
20023
20024         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
20025         now that readutmp.c may call `free (0)'.
20026
20027 2004-04-19  Bruno Haible  <bruno@clisp.org>
20028
20029         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
20030         * m4/inttypes_h.m4: Likewise.
20031         * m4/stdint_h.m4: Likewise.
20032         * m4/intmax_t.m4: Likewise.
20033         * m4/uintmax_t.m4: Likewise.
20034
20035 2004-04-18  Jim Meyering  <jim@meyering.net>
20036
20037         * m4/prereq.m4: Don't forbid jm_ prefix.
20038
20039         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
20040         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
20041         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
20042         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
20043         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
20044         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
20045         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
20046         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
20047         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
20048         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
20049         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
20050         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
20051         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
20052         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
20053         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
20054         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
20055         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
20056         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
20057         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
20058
20059 2004-04-18  Jim Meyering  <jim@meyering.net>
20060
20061         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
20062         failure, don't leak memory and do call END_UTMP_ENT.
20063
20064 2004-04-16  Jim Meyering  <jim@meyering.net>
20065
20066         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
20067         coreutils' stat program.
20068         (gl_PREREQ): Don't require jm_PREREQ_STAT.
20069
20070 2004-04-11  Paul Eggert  <eggert@twinsun.com>
20071
20072         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
20073         C89.
20074         (CHAR_BIT): Remove, since we assume C89.
20075         Include <stdint.h> if available, as per current Autoconf CVS advice.
20076
20077 2004-03-31  Jim Meyering  <jim@meyering.net>
20078
20079         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
20080         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
20081         * m4/xalloc.m4: Likewise.
20082
20083 2004-03-30  Paul Eggert  <eggert@twinsun.com>
20084
20085         Merge from coreutils.
20086
20087         * m4/inttostr.m4: New file.
20088         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
20089         Require AM_STDBOOL_H and gl_TIMESPEC instead.
20090         Require gl_CLOCK_TIME.
20091         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
20092
20093 2004-03-30  Paul Eggert  <eggert@twinsun.com>
20094
20095         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
20096         not bool, to be more consistent with Unix conventions.
20097         Suggested by Bruno Haible.
20098
20099         Merge from coreutils.
20100
20101         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
20102         * lib/umaxtostr.c: New files.
20103
20104         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
20105         the usual <time.h> dance.
20106         (get_date): Change signature to support fractional time stamps.
20107         All callers changed.
20108         * lib/getdate.y: Include "getdate.h" first, as we can now
20109         assume C89 and don't need to worry about 'const'.
20110         Similarly, include "unlocked-io.h" near start, not in middle.
20111         Include <limits.h>.
20112         (textint.value): Use long int rather than int.
20113         (textint.digits): Use size_t rather than int.
20114         (BILLION, LOG10_BILLION): New constants.
20115         (parser_control): New member rel_ns.  Members day_ordinal,
20116         time_zone, month, day, hour, minutes, rel_year, rel_month,
20117         rel_day, rel_hour, rel_minutes, rel_seconds
20118         are now long int, not int.  Member seconds is now struct timespec,
20119         not int.  New member timespec_seen.  Members dates_seen, days_seen,
20120         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
20121         not int.
20122         (%union.intval): Now long int, not int.
20123         New member timespec.
20124         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
20125         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
20126         (spec): Now is a timespec or an item list.
20127         (timespec, items): New nonterminals.
20128         (time, rel, relunit, number, get_date):
20129         Add support for fractional seconds.
20130         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
20131         (gmtime, localtime, mktime): Remove decls; not needed with C89.
20132         (to_hour): First arg is now long int, not int.
20133         (to_year): Returns long int, not int.
20134         Don't treat year -70 like 70.
20135         (tm_diff): Returns long int, not int.
20136         (lookup_word): Use bool instead of int when appropriate.
20137         (yylex): Use size_t for count, not int.
20138         Detect overflow when parsing large integer constants.
20139         Add support for fractions.
20140         (get_date): Make pointers 'const' if possible.
20141         Use more-portable code to detect integer overflow.
20142         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
20143         Don't use ctime; it's not reliable if the year has >4 digits.
20144
20145         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
20146         This is for compatibility with BSD.
20147
20148         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
20149         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
20150         From coreutils' system.h.
20151
20152         * lib/userspec.c: Don't include "posixver.h".
20153         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
20154         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
20155         compatible extension.  Simplify code by removing a boolean int
20156         that was always nonzero if a string was nonnull.
20157
20158 2004-03-30  Jim Meyering  <jim@meyering.net>
20159
20160         Merge from coreutils.
20161
20162         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
20163         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
20164         on some systems one must include <grp.h> before it.
20165         Reported by Christian Krackowizer.
20166
20167 2004-03-30  Jim Meyering  <jim@meyering.net>
20168
20169         Merge from coreutils.
20170
20171         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
20172
20173         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
20174         an empty input stream.
20175
20176         * lib/readtokens.c: Include <stdbool.h>.
20177         (readtoken): Use `size_t' rather than int/long.
20178         All callers adjusted.
20179         Use `bool' rather than `int' where appropriate.
20180         Use memset rather than an explicit loop.
20181         Use x2nrealloc rather than xrealloc.
20182         Allow the use of `\0' as a delimiter.
20183         (readtokens): Likewise.
20184         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
20185
20186 2004-03-30  Jim Meyering  <jim@meyering.net>
20187
20188         * m4/realloc.m4: Remove file, since now it does no more than
20189         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
20190         the `configure.ac' section of module/realloc.
20191         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
20192
20193 2004-03-30  Bruno Haible  <bruno@clisp.org>
20194
20195         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
20196         nonnull.
20197
20198 2004-03-29  Paul Eggert  <eggert@twinsun.com>
20199
20200         Merge changes to getloadavg.c from coreutils and Emacs.
20201
20202         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
20203         Define to an expression, not to the empty string.
20204         Include cloexec.h and xalloc.h.
20205         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
20206         Use set_cloexec_flag rather than rolling our own.
20207         * lib/cloexec.c, lib/cloexec.h: New files.
20208
20209 2004-03-29  Paul Eggert  <eggert@twinsun.com>
20210
20211         * m4/cloexec.m4: New file.
20212
20213 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20214
20215         * lib/getopt.h: Sync with libc CVS.
20216
20217 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20218             Bruno Haible  <bruno@clisp.org>
20219
20220         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
20221         mbswidth.
20222
20223 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20224             Bruno Haible  <bruno@clisp.org>
20225
20226         * lib/mbswidth.h: Include <wchar.h> only if
20227         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
20228         <wchar.h>.
20229         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
20230
20231 2004-03-09  Paul Eggert  <eggert@twinsun.com>
20232
20233         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
20234         Sync with libc CVS.
20235         * lib/getopt_int.h: New file, also synced from libc.
20236
20237 2004-03-09  Paul Eggert  <eggert@twinsun.com>
20238
20239         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
20240         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
20241         Bring back getopt.c, getopt.h, getopt1.c.
20242
20243 2004-03-07  Paul Eggert  <eggert@twinsun.com>
20244
20245         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
20246         All uses changed.  Check for sa_sigaction member; this fixes
20247         a bug first reported by Jason Andrade in
20248         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
20249
20250 2004-03-07  Paul Eggert  <eggert@twinsun.com>
20251
20252         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
20253         '#if' expressions.  Unlike the code it replaces, it does not
20254         depend on (defined _SC_PAGESIZE).  However, it does depend on
20255         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
20256         first reported by Jason Andrade in
20257         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
20258
20259 2004-02-25  Simon Josefsson  <jas@extundo.com>
20260
20261         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
20262
20263 2004-02-25  Simon Josefsson  <jas@extundo.com>
20264
20265         * lib/strdup.h: New file.
20266         * lib/strdup.c: Include it.
20267         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
20268         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
20269
20270 2004-02-23  Karl Berry  <karl@gnu.org>
20271
20272         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
20273         (from fencepost.gnu.org:/gd/gnuorg).
20274
20275 2004-02-23  Karl Berry  <karl@gnu.org>
20276
20277         * config/srclistvars.sh (GNUORG) [karl]: redefine.
20278         * config/srclist.txt: add maintain/standards documents.
20279
20280 2004-02-18  Bruno Haible  <bruno@clisp.org>
20281
20282         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
20283         Reported by Derek Robert Price <derek@ximbiot.com>.
20284
20285 2004-02-16  Karl Berry  <karl@gnu.org>
20286
20287         * config/mkinstalldirs, install-sh: update from automake.
20288
20289 2004-02-06  Karl Berry  <karl@gnu.org>
20290
20291         * m4/po.m4: update from gettext 0.14.1.
20292
20293 2004-02-06  Karl Berry  <karl@gnu.org>
20294
20295         * lib/config.charset: update from gettext 0.14.1.
20296
20297 2004-02-05  Paul Eggert  <eggert@twinsun.com>
20298
20299         Add comments and code, prompted by suggestions from Bruno Haible
20300         for sh-quote.
20301         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
20302         describing the enum quoting_style values.
20303         * lib/quotearg.c (quotearg_alloc): New function.
20304         (quotearg_buffer_restyled): Treat lone { and } as special.
20305         Treat = as special.  Work around bug with older shells
20306         that "see" a '\' that is really the 2nd byte of a multibyte char.
20307         Quote empty string with shell_quoting_style.
20308
20309 2004-02-03  Bruno Haible  <bruno@clisp.org>
20310
20311         * m4/pipe.m4: New file, from GNU gettext.
20312
20313 2004-02-03  Bruno Haible  <bruno@clisp.org>
20314
20315         * lib/pipe.h: New file, from GNU gettext.
20316         * lib/pipe.c: New file, from GNU gettext.
20317
20318 2004-01-27  Bruno Haible  <bruno@clisp.org>
20319
20320         * m4/execute.m4: New file, from GNU gettext.
20321
20322 2004-01-27  Bruno Haible  <bruno@clisp.org>
20323
20324         * lib/execute.h: New file, from GNU gettext.
20325         * lib/execute.c: New file, from GNU gettext.
20326         * lib/w32spawn.h: New file, from GNU gettext.
20327
20328 2004-01-24  Paul Eggert  <eggert@twinsun.com>
20329
20330         Merge from diffutils.
20331
20332         * lib/file-type.c (file_type): Add typed memory objects.
20333         * lib/file-type.h (S_TYPEISTMO): New macro.
20334
20335         * lib/c-stack.h (c_stack_action): Remove argv argument.
20336         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
20337         (die): Don't calculate message unless segv_action returns.
20338         (get_stack_location, min_address_from_argv, max_address_from_argv,
20339         volatile stack_base, volatile_stack_size): Remove.
20340         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
20341         that every segmentation violation is a stack overflow.  (Ouch!)
20342         See Debian bug 136249 (still outstanding) for more info about why
20343         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
20344
20345 2004-01-24  Paul Eggert  <eggert@twinsun.com>
20346
20347         Exit-status fix from coreutils.
20348
20349         Use exit_failure consistently in place of EXIT_FAILURE,
20350         so that program exit statuses are consistent on failure.
20351
20352         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
20353         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
20354         * lib/argmatch.h: Comment fix to match the above.
20355         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
20356         Now a macro referring to exit_failure, instead of a separate
20357         variable.  Include "exitfail.h" to get it.
20358         * lib/xstrtol.h: Include "exitfail.h".
20359         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
20360
20361         * lib/long-options.c (parse_long_options): Use prototype
20362         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
20363         for clarity.
20364
20365 2004-01-21  Jim Meyering  <jim@meyering.net>
20366
20367         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
20368         so as not to conflict with a different-sized __mktime_internal
20369         function in GNU libc.
20370         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
20371         Problem building statically-linked `ls' reported by Michael Brunnbauer.
20372
20373 2004-01-20  Karl Berry  <karl@gnu.org>
20374
20375         * config/config.guess: update from config.
20376
20377         * config/srclistvars.sh: GNUWWWLICENSES for karl.
20378
20379 2004-01-20  Bruno Haible  <bruno@clisp.org>
20380
20381         Safer stack allocation.
20382         * lib/setenv.c: Include allocsa.h.
20383         (alloca): Remove fallback definition.
20384         (freea): Remove macro.
20385         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
20386         instead of freea.
20387
20388 2004-01-20  Bruno Haible  <bruno@clisp.org>
20389
20390         * m4/eealloc.m4: New file, from GNU gettext.
20391
20392 2004-01-20  Bruno Haible  <bruno@clisp.org>
20393
20394         * m4/allocsa.m4: New file, from GNU gettext.
20395
20396 2004-01-20  Bruno Haible  <bruno@clisp.org>
20397
20398         * lib/xallocsa.h: New file, from GNU gettext.
20399         * lib/xallocsa.c: New file, from GNU gettext.
20400
20401 2004-01-20  Bruno Haible  <bruno@clisp.org>
20402
20403         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
20404
20405 2004-01-20  Bruno Haible  <bruno@clisp.org>
20406
20407         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
20408         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
20409         specially.
20410
20411 2004-01-20  Bruno Haible  <bruno@clisp.org>
20412
20413         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
20414         patch.
20415
20416 2004-01-20  Bruno Haible  <bruno@clisp.org>
20417
20418         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
20419
20420 2004-01-20  Bruno Haible  <bruno@clisp.org>
20421
20422         * lib/eealloc.h: New file.
20423
20424 2004-01-20  Bruno Haible  <bruno@clisp.org>
20425
20426         * lib/binary-io.h: Avoid warnings on Cygwin.
20427
20428 2004-01-20  Bruno Haible  <bruno@clisp.org>
20429
20430         * lib/allocsa.h: New file, from GNU gettext.
20431         * lib/allocsa.c: New file, from GNU gettext.
20432
20433 2004-01-18  Karl Berry  <karl@gnu.org>
20434
20435         * doc/gpl.texi, doc/lgpl.texi: new files.
20436
20437 2004-01-18  Karl Berry  <karl@gnu.org>
20438
20439         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
20440         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
20441
20442 2004-01-15  Paul Eggert  <eggert@twinsun.com>
20443
20444         Merge from coreutils.
20445
20446         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
20447         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
20448         (gl_DEFAULT_POSIX2_VERSION): Move
20449         the documentation from 'configure' into 'config.hin',
20450         so that 'configure --help' isn't burdened by it and
20451         we don't have to worry about its formatting there.
20452         Reword the documentation so that it's more succinct
20453         and can be run together into a single paragraph.
20454         * m4/same.m4 (gl_SAME): Check for pathconf.
20455
20456 2004-01-15  Paul Eggert  <eggert@twinsun.com>
20457
20458         Merge from coreutils.
20459
20460         * lib/posixver.c: Include posixver.h.
20461
20462         * lib/same.c: Include <stdbool.h>, <limits.h>.
20463         (_POSIX_NAME_MAX): Define if not defined.
20464         (MIN): New macro.
20465         (same_name): If file names are silently truncated, report
20466         that the file names are the same if they are the same after
20467         the silent truncation.
20468
20469         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
20470         conversion function.
20471         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
20472         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
20473         longer needed.
20474
20475 2004-01-15  Jim Meyering  <jim@meyering.net>
20476
20477         Merge from coreutils.
20478
20479         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
20480         if no library is required.
20481         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
20482         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
20483         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
20484         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
20485         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
20486         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
20487         value, $ac_cv_search_crypt, if it's "none required".
20488         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
20489         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
20490         not gl_FUNC_GETLOADAVG.
20491         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
20492         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
20493
20494 2004-01-15  Jim Meyering  <jim@meyering.net>
20495
20496         Merge from coreutils.
20497
20498         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
20499         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
20500         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
20501
20502         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
20503         optional configure-time default.
20504
20505         * lib/version-etc.c (version_etc_copyright): Update copyright date.
20506
20507         * lib/xreadlink.c (xreadlink): Correct outdated comment.
20508
20509 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
20510
20511         Merge from coreutils.
20512
20513         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
20514         value, $ac_cv_search_nanosleep, if it's "none required".
20515
20516 2004-01-14  Paul Eggert  <eggert@twinsun.com>
20517
20518         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
20519         with like-named macro in fnmatch.c.
20520         (EXT): Use an internal constant instead.
20521
20522         Merge fnmatch patches from glibc.
20523         * lib/fnmatch.c (mbsinit): Remove define.
20524         Add libc_hidden_ver (__fnmatch, fnmatch).
20525         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
20526         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
20527
20528 2004-01-14  Karl Berry  <karl@gnu.org>
20529
20530         * config/install-sh: update from automake.
20531
20532 2004-01-13  Karl Berry  <karl@gnu.org>
20533
20534         * config/install-sh: update from automake.
20535
20536 2004-01-09  Karl Berry  <karl@gnu.org>
20537
20538         * config/install-sh: update from automake.
20539
20540 2004-01-05  Karl Berry  <karl@gnu.org>
20541
20542         * config/config.{sub,guess}: update from config.
20543
20544 2003-12-31  Karl Berry  <karl@gnu.org>
20545
20546         * config/depcomp: update from automake.
20547
20548 2003-12-14  Karl Berry  <karl@gnu.org>
20549
20550         * lib/config.charset: update from gettext-runtime.
20551
20552 2003-12-03  Paul Eggert  <eggert@twinsun.com>
20553
20554         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
20555         Bug reported by Alfred M. Szmidt.
20556
20557 2003-12-03  Bruno Haible  <bruno@clisp.org>
20558
20559         * m4/gettext.m4: Upgrade from gettext-0.13.
20560         * m4/po.m4: Upgrade from gettext-0.13.
20561         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
20562         * m4/intmax.m4: New file, from gettext-0.13.
20563         * m4/printf-posix.m4: New file, from gettext-0.13.
20564
20565 2003-11-29  Karl Berry  <karl@gnu.org>
20566
20567         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
20568
20569 2003-11-25  Paul Eggert  <eggert@twinsun.com>
20570             Bruno Haible  <bruno@clisp.org>
20571
20572         * lib/printf-parse.h: Don't include sys/types.h.
20573         (ARG_NONE): New macro.
20574         (char_directive): Change type of *arg_index fields to size_t.
20575         * lib/printf-parse.c: Don't include sys/types.h.
20576         (SSIZE_MAX): Remove macro.
20577         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
20578         Remove unnecessary overflow check.
20579         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
20580         fields.
20581
20582 2003-11-25  Bruno Haible  <bruno@clisp.org>
20583
20584         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
20585
20586 2003-11-25  Bruno Haible  <bruno@clisp.org>
20587
20588         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
20589         gt_TYPE_SSIZE_T.
20590
20591 2003-11-24  Paul Eggert  <eggert@twinsun.com>
20592
20593         * modules/alloca: Remove dependency on xalloc.
20594
20595 2003-11-24  Paul Eggert  <eggert@twinsun.com>
20596
20597         * lib/alloca.c: Remove dependency on xalloc module.
20598         (xalloc_die): Remove.
20599         (memory_full) [!defined emacs]: New macro.
20600         [!defined emacs]: Don't include xalloc.h.
20601         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
20602         address arithmetic overflows.  Change datatypes a bit to avoid
20603         unnecessary casts.
20604
20605 2003-11-22  Jim Meyering  <jim@meyering.net>
20606
20607         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
20608         s/size/size_t/.
20609
20610 2003-11-21  Karl Berry  <karl@gnu.org>
20611
20612         * config/config.{sub,guess}: update from config.
20613
20614 2003-11-18  Karl Berry  <karl@gnu.org>
20615
20616         * config/config.{sub,guess}: update from config.
20617
20618         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
20619
20620 2003-11-17  Paul Eggert  <eggert@twinsun.com>
20621
20622         * README: Mention that S+T cannot overflow if S is the size of
20623         an existing object and T is sufficiently small.
20624
20625 2003-11-17  Jim Meyering  <jim@meyering.net>
20626
20627         On systems without utime and without a utimes function capable of
20628         dealing with a NULL struct utimbuf* argument, this utime replacement
20629         could -- in unusual circumstances -- leak a file descriptor.
20630         * lib/utime.c: Include <unistd.h> and <errno.h>.
20631         (utime_null): Be sure to close `fd' and to preserve errno.
20632         Reported by Geoff Collyer via Arnold Robbins.
20633
20634 2003-11-17  Bruno Haible  <bruno@clisp.org>
20635
20636         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
20637         (Depends-on): Add xsize.
20638
20639 2003-11-17  Bruno Haible  <bruno@clisp.org>
20640
20641         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
20642
20643 2003-11-17  Bruno Haible  <bruno@clisp.org>
20644
20645         * lib/vasnprintf.c (alloca): Remove fallback definition.
20646         (freea): Remove definition.
20647         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
20648         Reported by Paul Eggert.
20649
20650 2003-11-16  Paul Eggert  <eggert@twinsun.com>
20651             Bruno Haible  <bruno@clisp.org>
20652
20653         Protect against address arithmetic overflow.
20654         * lib/printf-args.h: Include stddef.h.
20655         (arguments): Change type of field 'count' to size_t.
20656         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
20657         'unsigned int' where appropriate.
20658         * lib/printf-parse.h: Include sys/types.h.
20659         (char_directive): Change type of *arg_index fields to ssize_t.
20660         (char_directives): Change type of fields 'count', max_*_length to
20661         size_t.
20662         * lib/printf-parse.c: Include sys/types.h and xsize.h.
20663         (SSIZE_MAX): Define fallback value.
20664         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
20665         instead of 'int' where appropriate. Check a_allocated, d_allocated
20666         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
20667         * lib/vasnprintf.c: Include xsize.h.
20668         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
20669         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
20670         overflow. Avoid wraparound when converting a width or precision from
20671         decimal to binary.
20672
20673 2003-11-16  Bruno Haible  <bruno@clisp.org>
20674
20675         Update from GNU gettext.
20676         * lib/printf-parse.c: Generalize to it can be compiled for wide
20677         strings.
20678         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
20679         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
20680         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
20681         SNPRINTF): New macros.
20682         Don't include <alloca.h> if the file is used inside libintl.
20683         (local_wcslen): New function, for Solaris 2.5.1.
20684         (VASNPRINTF): Use it instead of wcslen.
20685
20686 2003-11-16  Bruno Haible  <bruno@clisp.org>
20687
20688         * lib/xsize.h (xmax): New function.
20689         (xsum, xsum3, xsum4): Declare as "pure" functions.
20690
20691 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20692
20693         * modules/xalloc (Files): Undo latest change, since xalloc.h
20694         no longer needs SIZE_MAX or PTRDIFF_MAX.
20695
20696 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20697
20698         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
20699         gl_PTRDIFF_MAX.
20700
20701 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20702
20703         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
20704         "return", to pacify some unknown compiler.  Problem reported
20705         by Joerg Schilling.
20706
20707 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20708
20709         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
20710         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
20711         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
20712         heuristic is just as accurate as far as we know, and it removes a
20713         dependency on size_max.m4 and ptrdiff_max.m4.
20714
20715 2003-11-11  Bruno Haible  <bruno@clisp.org>
20716
20717         * modules/xsize (Files): Add m4/size_max.m4.
20718         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
20719
20720 2003-11-11  Bruno Haible  <bruno@clisp.org>
20721
20722         * m4/size_max.m4: New file.
20723         * m4/ptrdiff_max.m4: New file.
20724         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
20725         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
20726         (gl_XALLOC): Invoke it.
20727
20728 2003-11-11  Bruno Haible  <bruno@clisp.org>
20729
20730         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
20731         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
20732         defined.
20733
20734 2003-11-10  Paul Eggert  <eggert@twinsun.com>
20735
20736         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
20737         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
20738         rejected some allocations of exactly SIZE_MAX - 2 bytes.
20739         From Bruno Haible.
20740         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
20741         not (size_t) -1, since it's defined here.
20742
20743 2003-11-09  Karl Berry  <karl@gnu.org>
20744
20745         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
20746
20747 2003-11-06  Paul Eggert  <eggert@twinsun.com>
20748
20749         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
20750         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
20751         Reject sizes of exactly SIZE_MAX bytes.
20752         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
20753         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
20754
20755 2003-11-05  Bruno Haible  <bruno@clisp.org>
20756
20757         * lib/xsize.h: Include limits.h, to avoid a possible collision with
20758         SIZE_MAX defined in <limits.h> on Solaris.
20759
20760 2003-11-04  Jim Meyering  <jim@meyering.net>
20761
20762         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
20763         variable names, rather than @VAR@.
20764         * modules/poll: Likewise.
20765
20766 2003-11-04  Bruno Haible  <bruno@clisp.org>
20767
20768         * modules/xsize: New file.
20769         * modules/linebreak: Depend on xsize.
20770         * MODULES.html.sh (func_all_modules): Add xsize.
20771
20772 2003-11-04  Bruno Haible  <bruno@clisp.org>
20773
20774         * m4/xsize.m4: New file.
20775
20776 2003-11-04  Bruno Haible  <bruno@clisp.org>
20777
20778         * lib/xsize.h: New file.
20779         * lib/linebreak.c: Include xsize.h.
20780         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
20781         argument for overflow.
20782         Suggested by Paul Eggert.
20783
20784 2003-11-03  Karl Berry  <karl@gnu.org>
20785
20786         * config/config.{guess,sub}: update from config.
20787
20788 2003-11-03  Jim Meyering  <jim@meyering.net>
20789
20790         * modules/userspec (lib_SOURCES): Add userspec.h.
20791         (Include): Add "userspec.h".
20792         Improve description.
20793
20794 2003-11-03  Jim Meyering  <jim@meyering.net>
20795
20796         * lib/userspec.c: Include "userspec.h".
20797         * lib/userspec.h: New file.
20798
20799 2003-11-03  Bruno Haible  <bruno@clisp.org>
20800
20801         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
20802
20803 2003-11-03  Bruno Haible  <bruno@clisp.org>
20804
20805         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
20806         available, to avoid (extremely rare) race condition.
20807         Suggested by Paul Eggert.
20808
20809 2003-11-02  Karl Berry  <karl@gnu.org>
20810
20811         * config/srclist.txt (vasprintf.c): sync broken, sigh.
20812
20813 2003-10-31  Paul Eggert  <eggert@twinsun.com>
20814
20815         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
20816         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
20817         (read_filesystem_list): Set and use me_type_malloced.
20818         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
20819         whatever the type happens to be), for brevity and consistency.
20820         Check for size calculation overflow on Alphas running OSF/1.
20821
20822 2003-10-31  Jim Meyering  <jim@meyering.net>
20823
20824         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
20825
20826         * lib/linebuffer.c: Include <string.h> for declaration of memset.
20827
20828 2003-10-30  Paul Eggert  <eggert@twinsun.com>
20829             Bruno Haible  <bruno@clisp.org>
20830
20831         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
20832         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
20833
20834 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
20835
20836         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
20837         netbsd*-gnu*.  Suggested by Robert Millan.
20838
20839 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20840
20841         * modules/group-member: Depend on stdbool.
20842
20843 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20844
20845         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
20846
20847 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20848
20849         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
20850         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
20851         after the 'gnu' in these cases.  This fixes some bugs in the
20852         previous change, and is based on suggestions by Robert Millan.
20853
20854 2003-10-29  Paul Eggert  <eggert@twinsun.com>
20855
20856         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
20857         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
20858         no longer needed.
20859         * lib/quotearg.c (quotearg_n_options): Use it.
20860         * lib/group-member.c: Include <stdbool.h>.
20861         (free_group_info): Arg is now const *; don't free arg.
20862         (get_group_info): Now returns bool and accepts struct group_info *,
20863         rather than returning a malloc'ed struct group_info *.
20864         All uses changed.  Check for overflow in internal size calculation.
20865
20866         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
20867         rather than xmalloc/xrealloc.
20868         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
20869         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
20870         conformance bug: the old code used a pointer after freeing the
20871         storage that it addressed.
20872         * lib/hash.c (hash_initialize): Simplify the code by using
20873         xalloc_oversized rather than doing it by hand.
20874         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
20875         the buffer preserved.  Use free and xmalloc instead.
20876         * lib/quotearg.c (quotearg_n_options): Likewise.
20877         Use a simpler test for size overflow.  Don't use xalloc_oversized
20878         because unsigned int might be wider than size_t (!); this suggests
20879         that we should switch from unsigned int to size_t for slot numbers.
20880
20881 2003-10-28  Paul Eggert  <eggert@twinsun.com>
20882
20883         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
20884         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
20885         NetBSD kernels.  Requested by Richard Stallman.
20886
20887 2003-10-27  Paul Eggert  <eggert@twinsun.com>
20888
20889         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
20890         to allocate the returned structure.  Do not allocate a subarray,
20891         as x2nrealloc will do that.
20892         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
20893         instead of xnrealloc.
20894         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
20895
20896 2003-10-27  Bruno Haible  <bruno@clisp.org>
20897
20898         * lib/stdbool_.h: Better support for BeOS.
20899
20900 2003-10-26  Paul Eggert  <eggert@twinsun.com>
20901
20902         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
20903         now uses inline.
20904
20905 2003-10-26  Paul Eggert  <eggert@twinsun.com>
20906
20907         * lib/xalloc.h (xalloc_oversized): New static inline function, for
20908         callers that want to do their own size-overflow checking.  Include
20909         <stdbool.h>, since xalloc_oversized returns bool.
20910         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
20911         to use xalloc_oversized.
20912
20913         Add two functions x2realloc, x2nrealloc, for programs that grow
20914         arrays dynamically by doubling their sizes.
20915         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
20916         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
20917         New functions.
20918
20919         Port to C99 semantics for 'inline' of external functions.
20920         Bug reported by Bruno Haible.
20921         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
20922         with the old contents of xnmalloc.
20923         (xnmalloc, xmalloc): Use it.
20924         (xnrealloc_inline): New static inline function,
20925         with the old contents of xnrealloc.
20926         (xnrealloc, xrealloc): Use it.
20927
20928         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
20929         that.
20930
20931 2003-10-26  Karl Berry  <karl@gnu.org>
20932
20933         * config/srclist.txt (COPYING.DOC): no longer available from
20934         /gd/gnuorg; don't know where the ultimate source is.
20935
20936 2003-10-25  Paul Eggert  <eggert@twinsun.com>
20937
20938         Fix several address-calculation bugs in the hash modules,
20939         plus some minor code cleanup.
20940
20941         * lib/hash.h: Include <stdbool.h>, for bool.
20942         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
20943         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
20944         hash_get_n_entries, hash_get_max_bucket_length,
20945         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
20946         hash_rehash): Use size_t rather than unsigned.
20947         * lib/hash.c (struct hash_table, hash_get_n_buckets,
20948         hash_get_n_buckets_used, hash_get_n_entries,
20949         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
20950         hash_get_entries, hash_do_for_each, hash_string, is_prime,
20951         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
20952         Likewise.
20953         (SIZE_MAX): Define if not defined.
20954         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
20955         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
20956         hash_print):
20957         Use const * when possible.
20958         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
20959         (check_tuning): Fix bug: if tuning parameters were very close to
20960         0 or 1, rounding errors could have caused subscript violations.
20961         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
20962         (hash_initialize): Add 'fail:' label
20963         to free table and return NULL, and use it to simplify code.
20964         Use calloc rather than clearing the storage ourself.
20965         (hash_initialize, hash_rehash): Check for arithmetic overflow in
20966         buffer size calculations.
20967         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
20968         Include <stddef.h>, for size_t.
20969         * lib/hash-pjw.c (hash_pjw): Likewise.
20970         Switch to method described by Bruno Haible.
20971         Include <limits.h>, for CHAR_BIT.
20972         (SIZE_BITS): New macro.
20973
20974 2003-10-23  Paul Eggert  <eggert@twinsun.com>
20975
20976         * m4/getline.m4 (AM_FUNC_GETLINE):
20977         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
20978         hosts.  Problem reported by Derek Robert Price in
20979         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
20980         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
20981         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
20982
20983 2003-10-21  Paul Eggert  <eggert@twinsun.com>
20984
20985         * lib/getndelim2.c (getndelim2): When size calculation overflows,
20986         ceiling the allocation at NMAX bytes rather than silently
20987         discarding input bytes before NMAX is reached.  This makes
20988         a difference only if NMAX exceeds SIZE_MAX / 2.
20989
20990         * lib/obstack.c: Merge from glibc.
20991         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
20992         Add libc_hidden_def (_obstack_newchunk).
20993         (_obstack_free) [! defined _LIBC]: Remove.
20994         [defined _LIBC]: Make a strong alias from obstack_free, rather than
20995         a clone of the function body.
20996         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
20997         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
20998
20999         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
21000         glibc.
21001         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
21002         arg to memcpy.
21003
21004         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
21005         (obstack_ptr_grow_fast, obstack_int_grow_fast):
21006         Don't use lvalue casts, as GCC plans to remove support for them
21007         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
21008         was also present in the non-GCC version, indicating that this
21009         code had always been buggy and had never been widely used.
21010         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
21011         Use the fast variant of each macro, rather than copying the
21012         definiens of the fast variant; that way, we'll be more likely to
21013         catch future bugs in the fast variants.
21014
21015 2003-10-20  Bruno Haible  <bruno@clisp.org>
21016
21017         * modules/wait-process: New file.
21018         * MODULES.html.sh (func_all_modules): Add wait-process.
21019
21020 2003-10-20  Bruno Haible  <bruno@clisp.org>
21021
21022         * m4/wait-process.m4: New file.
21023
21024 2003-10-20  Bruno Haible  <bruno@clisp.org>
21025
21026         * lib/wait-process.h: New file, from GNU gettext.
21027         * lib/wait-process.c: New file, from GNU gettext.
21028
21029 2003-10-19  Jim Meyering  <jim@meyering.net>
21030
21031         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
21032         HPUX 10.20.
21033
21034 2003-10-18  Karl Berry  <karl@gnu.org>
21035
21036         * config/config.guess: update from config.
21037
21038 2003-10-16  Paul Eggert  <eggert@twinsun.com>
21039
21040         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
21041         (getgroups): First arg is int, not size_t.
21042         Don't let 'free' mangle errno.
21043
21044 2003-10-16  Paul Eggert  <eggert@twinsun.com>
21045
21046         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
21047
21048 2003-10-16  Karl Berry  <karl@gnu.org>
21049
21050         * config/config.{guess,sub}: update from config.
21051
21052 2003-10-16  Jim Meyering  <jim@meyering.net>
21053
21054         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
21055         memcpy.
21056
21057 2003-10-15  Paul Eggert  <eggert@twinsun.com>
21058
21059         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
21060         (SIZE_MAX): Remove.
21061         (new_exclude, add_exclude_file): Initial size no longer needs to
21062         be a power of 2.
21063         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
21064         our own address arithmetic overflow checking.
21065
21066         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
21067         (fnmatch): Do not alloca more than 2000 wide characters;
21068         instead, use malloc for large buffers.
21069         Check for address arithmetic overflow, and return -1
21070         with errno set to ENOMEM in that case.
21071         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
21072         (NEW_PATTERN): Do not alloca more than 8000 bytes;
21073         instead, return -1.  Check for address arithmetic overflow.
21074
21075 2003-10-14  Paul Eggert  <eggert@twinsun.com>
21076
21077         Handle invalid suffixes and overflow independently, so that
21078         callers can treat them independently as needed.  Fix some bugs in
21079         suffix handling, e.g., "100k@" was not diagnosed as an invalid
21080         suffix for a human-readable blocksize.  The major caller-visible
21081         change is the addition of a new
21082         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
21083         that both overflow and suffix chars were found.
21084
21085         * lib/human.c (humblock): Don't check separately for invalid suffix
21086         char; that is xstrtoumax's job (now that its bug is fixed).
21087         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
21088         INTMAX_MAX]: New macros.
21089         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
21090         TYPE_MAXIMUM): New macros.
21091         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
21092         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
21093         if overflow occurs, as it's what __strtol does and it's more useful
21094         in practice.
21095         (__xstrtol): If __strtol reports some error other than ERANGE,
21096         reflect it to the caller as LONGINT_INVALID.  If it reports
21097         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
21098         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
21099         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
21100         value.
21101         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
21102         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
21103         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
21104         [defined UINTMAX_MAX]: New macros.
21105
21106 2003-10-14  Bruno Haible  <bruno@clisp.org>
21107
21108         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
21109
21110 2003-10-14  Bruno Haible  <bruno@clisp.org>
21111
21112         * m4/sig_atomic_t: New file, from GNU gettext.
21113         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
21114
21115 2003-10-14  Bruno Haible  <bruno@clisp.org>
21116
21117         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
21118         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
21119         Also use volatile where needed.
21120
21121 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21122
21123         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
21124         Change maintainer from Bruno Haible to 'all'.
21125
21126 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21127
21128         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
21129
21130 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21131
21132         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
21133         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
21134         and define in terms of the other primitives.
21135         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
21136         (SIZE_MAX): Define if not already defined.
21137         (array_size_overflow): New function.
21138         (xalloc_die): Abort instead of exiting if 'error' returns.
21139         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
21140         (xmalloc, xrealloc): Use them.
21141         (xcalloc): Check for address arithmetic overflow.
21142         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
21143         a bit faster than strcpy.
21144
21145 2003-10-10  Simon Josefsson  <jas@extundo.com>
21146
21147         * modules/argp (Depends-on): Add restrict and strcase.
21148
21149 2003-10-10  Simon Josefsson  <jas@extundo.com>
21150
21151         * m4/argp.m4: Add AC_C_INLINE.
21152
21153 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21154
21155         Merge getpass from libc, plus a few fixes.
21156
21157         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
21158         Include <stdbool.h>.
21159         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
21160         __fsetlocking to empty.
21161         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
21162         do include <bits/libc-lock.h>.
21163         Do not include <fcntl.h>; not needed.
21164         [_LIBC]: Include <wchar.h>.
21165         (NOTCANCEL_MODE): New macro.
21166         (flockfile, funlockfile) [_LIBC]: New macros.
21167         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
21168         [!_LIBC]: New macros.
21169         (call_fclose): New function.
21170         (getpass): Use it.  Save tty stream separately; this simplifies the
21171         code and makes it more reliable if stdin happens to equal stdout.
21172         Invoke __fsetlocking on tty.
21173         Handle thread cancellation if needed.
21174         Namespace cleanup (use __tcgetattr, __getline).
21175         Use bool for Booleans.
21176         [USE_IN_LIBIO]: Handle wide streams.
21177         [!_LIBC]: Unconditionally do the fseek, since we don't know what
21178         stream might go where.
21179
21180         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
21181         doesn't have to include <stdio.h> before us.
21182         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
21183         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
21184         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
21185         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
21186         if not declared, so that we can use getpass.c code from libc without
21187         rewriting it.
21188         (flockfile, ftrylockfile, funlockfile): New macros.
21189
21190 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21191
21192         * modules/getpass: Depend on stdbool.
21193
21194 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21195
21196         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
21197
21198 2003-10-07  Karl Berry  <karl@gnu.org>
21199
21200         * config/config.{guess,sub}: update from config.
21201
21202 2003-10-06  Jim Meyering  <jim@meyering.net>
21203             Bruno Haible  <bruno@clisp.org>
21204
21205         This lets translators provide better translations for the
21206         "Written by ..." part of --version output.
21207         * lib/version-etc.h: Include stdarg.h.
21208         (version_etc_copyright): Declare as readonly.
21209         (version_etc): Make this function variadic with a NULL-terminated list
21210         of author name strings.
21211         (version_etc_va): New declaration.
21212         * lib/version-etc.c: Include stdarg.h, stdlib.h.
21213         (version_etc_copyright): Declare as readonly.
21214         (version_etc_va): New function. Provide a different translatable string
21215         for each possible number of authors < 10. Abbreviate when there are 10
21216         authors or more.
21217         (version_etc): Make this function variadic. Call version_etc_va.
21218         Suggestion from Gary V. Vaughan.
21219
21220         * lib/long-options.h (parse_long_options): Change prototype: the
21221         authors string is moved to the end and becomes variadic.
21222         * lib/long-options.c: Include stdarg.h.
21223         (parse_long_options): Make this function variadic, too.
21224         Call version_etc_va, not version_etc.
21225
21226 2003-10-06  Bruno Haible  <bruno@clisp.org>
21227
21228         * modules/version-etc-2: Remove file.
21229         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
21230
21231 2003-10-06  Bruno Haible  <bruno@clisp.org>
21232
21233         * modules/fatal-signal: New file.
21234         * MODULES.html.sh (func_all_modules): Add fatal-signal.
21235
21236 2003-10-06  Bruno Haible  <bruno@clisp.org>
21237
21238         * m4/fatal-signal.m4: New file.
21239         * m4/signalblocking.m4: New file, from GNU gettext.
21240
21241 2003-10-06  Bruno Haible  <bruno@clisp.org>
21242
21243         * lib/version-etc-2.h: Remove file.
21244         * lib/version-etc-2.c: Remove file.
21245
21246 2003-10-06  Bruno Haible  <bruno@clisp.org>
21247
21248         * lib/fatal-signal.h: New file, from GNU gettext.
21249         * lib/fatal-signal.c: New file, from GNU gettext.
21250
21251 2003-10-05  Paul Eggert  <eggert@twinsun.com>
21252
21253         * README: Rework advice for preventing empty .o files.
21254         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
21255         not <sys/types.h>.
21256
21257 2003-10-04  Karl Berry  <karl@gnu.org>
21258
21259         * lib/argp*: update from libc.
21260
21261 2003-10-04  Karl Berry  <karl@gnu.org>
21262
21263         * config/config.{guess,sub}: update from config.
21264
21265 2003-10-02  Bruno Haible  <bruno@clisp.org>
21266
21267         * modules/lchown (Include): Add lchown.h.
21268         * modules/time_r (Include): Use "..." syntax.
21269         * modules/xgetdomainname (Include): Add xgetdomainname.h.
21270
21271 2003-10-01  Simon Josefsson  <jas@extundo.com>
21272
21273         * MODULES.html.sh (func_all_modules): Move gethostname from section
21274         'based on' to section 'lacking' POSIX:2001.
21275
21276 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
21277
21278         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
21279         to output mode on the same stream.
21280
21281 2003-09-29  Paul Eggert  <eggert@twinsun.com>
21282
21283         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
21284         Fix arg typo in previous patch.
21285
21286 2003-09-28  Jim Meyering  <jim@meyering.net>
21287
21288         * lib/error.c: Correct cpp indentation.
21289
21290 2003-09-27  Paul Eggert  <eggert@twinsun.com>
21291
21292         * modules/free: New file.
21293
21294 2003-09-27  Paul Eggert  <eggert@twinsun.com>
21295
21296         * m4/free.m4: New file.
21297
21298 2003-09-27  Paul Eggert  <eggert@twinsun.com>
21299
21300         * lib/minmax.h (MIN, MAX)
21301         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
21302         Omit the special code that used __typeof__, since we worry that
21303         it could be more trouble than it's worth.  See:
21304         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
21305         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
21306
21307         * lib/free.c: New file.
21308
21309 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
21310
21311         Trivial fixes to Makefile.am parts of module listings.
21312         * modules/strstr: Append strstr.h to lib_SOURCES.
21313         * modules/strcase: Likewise, for strcase.h.
21314
21315 2003-09-27  Karl Berry  <karl@gnu.org>
21316
21317         * config/mkinstalldirs: update from automake.
21318
21319 2003-09-26  Paul Eggert  <eggert@twinsun.com>
21320
21321         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
21322         (error_tail): Do not loop, reallocating temporary buffer, since
21323         the output cannot contain more wide characters than the input
21324         contains bytes, the size must be big enough already.  This avoids
21325         one potential size overflow calculation.  Check for size overflow
21326         when calculating temporary buffer size.  Free temporary buffer
21327         when done, if it was allocated with malloc; this plugs a memory
21328         leak.  Remove casts from void * to pointers, that are no longer
21329         needed now that we're assuming C89 or better.
21330
21331         Merge error changes from glibc.
21332
21333         * lib/error.c, error.h: Update copyright notice header to match glibc.
21334         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
21335         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
21336         Disable cancellation while printing error.
21337         * lib/error.h: Prepend __ to parameter names.
21338
21339 2003-09-26  Jim Meyering  <jim@meyering.net>
21340
21341         * lib/error.c (error_tail): Move some declarations
21342         into inner scope where the local variables are used.
21343
21344 2003-09-26  Bruno Haible  <bruno@clisp.org>
21345
21346         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
21347         stpncpy().
21348         Don't define stpncpy through config.h; it's now done through stpncpy.h.
21349
21350 2003-09-26  Bruno Haible  <bruno@clisp.org>
21351
21352         * lib/stpncpy.h (gnu_stpncpy): New declaration.
21353         (stpncpy): Define as alias for gnu_stpncpy.
21354         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
21355
21356 2003-09-25  Simon Josefsson  <jas@extundo.com>
21357
21358         * lib/xgetdomainname.h: New file.
21359         * lib/xgetdomainname.c: New file.
21360
21361 2003-09-25  Simon Josefsson  <jas@extundo.com>
21362             Bruno Haible  <bruno@clisp.org>
21363
21364         * modules/getdomainname: New file.
21365         * modules/xgetdomainname: New file.
21366         * MODULES.html.sh (func_all_modules): Add getdomainname,
21367         xgetdomainname.
21368
21369 2003-09-25  Simon Josefsson  <jas@extundo.com>
21370             Bruno Haible  <bruno@clisp.org>
21371
21372         * m4/getdomainname.m4: New file.
21373
21374 2003-09-25  Simon Josefsson  <jas@extundo.com>
21375             Bruno Haible  <bruno@clisp.org>
21376
21377         * lib/getdomainname.h: New file.
21378         * lib/getdomainname.c: New file.
21379
21380 2003-09-25  Karl Berry  <karl@gnu.org>
21381
21382         * lib/argp-fmtstream.c, argp-help.c: update from libc.
21383
21384 2003-09-25  Karl Berry  <karl@gnu.org>
21385
21386         * config/install-sh: update from automake.
21387
21388 2003-09-25  Bruno Haible  <bruno@clisp.org>
21389
21390         * modules/version-etc-2: New file, from modules/version-etc with
21391         modifications.
21392         * MODULES.html.sh (func_all_modules): Add version-etc-2.
21393
21394 2003-09-25  Bruno Haible  <bruno@clisp.org>
21395
21396         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
21397         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
21398
21399 2003-09-24  Simon Josefsson  <jas@extundo.com>
21400
21401         * modules/xgethostname: Add xgethostname.h.
21402
21403 2003-09-24  Paul Eggert  <eggert@twinsun.com>
21404
21405         * lib/linebuffer.c (freebuffer): Don't free the argument, just
21406         the buffer associated with the argument.  Bug reported by
21407         Simon Josefsson.
21408
21409 2003-09-24  Paul Eggert  <eggert@twinsun.com>
21410
21411         * README: Document assumptions that 'int' is at least 32 bits
21412         wide, that integer arithmetic is 2's complement without overflow,
21413         that there are no holes in integer values, that adding sizes of
21414         two nonoverlapping objects can't overflow, and that all-bits-zero
21415         yields scalar zero.  Fix spelling and capitalization typos.
21416
21417 2003-09-19  Karl Berry  <karl@gnu.org>
21418
21419         * lib/argp.h: update from libc.
21420
21421 2003-09-17  Paul Eggert  <eggert@twinsun.com>
21422
21423         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
21424         to avoid spurious warnings like "AC_RUN_IFELSE was called before
21425         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
21426
21427 2003-09-17  Paul Eggert  <eggert@twinsun.com>
21428
21429         * gnulib-tool: Use "test -h", not "test -L", for portability
21430         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
21431         (tags_regexp): Remove, since \| doesn't conform to POSIX.
21432         (sed_extract_prog): Issue s commands one-by-one, rather than
21433         using \| in one s command.
21434
21435 2003-09-16  Paul Eggert  <eggert@twinsun.com>
21436
21437         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
21438         input error, instead of returning NULL the next time we are called
21439         (and therefore losing track of errno).
21440
21441 2003-09-16  Bruno Haible  <bruno@clisp.org>
21442
21443         * gnulib-tool (func_create_testdir): Warn about duplicated
21444         dependencies.
21445
21446 2003-09-15  Paul Eggert  <eggert@twinsun.com>
21447
21448         * modules/argmatch, modules/fatal, modules/obstack,
21449         modules/xalloc, modules/xgethostname: Sort dependencies by
21450         importance, not alphabetically.
21451
21452 2003-09-15  Paul Eggert  <eggert@twinsun.com>
21453
21454         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
21455         fails, so that the caller gets the proper errno.
21456
21457         * lib/readutmp.c (read_utmp): Likewise.
21458         Check for fstat error.  Close stream and free storage
21459         when failing.
21460
21461 2003-09-14  Karl Berry  <karl@gnu.org>
21462
21463         * config/srclist.txt (strdup.c): disable for c89 changes.
21464
21465 2003-09-14  Jim Meyering  <jim@meyering.net>
21466
21467         * lib/getloadavg.c: Correct cpp indentation.
21468         * lib/strdup.c: Likewise.
21469         * lib/vasnprintf.c: Likewise.
21470
21471 2003-09-14  Bruno Haible  <bruno@clisp.org>
21472
21473         * modules/fwriteerror: New file.
21474         * MODULES.html.sh (func_all_modules): Add fwriteerror.
21475
21476 2003-09-14  Bruno Haible  <bruno@clisp.org>
21477
21478         * lib/fwriteerror.h: New file.
21479         * lib/fwriteerror.c: New file.
21480
21481 2003-09-12  Paul Eggert  <eggert@twinsun.com>
21482
21483         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
21484         modules/xgethostname, modules/xalloc: Depend on exit.
21485
21486 2003-09-12  Paul Eggert  <eggert@twinsun.com>
21487
21488         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
21489
21490         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
21491         and AC_MINIX, too, so that their extensions are available.
21492
21493         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
21494         This macro has been superseded by gl_BACKUPFILE.
21495
21496         More patches to assume C89 or better.
21497
21498         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
21499
21500         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
21501         unconditionally.
21502         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
21503         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
21504         Include <string.h>, <stdlib.h> unconditionally.
21505         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
21506         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
21507         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
21508         headers or for string.h.
21509         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
21510         or strtoul.
21511
21512         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
21513         headers.
21514         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
21515         * m4/userspec.m4 (gl_USERSPEC): Likewise.
21516         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
21517         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
21518         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
21519         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
21520         memcpy, memset.
21521         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
21522         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
21523         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
21524         strtol.
21525         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
21526         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
21527         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
21528         strtoul.
21529
21530 2003-09-12  Paul Eggert  <eggert@twinsun.com>
21531
21532         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
21533         * lib/obstack.c [!defined _LIBC]: Likewise.
21534         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
21535         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
21536         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
21537
21538         More changes to assume C89 or better.
21539
21540         * lib/error.c (error_tail): Assume vprintf.
21541
21542         * lib/argmatch.c (getenv): Remove decl.
21543         * lib/progreloc.c (get_full_program_name): Define via prototype.
21544         * lib/setenv.c (clearenv): Likewise.
21545         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
21546         needed.
21547         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
21548         (malloc, memcpy): Remove decls.
21549         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
21550         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
21551         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
21552         (memcpy): Remove macro.
21553         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
21554         (__P): Remove.  All uses removed.
21555         (PTR): Remove.  All uses changed to void *.
21556         (CHAR_BIT, NULL): Remove.
21557         (spaces, zeros, memset_space, memset_zero)
21558         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
21559         Remove.
21560         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
21561         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
21562         Define with prototype.
21563         Remove now-unnecessary prototype decl.
21564         (extra_args_spec): Assume ANSI C.  All uses changed.
21565         (extra_args_spec_iso): Remove.
21566         (my_strftime, emacs_strftimeu): Define via prototype.
21567         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
21568         unconditionally.
21569         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
21570         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
21571         (strtoul, strtol): Remove decls.
21572         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
21573         LONG_MAX): Remove.
21574         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
21575         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
21576         (LOCALE_PARAM_PROTO): New macro.
21577         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
21578         (INTERNAL (strtol), strtol): Define with a prototype.
21579         (PARAMS): Remove.  All uses removed.
21580         * lib/tempname.c: Include <string.h> unconditionally.
21581         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
21582         * lib/xgethostname.c (main): Define with a prototype.
21583         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
21584         Include <stdlib.h> unconditionally.
21585         (calloc, malloc, realloc, free): Remove decls.
21586         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
21587         Include <stdlib.h> unconditionally.  Sort include file names.
21588         (strtod): Remove.
21589         (xstrtod): Define with a prototype.
21590         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
21591         (strtol, strtoul): Remove decls.
21592
21593 2003-09-11  Paul Eggert  <eggert@twinsun.com>
21594
21595         More patches to assume C89 or better.
21596         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
21597         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
21598         string.h, memchr, STDC_HEADERS.
21599
21600 2003-09-11  Paul Eggert  <eggert@twinsun.com>
21601
21602         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
21603         Include <stdlib.h>, <string.h> unconditionally.
21604         Remove now-unnecessary cast to char *.
21605         * lib/strnlen.c: Include <string.h> unconditionally.
21606         * lib/yesno.c (yesno): Define with a prototype.
21607
21608 2003-09-11  Bruno Haible  <bruno@clisp.org>
21609
21610         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
21611
21612 2003-09-10  Jim Meyering  <jim@meyering.net>
21613
21614         * lib/error.c: Correct indentation of cpp directives.
21615
21616 2003-09-10  Bruno Haible  <bruno@clisp.org>
21617
21618         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
21619         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
21620         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
21621         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
21622         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
21623         <stdlib.h> and <string.h> checks.
21624         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
21625         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
21626
21627 2003-09-10  Bruno Haible  <bruno@clisp.org>
21628
21629         * lib/strcspn.c: Include <string.h> unconditionally.
21630         * lib/strpbrk.c: Include <string.h> unconditionally.
21631         * lib/strstr.c: Include <string.h> unconditionally.
21632         * lib/unicodeio.c: Include <string.h> unconditionally.
21633         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
21634         * lib/unsetenv.c: Likewise.
21635         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
21636         * lib/yesno.c: Include <stdlib.h> unconditionally.
21637         (rpmatch): Add prototype.
21638
21639 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21640
21641         More patches to assume C89 or better.
21642         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
21643         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
21644         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
21645         or for string.h.
21646         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
21647         stdlib.h.
21648         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
21649         C headers.
21650         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
21651         string.h.
21652         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
21653         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
21654         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
21655         or for string.h.
21656         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
21657         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
21658         C headers.
21659         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
21660         memcpy.
21661         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
21662         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
21663         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
21664         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
21665         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
21666         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
21667         string.h, free.
21668         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
21669         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
21670         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
21671         C headers, or for string.h.
21672         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
21673         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
21674         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
21675         headers, memory.h, stdlib.h, string.h, strings.h.
21676         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
21677         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
21678         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
21679         strchr.
21680         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
21681         headers, memory.h, string.h.
21682         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
21683         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
21684         free.
21685         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
21686         headers.
21687         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
21688         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
21689         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
21690         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
21691         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
21692
21693 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21694
21695         More K&R removal.
21696
21697         * lib/acosl.c (main): Use a prototype.
21698         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
21699         tanl.c: Likewise.
21700
21701         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
21702
21703         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
21704         (getopt, etopt_long, getopt_long_only, _getopt_internal)
21705         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
21706         with a prototype.
21707         * lib/getopt.c (const): Remove macro.
21708         Include <string.h> unconditionally.
21709         (my_index): Remove; all uses changed to strchr.
21710         (strlen): Remove decl.
21711         (exchange): Remove forward decl; no longer needed.
21712         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
21713         Define with prototype.
21714         * lib/getopt1.c (const): Remove macro.
21715         (getopt_long, getopt_long_only, main): Define with prototype.
21716
21717         * lib/getugroups.c: Include <string.h> unconditionally.
21718
21719         * lib/getusershell.c: Include <stdlib.h> unconditionally.
21720         (getusershell, setusershell, endusershell, readname, main):
21721         Define with prototypes.
21722
21723         * lib/group-member.c: Include group-member.h first.
21724         Include <stdlib.h> unconditionally.
21725
21726         * lib/hard-locale.c: Include hard-locale.h first.
21727         Include <stdlib.h>, <string.h> unconditionally.
21728
21729         * lib/hash.c (free, malloc): Remove decls.
21730         Include <stdlib.h> unconditionally.
21731
21732         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
21733         (getenv): Do not declare.
21734
21735         * lib/idcache.c: Include <string.h> unconditionally.
21736
21737         * lib/long-options.c: Include long-options.h first, to test interface.
21738         Include <stdlib.h> unconditionally.
21739
21740         * lib/makepath.c: Include makepath.h first, to test interface.
21741         Include <stdlib.h> and <string.h> unconditionally.
21742
21743         * lib/linebuffer.c: Include <stdlib.h>.
21744         (free): Remove decl.
21745
21746         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
21747         stddef.h. rpl_malloc returns void *, not char *.
21748         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
21749         prototype.
21750
21751         * lib/md5.h: Include <limits.h> unconditionally.
21752         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
21753         (__P): Remove; all uses removed.
21754         * lib/md5.c: Include "md5.h" first.
21755         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
21756         md5_buffer, md5_process_bytes, md5_process_block):
21757         Define with prototypes.
21758         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
21759         * lib/sha.c: Include "sha.h" first.
21760         Include <stdlib.h>, <string.h> unconditionally.
21761
21762         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
21763         * lib/memcmp.c (__ptr_t): Likewise.
21764         * lib/memrchr.c (__ptr_t): Likewise.
21765         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
21766         Include <string.h> unconditionally.
21767         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
21768         * lib/memchr.c: Include <stdlib.h> unconditionally.
21769         * lib/memchr.c (LONG_MAX): Remove.
21770         * lib/memrchr.c (LONG_MAX): Likewise.
21771         * lib/memchr.c (__memchr): Define via a prototype.
21772         * lib/memrchr.c (__memrchr): Likewise.
21773         * lib/memcmp.c (__P): Remove, and remove all uses.
21774         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
21775         Remove forward decls; no longer needed.
21776         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
21777         Use types required by C89 in prototype.
21778
21779         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
21780         * lib/savedir.c: Likewise.
21781         * lib/mkdir.c (free): Remove decl.
21782         * lib/rmdir.c (rmdir): Define with a prototype.
21783         * lib/savedir.c: Include savedir.h first, to test interface.
21784
21785         * lib/mktime.c (STDC_HEADERS): Remove.
21786         Include <stdlib.h>, <string.h> unconditionally.
21787
21788         * lib/modechange.c: Include <stdlib.h> unconditionally.
21789         (malloc): Remove decl.
21790
21791         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
21792         (free): Remove decl.
21793
21794         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
21795         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
21796         (This type really should be intptr_t, but that's a C99ism.)
21797         (_obstack_memcpy): Remove: all uses changed to memcpy.
21798         Include <string.h> unconditionally.
21799         (struct obstack): Assume __STDC__ for types of members
21800         chunkfun, freefun, extra_arg.
21801         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
21802         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
21803         obstack_begin, obstack_specify_allocation,
21804         obstack_specify_allocation_with_arg, obstack_chunkfun,
21805         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
21806         Remove unprototyped decls and the macros that use them.
21807         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
21808         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
21809         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
21810         (defined __STDC__ && __STDC__)]:
21811         Remove nonprototyped code.
21812         Include <stdlib.h> unconditionally.
21813         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
21814         _obstack_allocated_p, _obstack_free, obstack_free,
21815         _obstack_memory_used, print_and_abort):
21816         Define using prototypes.
21817         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
21818         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
21819         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
21820         obstack_next_free, obstack_object_size, obstack_room) [0]:
21821         Remove unused, unprototyped code.
21822
21823         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
21824
21825         * lib/physmem.c (physmem_total, physmem_available, main): Define
21826         with prototypes.
21827
21828         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
21829         (main): Define with a prototype.
21830
21831         * lib/posixver.c (getenv): Remove decl.
21832
21833         * lib/putenv.c (malloc): Returns void *, not char *.
21834         Include <string.h> unconditionally.
21835         (strchr, memcpy, NULL): Do not define.
21836
21837         * lib/readtokens.c: Include readtokens.h first, to test interface.
21838         Include <stdlib.h>, <string.h> unconditionally.
21839         (init_tokenbuffer): Define with a prototype.
21840
21841         * lib/regex.c (PARAMS): Remove.  All uses removed.
21842         All uses of _RE_ARGS removed, too.
21843         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
21844         unconditionally.
21845         (bzero): Assume memset exists.
21846         (memcmp, memcpy, NULL): Remove.
21847         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
21848         char, or assignments to local vars of type signed char.
21849         (init_syntax_once, PREFIX(extract_number_and_incr),
21850         PREFIX(print_partial_compiled_pattern),
21851         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
21852         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
21853         PREFIX(regex_grow_registers), PREFIX(regex_compile),
21854         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
21855         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
21856         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
21857         wcs_compile_range, byte_compile_range, truncate_wchar,
21858         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
21859         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
21860         count_mbs_length, wcs_re_match_2_internal,
21861         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
21862         PREFIX(alt_match_null_string_p),
21863         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
21864         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
21865         regfree, PREFIX(extract_number)): Define with prototype.  Remove
21866         now-unnecessary declaration, if any.
21867         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
21868         regcomp, regexec):
21869         Remove now-unnecessary casts among pointer types.
21870         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
21871
21872         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
21873         (free): Remove decl.
21874
21875         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
21876
21877         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
21878         (free): Remove decl.
21879
21880         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
21881         * lib/xgetcwd.c: Likewise.
21882
21883         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
21884         (free): Remove decl.
21885
21886         * lib/strchrnul.c (strchrnul): Define with a prototype.
21887         Fix bug: c_in was not converted to char before searching.
21888
21889         The following changes are not K&R related:
21890
21891         * lib/group-member.h: Include <sys/types.h>, so that this file is
21892         self-contained.
21893         * lib/makepath.h: Likewise.
21894
21895         * lib/getusershell.c (readname, default_index, line_size, readname):
21896         Use size_t, not int, for sizes.
21897         (readname): If the size overflows, report an error instead of
21898         looping forever.
21899
21900 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21901
21902         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
21903         libc.
21904
21905 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21906
21907         * README: New section: portability guidelines.
21908
21909 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
21910
21911         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
21912         C89 spec.
21913
21914 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
21915
21916         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
21917
21918 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21919
21920         Assume C89 or better; remove K&R cruft.
21921         A few of these changes were first proposed by Derek Robert Price
21922         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
21923
21924         * lib/addext.c: Include <string.h> unconditionally.
21925         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
21926         Don't declare getenv or malloc.
21927
21928         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
21929         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
21930         (NULL): Remove.
21931         (find_stack_direction, alloca): Use prototypes.
21932
21933         * lib/atexit.c (atexit): Define using a prototype.
21934
21935         * lib/basename.c, dirname.c, stripslash.c:
21936         Include <string.h> unconditionally.
21937
21938         * lib/bcopy.c: Include <stddef.h>.
21939         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
21940
21941         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
21942
21943         * lib/error.h (error, error_at_line, error_print_progname)
21944         [! (defined (__STDC__) && __STDC__)]: Remove decls.
21945         * lib/error.c: Include error.h first, to check interface.
21946         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
21947         (VA_START): Remove; all uses changeed to va_start.
21948         (exit, strerror): Remove decls.
21949         (error_print_progname): Prototype uncondionally.
21950         Don't include <errno.h>; no longer needed.
21951         (private_strerror): Remove.
21952         (error_tail): Always define.
21953         (error, error_at_line): Assume C89 or better; always use prototypes.
21954         * lib/fatal.c: Include "fatal.h" first, to test interface.
21955         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
21956         (VA_START): Remove; all uses changed to va_start.
21957         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
21958         this case.
21959         (exit): Remove decl.
21960         (fatal): Prototype unconditionally.  Assume va_start works.
21961         Abort at end, to pacify gcc.
21962
21963         * lib/euidaccess.c (main): Define with a prototype.
21964
21965         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
21966
21967         * lib/exitfail.c: Include <stdlib.h> unconditionally.
21968
21969         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
21970         prototypes.
21971         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
21972         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
21973         (getenv): Remove decl.
21974         (fnmatch): Define using a prototype.
21975         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
21976         (FCT): Define using a prototype.
21977
21978         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
21979
21980         * lib/gethostname.c: Include <stddef.h>.
21981         (gethostname): Define with prototype.  Length is size_t, not int.
21982
21983 2003-09-08  Paul Eggert  <eggert@twinsun.com>
21984
21985         Assume C89 or better; remove K&R cruft.
21986         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
21987         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
21988         string.h, getenv, malloc.
21989         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
21990         headers.
21991         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
21992         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
21993         do not check for strerror.
21994         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
21995         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
21996         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
21997         do not check for doprnt or vprintf.
21998         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
21999         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
22000
22001 2003-09-08  Paul Eggert  <eggert@twinsun.com>
22002
22003         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
22004         getversion.c should have been removed then, but was accidentally
22005         preserved.
22006
22007         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
22008         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
22009
22010 2003-09-08  Karl Berry  <karl@gnu.org>
22011
22012         * config/config.sub, config.guess, srclistvars.sh: update from savannah
22013                 config, forget about prep.
22014
22015         * config/depcomp, missing: update from automake.
22016
22017 2003-09-07  Paul Eggert  <eggert@twinsun.com>
22018
22019         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
22020         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
22021
22022 2003-09-07  Paul Eggert  <eggert@twinsun.com>
22023
22024         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
22025         copy_tm_result.  Bug reported by Simon Josefsson in
22026         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
22027
22028 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22029
22030         * m4/time_r.m4: New file.
22031         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
22032         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
22033         is. Check for timegm declaration.
22034         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
22035         Do not check for gmtime_r.
22036         Replace mktime if __mktime_internal does not exist and if mktime
22037         hasn't been replaced already.
22038
22039 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22040
22041         * lib/time_r.c, lib/time_r.h: New files.
22042
22043         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
22044         __localtime_r.
22045         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
22046         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
22047
22048         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
22049         __gmtime_r.
22050         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
22051         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
22052         Include <time_r.h>.
22053
22054         * lib/timegm.c: Switch to glibc implementation, with the following
22055         changes:
22056         [defined HAVE_CONFIG_H]: Include <config.h>.
22057         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
22058         (__mktime_internal) [!defined _LIBC]: New decl.
22059         (__gmtime_r) [!defined _LIBC]: New macro and function.
22060         (timegm): Use a prototype, since gnulib assumes C89.
22061         Do not bother declaring tmp to be const, as it's not really usefu.
22062         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
22063         (timegm): Declare only if HAVE_DECL_TIMEGM.
22064
22065 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22066
22067         * MODULES.html.sh (func_all_modules): Add time_r.
22068         * modules/time_r: New file.
22069         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
22070         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
22071
22072 2003-09-03  Paul Eggert  <eggert@twinsun.com>
22073
22074         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
22075         Bug reported by Lute Kamstra in
22076         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
22077
22078         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
22079         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
22080         course with correspondingly smaller numbers for tomorrow and
22081         yesterday.  From Tadayoshi Funaba.  Originally installed into
22082         sh-utils on 1999-08-07, but the patch got lost (I guess during the
22083         coreutils merge?).
22084
22085 2003-08-31  Simon Josefsson  <jas@extundo.com>
22086
22087         * modules/timegm: New file.
22088         * MODULES.html.sh (func_all_modules): Add timegm.
22089
22090 2003-08-31  Simon Josefsson  <jas@extundo.com>
22091
22092         * m4/timegm.m4: New file.
22093
22094 2003-08-31  Simon Josefsson  <jas@extundo.com>
22095
22096         * lib/timegm.h: New file.
22097         * lib/timegm.c: New file.  Based on
22098         wget-1.8.2/src/http.c:mktime_from_utc.
22099
22100 2003-08-31  Karl Berry  <karl@gnu.org>
22101
22102         * lib/argp.h: update from libc.
22103
22104 2003-08-28  Bruno Haible  <bruno@clisp.org>
22105
22106         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
22107         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
22108         followed by '#define fnmatch fnmatch_posix' gives an error.
22109
22110 2003-08-28  Bruno Haible  <bruno@clisp.org>
22111
22112         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
22113         warning on QNX, which defines O_BINARY to 000000.
22114
22115 2003-08-27  Jim Meyering  <jim@meyering.net>
22116
22117         * m4/mkstemp.m4: Require that the system mkstemp be able to create
22118         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
22119         would fail after 32.  Reported by Danny Levinson.  Details here:
22120         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
22121
22122 2003-08-24  Bruno Haible  <bruno@clisp.org>
22123
22124         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
22125         MSVC7 <stdio.h> is included later.
22126
22127 2003-08-22  Simon Josefsson  <jas@extundo.com>
22128
22129         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
22130
22131 2003-08-20  Karl Berry  <karl@gnu.org>
22132
22133         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
22134
22135 2003-08-20  Bruno Haible  <bruno@clisp.org>
22136
22137         * modules/progname: New file.
22138         * MODULES.html.sh (func_all_modules): Add progname.
22139
22140 2003-08-20  Bruno Haible  <bruno@clisp.org>
22141
22142         * lib/progname.h: New file, from GNU gettext.
22143         * lib/progname.c: New file, from GNU gettext.
22144         * lib/progreloc.c: New file, from GNU gettext.
22145
22146 2003-08-19  Jim Meyering  <jim@meyering.net>
22147
22148         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
22149         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
22150
22151 2003-08-19  Bruno Haible  <bruno@clisp.org>
22152
22153         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
22154         more.
22155
22156 2003-08-19  Bruno Haible  <bruno@clisp.org>
22157
22158         * lib/xstrdup.c: Assume <string.h> exists.
22159
22160 2003-08-18  Paul Eggert  <eggert@twinsun.com>
22161
22162         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
22163         in makefile rules.
22164
22165 2003-08-18  Jim Meyering  <jim@meyering.net>
22166
22167         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
22168         * m4/lib-ld.m4: Likewise.
22169
22170 2003-08-18  Jim Meyering  <jim@meyering.net>
22171
22172         * lib/setenv.h: Indent nested cpp directive.
22173         * lib/vasnprintf.c: Remove trailing blanks.
22174
22175 2003-08-17  Simon Josefsson  <jas@extundo.com>
22176
22177         * modules/xstrndup: New file.
22178         * MODULES.html.sh (func_all_modules): Add xstrndup.
22179
22180 2003-08-17  Simon Josefsson  <jas@extundo.com>
22181
22182         * modules/argp: Fix autoconf macro name. Add more dependencies.
22183
22184 2003-08-17  Simon Josefsson  <jas@extundo.com>
22185
22186         * m4/xstrndup.m4: New file.
22187
22188 2003-08-17  Simon Josefsson  <jas@extundo.com>
22189
22190         * m4/argp.m4: New file.
22191
22192 2003-08-17  Simon Josefsson  <jas@extundo.com>
22193             Bruno Haible  <bruno@clisp.org>
22194
22195         * lib/xstrndup.h: New file.
22196         * lib/xstrndup.c: New file.
22197
22198 2003-08-17  Bruno Haible  <bruno@clisp.org>
22199
22200         * modules/strndup (Files, Include): Add lib/strndup.h.
22201
22202 2003-08-17  Bruno Haible  <bruno@clisp.org>
22203
22204         * modules/euidaccess (Files): Add lib/euidaccess.h.
22205
22206 2003-08-17  Bruno Haible  <bruno@clisp.org>
22207
22208         * lib/strndup.h: New file.
22209
22210 2003-08-17  Bruno Haible  <bruno@clisp.org>
22211
22212         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
22213         like AC_GNU_SOURCE.
22214         * modules/extensions (configure.ac): Comment out the invocation of
22215         gl_USE_SYSTEM_EXTENSIONS.
22216
22217 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22218
22219         Merges from coreutils, etc.
22220         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
22221         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
22222         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
22223         fixing a typo.
22224         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
22225         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
22226
22227 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22228
22229         Document merge from coreutils.
22230         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
22231         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
22232         * modules/utime: Add m4/utimes-null.m4.
22233
22234 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22235
22236         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
22237         space, undoing this 2003-08-12 change:
22238         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
22239
22240 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22241
22242         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
22243         strtoul.c from libc, undoing this 2003-08-12 change:
22244         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
22245
22246 2003-08-16  Jim Meyering  <jim@meyering.net>
22247
22248         Merges from coreutils.
22249         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
22250         prefix.  Adjust cache variables similarly.  Create 500 rather than
22251         just 300 files, to exercise bug on Darwin6.5, too.
22252         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
22253         $missing_dir.
22254         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
22255         AM_SYS_POSIX_TERMIOS.
22256         Reported by mkc@mathdogs.com.
22257         Also change use of $am_cv_sys_posix_termios
22258         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
22259         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
22260         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
22261         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
22262         in /proc/mounts until it finds one with matching device number.  This
22263         is unnecessary when the FILE argument *is* a mount point.  No stat call
22264         is necessary in that case.  So, disable the statvfs-testing code on
22265         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
22266         as RedHat bug# 84846.
22267         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
22268         to 1MB, so as not to render systems with no stack size limit (e.g.,
22269         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
22270         Include <unistd.h>.  On some systems,
22271         it is required for the definition of _SC_PAGESIZE.
22272
22273 2003-08-16  Jim Meyering  <jim@meyering.net>
22274
22275         Merge from coreutils.
22276         * lib/xstrtoimax.c: #else #if -> #elif.
22277         * lib/xstrtoumax.c: Likewise.
22278
22279 2003-08-16  Jim Meyering  <jim@meyering.net>
22280
22281         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
22282         * m4/utimes.m4: Removed.
22283         * m4/utimes-null.m4: Renamed from utimes.m4.
22284
22285         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
22286         to 1MB, so as not to render systems with no stack size limit (e.g.,
22287         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
22288         Include <unistd.h>.  On some systems,
22289         it is required for the definition of _SC_PAGESIZE.
22290
22291 2003-08-16  Jim Meyering  <jim@meyering.net>
22292         and Paul Eggert  <eggert@cs.ucla.edu>
22293
22294         Merges from coreutils, etc.
22295
22296         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
22297         using the latest version from cvs.  This avoids problems with #line
22298         directives using a vendor (Sun) compiler.
22299         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
22300         Don't set GETGROUPS_LIB here; now it's
22301         done via getgroups.m4's wrapper function.
22302         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
22303         rather than just in sh-util/configure.in, so that the
22304         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
22305         same.
22306         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
22307         AC_FUNC_GETLOADAVG where to find getloadavg.c.
22308         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
22309         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
22310         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
22311         Remove code that is now done by the newly-required macros.
22312         Append $(EXEEXT) to DF_PROG.
22313         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
22314         Do not invoke or require the following here,
22315         since prereq.m4 or some gnulib .m4 now does this for us:
22316         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
22317         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
22318         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
22319         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
22320         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
22321         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
22322         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
22323         AC_FUNC_OBSTACK.
22324         Do not replace the following functions, as this is now the job
22325         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
22326         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
22327         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
22328         atexit getpass, strdup, getpagesize.
22329         Replace 'raise'.
22330         Do not check for the following functions, as this is now the job
22331         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
22332         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
22333         setregid.
22334         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
22335         Check for sys/sysctl.h.
22336         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
22337         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
22338         of checking for ssize_t ourselves.
22339
22340         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
22341         Require every macro that gnulib/modules/* suggests for us.
22342         (jm_PREREQ_ADDEXT): New macro.
22343         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
22344         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
22345
22346         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
22347         (gl_PHYSMEM): Use it.
22348         Also check for `table' function.
22349         Check for new headers and functions.
22350         Add check for sys/sysmp.h.
22351         With suggestions from Kaveh Ghazi.
22352         Ignore headers that are present but cannot be compiled.  This
22353         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
22354         C 5.4.
22355
22356 2003-08-15  Paul Eggert  <eggert@twinsun.com>
22357
22358         Document merge from coreutils.
22359         * modules/userspec: Depend on posixver.
22360         * modules/strftime: Depend on tzset.
22361
22362 2003-08-15  Paul Eggert  <eggert@twinsun.com>
22363
22364         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
22365         rather than tab, after '#' in shell-script copyright notices.
22366         Suggested by Bruno Haible.
22367
22368 2003-08-15  Paul Eggert  <eggert@twinsun.com>
22369
22370         * config/srclist-update: Use three spaces, rather than tab, after '#'
22371         in shell-script copyright notices.  Suggested by Bruno Haible.
22372         Remove unnecessary parenthesization in regular expression.
22373
22374 2003-08-15  Jim Meyering  <jim@meyering.net>
22375
22376         Merge from coreutils.
22377         * lib/xgethostname.c: Include <stdlib.h>.
22378         (xghostname): Don't exit for anything other than memory-related
22379         failure; just return NULL.
22380         * lib/userspec.c: Include "posixver.h".
22381         (parse_user_spec): Accept `.' as a separator only
22382         in pre-POSIX-200112 mode.
22383         * lib/strtoimax.c: Use #elif rather than #else #if.
22384         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
22385         Remove function, now that we can rely on a working tzset function.
22386         [!_LIBC]: Ensure that the required autoconf test has been run.
22387         [!defined _NL_CURRENT && HAVE_STRFTIME]:
22388         Use underlying_strftime for %r.
22389         * lib/sha.c: Merge in some clean-up and optimization changes from
22390         glibc.
22391         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
22392         Ensure that it is a multiple of 64.
22393         Rearrange loop exit tests so as to avoid performing an
22394         additional fread after encountering an error or EOF.
22395         * lib/realloc.c: Update copyright date.
22396
22397 2003-08-15  Jim Meyering  <jim@meyering.net>
22398         and Paul Eggert  <eggert@twinsun.com>
22399
22400         Merge from coreutils.
22401         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
22402         member but strut utmpx does not.  Needed for AIX 4.3.3.
22403         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
22404
22405 2003-08-15  Jim Meyering  <jim@meyering.net>
22406         and Paul Eggert  <eggert@cs.ucla.edu>
22407
22408         Merges from coreutils, etc.
22409         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
22410         Require gl_FUNC_TZSET_CLOBBER.
22411         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
22412         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
22413         members.
22414
22415 2003-08-14  Paul Eggert  <eggert@twinsun.com>
22416
22417         Help the merge from coreutils.
22418         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
22419         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
22420         * m4/tzset.m4: Use it too.
22421
22422 2003-08-14  Paul Eggert  <eggert@twinsun.com>
22423
22424         * modules/tzset: New file.
22425
22426 2003-08-14  Jim Meyering  <jim@meyering.net>
22427
22428         Merges from coreutils.
22429         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
22430         variable names, rather than @FNMATCH_H@.
22431         * modules/alloca: Likewise for $(ALLOCA_H).
22432
22433         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
22434         the three copies of the literal target, `fnmatch.h'.
22435         * modules/alloca (alloca.h): Likewise.
22436
22437 2003-08-14  Jim Meyering  <jim@meyering.net>
22438
22439         Merge from coreutils.
22440         * m4/tzset.m4: New file.
22441         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
22442         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
22443         otherwise, AIX 5.1 systems would end up using the latter.
22444         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
22445         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
22446         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
22447         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
22448
22449 2003-08-14  Jim Meyering  <jim@meyering.net>
22450
22451         Merge from coreutils.
22452         * lib/obstack.h: Whitespace changes.
22453         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
22454         and xcalloc return values.
22455         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
22456         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
22457         hang on OSF/1 5.1 for DIR on both local and remote file systems.
22458         Reported by (and fix confirmed by) Nelson H. F. Beebe.
22459         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
22460         error from mntctl.
22461         Use mntctl's return value to drive the entry-processing loop, since
22462         we can't rely on the value of the vmt_length member in the last
22463         entry.  On some systems doing so could result in exhausting
22464         virtual memory.  Based in part on a patch from Mike Jetzer.
22465
22466 2003-08-14  Jim Meyering  <jim@meyering.net>
22467         and Paul Eggert  <eggert@twinsun.com>
22468
22469         Merges from coreutils, plus other fixes.
22470         * lib/physmem.c: Merge in portability changes from gcc/libiberty
22471         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
22472         for credits and details.  Thanks to Kaveh Ghazi for helping
22473         to keep these files in sync.
22474         (ARRAY_SIZE): Define it.
22475         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
22476         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
22477         (memcasecmp): Don't assume size_t fits in unsigned int.
22478         Remove casts and duplicate code.
22479         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
22480         (memcpy): Remove definition.
22481         Merge in some clean-up and optimization changes from glibc.
22482         [BLOCKSIZE]: Move definition to top of file.
22483         Ensure that it is a multiple of 64.
22484         Rearrange loop exit tests so as to avoid performing an
22485         additional fread after encountering an error or EOF.
22486         * lib/md5.h (md5_uintptr): Define.
22487         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
22488         return to the initial working directory.  Preserve errno
22489         for caller.
22490         * lib/idcache.c: Include "xalloc.h".
22491         (xmalloc, xrealloc): Remove decls.
22492         (getuser): Remove casts no longer required in C89.
22493         * lib/human.c: Include stdio.h, for sprintf.
22494         * lib/group-member.c: Include "xalloc.h".
22495         (xmalloc, xrealloc): Remove decls.
22496         (get_group_info): Remove casts no longer required in C89.
22497         * lib/getusershell.c (readname): Remove casts no longer required in
22498         C89.
22499         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
22500         * lib/getline.c: Whitespace fix, from coreutils.
22501
22502 2003-08-13  Paul Eggert  <eggert@twinsun.com>
22503
22504         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
22505         Check for isascii.
22506
22507         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
22508         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
22509         Undo previous (whitespace-only) change.
22510
22511 2003-08-13  Paul Eggert  <eggert@twinsun.com>
22512
22513         * lib/exclude.c: Include <ctype.h>
22514         (IN_CTYPE_DOMAIN): New macro.
22515         (is_space): New fn.
22516         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
22517         and empty lines.
22518
22519         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
22520         Undo previous (whitespace-only) change.
22521
22522 2003-08-13  Paul Eggert  <eggert@twinsun.com>
22523
22524         * config/srclist-update: Change update back to the old behavior,
22525         leaving whitespace alone.  Use one 'sed' command rather than a
22526         pipeline.
22527         (fixlicense): Now a variable, not a function.
22528         (remove_trailing_blanks): Remove.
22529         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
22530         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
22531         Undo previous (whitespace-only) change.
22532
22533 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22534
22535         Merge from coreutils.
22536         * modules/euidaccess: Add lib_SOURCES, include for new
22537         file euidaccess.h
22538
22539 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22540
22541         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
22542         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
22543         Normalize leading white space and remove trailing white space.
22544
22545         Merge from coreutils
22546         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
22547
22548         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
22549         0.12.1.  These files are now being upgraded automatically by
22550         ../config/srclist-update.
22551
22552 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22553
22554         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
22555         Normalize leading white space and remove trailing white space.
22556         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
22557         notice, as per ../config/srclist-update.
22558
22559         Merge from coreutils.
22560         * lib/euidaccess.h: New file.
22561         * lib/euidaccess.c: Include it.
22562         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
22563         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
22564         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
22565
22566 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22567
22568         * config/srclist-update: Add copyright notice.
22569         (remove_id_lines, remove_trailing_blanks): New constants.
22570         (fixfile): Use them to normalize spacing a bit in copied files.
22571         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
22572         Normalize leading white space and remove trailing white space.
22573
22574         * config/texinfo.tex: Sync with texinfo.
22575
22576         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
22577         strtoul.c from libc, to merge coreutils whitespace changes.
22578
22579         * config/srclist.txt: Get the following m4 files from gettext:
22580         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
22581         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
22582         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
22583         wint_t.m4.
22584
22585 2003-08-12  Karl Berry  <karl@gnu.org>
22586
22587         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
22588         been made.
22589
22590 2003-08-11  Paul Eggert  <eggert@twinsun.com>
22591
22592         * modules/gnu-source, m4/gnu-source.m4:
22593         Remove; we're assuming Autoconf 2.54 or later now.
22594         Suggested by Bruno Haible.
22595         * MODULES.html.sh (func_all_modules): Remove gnu-source.
22596
22597 2003-08-11  Bruno Haible  <bruno@clisp.org>
22598
22599         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
22600
22601 2003-08-11  Bruno Haible  <bruno@clisp.org>
22602
22603         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
22604         (vasnprintf): Use it instead of wcslen.
22605
22606 2003-08-11  Bruno Haible  <bruno@clisp.org>
22607
22608         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
22609         value to ensure that _Bool promotes to int. Use #define for _Bool when
22610         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
22611
22612 2003-08-10  Karl Berry  <karl@gnu.org>
22613
22614         * lib/regex.h: update from libc (whitespace fix).
22615
22616 2003-08-09  Paul Eggert  <eggert@twinsun.com>
22617
22618         Merge some files from coreutils.  These changes were
22619         originally made by Jim Meyering.
22620         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
22621         many older Unixes require this.
22622         * lib/alloca.c (alloca): Remove cast to argument of free;
22623         no longer needed in C89.
22624         * lib/alloca_.h, regex.h: Fix white space to match
22625         what GNU indent does.
22626
22627 2003-08-09  Paul Eggert  <eggert@twinsun.com>
22628
22629         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
22630         apparently Emacs's Unicode mode got confused before my 2003-08-05
22631         checkin.
22632
22633 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22634
22635         * m4/extensions.m4: New file.
22636         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
22637         Require gl_USE_SYSTEM_EXTENSIONS.
22638         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
22639         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
22640
22641 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22642
22643         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
22644         * modules/extensions, modules/gnu-source: New files.
22645         * modules/timespec, modules/unlocked-io: Depend on extensions.
22646
22647 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22648
22649         * modules/restrict: New file.
22650         * MODULES.html.sh (func_all_modules): Add restrict.
22651         * modules/regex: Depend on restrict.
22652
22653 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22654
22655         * m4/restrict.m4: New file.
22656         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
22657
22658 2003-08-07  Bruno Haible  <bruno@clisp.org>
22659
22660         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
22661         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
22662
22663 2003-08-07  Bruno Haible  <bruno@clisp.org>
22664
22665         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
22666         makes the module 'getndelim2' compatible with the module 'getline'.
22667
22668 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22669
22670         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
22671         byte with "\201" to avoid glitches when editing that source file
22672         with multi-gnome-terminal.
22673
22674 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22675
22676         * lib/bumpalloc.h: Remove.
22677
22678 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22679
22680         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
22681         * modules/bumpalloc: Remove.
22682
22683 2003-08-04  Paul Eggert  <eggert@twinsun.com>
22684
22685         * lib/getloadavg.c: Change copyright notice and spacing to conform to
22686         GNU coding style.
22687
22688         Merge from coreutils.
22689         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
22690         1. From glibc.
22691         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
22692         from Karl Berry, implemented by Jim Meyering.
22693         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
22694         from Dmitry V. Levin.
22695         Remove anachronistic cast of xrealloc.
22696         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
22697         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
22698         type. Otherwise, it wouldn't compile with at least /bin/cc on
22699         ymp-cray-unicos9.0.2.X.
22700         Combine two mostly-identical uses of alloca into one.
22701         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
22702
22703 2003-08-04  Dave Love  <d.love@dl.ac.uk>
22704
22705         [From Emacs.]
22706
22707         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
22708         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
22709         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
22710         obsolete NLIST_NAME_UNION.
22711         [__GNU__]: Undef BSD and FSCALE.
22712         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
22713
22714 2003-08-03  Paul Eggert  <eggert@twinsun.com>
22715
22716         * lib/stdbool_.h (_Bool): Make it signed char, instead of
22717         an enum type, so that it's guaranteed to promote to int.  See:
22718         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
22719
22720 2003-08-03  Karl Berry  <karl@gnu.org>
22721
22722         * config/depcomp: update from automake.
22723
22724 2003-07-31  Paul Eggert  <eggert@twinsun.com>
22725
22726         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
22727         (strerror): Don't assume that a printable int fits in 14 bytes.
22728
22729 2003-07-31  Bruno Haible  <bruno@clisp.org>
22730
22731         * modules/getpass-gnu: New file.
22732         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
22733
22734 2003-07-31  Bruno Haible  <bruno@clisp.org>
22735
22736         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
22737
22738 2003-07-24  Karl Berry  <karl@gnu.org>
22739
22740         * config/missing: update from automake.
22741
22742 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
22743             Bruno Haible  <bruno@clisp.org>
22744
22745         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
22746         * lib/getline.c (getline, getdelim): Likewise.
22747         Remove _GNU_SOURCE define; now it's defined in config.h through
22748         m4/getline.m4.
22749
22750 2003-07-23  Karl Berry  <karl@gnu.org>
22751
22752         * config/config.sub: update from prep.
22753
22754 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22755
22756         * modules/xalloc (Depends-on): Add exitfail.
22757         * modules/xmemcoll: Likewise.
22758
22759 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22760
22761         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
22762         over-parenthesization in macros.
22763
22764         Sync with coreutils.
22765
22766         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
22767         required by C99.
22768
22769         Use `exit_failure' for xalloc and xmemcoll instead of their own
22770         private exit-failure variables.
22771         * lib/xalloc.h (xalloc_exit_failure): Remove.
22772         * lib/xmalloc.c: Likewise.  Include exitfail.h.
22773         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
22774         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
22775         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
22776         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
22777
22778 2003-07-20  Jim Meyering  <jim@meyering.net>
22779
22780         * modules/closeout (Depends-on): Add exitfail.
22781         Suggestion from Bruno Haible.
22782
22783 2003-07-19  Karl Berry  <karl@gnu.org>
22784
22785         * config/config.sub: update from prep.
22786
22787 2003-07-18  Paul Eggert  <eggert@twinsun.com>
22788
22789         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
22790         Remove.
22791         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
22792         to test that it can stand by itself.  Include "exitfail.h".
22793         Clients should set exit_failure instead.
22794         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
22795
22796 2003-07-18  Bruno Haible  <bruno@clisp.org>
22797
22798         * modules/getndelim2: New file.
22799         * modules/getline: Share files with module getndelim2.
22800         * modules/getnline: Depend on getndelim2 instead of sharing files with
22801         it. Add getnline.c to lib_SOURCES.
22802         * MODULES.html.sh (func_all_modules): Add getndelim2.
22803
22804 2003-07-18  Bruno Haible  <bruno@clisp.org>
22805
22806         * m4/getndelim2.m4: New file.
22807         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
22808         invoke gl_PREREQ_GETNDELIM2.
22809         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
22810         gl_PREREQ_GETNDELIM2.
22811         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
22812         gl_GETNDELIM2.
22813
22814 2003-07-18  Bruno Haible  <bruno@clisp.org>
22815
22816         * lib/getndelim2.h: New file.
22817         * lib/getndelim2.c: Make into a module of its own. Include config.h,
22818         getndelim2.h.
22819         (getndelim2): Make non-static. Change return type to ssize_t.
22820         * lib/getline.h: Change argument names.
22821         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
22822         * lib/getnline.c: Include getndelim2.h.
22823
22824 2003-07-18  Andreas Schwab  <schwab@suse.de>
22825
22826         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
22827
22828 2003-07-17  Karl Berry  <karl@gnu.org>
22829
22830         * config/config.sub: update from prep.
22831
22832 2003-07-17  Bruno Haible  <bruno@clisp.org>
22833
22834         * modules/getnline: New file.
22835         * modules/getline: Add lib/getndelim2.c to source file list.
22836         * MODULES.html.sh (func_all_modules): Add getnline.
22837
22838 2003-07-17  Bruno Haible  <bruno@clisp.org>
22839
22840         * m4/getnline.m4: New file.
22841
22842 2003-07-17  Bruno Haible  <bruno@clisp.org>
22843
22844         * m4/Makefile.am.in: Remove file.
22845         * m4/Makefile.am: Remove file.
22846         * m4/Makefile.in: Remove file.
22847
22848 2003-07-17  Bruno Haible  <bruno@clisp.org>
22849
22850         * lib/getnline.h: New file.
22851         * lib/getnline.c: New file.
22852         * lib/getndelim2.c: New file, extracted from getline.c.
22853         (getndelim2): Renamed from getdelim2, with added nmax argument.
22854         * lib/getline.c: Include getndelim2.c.
22855         (getdelim2): Moved out to getndelim2.c.
22856         (getline, getdelim): Update.
22857
22858 2003-07-17  Bruno Haible  <bruno@clisp.org>
22859
22860         * lib/Makefile.am: Remove file.
22861         * lib/Makefile.in: Remove file.
22862
22863 2003-07-17  Bruno Haible  <bruno@clisp.org>
22864
22865         * configure.in: Remove file.
22866         * Makefile.in: Remove file.
22867
22868 2003-07-17  Bruno Haible  <bruno@clisp.org>
22869
22870         * MODULES.html.sh: Put the </BODY> right before </HTML>.
22871
22872 2003-07-16  Karl Berry  <karl@gnu.org>
22873
22874         * config/srclist-update: was running fixlicense twice, which caused
22875                 texinfo.tex to be nullified for some reason.  Simplify,
22876                 $gplsrc is no longer needed as far as I can see?
22877
22878 2003-07-16  Jim Meyering  <jim@meyering.net>
22879
22880         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
22881
22882 2003-07-15  Paul Eggert  <eggert@twinsun.com>
22883
22884         * config/srclist.txt: Get the following files from gettext-runtime/intl
22885         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
22886         ref-del.sin.  From Bruno Haible.
22887         * config/srclist-update (fixfile): Change grep pattern again, since the
22888         previous fix didn't work (there was another trailing $).  Use
22889         '[$]' to escape the $s.
22890
22891 2003-07-15  Karl Berry  <karl@gnu.org>
22892
22893         * lib/vasnprintf.c: update from gettext.
22894
22895 2003-07-15  Karl Berry  <karl@gnu.org>
22896
22897         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
22898         gets expanded when surrounded by '$'.
22899
22900 2003-07-15  Jim Meyering  <jim@meyering.net>
22901
22902         * modules/save-cwd: Don't depend on error.  From Derek Price.
22903
22904 2003-07-15  Jim Meyering  <jim@meyering.net>
22905
22906         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
22907
22908 2003-07-14  Simon Josefsson  <jas@extundo.com>
22909
22910         * modules/mempcpy: New file.
22911         * MODULES.html.sh (func_all_modules): Add mempcpy.
22912
22913 2003-07-14  Simon Josefsson  <jas@extundo.com>
22914
22915         * m4/mempcpy.m4: New file.
22916
22917 2003-07-14  Simon Josefsson  <jas@extundo.com>
22918
22919         * lib/mempcpy.h: New file.
22920         * lib/mempcpy.c: New file.
22921
22922 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22923
22924         * modules/getdate, modules/posixtm: Depend on mktime.
22925
22926 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22927
22928         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
22929         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
22930         unicodeio.c, unicodeio.h, unlocked-io.h:
22931         Switch from LGPL to GPL.
22932
22933 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22934
22935         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
22936         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
22937         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
22938         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
22939         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
22940         updated automatically by ../config/srclist-update.  This changes
22941         their license from LPGL to GPL.
22942
22943 2003-07-14  Paul Eggert  <eggert@twinsun.com>
22944
22945         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
22946         assumed to refer to the root of the most recent stable gettext version.
22947         * config/srclistvars.sh: Add defaults for eggert.
22948         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
22949         Match "This program" as well as "The program".  This is needed
22950         for gettext.
22951
22952 2003-07-14  Jim Meyering  <jim@meyering.net>
22953
22954         Don't emit diagnostics.  Let callers do that.
22955         * lib/save-cwd.c: Don't include "error.h".
22956         (save_cwd): Don't call error.  Ensure that errno is valid
22957         when returning nonzero.
22958
22959         * lib/save-cwd.h (restore_cwd): Update prototype.
22960         * lib/save-cwd.c (restore_cwd): Remove two parameters.
22961         Simplify.  Don't call error upon failure.  Let callers do that.
22962         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
22963         when auditing is enabled.  But don't bother updating the #if.
22964
22965 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
22966
22967         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
22968         it breaks C++ compilation.
22969         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
22970
22971 2003-07-10  Simon Josefsson  <jas@extundo.com>
22972
22973         * modules/strchrnul (Makefile.am): Add strchrnul.h.
22974
22975 2003-07-10  Jim Meyering  <jim@meyering.net>
22976
22977         * m4/clock_time.m4: Remove trailing blank.
22978         * m4/intmax_t.m4: Likewise.
22979
22980 2003-07-10  Jim Meyering  <jim@meyering.net>
22981
22982         * lib/vasnprintf.c: Remove trailing blanks.
22983         Make cpp indentation consistent.
22984
22985 2003-07-09  Paul Eggert  <eggert@twinsun.com>
22986
22987         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
22988         posixver.c, strftime.c, strnlen.c, strverscmp.c:
22989         Switch from LGPL to GPL.
22990
22991 2003-07-09  Paul Eggert  <eggert@twinsun.com>
22992
22993         * config/srclist.txt: Sort sublists.  Add
22994         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
22995         that differ from gnulib for one reason or another; we'd like this list
22996         to be smaller but for now let's document what we have.
22997
22998 2003-07-08  Paul Eggert  <eggert@twinsun.com>
22999
23000         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
23001         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
23002         and sweeter "eval x=$x".
23003         * config/srclist.txt: Get lib/argp* from glibc.
23004
23005 2003-07-07  Paul Eggert  <eggert@twinsun.com>
23006
23007         * lib/mktime.c: Fix some boundary cases and remove need for floating
23008         point.
23009
23010         Issue a compile-time diagnostic if time_t is floating point, or if
23011         two's complement arithmetic is not in effect, or if arithmetic
23012         right shift does not propagate the sign.  These assumptions were
23013         all in the original code but they weren't checked.
23014
23015         (TIME_T_MIDPOINT, verify): New macros.
23016         (__isleap): Remove; it has integer overflow problems.
23017         (leapyear): New function, without those problems.
23018         (ydhms_tm_diff): Remove; splitting into two parts.
23019         (ydhms_diff): New function, containing the arithmetic part of
23020         the old ydhms_tm_diff function.  Issue a compile-time
23021         diagnostic if we are not using C99 integer division.
23022         Avoid casts when possible.
23023         (guess_time_tm): New function, containing the checking part of
23024         the old ydhms_tm_diff function.  Return the new value, rather than
23025         the difference between it and the old.  Accept a new argument T
23026         so that *T specifies the old value.  Check for overflow in the result.
23027
23028         (__mktime_internal): Use a time_t offset, not a long int offset.
23029         This undoes the 2003-06-04 change, which is no longer needed now
23030         that we have better overflow checking.
23031         (localtime_offset): Likewise.
23032
23033         (__mktime_internal): Avoid harmful overflow on hosts where time_t
23034         and long are 64-bit but int is only 32-bit.
23035         (ydhms_diff): Use long int to store year1 and yday1.
23036         Issue a compile-time diagnostic if long int is not wide enough.
23037
23038         (__mktime_internal): Use long int to store adjusted year and yday.
23039         Use plain C rather than preprocessor commands, if that doesn't
23040         affect efficiency.
23041         Check for overflow (and try to repair) after each probe
23042         rather than checking only at the very end.  This avoids some bugs
23043         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
23044         does not equal GMT offset at maximum time).
23045         Use integer to check for overflow rather than floating point; this
23046         is more portable to non-IEEE hosts, and is a tad faster.
23047         When we detect that we are oscillating between two values,
23048         don't check whether tm_isdst has the requested value, since
23049         we already know the answer.  When tm_isdst has the wrong value,
23050         use a different heuristic to find the right one, based on the
23051         extreme values actually observed in practice in tz2003a,
23052         rather than the (overly optimistic) "previous 3 calendar quarters".
23053
23054         (not_equal_tm, print_tm, check_result): Use "const T" rather than
23055         "T const" to accommodate glibc style.
23056         (check_result): Use less-confusing report format.  "long" -> "long int.
23057         (main): Likewise.
23058         Don't loop if the iteration overflows time_t.
23059         Allow a negative step in the iteration.
23060
23061 2003-07-06  Karl Berry  <karl@gnu.org>
23062
23063         * config/depcomp: update from automake.
23064         * config/config.sub: update from prep.
23065
23066 2003-07-03  Karl Berry  <karl@gnu.org>
23067
23068         * config/config.guess: update from prep.
23069
23070 2003-07-01  Paul Eggert  <eggert@twinsun.com>
23071
23072         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
23073         xreadlink.c now includes it unconditionally.
23074
23075 2003-07-01  Paul Eggert  <eggert@twinsun.com>
23076
23077         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
23078         having it depend on HAVE_SYS_TYPES_H.
23079
23080 2003-07-01  Bruno Haible  <bruno@clisp.org>
23081
23082         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
23083         <sys/types.h> should be sufficient.
23084         Reported by Paul Eggert.
23085
23086 2003-06-26  Karl Berry  <karl@gnu.org>
23087
23088         * config/depcomp: update from automake.
23089
23090 2003-06-26  Bruno Haible  <bruno@clisp.org>
23091
23092         * modules/human: Depend on module stdbool.
23093
23094 2003-06-25  Bruno Haible  <bruno@clisp.org>
23095
23096         * modules/readlink: New file.
23097         * modules/xreadlink: Depend on it.
23098         * MODULES.html.sh (func_all_modules): Add readlink.
23099
23100 2003-06-25  Bruno Haible  <bruno@clisp.org>
23101
23102         * m4/readlink.m4: New file.
23103
23104 2003-06-25  Bruno Haible  <bruno@clisp.org>
23105
23106         * lib/readlink.c: New file.
23107
23108 2003-06-22  Karl Berry  <karl@gnu.org>
23109
23110         * config/srclist.txt: update mkinstalldirs from automake.
23111         * config/mkinstalldirs: update.
23112
23113 2003-06-22  Bruno Haible  <bruno@clisp.org>
23114
23115         Portability to mingw32.
23116         * m4/ssize_t.m4: New file, from GNU gettext.
23117         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
23118         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
23119
23120 2003-06-22  Bruno Haible  <bruno@clisp.org>
23121
23122         * modules/safe-read: Add m4/ssize_t.m4.
23123         * modules/xreadlink: Add m4/ssize_t.m4.
23124
23125 2003-06-20  Bruno Haible  <bruno@clisp.org>
23126
23127         Assume C89, so PARAMS isn't needed.
23128         * lib/unicodeio.h (PARAMS): Remove.
23129         * lib/unicodeio.c: Don't use PARAMS.
23130
23131 2003-06-18  Karl Berry  <karl@gnu.org>
23132
23133         * config/config.{guess,sub}: update from prep.
23134
23135 2003-06-18  Jim Meyering  <jim@meyering.net>
23136
23137         Merge changes from coreutils.
23138         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
23139         Remove explicit declarations of xmalloc and realloc.
23140         Include xalloc.h.
23141         (read_utmp): Remove anachronistic cast of xmalloc.
23142
23143 2003-06-17  Paul Eggert  <eggert@twinsun.com>
23144
23145         Assume C89, so PARAMS isn't needed.
23146         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
23147         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
23148         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
23149         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
23150         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
23151         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
23152         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
23153         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
23154         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
23155         lib/xstrtod.h, lib/xstrtol.h: Likewise.
23156         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
23157         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
23158         no longer needed. Anyway, config.h should always be included before any
23159         other file.
23160
23161 2003-06-11  Simon Josefsson  <jas@extundo.com>
23162
23163         * modules/sysexits: New file.
23164         * MODULES.html.sh (func_all_modules): Add sysexits.
23165
23166 2003-06-11  Simon Josefsson  <jas@extundo.com>
23167
23168         * lib/sysexit_.h: New file.
23169
23170 2003-06-11  Derek Price  <derek@ximbiot.com>
23171
23172         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
23173         necessary.
23174
23175 2003-06-11  Bruno Haible  <bruno@clisp.org>
23176
23177         * m4/sysexits.m4: New file.
23178
23179 2003-06-10  Simon Josefsson  <jas@extundo.com>
23180
23181         * lib/argp.h: New file, from glibc.
23182         * lib/argp-ba.c: New file, from glibc.
23183         * lib/argp-eexst.c: New file, from glibc.
23184         * lib/argp-fmtstream.c: New file, from glibc.
23185         * lib/argp-fmtstream.h: New file, from glibc.
23186         * lib/argp-fs-xinl.c: New file, from glibc.
23187         * lib/argp-help.c: New file, from glibc.
23188         * lib/argp-namefrob.h: New file, from glibc.
23189         * lib/argp-parse.c: New file, from glibc.
23190         * lib/argp-pv.c: New file, from glibc.
23191         * lib/argp-pvh.c: New file, from glibc.
23192         * lib/argp-xinl.c: New file, from glibc.
23193
23194 2003-06-10  Simon Josefsson  <jas@extundo.com>
23195
23196         * modules/strchrnul: New file.
23197
23198 2003-06-10  Simon Josefsson  <jas@extundo.com>
23199
23200         * modules/argp: New file.
23201
23202 2003-06-10  Simon Josefsson  <jas@extundo.com>
23203
23204         * m4/strchrnul.m4: New file.
23205
23206 2003-06-10  Simon Josefsson  <jas@extundo.com>
23207
23208         * lib/strchrnul.h: New file.
23209         * lib/strchrnul.c: New file.
23210
23211 2003-06-10  Bruno Haible  <bruno@clisp.org>
23212
23213         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
23214
23215 2003-06-07  Karl Berry  <karl@gnu.org>
23216
23217         * config/config.{guess,sub}: update from prep.
23218
23219 2003-06-07  Jim Meyering  <jim@meyering.net>
23220
23221         * modules/strtod: Use $(...) notation, not @...@ for
23222         AC_REPLACE'd variables.
23223         * modules/localcharset: Likewise.
23224
23225 2003-06-07  Jim Meyering  <jim@meyering.net>
23226
23227         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
23228         in place of my name in the copyright comment.
23229         Remove definition and uses of __P.
23230
23231         From coreutils.
23232         * lib/stat.c: Don't declare xmalloc explicitly.
23233         Instead, include "xalloc.h".
23234         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
23235         xrealloc, and xcalloc return values.
23236         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
23237         Improve comment.
23238         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
23239
23240 2003-06-07  Bruno Haible  <bruno@clisp.org>
23241
23242         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
23243         avoid AC_CONFIG_LINKS.
23244         * modules/fnmatch (Makefile.am): Use explicit creation rule for
23245         fnmatch.h, to avoid AC_CONFIG_LINKS.
23246         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
23247
23248 2003-06-07  Bruno Haible  <bruno@clisp.org>
23249
23250         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
23251         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
23252         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
23253         directory.
23254         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
23255         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
23256         directory.
23257
23258 2003-06-06  Jim Meyering  <jim@meyering.net>
23259
23260         Merge from coreutils.
23261         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
23262         Consolidate declarations and initializations of *_base* locals.
23263
23264         Merge from coreutils.
23265         This avoids a core dump on systems without GNU putenv,
23266         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
23267         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
23268         (unsetenv): New static function, from GNU libc.
23269         (rpl_putenv): Use it.
23270
23271         * lib/modechange.c: Remove trailing blanks.
23272
23273         Merge from coreutils.
23274         * lib/fsusage.c: Remove declaration of statfs.
23275         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
23276
23277         * lib/posixtm.c: Include <stdbool.h> unconditionally.
23278
23279 2003-06-06  Jim Meyering  <jim@meyering.net>
23280
23281         * lib/stdbool_.h: Renamed from stdbool.h.in.
23282
23283 2003-06-06  Jim Meyering  <jim@meyering.net>
23284             Bruno Haible  <bruno@clisp.org>
23285
23286         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
23287         Adjust Makefile.am snippet not to redirect directly to target.
23288         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
23289
23290 2003-06-05  Paul Eggert  <eggert@twinsun.com>
23291
23292         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
23293         mismatch, look in future quarters as well as past.  This fixes a
23294         bug when processing fall-backwards gaps immediately after a long
23295         period of daylight-saving time.
23296
23297         * lib/mktime.c: Assume freestanding C89 or better.
23298         (HAVE_LIMITS_H): Remove.  Assume it's 1.
23299         (__P): Remove; not used.
23300         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
23301         (mktime, not_equal_tm, print_tm, check_result,
23302         main): Use prototypes.  Use const * where appropriate.
23303         (main): Fix typo in testing code that uncovered by above changes.
23304         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
23305
23306 2003-06-04  Paul Eggert  <eggert@twinsun.com>
23307
23308         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
23309         locale.h, localeconv.  This merges changes from coreutils.
23310
23311         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
23312         It can be removed after the next Autoconf is released.
23313         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
23314         needed.
23315
23316 2003-06-04  Paul Eggert  <eggert@twinsun.com>
23317
23318         * lib/mktime.c: Fix Debian bug 177940
23319         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
23320         (localtime_offset): Now long int, not time_t, because we want it
23321         to be guaranteed to be signed.  All uses changed.
23322         (__mktime_internal): If overflow would occur when adding offset,
23323         don't add it.
23324
23325         Merge 'human' changes from coreutils.  Rewrite to support
23326         locale-specific notations like thousands separators.
23327         * lib/human.c: Simplify authorship notice.
23328         Include human.h immediately after config.h.
23329         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
23330         <limits.h>: Do not include, since human.h does.
23331         (SIZE_MAX, UINTMAX_MAX): New macros.
23332         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
23333         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
23334         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
23335         (power_letter): Renamed from suffixes.
23336         (generate_suffix_backwards): Remove.
23337         (adjust_value): Now takes int style (because of human.h changes)
23338         and long double value (for greater precision on some platforms).
23339         (group_number): New function.
23340         (human_readable): Use it.  Use integer options, not enum.
23341         Put the options before the sizes in the arg list.
23342         Support all the new options.
23343         The old human_readable function has been removed;
23344         use inttostr.h instead.
23345         (human_readable, default_block_size, humblock):
23346         Use uintmax_t, not int, for block sizes.
23347         (human_readable_inexact, block_size_types): Remove.
23348         (block_size_opts): New constant.
23349         (human_options): Renamed from human_block_size, with new signature
23350         that allows block sizes up to UINTMAX_MAX.  All callers changed.
23351         * lib/human.h: Add copyright and authorship notice.
23352         Include <limits.h> and <stdbool.h> unconditionally.
23353         (PARAMS): Remove.  All uses removed.
23354         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
23355         (enum human_inexact_style): Remove tag; now a nameless enum.
23356         (human_floor, human_ceiling, human_round_to_even): Now have
23357         values 2, 0, 1 rather than -1, 1, 0.
23358         (human_group_digits, human_suppress_point_zero, human_autoscale,
23359         human_base_1024, human_SI, human_B): New constants.
23360         (human_readable_inexact, human_block_size): Remove.
23361         (human_readable): Size args are now uintmax_t, not int.
23362         (human_options): New decl.
23363
23364         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
23365         unnecessary now that we assume C89 or better.  This change
23366         imported from coreutils.
23367
23368         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
23369         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
23370         in the 2003-05-30 sync from glibc.
23371
23372         .h files should stand alone, but we shouldn't include <sys/types.h>
23373         if we can get away with just <stddef.h>.
23374
23375         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
23376         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
23377         rather than <sys/types.h>, as we merely need size_t.
23378         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
23379         to get size_t.
23380         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
23381         Include <stdio.h>, to get FILE.
23382         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
23383         memcasecmp.h has included <stddef.h> and all we need is size_t.
23384         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
23385         our interface, instead of including <sys/types.h>
23386
23387 2003-06-04  Paul Eggert  <eggert@twinsun.com>
23388
23389         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
23390         now, as glibc mktime is buggy on non-glibc systems.
23391
23392 2003-06-03  Karl Berry  <karl@gnu.org>
23393
23394         * config/config.sub: update from prep.
23395
23396 2003-06-02  Paul Eggert  <eggert@twinsun.com>
23397
23398         [from coreutils]
23399         Fix some minor time-related bugs with POSIX time arguments.
23400         Some valid time stamps were being rejected (notably -1, and
23401         time stamps before 1900 on 64-bit hosts).  And some invalid
23402         time stamps were being accepted, e.g. September 31.
23403
23404         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
23405         that we can return (time_t) -1 successfully.
23406         * lib/posixtm.c: Likewise.
23407         [HAVE_STDBOOL_H]: Include <stdbool.h>.
23408         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
23409         (t): Remove static var.
23410         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
23411         of static var.  All uses changed.
23412         (year): Do not reject years before 1900; they can occur with
23413         64-bit time_t.
23414         (posix_time_parse): Do not check for out-of-range components;
23415         that is now the caller's responsibility, since our checks were
23416         only approximations.
23417         (posixtime): Use mktime to check for out-of-range components,
23418         since it knows them exactly.
23419         If mktime returns (time_t) -1, check whether an error actually occurred
23420         by invoking localtime on -1.
23421         (main) [TEST_POSIXTIME]: Check for input data errors, and report
23422         posixtime failures better.
23423         Improve the test data (in comments only).
23424
23425 2003-06-02  Karl Berry  <karl@gnu.org>
23426
23427         * config/mkinstalldirs (version): new variable.
23428         (--version): new option.
23429         (usage): improve message.
23430
23431 2003-05-30  Karl Berry  <karl@gnu.org>
23432
23433         * lib/mktime.c: update from libc.
23434
23435 2003-05-30  Bruno Haible  <bruno@clisp.org>
23436
23437         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
23438         * config/config.rpath: Upgrade to gettext-0.12.1.
23439
23440 2003-05-30  Bruno Haible  <bruno@clisp.org>
23441
23442         * m4/gettext.m4: Upgrade to gettext-0.12.1.
23443         * m4/nls.m4: New file, from gettext-0.12.1.
23444         * m4/po.m4: New file, from gettext-0.12.1.
23445         * m4/progtest.m4: Upgrade to gettext-0.12.1.
23446
23447 2003-05-30  Bruno Haible  <bruno@clisp.org>
23448
23449         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
23450         * lib/localcharset.h: Likewise.
23451         * lib/localcharset.c: Likewise.
23452
23453 2003-05-29  Karl Berry  <karl@gnu.org>
23454
23455         * config/config.rpath: update from gettext.
23456
23457 2003-05-28  Paul Eggert  <eggert@twinsun.com>
23458
23459         Assume the headers required for C89 freestanding compilers.
23460         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
23461         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
23462         * m4/human.m4 (gl_HUMAN): Likewise.
23463         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
23464         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
23465         * m4/userspec.m4 (gl_USERSPEC): Likewise.
23466         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
23467         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
23468         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
23469
23470 2003-05-28  Paul Eggert  <eggert@twinsun.com>
23471
23472         Assume the headers required for C89 freestanding compilers.
23473         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
23474         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
23475         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
23476         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
23477         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
23478         define, since <limits.h> is guaranteed to do that.
23479         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
23480         * lib/exclude.c: Include <stdbool.h> unconditionally.
23481         * lib/tempname.c: Include <stddef.h> unconditionally.
23482         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
23483         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
23484         <stddef.h> does that.
23485         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
23486         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
23487         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
23488         needed.
23489         * lib/xstrtol.c: Likewise.
23490         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
23491         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
23492
23493         * lib/addext.c (addext): Use assignment rather than cast, to avoid
23494         warnings on some platforms.
23495
23496         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
23497         arbitrarily.
23498
23499 2003-05-26  Jim Meyering  <jim@meyering.net>
23500
23501         Merge in a change from coreutils:
23502         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
23503         that is guaranteed to be `no'.  Use `no_such_member' to indicate
23504         that condition, rather than `-1' which is slightly misleading.
23505         Change the name of the cache variable to have the gl_ prefix.
23506         Prompted by a patch from Richard Dawe for DJGPP.
23507
23508 2003-05-24  Karl Berry  <karl@gnu.org>
23509
23510         * config/config.guess: update from prep.
23511
23512 2003-05-22  Karl Berry  <karl@gnu.org>
23513
23514         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
23515
23516 2003-05-20  Karl Berry  <karl@gnu.org>
23517
23518         * config/config.guess: update from prep.
23519
23520 2003-05-18  Karl Berry  <karl@gnu.org>
23521
23522         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
23523         might actually be set by the user.
23524
23525         * config/depcomp, install-sh, mdate-sh: update from automake.
23526
23527 2003-05-17  Bruno Haible  <bruno@clisp.org>
23528
23529         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
23530         invalid expansion for AC_EGREP_CPP.
23531         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
23532         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
23533         Suggested by Akim Demaille <akim@epita.fr> in
23534         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
23535
23536 2003-05-12  Jim Meyering  <jim@meyering.net>
23537
23538         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
23539         the space-padded-by-default conversion specifiers, %e, %k, %l.
23540
23541 2003-05-12  Bruno Haible  <bruno@clisp.org>
23542
23543         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
23544         the string is longer than 4 KB.
23545
23546 2003-05-11  Karl Berry  <karl@gnu.org>
23547
23548         * config/config.{guess,sub}: update from prep.
23549
23550 2003-05-09  Bruno Haible  <bruno@clisp.org>
23551
23552         * modules/error: Add m4/strerror_r.m4 to file list.
23553
23554 2003-05-03  Bruno Haible  <bruno@clisp.org>
23555
23556         Upgrade to Unicode-4.0.
23557         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
23558         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
23559         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
23560         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
23561         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
23562         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
23563         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
23564         Change width of U+E0100..U+E01EF from 1 to 0.
23565
23566 2003-04-25  Jim Meyering  <jim@meyering.net>
23567
23568         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
23569         of type size_t, not int.
23570
23571 2003-04-25  Bruno Haible  <bruno@clisp.org>
23572
23573         * lib/copy-file.c: Include <stddef.h>, for size_t.
23574
23575 2003-04-21  Paul Eggert  <eggert@twinsun.com>
23576
23577         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
23578         code which expansion is under static control.  Patch imported from
23579         Akim Demaille's patch to Bison; see
23580         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
23581
23582 2003-04-14  Bruno Haible  <bruno@clisp.org>
23583
23584         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
23585
23586 2003-04-11  Jim Meyering  <jim@meyering.net>
23587
23588         Merge changes from Coreutils.
23589
23590         2003-03-22  Jim Meyering  <jim@meyering.net>
23591
23592         * lib/strftime.c (widen): Cast alloca return value to proper type.
23593
23594         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
23595
23596         From GNU libc.
23597         * lib/strftime.c (my_strftime): Handle very large width
23598         specifications for numeric values correctly.  Improve checks for
23599         overflow.
23600
23601         2003-01-19  Jim Meyering  <jim@meyering.net>
23602
23603         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
23604         definitions.
23605         (nl_get_alt_digit) [! defined my_strftime]: Define.
23606         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
23607         _nl_get_alt_digit and _nl_get_walt_digit.
23608
23609         * lib/strftime.c (my_strftime): Merge in locale-related changes from
23610         libc. These changes have no effect outside of _LIBC.
23611
23612 2003-04-10  Bruno Haible  <bruno@clisp.org>
23613
23614         * modules/findprog: New file.
23615         * MODULES.html.sh (func_all_modules): Add it.
23616
23617 2003-04-10  Bruno Haible  <bruno@clisp.org>
23618
23619         * m4/findprog.m4: New file.
23620         * m4/eaccess.m4: New file.
23621
23622 2003-04-10  Bruno Haible  <bruno@clisp.org>
23623
23624         * lib/findprog.h: New file, from GNU gettext.
23625         * lib/findprog.c: New file, from GNU gettext.
23626
23627 2003-04-05  Jim Meyering  <jim@meyering.net>
23628
23629         Merge changes from Coreutils.
23630
23631         * lib/exclude.h (PARAMS): Remove definition and uses.
23632         * lib/exclude.c: Remove uses of `PARAMS'.
23633
23634         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
23635         Add test-cases for DOS filenames. Declare program_name.
23636         (main): Set up program_name.  Patch by Rich Dawe.
23637
23638         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
23639         error from mntctl.
23640         Use mntctl's return value to drive the entry-processing loop, since
23641         we can't rely on the value of the vmt_length member in the last
23642         entry.  On some systems doing so could result in exhausting
23643         virtual memory.  Based in part on a patch from Mike Jetzer.
23644
23645 2003-04-04  Bruno Haible  <bruno@clisp.org>
23646
23647         * modules/linebreak: New file.
23648         * MODULES.html.sh (func_all_modules): Add it.
23649
23650 2003-04-04  Bruno Haible  <bruno@clisp.org>
23651
23652         * m4/linebreak.m4: New file.
23653
23654 2003-04-04  Bruno Haible  <bruno@clisp.org>
23655
23656         * lib/linebreak.h: New file, from GNU gettext.
23657         * lib/linebreak.c: New file, from GNU gettext with slight
23658         modifications.
23659         * lib/lbrkprop.h: New file, from GNU gettext.
23660
23661 2003-04-03  Bruno Haible  <bruno@clisp.org>
23662
23663         * modules/utf8-ucs4: New file.
23664         * modules/utf16-ucs4: New file.
23665         * modules/ucs4-utf8: New file.
23666         * modules/ucs4-utf16: New file.
23667         * MODULES.html.sh (func_all_modules): Add them.
23668
23669 2003-04-03  Bruno Haible  <bruno@clisp.org>
23670
23671         * m4/utf-ucs4.m4: New file.
23672         * m4/ucs4-utf.m4: New file.
23673
23674 2003-04-03  Bruno Haible  <bruno@clisp.org>
23675
23676         * lib/utf8-ucs4.h: New file, from GNU gettext.
23677         * lib/utf16-ucs4.h: New file, from GNU gettext.
23678         * lib/ucs4-utf8.h: New file, from GNU gettext.
23679         * lib/ucs4-utf16.h: New file, from GNU gettext.
23680
23681 2003-04-02  Bruno Haible  <bruno@clisp.org>
23682
23683         * modules/binary-io: New file.
23684         * MODULES.html.sh (func_all_modules): Add it.
23685
23686 2003-04-02  Bruno Haible  <bruno@clisp.org>
23687
23688         * lib/binary-io.h: New file, from GNU gettext.
23689
23690 2003-04-01  Bruno Haible  <bruno@clisp.org>
23691
23692         * modules/pathname: New file.
23693         * MODULES.html.sh (func_all_modules): Add it.
23694
23695 2003-04-01  Bruno Haible  <bruno@clisp.org>
23696
23697         * lib/pathname.h: New file, from GNU gettext.
23698         * lib/concatpath.c: New file, from GNU gettext.
23699
23700 2003-03-30  Bruno Haible  <bruno@clisp.org>
23701
23702         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
23703
23704 2003-03-30  Bruno Haible  <bruno@clisp.org>
23705
23706         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
23707         function chown() doesn't exist.
23708
23709 2003-03-28  Bruno Haible  <bruno@clisp.org>
23710
23711         * modules/copy-file: New file.
23712         * MODULES.html.sh (func_all_modules): Add it.
23713
23714 2003-03-28  Bruno Haible  <bruno@clisp.org>
23715
23716         * m4/copy-file.m4: New file.
23717
23718 2003-03-28  Bruno Haible  <bruno@clisp.org>
23719
23720         * lib/copy-file.h: New file, from GNU gettext.
23721         * lib/copy-file.c: New file, from GNU gettext.
23722
23723 2003-03-18  Jim Meyering  <jim@meyering.net>
23724
23725         * lib/quote.c (quote_n): Fix typo in comment.
23726
23727 2003-03-18  Bruno Haible  <bruno@clisp.org>
23728
23729         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
23730         checking.
23731         * m4/onceonly_2_57.m4: Likewise.
23732
23733 2003-03-17  Bruno Haible  <bruno@clisp.org>
23734
23735         * m4/onceonly.m4: Require autoconf 2.54 or newer.
23736         (m4_quote): Remove macro.
23737         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
23738
23739 2003-03-14  Jim Meyering  <jim@meyering.net>
23740
23741         Merge changes from Coreutils.
23742         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
23743         to be const, in order to avoid warnings.
23744         (obstack_room): Likewise.
23745         (obstack_empty_p): Likewise.
23746
23747 2003-03-14  Bruno Haible  <bruno@clisp.org>
23748
23749         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
23750         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
23751
23752 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23753
23754         Merge changes from Bison.
23755         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
23756         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
23757         when compiling Bison 1.875's `bitset bset = obstack_alloc
23758         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
23759         * lib/hash.c: Include <stdbool.h> unconditionally.
23760
23761 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23762
23763         * m4/onceonly.m4 (m4_quote): New macro.
23764         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
23765         Quote AC_FOREACH variable-expansions properly.
23766
23767 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23768
23769         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
23770
23771 2003-03-09  Paul Eggert  <eggert@twinsun.com>
23772
23773         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
23774         Reported by Bruce Becker; see:
23775         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
23776
23777 2003-03-03  Paul Eggert  <eggert@twinsun.com>
23778             Bruno Haible  <bruno@clisp.org>
23779
23780         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
23781         Reported by John Hughes, see
23782         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
23783
23784 2003-02-20  Bruno Haible  <bruno@clisp.org>
23785
23786         * MODULES.html.sh (func_all_modules): Add poll.
23787
23788 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23789
23790         * modules/poll: New file.
23791
23792 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23793
23794         * lib/poll_.h: New file.
23795         * lib/poll.c: New file.
23796
23797 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23798
23799         * m4/poll.m4: New file.
23800
23801 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23802
23803         * modules/mathl: New file.
23804
23805 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23806
23807         * lib/mathl.h: New file.
23808         * lib/acosl.c: New file.
23809         * lib/asinl.c: New file.
23810         * lib/atanl.c: New file.
23811         * lib/ceill.c: New file.
23812         * lib/cosl.c: New file.
23813         * lib/expl.c: New file.
23814         * lib/floorl.c: New file.
23815         * lib/frexpl.c: New file.
23816         * lib/ldexpl.c: New file.
23817         * lib/logl.c: New file.
23818         * lib/sincosl.c: New file.
23819         * lib/sinl.c: New file.
23820         * lib/sqrtl.c: New file.
23821         * lib/tanl.c: New file.
23822         * lib/trigl.c: New file.
23823         * lib/trigl.h: New file.
23824
23825 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23826
23827         * m4/mathl.m4: New file.
23828
23829 2003-02-18  Bruno Haible  <bruno@clisp.org>
23830
23831         * MODULES.html.sh (func_all_modules): Add mathl.
23832
23833 2003-02-17  Bruno Haible  <bruno@clisp.org>
23834
23835         * modules/mkdtemp: New module.
23836         * MODULES.html.sh (func_all_modules): Add it.
23837
23838 2003-02-17  Bruno Haible  <bruno@clisp.org>
23839
23840         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
23841
23842 2003-02-17  Bruno Haible  <bruno@clisp.org>
23843
23844         * lib/mkdtemp.h: New file, from GNU gettext.
23845         * lib/mkdtemp.c: New file, from GNU gettext.
23846
23847 2003-02-02  Jim Meyering  <jim@meyering.net>
23848
23849         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
23850         e.g. glibc-2.2.93.
23851
23852 2003-01-31  Bruno Haible  <bruno@clisp.org>
23853
23854         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
23855         'rpl_rename'.
23856         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
23857         'rpl_strnlen'.
23858         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
23859         'rpl_strtod'.
23860         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
23861         'rpl_utime'.
23862
23863 2003-01-31  Bruno Haible  <bruno@clisp.org>
23864
23865         * lib/rename.c: #undef rename before defining rpl_rename.
23866         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
23867
23868 2003-01-30  Bruno Haible  <bruno@clisp.org>
23869
23870         * modules/vasnprintf, modules/vasprintf: New modules.
23871         * MODULES.html.sh (func_all_modules): Add them.
23872
23873 2003-01-30  Bruno Haible  <bruno@clisp.org>
23874
23875         * m4/signed.m4: New file, from GNU gettext.
23876         * m4/longdouble.m4: New file, from GNU gettext.
23877         * m4/wchar_t.m4: New file, from GNU gettext.
23878         * m4/wint_t.m4: New file, from GNU gettext.
23879         * m4/vasnprintf.m4: New file.
23880         * m4/vasprintf.m4: New file.
23881
23882 2003-01-30  Bruno Haible  <bruno@clisp.org>
23883
23884         * lib/printf-args.h: New file, from GNU gettext.
23885         * lib/printf-args.c: New file, from GNU gettext.
23886         * lib/printf-parse.h: New file, from GNU gettext.
23887         * lib/printf-parse.c: New file, from GNU gettext.
23888         * lib/vasnprintf.h: New file, from GNU gettext.
23889         * lib/vasnprintf.c: New file, from GNU gettext.
23890         * lib/asnprintf.c: New file, from GNU gettext.
23891         * lib/vasprintf.h: New file, from GNU gettext with modifications.
23892         * lib/vasprintf.c: New file, from GNU gettext.
23893         * lib/asprintf.c: New file, from GNU gettext.
23894
23895 2003-01-29  Bruno Haible  <bruno@clisp.org>
23896
23897         * modules/stpncpy: New module.
23898         * MODULES.html.sh (func_all_modules): Add it.
23899
23900 2003-01-29  Bruno Haible  <bruno@clisp.org>
23901
23902         * m4/stpncpy.m4: New file.
23903
23904 2003-01-29  Bruno Haible  <bruno@clisp.org>
23905
23906         * lib/stpncpy.h: New file, from GNU gettext with modifications.
23907         * lib/stpncpy.c: New file, from GNU gettext with modifications.
23908
23909 2003-01-28  Bruno Haible  <bruno@clisp.org>
23910
23911         * modules/c-ctype: New module.
23912         * MODULES.html.sh (func_all_modules): Add it.
23913
23914 2003-01-28  Bruno Haible  <bruno@clisp.org>
23915
23916         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
23917         Paul Eggert.
23918         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
23919         Paul Eggert.
23920
23921 2003-01-27  Bruno Haible  <bruno@clisp.org>
23922
23923         * modules/xsetenv: New module.
23924         * MODULES.html.sh (func_all_modules): Add it.
23925
23926 2003-01-27  Bruno Haible  <bruno@clisp.org>
23927
23928         * lib/xsetenv.h: New file, from GNU gettext.
23929         * lib/xsetenv.c: New file, from GNU gettext.
23930
23931 2003-01-23  Jim Meyering  <jim@meyering.net>
23932
23933         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
23934         from working on systems without dirfd (at least Irix and OSF1/Tru64).
23935
23936 2003-01-23  Bruno Haible  <bruno@clisp.org>
23937
23938         * modules/minmax: New module.
23939         * MODULES.html.sh (func_all_modules): Add it.
23940
23941 2003-01-23  Bruno Haible  <bruno@clisp.org>
23942
23943         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
23944         Eggert.
23945
23946 2003-01-22  Bruno Haible  <bruno@clisp.org>
23947
23948         * modules/exit: New module.
23949         * MODULES.html.sh (func_all_modules): Add it.
23950
23951 2003-01-22  Bruno Haible  <bruno@clisp.org>
23952
23953         * lib/exit.h: New file, from GNU gettext.
23954
23955 2003-01-19  Bruno Haible  <bruno@clisp.org>
23956
23957         * gnulib-tool: Recognize option --extract-maintainer.
23958         (func_get_maintainer): New function.
23959         * modules/*: Add Maintainer entry.
23960
23961 2003-01-16  Jim Meyering  <jim@meyering.net>
23962
23963         * m4/regex.m4: The `regex' struct is both input and output.
23964         Initialize it before each use.  Patch by Tim Waugh.
23965
23966 2003-01-16  Bruno Haible  <bruno@clisp.org>
23967
23968         * MODULES.html.sh: Add a table of contents. Add the module name as
23969         leftmost column. Add hyperlinks.
23970
23971 2003-01-15  Bruno Haible  <bruno@clisp.org>
23972
23973         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
23974
23975 2003-01-15  Bruno Haible  <bruno@clisp.org>
23976
23977         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
23978         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
23979         suffix.
23980
23981 2003-01-15  Bruno Haible  <bruno@clisp.org>
23982
23983         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
23984
23985 2003-01-15  Bruno Haible  <bruno@clisp.org>
23986
23987         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
23988         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
23989
23990 2003-01-14  Jim Meyering  <jim@meyering.net>
23991
23992         * lib/same.c (same_name): Tweak a comment.
23993
23994 2003-01-14  Bruno Haible  <bruno@clisp.org>
23995
23996         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
23997         when a string comparison is sufficient.
23998
23999 2003-01-14  Bruno Haible  <bruno@clisp.org>
24000
24001         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
24002         'unsigned int'.
24003
24004 2003-01-14  Bruno Haible  <bruno@clisp.org>
24005
24006         * lib/hash-pjw.c: Add comment about low quality of this function.
24007
24008 2003-01-13  Bruno Haible  <bruno@clisp.org>
24009
24010         * modules/stpcpy: Distribute lib/stpcpy.h.
24011         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
24012
24013 2003-01-13  Bruno Haible  <bruno@clisp.org>
24014
24015         * modules/*: Add a description.
24016         * modules/strpbrk: Fix Makefile.am snippet.
24017         * modules/strtoimax: Fix dependencies.
24018         * modules/strtoumax: Likewise.
24019
24020 2003-01-13  Bruno Haible  <bruno@clisp.org>
24021
24022         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
24023         * modules/alloca (Makefile.am): All object files depend on alloca.h.
24024         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
24025
24026 2003-01-13  Bruno Haible  <bruno@clisp.org>
24027
24028         * gnulib-tool (func_create_testdir): Store config/* files in the main
24029         directory.
24030         * config.rpath: Move to ...
24031         * config/config.rpath: ... here.
24032         * modules/gettext: Contains config/config.rpath, not config.rpath.
24033         * modules/iconv: Likewise.
24034
24035 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24036
24037         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24038         to avoid collisions with libcurses and libreadline.
24039
24040         * m4/getstr.m4: Remove.
24041         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
24042
24043 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24044
24045         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24046         to avoid collisions with libcurses and libreadline.
24047
24048         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
24049         * lib/getstr.h, getstr.c: Remove.
24050         * lib/getline.c: Include "getline.h", to check interface.
24051         Move body of old getstr.c here: this defines MIN_CHUNK and
24052         declares getdelim2, which is renamed from getstr.
24053         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
24054
24055         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
24056         All uses changed.
24057         * lib/linebuffer.h: Likewise.
24058         (readline): Remove backward-compatibility macro.
24059
24060 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24061
24062         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24063         to avoid collisions with libcurses and libreadline.
24064         * getstr: Remove.
24065         * MODULES.html.sh: Remove getstr.
24066         * modules/getline: Depend on unlocked-io, not getstr.
24067
24068 2003-01-12  Jim Meyering  <jim@meyering.net>
24069
24070         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
24071
24072 2003-01-10  Bruno Haible  <bruno@clisp.org>
24073
24074         * modules/alloca: Change Makefile.am requirements. Simplify Include
24075         requirements. Add lib/alloca_.h to file list.
24076
24077 2003-01-10  Bruno Haible  <bruno@clisp.org>
24078
24079         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
24080
24081 2003-01-10  Bruno Haible  <bruno@clisp.org>
24082
24083         * lib/alloca_.h: New file.
24084         * lib/getdate.y: Unconditionally include alloca.h.
24085         * lib/makepath.c: Likewise.
24086         * lib/setenv.c: Likewise.
24087         * lib/userspec.c: Likewise.
24088
24089 2003-01-09  Karl Berry  <karl@gnu.org>
24090
24091         * MODULES.html.sh: include `dirname $0` in PATH, to find
24092         gnulib-tool.
24093
24094 2003-01-09  Bruno Haible  <bruno@clisp.org>
24095
24096         * modules/stdbool: Change configure.ac, Makefile.am requirements.
24097         Simplify Include requirements. Add lib/stdbool.h.in to file list.
24098
24099 2003-01-09  Bruno Haible  <bruno@clisp.org>
24100
24101         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
24102
24103 2003-01-09  Bruno Haible  <bruno@clisp.org>
24104
24105         * lib/stdbool.h.in: New file.
24106
24107 2003-01-09  Bruno Haible  <bruno@clisp.org>
24108
24109         * gnulib-tool (func_all_modules): Ignore files ending in ~.
24110         * MODULES.html.sh: Likewise.
24111
24112 2003-01-08  Jim Meyering  <jim@meyering.net>
24113
24114         * lib/full-write.c: Undefine and define-away `const' after inclusion
24115         of errno.h, not before.  Suggestion from Bruno Haible.
24116
24117 2003-01-08  Bruno Haible  <bruno@clisp.org>
24118
24119         * modules/full-read: Depend on full-write.
24120
24121 2003-01-08  Bruno Haible  <bruno@clisp.org>
24122
24123         * lib/safe-read.c: Include specification header first, to ensure its
24124         selfcontainedness.
24125         * lib/full-write.c: Likewise.
24126
24127 2003-01-07  Jim Meyering  <jim@meyering.net>
24128
24129         * lib/full-write.c: Rework so that it may serve to define full_read,
24130         too.
24131         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
24132
24133 2003-01-07  Bruno Haible  <bruno@clisp.org>
24134
24135         * lib/strtoimax.c: Include <stdint.h> as an alternative to
24136         <inttypes.h>.
24137         * lib/xstrtol.h: Likewise.
24138         * lib/xstrtoimax.c: Likewise.
24139         * lib/xstrtoumax.c: Likewise.
24140         * lib/human.h: Likewise.
24141
24142         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
24143         on systems that have <inttypes.h> but not <stdint.h>.
24144
24145 2003-01-07  Bruno Haible  <bruno@clisp.org>
24146
24147         * MODULES.html.sh: Add copyright notice.
24148         (missed_files): Omit CVS directory entries.
24149         (func_module): Make it work with sed-3.02.
24150         * MODULES.txt: Remove file.
24151
24152 2003-01-06  Jim Meyering  <jim@meyering.net>
24153
24154         * lib/version-etc.c: Update year in translatable copyright string.
24155
24156 2003-01-03  Karl Berry  <karl@gnu.org>
24157
24158         * config/config.{guess,sub}: update from prep.
24159
24160 2003-01-02  Karl Berry  <karl@gnu.org>
24161
24162         * doc/COPYING.DOC: belatedly updated to 1.2.
24163
24164 2003-01-01  Karl Berry  <karl@gnu.org>
24165
24166         * gnulib-tool (func_verify_module): report module name $module in
24167         error message, not $1.
24168         * gnulib-tool (create-testdir): don't complain if destdir couldn't
24169         be created, only if it doesn't exist.
24170         * gnulib-tool (last_checkin_date): don't expand the $Date here.
24171
24172 2002-12-31  Paul Eggert  <eggert@twinsun.com>
24173
24174         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
24175
24176 2002-12-31  Paul Eggert  <eggert@twinsun.com>
24177
24178         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
24179         memcmp if strcoll doesn't work.
24180
24181 2002-12-31  Bruno Haible  <bruno@clisp.org>
24182
24183         * lib/utime.c (utime_null): No need to call ftruncate if the file was
24184         nonempty.
24185
24186 2002-12-31  Bruno Haible  <bruno@clisp.org>
24187
24188         * lib/memcoll.c (STRCOLL): New macro.
24189         (memcoll): Use it.
24190
24191 2002-12-31  Bruno Haible  <bruno@clisp.org>
24192
24193         * lib/localcharset.h: New file.
24194         * lib/localcharset.c: Include it.
24195         * lib/unicodeio.c: Likewise.
24196
24197 2002-12-31  Bruno Haible  <bruno@clisp.org>
24198
24199         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
24200         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
24201
24202 2002-12-31  Bruno Haible  <bruno@clisp.org>
24203
24204         * lib/getline.h: Include <stddef.h>, for size_t.
24205
24206         * lib/unicodeio.h: Include <stddef.h>, for size_t.
24207         * lib/unicodeio.c: Don't include <stddef.h>.
24208
24209 2002-12-31  Bruno Haible  <bruno@clisp.org>
24210
24211         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
24212         HAVE_TM_ZONE.
24213
24214 2002-12-24  Karl Berry  <karl@gnu.org>
24215
24216         * config/config.guess: update from prep.
24217
24218 2002-12-24  Bruno Haible  <bruno@clisp.org>
24219
24220         General infrasructure.
24221         * m4/README: Rewritten.
24222         * m4/onceonly.m4: New file.
24223         * m4/onceonly_2_57.m4: New file.
24224
24225         Module atexit.
24226         * m4/atexit.m4: New file.
24227
24228         Module strtod.
24229         * m4/strtod.m4: New file.
24230
24231         Module strtol.
24232         * m4/strtol.m4: New file.
24233
24234         Module strtoul.
24235         * m4/strtoul.m4: New file.
24236
24237         Module memchr.
24238         * m4/memchr.m4: New file.
24239
24240         Module memcmp.
24241         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
24242         (jm_FUNC_MEMCMP): Invoke it.
24243
24244         Module memcpy.
24245         * m4/memcpy.m4: New file.
24246
24247         Module memmove.
24248         * m4/memmove.m4: New file.
24249
24250         Module memset.
24251         * m4/memset.m4: New file.
24252
24253         Module strcspn.
24254         * m4/strcspn.m4: New file.
24255
24256         Module strpbrk.
24257         * m4/strpbrk.m4: New file.
24258
24259         Module strstr.
24260         * m4/strstr.m4: New file.
24261
24262         Module strerror.
24263         * m4/strerror.m4: New file.
24264
24265         Module mktime.
24266         * m4/mktime.m4: Renamed from jm-mktime.m4.
24267         (gl_PREREQ_MKTIME): New macro.
24268         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
24269
24270         Module malloc.
24271         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
24272         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
24273         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
24274
24275         Module realloc.
24276         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
24277         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
24278         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
24279
24280         Module strftime.
24281         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
24282         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
24283         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
24284         gl_TM_GMTOFF.
24285         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
24286
24287         Module xalloc.
24288         * m4/xalloc.m4: New file.
24289
24290         Module alloca.
24291         * m4/alloca.m4: New file.
24292
24293         Module putenv.
24294         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
24295         (jm_FUNC_PUTENV): Invoke it.
24296
24297         Module setenv.
24298         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
24299         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
24300         when invoked twice.
24301         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
24302         gt_FUNC_SETENV.
24303
24304         Module memrchr.
24305         * m4/memrchr.m4: New file.
24306
24307         Module stpcpy.
24308         * m4/stpcpy.m4: New file.
24309
24310         Module strcase.
24311         * m4/strcase.m4: New file.
24312
24313         Module strdup.
24314         * m4/strdup.m4: New file.
24315
24316         Module strnlen.
24317         * m4/strnlen.m4: New file.
24318
24319         Module strndup.
24320         * m4/strndup.m4: New file.
24321
24322         Module xstrtod.
24323         * m4/xstrtod.m4: New file.
24324
24325         Module xstrtol.
24326         * m4/xstrtol.m4: New file.
24327
24328         Module getdate.
24329         * m4/getdate.m4: New file.
24330
24331         Module unlocked-io.
24332         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
24333         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
24334         * m4/jm-glibc-io.m4n: Remove file.
24335
24336         Module long-options.
24337         * m4/long-options.m4: New file.
24338
24339         Module md5.
24340         * m4/md5.m4: New file.
24341
24342         Module sha.
24343         * m4/sha.m4: New file.
24344
24345         Module getstr.
24346         * m4/getstr.m4: New file.
24347
24348         Module getline.
24349         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
24350         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
24351         <sys/types.h>, for size_t. Use the function name gnu_getline, not
24352         simply getline. Infoke gl_PREREQ_GETLINE.
24353
24354         Module obstack.
24355         * m4/obstack.m4: New file.
24356
24357         Module hash.
24358         * m4/hash.m4: New file.
24359
24360         Module readtokens.
24361         * m4/readtokens.m4: New file.
24362
24363         Module strverscmp.
24364         * m4/strverscmp.m4: New file.
24365
24366         Module stdbool.
24367         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
24368         OSF/1.
24369
24370         Module strtoll.
24371         * m4/strtoll.m4: New file.
24372
24373         Module strtoull.
24374         * m4/strtoull.m4: New file.
24375
24376         Module strtoimax.
24377         * m4/strtoimax.m4: New file.
24378
24379         Module strtoumax.
24380         * m4/strtoumax.m4: New file.
24381
24382         Module xstrtoimax.
24383         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
24384         jm_AC_PREREQ_XSTRTOIMAX.
24385         Moved the strtol prerequisites to strtol.m4.
24386         Moved the strtoll prerequisites to strtoll.m4.
24387         Moved the strtoimax prerequisites to strtoimax.m4.
24388
24389         Module xstrtoumax.
24390         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
24391         jm_AC_PREREQ_XSTRTOUMAX.
24392         Moved the strtoul prerequisites to strtoul.m4.
24393         Moved the strtoull prerequisites to strtoull.m4.
24394         Moved the strtoumax prerequisites to strtoumax.m4.
24395
24396         Module chown.
24397         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
24398         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
24399
24400         Module dup2.
24401         * m4/dup2.m4: New file.
24402
24403         Module ftruncate.
24404         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
24405         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
24406
24407         Module getgroups.
24408         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
24409         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
24410
24411         Module gettimeofday.
24412         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
24413         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
24414         gl_PREREQ_GETTIMEOFDAY.
24415
24416         Module mkdir.
24417         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
24418         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
24419
24420         Module mkstemp.
24421         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
24422         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
24423         jm_AC_TYPE_UINTMAX_T.
24424         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
24425
24426         Module stat.
24427         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
24428         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
24429
24430         Module lstat.
24431         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
24432         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
24433
24434         Module timespec.
24435         * m4/timespec.m4 (gl_TIMESPEC): New macro.
24436         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
24437         * m4/st_mtim.m4: Indentation.
24438
24439         Module nanosleep.
24440         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
24441         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
24442         gl_PREREQ_NANOSLEEP.
24443
24444         Module regex.
24445         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
24446         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
24447         (gl_REGEX): New macro.
24448
24449         Module rename.
24450         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
24451         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
24452
24453         Module rmdir.
24454         * m4/rmdir.m4: New file.
24455
24456         Module utime.
24457         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
24458         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
24459         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
24460
24461         Module dirname.
24462         * m4/dirname.m4: New file.
24463
24464         Module getopt.
24465         * m4/getopt.m4: New file.
24466
24467         Module unistd-safer.
24468         * m4/unistd-safer.m4: New file.
24469
24470         Module fnmatch.
24471         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
24472         declaration.
24473         (gl_PREREQ_FNMATCH_EXTRA): New macro.
24474         (gl_FUNC_FNMATCH_POSIX): New macro.
24475         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
24476         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
24477         simply fnmatch.
24478
24479         Module exclude.
24480         * m4/exclude.m4: New file.
24481
24482         Module human.
24483         * m4/human.m4: New file.
24484
24485         Module acl.
24486         * m4/acl.m4: Nop.
24487
24488         Module backupfile.
24489         * m4/backupfile.m4: New file.
24490         * m4/d-ino.m4: Indentation.
24491
24492         Module fsusage.
24493         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
24494         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
24495         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
24496
24497         Module dirfd.
24498         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
24499         requirements.
24500
24501         Module euidaccess.
24502         * m4/euidaccess.m4: New file.
24503
24504         Module file-type.
24505         * m4/file-type.m4: New file.
24506
24507         Module fileblocks.
24508         * m4/fileblocks.m4: New file.
24509
24510         Module filemode.
24511         * m4/filemode.m4: New file.
24512
24513         Module isdir.
24514         * m4/isdir.m4: New file.
24515
24516         Module lchown.
24517         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
24518         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
24519
24520         Module makepath.
24521         * m4/makepath.m4: New file.
24522
24523         Module modechange.
24524         * m4/modechange.m4: New file.
24525
24526         Module mountlist.
24527         * m4/mountlist.m4: New file.
24528         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
24529         Indentation.
24530
24531         Module path-concat.
24532         * m4/path-concat.m4: New file.
24533
24534         Module pathmax.
24535         * m4/pathmax.m4: New file.
24536
24537         Module same.
24538         * m4/same.m4: New file.
24539
24540         Module save-cwd.
24541         * m4/save-cwd.m4: New file.
24542
24543         Module savedir.
24544         * m4/savedir.m4: New file.
24545
24546         Module xgetcwd.
24547         * m4/xgetcwd.m4: New file.
24548         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
24549
24550         Module xreadlink.
24551         * m4/xreadlink.m4: New file.
24552
24553         Module safe-read.
24554         * m4/safe-read.m4: New file.
24555
24556         Module safe-write.
24557         * m4/safe-write.m4: New file.
24558
24559         Module closeout.
24560         * m4/closeout.m4: New file.
24561
24562         Module stdio-safer.
24563         * m4/stdio-safer.m4: New file.
24564
24565         Module getpass.
24566         * m4/getpass.m4: New file.
24567
24568         Module getugroups.
24569         * m4/getugroups.m4: New file.
24570
24571         Module group-member.
24572         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
24573         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
24574
24575         Module idcache.
24576         * m4/idcache.m4: New file.
24577
24578         Module userspec.
24579         * m4/userspec.m4: New file.
24580
24581         Module gettime.
24582         * m4/clock_time.m4: New file.
24583         * m4/gettime.m4: New file.
24584
24585         Module settime.
24586         * m4/settime.m4: New file.
24587
24588         Module posixtm.
24589         * m4/posixtm.m4: New file.
24590
24591         Module gethostname.
24592         * m4/gethostname.m4: New file.
24593
24594         Module canon-host.
24595         * m4/canon-host.m4: New file.
24596
24597         Module gettext.
24598         * m4/codeset.m4: New file, from gettext-0.11.5.
24599         * m4/gettext.m4: New file, from gettext-0.11.5.
24600         * m4/glibc21.m4: New file, from gettext-0.11.5.
24601         * m4/iconv.m4: New file, from gettext-0.11.5.
24602         * m4/intdiv0.m4: New file, from gettext-0.11.5.
24603         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
24604         * m4/inttypes.m4: New file, from gettext-0.11.5.
24605         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
24606         * m4/isc-posix.m4: New file, from gettext-0.11.5.
24607         * m4/lcmessage.m4: New file, from gettext-0.11.5.
24608         * m4/lib-ld.m4: New file, from gettext-0.11.5.
24609         * m4/lib-link.m4: New file, from gettext-0.11.5.
24610         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
24611         * m4/progtest.m4: New file, from gettext-0.11.5.
24612         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
24613         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
24614         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
24615
24616         Module localcharset.
24617         * m4/localcharset.m4: New file.
24618
24619         Module hard-locale.
24620         * m4/hard-locale.m4: New file.
24621
24622         Module mbswidth.
24623         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
24624         onceonly macros.
24625         * m4/mbrtowc.m4: Add comment.
24626
24627         Module memcasecmp.
24628         * m4/memcasecmp.m4: New file.
24629
24630         Module memcoll.
24631         * m4/memcoll.m4: New file.
24632
24633         Module unicodeio.
24634         * m4/unicodeio.m4: New file.
24635
24636         Module rpmatch.
24637         * m4/rpmatch.m4: New file.
24638
24639         Module yesno.
24640         * m4/yesno.m4: New file.
24641
24642         Module exitfail.
24643         * m4/exitfail.m4: New file.
24644
24645         Module c-stack.
24646         * m4/c-stack.m4 (gl_C_STACK): New macro.
24647         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
24648
24649         Module error.
24650         * m4/error.m4 (gl_ERROR): New macro.
24651         (jm_PREREQ_ERROR): Use onceonly macros.
24652
24653         Module fatal.
24654         * m4/fatal.m4: New file.
24655
24656         Module getloadavg.
24657         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
24658         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
24659
24660         Module getpagesize.
24661         * m4/getpagesize.m4: New file.
24662
24663         Module getusershell.
24664         * m4/getusershell.m4: New file.
24665
24666         Module physmem.
24667         * m4/physmem.m4: New file.
24668
24669         Module posixver.
24670         * m4/posixver.m4: New file.
24671
24672         Module quotearg.
24673         * m4/quotearg.m4: New file.
24674
24675         Module quote.
24676         * m4/quote.m4: New file.
24677
24678         Module readutmp.
24679         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
24680
24681         Module sig2str.
24682         * m4/sig2str.m4: New file.
24683
24684         Other.
24685         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
24686         ulonglong.m4.
24687         * m4/intmax_t.m4: New file.
24688         * m4/d-type.m4: Indentation.
24689         * m4/jm-macros.m4: Update.
24690         * m4/prereq.m4 (jm_PREREQ): Update.
24691         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
24692         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
24693         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
24694         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
24695         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
24696         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
24697         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
24698         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
24699         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
24700         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
24701         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
24702         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
24703         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
24704         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
24705         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
24706         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
24707         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
24708         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
24709         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
24710
24711 2002-12-24  Bruno Haible  <bruno@clisp.org>
24712
24713         * MODULES.txt: Update according to m4/ changes.
24714
24715         Module gettext.
24716         * config.rpath: New file, from gettext-0.11.5.
24717
24718         * modules/*: New module descriptions.
24719         * gnulib-tool: New file.
24720         * MODULES.html.sh: New file.
24721
24722 2002-12-21  Karl Berry  <karl@gnu.org>
24723
24724         * doc/fdl.texi: update to version 1.2.
24725
24726 2002-12-19  Karl Berry  <karl@gnu.org>
24727
24728         * config/config.guess: update from prep.
24729
24730 2002-12-18  Bruno Haible  <bruno@clisp.org>
24731
24732         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
24733         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
24734
24735 2002-12-17  Bruno Haible  <bruno@clisp.org>
24736
24737         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
24738         stdlib.h, string.h.
24739
24740 2002-12-17  Bruno Haible  <bruno@clisp.org>
24741
24742         * lib/canon-host.c (strdup): Remove unused declaration.
24743
24744         * lib/fsusage.c: Include full_read.h.
24745         (get_fs_usage): Use full_read instead of safe_read.
24746
24747         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
24748
24749 2002-12-12  Karl Berry  <karl@gnu.org>
24750
24751         * config/config.guess: update from prep.
24752
24753 2002-12-11  Bruno Haible  <bruno@clisp.org>
24754
24755         * m4/setenv.m4: New file, from gettext-0.11.5.
24756
24757 2002-12-11  Bruno Haible  <bruno@clisp.org>
24758
24759         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
24760         not unsetenv().
24761         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
24762         modifications:
24763
24764         2002-12-11  Bruno Haible  <bruno@clisp.org>
24765
24766                 * setenv.c (alloca): Fall back to malloc.
24767                 (freea): New macro.
24768                 (setenv): Use freea() to free memory allocated with alloca().
24769
24770         2002-11-13  Bruno Haible  <bruno@clisp.org>
24771
24772                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
24773                 function declarations.
24774                 * unsetenv.c (unsetenv): Likewise.
24775
24776         2002-03-04  Bruno Haible  <bruno@clisp.org>
24777
24778                 Portability to AIX 4.3.3.
24779                 * unsetenv.c: New file, extracted from setenv.c.
24780                 * setenv.c: Move the unsetenv() function to unsetenv.c.
24781
24782         2001-12-20  Bruno Haible  <bruno@clisp.org>
24783
24784                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
24785                 use malloc instead. For SunOS 4.
24786
24787         2001-12-11  Bruno Haible  <bruno@clisp.org>
24788
24789                 * setenv.c: Declare alloca.
24790                 (compar_fn_t): New typedef.
24791                 (KNOWN_VALUE, STORE_VALUE): Use it.
24792
24793         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
24794         setenv.h.
24795
24796 2002-12-10  Paul Eggert  <eggert@twinsun.com>
24797
24798         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
24799         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
24800         Choose values that are less likely to collide with system fnmatch
24801         options.
24802         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
24803         defined (e.g., a pure POSIX system).
24804         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
24805         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
24806
24807 2002-12-06  Paul Eggert  <eggert@twinsun.com>
24808
24809         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
24810         a pain in practice to deal with generated m4 files.  This change
24811         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
24812
24813         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
24814         and jm-glibc-io.m4, as they are no longer a special case.
24815         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
24816         kludge and the auto-generation stuff.  Check only whether the
24817         functions are declared, not whether they exist, since older hosts
24818         that don't declare the functions can't use the optimization anyway.
24819
24820 2002-12-06  Jim Meyering  <jim@meyering.net>
24821
24822         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
24823
24824         Merge in changes from libc's misc/error.c, in preparation
24825         for the merge of gnulib's changes back into libc.
24826
24827         * lib/error.c (_): Define only if not already defined.
24828         Move definition to follow all #include directives.
24829         Include unlocked-io.h only if !_LIBC.
24830         [_LIBC]: Include <libio/libioP.h>.
24831         [USE_IN_LIBIO]: Include <libio/iolibio.h>
24832         (fflush): Tweak definition to use INTUSE.
24833         (putc): Define.
24834
24835 2002-12-05  Paul Eggert  <eggert@twinsun.com>
24836
24837         * lib/alloca.c [defined emacs]: Include "lisp.h".
24838         (xalloc_die) [defined emacs]: New macro.
24839         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
24840         [! defined emacs]: Include <xalloc.h>.
24841         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
24842         (pointer): Typedef to POINTER_TYPE *.
24843         (malloc): Remove decl; we now always use xmalloc.
24844         (alloca): Use old-style definition, since Emacs needs this.
24845         Check for arithmetic overflow when computing combined size.
24846
24847 2002-12-04  Paul Eggert  <eggert@twinsun.com>
24848
24849         Do not generate unlocked-io.h automatically, since it's easier to
24850         maintain it by hand.
24851
24852         * lib/unlocked-io.h: New file, from GNU diffutils,
24853         but with proper copyright notice and attribution.
24854         * lib/gen-uio: Remove.
24855         * lib/Makefile.am: Add copyright notice.
24856         (libfetish_a_SOURCES): Add unlocked-io.h.
24857         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
24858         (DISTCLEANFILES, io_functions): Remove macros.
24859         (EXTRA_DIST): Remove gen_uio.
24860         (unlocked-io.h): Remove rule.
24861
24862 2002-12-04  Jim Meyering  <jim@meyering.net>
24863
24864         Reflect the fact that stat.c and lstat.c are no longer generated.
24865         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
24866         (DISTCLEANFILES): Likewise.
24867         (EXTRA_DIST): Likewise.
24868         (all_local): Don't depend on stat.c or lstat.c.
24869         (stat.c, lstat.c): Remove rules.
24870         (EXTRA_DIST): Remove xstat.in.
24871
24872         * lib/xstat.in: Remove file.  Contents moved into stat.c.
24873         * lib/stat.c: New file.  Contents mostly from xstat.in.
24874         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
24875         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
24876
24877         * lib/safe-read.c: Rework so that it may serve to define safe_write,
24878         too.
24879         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
24880
24881 2002-12-03  Jim Meyering  <jim@meyering.net>
24882
24883         * lib/safe-read.c, safe-write.c: Change variable names and comments,
24884         but not semantics, to minimize the differences between these two files.
24885         (safe_read): Change comment to mention SAFE_READ_ERROR.
24886
24887         * lib/safe-read.c (IS_EINTR): Define.
24888         (safe_read): Use IS_EINTR in place of in-function cpp directives.
24889
24890 2002-12-02  Jim Meyering  <jim@meyering.net>
24891
24892         * lib/safe-read.c (EINTR): Define.
24893         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
24894         (INT_MAX): Provide fallback.
24895         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
24896
24897         * lib/safe-read.h (SAFE_READ_ERROR): Define.
24898
24899 2002-12-02  Bruno Haible  <bruno@clisp.org>
24900
24901         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
24902         Define, taken from safe-read.c.
24903         (INT_MAX): Provide fallback.
24904         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
24905         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
24906
24907         * lib/safe-read.c (EINTR): Remove definition.
24908         (safe_read): Don't use EINTR if it is absent.
24909
24910 2002-12-01  Jim Meyering  <jim@meyering.net>
24911
24912         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
24913         zero.
24914         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
24915
24916 2002-11-27  Paul Eggert  <eggert@twinsun.com>
24917
24918         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
24919         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
24920         with `if (! (value < limit)) abort ();', for readability.
24921
24922 2002-11-26  Karl Berry  <karl@gnu.org>
24923
24924         * lib/strdup.c: copy from libc again, with jim's ok.
24925         * lib/.cppi-disable: re-add strdup.c
24926
24927 2002-11-25  Karl Berry  <karl@gnu.org>
24928
24929         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
24930         instead of "strtol.c".
24931
24932 2002-11-25  Karl Berry  <karl@gnu.org>
24933
24934         * config/install-sh: update from automake for variable quoting, $0 in
24935         error msgs, etc.
24936
24937         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
24938         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
24939         entry.
24940
24941 2002-11-25  Jim Meyering  <jim@meyering.net>
24942
24943         * lib/mktime.c: Sync from libc, now that it has the latest fix.
24944
24945 2002-11-24  Karl Berry  <karl@gnu.org>
24946
24947         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
24948         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
24949
24950 2002-11-24  Jim Meyering  <jim@meyering.net>
24951
24952         Update from coreutils:
24953
24954         * lib/mktime.c: Merge in changes from libc.
24955
24956         Avoid a link-time failure on some Linux systems.
24957         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
24958         (otherwise).
24959         (__mon_yday): Declare with the STATIC attribute.
24960         (__mktime_internal): Likewise.
24961         Based on a report from Greg Schafer.
24962
24963 2002-11-23  Jim Meyering  <jim@meyering.net>
24964
24965         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
24966         Use `unsigned', not `int', as type of index.
24967
24968         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
24969
24970         * lib/fsusage.c: Remove unneeded parentheses around operands of
24971         `defined'.
24972
24973 2002-11-22  Paul Eggert  <eggert@twinsun.com>
24974
24975         * lib/quotearg.h: Allow multiple inclusion by surrounding with
24976         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
24977         so that we can be included first.
24978         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
24979         * lib/quotearg.c: Include quotearg.h immediately after config.h.
24980         No need to include stddef.h or sys/types.h any more.
24981         Surround local include files with "", not "<>".
24982         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
24983         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
24984         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
24985         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
24986         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
24987         (ISPRINT): Remove; no longer needed now that we assume C89.
24988
24989         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
24990         Preserve errno.
24991
24992         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
24993         quotearg_char): Use SIZE_MAX rather than
24994         (size_t) -1 when we are talking about "infinity".
24995
24996         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
24997
24998 2002-11-22  Paul Eggert  <eggert@twinsun.com>
24999
25000         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
25001         hint that one should use `if (! x) abort ();' rather than `assert
25002         (x);', and anyway it's one less thing to worry about configuring.
25003         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
25004         hash_rehash, hash_insert): Use abort rather than assert.
25005
25006 2002-11-22  Bruno Haible  <bruno@clisp.org>
25007
25008         * lib/safe-read.h: Assume C89. Add comments.
25009         (safe_read): Change return type to size_t.
25010         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
25011         byte counts > SSIZE_MAX correctly.
25012         * lib/safe-write.h: New file.
25013         * lib/safe-write.c: New file.
25014         * lib/full-read.h: New file.
25015         * lib/full-read.c: New file.
25016         * lib/full-write.h: Assume C89. Add comments.
25017         * lib/full-write.c: Include safe-write.h.
25018         (full_write): Rewritten to use safe_write.
25019         Suggested by Jim Meyering and Paul Eggert.
25020
25021 2002-11-21  Jim Meyering  <jim@meyering.net>
25022
25023         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
25024
25025         Merge in changes from the coreutils.
25026
25027         2002-09-25  Paul Eggert  <eggert@twinsun.com>
25028         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
25029         <stdint.h>.
25030         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
25031         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
25032         int.  Work more efficiently if X is the same width as uintmax_t.
25033         Do not compare X to -1, to avoid bogus compiler warning.
25034         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
25035         Don't assume that f_frsize and f_bsize are the same type.
25036
25037         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
25038         warning on FreeBSD.
25039
25040         * lib/makepath.c (make_path): Restore umask *before* creating the final
25041         component.
25042         (make_path): Minor reformatting.
25043
25044         * lib/xmalloc.c: Adjust to work with new autoconf macros,
25045         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
25046         HAVE_MALLOC/HAVE_REALLOC.
25047
25048         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
25049         dummy ones.  At least on GNU/Linux systems, `auto' means something
25050         else.
25051         From Michael Stone.
25052
25053 2002-11-21  Bruno Haible  <bruno@clisp.org>
25054
25055         Remove case insensitive option matching.
25056         * lib/argmatch.h (argcasematch): Remove declaration.
25057         (ARGCASEMATCH): Remove macro.
25058         (__xargmatch_internal): Remove case_sensitive argument.
25059         (XARGMATCH): Update.
25060         (XARGCASEMATCH): Remove macro.
25061         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
25062         case_sensitive argument.
25063         (argcasematch): Remove function.
25064         (__xargmatch_internal): Remove case_sensitive argument.
25065         (main): Use XARGMATCH instead of XARGCASEMATCH.
25066
25067         * lib/xmalloc.c: Change compile-time error message. Add comment about
25068         required autoconf version.
25069
25070 2002-11-20  Paul Eggert  <eggert@twinsun.com>
25071
25072         Merge argmatch cleanups from Bison.  Assume C89.
25073
25074         * lib/argmatch.c: Include config.h here, not in argmatch.h.
25075         Include stdlib.h, for EXIT_FAILURE.
25076         Always include <string.h>, since we assume C89.
25077         (EXIT_FAILURE): Remove pre-C89 bug workaround.
25078         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
25079         Include <stddef.h> instead, since it's all we need for size_t.
25080         (PARAMS): Remove.  All uses removed.
25081         (ARRAY_CARDINALITY): Do not bother to #undef.
25082         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
25083         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
25084         Remove unnecessary parentheses.
25085         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
25086         Insert necessary parentheses.
25087         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
25088         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
25089
25090 2002-11-19  Bruno Haible  <bruno@clisp.org>
25091
25092         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
25093         * lib/mbswidth.h: Include <stddef.h>, for size_t.
25094
25095         * lib/mbswidth.h (PARAMS): Remove macro.
25096         (mbswidth, mbsnwidth): Use ANSI C function declarations.
25097         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
25098
25099         * lib/gcd.h (PARAMS): Remove macro.
25100         (gcd): Use ANSI C function declarations.
25101         * lib/gcd.c (gcd): Likewise.
25102
25103 2002-11-15  Bruno Haible  <bruno@clisp.org>
25104
25105         * lib/strcspn.c: Include <stddef.h>.
25106         (strcspn): Use ANSI C function declaration. Change return type to
25107         size_t. Use NULL.
25108         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
25109         (strpbrk): Use NULL.
25110         * lib/strpbrk.h (PARAMS): Remove macro.
25111         (strpbrk): Use ANSI C function declaration.
25112         * lib/strstr.c: Don't include <sys/types.h>.
25113         * lib/strstr.h (PARAMS): Remove macro.
25114         (strstr): Use ANSI C function declarations.
25115
25116 2002-11-14  Karl Berry  <karl@gnu.org>
25117
25118         * config/mkinstalldirs: `do' on separate line, instead of
25119         `for var; do'.
25120
25121 2002-11-06  Bruno Haible  <bruno@clisp.org>
25122
25123         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
25124         * lib/gcd.c (gcd): Likewise.
25125
25126 2002-11-05  Bruno Haible  <bruno@clisp.org>
25127
25128         * lib/gcd.h: New file, from gettext-0.11.5.
25129         * lib/gcd.c: New file, from gettext-0.11.5.
25130
25131 2002-11-05  Bruno Haible  <bruno@clisp.org>
25132
25133         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25134         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25135         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25136         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25137
25138         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
25139         <libintl.h>.
25140         * lib/makepath.c: Include gettext.h instead of <locale.h> and
25141         <libintl.h>.
25142
25143         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
25144         * lib/human.c: Include gettext.h instead of <libintl.h>.
25145         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
25146         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
25147         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
25148         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
25149         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
25150         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
25151         (textdomain): Remove definition.
25152         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
25153
25154         * lib/long-options.c: Remove include of <libintl.h> and definition of
25155         _.
25156         * lib/same.c: Remove include of <libintl.h> and definition of _.
25157
25158 2002-11-04  Owen Taylor  <otaylor@redhat.com>
25159
25160         * lib/config.charset: A few additions for Solaris.
25161
25162 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
25163
25164         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
25165         * lib/localcharset.c (locale_charset): Declare as extern "C".
25166
25167 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
25168
25169         * lib/config.charset: msdos in uk_UA uses CP1125.
25170
25171 2002-11-04  Bruno Haible  <bruno@clisp.org>
25172
25173         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
25174         * lib/strcase.h: New file, from GNU gettext-0.11.5.
25175         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
25176         * lib/strstr.h: New file, from GNU gettext-0.11.5.
25177         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
25178
25179 2002-11-04  Bruno Haible  <bruno@clisp.org>
25180
25181         * lib/localcharset.c (locale_charset): Don't return an empty string.
25182
25183 2002-11-04  Bruno Haible  <bruno@clisp.org>
25184
25185         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
25186         aliases.
25187
25188 2002-11-04  Bruno Haible  <bruno@clisp.org>
25189
25190         * lib/config.charset: Update for newest glibc. Add canonical names
25191         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
25192
25193 2002-11-04  Bruno Haible  <bruno@clisp.org>
25194
25195         * lib/config.charset: Add support for NetBSD.
25196
25197 2002-11-04  Bruno Haible  <bruno@clisp.org>
25198
25199         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
25200
25201 2002-11-01  Bruno Haible  <bruno@clisp.org>
25202
25203         * configure.in: Add AC_CONFIG_AUX_DIR call.
25204         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
25205         test/Makefile.
25206         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
25207
25208 2002-09-28  Karl Berry  <karl@gnu.org>
25209
25210         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
25211         installed automake until the next release, since changes have been
25212         made.
25213
25214 2002-09-25  Karl Berry  <karl@gnu.org>
25215
25216         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
25217         * lib/getopt*: copy from libc/posix.
25218         * lib/gettext.h: copy from gettext.
25219         * lib/.cppi-disable: add strdup.c, gettext.h.
25220
25221 2002-09-25  Karl Berry  <karl@gnu.org>
25222
25223         * config/srclist.txt: enable gettext.h check.
25224         * config/config.{guess,sub}: update from prep.
25225         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
25226                 from automake 1.6.3.
25227         See srclist*.
25228
25229 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
25230
25231         * regex.c (PATFETCH): Remove the translating fetch.
25232         (PATFETCH_RAW): Rename to PATFETCH.
25233         (set_image_of_range): New fun.
25234         (SET_RANGE_TABLE_WORK_AREA): Use it.
25235         (regex_compile): Don't translate the pattern chars so eagerly.
25236         Only do it when inserting an `exactn' bytecode or when handling
25237         a char-range.
25238         (mutually_exclusive_p): Avoid empty statement.
25239
25240 2002-07-06  Jim Meyering  <meyering@lucent.com>
25241
25242         * m4/README: Don't mention Makefile.am.in.
25243         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
25244
25245 2002-07-01  Jim Meyering  <meyering@lucent.com>
25246
25247         * lib/c-stack.c: Include sys/time.h.
25248         From Volker Borchert.
25249
25250 2002-06-26  Paul Eggert  <eggert@twinsun.com>
25251
25252         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
25253
25254 2002-06-26  Paul Eggert  <eggert@twinsun.com>
25255
25256         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
25257         New macro.  Use it uniformly instead of
25258         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
25259         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
25260         reported by Vin Shelton.
25261
25262 2002-06-22  Paul Eggert  <eggert@twinsun.com>
25263
25264         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
25265         Do not assume SA_SIGINFO behavior.
25266         Bug reported by Jim Meyering on NetBSD 1.5.2.
25267
25268 2002-06-22  Jim Meyering  <meyering@lucent.com>
25269
25270         * m4/c-stack.m4: New file, from diffutils-2.8.2.
25271         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
25272
25273         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
25274         now that configure.ac uses AC_GNU_SOURCE.
25275         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
25276         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
25277
25278         Update to latest tools.  Suggestions from Paul Eggert.
25279         * m4/stdbool.m4: New file, from diffutils-2.8.2.
25280         * m4/gnu-source.m4: Update from diffutils-2.8.2.
25281         * m4/fnmatch.m4: Likewise.
25282         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
25283         to AC_HEADER_STDBOOL
25284
25285 2002-06-22  Jim Meyering  <meyering@lucent.com>
25286
25287         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
25288         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
25289
25290 2002-06-22  Jim Meyering  <meyering@lucent.com>
25291
25292         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
25293
25294         * lib/exitfail.c, exitfail.h: Likewise.
25295         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
25296
25297         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
25298         of fnmatch.h.
25299         (EXTRA_DIST): Add fnmatch_loop.c.
25300         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
25301
25302         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
25303         * lib/fnmatch.c: Update from diffutils-2.8.2.
25304         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
25305         * lib/fnmatch.h: Remove file.
25306
25307 2002-06-21  Jim Meyering  <meyering@lucent.com>
25308
25309         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
25310         * m4/mbrtowc.m4: Likewise.
25311
25312         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
25313         * m4/mbswidth.m4: Reflect name change:
25314         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
25315         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
25316
25317         * m4/lib-link.m4: Update from gettext-0.11.2.
25318         * m4/gettext.m4: Likewise.
25319
25320         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
25321         From Alfred M. Szmidt.
25322
25323 2002-06-18  Paul Eggert  <eggert@twinsun.com>
25324
25325         * lib/file-type.h: Report an error if neither S_ISREG nor
25326         S_IFREG is defined, instead of using a test specific to glibc
25327         2.2.  This should be safe, since POSIX requires S_ISREG and
25328         Unix Version 7 had S_IFREG.  We don't need to check for
25329         <sys/types.h> since we don't use any symbols that it defines.
25330
25331 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
25332
25333         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
25334         $@-t, so that each temporary file name is unique and valid in the first
25335         8 characters, for operation under DOS.
25336
25337 2002-06-15  Paul Eggert  <eggert@twinsun.com>
25338
25339         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
25340
25341 2002-06-15  Jim Meyering  <meyering@lucent.com>
25342
25343         Work even with DJGPP 2.03, which lacks support for symlinks.
25344         From Richard Dawe.
25345         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
25346         is defined.
25347         * lib/lchown.c (S_ISLNK): Likewise.
25348
25349 2002-06-15  Jim Meyering  <meyering@lucent.com>
25350
25351         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
25352         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
25353         have been included before this file.
25354
25355 2002-06-14  Jim Meyering  <meyering@lucent.com>
25356
25357         * lib/file-type.h: Use the version from diffutils-2.8.2.
25358         * lib/file-type.c: Likewise.
25359
25360 2002-06-07  Jim Meyering  <meyering@lucent.com>
25361
25362         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
25363         They're needed at least for NetBSD 1.5.2.
25364         ($statxfs_includes): Include those same headers.
25365         ($statxfs_includes): Include sys/vfs.h if available.
25366         ($statxfs_includes): Likewise for sys/statvfs.h.
25367         Check for the following members in both structs statfs and statvfs:
25368         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
25369
25370 2002-06-01  Jim Meyering  <meyering@lucent.com>
25371
25372         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
25373         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
25374
25375 2002-05-28  Jim Meyering  <meyering@lucent.com>
25376
25377         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
25378         Reported by Volker Borchert.
25379
25380 2002-05-27  Jim Meyering  <meyering@lucent.com>
25381
25382         Fix a problem seen only on nonconforming systems whereby ls.c's
25383         use of localtime, and then of gettimeofday would cause trouble:
25384         the localtime call used to initialize rpl_gettimeofday's save
25385         mechanism would clobber ls's current local time information so
25386         that in any long listing the first file would always be listed
25387         with date 1970-01-01.  Analysis by Volker Borchert.
25388
25389         * lib/gettimeofday.c (localtime): Undefine.
25390         (rpl_localtime): New function.
25391
25392 2002-05-27  Jim Meyering  <meyering@lucent.com>
25393
25394         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
25395         localtime.
25396
25397         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
25398         use the replacement function; it wouldn't resolve at link time.
25399         Reported by Volker Borchert.
25400
25401 2002-05-22  Jim Meyering  <meyering@lucent.com>
25402
25403         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
25404         file-type.h.
25405         * lib/file-type.h: New file.
25406         * lib/file-type.c (file_type): New file/function.  Extracted from
25407         diffutils.
25408
25409 2002-04-30  Jim Meyering  <meyering@lucent.com>
25410
25411         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
25412
25413 2002-04-29  Paul Eggert  <eggert@twinsun.com>
25414
25415         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
25416
25417 2002-04-29  Paul Eggert  <eggert@twinsun.com>
25418
25419         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
25420         Do not check for alloca.h (no longer used) or stdbool.h (was never
25421         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
25422
25423 2002-04-29  Paul Eggert  <eggert@twinsun.com>
25424
25425         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
25426
25427 2002-04-29  Jim Meyering  <meyering@lucent.com>
25428
25429         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
25430         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
25431         Use AC_FUNC_STRNLEN here instead.
25432
25433         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
25434         With autoconf-2.53a, it's part of AC_PROG_CC.
25435
25436 2002-04-28  Paul Eggert  <eggert@twinsun.com>
25437
25438         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
25439         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
25440
25441 2002-04-28  Paul Eggert  <eggert@twinsun.com>
25442
25443         * lib/sig2str.h, lib/sig2str.c: New files.
25444         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
25445
25446 2002-04-28  Paul Eggert  <eggert@twinsun.com>
25447
25448         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
25449         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
25450         of 127, since 64 is the largest conceivable number for ancient
25451         nonstandard hosts.
25452         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
25453
25454 2002-04-28  Jim Meyering  <meyering@lucent.com>
25455
25456         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
25457
25458 2002-04-24  Jim Meyering  <meyering@lucent.com>
25459
25460         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
25461         (jm_PREREQ): Use it.
25462
25463         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
25464         mach/mach.h fcntl.h.
25465         Check for this function: setlocale.
25466
25467 2002-04-24  Jim Meyering  <meyering@lucent.com>
25468
25469         * lib/gettext.h: New file, from Gettext.
25470         * lib/Makefile.am (INCLUDES): Remove -I../intl.
25471         (libfetish_a_SOURCES): Add gettext.h.
25472
25473 2002-04-16  Jim Meyering  <meyering@lucent.com>
25474
25475         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
25476         ut_pid, ut_id, ut_exit.
25477
25478 2002-04-16  Jim Meyering  <meyering@lucent.com>
25479
25480         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
25481         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
25482         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
25483
25484 2002-04-12  Jim Meyering  <meyering@lucent.com>
25485
25486         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
25487         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
25488         existence of the getmntinfo function.  Needed for Darwin 5.3.
25489
25490         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
25491         This is necessary at least on Darwin 5.3.
25492
25493         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
25494         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
25495         strnlen.o in the library, and that makes some versions of ranlib
25496         object.
25497
25498 2002-04-12  Jim Meyering  <meyering@lucent.com>
25499
25500         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
25501
25502 2002-04-09  Jim Meyering  <meyering@lucent.com>
25503
25504         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
25505         to be more precise.  Rather than saying we're checking whether the
25506         function `works', say what we're testing.
25507         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
25508         Reported by Bruno Haible.
25509
25510 2002-03-10  Jim Meyering  <meyering@lucent.com>
25511
25512         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
25513         Suggestion from Santiago Vila.
25514
25515 2002-03-08  Jim Meyering  <meyering@lucent.com>
25516
25517         * lib/rename.c: Mention that this wrapper is needed also on
25518         mips-dec-ultrix4.4 systems.
25519
25520 2002-03-02  Jim Meyering  <meyering@lucent.com>
25521
25522         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
25523         not HAVE_CLOCK_SETTIME.
25524
25525 2002-02-27  Paul Eggert  <eggert@twinsun.com>
25526
25527         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
25528         Check for clock_settime.
25529
25530 2002-02-27  Paul Eggert  <eggert@twinsun.com>
25531
25532         * lib/nanosleep.h: Rename to....
25533         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
25534
25535         * lib/gettime.c: New file.
25536         * lib/settime.c: New file.
25537         * lib/stime.c: Remove.
25538
25539         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
25540         timespec.h.  Remove nanosleep.h.
25541
25542 2002-02-25  Paul Eggert  <eggert@twinsun.com>
25543
25544         * m4/acl.m4: New file.
25545         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
25546         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
25547
25548 2002-02-25  Paul Eggert  <eggert@twinsun.com>
25549
25550         * lib/acl.c, lib/acl.h: New files.
25551         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
25552
25553 2002-02-24  Jim Meyering  <meyering@lucent.com>
25554
25555         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
25556         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
25557         cause trouble.  Reported by Nelson Beebe.
25558
25559 2002-02-23  Paul Eggert  <eggert@twinsun.com>
25560
25561         * lib/path-concat.c (xpath_concat): Reorder code to pacify
25562         compilers that don't know that xalloc_die never returns.
25563
25564 2002-02-20  Jim Meyering  <meyering@lucent.com>
25565
25566         * lib/getdate.c: Regenerate using bison-1.33.
25567
25568 2002-02-17  Jim Meyering  <meyering@lucent.com>
25569
25570         * config/config.guess (main): Don't use `head -1'; it's no longer
25571         portable. Use `sed 1q' instead.
25572
25573 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
25574
25575         * m4/codeset.m4: Upgrade to gettext-0.11.
25576         * m4/gettext.m4: Upgrade to gettext-0.11.
25577         * m4/glibc21.m4: Upgrade to gettext-0.11.
25578         * m4/iconv.m4: Upgrade to gettext-0.11.
25579         * m4/isc-posix.m4: Upgrade to gettext-0.11.
25580         * m4/lcmessage.m4: Upgrade to gettext-0.11.
25581         * m4/lib-ld.m4: New file, from gettext-0.11.
25582         * m4/lib-link.m4: New file, from gettext-0.11.
25583         * m4/lib-prefix.m4: New file, from gettext-0.11.
25584         * m4/progtest.m4: Upgrade to gettext-0.11.
25585
25586 2002-02-15  Paul Eggert  <eggert@twinsun.com>
25587
25588         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
25589         (jm_PREREQ): Use it.
25590
25591 2002-02-15  Paul Eggert  <eggert@twinsun.com>
25592
25593         * lib/posixver.c, lib/posixver.h: New files.
25594         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
25595
25596 2002-02-02  Paul Eggert  <eggert@twinsun.com>
25597             Bruno Haible  <bruno@clisp.org>
25598
25599         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
25600         (fwrite_success_callback): New declaration.
25601         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
25602         print_unicode_char. Call failure callback instead of error.
25603         (fwrite_success_callback): New function.
25604         (exit_failure_callback): New function.
25605         (fallback_failure_callback): New function.
25606         (print_unicode_char): Call unicode_to_mb.
25607
25608 2002-01-26  Jim Meyering  <meyering@lucent.com>
25609
25610         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
25611         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
25612
25613 2002-01-26  Jim Meyering  <meyering@lucent.com>
25614
25615         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
25616
25617 2002-01-22  Paul Eggert  <eggert@twinsun.com>
25618
25619         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
25620
25621 2002-01-22  Jim Meyering  <meyering@lucent.com>
25622
25623         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
25624         Otherwise, some versions of automake would omit the rule that makes
25625         Makefile from Makefile.in.
25626
25627 2002-01-21  Paul Eggert  <eggert@twinsun.com>
25628
25629         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
25630         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
25631         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
25632         (memcoll): Set errno to zero if there is no error.
25633
25634         * lib/quotearg.c (quotearg_buffer_restyled):
25635         Fix bug with quoting buffers containing NUL when backslashing escapes.
25636         This bug was exposed by the other changes in this patch.
25637         (quotearg_n_options): New arg ARGSIZE.
25638         All callers changed.
25639         (quoting_options_from_style): New function.
25640         (quotearg_n_style): Use it.
25641         (quotearg_n_style_mem): New function.
25642
25643         * lib/quotearg.h (quotearg_n_style_mem): New function.
25644
25645 2002-01-19  Jim Meyering  <meyering@lucent.com>
25646
25647         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
25648         Remove useless quotes: DF_PROG="df".
25649         * m4/strnlen.m4: New file.
25650
25651 2002-01-16  Paul Eggert  <eggert@twinsun.com>
25652
25653         * lib/backupfile.c (ISDIGIT): Comment fix.
25654         * lib/getdate.y (ISDIGIT): Likewise.
25655         * lib/posixtm.c (ISDIGIT, year): Likewise.
25656         * lib/strverscmp.c (ISDIGIT): Likewise.
25657         * lib/userspec.c (ISDIGIT): Likewise.
25658
25659 2002-01-16  Jim Meyering  <meyering@lucent.com>
25660
25661         * lib/getdate.y: Add three semicolons, each just before a closing
25662         brace. Bison (as of version 1.31) no longer papers over that mistake.
25663
25664 2002-01-05  Jim Meyering  <meyering@lucent.com>
25665
25666         * lib/version-etc.c (version_etc_copyright): Update copyright year.
25667
25668 2001-12-19  Paul Eggert  <eggert@twinsun.com>
25669
25670         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
25671         not silently exit merely because the output buffer happens to
25672         have nothing pending.
25673
25674 2001-12-18  Paul Eggert  <eggert@twinsun.com>
25675
25676         See the big note in ../ChangeLog.
25677         * lib/human.c (suffixes): Prefer K to k for 1024.
25678         (generate_suffix_backwards): New function.
25679         (human_readable_inexact): Use it.
25680         * lib/xstrtol.c (__xstrtol): If there is no number but there
25681         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
25682         Accept 'K' as well as 'k'.
25683
25684 2001-12-15  Jim Meyering  <meyering@lucent.com>
25685
25686         * lib/regex.h (__restrict_arr): Update from libc.
25687
25688         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
25689         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
25690         (STREQ): Define.
25691
25692 2001-12-14  Jim Meyering  <meyering@lucent.com>
25693
25694         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
25695         Suggestion from Bruno Haible.
25696
25697 2001-12-10  Jim Meyering  <meyering@lucent.com>
25698
25699         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
25700         xrealloc, Instead, include "xalloc.h".
25701         (initbuffer): Don't cast xmalloc return value to char*.
25702         (readline): Reword comment.
25703         Don't cast xrealloc return value to char*
25704         Return NULL, not 0.
25705
25706 2001-12-09  Jim Meyering  <meyering@lucent.com>
25707
25708         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
25709         about `signed and unsigned type in conditional expression'.
25710         * lib/posixtm.c (posix_time_parse): Likewise.
25711
25712         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
25713
25714         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
25715         to avoid a pedantic warning.
25716
25717         * lib/getstr.c: Don't include assert.h.
25718         (getstr): Remove warning-evoking assertions.
25719         Return -1 if offset parameter is out of bounds.
25720         Change the type of a local from int to size_t.
25721
25722         * lib/strftime.c (my_strftime_localtime_r): Include this function
25723         definition in the `#if ! HAVE_TM_GMTOFF' block.
25724
25725         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
25726         Include xalloc.h instead.
25727
25728 2001-12-02  Jim Meyering  <meyering@lucent.com>
25729
25730         * lib/tempname.c: Don't declare getenv, thus reverting the change of
25731         2001-11-18.  It's no longer necessary, now that stdlib.h is always
25732         included.
25733
25734         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
25735         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
25736
25737 2001-11-30  Akim Demaille  <akim@epita.fr>
25738
25739         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
25740         before being defined.
25741
25742 2001-11-27  Paul Eggert  <eggert@twinsun.com>
25743
25744         * lib/quotearg.h (quotearg_n, quotearg_n_style):
25745         First arg is int, not unsigned.
25746         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
25747         (SIZE_MAX, UINT_MAX): New macros.
25748         (quotearg_n_options): Abort if N is negative.
25749         Avoid overflow check on hosts where size_t is 64 bits and int
25750         is 32 bits, as overflow is impossible there.
25751         Fix off-by-one typo that caused unnecessary reallocation.
25752
25753 2001-11-27  Jim Meyering  <meyering@lucent.com>
25754
25755         * lib/tempname.c: Merge with version from libc.
25756         * lib/regex.c: Likewise.
25757
25758         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
25759         systems for which STDC_HEADERS is 0, it was not included, resulting in
25760         a warning about an integer-to-pointer conversion problem with getenv.
25761         Reported by Volker Borchert.
25762
25763 2001-11-26  Jim Meyering  <meyering@lucent.com>
25764
25765         * lib/gtod.h: Remove file.
25766         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
25767         * lib/gettimeofday.c: Don't include gtod.h.
25768         (GTOD_init): Remove function.
25769         (rpl_gettimeofday): Do its job here instead, rather than aborting.
25770         Suggestion from Volker Borchert.
25771
25772 2001-11-23  Jim Meyering  <meyering@lucent.com>
25773
25774         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
25775         it.
25776         * lib/hash.c (struct hash_table): Define it here instead.
25777
25778 2001-11-22  Jim Meyering  <meyering@lucent.com>
25779
25780         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
25781
25782 2001-11-20  Jim Meyering  <meyering@lucent.com>
25783
25784         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
25785         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
25786
25787 2001-11-19  Jim Meyering  <meyering@lucent.com>
25788
25789         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
25790         directory.  Use "conftestXXXXXX" as the template.
25791         Suggestion from Paul Eggert.
25792
25793         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
25794         immediately, so the test doesn't mistakenly hit the max-open-files
25795         limit.
25796
25797 2001-11-18  Paul Eggert  <eggert@twinsun.com>
25798
25799         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
25800         (TEMPORARIES): New macro.
25801         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
25802         removes an artificial limitation (e.g. HP-UX 10.20, where
25803         TMP_MAX is 17576).
25804
25805 2001-11-18  Jim Meyering  <meyering@lucent.com>
25806
25807         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
25808
25809 2001-11-18  Jim Meyering  <meyering@lucent.com>
25810
25811         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
25812         on SunOS 4.
25813
25814         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
25815         files will be created before anything else.
25816
25817 2001-11-17  Paul Eggert  <eggert@twinsun.com>
25818
25819         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
25820         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
25821
25822 2001-11-17  Jim Meyering  <meyering@lucent.com>
25823
25824         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
25825         Prompted by a report from Bob Proulx.
25826
25827         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
25828         Instead, require UTILS_FUNC_MKSTEMP.
25829
25830 2001-11-17  Jim Meyering  <meyering@lucent.com>
25831
25832         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
25833         Now, that's done as part of AC_FUNC_STRTOD.
25834
25835 2001-11-17  Jim Meyering  <meyering@lucent.com>
25836
25837         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
25838         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
25839         rather than group writable.  Patch by Juan F. Codagnone.
25840
25841         * lib/readtokens.c: Remove explicit declarations of xmalloc and
25842         xrealloc, Instead, include "xalloc.h".
25843
25844         * lib/mountlist.c: Include unlocked-io.h after all system headers.
25845         Remove explicit declarations of xmalloc, xrealloc,
25846         and xstrdup.  Instead, include "xalloc.h".
25847
25848         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
25849         unlocked-io.h.
25850         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
25851         Likewise.
25852         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
25853
25854         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
25855         Reported by Padraig Brady.
25856
25857         * lib/mkstemp.c: #undef mkstemp.
25858         Include config.h.
25859         (rpl_mkstemp): Rename from mkstemp.
25860         Protoize.
25861
25862 2001-11-16  Jim Meyering  <meyering@lucent.com>
25863
25864         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
25865         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
25866         determine the amount of total physical memory, use pstat_getstatic.
25867         HPUX-11 doesn't define _SC_PHYS_PAGES.
25868         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
25869         If sysconf couldn't be used to determine the amount of available
25870         physical memory, use both pstat_getstatic and pstat_getdynamic.
25871         Based on a patch from Bob Proulx.
25872
25873 2001-11-10  Jim Meyering  <meyering@lucent.com>
25874
25875         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
25876         (jm_PREREQ): Use it.
25877
25878 2001-11-09  Jim Meyering  <meyering@lucent.com>
25879
25880         * m4/jm-macros.m4: Require autoconf-2.52f.
25881         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
25882         Use these AC_-prefixed names, not the AM_-prefixed ones.
25883
25884         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
25885
25886 2001-11-05  Jim Meyering  <meyering@lucent.com>
25887
25888         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
25889
25890 2001-11-04  Jim Meyering  <meyering@lucent.com>
25891
25892         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
25893         $DEFS.
25894
25895 2001-11-03  Jim Meyering  <meyering@lucent.com>
25896
25897         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
25898         of AC_DEFUN.
25899
25900         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
25901         know the name of the variable in the macro definition.
25902
25903 2001-11-03  Jim Meyering  <meyering@lucent.com>
25904
25905         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
25906         in argmatch_to_argument call.
25907
25908         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
25909         argument.
25910
25911         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
25912         e.g., a fault due to an attempt to free a NULL pointer.
25913
25914 2001-11-01  Jim Meyering  <meyering@lucent.com>
25915
25916         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
25917         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
25918
25919 2001-11-01  Jim Meyering  <meyering@lucent.com>
25920
25921         * lib/dirfd.c, lib/dirfd.h: New files.
25922         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
25923
25924         * lib/hash.c (hash_print) [TESTING]: Clean up.
25925
25926 2001-10-22  Paul Eggert  <eggert@twinsun.com>
25927
25928         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
25929         to avoid a warning if -Wall.
25930
25931 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
25932
25933         * README: New file
25934         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
25935         (per RMS's instructions, this is now the canonical source)
25936         * lgpl/, gpl/: New directories.
25937
25938 2001-10-21  Paul Eggert  <eggert@twinsun.com>
25939
25940         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
25941
25942 2001-10-21  Jim Meyering  <meyering@lucent.com>
25943
25944         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
25945         this code would end up calling gettext even in packages built
25946         with --disable-nls.
25947         * lib/getopt.c (_): Likewise.
25948         * lib/regex.c (_): Likewise.
25949
25950 2001-10-20  Paul Eggert  <eggert@twinsun.com>
25951
25952         * m4/error.m4 (jm_PREREQ_ERROR):
25953         Do not invoke AC_CHECK_FUNCS with strerror_r, as
25954         AC_FUNC_STRERROR_R does that.
25955         Check for strerror declaration.
25956
25957         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
25958         are supposed to have them these days.
25959         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
25960         Merge changes from latest Autoconf CVS.
25961         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
25962         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
25963         POSIX decided to standardize on the int flavor of strerror_r.
25964
25965 2001-10-20  Paul Eggert  <eggert@twinsun.com>
25966
25967         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
25968         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
25969         Use strerror_r that is only a macro, even if it is not a function.
25970         (strerror): Check for HAVE_DECL_STRERROR before declaring.
25971         (private_strerror): Use prototypes, not old-style function definition.
25972         (print_errno_message): New function.
25973         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
25974         char*-flavored one.
25975         (error_tail, error, error_at_line): Use it.
25976
25977 2001-10-11  Jim Meyering  <meyering@lucent.com>
25978
25979         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
25980         and quote_n (1, ... to avoid clobbering a buffer.
25981
25982 2001-10-05  Jim Meyering  <meyering@lucent.com>
25983
25984         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
25985         hash-pjw.h.
25986         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
25987         * lib/hash-pjw.h: New file.
25988
25989 2001-09-30  Jim Meyering  <meyering@lucent.com>
25990
25991         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
25992         `struct fsstat' has the `f_fstypename' member.
25993         Use that to define FS_TYPE, which is now used to make
25994         the getfsstat link test tighter.
25995
25996 2001-09-30  Jim Meyering  <meyering@lucent.com>
25997
25998         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
25999         Include <sys/ucred.h>, for Apple Darwin.
26000         Include sys/mount.h and sys/fs_types.h only if available.
26001         (FS_TYPE): Define.
26002         (read_filesystem_list): Use FS_TYPE.
26003
26004 2001-09-29  Paul Eggert  <eggert@twinsun.com>
26005
26006         * lib/exclude.c (excluded_filename): 0 -> false, since it's
26007         a boolean context.
26008
26009 2001-09-29  Jim Meyering  <meyering@lucent.com>
26010
26011         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
26012         [one-argument getmntent function]): Include stdio.h before mntent.h.
26013         SunOS 4.1.x needs it for the declaration of `FILE'.
26014         Patch by Volker Borchert.
26015
26016         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
26017         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
26018         sys/fs_types.h, and make the link-test for getfsstat guard #include
26019         directives with appropriate #if HAVE_*_H tests so that we can
26020         detect getfsstat on Apple Darwin1.3.7 systems.
26021         Reported by Nelson Beebe.
26022         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
26023
26024 2001-09-28  Paul Eggert  <eggert@twinsun.com>
26025
26026         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
26027         #defines strtoimax.  Also treat the other strto* functions
26028         like strtoimax.
26029
26030         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
26031         Check for strtoul and strtoumax,
26032         as those declarations are made even in the signed case.
26033         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
26034         Likewise, for strtol and strtoimax.
26035
26036 2001-09-28  Paul Eggert  <eggert@twinsun.com>
26037
26038         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
26039         #defines strtoimax.  Also treat the other strto* functions
26040         like strtoimax.
26041
26042         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
26043         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
26044         (strtoimax, strtoumax): Do not declare if already defined as a macro.
26045
26046 2001-09-26  Jim Meyering  <meyering@lucent.com>
26047
26048         Most macros in unlocked-io.h had the wrong number of arguments.
26049         * lib/gen-uio: New script.
26050         (USE_UNLOCKED_IO): Define to 1 if not already defined.
26051         * lib/unlocked-io.hin: Remove file.
26052         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
26053         rather than trying to embed it here.
26054         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
26055         Reported by Padraig Brady.
26056
26057 2001-09-25  Volker Borchert  <bt@teknon.de>
26058
26059         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
26060         `result'.
26061
26062 2001-09-24  Jim Meyering  <meyering@lucent.com>
26063
26064         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
26065
26066 2001-09-23  Jim Meyering  <meyering@lucent.com>
26067
26068         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
26069         instead of the mere test for existence of mntent.h.  The latter
26070         would get a false-positive on AIX 3.4 systems.
26071         In the outer getmntent if-block, don't die if neither of the getmntent
26072         tests succeeds.  Instead, just fall through and continue with the
26073         remaining tests.
26074
26075 2001-09-23  Jim Meyering  <meyering@lucent.com>
26076
26077         * lib/mountlist.c: Remove useless parentheses in #if directives.
26078         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
26079         the deprecated MOUNTED symbol is no longer defined in mntent.h.
26080
26081 2001-09-22  Jim Meyering  <meyering@lucent.com>
26082
26083         * m4/gettext.m4: New file.  From gettext.
26084         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
26085         * m4/progtest.m4: Likewise
26086         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
26087         * m4/glibc21.m4: Likewise.
26088
26089         * m4/libintl.m4: Remove.  No longer used.
26090
26091 2001-09-22  Jim Meyering  <meyering@lucent.com>
26092
26093         * lib/localcharset.c: Update from latest gettext.
26094         * lib/config.charset: Likewise.
26095
26096 2001-09-20  Jim Meyering  <meyering@lucent.com>
26097
26098         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
26099         strtoimax.
26100         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
26101         strtoumax.
26102
26103 2001-09-20  Jim Meyering  <meyering@lucent.com>
26104
26105         * lib/xstrtol.c (strtoimax): Guard declaration with
26106         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
26107         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
26108         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
26109         (strtoumax): Likewise, for completeness (it wasn't necessary).
26110
26111 2001-09-17  Paul Eggert  <eggert@twinsun.com>
26112
26113         * lib/strtoimax.c (HAVE_LONG_LONG):
26114         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
26115         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
26116         to work around bug in IBM C compiler.
26117
26118 2001-09-17  Jim Meyering  <meyering@lucent.com>
26119
26120         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
26121         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
26122         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
26123         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
26124         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
26125         whenever the right hand side need not be expanded by the shell.
26126
26127 2001-09-16  Paul Eggert  <eggert@twinsun.com>
26128
26129         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
26130         library.  It's not correct, as some older glibcs are buggy.
26131         fnmatch wasn't fixed until glibc 2.2.
26132
26133         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
26134         special shell magic here.
26135
26136 2001-09-16  Jim Meyering  <meyering@lucent.com>
26137
26138         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
26139         * m4/jm-macros.m4: Require it.
26140
26141 2001-09-16  Jim Meyering  <meyering@lucent.com>
26142
26143         * lib/mkdir.c: New file.
26144
26145 2001-09-15  Jim Meyering  <meyering@lucent.com>
26146
26147         * m4/jm-macros.m4: Check for help2man.
26148
26149 2001-09-11  Jim Meyering  <meyering@lucent.com>
26150
26151         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
26152         The body, by Paul Eggert, was moved here from configure.in.
26153         * m4/jm-macros.m4: Require UTILS_HOST_OS.
26154
26155 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26156
26157         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
26158         (jm_PREREQ): Use it.
26159
26160 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26161
26162         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
26163         Use ssize_t, not int, to store result of readlink.
26164         Check for ssize_t overflow as well as size_t overflow,
26165         as POSIX says the result of readlink is implementation-defined
26166         when ssize_t overflows.
26167         Remove unnecessary cast to char*.
26168         Use free+malloc instead of realloc, as the storage doesn't need
26169         to be preserved and it's clearer and can be more efficient that way.
26170         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
26171         * lib/xreadlink.h (xreadlink): Update prototype.
26172
26173 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26174
26175         * lib/xgetcwd.c: Revert some of the previous change; intead,
26176         fix the HAVE_GETCWD_NULL code to behave more like the
26177         !HAVE_GETCWD_NULL code used to.
26178
26179         Include "xalloc.h".
26180         (xgetcwd): Do not return NULL when memory is exhausted; instead,
26181         invoke xalloc_die.
26182
26183 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26184
26185         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
26186         sys/param.h, as pathmax.h includes them.
26187
26188 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26189
26190         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
26191         (jm_PREREQ_XGETCWD): New macro.
26192
26193         * m4/getcwd.m4: New file.
26194
26195 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26196
26197         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
26198         like the HAVE_GETCWD_NULL code.
26199         Include pathmax.h if not HAVE_GETCWD.
26200         Do not include xalloc.h.
26201         (INITIAL_BUFFER_SIZE): New symbol.
26202         Do not use xmalloc / xrealloc, since the caller is responsible for
26203         handling errors.  Preserve errno around `free' during failure.
26204         Do not overrun buffer when using getwd.
26205
26206 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26207
26208         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
26209         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
26210         getcwd (NULL, 0).
26211
26212 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26213
26214         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
26215         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
26216         spotted by Jim Meyering.
26217
26218 2001-09-03  Jim Meyering  <meyering@lucent.com>
26219
26220         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
26221         failure.
26222
26223 2001-09-02  Jim Meyering  <meyering@lucent.com>
26224
26225         * lib/error.c: Update from GNU libc.
26226
26227 2001-09-01  Jim Meyering  <meyering@lucent.com>
26228
26229         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
26230         Used by df.
26231
26232 2001-09-01  Jim Meyering  <meyering@lucent.com>
26233
26234         * lib/xreadlink.c: New file.
26235         * lib/xreadlink.h: New file.
26236         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
26237         xreadlink.h.
26238
26239         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
26240         doesn't conflict with sparc Solaris 7's definition in
26241         /usr/include/sys/int_types.h.
26242
26243         * lib/exclude.c: Use `""', not `<>' to #include non-system header
26244         files.
26245         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
26246         and strncasecmp as r-values.  Unixware didn't have declarations.
26247
26248 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26249
26250         * lib/xstrtol.h: Add copyright notice.
26251         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
26252         LONGINT_INVALID_SUFFIX_CHAR.
26253
26254 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26255
26256         * lib/xstrtol.c (strtoimax): New decl.
26257
26258 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26259
26260         * lib/xgetcwd.c: Don't include pathmax.h.
26261         Include stdlib.h and unistd.h if available.
26262         Include xalloc.h.
26263         (xmalloc, xstrdup, free): Remove decls.
26264         (xgetcwd): Don't assume sizes fit in unsigned.
26265         Check for overflow when computing sizes.
26266         Simplify reallocation code.
26267
26268 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26269
26270         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
26271         a directory's st_size can have an arbitrary value, so the old
26272         usage could waste an arbitrary amount of memory.  All uses
26273         changed.
26274         * lib/savedir.h: Update prototype.
26275
26276 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26277
26278         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
26279
26280         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
26281         old strtoimax.c.
26282
26283         Also, make the following further changes to make this file's
26284         configuration more similar to that of strtol.c:
26285         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
26286         (strtoumax, uintmax_t, strtoull, strtol): Remove.
26287         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
26288         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
26289         changed to signed values.
26290
26291         And make the following changes as well:
26292         Fix copyright notice, as 1999 was missing.
26293         (verify): New macro.
26294         (strtoimax): Check sizes at compile-time, not run-time.
26295         Prefer strtol to strtoll if both work.
26296         (main): Remove; it was not that useful and was a pain to maintain.
26297
26298         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
26299
26300 2001-08-31  Jim Meyering  <meyering@lucent.com>
26301
26302         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
26303         Use an initial, malloc'd, buffer of length 128 rather than
26304         a statically allocated one of length 1024.
26305
26306 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26307
26308         Simplify code, partly by assuming autoconf 2.52 semantics.
26309
26310         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
26311
26312         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
26313         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
26314         All uses removed.
26315         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
26316         Move AC_REQUIRE to next-to-top level, to avoid confusion.
26317         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
26318         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
26319         jm_AC_HEADER_INTTYPES_H.
26320         * m4/jm-macros.m4 (jm_MACROS): Likewise.
26321
26322         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
26323
26324         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
26325         Quote first arg of AC_DEFUN.
26326         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
26327         since they are needed to parse the include file even if we need
26328         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
26329         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
26330         but with opposite signedness.
26331
26332 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26333
26334         Merge 'exclude' changes from tar 1.13.22.
26335         This fixes one or two unlikely storage allocation overflow bugs,
26336         but doesn't change user-visible behavior otherwise.
26337
26338 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26339
26340         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
26341         (jm_PREREQ_EXCLUDE): New macro.
26342
26343 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26344
26345         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
26346         tm to be declared.
26347
26348 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26349
26350         * lib/hash.c: Remove '2001' from copyright notice.
26351
26352 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26353
26354         * lib/full-write.h: New file.
26355         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
26356         * lib/full-write.c: Correct credits, as cccp.c no longer
26357         exists and anyway it was so heavily changed from the old cccp
26358         code as to be unrecognizable.  Include full-write.h.
26359         (full_write) Return size_t, with short writes meaning failure.
26360         All callers changed.  This fixes a bug with large buffers
26361         on 64-bit hosts.
26362         * lib/utime.c: Include full-write.h.
26363
26364 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26365
26366         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
26367         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
26368         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
26369         Include if available.
26370         (<xalloc.h>): Include
26371         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
26372         (verify): New macro.  Use it to verify that EXCLUDE macros do not
26373         collide with FNM macros.
26374         (struct patopts): New struct.
26375         (struct exclude): Use it, as exclude patterns now come with options.
26376         (new_exclude): Support above changes.
26377         (new_exclude, add_exclude_file):
26378         Initial size must now be a power of two to simplify overflow checking.
26379         (free_exclude, fnmatch_no_wildcards): New function.
26380         (excluded_filename): No longer requires options arg, as the options
26381         are determined by add_exclude.  Now returns bool, not int.
26382         (excluded_filename, add_exclude):
26383         Add support for the fancy new exclusion options.
26384         (add_exclude, add_exclude_file): Now takes int options arg.
26385         Check for arithmetic overflow when computing sizes.
26386         (add_exclude_file): xrealloc might modify errno, so don't
26387         realloc until after errno might be used.
26388
26389         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
26390         New macros.
26391         (free_exclude): New decl.
26392         (add_exclude, add_exclude_file): Now takes int options arg.
26393         (excluded_filename): No longer requires options arg, as the options
26394         are determined by add_exclude.  Now returns bool, not int.
26395
26396 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26397
26398         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
26399
26400 2001-08-27  Jim Meyering  <meyering@lucent.com>
26401
26402         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
26403
26404         * lib/version-etc.c (N_): Remove definition.
26405         Revert most of last change.
26406         Instead, simply don't mark the `Copyright...' string for translation.
26407         Based on advice from Paul Eggert.
26408
26409         * lib/strtoxmax.c: Tweak comment.
26410
26411 2001-08-26  Jim Meyering  <meyering@lucent.com>
26412
26413         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
26414
26415         * m4/xstrtoimax.m4: New file.
26416         * m4/xstrtoumax.m4: Add comments explaining why we
26417         AC_REPLACE_FUNCS(strtol).
26418
26419 2001-08-26  Jim Meyering  <meyering@lucent.com>
26420
26421         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
26422         of copyright with `%s' so translators don't get an untranslated
26423         message in 2002.
26424         (COPYRIGHT_YEAR): Define.
26425         (version_etc): Use fprintf rather than fputs.
26426         Suggestion from Ulrich Drepper.
26427
26428         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
26429
26430         * lib/strtoll.c: New file, from GNU libc.
26431         * lib/xstrtoimax.c: New file.
26432
26433         * lib/xstrtol.h: Add xstrtoimax.
26434         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
26435         * lib/strtoimax.c: New file.  Likewise, but first define
26436         STRTOUXMAX_SIGNED.
26437
26438         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
26439         ...
26440         * lib/strtoxmax.c: ... then renamed to this.
26441
26442 2001-08-18  Paul Eggert  <eggert@twinsun.com>
26443
26444         * m4/inttypes.m4: Add AC_PREREQ(2.13).
26445         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
26446         (jm_AC_TYPE_INTMAX_T): New macro.
26447         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
26448
26449         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
26450
26451         * m4/longlong.m4: Renamed from ulonglong.m4.
26452         * m4/inttypes.m4: Renamed from inttypes_h.m4.
26453         * m4/uintmax_t.m4: Removed.
26454
26455 2001-08-13  Paul Eggert  <eggert@twinsun.com>
26456
26457         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
26458         Port to Solaris 8, where 'sed' requires a space after the 'r'
26459         command, and where sh dislikes "$/".  Clean up the spacing a bit.
26460         Redirect output to $tmp just once.
26461
26462 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
26463
26464         * lib/addext.c (<errno.h>): Include.
26465         (errno): Declare if not defined.
26466         (addext): Work correctly when pathconf returns -1 and leaves
26467         errno alone because there is no limit.  Also, work even if
26468         pathconf returns a value greater than SIZE_MAX.
26469
26470 2001-08-12  Jim Meyering  <meyering@lucent.com>
26471
26472         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
26473         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
26474         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
26475         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
26476         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
26477         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
26478         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
26479         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
26480         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
26481         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
26482         utime.m4, utimes.m4, xstrtoumax.m4:
26483         Quote the first argument in each use of AC_DEFUN.
26484
26485 2001-08-12  Jim Meyering  <meyering@lucent.com>
26486
26487         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
26488         Simply `return getcwd (NULL, 0);'.
26489         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
26490         Use 1300 as initial value for length, not PATH_MAX.
26491
26492         * lib/pathmax.h: Clean up cpp syntax.
26493
26494 2001-08-12  Jim Meyering  <meyering@lucent.com>
26495
26496         * lib/gettimeofday.c: New file.
26497         * lib/gtod.h: New file.
26498         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
26499
26500 2001-08-05  Jim Meyering  <meyering@lucent.com>
26501
26502         * m4/jm-macros.m4: Require autoconf-2.52.
26503
26504 2001-08-04  Jim Meyering  <meyering@lucent.com>
26505
26506         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
26507         stmt, to get in sync with glibc.
26508
26509 2001-08-03  Paul Eggert  <eggert@twinsun.com>
26510
26511         The following changes are from gettext 0.10.39 as maintained by
26512         Bruno Haible.
26513
26514         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
26515         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
26516         with inverted sense.  All uses changed.
26517
26518         * lib/mbswidth.c: Don't include <limits.h>.
26519         Include <stdlib.h> and <string.h> unconditionally.
26520         (iswcntrl, mbsinit, ISCNTRL): New macros.
26521         (mbsnwidth): Use K&R style function declarations.
26522         Don't bother checking for MB_LEN_MAX == 1, since the compiler
26523         can optimize it when MB_CUR_MAX == 1.
26524         The width of control characters is zero, not 1.
26525
26526 2001-08-03  Paul Eggert  <eggert@twinsun.com>
26527
26528         The following changes are from gettext 0.10.39 as maintained by
26529         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
26530
26531         * m4/codeset.m4: Upgrade to serial AM1.
26532         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
26533         all uses changed.  Quote first arg of AC_DEFUN.
26534         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
26535
26536         * m4/iconv.m4: Upgrade to serial AM2.
26537         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
26538         Add --with-libconv-prefix.
26539         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
26540         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
26541         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
26542         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
26543         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
26544
26545         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
26546         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
26547         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
26548         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
26549         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
26550         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
26551         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
26552         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
26553         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
26554
26555         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
26556         string.h any more.
26557
26558         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
26559         not the default value.
26560
26561         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
26562         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
26563         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
26564         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
26565         Also check for iswcntrl, used for wcwidth fallback.
26566         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
26567         to Autoconf 2.13.
26568
26569 2001-08-03  Jim Meyering  <meyering@lucent.com>
26570
26571         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
26572         as it was in the original.  Reported by Paul Eggert.
26573
26574 2001-07-16  Jim Meyering  <meyering@lucent.com>
26575
26576         * m4/gettimeofday.m4: New file.
26577         Prompted by a report from Bernhard Baehr.
26578
26579 2001-07-15  Jim Meyering  <meyering@lucent.com>
26580
26581         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
26582         stuff. Now it's in ../Makefile.cfg.
26583
26584 2001-07-15  Jim Meyering  <meyering@lucent.com>
26585
26586         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
26587         (BUILT_SOURCES): Add unlocked-io.h.
26588         (io_functions): Define.
26589         (unlocked-io.h): New rule.
26590         (DISTCLEANFILES): Add unlocked-io.h.
26591         (all-local): Depend on unlocked-io.h, to ensure it is created.
26592
26593         * lib/unlocked-io.hin: New file
26594
26595         * lib/regex.c: Update from glibc.
26596
26597 2001-07-05  Jim Meyering  <meyering@lucent.com>
26598
26599         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
26600         recommendation.
26601         (libfetish_a_SOURCES): Put all .h files here instead.
26602         Remove a thus-exposed (better checks in automake) duplicate and
26603         two unnecessary .h files.
26604
26605 2001-07-04  Jim Meyering  <meyering@lucent.com>
26606
26607         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
26608         that generates jm-glibc-io.m4 so that it doesn't trigger any make
26609         distcheck failure.
26610
26611 2001-07-02  Jim Meyering  <meyering@lucent.com>
26612
26613         The following changes were prompted by suggestions from Bruno Haible.
26614
26615         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
26616         is now generated.
26617         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
26618         definition of EXTRA_DIST.
26619         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
26620         ensure that the generated file is created/updated whenever the list
26621         of $(unlocked_functions) is changed.
26622         (jm-glibc-io.m4): New rule.
26623         (unlocked-io.h): New rule -- currently unused.
26624
26625 2001-06-24  Jim Meyering  <meyering@lucent.com>
26626
26627         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
26628         unmatched right bracket, rather than kludging it with an extra,
26629         falsely-matching quote in a comment.  Patch by Akim Demaille.
26630
26631 2001-06-11  Jim Meyering  <meyering@lucent.com>
26632
26633         * lib/regex.c: Update from GNU libc.
26634
26635 2001-05-27  Jim Meyering  <meyering@lucent.com>
26636
26637         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
26638         Check for ut_type in struct utmp.
26639
26640 2001-05-27  Jim Meyering  <meyering@lucent.com>
26641
26642         * lib/readutmp.h (UT_TYPE): Define.
26643
26644 2001-05-24  Jim Meyering  <meyering@lucent.com>
26645
26646         * lib/argmatch.c: Include "quote.h".
26647         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
26648         quote function.  Reported by Göran Uddeborg.
26649
26650 2001-05-22  Jim Meyering  <meyering@lucent.com>
26651
26652         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
26653         now that we use the package-supplied version unconditionally.
26654         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
26655
26656 2001-05-21  Jim Meyering  <meyering@lucent.com>
26657
26658         * m4/regex.m4: Change a couple backticks to single quotes to avoid
26659         shell syntax errors.
26660
26661 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26662
26663         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
26664
26665 2001-05-20  Paul Eggert  <eggert@twinsun.com>
26666
26667         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
26668         Don't bother to check library strftime, since
26669         we'll be using our own my_strftime function anyway.
26670         Define my_strftime instead of strftime.
26671
26672 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
26673
26674         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
26675         which is not yet declared.
26676
26677 2001-05-15  Jim Meyering  <meyering@lucent.com>
26678
26679         * m4/regex.m4: Use proper quoting so brackets appear in the test
26680         program.
26681         Reported by, and with help from, Bruno Haible.
26682
26683 2001-05-13  Jim Meyering  <meyering@lucent.com>
26684
26685         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
26686         undefined.
26687
26688 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26689
26690         dirname code cleanup.  base_name now behaves more compatibly
26691         with POSIX basename when given file names that have trailing
26692         slashes, and similarly for dir_name.  Add new primitives
26693         base_len and dir_len.  Put the directory-name-related decls
26694         into dirname.h.
26695
26696         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
26697         * lib/backupfile.c (base_name): Likewise.
26698         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
26699         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
26700         * lib/makepath.c (strip_trailing_slashes): Likewise.
26701         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
26702         ISSLASH): Likewise.
26703         * lib/rename.c (strip_trailing_slashes): Likewise.
26704         * lib/same.c (base_name): Likewise.
26705         * lib/stripslash.c (ISSLASH): Likewise.
26706
26707         * lib/addext.c: Include <dirname.h> after size_t is defined.
26708         * lib/backupfile.c: Likewise.
26709
26710         * lib/addext.c (addext): Use base_len to trim redundant
26711         trailing slashes instead of doing it ourselves.
26712         But do not trim the last slash if it is not redundant.
26713
26714         * lib/backupfile.c (find_backup_file_name,
26715         max_backup_version): Use base_len instead of rolling it ourselves.
26716         Handle the case of "" and (on DOS) "C:" correctly.
26717
26718         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
26719         needed. Include <string.h>, <dirname.h>.
26720         (base_name): Allow file names ending in slashes, other than names
26721         that are all slashes.  In this case, return the basename followed
26722         by the slashes.  This is more general, and can be used in places
26723         where the original base_name purposely had an assertion failure.
26724         (base_len): New function.
26725
26726         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
26727         Do not include <assert.h>; no longer needed.
26728         Include xalloc.h.
26729         (memrchr): Remove decl.
26730         (dir_name_r): Remove.
26731         (dir_len): Renamed from dirlen.  All callers changed.
26732         Rewrite in terms of base_name, for simplicity and consistency.
26733         (dir_name): Never return NULL.  All callers changed.
26734         Do not include <stdlib.h> in test program; no longer needed.
26735         return 0; is fine for test program.
26736
26737         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
26738         New macros.
26739         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
26740
26741         * lib/path-concat.c (path_concat): Use base_len to compute
26742         base length, not strlen; this means we cannot rely on memcpy
26743         to null-terminate.
26744
26745         * lib/same.c (STREQ): Remove.
26746         (same_name): Handle the case where the basename ends in trailing '/'.
26747
26748         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
26749         a slash was stripped.  Do not strip the last slash after a
26750         file system prefix.
26751
26752 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26753
26754         * lib/Makefile.am (libfetish_a_SOURCES):
26755         Add strftime.c, since we now compile it on all hosts.
26756
26757         * lib/strftime.c (my_strftime):
26758         Define to nstrftime if emacs, but only if my_strftime is not defined.
26759         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
26760         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
26761         Add one more extra argument: a nanoseconds value.
26762         All uses changed.
26763         (ns): New macro.
26764         (my_strftime function): Add %N format.
26765         (emacs_strftimeu): Renamed from emacs_strftime,
26766         with extra ut argument.
26767
26768 2001-05-09  Paul Eggert  <eggert@twinsun.com>
26769
26770         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
26771
26772 2001-04-21  Jim Meyering  <meyering@lucent.com>
26773
26774         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
26775         doesn't interfere.
26776
26777 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26778
26779         * m4/ftruncate.m4: Check for chsize.
26780         Link with ftruncate.o unconditionally if ftruncate is missing.
26781         This was required when cross-compiling to i586-mingw32msvc.
26782
26783 2001-04-08  Jim Meyering  <meyering@lucent.com>
26784
26785         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
26786         recomputed; that's necessary when the offset spans a DST transition.
26787         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
26788
26789 2001-04-02  Jim Meyering  <meyering@lucent.com>
26790
26791         * lib/regex.h, regex.c: Update from GNU libc.
26792
26793 2001-03-24  Jim Meyering  <meyering@lucent.com>
26794
26795         * m4/jm-macros.m4: Require autoconf-2.49d.
26796
26797 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
26798
26799         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
26800
26801 2001-03-19  Paul Eggert  <eggert@twinsun.com>
26802
26803         * lib/version-etc.c (version_etc_copyright): Update to 2001.
26804
26805 2001-03-17  Jim Meyering  <meyering@lucent.com>
26806
26807         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
26808         now that the version in autoconf is equivalent.
26809         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
26810
26811         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
26812         Suggestion from Akim Demaille.
26813
26814         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
26815         (jm_PREREQ_TEMPNAME): New function.
26816
26817 2001-03-16  Paul Eggert  <eggert@twinsun.com>
26818
26819         * lib/tempname.c (uint64_t): Define to uintmax_t if
26820         not defined, and if UINT64_MAX is not defined.
26821         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
26822         Reported by John David Anglin.
26823
26824 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
26825
26826         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
26827         resolve alias if codeset is empty.
26828         * lib/config.charset (BeOS): Use wildcard syntax.
26829
26830 2001-03-13  Jim Meyering  <meyering@lucent.com>
26831
26832         * lib/path-concat.c (path_concat)
26833         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
26834         concatenating e.g., `C:' and `foo'.
26835         From Bruno Haible.
26836
26837 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
26838
26839         * lib/localcharset.c (locale_charset): Don't use
26840         setlocale(LC_CTYPE,NULL). Don't return NULL.
26841         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
26842
26843 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
26844
26845         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
26846         support for DOS/DJGPP.
26847
26848 2001-03-01  Paul Eggert  <eggert@twinsun.com>
26849
26850         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
26851         lacks mkstemp.  Compile our own tempname.c if we compile our own
26852         mkstemp.c, as mkstemp relies on tempname.
26853
26854 2001-03-01  Jim Meyering  <meyering@lucent.com>
26855
26856         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
26857         AH_VERBATIM really does output its argument verbatim.
26858
26859 2001-02-28  Paul Eggert  <eggert@twinsun.com>
26860
26861         * lib/Makefile.am (libfetish_a_SOURCES):
26862         Add dup-safer.c, fopen-safer.c.
26863         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
26864
26865         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
26866         * lib/unistd-safer.h: New files.
26867
26868 2001-02-25  Paul Eggert  <eggert@twinsun.com>
26869
26870         The mkstemp replacement is taken from glibc 2.2.2, with some
26871         portability fixes for use outside glibc, as follows:
26872
26873         * lib/tempname.c (struct_stat64): New macro.
26874         (direxists, __gen_tempname): Use it.
26875         This avoids a portability problem with Solaris 8.
26876
26877         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
26878         (<stddef.h>, <stdint.h>, <string.h>):
26879         Include only if STDC_HEADERS || _LIBC.
26880         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
26881         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
26882         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
26883         (__set_errno): Define this macro if <errno.h> doesn't.
26884         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
26885         Define these macros if <stdio.h> doesn't.
26886         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
26887         Define these macros if <sys/stat.h>
26888         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
26889         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
26890         __xstat64): Define if not _LIBC.
26891         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
26892         (__gen_tempname): Invoke gettimeofday only if
26893         HAVE_GETTIMEOFDAY || _LIBC;
26894         otherwise, fall back on plain "time".
26895         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
26896
26897         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
26898
26899         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
26900
26901 2001-02-18  Paul Eggert  <eggert@twinsun.com>
26902
26903         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
26904
26905 2001-02-17  Paul Eggert  <eggert@twinsun.com>
26906
26907         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
26908         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
26909         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
26910         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
26911
26912 2001-02-17  Paul Eggert  <eggert@twinsun.com>
26913
26914         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
26915         Remove workaround macros for hosts that have mbrtowc but not
26916         mbstate_t, as we now insist on proper declarations for both
26917         before using mbrtowc.
26918
26919 2001-02-17  Jim Meyering  <meyering@lucent.com>
26920
26921         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
26922         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
26923         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
26924         UnixWare 7.1.1.
26925
26926         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
26927         rather than AC_CACHE_VAL.
26928
26929 2001-02-17  Jim Meyering  <meyering@lucent.com>
26930
26931         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
26932         around included file name.
26933
26934         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
26935
26936         * lib/strftime.c: Update from GNU libc (the only changes were to
26937         comments).
26938
26939 2001-02-17  Jim Meyering  <meyering@lucent.com>
26940
26941         * lib/regex.c: Update from libc.
26942
26943 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
26944
26945         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
26946         clash.
26947
26948 2001-02-16  Paul Eggert  <eggert@twinsun.com>
26949
26950         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
26951         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
26952         Reported by Mark Hounschell via Paul Eggert.
26953
26954 2001-02-07  Jim Meyering  <meyering@lucent.com>
26955
26956         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
26957
26958 2001-02-05  Jim Meyering  <meyering@lucent.com>
26959
26960         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
26961         it includes the patch required for `large file' support with at least
26962         HP-UX's 10.20 /bin/cc.
26963
26964 2001-02-03  Jim Meyering  <meyering@lucent.com>
26965
26966         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
26967         AS_IF, now that it works once again (mysteriously).
26968         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
26969
26970 2001-01-30  Jim Meyering  <meyering@lucent.com>
26971
26972         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
26973         * m4/chown.m4: Rename conftestchown to conftest.chown.
26974         * m4/rename.m4: s/conftestdir/conftest.d1/ and
26975         s/conftestdir2/conftest.d2/.
26976         * m4/utimes.m4: s/conftestdata/conftest.data/
26977         Inspired by Pavel Roskin's change in autoconf.
26978
26979 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
26980
26981         * lib/config.charset: Update for FreeBSD 4.2.
26982
26983 2001-01-27  Jim Meyering  <meyering@lucent.com>
26984
26985         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
26986         a use of AS_IF.
26987         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
26988
26989 2001-01-26  Jim Meyering  <meyering@lucent.com>
26990
26991         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
26992         quotearg.c includes it.
26993
26994 2001-01-26  Jim Meyering  <meyering@lucent.com>
26995
26996         * lib/quotearg.c: Include stddef.h.
26997         * lib/quote.c: Include stddef.h.
26998         Reported by Axel Kittenberger.
26999
27000         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
27001         line in double quotes so that it evokes a better diagnostic.
27002         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
27003         Reported by Axel Kittenberger.
27004
27005 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
27006
27007         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
27008         as if it was a `charset'.
27009
27010 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
27011
27012         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
27013         has const.
27014
27015 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
27016
27017         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
27018         to avoid a warning.  Add back 'const' to inptr.
27019
27020 2001-01-20  Jim Meyering  <meyering@lucent.com>
27021
27022         Be sure that headers are checked before used in code compiled
27023         for the type checks.
27024         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
27025         In place of that, invoke jm_CHECK_ALL_TYPES.
27026         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
27027         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
27028         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
27029         The check for ssize_t was mistakenly run before the test for unistd.h.
27030
27031         The configure-time check for stdbool.h was missing.
27032         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
27033         (jm_PREREQ_HASH): New function.
27034
27035 2001-01-17  Jim Meyering  <meyering@lucent.com>
27036
27037         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
27038         for autoconf-2.49c.
27039         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
27040
27041 2001-01-16  Jim Meyering  <meyering@lucent.com>
27042
27043         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
27044         From Bruno Haible.
27045
27046 2001-01-14  Jim Meyering  <meyering@lucent.com>
27047
27048         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
27049         foo and bar.  Create conftestdir/ in the script, not in the C code.
27050         Remove directories in the script, not in the C code.
27051         Remove conftestdir{,2} before trying to create the directory.
27052         Make the entire configure script fail if the mkdir fails.
27053
27054 2001-01-14  Jim Meyering  <meyering@lucent.com>
27055
27056         * lib/rename.c: New file.  From Volker Borchert.
27057         Include stdlib.h, string.h or strings.h, and xalloc.h.
27058         Use strip_trailing_slashes rather than open-coding it.
27059
27060 2001-01-03  Paul Eggert  <eggert@twinsun.com>
27061
27062         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
27063
27064 2001-01-03  Jim Meyering  <meyering@lucent.com>
27065
27066         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
27067         of local `inptr' to avoid warning with some system declarations of
27068         iconv.
27069
27070 2001-01-02  Volker Borchert  <bt@teknon.de>
27071
27072         * m4/rename.m4: New file.
27073         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
27074
27075 2001-01-01  Jim Meyering  <meyering@lucent.com>
27076
27077         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
27078         even on systems with utmpx.h.  It's necessary for the declaration of
27079         utmp's ut_user member.  Reported by Andreas Jaeger.
27080
27081         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
27082         available. They are required for the declarations of getgrgid and
27083         getpwuid resp.
27084         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
27085         Reported by Andreas Jaeger.
27086
27087 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
27088
27089         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
27090         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
27091         so `make install' also works in VPATH builds.
27092
27093 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
27094
27095         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
27096         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
27097         can be used in subdirectories.
27098
27099 2000-12-29  Paul Eggert  <eggert@twinsun.com>
27100
27101         * lib/modechange.c: Do not assume that mode_t uses the
27102         traditional octal encoding.  E.g. "chmod 1 FOO" should set
27103         the other-execute bit of FOO even if S_IXOTH != 1.
27104
27105         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
27106         WOTH, XOTH, ALLM): New macros.
27107         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
27108          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
27109         Use them.
27110         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
27111         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
27112         (mode_compile):
27113         No need to use uintmax_t; unsigned long is long enough.
27114         Don't bother to get suffix since we don't use it.
27115
27116 2000-12-26  Jim Meyering  <meyering@lucent.com>
27117
27118         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
27119         better with autoheader.
27120
27121 2000-12-24  Jim Meyering  <meyering@lucent.com>
27122
27123         * lib/hash.c (is_prime): Return explicit boolean values.
27124         (hash_get_first): Return NULL to appease Irix5.6's 89.
27125         Reported by Nelson Beebe.
27126
27127 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
27128
27129         * lib/localcharset.c (locale_charset): Add support for Win32.
27130
27131 2000-12-18  Paul Eggert  <eggert@twinsun.com>
27132
27133         * lib/physmem.h, lib/physmem.c: New files.
27134
27135         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
27136         (noinst_HEADERS): Add physmem.h.
27137
27138         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
27139         't' for compatibility with Solaris 8 sort.
27140
27141 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
27142
27143         * lib/config.charset: Add support for BeOS.
27144
27145 2000-12-17  Jim Meyering  <meyering@lucent.com>
27146
27147         * m4/dos.m4 (jm_AC_DOS): New file and macro.
27148         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
27149
27150 2000-12-16  Jim Meyering  <meyering@lucent.com>
27151
27152         This bug had a serious impact on chown: `chown N:M FILE' (for integer
27153         N and M) would have treated it like `chown N:N FILE'.
27154
27155         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
27156
27157 2000-12-16  Jim Meyering  <meyering@lucent.com>
27158
27159         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
27160         SHELLS_FILE to a file name that's useful on djgpp systems.
27161         Include stdlib.h.
27162         (ADDITIONAL_DEFAULT_SHELLS): Define.
27163         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
27164         Based mostly on a patch from Prashant TR.
27165
27166 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
27167
27168         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
27169         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
27170         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
27171
27172 2000-12-08  Andreas Schwab  <schwab@suse.de>
27173
27174         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
27175         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
27176
27177 2000-12-07  Jim Meyering  <meyering@lucent.com>
27178
27179         * lib/stripslash.c (ISSLASH): Define.
27180         (strip_trailing_slashes): Use ISSLASH rather than comparing against
27181         `/'.
27182         From Prashant TR.
27183
27184         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
27185         (dir_name_r): Declare this function as static.
27186         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
27187         manifest itself on a name containing a mix of slashes and
27188         backslashes.
27189         Make this function work with names starting with a DOS-style
27190         drive letter and colon prefix.
27191         (dir_name): Append `.' if necessary.
27192         Based mostly on patches from Prashant TR and Eli Zaretskii.
27193
27194         * lib/dirname.h (dir_name_r): Remove prototype.
27195
27196 2000-12-06  Paul Eggert  <eggert@twinsun.com>
27197
27198         * m4/off_t-format.m4: Remove this file.
27199         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
27200
27201 2000-12-06  Jim Meyering  <meyering@lucent.com>
27202
27203         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
27204         replacement strtoull, we may well need the replacement strtoul, too.
27205         Check for declarations of strtoul and strtoull.
27206         Check for strtol.  Mainly as a cue to cause automake to include
27207         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
27208         Check for limits.h -- strtol.c needs it.
27209
27210 2000-12-05  Jim Meyering  <meyering@lucent.com>
27211
27212         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
27213
27214 2000-12-04  Jim Meyering  <meyering@lucent.com>
27215
27216         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
27217         Also include memory.h, stdlib.h, unistd.h if appropriate.
27218         Reported by Andreas Jaeger (conflicting declaration of malloc).
27219
27220 2000-12-02  Jim Meyering  <meyering@lucent.com>
27221
27222         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
27223         * m4/jm-macros.m4 (jm_MACROS): require it.
27224
27225 2000-12-02  Jim Meyering  <meyering@lucent.com>
27226
27227         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
27228
27229 2000-12-01  Paul Eggert  <eggert@twinsun.com>
27230
27231         * lib/memrchr.c: Include <config.h> before any system include file.
27232
27233 2000-11-30  Jim Meyering  <meyering@lucent.com>
27234
27235         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
27236
27237 2000-11-30  Jim Meyering  <meyering@lucent.com>
27238
27239         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
27240
27241 2000-11-29  Paul Eggert  <eggert@twinsun.com>
27242
27243         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
27244
27245 2000-11-26  Jim Meyering  <meyering@lucent.com>
27246
27247         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
27248
27249 2000-11-22  Paul Eggert  <eggert@twinsun.com>
27250
27251         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
27252         size of (size_t) -1; it's not portable.
27253
27254 2000-11-17  Jim Meyering  <meyering@lucent.com>
27255
27256         * lib/strstr.c: Update from GNU libc.
27257
27258 2000-11-17  Akim Demaille  <akim@epita.fr>
27259
27260         * lib/obstack.h: Formatting changes.
27261         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
27262         prevent type checking.
27263         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
27264         cast the value to (void *): assigning a `foo *' to a `void *'
27265         variable is valid.
27266         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
27267
27268 2000-11-16  Jim Meyering  <meyering@lucent.com>
27269
27270         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
27271
27272 2000-11-11  Jim Meyering  <meyering@lucent.com>
27273
27274         * lib/error.c: Add a couple #includes, merging from GNU libc version.
27275
27276 2000-11-10  Jim Meyering  <meyering@lucent.com>
27277
27278         * lib/obstack.h: Update from GNU libc.
27279         * lib/obstack.c: Likewise.
27280
27281 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
27282
27283         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
27284
27285 2000-11-06  Paul Eggert  <eggert@twinsun.com>
27286
27287         * lib/getusershell.c (setusershell): Use rewind rather than
27288         fseek/fseeko, to avoid configuration hassles with fseeko.
27289         Don't bother opening SHELLS_FILE if shellstream is NULL;
27290         it's not necessary.
27291
27292 2000-11-05  Jim Meyering  <meyering@lucent.com>
27293
27294         * lib/makepath.h (make_dir): Declare.
27295         * lib/makepath.c (make_dir): Remove `static' attribute.
27296         Tweak a comment.
27297
27298 2000-11-04  Jim Meyering  <meyering@lucent.com>
27299
27300         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
27301
27302 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
27303
27304         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
27305         last one in a bucket, advance to the next bucket.
27306
27307 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
27308
27309         * lib/fnmatch.c: Do not comment out all the code if we are using
27310         the GNU C library, because in some cases we are replacing buggy
27311         code in the GNU C library itself.
27312
27313 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
27314
27315         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
27316         (regex_compile): Catch bogus \(\1\).
27317
27318 2000-10-30  Paul Eggert  <eggert@twinsun.com>
27319
27320         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
27321         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
27322         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
27323
27324 2000-10-30  Paul Eggert  <eggert@twinsun.com>
27325
27326         * lib/error.h, getline.h, modechange.h:
27327         Remove "2000" from Copyright line, as the file hasn't been
27328         changed this year other than in the copyright notice.
27329
27330         * lib/xalloc.h: Add "2000" to Copyright line, as this file
27331         was changed this year.
27332
27333 2000-10-29  Jim Meyering  <meyering@lucent.com>
27334
27335         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
27336         renaming.
27337         * m4/ls-mntd-fs.m4: Likewise
27338
27339 2000-10-29  Jim Meyering  <meyering@lucent.com>
27340
27341         * lib/xstat.in: Fix grammar in comment.
27342
27343 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
27344
27345         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
27346         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
27347         doesn't define __restrict_arr.
27348
27349 2000-10-28  Jim Meyering  <meyering@lucent.com>
27350
27351         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
27352         (jm_PREREQ_MEMCHR): New function.
27353
27354 2000-10-28  Jim Meyering  <meyering@lucent.com>
27355
27356         * lib/memchr.c: Update from libc.
27357         Adjust for portability:
27358         [HAVE_STDLIB_H]: Include stdlib.h.
27359         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
27360         Undef __memchr, too.
27361         [!weak_alias]: Define __memchr to memchr.
27362
27363         * lib/regex.c: Update from libc.
27364         * lib/regex.h: Likewise.
27365         * lib/getopt1.c: Likewise.
27366         * lib/memcmp.c: Likewise.
27367
27368         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
27369         Avoid using fseek, when possible -- it's broken by design.
27370         Patch by Ulrich Drepper.
27371
27372 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
27373
27374         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
27375         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
27376         Giving in to popular pressure to shut up the compiler with casts.
27377
27378 2000-10-26  Jim Meyering  <meyering@lucent.com>
27379
27380         * lib/strftime.c: Update from libc.
27381
27382 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
27383
27384         * regex.c: More `unsigned char' -> `re_char' changes.
27385         Also change several `int' into `re_wchar_t'.
27386         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
27387         (PUSH_FAILURE_POINTER): Don't cast any more.
27388         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
27389         We want GCC to complain, since this piece of code makes
27390         re_match non-reentrant, which *should* be fixed.
27391         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
27392         (EXTEND_BUFFER): Use RETALLOC.
27393         (SET_LIST_BIT): Don't cast.
27394         (re_wchar_t): New type.
27395         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
27396         that those two functions will always properly return.
27397         (IMMEDIATE_QUIT_CHECK): Cast to void.
27398         (analyse_first): Use recursion rather than an explicit stack.
27399         (re_compile_fastmap): Can't fail anymore.
27400         (re_search_2): Don't check re_compile_fastmap for failure.
27401         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
27402         Now also sets the new value (passed in a new argument).
27403         (re_match_2_internal): Use it.
27404         Also, use a new var `reg' of type size_t when looping through regs
27405         rather than reuse the inappropriate `mcnt'.
27406
27407 2000-10-25  Jim Meyering  <meyering@lucent.com>
27408
27409         * lib/obstack.c: Update from libc.
27410
27411 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
27412
27413         * regex.c (regex_compile): Change the way of handling a range from
27414         a char less than 256 to a char not less than 256.
27415
27416 2000-10-24  Andrew Innes  <andrewi@gnu.org>
27417
27418         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
27419         NT-Emacs only.
27420         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
27421         so that re_search functions only quit when callers expect them to.
27422
27423 2000-10-23  Jim Meyering  <meyering@lucent.com>
27424
27425         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
27426         wrong.  That set_locale call must not have any side effects.
27427         From Paul Eggert.
27428
27429 2000-10-22  Jim Meyering  <meyering@lucent.com>
27430
27431         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
27432         [CYCLIC]: Remove now-unused definition.
27433
27434         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
27435         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
27436         Suggestion from Ulrich Drepper.
27437
27438 2000-10-21  Jim Meyering  <meyering@lucent.com>
27439
27440         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
27441         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
27442         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
27443
27444 2000-10-21  Jim Meyering  <meyering@lucent.com>
27445
27446         * lib/dirname.c (memrchr): Declare if necessary.
27447         (dir_name): Remove the restriction that there be no
27448         trailing slashes.  Now, this code skips past them, effectively
27449         ignoring them.
27450         [TEST_DIRNAME] (main): New unit tests.
27451
27452         * lib/memrchr.c: New file from GNU libc.
27453         Undef __memrchr, too.
27454         [!weak_alias]: Define __memrchr to memrchr.
27455         Guard weak_alias use with `#ifdef weak_alias'.
27456
27457 2000-10-21  Jim Meyering  <meyering@lucent.com>
27458
27459         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
27460         (dir_name): Use dir_name_r.
27461         * lib/dirname.h (dir_name_r): Declare it.
27462
27463 2000-10-17  Jim Meyering  <meyering@lucent.com>
27464
27465         * lib/quote.h (PARAMS): Define and use.
27466         Reported by Akim Demaille.
27467
27468         * lib/getopt.c: Update from libc.
27469
27470 2000-10-16  Jim Meyering  <meyering@lucent.com>
27471
27472         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
27473         setlocale.
27474         From Jan Fedak.
27475
27476 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
27477
27478         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
27479
27480 2000-09-25  Jim Meyering  <meyering@lucent.com>
27481
27482         * lib/md5.h (rol): Define (from GnuPG).
27483
27484         * lib/sha.c: Give credit (GnuPG) where due.
27485         (M): Use rol rather than open-coding it.
27486         Add a FIXME comment.
27487
27488 2000-09-21  Jim Meyering  <meyering@lucent.com>
27489
27490         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
27491         Reported by Michael Stone.
27492
27493 2000-09-20  Jim Meyering  <meyering@lucent.com>
27494
27495         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
27496         (noinst_HEADERS): Add sha.h.
27497         Based on code from Scott G. Miller and from GnuPG.
27498
27499 2000-09-18  Jim Meyering  <meyering@lucent.com>
27500
27501         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
27502         LIBS. Otherwise, everyone ends up linking with -lelf for some
27503         configurations.
27504         Reported by Mike Stone.
27505
27506 2000-09-15  Jim Meyering  <meyering@lucent.com>
27507
27508         * lib/regex.c: Update from libc.
27509
27510 2000-09-10  Jim Meyering  <meyering@lucent.com>
27511
27512         * lib/getopt.c (_getopt_internal): Update from glibc.
27513
27514 2000-09-09  Jim Meyering  <meyering@lucent.com>
27515
27516         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
27517         think it should be used as a general replacement for isascii.
27518         * lib/fnmatch.c: Likewise.
27519         * lib/mbswidth.c: Likewise
27520         * lib/regex.c: Likewise.
27521
27522         Don't use atoi.
27523         * lib/userspec.c: Include sys/param.h and limits.h.
27524         Include xstrtol.h.
27525         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
27526         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
27527         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
27528         UID, GID.  Check range.
27529
27530 2000-09-06  Jim Meyering  <meyering@lucent.com>
27531
27532         * lib/getopt.c (_getopt_internal): Update from glibc.
27533
27534 2000-08-30  Jim Meyering  <meyering@lucent.com>
27535
27536         * lib/strftime.c: Merge in changes from GNU libc.
27537
27538 2000-08-26  Jim Meyering  <meyering@lucent.com>
27539
27540         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
27541         * m4/fpending.m4: New file.
27542
27543 2000-08-26  Jim Meyering  <meyering@lucent.com>
27544
27545         * lib/closeout.c: Include "__fpending.h".
27546         (close_stdout_status): Return right away if there's nothing to flush.
27547
27548         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
27549         * lib/__fpending.c: New file.
27550         * lib/__fpending.h: New file.
27551
27552 2000-08-20  Jim Meyering  <meyering@lucent.com>
27553
27554         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
27555         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
27556         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
27557
27558 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
27559
27560         Improve fileutils installation on systems where running
27561         programs (like install) can't be unlinked.
27562         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
27563         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
27564
27565 2000-08-07  Paul Eggert  <eggert@twinsun.com>
27566
27567         Standardize on "memory exhausted" instead of "Memory exhausted"
27568         or "virtual memory exhausted".
27569         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
27570         "virtual memory exhausted".
27571         * lib/same.c (same_name): Invoke xalloc_die instead of printing
27572         our own message.
27573         * lib/userspec.c (parse_user_spec): Likewise.
27574         * lib/bumpalloc.h: comment fix
27575         * lib/same.c, userspec.c: Include xalloc.h.
27576
27577         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
27578         not char *const and pointing to a constant array.
27579         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
27580         (xrealloc): Comment fix.
27581
27582         * lib/userspec.c (parse_user_spec):
27583         Don't translate a message until just before returning,
27584         to avoid unnecessary translation.
27585
27586 2000-08-07  Jim Meyering  <meyering@lucent.com>
27587
27588         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
27589         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
27590         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
27591         getgroups.c, gethostname.c, getopt.h, group-member.c,
27592         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
27593         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
27594         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
27595         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
27596         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
27597         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
27598         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
27599         yesno.c: Back out Copyright date changes for each file with no change
27600         this year.  This eases coordination with other programs using the same
27601         source code modules.  From Paul Eggert.
27602
27603 2000-08-06  Paul Eggert  <eggert@twinsun.com>
27604
27605         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
27606         not char, for compatibility with glibc 2.1.3 strftime.c.
27607
27608 2000-08-03  Greg McGary  <greg@mcgary.org>
27609
27610         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
27611         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
27612         (EXTEND_BUFFER): Use them.
27613
27614 2000-08-01  Jim Meyering  <meyering@lucent.com>
27615
27616         * lib/dirname.c (ISSLASH): Define.
27617         (BACKSLASH_IS_PATH_SEPARATOR): Define.
27618         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
27619         both `\' and `/' may be use as path separators.
27620         Based on a patch from Prashant TR.
27621
27622 2000-07-31  Paul Eggert  <eggert@twinsun.com>
27623
27624         * lib/quotearg.c (quotearg_n_options): Don't make the initial
27625         slot vector a constant, since it might get modified.
27626
27627 2000-07-31  Jim Meyering  <meyering@lucent.com>
27628
27629         * lib/xmalloc.c: Use `virtual memory exhausted', not
27630         `Memory exhausted'.
27631         * lib/obstack.c (print_and_abort): Likewise.
27632
27633 2000-07-30  Paul Eggert  <eggert@twinsun.com>
27634
27635         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
27636         buffer, so that the caller can always quote one small
27637         component of a "memory exhausted" message in slot 0.
27638         From a suggestion by Jim Meyering.
27639
27640 2000-07-30  Jim Meyering  <meyering@lucent.com>
27641
27642         * lib/makepath.c (make_path): Quote the other instance, too.
27643
27644         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
27645         (STATIC_BUF_SIZE): Define.
27646         (quotearg_n_options): Use only statically allocated storage when
27647         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
27648         than STATIC_BUF_SIZE.
27649
27650 2000-07-29  Jim Meyering  <meyering@lucent.com>
27651
27652         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
27653         * lib/dirname.c (dir_name): Likewise.
27654
27655         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
27656         `/'.
27657
27658         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
27659         (dir_name): Assert that there are no trailing slashes.
27660
27661 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
27662
27663         * lib/mbswidth.h (mbswidth): Add a flags argument.
27664         (mbswidth): New declaration.
27665         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
27666         * lib/mbswidth.c (mbswidth): Add a flags argument.
27667         (mbsnwidth): New function.
27668
27669 2000-07-24  Jim Meyering  <meyering@lucent.com>
27670
27671         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
27672
27673 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27674
27675         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
27676
27677 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27678
27679         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
27680         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
27681         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
27682         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
27683         invoke multibyte primitives.
27684
27685 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27686
27687         * lib/quotearg.c:
27688         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
27689         so that mbstate_t is always defined.
27690
27691         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
27692         be 1 in at least one GCC installation, and this configuration
27693         error is likely to be common.  Ignoring MB_LEN_MAX hurts
27694         performance on hosts that have mbrtowc but have only unibyte
27695         locales, but I assume these hosts are rare.
27696
27697 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27698
27699         * lib/mbswidth.c (_XOPEN_SOURCE):
27700         Don't define; this causes problems on Solaris 7.
27701         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
27702
27703 2000-07-23  Jim Meyering  <meyering@lucent.com>
27704
27705         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
27706         too: getgrgid, getpwuid, getuid.
27707
27708 2000-07-23  Jim Meyering  <meyering@lucent.com>
27709
27710         * lib/basename.c (base_name): Add an assertion.
27711
27712 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
27713
27714         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
27715         shadow its mbsinit function.
27716
27717 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27718
27719         * lib/mbswidth.h: New file.
27720         * lib/mbswidth.c: New file.
27721         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
27722         (noinst_HEADERS): Add mbswidth.h.
27723
27724 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27725
27726         * lib/config.charset: Add support for FreeBSD. Improve support for
27727         HP-UX and IRIX 6.
27728
27729 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
27730
27731         * m4/mbswidth.m4: New file.
27732         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
27733
27734 2000-07-15  Jim Meyering  <meyering@lucent.com>
27735
27736         * lib/makepath.c: Include quote.h.
27737         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
27738         corresponding argument in a `quote (...)' call.
27739         Give better diagnostics.
27740
27741         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
27742         (noinst_HEADERS): Add quote.h.
27743
27744         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
27745         from tar's src/misc.c.
27746         * lib/quote.h: New file.  Prototypes for same.
27747
27748 2000-07-14  Paul Eggert  <eggert@twinsun.com>
27749
27750         From a suggestion by Bruno Haible.
27751         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
27752         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
27753         to decide whether to define the BeOS workaround macro;
27754         this adjusts to the change to AC_MBSTATE_T.
27755
27756 2000-07-14  Jim Meyering  <meyering@lucent.com>
27757
27758         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
27759         jm_AC_TYPE_UINTMAX_T.
27760
27761 2000-07-13  Paul Eggert  <eggert@twinsun.com>
27762
27763         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
27764
27765         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
27766         quotearg_buffer_restyled): Add support for
27767         clocale_quoting_style.  Undo previous change to
27768         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
27769         and "{RIGHT QUOTATION MARK}" msgids.
27770
27771 2000-07-10  Paul Eggert  <eggert@twinsun.com>
27772
27773         From a suggestion by Bruno Haible.
27774         * m4/mbstate_t.m4 (AC_MBSTATE_T):
27775         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
27776         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
27777         and mbstate_t, to a single-part test that simply defines mbstate_t.
27778         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
27779         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
27780
27781 2000-07-10  Jim Meyering  <meyering@lucent.com>
27782
27783         * m4/strerror_r.m4: Mirror the correction made in autoconf.
27784
27785         * m4/gnu-source.m4: Output to confdefs.h directly.
27786         Suggestion from Akim Demaille.
27787
27788 2000-07-09  Paul Eggert  <eggert@twinsun.com>
27789
27790         The old behavior of quoting `like this' doesn't look good with
27791         newer, ISO-style fonts.  See:
27792         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
27793
27794         Instead, quote "like this" by default.  Let the translator
27795         tailor the locale-specific quoting behavior by providing
27796         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
27797
27798         * lib/quotearg.c (N_): New macro.
27799         (gettext_default): New function.
27800         (quotearg_buffer_restyled): Use
27801         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
27802         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
27803
27804 2000-07-09  Jim Meyering  <meyering@lucent.com>
27805
27806         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
27807         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
27808
27809         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
27810         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
27811
27812 2000-07-09  Jim Meyering  <meyering@lucent.com>
27813
27814         * lib/Most files: Update copyright dates to include 2000.
27815
27816 2000-07-08  Jim Meyering  <meyering@lucent.com>
27817
27818         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
27819         if not defined.
27820         (xgethostname): Remove now-unnecessary #ifdef.
27821         Move declaration of `err' into loop where it's used.
27822
27823 2000-07-05  Paul Eggert  <eggert@twinsun.com>
27824         and Bruno Haible  <haible@clisp.cons.org>
27825
27826         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
27827         only if the test for an object-type mbstate_t fails.  This
27828         prevents us from mistakenly reporting that mbstate_t is a
27829         system object type after we "#define mbstate_t int" to work
27830         around its lack.
27831
27832 2000-07-05  Paul Eggert  <eggert@twinsun.com>
27833         and Bruno Haible  <haible@clisp.cons.org>
27834
27835         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
27836
27837 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27838
27839         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
27840         to strerror_r.
27841         Include <ctype.h> for use of isalpha.
27842
27843 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27844
27845         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
27846         by allocating a larger buffer. Test the gethostname return value for
27847         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
27848         returns an error and ENAMETOOLONG isn't defined.
27849
27850 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
27851
27852         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
27853         dimension.
27854
27855 2000-07-04  Jim Meyering  <meyering@lucent.com>
27856
27857         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
27858         of the deprecated AC_CHECKING.
27859
27860 2000-07-04  Jim Meyering  <meyering@lucent.com>
27861
27862         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
27863         Reported by Bruno Haible.
27864
27865 2000-07-04  Jim Meyering  <meyering@lucent.com>
27866
27867         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
27868         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
27869         lacks mbrtowc.
27870
27871 2000-07-03  Paul Eggert  <eggert@twinsun.com>
27872
27873         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
27874         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
27875
27876 2000-07-03  Paul Eggert  <eggert@twinsun.com>
27877         and Bruno Haible  <haible@clisp.cons.org>
27878
27879         * lib/quotearg.c (mbrtowc):
27880         Assign to *pwc, and return 1 only if result is nonzero.
27881         (iswprint): Use ISPRINT when substituting our own mbrtowc.
27882
27883 2000-07-03  Jim Meyering  <meyering@lucent.com>
27884
27885         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
27886
27887 2000-07-03  Jim Meyering  <meyering@lucent.com>
27888
27889         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
27890         This is necessary to get a definition of e.g., UTMP_FILE on
27891         HP-UX 10.20.
27892         From Bob Proulx.
27893
27894 2000-07-02  Jim Meyering  <meyering@lucent.com>
27895
27896         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
27897
27898         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
27899         AC_LIBOBJ(function_name).
27900         * m4/chown.m4: Likewise.
27901         * m4/fnmatch.m4: Likewise.
27902         * m4/ftruncate.m4: Likewise.
27903         * m4/getgroups.m4: Likewise.
27904         * m4/getline.m4: Likewise.
27905         * m4/group-member.m4: Likewise.
27906         * m4/jm-macros.m4: Likewise.
27907         * m4/lstat.m4: Likewise.
27908         * m4/malloc.m4: Likewise.
27909         * m4/memcmp.m4: Likewise.
27910         * m4/nanosleep.m4: Likewise.
27911         * m4/putenv.m4: Likewise.
27912         * m4/realloc.m4: Likewise.
27913         * m4/regex.m4: Likewise.
27914         * m4/stat.m4: Likewise.
27915         * m4/strftime.m4: Likewise.
27916
27917 2000-07-02  Jim Meyering  <meyering@lucent.com>
27918
27919         * lib/quotearg.c (mbstate_t): Don't define here.
27920
27921 2000-07-02  Jim Meyering  <meyering@lucent.com>
27922
27923         * lib/nanosleep.c (SIGCONT): Define if not already defined.
27924
27925 2000-07-01  Jim Meyering  <meyering@lucent.com>
27926
27927         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
27928
27929 2000-07-01  Jim Meyering  <meyering@lucent.com>
27930
27931         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
27932         problem.
27933
27934 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
27935
27936         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
27937         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
27938
27939 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
27940
27941         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
27942         per change in ../m4/ls-mntd-fs.m4.
27943         (read_filesystem_list): Ignore symbolic links.
27944
27945 2000-06-29  Jim Meyering  <meyering@lucent.com>
27946
27947         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
27948         for declaration of strcmp.
27949
27950         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
27951
27952         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
27953         Avoid warning by casting result to `char *' to remove `const'.
27954
27955 2000-06-28  Jim Meyering  <meyering@lucent.com>
27956
27957         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
27958         included by quotearg.c, for which we perform this test.  From
27959         Bruno Haible.
27960
27961 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
27962
27963         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
27964         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
27965         <utmpx.h> exists, put readutmp.o into LIBOBJS.
27966
27967 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
27968
27969         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
27970
27971 2000-06-26  Paul Eggert  <eggert@twinsun.com>
27972
27973         savedir now sets errno on failure and invokes xmalloc to get memory.
27974         Fix a couple of other minor bugs while we're at it.
27975
27976         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
27977         (NAMLEN): Remove macro.
27978         (malloc, realloc): Remove decls.
27979         (stpcpy): Likewise.
27980         ("xalloc.h"): Include.
27981         (NAME_SIZE_DEFAULT): New macro.
27982         (savedir): Use xmalloc / xrealloc to allocate memory.
27983         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
27984         Skip "" directory entries.
27985         Use strlen to calculate directory entry length, since the old method
27986         is rarely used these days and isn't worth supporting.
27987         Don't use a pointer after freeing it.
27988         Check for integer overflow when calculating allocation size.
27989         Use memcpy to copy entries, instead of stpcpy.
27990         Set errno properly when returning NULL.
27991         Check for readdir error.
27992
27993 2000-06-26  Jim Meyering  <meyering@lucent.com>
27994
27995         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
27996
27997 2000-06-25  Jim Meyering  <meyering@lucent.com>
27998
27999         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
28000         Linux header bug when _XOPEN_SOURCE is defined to 500.
28001
28002 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
28003
28004         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
28005         deficiency.
28006
28007 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
28008
28009         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
28010         Include xalloc.h.
28011         Don't include <stdlib.h>.  Don't declare malloc, realloc.
28012
28013 2000-06-24  Jim Meyering  <meyering@lucent.com>
28014
28015         * m4/strerror_r.m4: Revive this file -- to try out an experimental
28016         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
28017         for which strerror does return char*, but which lacks a conveniently
28018         accessible declaration of the function.  If the compile-test says
28019         strerror_r doesn't work, then resort to a `run'-test that works on
28020         BeOS and segfaults on DEC Unix.
28021
28022 2000-06-24  Jim Meyering  <meyering@lucent.com>
28023
28024         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
28025
28026 2000-06-23  Paul Eggert  <eggert@twinsun.com>
28027
28028         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
28029         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
28030
28031 2000-06-23  Paul Eggert  <eggert@twinsun.com>
28032
28033         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
28034         (mbrtowc, mbstate_t): Define substitutes if
28035         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
28036         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
28037         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
28038
28039 2000-06-23  Jim Meyering  <meyering@lucent.com>
28040
28041         * m4/afs.m4: Add missing AC_MSG_RESULT.
28042         Reported by Bruno Haible.
28043
28044         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
28045         Suggestion from Bruno Haible.
28046
28047 2000-06-23  Jim Meyering  <meyering@lucent.com>
28048
28049         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
28050
28051 2000-06-21  Jim Meyering  <meyering@lucent.com>
28052
28053         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
28054
28055 2000-06-21  Jim Meyering  <meyering@lucent.com>
28056
28057         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
28058         (noinst_HEADERS): Add getstr.h.
28059
28060         * lib/getline.c (getstr): Move into a separate file.
28061         * lib/getstr.c (getstr): New file, extracted from getline.c, with
28062         the following changes: new parameter, delim2; both delim[12]
28063         parameters have type `int', not `char'.  The latter would lose
28064         with 8-bit delimiters.
28065         * lib/getstr.h: New file.
28066
28067 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28068
28069         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
28070         than 1024, return a memory chunk of least possible size, instead
28071         of size PATH_MAX + 2. In the loop, increment the size proportionally.
28072         Use free/xmalloc instead of xrealloc to avoid copying for very long
28073         paths.
28074
28075 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28076
28077         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
28078         the empty string.
28079
28080 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28081
28082         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
28083         address, not strdup.  Include <stdlib.h> and don't declare free().
28084
28085 2000-06-19  Jim Meyering  <meyering@lucent.com>
28086
28087         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
28088
28089 2000-06-18  Jim Meyering  <meyering@lucent.com>
28090
28091         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
28092
28093         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
28094         `checking whether...' message to be consistent with that of the
28095         lstat test.
28096
28097 2000-06-18  Jim Meyering  <meyering@lucent.com>
28098
28099         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
28100         Besides, these days every porting target provides a mkdir function.
28101
28102         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
28103         needed. (this snippet comes from src/system.h).
28104
28105 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
28106
28107         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
28108
28109 2000-06-15  Paul Eggert  <eggert@twinsun.com>
28110
28111         * lib/human.c (adjust_value): New function.
28112         (human_readable_inexact): Apply rounding style even when
28113         printing approximate values.
28114
28115 2000-06-14  Paul Eggert  <eggert@twinsun.com>
28116
28117         * lib/human.c (human_readable_inexact): Allow an input block
28118         size that is not a multiple of the output block size, and vice versa.
28119         Reported by Piergiorgio Sartor.
28120
28121 2000-06-14  Paul Eggert  <eggert@twinsun.com>
28122
28123         * lib/getdate.y (get_date): Apply relative times after time
28124         zone indicator, not before.  Reported by Todd A. Jacobs.
28125
28126 2000-06-13  Jim Meyering  <meyering@lucent.com>
28127
28128         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
28129
28130         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
28131
28132 2000-06-12  Paul Eggert  <eggert@twinsun.com>
28133
28134         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
28135
28136 2000-06-12  Jim Meyering  <meyering@lucent.com>
28137
28138         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
28139         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
28140         optional argument.
28141         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
28142         the optional argument, `lib'.
28143
28144 2000-06-08  Jim Meyering  <meyering@lucent.com>
28145
28146         * m4/largefile.m4: Remove file (now that it's part of autoconf).
28147
28148 2000-06-04  Paul Eggert  <eggert@twinsun.com>
28149
28150         Rewrite largefile configuration so that we don't need to run
28151         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
28152         AC_CANONICAL_HOST in configure.in -- jmm]
28153
28154         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
28155         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
28156         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
28157         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
28158         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
28159         All uses changed.
28160         Instead of inspecting the output of getconf, try to compile the
28161         test program without and with the macro definition.
28162         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
28163         for getconf.  Instead, check for the needed flags by compiling
28164         test programs.
28165
28166 2000-06-04  Paul Eggert  <eggert@twinsun.com>
28167
28168         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
28169
28170 2000-06-04  Jim Meyering  <meyering@lucent.com>
28171
28172         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
28173         SunOS 4.1.4 for which gid_t is an unsigned type.
28174
28175 2000-06-03  Jim Meyering  <meyering@lucent.com>
28176
28177         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
28178         now that autoconf requires that.
28179
28180         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
28181         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
28182         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
28183
28184 2000-06-03  Jim Meyering  <meyering@lucent.com>
28185
28186         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
28187
28188 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
28189
28190         * m4/glibc21.m4: New file.
28191         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
28192
28193 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
28194
28195         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
28196         newer, don't install charset.alias.
28197         * lib/config.charset: Change the Linux/glibc rules so they become empty
28198         on glibc-2.1 or newer.
28199
28200 2000-06-02  Jim Meyering  <meyering@lucent.com>
28201
28202         * lib/mountlist.c: Back out last change.  Instead, do this...
28203         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
28204         me_dummy member using the same `ignore'-testing code.
28205         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
28206         fs_type strings.
28207         From Mark D. Roth.
28208
28209 2000-05-29  Jim Meyering  <meyering@lucent.com>
28210
28211         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
28212         mounts with the `ignore' attribute.  Based on a patch from
28213         Mark D. Roth.
28214
28215 2000-05-28  Jim Meyering  <meyering@lucent.com>
28216
28217         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
28218         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
28219         * m4/stat.m4: Likewise.
28220         * m4/lstat.m4: Likewise.
28221         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
28222
28223         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
28224         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
28225
28226 2000-05-26  Jim Meyering  <meyering@lucent.com>
28227
28228         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
28229
28230 2000-05-24  Jim Meyering  <meyering@lucent.com>
28231
28232         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
28233         autoconf requires that.
28234         * m4/lib-check.m4: Likewise.
28235         * m4/jm-macros.m4: Likewise.
28236         * m4/strftime.m4: Likewise.
28237
28238         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
28239         AC_CHECK_DECLS, now that autoconf requires that.
28240
28241 2000-05-22  Jim Meyering  <meyering@lucent.com>
28242
28243         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
28244         * m4/lstat.m4: Likewise.
28245
28246 2000-05-22  Jim Meyering  <meyering@lucent.com>
28247
28248         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
28249
28250 2000-05-20  Jim Meyering  <meyering@lucent.com>
28251
28252         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
28253         (jm_PREREQ): Use it.
28254
28255 2000-05-18  Jim Meyering  <meyering@lucent.com>
28256
28257         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
28258         back, too, since it may have been modified by allocate_entry.
28259         (hash_delete): Rewrite to use neither the assignment operator
28260         nor the comma operator in an if-expression.
28261
28262 2000-05-15  Paul Eggert  <eggert@twinsun.com>
28263
28264         * lib/closeout.c:
28265         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
28266         Remove; no longer needed.
28267         "quotearg.h": Add include.
28268         (file_name): Do not bother to explicitly initialize to NULL; it's less
28269         efficient on some hosts.
28270         (close_stdout_status): Remove test as to whether stdout was already
28271         closed; it breaks for the case "echo x | sort >&-".
28272         Quote file name colons.
28273         Do not assume that _("write error") lacks format strings.
28274
28275 2000-05-15  Jim Meyering  <meyering@lucent.com>
28276
28277         * lib/version-etc.c (version_etc_copyright): Update the copyright
28278         string used in all --version output.
28279
28280 2000-05-14  Jim Meyering  <meyering@lucent.com>
28281
28282         * lib/closeout.c (close_stdout_set_file_name): New function.
28283         (close_stdout_status): Use new file-scoped global.
28284         Return right away if fstat says the stdout file descriptor is invalid.
28285         * lib/closeout.h (close_stdout_set_file_name): Declare.
28286
28287 2000-05-10  Jim Meyering  <meyering@lucent.com>
28288
28289         * lib/closeout.c [default_exit_status]: New file-scoped variable.
28290         (close_stdout_set_status): New function.
28291         * lib/closeout.h (close_stdout_set_status): Declare.
28292
28293 2000-05-09  Jim Meyering  <meyering@lucent.com>
28294
28295         * m4/gettext.m4: Rename this...
28296         * m4/libintl.m4: ...to this.
28297
28298 2000-05-08  Jim Meyering  <meyering@lucent.com>
28299
28300         * lib/long-options.c: Don't include closeout.h.
28301         (parse_long_options): Don't call close_stdout for --version.
28302
28303 2000-05-06  Paul Eggert  <eggert@twinsun.com>
28304
28305         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
28306         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
28307         2.1.3 bug.  This avoids a clash when files like regex.c define
28308         _GNU_SOURCE.
28309
28310 2000-05-06  Jim Meyering  <meyering@lucent.com>
28311
28312         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
28313         (AC_REPLACE_FUNCS): Add strnlen.
28314
28315         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
28316         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
28317
28318         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
28319         AC_SEARCH_LIBS call for nanosleep.
28320         (LIB_NANOSLEEP): Set and AC_SUBST.
28321
28322 2000-05-06  Jim Meyering  <meyering@lucent.com>
28323
28324         * lib/strnlen.c: Undefine __strnlen and strnlen.
28325         [!weak_alias]: Define __strnlen to strnlen.
28326
28327         * lib/atexit.c: New file, from libiberty.
28328
28329 2000-05-06  Jim Meyering  <meyering@lucent.com>
28330
28331         * lib/closeout.c (close_stdout_status): Also check for errors on the
28332         stderr stream.
28333
28334 2000-05-05  Jim Meyering  <meyering@lucent.com>
28335
28336         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
28337         AC_SEARCH_LIBS call for clock_gettime.
28338         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
28339
28340         * m4/search-libs.m4: Update from autoconf.
28341
28342         su doesn't work on Solaris 2.6.
28343         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
28344         <shadow.h>.  Reported by Dragos Harabor.
28345
28346 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
28347
28348         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
28349         memcpy instead of xmalloc, xrealloc, path_concat.
28350         (locale_charset): Treat empty environment variables as absent.
28351         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
28352
28353 2000-05-04  Jim Meyering  <meyering@lucent.com>
28354
28355         * lib/getopt.c: Update from glibc.
28356         * lib/obstack.c: Likewise.
28357         * lib/obstack.h: Likewise.
28358         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
28359         file
28360
28361         * lib/regex.h: Likewise.
28362         * lib/strndup.c: Likewise.
28363         * lib/strnlen.c: New file, from glibc.
28364
28365 2000-05-03  Jim Meyering  <meyering@lucent.com>
28366
28367         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
28368
28369 2000-05-02  Paul Eggert  <eggert@twinsun.com>
28370
28371         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
28372         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
28373         compile-time test, rather than inspecting host and OS, to
28374         decide whether to define _LARGEFILE_SOURCE.
28375
28376 2000-05-01  Jim Meyering  <meyering@lucent.com>
28377
28378         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
28379
28380         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
28381         Based on a patch from Bruno Haible.
28382
28383 2000-05-01  Jim Meyering  <meyering@lucent.com>
28384
28385         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
28386
28387 2000-04-29  Jim Meyering  <meyering@lucent.com>
28388
28389         * lib/path-concat.c: Declare strdup only if it's not defined.
28390         * lib/canon-host.c: Likewise.
28391
28392 2000-04-28  Jim Meyering  <meyering@lucent.com>
28393
28394         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
28395         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
28396         is included first, then limits.h is included by locale.h by libintl.h.
28397         From John David Anglin.
28398
28399 2000-04-25  Jim Meyering  <meyering@lucent.com>
28400
28401         * lib/makepath.c (S_IRWXUGO): Define.
28402         (make_path): Always perform explicit chmod if MODE specifies any
28403         of the `special' permission bits.  Prompted by a bug report against
28404         install from Mate Wierdl and Joost van Baal.
28405
28406 2000-04-18  Jim Meyering  <meyering@lucent.com>
28407
28408         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
28409         (jm_PREREQ): Use it.
28410
28411 2000-04-18  Jim Meyering  <meyering@lucent.com>
28412
28413         * lib/README: New file.
28414
28415         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
28416         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
28417
28418 2000-04-17  Jim Meyering  <meyering@lucent.com>
28419
28420         Get it right :-)
28421         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
28422         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
28423         Suggestion from Akim Demaille.
28424
28425 2000-04-17  Jim Meyering  <meyering@lucent.com>
28426
28427         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
28428         the definition of it to rpl_strftime also defined-away the system's
28429         declaration.
28430
28431 2000-04-15  Jim Meyering  <meyering@lucent.com>
28432
28433         Use `C' to denote so-called `contiguous' files, the same way
28434         that tar does.
28435         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
28436         (ftypelet): Use S_ISCTG.
28437         From Michael Deutschmann.
28438
28439 2000-04-14  Jim Meyering  <meyering@lucent.com>
28440
28441         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
28442         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
28443         clobbered.
28444
28445 2000-04-14  Jim Meyering  <meyering@lucent.com>
28446
28447         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
28448
28449 2000-04-13  Jim Meyering  <meyering@lucent.com>
28450
28451         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
28452         AH_VERBATIM to insert required #ifndef into config.h.in.
28453         Suggestion from Akim Demaille.
28454
28455 2000-04-12  Jim Meyering  <meyering@lucent.com>
28456
28457         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
28458         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
28459         Christian Krackowizer.
28460
28461         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
28462         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
28463         (AC_SYS_LARGEFILE): Require.
28464         (AM_C_PROTOTYPES): Require.
28465
28466 2000-04-08  Jim Meyering  <meyering@lucent.com>
28467
28468         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
28469         names don't conflict.  Reported by Eli Zaretskii.
28470
28471 2000-04-07  Jim Meyering  <meyering@lucent.com>
28472
28473         * lib/putenv.c: Move inclusion of errno.h so it follows that of
28474         sys/types.h, to work around system header problems on AIX 3.2.5.
28475         From Bruno Haible.
28476
28477 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
28478
28479         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
28480         bug.  Deal with the different error behavior of Irix iconv.
28481
28482 2000-04-05  Paul Eggert  <eggert@twinsun.com>
28483
28484         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
28485         IRIX if the installer said otherwise.
28486
28487 2000-04-05  Jim Meyering  <meyering@lucent.com>
28488
28489         Portability tweaks required for ultrix4.3.
28490         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
28491         (jm_CHECK_DECLS): Add getutent to the list of functions.
28492         (_jm_DECL_HEADERS): Add utmpx.h.
28493         From John David Anglin.
28494
28495         * m4/strftime.m4: Back out the 2000-04-02 change.
28496         Instead of that change, simply undefine putenv in the test program.
28497
28498 2000-04-05  Jim Meyering  <meyering@lucent.com>
28499
28500         Portability tweaks required for ultrix4.3.
28501         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
28502         getutent.
28503         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
28504         * lib/canon-host.c: Declare strdup.
28505         * lib/path-concat.c: Likewise.
28506         From John David Anglin.
28507
28508 2000-04-04  Jim Meyering  <meyering@lucent.com>
28509
28510         Be more DOS 8.3-friendly.
28511         * lib/ref-add.sin: Renamed from ref-add.sed.in.
28512         * lib/ref-del.sin: Renamed from ref-del.sed.in.
28513         * lib/Makefile.am: Reflect renaming.
28514         Reported by Eli Zaretskii.
28515
28516         Use a temporary file name that won't clash with `charset.alias'
28517         in the DOS 8.3 name space.
28518         * lib/Makefile.am (charset_tmp): Define.
28519         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
28520         (uninstall-local): Likewise.
28521         Reported by Eli Zaretskii.
28522
28523 2000-04-03  Jim Meyering  <meyering@lucent.com>
28524
28525         * m4/gettext.m4: Fix typo in comment.
28526
28527         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
28528         textutils/configure.in).  Suggestion from Paul Eggert.
28529         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
28530
28531 2000-04-02  Paul Eggert  <eggert@twinsun.com>
28532
28533         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
28534         variable in the shell rather than using putenv, which isn't
28535         portable.  This avoids the configure-time inter-test dependency
28536         on the potentially-renamed putenv function.
28537
28538 2000-03-30  Paul Eggert  <eggert@twinsun.com>
28539
28540         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
28541         before checking struct stat.st_blksize, so that
28542         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
28543
28544 2000-03-29  Paul Eggert  <eggert@twinsun.com>
28545
28546         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
28547         since strftime.c uses HAVE_STRFTIME to decide whether to use
28548         the underlying strftime.
28549
28550 2000-03-29  Paul Eggert  <eggert@twinsun.com>
28551
28552         * lib/time/strftime.c (my_strftime): Make sure we call the system
28553         strftime, not ourselves, when invoking the underlying strftime.
28554
28555 2000-03-24  Jim Meyering  <meyering@lucent.com>
28556
28557         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
28558         (charset_alias): Define.
28559         (install-exec-local): Factor out common code.
28560         (uninstall-local): Split lines longer than 80.
28561         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
28562         (SUFFIXES): Define.
28563         (.sed.in.sed): New rule.  Don't redirect directly to $@.
28564         (CLEANFILES): Add ref-add.sed and ref-del.sed.
28565
28566 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
28567
28568         * lib/config.charset: Output a line containing "Packages using this
28569         file".
28570         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
28571         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
28572         ref-del.sed): New rules.
28573
28574 2000-03-17  Jim Meyering  <meyering@lucent.com>
28575
28576         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
28577         Otherwise, include <strings.h>
28578
28579 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
28580
28581         * lib/unicodeio.c (utf8_wctomb): New function.
28582         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
28583         format instead of in UCS-4 with platform dependent endianness.
28584
28585 2000-03-10  Jim Meyering  <meyering@lucent.com>
28586
28587         * m4/lib-check.m4: Look for getspnam in -lgen, too.
28588         From Marco Franzen.
28589
28590 2000-03-07  Paul Eggert  <eggert@twinsun.com>
28591
28592         * lib/savedir.c (savedir): Work even if directory size is
28593         negative; this can happen with some screwy NFS configurations.
28594
28595 2000-03-06  Jim Meyering  <meyering@lucent.com>
28596
28597         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
28598         if it's NULL (because we ran out of memory).  From Bruno Haible.
28599
28600 2000-03-05  Jim Meyering  <meyering@lucent.com>
28601
28602         * lib/localcharset.c ("path-concat.h"): Include.
28603         (get_charset_aliases): Use path_concat instead of ANSI string
28604         concatenation.
28605
28606         * lib/unicodeio.h (PARAMS): Define.
28607         Use it to guard prototype.
28608
28609 2000-03-04  Jim Meyering  <meyering@lucent.com>
28610
28611         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
28612         for lib/localcharset.c.
28613
28614 2000-03-04  Jim Meyering  <meyering@lucent.com>
28615
28616         * lib/Makefile.am (install-exec-local): Create $(libdir) before
28617         installing into it.
28618         (uninstall-local): Uncomment this rule so `make distcheck' works
28619         once again.
28620
28621         * lib/unicodeio.c (<errno.h>): Include it.
28622         (errno): Declare if not defined.
28623
28624         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
28625
28626         * lib/config.charset: New version, incorporating remarks from a linux
28627         i18n mailing list.  From Bruno Haible.
28628
28629 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
28630
28631         * m4/codeset.m4: New file.
28632         * m4/iconv.m4: New file.
28633         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
28634
28635 2000-03-03  Jim Meyering  <meyering@lucent.com>
28636
28637         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
28638
28639 2000-03-02  Jim Meyering  <meyering@lucent.com>
28640
28641         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
28642         the messages come out on separate lines.
28643
28644         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
28645         rather than jm_CHECK_DECLARATIONS.
28646         * m4/decl.m4: Remove now-unused file.
28647
28648         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
28649         geteuid.
28650
28651 2000-03-02  Jim Meyering  <meyering@lucent.com>
28652
28653         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
28654
28655 2000-03-01  Jim Meyering  <meyering@lucent.com>
28656
28657         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
28658         * lib/unicodeio.c: Likewise.
28659
28660 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
28661
28662         * lib/config.charset: New file.
28663         * lib/localcharset.c: New file.
28664         * lib/unicodeio.h, lib/unicodeio.c: New files.
28665         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
28666         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
28667         (noinst_HEADERS): Add unicodeio.h.
28668         (all-local, install-exec-local, charset.alias): New targets.
28669
28670 2000-02-28  Paul Eggert  <eggert@twinsun.com>
28671
28672         * lib/quotearg.c (ALERT_CHAR): New macro.
28673         (quotearg_buffer_restyled): Use it.
28674
28675 2000-02-27  Jim Meyering  <meyering@lucent.com>
28676
28677         * m4/check-decl.m4: Add getenv to the list.
28678
28679 2000-02-27  Jim Meyering  <meyering@lucent.com>
28680
28681         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
28682         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
28683
28684         * lib/backupfile.c: Guard inclusion of stdlib.h with
28685         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
28686         Declare malloc if needed.
28687
28688         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
28689         `#ifndef HAVE_DECL..'
28690         now that autoconf always defines the HAVE_DECL_ symbols.
28691         * lib/human.c: Likewise.
28692         * lib/same.c: Likewise.
28693         * lib/strtoumax.c: Likewise.
28694
28695         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
28696         declaration check was not run.
28697         * lib/hash.c: Likewise.
28698         * lib/human.c: Likewise.
28699         * lib/same.c: Likewise.
28700         * lib/strtoumax.c: Likewise.
28701
28702         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
28703         `.', then first look up the entire `.'-containing string as a login
28704         name.
28705
28706 2000-02-23  Jim Meyering  <meyering@lucent.com>
28707
28708         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
28709         in place of my hack.
28710
28711 2000-02-18  Paul Eggert  <eggert@twinsun.com>
28712
28713         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
28714         (textint): New typedef.
28715         (parser_control): Member year changed from int to textint.
28716         All uses changed.
28717         (YYSTYPE): Removed; replaced by %union with int and textint members.
28718         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
28719         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
28720         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
28721         (tSNUMBER, tUNUMBER): Now of type <textintval>.
28722         (date, number, to_year): Use width of number in digits, not its value,
28723         to determine whether it's a 2-digit year, or a 2-digit time.
28724         (yylex): Store number of digits of numeric tokens.
28725         Reported by John Kendall.
28726
28727         (parser_control): Changed from struct parser_control to typedef (for
28728         consistency).  All uses changed.
28729
28730         (tID): Removed; not used.
28731         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
28732
28733 2000-02-14  Paul Eggert  <eggert@twinsun.com>
28734
28735         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
28736         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
28737
28738 2000-02-12  Jim Meyering  <meyering@lucent.com>
28739
28740         * lib/userspec.c (ISDIGIT): Define it.
28741         (isdigit): Remove definition.
28742         (is_number): Use ISDIGIT, not isdigit.
28743         <libintl.h>: Include.
28744         (_ and N_): Define.
28745         (parse_user_spec): Mark translatable strings.
28746
28747 2000-02-10  Jim Meyering  <meyering@lucent.com>
28748
28749         With these changes, nanosleep.[ch] are finally enough like the other
28750         lib/* replacement files to compile on a few more losing systems.
28751
28752         * lib/nanosleep.h: Don't include config.h.
28753         Remove prototype from declaration of nanosleep.
28754         (PARAMS): Remove now-unneeded definition.
28755         * lib/nanosleep.c: #undef nanosleep.
28756         (rpl_nanosleep): Rename from nanosleep.
28757
28758 2000-02-10  Jim Meyering  <meyering@lucent.com>
28759
28760         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
28761         gnu_nanosleep to rpl_nanosleep.
28762
28763 2000-02-09  Jim Meyering  <meyering@lucent.com>
28764
28765         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
28766         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
28767
28768 2000-02-08  Akim Demaille  <akim@epita.fr>
28769
28770         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
28771         `[' and `]' and remove uses of `changequote'.
28772         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
28773         (AC_SYS_LARGEFILE): Likewise.
28774         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
28775         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
28776         of changequote.
28777         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
28778         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
28779         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
28780         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
28781
28782 2000-02-05  Jim Meyering  <meyering@lucent.com>
28783
28784         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
28785         Remove explicit use of AC_HEADER_TIME.  It is required by
28786         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
28787         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
28788         in autoconf whereby the expansion of the latter ended up preceding
28789         the expansion of its prerequisite, AC_HEADER_TIME.
28790         Reported by Volker Borchert.
28791
28792 2000-02-03  Jim Meyering  <meyering@lucent.com>
28793
28794         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
28795
28796 2000-02-03  Jim Meyering  <meyering@lucent.com>
28797
28798         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
28799         rather than with `#if HAVE_UTMPNAME'.
28800
28801 2000-02-02  Jim Meyering  <meyering@lucent.com>
28802
28803         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
28804         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
28805         Reported by Eli Zaretskii.
28806
28807 2000-02-01  Jim Meyering  <meyering@lucent.com>
28808
28809         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
28810
28811 2000-01-31  Jim Meyering  <meyering@lucent.com>
28812
28813         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
28814         functions.  Add the time.h and sys/time.h headers along with the
28815         AC_REQUIRE'ment of AC_HEADER_TIME.
28816
28817 2000-01-31  Jim Meyering  <meyering@lucent.com>
28818
28819         * lib/nanosleep.h (nanosleep): Guard declaration with
28820         `#if ! HAVE_DECL_NANOSLEEP'.
28821         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
28822         the declaration in that vendor's sys/timers.h.
28823         Reported by Christian Krackowizer.
28824
28825         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
28826         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
28827         (ISPRINT): Likewise.
28828         Reported by Tom Tromey.
28829
28830 2000-01-30  Jim Meyering  <meyering@lucent.com>
28831
28832         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
28833
28834         * m4/prereq.m4 (utmp_includes): Define.
28835         Check for ut_user and ut_name members in both struct utmpx
28836         and struct utmp.
28837
28838 2000-01-30  Jim Meyering  <meyering@lucent.com>
28839
28840         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
28841         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
28842         header files where only utmpx.ut_user is declared.
28843
28844         * lib/readutmp.h (UT_USER): Define.
28845
28846 2000-01-29  Jim Meyering  <meyering@lucent.com>
28847
28848         * m4/lib-check.m4: New file containing library-related checks from
28849         fileutils and sh-utils (textutils had none).
28850
28851 2000-01-28  Jim Meyering  <meyering@lucent.com>
28852
28853         * m4/perl.m4: Change format of warning message to look more like that
28854         from the missing script.  Suggestion from François Pinard.
28855
28856 2000-01-25  Jim Meyering  <meyering@lucent.com>
28857
28858         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
28859         well as time.h in the compile check.
28860         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
28861         Fix typo in cross-compiling case: s/yes/no/.
28862
28863 2000-01-23  Jim Meyering  <meyering@lucent.com>
28864
28865         * m4/jm-macros.m4: Move df-related tests here from
28866         fileutils/configure.in
28867
28868         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
28869         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
28870
28871         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
28872         s/space/ac_fsusage_space/.
28873         (jm_FILE_SYSTEM_USAGE): Take two parameters.
28874
28875         * m4/ftruncate.m4: New file (derived from part of
28876         fileutils/configure.in).
28877         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
28878         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
28879
28880         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
28881         AC_SUBST these here, rather than just in sh-util/configure.in, so
28882         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
28883         all the same.
28884         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
28885         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
28886         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
28887         (AC_SUBST(POW_LIBM)): Likewise.
28888         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
28889
28890 2000-01-23  Jim Meyering  <meyering@lucent.com>
28891
28892         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
28893         obstack.c.
28894
28895 2000-01-22  Jim Meyering  <meyering@lucent.com>
28896
28897         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
28898
28899         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
28900
28901         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
28902         configure.in
28903         (AC_CHECK_HEADERS): Likewise for sh-utils.
28904         (AC_CHECK_HEADERS): Likewise for textutils.
28905         Merge the three lists of headers.
28906
28907         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
28908         from fileutils' configure.in.
28909
28910         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
28911         code. Moved tests into their own function (_jm_DECL_HEADERS) in
28912         check-decl.m4.
28913
28914         * m4/check-decl.m4: Use #if rather than #ifdef.
28915         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
28916         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
28917         (_jm_DECL_HEADERS): Define new function.
28918         (jm_CHECK_DECLARATIONS): Require it.
28919
28920 2000-01-22  Jim Meyering  <meyering@lucent.com>
28921
28922         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
28923         [! HAVE_DECL_STRTOULL]: Declare strtoull.
28924         Required for some AIX systems.  Reported by Christian Krackowizer.
28925         [TESTING] (main): New function.
28926
28927         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
28928         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
28929         letters.
28930
28931         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
28932         iswprint.
28933
28934         * lib/strverscmp.c (ISDIGIT): Define.
28935         (strverscmp): Use ISDIGIT, not isdigit.
28936
28937 2000-01-19  Jim Meyering  <meyering@lucent.com>
28938
28939         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
28940         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
28941         defines `struct timespec' in <sys/time.h>
28942
28943         * m4/c-bs-a.m4: Remove uses of changequote altogether.
28944         Thanks to Akim for explaining.
28945
28946 2000-01-17  Paul Eggert  <eggert@twinsun.com>
28947
28948         * lib/nanosleep.c (nanosleep):
28949         Don't use SA_INTERRUPT to decide whether to call sigaction, as
28950         POSIX.1 doesn't require SA_INTERRUPT and some systems
28951         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
28952         it's been part of POSIX.1 since day 1 (in 1988).
28953
28954 2000-01-17  Jim Meyering  <meyering@lucent.com>
28955
28956         * lib/interlock: Remove unused file.  Reported by François Pinard.
28957
28958 2000-01-16  Paul Eggert  <eggert@twinsun.com>
28959
28960         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
28961         alert, backslash, formfeed, and vertical tab unnecessarily in
28962         shell quoting style.
28963
28964 2000-01-16  Jim Meyering  <meyering@lucent.com>
28965
28966         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
28967         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
28968         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
28969         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
28970
28971 2000-01-16  Jim Meyering  <meyering@lucent.com>
28972
28973         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
28974         because the latter didn't work.
28975
28976 2000-01-15  Jim Meyering  <meyering@lucent.com>
28977
28978         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
28979         (AC_REPLACE_FUNCS): Add memcpy and memset.
28980         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
28981         Add strpbrk.
28982         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
28983
28984 2000-01-12  Jim Meyering  <meyering@lucent.com>
28985
28986         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
28987         (jm_PREREQ): Use it.
28988         (jm_PREREQ_READUTMP): New macro.
28989         (jm_PREREQ): Use it.
28990
28991 2000-01-11  Paul Eggert  <eggert@twinsun.com>
28992
28993         Quote multibyte characters correctly.
28994         * m4/c-bs-a.m4: New file.
28995         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
28996         (jm_PREREQ): Use it.
28997
28998 2000-01-11  Paul Eggert  <eggert@twinsun.com>
28999
29000         * m4/uintmax_t.m4: Port to autoconf 2.13.
29001
29002 2000-01-08  Jim Meyering  <meyering@ascend.com>
29003
29004         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
29005         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
29006
29007 2000-01-04  Jim Meyering  <meyering@ascend.com>
29008
29009         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
29010         jm_STRUCT_DIRENT_D_TYPE.
29011         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
29012         jm_STRUCT_DIRENT_D_INO.
29013         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
29014         jm_STRUCT_UTIMBUF.
29015         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
29016         renamings.
29017         * m4/utime.m4: Likewise.
29018
29019         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
29020         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
29021
29022 2000-01-03  Paul Eggert  <eggert@twinsun.com>
29023
29024         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
29025         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
29026
29027 2000-01-02  Jim Meyering  <meyering@ascend.com>
29028
29029         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
29030         remember if this is necessary.
29031
29032 1999-12-26  Jim Meyering  <meyering@ascend.com>
29033
29034         * m4/jm-macros.m4: Use it here.
29035         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
29036
29037 1999-12-23  Jim Meyering  <meyering@ascend.com>
29038
29039         * m4/jm-macros.m4: Check for clock_gettime (moved from
29040         fileutils/configure.in)
29041         Check for gettimeofday.
29042
29043 1999-12-20  Jim Meyering  <meyering@ascend.com>
29044
29045         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
29046         autoconf-2.14a-1999-12-20.
29047
29048 1999-12-19  Jim Meyering  <meyering@ascend.com>
29049
29050         * m4/lstat-slash.m4: New file.
29051         * m4/jm-macros.m4: Use the new macro:
29052         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
29053
29054 1999-12-07  Jim Meyering  <meyering@ascend.com>
29055
29056         * m4/perl.m4: Require that File::Compare be available, too.
29057         Too many systems seem to lack it.
29058
29059         * m4/strftime.m4: Add checks for most of the cpp macros tested in
29060         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
29061
29062 1999-11-18  Paul Eggert  <eggert@twinsun.com>
29063
29064         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
29065         problem with the QNX 4.25 shell, which doesn't propagate exit
29066         status of failed commands inside shell assignments.
29067
29068 1999-11-17  Jim Meyering  <meyering@ascend.com>
29069
29070         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
29071
29072 1999-11-07  Jim Meyering  <meyering@ascend.com>
29073
29074         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
29075
29076 1999-11-06  Jim Meyering  <meyering@ascend.com>
29077
29078         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
29079         * m4/jm-macros.m4 (jm_MACROS): Use it here.
29080
29081 1999-11-05  Jim Meyering  <meyering@ascend.com>
29082
29083         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
29084         configure.in of textutils, fileutils, and sh-utils into this one
29085         (shared between those packages) file.
29086         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
29087         AC_STRUCT_ST_BLKSIZE.
29088
29089 1999-11-03  Jim Meyering  <meyering@ascend.com>
29090
29091         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
29092         of AC_CHECK_TYPE checks includes unistd.h.
29093         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
29094         Suggestion from Akim Demaille.
29095
29096 1999-10-30  Jim Meyering  <meyering@ascend.com>
29097
29098         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
29099         m4-quoted string.
29100         * m4/ls-mntd-fs.m4: Likewise.
29101         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
29102         * m4/jm-winsz1.m4: Likewise.
29103
29104         * m4/const.m4: Remove file, since the fix made it into the experimental
29105         version of autoconf.
29106         * m4/mktime.m4: Likewise.
29107
29108         * m4/check-type.m4: Remove file, now that the latest version of
29109         AC_CHECK_TYPE takes a third arg to specify additional #includes.
29110
29111         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
29112         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
29113         AC_CHECK_TYPE.
29114
29115 1999-10-04  Jim Meyering  <meyering@ascend.com>
29116
29117         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
29118
29119 1999-09-22  Paul Eggert  <eggert@twinsun.com>
29120
29121         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
29122         2.95.1 bug with HP-UX 10.20.
29123
29124 1999-09-17  Jim Meyering  <meyering@ascend.com>
29125
29126         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
29127         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
29128         due to missing strdup (against sh-utils-2.0).
29129
29130 1999-08-29  Jim Meyering  <meyering@ascend.com>
29131
29132         * m4/jm-macros.m4: Require jm_BISON.
29133         * m4/bison.m4: New file.
29134
29135 1999-08-17  Paul Eggert  <eggert@twinsun.com>
29136
29137         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
29138         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
29139
29140 1999-08-05  Jim Meyering  <meyering@ascend.com>
29141
29142         * m4/getline.m4: Rename test file from conftestdata to conftest.data
29143         to avoid conflicts with `conftest' on 8+3 filesystems.
29144         Suggestion from Eli Zaretskii.
29145
29146 1999-08-04  Jim Meyering  <meyering@ascend.com>
29147
29148         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
29149         fileutils and sh-utils (textutils's getline test was inadequate).
29150         (AM_FUNC_GETLINE): Run this test.
29151         (AC_CHECK_FUNCS): Check for getdelim.
29152         Reported by Bob Proulx.
29153
29154 1999-08-02  Jim Meyering  <meyering@ascend.com>
29155
29156         * m4/jm-macros.m4: Add a comment.
29157
29158 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29159
29160         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
29161         <inttypes.h> defines strtoumax as a macro (and not as a
29162         function).
29163
29164 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29165
29166         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
29167         that we can shift, multiply and divide unsigned long long
29168         values; Ultrix cc can't do it.
29169
29170 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29171
29172         * m4/mktime.m4: New file, which is a preview of what should appear
29173         in the next public autoconf release.
29174
29175 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29176
29177         * m4/lfs.m4: Remove this file.
29178         * m4/largefile.m4: New file.  It contains the old contents of
29179         lfs.m4, except that all names with prefix AC_LFS have been
29180         changed to use the prefix AC_SYS_LARGEFILE instead, to be
29181         compatible with future autoconf versions.  Also, some minor m4
29182         quoting problems have been fixed.
29183
29184 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29185
29186         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
29187         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
29188         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
29189         and simplify the shell code.
29190
29191 1999-08-01  Jim Meyering  <meyering@ascend.com>
29192
29193         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
29194         m4.
29195
29196 1999-07-20  Jim Meyering  <meyering@ascend.com>
29197
29198         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
29199
29200 1999-07-15  Jim Meyering  <meyering@ascend.com>
29201
29202         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
29203
29204 1999-05-22  Jim Meyering  <meyering@ascend.com>
29205
29206         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
29207
29208 1999-05-20  Jim Meyering  <meyering@ascend.com>
29209
29210         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
29211         Add a colon after each `then' in case $4 is empty.
29212
29213 1999-05-16  Jim Meyering  <meyering@ascend.com>
29214
29215         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
29216
29217 1999-05-10  Jim Meyering  <meyering@ascend.com>
29218
29219         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
29220
29221         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
29222         AC_FUNC_MKTIME.
29223
29224 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
29225
29226         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
29227
29228 1999-05-04  Paul Eggert  <eggert@twinsun.com>
29229
29230         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
29231         not CPPFLAGS, so that linking works correctly in IRIX.
29232
29233 1999-04-30  Paul Eggert  <eggert@twinsun.com>
29234
29235         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
29236
29237 1999-04-20  Paul Eggert  <eggert@twinsun.com>
29238
29239         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
29240         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
29241         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
29242         jm_AC_TYPE_UNSIGNED_LONG_LONG.
29243         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
29244
29245         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
29246
29247 1999-04-20  Jim Meyering  <meyering@ascend.com>
29248
29249         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
29250         AC_REPLACE xstroull if necessary.  From Paul Eggert.
29251         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
29252
29253 1999-04-18  Jim Meyering  <meyering@ascend.com>
29254
29255         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
29256         * m4/jm-macros.m4: Use it.
29257
29258 1999-04-06  Jim Meyering  <meyering@ascend.com>
29259
29260         * m4/strftime.m4: Remove test for %f.
29261
29262 1999-03-29  Jim Meyering  <meyering@ascend.com>
29263
29264         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
29265         superset of the AC_TYPE_* checks in the textutils, fileutils,
29266         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
29267         AC_TYPE_PID_T.
29268
29269 1999-03-28  Jim Meyering  <meyering@ascend.com>
29270
29271         * m4/jm-macros.m4: Define GNU_PACKAGE here.
29272         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
29273         replaced e.g., in the *.sh files of the sh-utils.
29274
29275 1999-03-20  Jim Meyering  <meyering@ascend.com>
29276
29277         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
29278         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
29279         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
29280
29281 1999-03-19  Jim Meyering  <meyering@ascend.com>
29282
29283         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
29284
29285 1999-03-12  Jim Meyering  <meyering@ascend.com>
29286
29287         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
29288
29289 1999-03-07  Jim Meyering  <meyering@ascend.com>
29290
29291         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
29292         declared.
29293
29294 1999-02-17  Jim Meyering  <meyering@ascend.com>
29295
29296         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
29297         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
29298
29299 1999-02-07  Jim Meyering  <meyering@ascend.com>
29300
29301         * m4/group-member.m4: New file -- extracted from sh-utils'
29302         configure.in.
29303
29304         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
29305         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
29306
29307 1999-02-06  Jim Meyering  <meyering@ascend.com>
29308
29309         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
29310         * m4/fnmatch.m4: Likewise.
29311         * m4/getgroups.m4: Likewise.
29312         * m4/lstat.m4: Likewise.
29313         * m4/malloc.m4: Likewise.
29314         * m4/putenv.m4: Likewise.
29315         * m4/realloc.m4: Likewise.
29316         * m4/regex.m4: Likewise.
29317         * m4/stat.m4: Likewise.
29318         * m4/strftime.m4: Likewise.
29319         Suggestion from Alain Magloire.
29320
29321         * m4/chown.m4: Use `.$ac_objext', not `.o'.
29322         * m4/fnmatch.m4: Likewise.
29323         * m4/getgroups.m4: Likewise.
29324         * m4/getline.m4: Likewise.
29325         * m4/lstat.m4: Likewise.
29326         * m4/malloc.m4: Likewise.
29327         * m4/memcmp.m4: Likewise.
29328         * m4/putenv.m4: Likewise.
29329         * m4/realloc.m4: Likewise.
29330         * m4/regex.m4: Likewise.
29331         * m4/stat.m4: Likewise.
29332         * m4/strftime.m4: Likewise.
29333         Suggestion from Alain Magloire.
29334
29335         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
29336         an argument.
29337
29338         * m4/regex.m4: Add a run-time Test for proper operation of
29339         re_compile_pattern.
29340
29341 1999-01-31  Jim Meyering  <meyering@ascend.com>
29342
29343         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
29344
29345 1999-01-30  Jim Meyering  <meyering@ascend.com>
29346
29347         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
29348
29349         * m4/jm-mktime.m4: Make this a wrapper around the official
29350         AM_FUNC_MKTIME rather than my private copy, now that the official one
29351         is up to date.
29352         * m4/mktime.m4: Remove file.
29353
29354         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
29355         * m4/uptime.m4: Likewise.
29356         * m4/uintmax_t.m4: Likewise.
29357
29358 1999-01-28  Jim Meyering  <meyering@ascend.com>
29359
29360         * m4/jm-macros.m4: Use jm_AFS.
29361         * m4/afs.m4: New file (from fileutils' configure.in).
29362
29363         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
29364         * m4/chown.m4: Likewise.
29365         * m4/d-ino.m4: Likewise.
29366         * m4/d-type.m4: Likewise.
29367         * m4/fnmatch.m4: Likewise.
29368         * m4/getgroups.m4: Likewise.
29369         * m4/gettext.m4: Likewise.
29370         * m4/jm-mktime.m4: Likewise.
29371         * m4/jm-winsz2.m4: Likewise.
29372         * m4/lcmessage.m4: Likewise.
29373         * m4/ls-mntd-fs.m4: Likewise.
29374         * m4/malloc.m4: Likewise.
29375         * m4/memcmp.m4: Likewise.
29376         * m4/putenv.m4: Likewise.
29377         * m4/realloc.m4: Likewise.
29378         * m4/st_mtim.m4: Likewise.
29379         * m4/strftime.m4: Likewise.
29380
29381 1999-01-16  Jim Meyering  <meyering@ascend.com>
29382
29383         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
29384         (ARGMATCH_DIE_DECL): Define.
29385
29386 1999-01-12  Jim Meyering  <meyering@ascend.com>
29387
29388         * m4/Makefile.am.in: Rewrite to avoid using fmt.
29389         Reported by Lars Hecking.
29390
29391 1999-01-10  Jim Meyering  <meyering@ascend.com>
29392
29393         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
29394         gross kludge.
29395         * m4/inttypes_h.m4: Likewise.
29396         * m4/lstat.m4: Likewise.
29397         * m4/malloc.m4: Likewise.
29398         * m4/readdir.m4: Likewise.
29399         * m4/realloc.m4: Likewise.
29400         * m4/st_dm_mode.m4: Likewise.
29401         * m4/stat.m4: Likewise.
29402         * m4/utimbuf.m4: Likewise.
29403         * m4/utimes.m4: Likewise.
29404
29405         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
29406         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
29407         comments in config.h.in are meaningful.
29408
29409         * m4/jm-macros.m4: Require autoconf-2.13 here.
29410
29411         * m4/regex.m4: By default, don't use the included regex.c on systems
29412         with glibc 2.  Suggestion from Uli Drepper.
29413
29414 1999-01-02  Jim Meyering  <meyering@ascend.com>
29415
29416         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
29417
29418 1998-12-18  Jim Meyering  <meyering@ascend.com>
29419
29420         * m4/Makefile.am.in (Makefile.am): Simplify rule.
29421         Based on a suggestion from Lars Hecking.
29422
29423 1998-11-16  Paul Eggert  <eggert@twinsun.com>
29424
29425         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
29426
29427 1998-11-16  Jim Meyering  <meyering@ascend.com>
29428
29429         * m4/lfs.m4: Double-quote the `uname...` expression.
29430
29431 1998-11-14  Jim Meyering  <meyering@ascend.com>
29432
29433         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
29434         * m4/stat.m4: Likewise.
29435
29436 1998-11-03  Jim Meyering  <meyering@ascend.com>
29437
29438         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
29439         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
29440
29441 1998-10-18  Jim Meyering  <meyering@ascend.com>
29442
29443         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
29444
29445 1998-10-17  Jim Meyering  <meyering@ascend.com>
29446
29447         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
29448         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
29449         calls for those previously hard-coded headers.  Instead, take a new
29450         parameter.
29451         (jm_CHECK_DECLARATIONS): Reflect interface change.
29452         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
29453         (jm_CHECK_DECL_LOCALTIME_R): New macro.
29454
29455         * m4/mktime.m4: Test for spring-forward gap before long-running test.
29456
29457 1998-10-14  Jim Meyering  <meyering@ascend.com>
29458
29459         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
29460         instead of "TZ=America/Vancouver".  From Paul Eggert.
29461
29462 1998-10-11  Jim Meyering  <meyering@ascend.com>
29463
29464         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
29465         This adds a test for a recently added compatibility fix for mktime.c.
29466         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
29467
29468 1998-09-27  Jim Meyering  <meyering@ascend.com>
29469
29470         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
29471
29472         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
29473         ../configure.in, including a change from Gordon Matzigkeit to allow
29474         cross-compiling for the Hurd.
29475
29476         * m4/glibc.m4: New file/macro to test for the GNU C Library
29477         versions 1 and 2.  From Gordon Matzigkeit.
29478         Indent.
29479
29480 1998-09-21  Jim Meyering  <meyering@ascend.com>
29481
29482         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
29483
29484 1998-08-18  Paul Eggert  <eggert@twinsun.com>
29485
29486         Port nanosecond-resolution times to UnixWare 2.1.2 and
29487         pedantic Solaris 2.6.
29488
29489         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
29490         AC_STRUCT_ST_MTIM.
29491         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
29492         Generate name of ns member, instead of just 1 or undef.
29493         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
29494
29495 1998-08-15  Jim Meyering  <meyering@ascend.com>
29496
29497         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
29498         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
29499         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
29500         instead of jm_TYPE_SSIZE_T.
29501
29502 1998-08-12  Jim Meyering  <meyering@ascend.com>
29503
29504         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
29505
29506 1998-08-02  Jim Meyering  <meyering@ascend.com>
29507
29508         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
29509         in acconfig.h manually.
29510
29511 1998-07-31  Paul Eggert  <eggert@twinsun.com>
29512
29513         * m4/st_mtim.m4: New file.
29514
29515 1998-07-28  Jim Meyering  <meyering@ascend.com>
29516
29517         * m4/utimes.m4: Undef stat.
29518
29519 1998-07-25  Jim Meyering  <meyering@ascend.com>
29520
29521         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
29522         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
29523
29524 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
29525
29526         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
29527         uid and gid actually remain unchanged.
29528
29529 1998-07-07  Jim Meyering  <meyering@ascend.com>
29530
29531         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
29532
29533 1998-07-04  Jim Meyering  <meyering@ascend.com>
29534
29535         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
29536         to prove that this macro can be used in packages without regex.c.
29537
29538 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
29539
29540         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
29541         is to be used.
29542
29543 1998-07-03  Jim Meyering  <meyering@ascend.com>
29544
29545         * m4/gettext.m4: Add -lintl if it's found to be necessary.
29546
29547         * m4/gettext.m4: New file -- from gettext-0.10.35.
29548         * m4/lcmessage.m4: Likewise.
29549         * m4/progtest.m4: Likewise.
29550
29551         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
29552         * m4/jm-macros.m4: Require the new macro.
29553
29554 1998-06-29  Jim Meyering  <meyering@ascend.com>
29555
29556         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
29557         for the definition of NGROUPS (used in a system header included
29558         by sys/mount.h).
29559
29560 1998-06-28  Jim Meyering  <meyering@ascend.com>
29561
29562         * m4/ls-mntd-fs.m4: New file.
29563         * m4/fstypename.m4: New file.
29564
29565         * m4/jm-macros.m4: Require the new macro.
29566         * m4/jm-glibc-io.m4: New file.
29567
29568 1998-05-19  Jim Meyering  <meyering@ascend.com>
29569
29570         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
29571         * m4/lchown.m4: New file.
29572
29573         * m4/Makefile.am.in: New file.
29574         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
29575
29576 1998-05-14  Jim Meyering  <meyering@ascend.com>
29577
29578         * m4/Makefile.am (EXTRA_DIST): Add them.
29579         * m4/jm-macros.m4: New file.
29580         * m4/utimbuf.m4: New file.
29581
29582 1998-05-12  Jim Meyering  <meyering@ascend.com>
29583
29584         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
29585
29586 1998-05-11  Jim Meyering  <meyering@ascend.com>
29587
29588         * m4/isc-posix.m4: New file.
29589
29590 1998-05-10  Jim Meyering  <meyering@ascend.com>